edu.rice.cs.cunit.util
Class ILambda.Nary.TernaryAdaptor<R,P>
java.lang.Object
edu.rice.cs.cunit.util.ILambda.Nary.TernaryAdaptor<R,P>
- All Implemented Interfaces:
- ILambda.Nary<R,P>
- Enclosing interface:
- ILambda.Nary<R,P>
public static class ILambda.Nary.TernaryAdaptor<R,P>
- extends java.lang.Object
- implements ILambda.Nary<R,P>
Adapter to turn a ternary lambda into an N-ary lambda (with N=3).
Nested classes/interfaces inherited from interface edu.rice.cs.cunit.util.ILambda.Nary |
ILambda.Nary.BinaryAdaptor<R,P>, ILambda.Nary.Bind<R,P>, ILambda.Nary.BindK<R,P>, ILambda.Nary.Max<T extends java.lang.Comparable<T>>, ILambda.Nary.Min<T extends java.lang.Comparable<T>>, ILambda.Nary.TernaryAdaptor<R,P>, ILambda.Nary.UnaryAdaptor<R,P> |
Method Summary |
R |
apply(P... param)
Apply the ternary lambda. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
_decoree
private ILambda.Ternary<R,P,P,P> _decoree
- The ternary lambda.
ILambda.Nary.TernaryAdaptor
public ILambda.Nary.TernaryAdaptor(ILambda.Ternary<R,P,P,P> decoree)
- Creates a new N-ary lambda (with N=3).
- Parameters:
decoree
- ternarylambda
apply
public R apply(P... param)
- Apply the ternary lambda.
- Specified by:
apply
in interface ILambda.Nary<R,P>
- Parameters:
param
- exactly three parameter.
- Returns:
- return value of the ternary lambda
- Throws:
java.lang.IllegalArgumentException
- if param.length != 3