if(currentDistance + additionalDistance + additionalDistanceOfPickup > maxDistance){
return ConstraintsStatus.NOT_FULFILLED;
}
return ConstraintsStatus.FULFILLED;
}
<BUG>private boolean hasMaxDistance(Vehicle newVehicle){
return this.maxDistances[newVehicle.getIndex()] != null;</BUG>
}
private double getMaxDistance(Vehicle newVehicle) {
Double maxDistance = this.maxDistances[newVehicle.getIndex()];

if(currentDistance + additionalDistance + additionalDistanceOfPickup > maxDistance){
return ConstraintsStatus.NOT_FULFILLED;
}
return ConstraintsStatus.FULFILLED;
}
private boolean hasMaxDistance(Vehicle newVehicle){
if(newVehicle.getIndex() >= this.maxDistances.length) return false;
return this.maxDistances[newVehicle.getIndex()] != null;
}
private double getMaxDistance(Vehicle newVehicle) {
Double maxDistance = this.maxDistances[newVehicle.getIndex()];
