public class StandardPredicates extends Object
| Modifier and Type | Method and Description |
|---|---|
static <T> Predicate<T> |
isAssignableFrom(Class<?> clazz)
Returns a predicate checking whether its argument is an instance of the given class or any of its descendant classes.
|
static <T> Predicate<T> |
isInstanceOf(Class<?> clazz)
Returns a predicate checking whether its argument is an instance of the given class.
|
static <T> Predicate<T> |
isNonNull()
Returns a predicate checking whether its argument is non-
null. |
static <T> Predicate<T> |
isNull()
Returns a predicate checking whether its argument is
null. |
public static <T> Predicate<T> isAssignableFrom(Class<?> clazz)
IllegalArgumentException - if clazz is nullMoreObjects.isDescendantOf(Object, Class)public static <T> Predicate<T> isInstanceOf(Class<?> clazz)
IllegalArgumentException - if clazz is nullMoreObjects.isInstanceOf(Object, Class)public static <T> Predicate<T> isNonNull()
null.public static <T> Predicate<T> isNull()
null.