September 2018
Intermediate to advanced
802 pages
19h 30m
English
Often, we would want to compare date and time instances with others to check if they are before, after, or the same as that of the other. To achieve this, JDK provides isBefore(), isAfter(), and isEqual() methods in the java.time.LocalDate, java.time.LocalDateTime, and java.time.ZonedDateTime classes. In this recipe, we will look at using these methods to compare date and time instances.
Read now
Unlock full access