info.javelot.functionalj
Class Function2Impl<R,P1,P2>
java.lang.Object
info.javelot.functionalj.Function2Impl<R,P1,P2>
- All Implemented Interfaces:
- Function2<R,P1,P2>
public abstract class Function2Impl<R,P1,P2>
- extends Object
- implements Function2<R,P1,P2>
A base implementation of the Function2 interface, which implements all
methods except for the Function2.call(Object,Object) method - that is left to
subclasses to implement in order to define a function of 2 parameters.
- Author:
- Copyright © 2006
Frederic Daoud
|
Method Summary |
Function1<R,P2> |
bind(P1 p_param1)
Binds the first parameter of this function of 2 parameters to return a new
function of 1 parameter. |
Function0<R> |
bind(P1 p_param1,
P2 p_param2)
Binds both parameters of this function of 2 parameters to return a new
function of no parameters. |
Function1<R,P1> |
bind2(P2 p_param2)
Binds the second parameter of this function of 2 parameters to return a new
function of 1 parameter. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface info.javelot.functionalj.Function2 |
call |
Function2Impl
public Function2Impl()
bind
public Function1<R,P2> bind(P1 p_param1)
- Description copied from interface:
Function2
- Binds the first parameter of this function of 2 parameters to return a new
function of 1 parameter.
- Specified by:
bind in interface Function2<R,P1,P2>
- Parameters:
p_param1 - the parameter to bind to the first parameter of the function.
- Returns:
- a new function of 1 parameter.
bind
public Function0<R> bind(P1 p_param1,
P2 p_param2)
- Description copied from interface:
Function2
- Binds both parameters of this function of 2 parameters to return a new
function of no parameters.
- Specified by:
bind in interface Function2<R,P1,P2>
- Parameters:
p_param1 - the parameter to bind to the first parameter of the function.p_param2 - the parameter to bind to the second parameter of the function.
- Returns:
- a new function of no parameters.
bind2
public Function1<R,P1> bind2(P2 p_param2)
- Description copied from interface:
Function2
- Binds the second parameter of this function of 2 parameters to return a new
function of 1 parameter.
- Specified by:
bind2 in interface Function2<R,P1,P2>
- Parameters:
p_param2 - the parameter to bind to the second parameter of the function.
- Returns:
- a new function of 1 parameter.