Class Check.Comparables
java.lang.Object
atlantafx.validation.Check.Comparables
-
Method Summary
Modifier and TypeMethodDescriptionstatic <T extends Comparable<? super T>>
Predicate<@Nullable T> between(@Nullable T min, @Nullable T max) Checks if a value is within a lower and an upper bound (inclusive).static <T extends Comparable<? super T>>
Predicate<@Nullable T> greaterOrEqual(@Nullable T min) Checks if a value is greater than or equal to a minimum boundary.static <T extends Comparable<? super T>>
Predicate<@Nullable T> greaterThan(@Nullable T min) Checks if a value is strictly greater than a minimum boundary.static <T extends Comparable<? super T>>
Predicate<@Nullable T> inside(@Nullable T min, @Nullable T max) Checks if a value is strictly between a lower and an upper bound.static <T extends Comparable<? super T>>
Predicate<@Nullable T> isEqual(@Nullable T other) Checks if a value is equal to another value, byComparable.compareTo(T), not byObject.equals(Object).static <T extends Comparable<? super T>>
Predicate<@Nullable T> isNotEqual(@Nullable T other) Checks if a value is not equal to another value, byComparable.compareTo(T), not byObject.equals(Object).static <T extends Comparable<? super T>>
Predicate<@Nullable T> lessOrEqual(@Nullable T max) Checks if a value is less than or equal to a maximum boundary.static <T extends Comparable<? super T>>
Predicate<@Nullable T> lessThan(@Nullable T max) Checks if a value is strictly less than a maximum boundary.
-
Method Details
-
isEqual
Checks if a value is equal to another value, byComparable.compareTo(T), not byObject.equals(Object). -
isNotEqual
public static <T extends Comparable<? super T>> Predicate<@Nullable T> isNotEqual(@Nullable T other) Checks if a value is not equal to another value, byComparable.compareTo(T), not byObject.equals(Object). -
inside
public static <T extends Comparable<? super T>> Predicate<@Nullable T> inside(@Nullable T min, @Nullable T max) Checks if a value is strictly between a lower and an upper bound.- Parameters:
min- the lower bound (inclusive)max- the upper bound (exclusive)- Returns:
trueif the value is greater than min and less than max
-
between
public static <T extends Comparable<? super T>> Predicate<@Nullable T> between(@Nullable T min, @Nullable T max) Checks if a value is within a lower and an upper bound (inclusive).- Parameters:
min- the lower bound (inclusive)max- the upper bound (inclusive)- Returns:
trueif the value is greater than or equal to min and less than or equal to max
-
greaterThan
Checks if a value is strictly greater than a minimum boundary. -
greaterOrEqual
public static <T extends Comparable<? super T>> Predicate<@Nullable T> greaterOrEqual(@Nullable T min) Checks if a value is greater than or equal to a minimum boundary. -
lessThan
Checks if a value is strictly less than a maximum boundary. -
lessOrEqual
Checks if a value is less than or equal to a maximum boundary.
-