L - the left argument type.R - the right argument type.T - the returned value type.public class UnaryCompositeBinaryFunction<L,R,T> extends Object implements BinaryFunction<L,R,T>, Serializable
BinaryFunction composed of
one binary function, f, and two unary
functions, g and h,
evaluating the ordered parameters x, y
to f(g(x),h(y)).
Note that although this class implements
Serializable, a given instance will
only be truly Serializable if all the
underlying functors are. Attempts to serialize
an instance whose delegates are not all
Serializable will result in an exception.
| Constructor and Description |
|---|
UnaryCompositeBinaryFunction(BinaryFunction<? super G,? super H,? extends T> f,
UnaryFunction<? super L,? extends G> g,
UnaryFunction<? super R,? extends H> h)
Create a new UnaryCompositeBinaryFunction.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Object that) |
boolean |
equals(UnaryCompositeBinaryFunction<?,?,?> that)
Learn whether a given UnaryCompositeBinaryFunction is equal to this.
|
T |
evaluate(L left,
R right)
Evaluate this function.
|
int |
hashCode() |
String |
toString() |
public UnaryCompositeBinaryFunction(BinaryFunction<? super G,? super H,? extends T> f, UnaryFunction<? super L,? extends G> g, UnaryFunction<? super R,? extends H> h)
G - the adapted function left argument type.H - the adapted function right argument type.f - BinaryFunction to receive (output(g), output(h))g - left UnaryFunctionh - right UnaryFunctionpublic T evaluate(L left, R right)
evaluate in interface BinaryFunction<L,R,T>left - the L element of the ordered pair of argumentsright - the R element of the ordered pair of argumentspublic boolean equals(UnaryCompositeBinaryFunction<?,?,?> that)
that - UnaryCompositeBinaryFunction to testCopyright © 2003-2013 The Apache Software Foundation. All Rights Reserved.