nl.tudelft.simulation.traffic.track
Class ArcTrack

java.lang.Object
  extended bynl.tudelft.simulation.traffic.track.Track
      extended bynl.tudelft.simulation.traffic.track.ArcTrack
All Implemented Interfaces:
nl.tudelft.simulation.dsol.animation.LocatableInterface, TrackInterface

public class ArcTrack
extends Track

A curved track from one link to another link.
(c) copyright 2003-2004 Delft University of Technology , the Netherlands.
See for project information www.simulation.tudelft.nl
License of use: General Public License (GPL) , no warranty

Version:
May 30, 2004
Author:
Alexander Verbraeck

Field Summary
(package private)  double theta
          the angle of the dx/dy of the track
 
Fields inherited from class nl.tudelft.simulation.traffic.track.Track
endLink, name, startLink, TRACK_ROUTE_ACTIVE, TRACK_ROUTE_ALL, TRACK_ROUTE_LINE, vehicles
 
Constructor Summary
ArcTrack(java.lang.String name, TrackLinkInterface startLink, TrackLinkInterface endLink, double radius)
           
 
Method Summary
 javax.media.j3d.Bounds getBounds()
           
 java.awt.geom.Point2D getCenter()
           
 double getEndAngle()
           
 double getLength()
           
 nl.tudelft.simulation.language.d3.DirectedPoint getLocationOfProgression(double progression)
          The getLocationOfProgression method is only used for animation.
 double getRadius()
           
 double getStartAngle()
           
 boolean isCounterClockwise()
           
 
Methods inherited from class nl.tudelft.simulation.traffic.track.Track
addControlPoint, addVehicle, calculateDistanceFrontBack, calculateDistanceFrontBack, calculateTrackProgressionListActive, calculateTrackProgressionListAll, calculateTrackProgressionListLine, getControlPoints, getCpsOnInterval, getdx, getdy, getEndLink, getLocation, getStartLink, getVehiclesOnTrack, removeControlPoint, removeVehicle, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

theta

double theta
the angle of the dx/dy of the track

Constructor Detail

ArcTrack

public ArcTrack(java.lang.String name,
                TrackLinkInterface startLink,
                TrackLinkInterface endLink,
                double radius)
         throws java.lang.Exception
Parameters:
name -
startLink -
endLink -
radius -
Throws:
java.lang.Exception
Method Detail

getLocationOfProgression

public nl.tudelft.simulation.language.d3.DirectedPoint getLocationOfProgression(double progression)
Description copied from interface: TrackInterface
The getLocationOfProgression method is only used for animation. It translates a progression on this track to a 3d-coordinate. It also calculates the orientation of the returned Location.

Parameters:
progression -
Returns:
location
See Also:
TrackInterface.getLocationOfProgression(double)

getBounds

public javax.media.j3d.Bounds getBounds()
See Also:
LocatableInterface.getBounds()

getRadius

public double getRadius()
Returns:
Returns the radius.

getCenter

public java.awt.geom.Point2D getCenter()
Returns:
Returns the center.

getEndAngle

public double getEndAngle()
Returns:
Returns the endAngle.

getStartAngle

public double getStartAngle()
Returns:
Returns the startAngle.

isCounterClockwise

public boolean isCounterClockwise()
Returns:
Returns counter clockwise drawing direction.

getLength

public double getLength()
Returns:
length of the track
See Also:
TrackInterface.getLength()


Copyright © 2003-2004 Delft University of Technology, the Netherlands. All Rights Reserved.