T
- The type of objects the predicate can evaluate.public interface Predicate<T> extends Serializable
T
, and evaluates it
as either true
or false
.
ƒ(T) ∈ {true, false}Semantically, a predicate is a specialization of
Fn
, with the return type set to primitive boolean
.
Since Java does not allow type parameterization with primitive types, and predicates
play such an important role, it has been modeled as its own separate type.Modifier and Type | Interface and Description |
---|---|
static class |
Predicate.Always<T> |
Modifier and Type | Method and Description |
---|---|
boolean |
$(T value) |
boolean $(T value)
Copyright © 2016. All rights reserved.