T - the binary predicate input typespublic final class IsLessThanOrEqual<T> extends Object implements BinaryPredicate<T,T>, Serializable
BinaryPredicate that tests
true iff the left argument is less than or equal to the
right argument under the specified Comparator.
When no (or a null Comparator is specified,
a Comparable Comparator is used.| Modifier and Type | Field and Description |
|---|---|
static IsLessThanOrEqual<Comparable<?>> |
INSTANCE
Basic IsLessThanOrEqual instance.
|
| Constructor and Description |
|---|
IsLessThanOrEqual()
|
IsLessThanOrEqual(Comparator<? super T> comparator)
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(IsLessThanOrEqual<?> that)
Learn whether another IsLessThanOrEqual is equal to this.
|
boolean |
equals(Object that) |
int |
hashCode() |
static <T extends Comparable<?>> |
instance()
Get a typed IsLessThanOrEqual instance.
|
static <T extends Comparable<?>> |
instance(T right)
Get an IsLessThanOrEqual UnaryPredicate.
|
boolean |
test(T left,
T right)
Evaluate this predicate.
|
String |
toString() |
public static final IsLessThanOrEqual<Comparable<?>> INSTANCE
public IsLessThanOrEqual()
public IsLessThanOrEqual(Comparator<? super T> comparator)
comparator - the Comparator, when null,
a Comparator for Comparables will
be used.public boolean test(T left, T right)
true iff the left parameter is
less than or equal to the right parameter under my current
Comparator.test in interface BinaryPredicate<T,T>left - the L element of the ordered pair of argumentsright - the R element of the ordered pair of argumentspublic boolean equals(IsLessThanOrEqual<?> that)
that - the IsLessThanOrEqual to test.public static <T extends Comparable<?>> IsLessThanOrEqual<T> instance()
T - the binary predicate input typespublic static <T extends Comparable<?>> UnaryPredicate<T> instance(T right)
T - the binary predicate input typesright - the right side object of the comparison.Copyright © 2003-2013 The Apache Software Foundation. All Rights Reserved.