Package nz.org.riskscape.engine.function
Class BinaryFunction<T,U>
java.lang.Object
nz.org.riskscape.engine.function.BinaryFunction<T,U>
- All Implemented Interfaces:
AutoCloseable,RiskscapeFunction,UntypedFunction
-
Field Summary
Fields inherited from interface nz.org.riskscape.engine.function.RiskscapeFunction
BUILT_IN, LOG -
Constructor Summary
ConstructorsConstructorDescriptionBinaryFunction(Class<T> lhsJavaType, Class<U> rhsJavaType, Type returnType, BiFunction<T, U, Object> function) BinaryFunction(FunctionArgument lhs, FunctionArgument rhs, Type returnType, BiFunction<T, U, Object> function) BinaryFunction(Type lhs, Type rhs, Type returnType, BiFunction<T, U, Object> function) -
Method Summary
Modifier and TypeMethodDescriptionExecute the function with the given arguments.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface nz.org.riskscape.engine.function.RiskscapeFunction
builtin, close, getAggregationFunction, getOverloaded, getRealizable, getTypesFromArguments, identified, identified, isA, setProblemReporter, validate
-
Constructor Details
-
BinaryFunction
public BinaryFunction(FunctionArgument lhs, FunctionArgument rhs, Type returnType, BiFunction<T, U, Object> function) -
BinaryFunction
-
BinaryFunction
-
-
Method Details
-
call
Description copied from interface:UntypedFunctionExecute the function with the given arguments.
- Specified by:
callin interfaceUntypedFunction- Parameters:
args- list of arguments to the function that should conform to the types inArgumentList.getArgumentTypes()
-
getReturnType
- Specified by:
getReturnTypein interfaceRiskscapeFunction- Returns:
- the type that this function should return
-
getArguments
- Specified by:
getArgumentsin interfaceRiskscapeFunction
-
getArgumentTypes
- Specified by:
getArgumentTypesin interfaceRiskscapeFunction- Returns:
- the types that this function expects
-