Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVA

java check if dates are the same day

<dependency>
    <groupId>org.apache.commons</groupId>
    <artifactId>commons-lang3</artifactId>
    <version>3.12.0</version>
</dependency>

Then we can simply use the method isSameDay from DateUtils:

DateUtils.isSameDay(date1, date2);
Source by www.baeldung.com #
 
PREVIOUS NEXT
Tagged: #java #check #dates #day
ADD COMMENT
Topic
Name
7+7 =