ERROR - The constructor LocalDateTime(LocalDate, LocalTime) is not visible

Error

"The constructor LocalDateTime(LocalDate, LocalTime) is not visible" while using LocalDateTime and Java 8.

Error Type

Compile Time

Sample Code

LocalDateTime currentTime = new LocalDateTime(null, null);

Cause

Constructors for LocalDateTime are all private.

Resolution

Call the static method  of, ofEpochSecond, from and with to initialize the Localtime instance.  

LocalDateTime currentTime = LocalDateTime.of(2015, 12, 25, 12, 0);