edu.rice.cs.cunit.util
Class ILambda.Binary.NaryAdaptor<R,P>

java.lang.Object
  extended by edu.rice.cs.cunit.util.ILambda.Binary.NaryAdaptor<R,P>
All Implemented Interfaces:
ILambda.Binary<R,P,P>
Enclosing interface:
ILambda.Binary<R,P,Q>

public static class ILambda.Binary.NaryAdaptor<R,P>
extends java.lang.Object
implements ILambda.Binary<R,P,P>

Adapter to turn an N-ary lambda into a binary lambda.


Nested Class Summary
 
Nested classes/interfaces inherited from interface edu.rice.cs.cunit.util.ILambda.Binary
ILambda.Binary.Bind1st<R,P,Q>, ILambda.Binary.Bind2nd<R,P,Q>, ILambda.Binary.Max<T extends java.lang.Comparable<T>>, ILambda.Binary.Min<T extends java.lang.Comparable<T>>, ILambda.Binary.NaryAdaptor<R,P>
 
Field Summary
private  ILambda.Nary<R,P> _decoree
          The N-ary lambda.
 
Constructor Summary
ILambda.Binary.NaryAdaptor(ILambda.Nary<R,P> decoree)
          Creates a new binary lambda.
 
Method Summary
 R apply(P param1, P param2)
          Apply the N-ary lambda.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

_decoree

private ILambda.Nary<R,P> _decoree
The N-ary lambda.

Constructor Detail

ILambda.Binary.NaryAdaptor

public ILambda.Binary.NaryAdaptor(ILambda.Nary<R,P> decoree)
Creates a new binary lambda.

Parameters:
decoree - N-ary lambda
Method Detail

apply

public R apply(P param1,
               P param2)
Apply the N-ary lambda.

Specified by:
apply in interface ILambda.Binary<R,P,P>
Parameters:
param1 - the first parameter.
param2 - the second parameter.
Returns:
return value of the N-ary lambda