public class PlanningVisit extends Object implements Standstill
| Constructor and Description |
|---|
PlanningVisit() |
| Modifier and Type | Method and Description |
|---|---|
long |
distanceFromPreviousStandstill()
Distance from the previous standstill to this visit.
|
long |
distanceToDepot()
Distance from this visit back to the depot.
|
int |
getDemand() |
long |
getId() |
PlanningLocation |
getLocation()
The standstill's location.
|
PlanningVisit |
getNextVisit()
The next visit after this standstill.
|
Standstill |
getPreviousStandstill() |
PlanningVehicle |
getVehicle() |
boolean |
isLast()
Whether this visit is the last in a chain.
|
void |
setDemand(int demand) |
void |
setId(long id) |
void |
setLocation(PlanningLocation location) |
void |
setNextVisit(PlanningVisit nextVisit) |
void |
setPreviousStandstill(Standstill previousStandstill) |
void |
setVehicle(PlanningVehicle vehicle) |
String |
toString() |
public long getId()
public void setId(long id)
public PlanningLocation getLocation()
StandstillgetLocation in interface Standstillnullpublic void setLocation(PlanningLocation location)
public int getDemand()
public void setDemand(int demand)
public Standstill getPreviousStandstill()
public void setPreviousStandstill(Standstill previousStandstill)
public PlanningVisit getNextVisit()
StandstillgetNextVisit in interface Standstillnullpublic void setNextVisit(PlanningVisit nextVisit)
setNextVisit in interface Standstillpublic PlanningVehicle getVehicle()
public void setVehicle(PlanningVehicle vehicle)
public long distanceFromPreviousStandstill()
last visit.
The chain ends with a visit, not a depot so the cost of returning from the last visit back to the depot
has to be added in a separate step using distanceToDepot().public long distanceToDepot()
public boolean isLast()
next visitCopyright © 2001–2020 JBoss by Red Hat. All rights reserved.