Package repast.simphony.scenario
Class ScenarioCreator
java.lang.Object
repast.simphony.scenario.ScenarioCreator
Creates a scenario.xml file.
- Version:
- $Revision$ $Date$
- Author:
- Nick Collier
-
Constructor Summary
ConstructorsConstructorDescriptionScenarioCreator(File modelPath, File scenarioPath) Creates a ScenarioCreator that will create a scenario.xml in the specified scenario path, copying a model.score file from the model path.ScenarioCreator(File modelPath, File scenarioPath, boolean useModelPlugin) Creates a ScenarioCreator that will create a scenario.xml in the specified scenario path, copying a model.score file from the model path and using the specified modelInitializer.ScenarioCreator(File modelPath, File scenarioPath, String modelInitializerClass) Creates a ScenarioCreator that will create a scenario.xml in the specified scenario path, copying a model.score file from the model path and using the specified modelInitializer.ScenarioCreator(File modelPath, File scenarioPath, String modelInitializerClass, boolean useModelPlugin) Creates a ScenarioCreator that will create a scenario.xml in the specified scenario path, copying a model.score file from the model path and using the specified modelInitializer. -
Method Summary
Modifier and TypeMethodDescriptionvoidaddExtension(ScenarioCreatorExtension extension) Adds the specified ScenarioCreatorPlugin that will be run during scenario creation.voidCreate the scenario.static voidregisterExtension(ScenarioCreatorExtension extension) Statically register a strategy.
-
Constructor Details
-
ScenarioCreator
Creates a ScenarioCreator that will create a scenario.xml in the specified scenario path, copying a model.score file from the model path.- Parameters:
modelPath-scenarioPath-
-
ScenarioCreator
Creates a ScenarioCreator that will create a scenario.xml in the specified scenario path, copying a model.score file from the model path and using the specified modelInitializer.- Parameters:
modelPath-scenarioPath-modelInitializerClass-
-
ScenarioCreator
Creates a ScenarioCreator that will create a scenario.xml in the specified scenario path, copying a model.score file from the model path and using the specified modelInitializer.- Parameters:
modelPath-scenarioPath-useModelPlugin- if true, a model plugin entry is added to the scenario.xml file.
-
ScenarioCreator
public ScenarioCreator(File modelPath, File scenarioPath, String modelInitializerClass, boolean useModelPlugin) Creates a ScenarioCreator that will create a scenario.xml in the specified scenario path, copying a model.score file from the model path and using the specified modelInitializer.- Parameters:
modelPath-scenarioPath-modelInitializerClass-useModelPlugin- if true, a model plugin entry is added to the scenario.xml file.
-
-
Method Details
-
registerExtension
Statically register a strategy. The strategy will be added to any instance of a ScenarioCreator when it is created.- Parameters:
extension- the strategy to register.
-
addExtension
Adds the specified ScenarioCreatorPlugin that will be run during scenario creation.- Parameters:
extension-
-
createScenario
Create the scenario.- Throws:
Exceptionorg.apache.velocity.exception.ParseErrorException
-