org.apache.commons.collections.functors
Class TransformerPredicate
java.lang.Object
org.apache.commons.collections.functors.TransformerPredicate
- Predicate, Serializable
public final class TransformerPredicate
extends java.lang.Object
Predicate implementation that returns the result of a transformer.
$Revision: 1.6 $ $Date: 2004/05/16 11:16:01 $
TransformerPredicate
public TransformerPredicate(Transformer transformer)
Constructor that performs no validation.
Use getInstance
if you want that.
transformer
- the transformer to decorate
evaluate
public boolean evaluate(Object object)
Evaluates the predicate returning the result of the decorated transformer.
- evaluate in interface Predicate
object
- the input object
- true if decorated transformer returns Boolean.TRUE
getInstance
public static Predicate getInstance(Transformer transformer)
Factory to create the predicate.
transformer
- the transformer to decorate
getTransformer
public Transformer getTransformer()
Gets the transformer.
Copyright © 2001-2006 Apache Software Foundation. All Rights Reserved.