Package nz.org.riskscape.engine.rl
Class MapStruct
java.lang.Object
nz.org.riskscape.engine.function.BaseRealizableFunction
nz.org.riskscape.engine.rl.MapStruct
- All Implemented Interfaces:
nz.org.riskscape.engine.rl.agg.AggregationFunction,nz.org.riskscape.engine.rl.RealizableFunction
public class MapStruct
extends BaseRealizableFunction
implements nz.org.riskscape.engine.rl.agg.AggregationFunction
-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from interface nz.org.riskscape.engine.rl.RealizableFunction
nz.org.riskscape.engine.rl.RealizableFunction.MetadataIdentifiedRealizableFunction -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final nz.org.riskscape.engine.function.ArgumentListstatic final MapStruct.LocalProblemsFields inherited from class nz.org.riskscape.engine.function.BaseRealizableFunction
arguments, returnType -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionnz.org.riskscape.engine.function.RiskscapeFunctionnz.org.riskscape.problem.ResultOrProblems<nz.org.riskscape.engine.rl.agg.RealizedAggregateExpression>realize(nz.org.riskscape.engine.rl.RealizationContext context, nz.org.riskscape.engine.types.Type inputType, nz.org.riskscape.rl.ast.FunctionCall fc) nz.org.riskscape.problem.ResultOrProblems<nz.org.riskscape.engine.function.RiskscapeFunction>realize(nz.org.riskscape.engine.rl.RealizationContext context, nz.org.riskscape.rl.ast.FunctionCall functionCall, List<nz.org.riskscape.engine.types.Type> givenTypes) Implements some basic boilerplate error checks by default.Methods inherited from class nz.org.riskscape.engine.function.BaseRealizableFunction
build, buildFunction, builtin, getArguments, getReturnType, identifiedMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface nz.org.riskscape.engine.rl.agg.AggregationFunction
getArguments, getReturnTypeMethods inherited from interface nz.org.riskscape.engine.rl.RealizableFunction
isDoTypeAdaptation
-
Field Details
-
PROBLEMS
-
ARGUMENTS
public static final nz.org.riskscape.engine.function.ArgumentList ARGUMENTS
-
-
Constructor Details
-
MapStruct
public MapStruct()
-
-
Method Details
-
realize
public nz.org.riskscape.problem.ResultOrProblems<nz.org.riskscape.engine.function.RiskscapeFunction> realize(nz.org.riskscape.engine.rl.RealizationContext context, nz.org.riskscape.rl.ast.FunctionCall functionCall, List<nz.org.riskscape.engine.types.Type> givenTypes) Description copied from class:BaseRealizableFunctionImplements some basic boilerplate error checks by default. This allows simple realizable functions to just define the
BaseRealizableFunction.build(RealizationContext, FunctionCall, List)guts of the function. More complicated realizable functions (i.e. with non-trivial type handling) may want to override this completely.- Specified by:
realizein interfacenz.org.riskscape.engine.rl.RealizableFunction- Overrides:
realizein classBaseRealizableFunction
-
asFunction
public nz.org.riskscape.engine.function.RiskscapeFunction asFunction()- Overrides:
asFunctionin classBaseRealizableFunction- Returns:
- a
RiskscapeFunctionthat wraps thisRealizableFunction. Note that I haven't made this class implementsRiskscapeFunctiondirectly as the plan is to re-arrange these classes so that all functions become realizable but are not riskscape functions themselves (until they are realized).
-
realize
public nz.org.riskscape.problem.ResultOrProblems<nz.org.riskscape.engine.rl.agg.RealizedAggregateExpression> realize(nz.org.riskscape.engine.rl.RealizationContext context, nz.org.riskscape.engine.types.Type inputType, nz.org.riskscape.rl.ast.FunctionCall fc) - Specified by:
realizein interfacenz.org.riskscape.engine.rl.agg.AggregationFunction
-