diff --git a/src/main/java/org/matsim/freight/logistics/examples/initialPlans/ExampleSchedulingOfTransportChain.java b/src/main/java/org/matsim/freight/logistics/examples/initialPlans/ExampleSchedulingOfTransportChain.java index a601fee7..139ed25e 100644 --- a/src/main/java/org/matsim/freight/logistics/examples/initialPlans/ExampleSchedulingOfTransportChain.java +++ b/src/main/java/org/matsim/freight/logistics/examples/initialPlans/ExampleSchedulingOfTransportChain.java @@ -149,7 +149,7 @@ private static LSP createInitialLSP(Scenario scenario) { // The adapter i.e. the main run resource is created LSPResource mainRunResource = - ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainRunCarrier, network) + ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainRunCarrier) .setFromLinkId(Id.createLinkId("(4 2) (4 3)")) .setToLinkId(Id.createLinkId("(14 2) (14 3)")) .setMainRunCarrierScheduler(ResourceImplementationUtils.createDefaultMainRunCarrierScheduler(scenario)) diff --git a/src/main/java/org/matsim/freight/logistics/examples/initialPlans/ExampleSchedulingOfTransportChainHubsVsDirect.java b/src/main/java/org/matsim/freight/logistics/examples/initialPlans/ExampleSchedulingOfTransportChainHubsVsDirect.java index cab7575d..74cf3cc4 100644 --- a/src/main/java/org/matsim/freight/logistics/examples/initialPlans/ExampleSchedulingOfTransportChainHubsVsDirect.java +++ b/src/main/java/org/matsim/freight/logistics/examples/initialPlans/ExampleSchedulingOfTransportChainHubsVsDirect.java @@ -263,7 +263,7 @@ private static LSP createInitialLSP(Scenario scenario, SolutionType solutionType // The scheduler for the main run Resource is created and added to the Resource LSPResource mainRunResource = - ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainRunCarrier, network) + ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainRunCarrier) .setFromLinkId(depotLinkId) .setToLinkId(hubLinkId) .setMainRunCarrierScheduler( diff --git a/src/main/java/org/matsim/freight/logistics/examples/initialPlans/ExampleTwoEchelonGrid.java b/src/main/java/org/matsim/freight/logistics/examples/initialPlans/ExampleTwoEchelonGrid.java index 348b5a5f..de65bf2c 100644 --- a/src/main/java/org/matsim/freight/logistics/examples/initialPlans/ExampleTwoEchelonGrid.java +++ b/src/main/java/org/matsim/freight/logistics/examples/initialPlans/ExampleTwoEchelonGrid.java @@ -286,7 +286,7 @@ private static LSP createLSP(Scenario scenario) { CarrierVehicle.newInstance( Id.createVehicleId("mainTruck"), DEPOT_LINK_ID, VEH_TYPE_LARGE_50)); LSPResource mainCarrierRessource = - ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainCarrier, network) + ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainCarrier) .setFromLinkId(DEPOT_LINK_ID) .setMainRunCarrierScheduler( ResourceImplementationUtils.createDefaultMainRunCarrierScheduler(scenario)) diff --git a/src/main/java/org/matsim/freight/logistics/examples/initialPlans/ExampleTwoEchelonGrid_NR.java b/src/main/java/org/matsim/freight/logistics/examples/initialPlans/ExampleTwoEchelonGrid_NR.java index b0578ce0..1f4f3261 100644 --- a/src/main/java/org/matsim/freight/logistics/examples/initialPlans/ExampleTwoEchelonGrid_NR.java +++ b/src/main/java/org/matsim/freight/logistics/examples/initialPlans/ExampleTwoEchelonGrid_NR.java @@ -296,7 +296,7 @@ private static LSP createLSP(Scenario scenario) { CarrierVehicle.newInstance( Id.createVehicleId("mainTruck"), DEPOT_LINK_ID, VEH_TYPE_LARGE_50)); LSPResource mainCarrierRessource = - ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainCarrier, network) + ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainCarrier) .setFromLinkId(DEPOT_LINK_ID) .setMainRunCarrierScheduler( ResourceImplementationUtils.createDefaultMainRunCarrierScheduler(scenario)) diff --git a/src/main/java/org/matsim/freight/logistics/examples/mobsimExamples/ExampleMobsimOfTransportChain.java b/src/main/java/org/matsim/freight/logistics/examples/mobsimExamples/ExampleMobsimOfTransportChain.java index 4b1f08d5..b703c176 100644 --- a/src/main/java/org/matsim/freight/logistics/examples/mobsimExamples/ExampleMobsimOfTransportChain.java +++ b/src/main/java/org/matsim/freight/logistics/examples/mobsimExamples/ExampleMobsimOfTransportChain.java @@ -150,7 +150,7 @@ private static LSP createInitialLSP(Scenario scenario) { // The adapter i.e. the main run resource is created LSPResource mainRunResource = - ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainRunCarrier, network) + ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainRunCarrier) .setFromLinkId(Id.createLinkId("(4 2) (4 3)")) .setToLinkId(Id.createLinkId("(14 2) (14 3)")) .setMainRunCarrierScheduler(ResourceImplementationUtils.createDefaultMainRunCarrierScheduler(scenario)) diff --git a/src/main/java/org/matsim/freight/logistics/examples/multipleChains/ExampleGroceryDeliveryMultipleChains.java b/src/main/java/org/matsim/freight/logistics/examples/multipleChains/ExampleGroceryDeliveryMultipleChains.java index ee01be29..1d42b458 100644 --- a/src/main/java/org/matsim/freight/logistics/examples/multipleChains/ExampleGroceryDeliveryMultipleChains.java +++ b/src/main/java/org/matsim/freight/logistics/examples/multipleChains/ExampleGroceryDeliveryMultipleChains.java @@ -228,7 +228,7 @@ private static LSP createLSP(Scenario scenario) { vehicleTypes.getVehicleTypes().get(Id.create("heavy40t", VehicleType.class)))); LSPResource mainCarrierResource = ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance( - mainCarrier, scenario.getNetwork()) + mainCarrier) .setFromLinkId(depotLinkFromVehicles) .setMainRunCarrierScheduler( ResourceImplementationUtils.createDefaultMainRunCarrierScheduler(scenario)) diff --git a/src/main/java/org/matsim/freight/logistics/examples/multipleChains/ExampleMultipleMixedEchelonChains.java b/src/main/java/org/matsim/freight/logistics/examples/multipleChains/ExampleMultipleMixedEchelonChains.java index 165d45b9..0e18dbcd 100644 --- a/src/main/java/org/matsim/freight/logistics/examples/multipleChains/ExampleMultipleMixedEchelonChains.java +++ b/src/main/java/org/matsim/freight/logistics/examples/multipleChains/ExampleMultipleMixedEchelonChains.java @@ -199,7 +199,7 @@ private static LSP createLSP(Scenario scenario) { Id.createVehicleId("mainTruck"), DEPOT_LINK_ID, VEH_TYPE_LARGE_50)); LSPResource mainCarrierResource1 = ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance( - mainCarrier1, network) + mainCarrier1) .setFromLinkId(DEPOT_LINK_ID) .setMainRunCarrierScheduler( ResourceImplementationUtils.createDefaultMainRunCarrierScheduler(scenario)) @@ -316,7 +316,7 @@ private static LSP createLSP(Scenario scenario) { Id.createVehicleId("mainTruck"), DEPOT_LINK_ID, VEH_TYPE_LARGE_50)); LSPResource mainCarrierResource = ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance( - mainCarrier, network) + mainCarrier) .setFromLinkId(DEPOT_LINK_ID) .setMainRunCarrierScheduler( ResourceImplementationUtils.createDefaultMainRunCarrierScheduler(scenario)) diff --git a/src/main/java/org/matsim/freight/logistics/examples/multipleChains/ExampleMultipleTwoEchelonChainsReplanning.java b/src/main/java/org/matsim/freight/logistics/examples/multipleChains/ExampleMultipleTwoEchelonChainsReplanning.java index 1184bd82..adeca358 100644 --- a/src/main/java/org/matsim/freight/logistics/examples/multipleChains/ExampleMultipleTwoEchelonChainsReplanning.java +++ b/src/main/java/org/matsim/freight/logistics/examples/multipleChains/ExampleMultipleTwoEchelonChainsReplanning.java @@ -203,7 +203,7 @@ private static LSP createLSP(Scenario scenario) { CarrierVehicle.newInstance( Id.createVehicleId("mainTruck"), DEPOT_LINK_ID, VEH_TYPE_LARGE_50)); LSPResource mainCarrierResourceLeft = - ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainCarrierLeft, network) + ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainCarrierLeft) .setFromLinkId(DEPOT_LINK_ID) .setMainRunCarrierScheduler( ResourceImplementationUtils.createDefaultMainRunCarrierScheduler(scenario)) @@ -281,7 +281,7 @@ private static LSP createLSP(Scenario scenario) { CarrierVehicle.newInstance( Id.createVehicleId("mainTruck"), DEPOT_LINK_ID, VEH_TYPE_LARGE_50)); LSPResource mainCarrierResource = - ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainCarrier, network) + ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainCarrier) .setFromLinkId(DEPOT_LINK_ID) .setMainRunCarrierScheduler( ResourceImplementationUtils.createDefaultMainRunCarrierScheduler(scenario)) diff --git a/src/main/java/org/matsim/freight/logistics/examples/multipleChains/ExampleTwoLspsGroceryDeliveryMultipleChains.java b/src/main/java/org/matsim/freight/logistics/examples/multipleChains/ExampleTwoLspsGroceryDeliveryMultipleChains.java index 4c078ffc..03f5a53f 100644 --- a/src/main/java/org/matsim/freight/logistics/examples/multipleChains/ExampleTwoLspsGroceryDeliveryMultipleChains.java +++ b/src/main/java/org/matsim/freight/logistics/examples/multipleChains/ExampleTwoLspsGroceryDeliveryMultipleChains.java @@ -286,7 +286,7 @@ private static LogisticChain createTwoEchelonChain(Scenario scenario, String lsp vehicleTypesMainRun.getVehicleTypes().get(Id.create("heavy40t", VehicleType.class)))); LSPResource mainCarrierResource = ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance( - mainCarrier, scenario.getNetwork()) + mainCarrier) .setFromLinkId(depotLinkFromVehicles) .setMainRunCarrierScheduler( ResourceImplementationUtils.createDefaultMainRunCarrierScheduler(scenario)) diff --git a/src/main/java/org/matsim/freight/logistics/examples/multipleChains/ExampleTwoLspsGroceryDeliveryMultipleChainsWithToll.java b/src/main/java/org/matsim/freight/logistics/examples/multipleChains/ExampleTwoLspsGroceryDeliveryMultipleChainsWithToll.java index ebdaf658..88a1717e 100644 --- a/src/main/java/org/matsim/freight/logistics/examples/multipleChains/ExampleTwoLspsGroceryDeliveryMultipleChainsWithToll.java +++ b/src/main/java/org/matsim/freight/logistics/examples/multipleChains/ExampleTwoLspsGroceryDeliveryMultipleChainsWithToll.java @@ -312,7 +312,7 @@ private static LogisticChain createTwoEchelonChain(Scenario scenario, String lsp vehicleTypesMainRun.getVehicleTypes().get(Id.create("heavy40t", VehicleType.class)))); LSPResource mainCarrierResource = ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance( - mainCarrier, scenario.getNetwork()) + mainCarrier) .setFromLinkId(depotLinkFromVehicles) .setMainRunCarrierScheduler( ResourceImplementationUtils.createDefaultMainRunCarrierScheduler(scenario)) diff --git a/src/main/java/org/matsim/freight/logistics/io/LSPPlanXmlParserV1.java b/src/main/java/org/matsim/freight/logistics/io/LSPPlanXmlParserV1.java index db6726a9..dc898f18 100644 --- a/src/main/java/org/matsim/freight/logistics/io/LSPPlanXmlParserV1.java +++ b/src/main/java/org/matsim/freight/logistics/io/LSPPlanXmlParserV1.java @@ -320,7 +320,7 @@ public void endTag(String name, String content, Stack context) { ResourceImplementationUtils.createDefaultCollectionCarrierScheduler(null)) .build(); case mainRunCarrier -> lspResource = - ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(currentCarrier, null) + ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(currentCarrier) .setMainRunCarrierScheduler( ResourceImplementationUtils.createDefaultMainRunCarrierScheduler(null)) .build(); diff --git a/src/main/java/org/matsim/freight/logistics/resourceImplementations/ResourceImplementationUtils.java b/src/main/java/org/matsim/freight/logistics/resourceImplementations/ResourceImplementationUtils.java index 5d68cbd1..f8da646b 100644 --- a/src/main/java/org/matsim/freight/logistics/resourceImplementations/ResourceImplementationUtils.java +++ b/src/main/java/org/matsim/freight/logistics/resourceImplementations/ResourceImplementationUtils.java @@ -28,7 +28,6 @@ import org.matsim.api.core.v01.Id; import org.matsim.api.core.v01.Scenario; import org.matsim.api.core.v01.network.Link; -import org.matsim.api.core.v01.network.Network; import org.matsim.core.utils.io.IOUtils; import org.matsim.freight.carriers.Carrier; import org.matsim.freight.carriers.CarrierVehicle; @@ -332,23 +331,21 @@ public static class MainRunCarrierResourceBuilder { private final Id id; private final ArrayList clientElements; - private final Network network; private Carrier carrier; private Id fromLinkId; private Id toLinkId; private MainRunCarrierScheduler mainRunScheduler; private VehicleReturn vehicleReturn; - private MainRunCarrierResourceBuilder(Carrier carrier, Network network) { + private MainRunCarrierResourceBuilder(Carrier carrier) { this.id = Id.create(carrier.getId().toString(), LSPResource.class); setCarrierType(carrier, CARRIER_TYPE.mainRunCarrier); this.carrier = carrier; this.clientElements = new ArrayList<>(); - this.network = network; } - public static MainRunCarrierResourceBuilder newInstance(Carrier carrier, Network network) { - return new MainRunCarrierResourceBuilder(carrier, network); + public static MainRunCarrierResourceBuilder newInstance(Carrier carrier) { + return new MainRunCarrierResourceBuilder(carrier); } public MainRunCarrierResourceBuilder setMainRunCarrierScheduler( @@ -403,10 +400,6 @@ MainRunCarrierScheduler getMainRunScheduler() { return mainRunScheduler; } - Network getNetwork() { - return network; - } - VehicleReturn getVehicleReturn() { return vehicleReturn; } diff --git a/src/test/java/org/matsim/freight/logistics/adapterTests/MainRunResourceTest.java b/src/test/java/org/matsim/freight/logistics/adapterTests/MainRunResourceTest.java index 8d9f1c14..5dfe0fce 100644 --- a/src/test/java/org/matsim/freight/logistics/adapterTests/MainRunResourceTest.java +++ b/src/test/java/org/matsim/freight/logistics/adapterTests/MainRunResourceTest.java @@ -82,7 +82,7 @@ public void initialize() { carrier = CarriersUtils.createCarrier(carrierId); carrier.setCarrierCapabilities(capabilities); - mainRunResource = ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(carrier, network) + mainRunResource = ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(carrier) .setMainRunCarrierScheduler(ResourceImplementationUtils.createDefaultMainRunCarrierScheduler(scenario)) .setFromLinkId(Id.createLinkId("(4 2) (4 3)")).setToLinkId(Id.createLinkId("(14 2) (14 3)")) .build(); diff --git a/src/test/java/org/matsim/freight/logistics/logisticChainElementTests/MainRunElementTest.java b/src/test/java/org/matsim/freight/logistics/logisticChainElementTests/MainRunElementTest.java index d1f2a7c3..5a7fe385 100644 --- a/src/test/java/org/matsim/freight/logistics/logisticChainElementTests/MainRunElementTest.java +++ b/src/test/java/org/matsim/freight/logistics/logisticChainElementTests/MainRunElementTest.java @@ -78,7 +78,7 @@ public void initialize() { Carrier mainRunCarrierResourceBuilder = CarriersUtils.createCarrier(carrierId); mainRunCarrierResourceBuilder.setCarrierCapabilities(capabilities); - mainRunResource = ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainRunCarrierResourceBuilder, network) + mainRunResource = ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainRunCarrierResourceBuilder) .setMainRunCarrierScheduler(ResourceImplementationUtils.createDefaultMainRunCarrierScheduler(scenario)) .setFromLinkId(Id.createLinkId("(4 2) (4 3)")) .setToLinkId(Id.createLinkId("(14 2) (14 3)")) diff --git a/src/test/java/org/matsim/freight/logistics/logisticChainTests/CompleteLogisticChainTest.java b/src/test/java/org/matsim/freight/logistics/logisticChainTests/CompleteLogisticChainTest.java index 752712cd..13afaa97 100644 --- a/src/test/java/org/matsim/freight/logistics/logisticChainTests/CompleteLogisticChainTest.java +++ b/src/test/java/org/matsim/freight/logistics/logisticChainTests/CompleteLogisticChainTest.java @@ -134,7 +134,7 @@ public void initialize() { Carrier mainRunCarrier = CarriersUtils.createCarrier(collectionCarrierId); mainRunCarrier.setCarrierCapabilities(mainRunCapabilities); - LSPResource mainRunResource = ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainRunCarrier, network) + LSPResource mainRunResource = ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainRunCarrier) .setMainRunCarrierScheduler(ResourceImplementationUtils.createDefaultMainRunCarrierScheduler(scenario)) .setFromLinkId(Id.createLinkId("(4 2) (4 3)")) .setToLinkId(Id.createLinkId("(14 2) (14 3)")) diff --git a/src/test/java/org/matsim/freight/logistics/lspCreationTests/CompleteLSPCreationTest.java b/src/test/java/org/matsim/freight/logistics/lspCreationTests/CompleteLSPCreationTest.java index 2a591b4e..1a8600d6 100644 --- a/src/test/java/org/matsim/freight/logistics/lspCreationTests/CompleteLSPCreationTest.java +++ b/src/test/java/org/matsim/freight/logistics/lspCreationTests/CompleteLSPCreationTest.java @@ -127,7 +127,7 @@ public void initialize() { mainRunCarrier.setCarrierCapabilities(mainRunCapabilities); - LSPResource mainRunResource = ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainRunCarrier, network) + LSPResource mainRunResource = ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainRunCarrier) .setMainRunCarrierScheduler(ResourceImplementationUtils.createDefaultMainRunCarrierScheduler(scenario)) .setFromLinkId(Id.createLinkId("(4 2) (4 3)")) .setToLinkId(Id.createLinkId("(14 2) (14 3)")) diff --git a/src/test/java/org/matsim/freight/logistics/lspMobsimTests/CompleteLSPMobsimTest.java b/src/test/java/org/matsim/freight/logistics/lspMobsimTests/CompleteLSPMobsimTest.java index ab7d6927..8276d02f 100644 --- a/src/test/java/org/matsim/freight/logistics/lspMobsimTests/CompleteLSPMobsimTest.java +++ b/src/test/java/org/matsim/freight/logistics/lspMobsimTests/CompleteLSPMobsimTest.java @@ -143,7 +143,7 @@ public void initialize() { mainRunCarrier.setCarrierCapabilities(mainRunCapabilities); - LSPResource mainRunResource = ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainRunCarrier, network) + LSPResource mainRunResource = ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainRunCarrier) .setMainRunCarrierScheduler(ResourceImplementationUtils.createDefaultMainRunCarrierScheduler(scenario)) .setFromLinkId(Id.createLinkId("(4 2) (4 3)")) .setToLinkId(Id.createLinkId("(14 2) (14 3)")) diff --git a/src/test/java/org/matsim/freight/logistics/lspMobsimTests/FirstAndSecondReloadLSPMobsimTest.java b/src/test/java/org/matsim/freight/logistics/lspMobsimTests/FirstAndSecondReloadLSPMobsimTest.java index 13f7eaf4..72a085ec 100644 --- a/src/test/java/org/matsim/freight/logistics/lspMobsimTests/FirstAndSecondReloadLSPMobsimTest.java +++ b/src/test/java/org/matsim/freight/logistics/lspMobsimTests/FirstAndSecondReloadLSPMobsimTest.java @@ -149,7 +149,7 @@ public void initialize() { mainRunCarrier.setCarrierCapabilities(mainRunCapabilities); - LSPResource mainRunResource = ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainRunCarrier, network) + LSPResource mainRunResource = ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainRunCarrier) .setMainRunCarrierScheduler(ResourceImplementationUtils.createDefaultMainRunCarrierScheduler(scenario)) .setFromLinkId(Id.createLinkId("(4 2) (4 3)")) .setToLinkId(Id.createLinkId("(14 2) (14 3)")) diff --git a/src/test/java/org/matsim/freight/logistics/lspMobsimTests/MainRunLSPMobsimTest.java b/src/test/java/org/matsim/freight/logistics/lspMobsimTests/MainRunLSPMobsimTest.java index ef553ae6..e7657713 100644 --- a/src/test/java/org/matsim/freight/logistics/lspMobsimTests/MainRunLSPMobsimTest.java +++ b/src/test/java/org/matsim/freight/logistics/lspMobsimTests/MainRunLSPMobsimTest.java @@ -147,7 +147,7 @@ public void initialize() { mainRunCarrier.setCarrierCapabilities(mainRunCapabilities); - LSPResource mainRunResource = ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainRunCarrier, network) + LSPResource mainRunResource = ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainRunCarrier) .setMainRunCarrierScheduler(ResourceImplementationUtils.createDefaultMainRunCarrierScheduler(scenario)) .setFromLinkId(Id.createLinkId("(4 2) (4 3)")) .setToLinkId(Id.createLinkId("(14 2) (14 3)")) diff --git a/src/test/java/org/matsim/freight/logistics/lspMobsimTests/MainRunOnlyLSPMobsimTest.java b/src/test/java/org/matsim/freight/logistics/lspMobsimTests/MainRunOnlyLSPMobsimTest.java index 43a9e80d..6d9704f7 100644 --- a/src/test/java/org/matsim/freight/logistics/lspMobsimTests/MainRunOnlyLSPMobsimTest.java +++ b/src/test/java/org/matsim/freight/logistics/lspMobsimTests/MainRunOnlyLSPMobsimTest.java @@ -97,7 +97,7 @@ public void initialize() { mainRunCarrier.setCarrierCapabilities(mainRunCapabilities); - LSPResource mainRunResource = ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainRunCarrier, network) + LSPResource mainRunResource = ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainRunCarrier) .setMainRunCarrierScheduler(ResourceImplementationUtils.createDefaultMainRunCarrierScheduler(scenario)) .setFromLinkId(Id.createLinkId("(4 2) (4 3)")) .setToLinkId(Id.createLinkId("(14 2) (14 3)")) diff --git a/src/test/java/org/matsim/freight/logistics/lspMobsimTests/MultipleIterationsCompleteLSPMobsimTest.java b/src/test/java/org/matsim/freight/logistics/lspMobsimTests/MultipleIterationsCompleteLSPMobsimTest.java index b16e8ab3..6ef78b8b 100644 --- a/src/test/java/org/matsim/freight/logistics/lspMobsimTests/MultipleIterationsCompleteLSPMobsimTest.java +++ b/src/test/java/org/matsim/freight/logistics/lspMobsimTests/MultipleIterationsCompleteLSPMobsimTest.java @@ -154,7 +154,7 @@ public void initialize() { mainRunCarrier.setCarrierCapabilities(mainRunCapabilities); - LSPResource mainRunResource = ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainRunCarrier, network) + LSPResource mainRunResource = ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainRunCarrier) .setMainRunCarrierScheduler(ResourceImplementationUtils.createDefaultMainRunCarrierScheduler(scenario)) .setFromLinkId(Id.createLinkId("(4 2) (4 3)")) .setToLinkId(Id.createLinkId("(14 2) (14 3)")) diff --git a/src/test/java/org/matsim/freight/logistics/lspMobsimTests/MultipleIterationsFirstAndSecondReloadLSPMobsimTest.java b/src/test/java/org/matsim/freight/logistics/lspMobsimTests/MultipleIterationsFirstAndSecondReloadLSPMobsimTest.java index 8e5ffa19..e2e7f500 100644 --- a/src/test/java/org/matsim/freight/logistics/lspMobsimTests/MultipleIterationsFirstAndSecondReloadLSPMobsimTest.java +++ b/src/test/java/org/matsim/freight/logistics/lspMobsimTests/MultipleIterationsFirstAndSecondReloadLSPMobsimTest.java @@ -155,7 +155,7 @@ public void initialize() { mainRunCarrier.setCarrierCapabilities(mainRunCapabilities); - LSPResource mainRunResource = ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainRunCarrier, network) + LSPResource mainRunResource = ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainRunCarrier) .setMainRunCarrierScheduler(ResourceImplementationUtils.createDefaultMainRunCarrierScheduler(scenario)) .setFromLinkId(Id.createLinkId("(4 2) (4 3)")) .setToLinkId(Id.createLinkId("(14 2) (14 3)")) diff --git a/src/test/java/org/matsim/freight/logistics/lspMobsimTests/MultipleIterationsMainRunLSPMobsimTest.java b/src/test/java/org/matsim/freight/logistics/lspMobsimTests/MultipleIterationsMainRunLSPMobsimTest.java index 27764a2c..6ca4a9cb 100644 --- a/src/test/java/org/matsim/freight/logistics/lspMobsimTests/MultipleIterationsMainRunLSPMobsimTest.java +++ b/src/test/java/org/matsim/freight/logistics/lspMobsimTests/MultipleIterationsMainRunLSPMobsimTest.java @@ -154,7 +154,7 @@ public void initialize() { mainRunCarrier.setCarrierCapabilities(mainRunCapabilities); - LSPResource mainRunResource = ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainRunCarrier, network) + LSPResource mainRunResource = ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainRunCarrier) .setMainRunCarrierScheduler(ResourceImplementationUtils.createDefaultMainRunCarrierScheduler(scenario)) .setFromLinkId(Id.createLinkId("(4 2) (4 3)")) .setToLinkId(Id.createLinkId("(14 2) (14 3)")) diff --git a/src/test/java/org/matsim/freight/logistics/lspMobsimTests/MultipleShipmentsCompleteLSPMobsimTest.java b/src/test/java/org/matsim/freight/logistics/lspMobsimTests/MultipleShipmentsCompleteLSPMobsimTest.java index e5a76923..98d133aa 100644 --- a/src/test/java/org/matsim/freight/logistics/lspMobsimTests/MultipleShipmentsCompleteLSPMobsimTest.java +++ b/src/test/java/org/matsim/freight/logistics/lspMobsimTests/MultipleShipmentsCompleteLSPMobsimTest.java @@ -157,7 +157,7 @@ public void initialize() { mainRunCarrier.setCarrierCapabilities(mainRunCapabilities); - LSPResource mainRunResource = ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainRunCarrier, network) + LSPResource mainRunResource = ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainRunCarrier) .setMainRunCarrierScheduler(ResourceImplementationUtils.createDefaultMainRunCarrierScheduler(scenario)) .setFromLinkId(Id.createLinkId("(4 2) (4 3)")) .setToLinkId(Id.createLinkId("(14 2) (14 3)")) diff --git a/src/test/java/org/matsim/freight/logistics/lspMobsimTests/MultipleShipmentsFirstAndSecondReloadLSPMobsimTest.java b/src/test/java/org/matsim/freight/logistics/lspMobsimTests/MultipleShipmentsFirstAndSecondReloadLSPMobsimTest.java index 374fae8e..fc0dc5c1 100644 --- a/src/test/java/org/matsim/freight/logistics/lspMobsimTests/MultipleShipmentsFirstAndSecondReloadLSPMobsimTest.java +++ b/src/test/java/org/matsim/freight/logistics/lspMobsimTests/MultipleShipmentsFirstAndSecondReloadLSPMobsimTest.java @@ -154,7 +154,7 @@ public void initialize() { mainRunCarrier.setCarrierCapabilities(mainRunCapabilities); - LSPResource mainRunResource = ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainRunCarrier, network) + LSPResource mainRunResource = ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainRunCarrier) .setMainRunCarrierScheduler(ResourceImplementationUtils.createDefaultMainRunCarrierScheduler(scenario)) .setFromLinkId(Id.createLinkId("(4 2) (4 3)")) .setToLinkId(Id.createLinkId("(14 2) (14 3)")) diff --git a/src/test/java/org/matsim/freight/logistics/lspMobsimTests/MultipleShipmentsMainRunLSPMobsimTest.java b/src/test/java/org/matsim/freight/logistics/lspMobsimTests/MultipleShipmentsMainRunLSPMobsimTest.java index 8eebf67e..8846bdad 100644 --- a/src/test/java/org/matsim/freight/logistics/lspMobsimTests/MultipleShipmentsMainRunLSPMobsimTest.java +++ b/src/test/java/org/matsim/freight/logistics/lspMobsimTests/MultipleShipmentsMainRunLSPMobsimTest.java @@ -148,7 +148,7 @@ public void initialize() { mainRunCarrier.setCarrierCapabilities(mainRunCapabilities); - LSPResource mainRunResource = ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainRunCarrier, network) + LSPResource mainRunResource = ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainRunCarrier) .setMainRunCarrierScheduler(ResourceImplementationUtils.createDefaultMainRunCarrierScheduler(scenario)) .setFromLinkId(Id.createLinkId("(4 2) (4 3)")) .setToLinkId(Id.createLinkId("(14 2) (14 3)")) diff --git a/src/test/java/org/matsim/freight/logistics/lspMobsimTests/RepeatedMultipleShipmentsCompleteLSPMobsimTest.java b/src/test/java/org/matsim/freight/logistics/lspMobsimTests/RepeatedMultipleShipmentsCompleteLSPMobsimTest.java index 30b10ac5..2229d579 100644 --- a/src/test/java/org/matsim/freight/logistics/lspMobsimTests/RepeatedMultipleShipmentsCompleteLSPMobsimTest.java +++ b/src/test/java/org/matsim/freight/logistics/lspMobsimTests/RepeatedMultipleShipmentsCompleteLSPMobsimTest.java @@ -149,7 +149,7 @@ public void initialize() { mainRunCarrier.setCarrierCapabilities(mainRunCapabilities); - LSPResource mainRunResource = ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainRunCarrier, network) + LSPResource mainRunResource = ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainRunCarrier) .setMainRunCarrierScheduler(ResourceImplementationUtils.createDefaultMainRunCarrierScheduler(scenario)) .setFromLinkId(Id.createLinkId("(4 2) (4 3)")) .setToLinkId(Id.createLinkId("(14 2) (14 3)")) diff --git a/src/test/java/org/matsim/freight/logistics/lspPlanTests/CompleteLSPPlanTest.java b/src/test/java/org/matsim/freight/logistics/lspPlanTests/CompleteLSPPlanTest.java index d9a7faee..3efe8d0f 100644 --- a/src/test/java/org/matsim/freight/logistics/lspPlanTests/CompleteLSPPlanTest.java +++ b/src/test/java/org/matsim/freight/logistics/lspPlanTests/CompleteLSPPlanTest.java @@ -128,7 +128,7 @@ public void initialize() { mainRunCarrier.setCarrierCapabilities(mainRunCapabilities); - LSPResource mainRunResource = ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainRunCarrier, network) + LSPResource mainRunResource = ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainRunCarrier) .setMainRunCarrierScheduler(ResourceImplementationUtils.createDefaultMainRunCarrierScheduler(scenario)) .setFromLinkId(Id.createLinkId("(4 2) (4 3)")) .setToLinkId(Id.createLinkId("(14 2) (14 3)")) diff --git a/src/test/java/org/matsim/freight/logistics/lspShipmentAssignmentTests/CompleteLSPShipmentAssignerTest.java b/src/test/java/org/matsim/freight/logistics/lspShipmentAssignmentTests/CompleteLSPShipmentAssignerTest.java index 65e1c095..ca924374 100644 --- a/src/test/java/org/matsim/freight/logistics/lspShipmentAssignmentTests/CompleteLSPShipmentAssignerTest.java +++ b/src/test/java/org/matsim/freight/logistics/lspShipmentAssignmentTests/CompleteLSPShipmentAssignerTest.java @@ -132,7 +132,7 @@ public void initialize() { mainRunCarrier.setCarrierCapabilities(mainRunCapabilities); - LSPResource mainRunResource = ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainRunCarrier, network) + LSPResource mainRunResource = ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainRunCarrier) .setMainRunCarrierScheduler(ResourceImplementationUtils.createDefaultMainRunCarrierScheduler(scenario)) .setFromLinkId(Id.createLinkId("(4 2) (4 3)")) .setToLinkId(Id.createLinkId("(14 2) (14 3)")) diff --git a/src/test/java/org/matsim/freight/logistics/resourceImplementations/CompleteLSPSchedulingTest.java b/src/test/java/org/matsim/freight/logistics/resourceImplementations/CompleteLSPSchedulingTest.java index f971ff90..b50e4bb5 100644 --- a/src/test/java/org/matsim/freight/logistics/resourceImplementations/CompleteLSPSchedulingTest.java +++ b/src/test/java/org/matsim/freight/logistics/resourceImplementations/CompleteLSPSchedulingTest.java @@ -144,7 +144,7 @@ public void initialize() { Carrier mainRunCarrier = CarriersUtils.createCarrier(mainRunCarrierId); mainRunCarrier.setCarrierCapabilities(mainRunCapabilities); - mainRunResource = ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainRunCarrier, network) + mainRunResource = ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainRunCarrier) .setMainRunCarrierScheduler(ResourceImplementationUtils.createDefaultMainRunCarrierScheduler(scenario)) .setFromLinkId(fromLinkId) .setToLinkId(toLinkId) diff --git a/src/test/java/org/matsim/freight/logistics/resourceImplementations/MainRunLSPSchedulingTest.java b/src/test/java/org/matsim/freight/logistics/resourceImplementations/MainRunLSPSchedulingTest.java index 3b923b04..60d727c0 100644 --- a/src/test/java/org/matsim/freight/logistics/resourceImplementations/MainRunLSPSchedulingTest.java +++ b/src/test/java/org/matsim/freight/logistics/resourceImplementations/MainRunLSPSchedulingTest.java @@ -136,7 +136,7 @@ public void initialize() { Carrier mainRunCarrier = CarriersUtils.createCarrier(mainRunCarrierId); mainRunCarrier.setCarrierCapabilities(mainRunCapabilities); - mainRunResource = ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainRunCarrier, network) + mainRunResource = ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainRunCarrier) .setMainRunCarrierScheduler(ResourceImplementationUtils.createDefaultMainRunCarrierScheduler(scenario)) .setFromLinkId(fromLinkId) .setToLinkId(toLinkId) diff --git a/src/test/java/org/matsim/freight/logistics/resourceImplementations/MultipleShipmentsCompleteLSPSchedulingTest.java b/src/test/java/org/matsim/freight/logistics/resourceImplementations/MultipleShipmentsCompleteLSPSchedulingTest.java index 9110578a..5d175cc0 100644 --- a/src/test/java/org/matsim/freight/logistics/resourceImplementations/MultipleShipmentsCompleteLSPSchedulingTest.java +++ b/src/test/java/org/matsim/freight/logistics/resourceImplementations/MultipleShipmentsCompleteLSPSchedulingTest.java @@ -146,7 +146,7 @@ public void initialize() { mainRunCarrier.setCarrierCapabilities(mainRunCapabilities); - mainRunResource = ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainRunCarrier, network) + mainRunResource = ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainRunCarrier) .setMainRunCarrierScheduler(ResourceImplementationUtils.createDefaultMainRunCarrierScheduler(scenario)) .setFromLinkId(fromLinkId) .setToLinkId(toLinkId) diff --git a/src/test/java/org/matsim/freight/logistics/resourceImplementations/MultipleShipmentsMainRunLSPSchedulingTest.java b/src/test/java/org/matsim/freight/logistics/resourceImplementations/MultipleShipmentsMainRunLSPSchedulingTest.java index 6b1da45e..5c37fec9 100644 --- a/src/test/java/org/matsim/freight/logistics/resourceImplementations/MultipleShipmentsMainRunLSPSchedulingTest.java +++ b/src/test/java/org/matsim/freight/logistics/resourceImplementations/MultipleShipmentsMainRunLSPSchedulingTest.java @@ -136,7 +136,7 @@ public void initialize() { Carrier mainRunCarrier = CarriersUtils.createCarrier(mainRunCarrierId); mainRunCarrier.setCarrierCapabilities(mainRunCapabilities); - mainRunResource = ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainRunCarrier, network) + mainRunResource = ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainRunCarrier) .setMainRunCarrierScheduler(ResourceImplementationUtils.createDefaultMainRunCarrierScheduler(scenario)) .setFromLinkId(fromLinkId) .setToLinkId(toLinkId) diff --git a/src/test/java/org/matsim/freight/logistics/resourceImplementations/MultipleShipmentsSecondReloadLSPSchedulingTest.java b/src/test/java/org/matsim/freight/logistics/resourceImplementations/MultipleShipmentsSecondReloadLSPSchedulingTest.java index 1b4fc2ad..77313d8f 100644 --- a/src/test/java/org/matsim/freight/logistics/resourceImplementations/MultipleShipmentsSecondReloadLSPSchedulingTest.java +++ b/src/test/java/org/matsim/freight/logistics/resourceImplementations/MultipleShipmentsSecondReloadLSPSchedulingTest.java @@ -144,7 +144,7 @@ public void initialize() { mainRunCarrier.setCarrierCapabilities(mainRunCapabilities); - mainRunResource = ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainRunCarrier, network) + mainRunResource = ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainRunCarrier) .setMainRunCarrierScheduler(ResourceImplementationUtils.createDefaultMainRunCarrierScheduler(scenario)) .setFromLinkId(fromLinkId) .setToLinkId(Id.createLinkId(toLinkId)) diff --git a/src/test/java/org/matsim/freight/logistics/resourceImplementations/SecondReloadLSPSchedulingTest.java b/src/test/java/org/matsim/freight/logistics/resourceImplementations/SecondReloadLSPSchedulingTest.java index f4a25f47..2deeac37 100644 --- a/src/test/java/org/matsim/freight/logistics/resourceImplementations/SecondReloadLSPSchedulingTest.java +++ b/src/test/java/org/matsim/freight/logistics/resourceImplementations/SecondReloadLSPSchedulingTest.java @@ -144,7 +144,7 @@ public void initialize() { mainRunCarrier.setCarrierCapabilities(mainRunCapabilities); - mainRunResource = ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainRunCarrier, network) + mainRunResource = ResourceImplementationUtils.MainRunCarrierResourceBuilder.newInstance(mainRunCarrier) .setMainRunCarrierScheduler(ResourceImplementationUtils.createDefaultMainRunCarrierScheduler(scenario)) .setFromLinkId(fromLinkId) .setToLinkId(Id.createLinkId(toLinkId))