@FunctionalInterfacepublic interfaceLongPredicate
long-valued argument. This is thelong-consuming primitive type specialization ofPredicate.This is afunctional interface whose functional method istest(long).
Predicate| Modifier and Type | Method | Description |
|---|---|---|
defaultLongPredicate | and(LongPredicate other) | Returns a composed predicate that represents a short-circuiting logical AND of this predicate and another. |
defaultLongPredicate | negate() | Returns a predicate that represents the logical negation of this predicate. |
defaultLongPredicate | or(LongPredicate other) | Returns a composed predicate that represents a short-circuiting logical OR of this predicate and another. |
boolean | test(long value) | Evaluates this predicate on the given argument. |
boolean test(long value)
value - the input argumenttrue if the input argument matches the predicate, otherwisefalsedefault LongPredicate and(LongPredicate other)
false, then theother predicate is not evaluated.Any exceptions thrown during evaluation of either predicate are relayed to the caller; if evaluation of this predicate throws an exception, theother predicate will not be evaluated.
other - a predicate that will be logically-ANDed with this predicateother predicateNullPointerException - if other is nulldefault LongPredicate negate()
default LongPredicate or(LongPredicate other)
true, then theother predicate is not evaluated.Any exceptions thrown during evaluation of either predicate are relayed to the caller; if evaluation of this predicate throws an exception, theother predicate will not be evaluated.
other - a predicate that will be logically-ORed with this predicateother predicateNullPointerException - if other is null