edu.rice.cs.cunit.util
Class ILambda.Ternary.Bind2nd<R,P,Q,S>

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

public static class ILambda.Ternary.Bind2nd<R,P,Q,S>
extends java.lang.Object
implements ILambda.Binary<R,P,S>

Binary decorator for a ternary lambda that binds a constant to its second parameter.


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  Q _constant
          The constant second argument.
private  ILambda.Ternary<R,P,Q,S> _decoree
          The ternary lambda that is decorated.
 
Constructor Summary
ILambda.Ternary.Bind2nd(ILambda.Ternary<R,P,Q,S> decoree, Q constant)
          Create a new binary decorator for a ternary lambda, binding a constant to its second parameter.
 
Method Summary
 R apply(P param1, S param3)
          Apply the binary decorator, i.e.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

_constant

private Q _constant
The constant second argument.


_decoree

private ILambda.Ternary<R,P,Q,S> _decoree
The ternary lambda that is decorated.

Constructor Detail

ILambda.Ternary.Bind2nd

public ILambda.Ternary.Bind2nd(ILambda.Ternary<R,P,Q,S> decoree,
                               Q constant)
Create a new binary decorator for a ternary lambda, binding a constant to its second parameter.

Parameters:
decoree - ternary lambda
constant - constant for the ternary lambda's second parameter
Method Detail

apply

public R apply(P param1,
               S param3)
Apply the binary decorator, i.e. apply the constant and the parameters to the ternary lambda.

Specified by:
apply in interface ILambda.Binary<R,P,S>
Parameters:
param1 - argument for the ternary lambda's first parameter
param3 - argument for the ternary lambda's third parameter
Returns:
return value of the binary lambda