Package org.tensorics.core.functional
Interface Func2<T1,T2,R>
-
- Type Parameters:
T1
- the first argument typeT2
- the second argument typeR
- the result type
- All Superinterfaces:
FiniteArgumentFunction<R>
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
@FunctionalInterface public interface Func2<T1,T2,R> extends FiniteArgumentFunction<R>
Represents a function with two arguments.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description R
apply(T1 t1, T2 t2)
default int
numberOfArgs()
The number of arguments that the function acceptsdefault FuncN<R>
toFuncN()
Transform this function to aFuncN
, binding the arguments automatically.
-
-
-
Method Detail
-
toFuncN
default FuncN<R> toFuncN()
Description copied from interface:FiniteArgumentFunction
Transform this function to aFuncN
, binding the arguments automatically.- Specified by:
toFuncN
in interfaceFiniteArgumentFunction<T1>
- Returns:
- the
FuncN
representation of this function
-
numberOfArgs
default int numberOfArgs()
Description copied from interface:FiniteArgumentFunction
The number of arguments that the function accepts- Specified by:
numberOfArgs
in interfaceFiniteArgumentFunction<T1>
- Returns:
- the number of arguments
-
-