org.apache.commons.collections.functors
public class PredicateTransformer extends Object implements Transformer, Serializable
Since: Commons Collections 3.0
Version: $Revision: 646777 $ $Date: 2008-04-10 13:33:15 +0100 (Thu, 10 Apr 2008) $
Constructor Summary | |
---|---|
PredicateTransformer(Predicate predicate)
Constructor that performs no validation.
|
Method Summary | |
---|---|
static Transformer | getInstance(Predicate predicate)
Factory method that performs validation.
|
Predicate | getPredicate()
Gets the predicate.
|
Object | transform(Object input)
Transforms the input to result by calling a predicate.
|
getInstance
if you want that.
Parameters: predicate the predicate to call, not null
Parameters: predicate the predicate to call, not null
Returns: the predicate
transformer
Throws: IllegalArgumentException if the predicate is null
Returns: the predicate
Since: Commons Collections 3.1
Parameters: input the input object to transform
Returns: the transformed result