/** * Returns the departureTime of this vehicle in this route. * * @return departureTime * @throws IllegalArgumentException if start is null */ public double getDepartureTime() { if (start == null) throw new IllegalArgumentException("cannot get departureTime without having a vehicle on this route. use setVehicle(vehicle,departureTime) instead."); return start.getEndTime(); }
@Override public String toString() { return "[start=" + start + "][end=" + end + "][departureTime=" + start.getEndTime() + "][vehicle=" + vehicle + "][driver=" + driver + "][nuOfActs=" + tourActivities.getActivities().size() + "]"; }
/** * Sets the departure-time of the route, i.e. which is the time the vehicle departs from start-location. * <p> * <p><b>Note</b> that departureTime cannot be lower than earliestDepartureTime of vehicle. * * @param departureTime departure time of vehicle being employed for this route * @return builder * @throws IllegalArgumentException if departureTime < vehicle.getEarliestDeparture() */ public Builder setDepartureTime(double departureTime) { if (departureTime < start.getEndTime()) throw new IllegalArgumentException("departureTime < vehicle.getEarliestDepartureTime(). this must not be."); start.setEndTime(departureTime); return this; }
/** * @param route to get the total operation time from * @return operation time of this route, i.e. endTime - startTime of specified route */ public Double getOperationTime(VehicleRoute route) { if (route == null) throw new IllegalArgumentException("route is missing."); return route.getEnd().getArrTime() - route.getStart().getEndTime(); }
private Start(Start start) { this.location = start.getLocation(); theoretical_earliestOperationStartTime = start.getTheoreticalEarliestOperationStartTime(); theoretical_latestOperationStartTime = start.getTheoreticalLatestOperationStartTime(); endTime = start.getEndTime(); setIndex(-1); }
if (currentRoute.getStart() == null) { currentStart = newVehicleDepartureTime; } else currentStart = currentRoute.getStart().getEndTime();
out.format("+---------+----------------------+-----------------------+-----------------+-----------------+-----------------+-----------------+%n"); double costs = 0; out.format(leftAlgin, routeNu, getVehicleString(route), route.getStart().getName(), "-", "undef", Math.round(route.getStart().getEndTime()), Math.round(costs)); TourActivity prevAct = route.getStart();
int actIndex = 0; double sumOf_prevCosts_newVehicle = 0.0; double prevActDepTime_newVehicle = start.getEndTime(); double insertion_costs = auxilliaryPathCostCalculator.costOfPath(wholeTour, start.getEndTime(), newDriver, newVehicle) - currentRouteCosts; insertionData.setVehicleDepartureTime(start.getEndTime()); return insertionData;
/** * Returns the departureTime of this vehicle in this route. * * @return departureTime * @throws IllegalArgumentException if start is null */ public double getDepartureTime() { if (start == null) throw new IllegalArgumentException("cannot get departureTime without having a vehicle on this route. use setVehicle(vehicle,departureTime) instead."); return start.getEndTime(); }
xmlConfig.setProperty(path + "(" + routeCounter + ").driverId", route.getDriver().getId()); xmlConfig.setProperty(path + "(" + routeCounter + ").vehicleId", route.getVehicle().getId()); xmlConfig.setProperty(path + "(" + routeCounter + ").start", route.getStart().getEndTime()); int actCounter = 0; for (TourActivity act : route.getTourActivities().getActivities()) {
@Override public String toString() { return "[start=" + start + "][end=" + end + "][departureTime=" + start.getEndTime() + "][vehicle=" + vehicle + "][driver=" + driver + "][nuOfActs=" + tourActivities.getActivities().size() + "]"; }
/** * Sets the departure-time of the route, i.e. which is the time the vehicle departs from start-location. * <p> * <p><b>Note</b> that departureTime cannot be lower than earliestDepartureTime of vehicle. * * @param departureTime departure time of vehicle being employed for this route * @return builder * @throws IllegalArgumentException if departureTime < vehicle.getEarliestDeparture() */ public Builder setDepartureTime(double departureTime) { if (departureTime < start.getEndTime()) throw new IllegalArgumentException("departureTime < vehicle.getEarliestDepartureTime(). this must not be."); start.setEndTime(departureTime); return this; }
xmlConfig.setProperty(solutionPath + "(" + counter + ").routes.route(" + routeCounter + ").start", route.getStart().getEndTime()); int actCounter = 0; for (TourActivity act : route.getTourActivities().getActivities()) {
/** * @param route to get the total operation time from * @return operation time of this route, i.e. endTime - startTime of specified route */ public Double getOperationTime(VehicleRoute route) { if (route == null) throw new IllegalArgumentException("route is missing."); return route.getEnd().getArrTime() - route.getStart().getEndTime(); }
private Start(Start start) { this.location = start.getLocation(); theoretical_earliestOperationStartTime = start.getTheoreticalEarliestOperationStartTime(); theoretical_latestOperationStartTime = start.getTheoreticalLatestOperationStartTime(); endTime = start.getEndTime(); setIndex(-1); }
if (currentRoute.getStart() == null) { currentStart = newVehicleDepartureTime; } else currentStart = currentRoute.getStart().getEndTime();
out.format("+---------+----------------------+-----------------------+-----------------+-----------------+-----------------+-----------------+%n"); double costs = 0; out.format(leftAlgin, routeNu, getVehicleString(route), route.getStart().getName(), "-", "undef", Math.round(route.getStart().getEndTime()), Math.round(costs)); TourActivity prevAct = route.getStart();
xmlConfig.setProperty(path + "(" + routeCounter + ").driverId", route.getDriver().getId()); xmlConfig.setProperty(path + "(" + routeCounter + ").vehicleId", route.getVehicle().getId()); xmlConfig.setProperty(path + "(" + routeCounter + ").start", route.getStart().getEndTime()); int actCounter = 0; for (TourActivity act : route.getTourActivities().getActivities()) {
assert route.getDepartureTime() == route.getStart().getEndTime() : "at this point route.getDepartureTime and route.getStart().getEndTime() must be equal"; TourActivities tour = route.getTourActivities(); CarrierVehicle carrierVehicle = createCarrierVehicle(route.getVehicle()); double depTime = route.getStart().getEndTime();
rd.startTime = vr.getStart().getEndTime();