Skip to content

Commit

Permalink
remove drt-case. attempt to make code easier to read. todo: remove co…
Browse files Browse the repository at this point in the history
…mments
  • Loading branch information
tschlenther committed Feb 2, 2024
1 parent a916ea6 commit 9f17787
Show file tree
Hide file tree
Showing 3 changed files with 229 additions and 171 deletions.
14 changes: 5 additions & 9 deletions src/main/java/org/matsim/run/RunLeipzigScenario.java
Original file line number Diff line number Diff line change
Expand Up @@ -99,13 +99,9 @@ public class RunLeipzigScenario extends MATSimApplication {
@CommandLine.Option(names = "--intermodality", defaultValue = "drtAndPtSeparateFromEachOther", description = "Define if drt should be used as access and egress mode for pt.")
private DrtCaseSetup.PtDrtIntermodality ptDrtIntermodality;

public RunLeipzigScenario(@Nullable Config config) {
super(config);
}
public RunLeipzigScenario(@Nullable Config config) { super(config); }

public RunLeipzigScenario() {
super(String.format("input/v%s/leipzig-v%s-10pct.config.xml", VERSION, VERSION));
}
public RunLeipzigScenario() { super(String.format("input/v%s/leipzig-v%s-10pct.config.xml", VERSION, VERSION)); }

public static void main(String[] args) {
MATSimApplication.run(RunLeipzigScenario.class, args);
Expand Down Expand Up @@ -191,7 +187,7 @@ protected Config prepareConfig(Config config) {
if (networkOpt.hasDrtArea()) {
//drt
try {
DrtCaseSetup.prepareConfig(config, drtCase, new ShpOptions(networkOpt.getDrtArea(), null, null));
DrtCaseSetup.prepareConfig(config, /* drtCase, */ new ShpOptions(networkOpt.getDrtArea(), null, null));
} catch (URISyntaxException e) {
log.fatal(e);
}
Expand Down Expand Up @@ -280,7 +276,7 @@ protected void prepareScenario(Scenario scenario) {
// (passt das Netz an aus den mitgegebenen shape files, z.B. parking area, car-free area, ...)

if (networkOpt.hasDrtArea()) {
DrtCaseSetup.prepareScenario(scenario, drtCase, new ShpOptions(networkOpt.getDrtArea(), null, null), VERSION);
DrtCaseSetup.prepareScenario(scenario, /*drtCase, */ new ShpOptions(networkOpt.getDrtArea(), null, null), VERSION);
}

}
Expand Down Expand Up @@ -328,7 +324,7 @@ public void install() {
});

if (networkOpt.hasDrtArea()) {
DrtCaseSetup.prepareControler(controler, drtCase, new ShpOptions(networkOpt.getDrtArea(), null, null), ptDrtIntermodality);
DrtCaseSetup.prepareControler(controler,/* drtCase,*/ new ShpOptions(networkOpt.getDrtArea(), null, null), ptDrtIntermodality);
}

if (bike == BicycleHandling.onNetworkWithBicycleContrib) {
Expand Down
Loading

0 comments on commit 9f17787

Please sign in to comment.