public static long durationMS ( LocalDateTime start , LocalDateTime end ) { if ( start == null || end == null ) { return 0 ; } return Duration . between ( start , end ) . toMillis ( ) ; }
The time between two dates