public class Predicates
extends java.lang.Object
Predicate objects.| Modifier and Type | Method and Description |
|---|---|
static <T> Predicate<T> |
alwaysFalse()
Returns a Predicate that always evaluates to false.
|
static <T> Predicate<T> |
alwaysTrue()
Returns a Predicate that always evaluates to true.
|
static <T> Predicate<T> |
and(java.util.Collection<Predicate<? super T>> components)
Returns a Predicate that evaluates to true iff each of its components
evaluates to true.
|
static <T> Predicate<T> |
and(Predicate<? super T>... components)
Returns a Predicate that evaluates to true iff each of its components
evaluates to true.
|
static <T> Predicate<T> |
not(Predicate<? super T> predicate)
Returns a Predicate that evaluates to true iff the given Predicate
evaluates to false.
|
static <T> Predicate<T> |
or(Predicate<? super T>... components)
Returns a Predicate that evaluates to true iff any one of its components
evaluates to true.
|
public static <T> Predicate<T> alwaysTrue()
public static <T> Predicate<T> alwaysFalse()
public static <T> Predicate<T> not(Predicate<? super T> predicate)
public static <T> Predicate<T> and(Predicate<? super T>... components)
public static <T> Predicate<T> and(java.util.Collection<Predicate<? super T>> components)
public static <T> Predicate<T> or(Predicate<? super T>... components)