Package org.kiwiproject.time
Class KiwiDurations
java.lang.Object
org.kiwiproject.time.KiwiDurations
Utilities related to Java's
Duration class.-
Method Summary
Modifier and TypeMethodDescriptionstatic booleanisNegativeOrZero(Duration duration) Check if aDurationis negative or zero.static booleanisPositive(Duration duration) Check if aDurationis positive.static booleanisPositiveOrZero(Duration duration) Check if aDurationis positive or zero.
-
Method Details
-
isPositive
Check if aDurationis positive.- Parameters:
duration- the duration to check- Returns:
- true if the duration is strictly positive, otherwise false
-
isPositiveOrZero
Check if aDurationis positive or zero.- Parameters:
duration- the duration to check- Returns:
- true if the duration is positive or zero, otherwise false
-
isNegativeOrZero
Check if aDurationis negative or zero.- Parameters:
duration- the duration to check- Returns:
- true if the duration is negative or zero, otherwise false
-