|
MATSIM
|
Classes | |
| class | MySpecialRoute |
Static Public Member Functions | |
| static void | main (String[] args) |
This is is an example, taken from Thibaut, of how to set an additional route factory before the controler has started.
This will generate the route, with start and end link id. It will also set distance and travel time if they are in the file. This is sufficient information for teleportation. Additional information needs to come from elsewhere, or the corresponding MatsimReader needs to be modified.
Note, however, that for pure teleportation it is not necessary to set the route factory since the default RouteFactories will already generate an instance of GenericRoute when a mode is not registered.
Definition at line 52 of file RunReadNonstandardRoutesExample.java.
|
static |
Definition at line 54 of file RunReadNonstandardRoutesExample.java.
References org.matsim.core.config.ConfigUtils.createConfig(), org.matsim.core.scenario.ScenarioUtils.createScenario(), org.matsim.api.core.v01.population.Population.getFactory(), org.matsim.api.core.v01.Scenario.getPopulation(), org.matsim.core.scenario.ScenarioUtils.loadScenario(), org.matsim.core.controler.Controler.run(), and org.matsim.core.population.routes.RouteFactories.setRouteFactory().

1.8.8