nl.tudelft.simulation.traffic.controlpoint.real
Class SpeedSign
java.lang.Object
nl.tudelft.simulation.event.EventProducer
nl.tudelft.simulation.traffic.controlpoint.real.AbstractVisibleControlPoint
nl.tudelft.simulation.traffic.controlpoint.real.SpeedSign
- All Implemented Interfaces:
- ControlPointInterface, nl.tudelft.simulation.event.EventProducerInterface, nl.tudelft.simulation.dsol.animation.LocatableInterface, java.io.Serializable, SpeedLimitInterface, VisibleControlPointInterface
- public class SpeedSign
- extends AbstractVisibleControlPoint
- implements SpeedLimitInterface, nl.tudelft.simulation.dsol.animation.LocatableInterface
This class represents a simple sign. Basically it only implements the
SpeedLimitInterface and extends the AbstractVisibleControlPoint.
- Author:
- J.H. Kwakkel & H.W.G. Phaff
- See Also:
SpeedLimitInterface,
AbstractVisibleControlPoint,
Serialized Form
| Fields inherited from class nl.tudelft.simulation.event.EventProducer |
listeners |
| Fields inherited from interface nl.tudelft.simulation.event.EventProducerInterface |
FIRST_POSITION, LAST_POSITION |
|
Constructor Summary |
SpeedSign(java.lang.String name,
TrackInterface track,
double progression,
double visibleDistance,
double speedLimit,
nl.tudelft.simulation.dsol.simulators.SimulatorInterface simulator,
double dx,
double dy,
java.lang.String text,
java.awt.Color backgroundColor,
java.awt.Color textColor,
java.awt.Color lineColor)
|
| Methods inherited from class nl.tudelft.simulation.event.EventProducer |
addListener, addListener, addListener, addListener, fireEvent, fireEvent, fireEvent, fireEvent, fireEvent, fireEvent, fireEvent, fireEvent, fireEvent, fireEvent, fireEvent, fireEvent, fireEvent, fireEvent, fireEvent, fireEvent, getEventTypes, removeAllListeners, removeAllListeners, removeListener |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
SpeedSign
public SpeedSign(java.lang.String name,
TrackInterface track,
double progression,
double visibleDistance,
double speedLimit,
nl.tudelft.simulation.dsol.simulators.SimulatorInterface simulator,
double dx,
double dy,
java.lang.String text,
java.awt.Color backgroundColor,
java.awt.Color textColor,
java.awt.Color lineColor)
- Parameters:
name - track - progression - visibleDistance - speedLimit - simulator - dx - dy - text - backgroundColor - textColor - lineColor -
pass
public void pass(VehiclePhysicalInterface vehicle)
- Description copied from interface:
ControlPointInterface
- This method handles actions of the controlPoint when the controlPoint is
passed by a vehicle.
- Specified by:
pass in interface ControlPointInterface
- Parameters:
vehicle - that triggers the controlPoint- See Also:
ControlPointInterface.pass(nl.tudelft.simulation.traffic.vehicle.VehiclePhysicalInterface)
getProgression
public double getProgression()
- Description copied from interface:
ControlPointInterface
- The getProgression() method returns progression where the controlPoint is
located
- Specified by:
getProgression in interface ControlPointInterface- Overrides:
getProgression in class AbstractVisibleControlPoint
- See Also:
ControlPointInterface.getProgression()
getTrack
public TrackInterface getTrack()
- Description copied from interface:
ControlPointInterface
- This method returns the track on which the controlPoint is located
- Specified by:
getTrack in interface ControlPointInterface- Overrides:
getTrack in class AbstractVisibleControlPoint
- See Also:
ControlPointInterface.getTrack()
getSpeedLimit
public double getSpeedLimit()
- Specified by:
getSpeedLimit in interface SpeedLimitInterface
- Returns:
- the new speedLimit
- See Also:
SpeedLimitInterface.getSpeedLimit()
getLocation
public nl.tudelft.simulation.language.d3.DirectedPoint getLocation()
throws java.rmi.RemoteException
- Specified by:
getLocation in interface nl.tudelft.simulation.dsol.animation.LocatableInterface- Overrides:
getLocation in class AbstractVisibleControlPoint
- Throws:
java.rmi.RemoteException- See Also:
LocatableInterface.getLocation()
getBounds
public javax.media.j3d.Bounds getBounds()
throws java.rmi.RemoteException
- Specified by:
getBounds in interface nl.tudelft.simulation.dsol.animation.LocatableInterface- Overrides:
getBounds in class AbstractVisibleControlPoint
- Throws:
java.rmi.RemoteException- See Also:
LocatableInterface.getBounds()
getText
public java.lang.String getText()
- Returns:
- Returns the display text.
toString
public java.lang.String toString()
- See Also:
Object.toString()
Copyright © 2003-2004 Delft University of Technology, the Netherlands. All Rights Reserved.