|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
The TrackInterface defines the interface of Track. A track represents an
element of the infrastructure running from its startLink to its endLink.
Progression is defined as a distance along the infrastructure. Vehicles only
use progression. They only think in a line along the infrastructure, not in
worldcoordinates.
TrackLinkInterface| Method Summary | |
void |
addControlPoint(ControlPointInterface cp)
This method adds a controlPoint to this track. |
void |
addVehicle(VehiclePhysicalInterface vehicle)
indicate that a vehicle is driving on the track (with front) |
TrackProgression |
calculateTrackProgressionListActive(double delta)
Calculate a position on the 'active' track located 'delta' meters from the start of the current track. |
java.util.List |
calculateTrackProgressionListAll(double delta)
Calculate all positions on tracks located 'delta' meters from the start of the current track. |
java.util.List |
calculateTrackProgressionListLine(double delta,
java.lang.String line)
Calculate a position on a track located 'delta' meters from the start of the current track. |
ControlPointsList |
getControlPoints()
Returns controlpoints for the track, as a sorted list. |
ControlPointsList |
getCpsOnInterval(double startProgression,
double lengthOfInterval)
This method checks for controlPoints in an interval, inclusive, so returns cps that are on the edges of the interval |
TrackLinkInterface |
getEndLink()
This method returns the link seen as the link at which the track ends. |
double |
getLength()
|
nl.tudelft.simulation.language.d3.DirectedPoint |
getLocationOfProgression(double progression)
The getLocationOfProgression method is only used for animation. |
TrackLinkInterface |
getStartLink()
This method returns the link seen as the link from which the track starts. |
java.util.List |
getVehiclesOnTrack()
get the vehicles on the track |
void |
removeControlPoint(ControlPointInterface cp)
This method removes a given cp from the ControlPointsLists of the track. |
void |
removeVehicle(VehiclePhysicalInterface vehicle)
indicate that a vehicle is no longer driving on the track (with front) |
| Method Detail |
public nl.tudelft.simulation.language.d3.DirectedPoint getLocationOfProgression(double progression)
progression -
public ControlPointsList getControlPoints()
public void addControlPoint(ControlPointInterface cp)
cp - ControlPointInterfacepublic TrackLinkInterface getStartLink()
public TrackLinkInterface getEndLink()
public double getLength()
public ControlPointsList getCpsOnInterval(double startProgression,
double lengthOfInterval)
startProgression - lengthOfInterval -
public void removeControlPoint(ControlPointInterface cp)
cp - public void addVehicle(VehiclePhysicalInterface vehicle)
vehicle - public void removeVehicle(VehiclePhysicalInterface vehicle)
vehicle - public java.util.List getVehiclesOnTrack()
public java.util.List calculateTrackProgressionListAll(double delta)
delta -
public TrackProgression calculateTrackProgressionListActive(double delta)
delta -
public java.util.List calculateTrackProgressionListLine(double delta,
java.lang.String line)
delta - line -
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||