Package nz.org.riskscape.engine.model
Interface ModelFramework
- All Superinterfaces:
Identified
Defines a framework for building models, e.g. built from a model template vs built via a wizard. Frameworks provide a consistent way of producing models that are also flexible (in that they support parameters that let the user customize the model to suit their needs).
-
Method Summary
Modifier and TypeMethodDescriptionbuild
(Project project, BoundParameters values) Constructs a new model based on the given parameters.Returns a set of parameters that are used to initially build the model, e.g.Methods inherited from interface nz.org.riskscape.engine.Identified
getId, getIdentifiedClass
-
Method Details
-
getBuildParameterSet
ParameterSet getBuildParameterSet()Returns a set of parameters that are used to initially build the model, e.g. "template = default". These are fixed, in that once they are specified they cannot be overridden later.
-
build
Constructs a new model based on the given parameters. Note that any unbound parameters that aren't picked up by the framework's parameters (
getBuildParameterSet()
will be bound against the resulting model's parameter set (Model.getBoundParameters()
)- Returns:
- the model built, or a list of problems that prevented it being built.
-