1
0
Fork 0
mirror of https://github.com/graphhopper/jsprit.git synced 2020-01-24 07:45:05 +01:00

adjusted examples to multiple cap dims

This commit is contained in:
oblonski 2014-03-04 12:18:37 +01:00
parent 794ce90e6a
commit 71f19d9fbe
23 changed files with 144 additions and 142 deletions

View file

@ -75,7 +75,7 @@ public class MultipleDepotExampleWithPenaltyVehicles {
int depotCounter = 1;
for(Coordinate depotCoord : Arrays.asList(firstDepotCoord,second)){
for(int i=0;i<nuOfVehicles;i++){
VehicleType vehicleType = VehicleTypeImpl.Builder.newInstance(depotCounter + "_type", capacity).setCostPerDistance(1.0).build();
VehicleType vehicleType = VehicleTypeImpl.Builder.newInstance(depotCounter + "_type").addCapacityDimension(0, capacity).setCostPerDistance(1.0).build();
String vehicleId = depotCounter + "_" + (i+1) + "_vehicle";
VehicleImpl.Builder vehicleBuilder = VehicleImpl.Builder.newInstance(vehicleId);
vehicleBuilder.setStartLocationCoordinate(depotCoord);