| Modifier and Type | Field and Description |
|---|---|
protected TimeWindowsImpl |
deliveryTimeWindows |
double |
maxTimeInVehicle |
Object |
userData |
protected TimeWindowsImpl deliveryTimeWindows
public Object userData
public double maxTimeInVehicle
public static Shipment.Builder newInstance(String id)
id - the id of the shipment which must be a unique identifier among all jobspublic Shipment.Builder setUserData(Object userData)
The user data is a black box for the framework, it only stores it, but never interacts with it in any way.
userData - any object holding the domain specific user data
associated with the object.public Shipment.Builder setPickupLocation(Location pickupLocation)
pickupLocation - pickup locationpublic Shipment.Builder setPickupServiceTime(double serviceTime)
ServiceTime is intended to be the time the implied activity takes at the pickup-location.
serviceTime - the service time / duration the pickup of the associated shipment takesIllegalArgumentException - if servicTime < 0.0public Shipment.Builder setPickupTimeWindow(TimeWindow timeWindow)
By default timeWindow is [0.0, Double.MAX_VALUE}
timeWindow - the time window within the pickup operation/activity can STARTIllegalArgumentException - if timeWindow is nullpublic Shipment.Builder setDeliveryLocation(Location deliveryLocation)
deliveryLocation - delivery locationpublic Shipment.Builder setDeliveryServiceTime(double deliveryServiceTime)
ServiceTime is intended to be the time the implied activity takes at the delivery-location.
deliveryServiceTime - the service time / duration of shipment's deliveryIllegalArgumentException - if serviceTime < 0.0public Shipment.Builder setDeliveryTimeWindow(TimeWindow timeWindow)
By default timeWindow is [0.0, Double.MAX_VALUE}
timeWindow - the time window within the associated delivery is allowed to STARTIllegalArgumentException - if timeWindow is nullpublic Shipment.Builder addSizeDimension(int dimensionIndex, int dimensionValue)
dimensionIndex - the dimension index of the corresponding capacity valuedimensionValue - the capacity valueIllegalArgumentException - if dimVal < 0public Shipment.Builder addAllSizeDimensions(Capacity size)
public Shipment build()
IllegalArgumentException - if neither pickup-location nor pickup-coord is set or if neither delivery-location nor delivery-coord
is setpublic Shipment.Builder addRequiredSkill(String skill)
public Shipment.Builder addAllRequiredSkills(Collection<String> skills)
public Shipment.Builder addAllRequiredSkills(Skills skills)
public Shipment.Builder setName(String name)
public Shipment.Builder addDeliveryTimeWindow(TimeWindow timeWindow)
public Shipment.Builder addDeliveryTimeWindow(double earliest, double latest)
public Shipment.Builder addAllDeliveryTimeWindows(Collection<TimeWindow> timeWindow)
public Shipment.Builder addPickupTimeWindow(TimeWindow timeWindow)
public Shipment.Builder addPickupTimeWindow(double earliest, double latest)
public Shipment.Builder addAllPickupTimeWindows(Collection<TimeWindow> timeWindow)
public Shipment.Builder setPriority(int priority)
Default is 2.
priority - public Shipment.Builder setMaxTimeInVehicle(double maxTimeInVehicle)
maxTimeInVehicle - Copyright © 2013–2024. All rights reserved.