|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectuk.co.jezuk.mango.Predicates
The Mango Library Unary and Binary Predicates
| Method Summary | |
static BinaryPredicate |
And(BinaryPredicate pred1,
BinaryPredicate pred2)
A BinaryPredicate which returns the logical AND of two other BinaryPredicate. |
static Predicate |
And(Predicate pred1,
Predicate pred2)
A Predicate which returns the logical AND of two other Predicate. |
static BinaryPredicate |
EqualTo()
BinaryPredicate testing for equality. |
static Predicate |
False()
A Predicate which always returns false |
static BinaryPredicate |
GreaterThan()
BinaryPredicate that returns true if x is greater than y. |
static BinaryPredicate |
GreaterThanEquals()
BinaryPredicate that returns true if x is greater than or equal to y. |
static BinaryPredicate |
LessThan()
BinaryPredicate that returns true if x is less than y. |
static BinaryPredicate |
LessThanEquals()
BinaryPredicate that returns true if x is less than or equal to y. |
static BinaryPredicate |
Not(BinaryPredicate pred)
A BinaryPredicate which is the logical negation of some other BinaryPredicate. |
static Predicate |
Not(Predicate pred)
A Predicate which is the logical negation of some other Predicate. |
static BinaryPredicate |
NotEqualTo()
true if not(x.equals(y)), (x == null) && not(y == null) or not(x == null) && (y == null) |
static BinaryPredicate |
Or(BinaryPredicate pred1,
BinaryPredicate pred2)
A BinaryPredicate which returns the logical OR of two other BinaryPredicate. |
static Predicate |
Or(Predicate pred1,
Predicate pred2)
A Predicate which returns the logical OR of two other Predicate. |
static Predicate |
True()
A Predicate which always returns true |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Method Detail |
public static Predicate True()
Predicate which always returns true
public static Predicate False()
Predicate which always returns false
public static Predicate Not(Predicate pred)
Predicate which is the logical negation of some other Predicate. If n
is a Not object, and pred is the Predicate it was constructed with,
then n.test(x) returns !pred.test(x).
public static Predicate And(Predicate pred1,
Predicate pred2)
Predicate which returns the logical AND of two other Predicate. If a
is an And object, constructed with pred1 and pred2, then
a.test(x) returns pred1.test(x) && pred2.test(x)
public static Predicate Or(Predicate pred1,
Predicate pred2)
Predicate which returns the logical OR of two other Predicate. If a
is an Or object, constructed with pred1 and pred2, then
a.test(x) returns pred1.test(x) || pred2.test(x)
public static BinaryPredicate EqualTo()
BinaryPredicate testing for equality.
true if x.equals(y) or (x == null && y == null)
public static BinaryPredicate GreaterThan()
BinaryPredicate that returns true if x is greater than y.
x and y must implement the java.lang.Comparable interface.
public static BinaryPredicate GreaterThanEquals()
BinaryPredicate that returns true if x is greater than or equal to y.
x and y must implement the java.lang.Comparable interface.
public static BinaryPredicate LessThan()
BinaryPredicate that returns true if x is less than y.
x and y must implement the java.lang.Comparable interface.
public static BinaryPredicate LessThanEquals()
BinaryPredicate that returns true if x is less than or equal to y.
x and y must implement the java.lang.Comparable interface.
public static BinaryPredicate NotEqualTo()
true if not(x.equals(y)), (x == null) && not(y == null) or not(x == null) && (y == null)
public static BinaryPredicate Not(BinaryPredicate pred)
BinaryPredicate which is the logical negation of some other BinaryPredicate. If n
is a Not object, and pred is the Predicate it was constructed with,
then n.test(x,y) returns !pred.test(x,y).
public static BinaryPredicate And(BinaryPredicate pred1,
BinaryPredicate pred2)
BinaryPredicate which returns the logical AND of two other BinaryPredicate. If a
is an And object, constructed with pred1 and pred2, then
a.test(x,y) returns pred1.test(x,y) && pred2.test(x,y)
public static BinaryPredicate Or(BinaryPredicate pred1,
BinaryPredicate pred2)
BinaryPredicate which returns the logical OR of two other BinaryPredicate. If a
is an Or object, constructed with pred1 and pred2, then
a.test(x,y) returns pred1.test(x,y) || pred2.test(x,y)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||