mirror of
https://github.com/graphhopper/jsprit.git
synced 2020-01-24 07:45:05 +01:00
adjust vehicle array - related to #292
This commit is contained in:
parent
f8ea447cb9
commit
651b52530f
1 changed files with 1 additions and 1 deletions
|
|
@ -52,7 +52,7 @@ public class MaxDistanceConstraint implements HardActivityConstraint{
|
|||
|
||||
private void makeArray(Map<Vehicle, Double> maxDistances) {
|
||||
int maxIndex = getMaxIndex(maxDistances.keySet());
|
||||
this.maxDistances = new Double[maxIndex];
|
||||
this.maxDistances = new Double[maxIndex+1];
|
||||
for(Vehicle v : maxDistances.keySet()){
|
||||
this.maxDistances[v.getIndex()]=maxDistances.get(v);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue