static public boolean isSameLocalDate ( LocalDate first , LocalDate second ) { // If both values are null, return true. if ( first == null && second == null ) { return true ; } // At least one value contains a date. If the other value is null, then return false. if ( first == null || second == null ) { return false ; } // Both values contain dates. Return true if the dates are equal, otherwise return false. return first . isEqual ( second ) ; }
isSameLocalDate This compares two date variables to see if their values are equal . Returns true if the values are equal otherwise returns false .