faq 100171809 - matsim-org/matsim-code-examples GitHub Wiki
by Kai Nagel on 2016-12-11 09:45:12
by Kai Nagel on 2016-12-11 09:51:56
Typically, there is some syntax of type
controler.addOverridingModule(new XxxModule()) ;
Then what you can do is
- make a local copy of
RunXxxExample.java
, say toMyRunXxxExample.java
- make a local copy of
XxxModule.java
, say toMyXxxModule.java
, -
replace, in
MyRunXxxExample
, the above overridingModule line tocontroler.addOverridingModule(new MyXxxModule());
- And finally adapt
MyXxxModule
to your needs.
In that sense, the pre-existing {{XxxModule}} classes are default versions that typically allow configuration from the config file. And the RunXxxExample
classes are default executables around those default modules.
The most extreme case is ControlerDefaultsModule
, made executable by the Controler
class.