public class DefaultCarAnimation extends Renderable2D<LaneBasedGTU> implements ClonableRenderable2DInterface<LaneBasedGTU>, Serializable
 Copyright (c) 2013-2019 Delft University of Technology, PO Box 5, 2600 AA, Delft, the Netherlands. All rights reserved. 
 BSD-style license. See OpenTrafficSim License.
 
| Modifier and Type | Class and Description | 
|---|---|
class  | 
DefaultCarAnimation.Text
Text animation for the Car. 
 | 
Renderable2DInterface.Util| Constructor and Description | 
|---|
DefaultCarAnimation(LaneBasedGTU gtu,
                   SimulatorInterface.TimeDoubleUnit simulator)
Construct the DefaultCarAnimation for a LaneBasedIndividualCar. 
 | 
DefaultCarAnimation(LaneBasedGTU gtu,
                   SimulatorInterface.TimeDoubleUnit simulator,
                   GTUColorer gtuColorer)
Construct the DefaultCarAnimation for a LaneBasedIndividualCar. 
 | 
| Modifier and Type | Method and Description | 
|---|---|
ClonableRenderable2DInterface<LaneBasedGTU> | 
clone(LaneBasedGTU newSource,
     SimulatorInterface.TimeDoubleUnit newSimulator)
Clone the animation object and register it for the new source on the new simulation. 
 | 
void | 
destroy() | 
boolean | 
equals(Object object) | 
int | 
hashCode() | 
void | 
paint(Graphics2D graphics,
     ImageObserver observer) | 
void | 
setGTUColorer(GTUColorer newGTUColorer)
Replace the GTUColorer. 
 | 
String | 
toString() | 
bind2Context, contains, getSource, isFlip, isRotate, isScale, isTranslate, paint, setFlip, setRotate, setScale, setTranslateclone, finalize, getClass, notify, notifyAll, wait, wait, waitcontains, getSource, paintpublic DefaultCarAnimation(LaneBasedGTU gtu, SimulatorInterface.TimeDoubleUnit simulator) throws NamingException, RemoteException
gtu - LaneBasedGTU; the Car to drawsimulator - SimulatorInterface.TimeDoubleUnit; the simulator to schedule onNamingException - in case of registration failure of the animationRemoteException - on communication failurepublic DefaultCarAnimation(LaneBasedGTU gtu, SimulatorInterface.TimeDoubleUnit simulator, GTUColorer gtuColorer) throws NamingException, RemoteException
gtu - LaneBasedGTU; the Car to drawsimulator - SimulatorInterface.TimeDoubleUnit; the simulator to schedule ongtuColorer - GTUColorer; the GTUColorer that determines what fill color to useNamingException - in case of registration failure of the animationRemoteException - on communication failurepublic final void setGTUColorer(GTUColorer newGTUColorer)
newGTUColorer - GTUColorer; the GTUColorer to use from now onpublic final void paint(Graphics2D graphics, ImageObserver observer)
paint in class Renderable2D<LaneBasedGTU>public final void destroy()
                   throws NamingException
destroy in interface Renderable2DInterface<LaneBasedGTU>destroy in class Renderable2D<LaneBasedGTU>NamingExceptionpublic ClonableRenderable2DInterface<LaneBasedGTU> clone(LaneBasedGTU newSource, SimulatorInterface.TimeDoubleUnit newSimulator) throws NamingException, RemoteException
clone in interface ClonableRenderable2DInterface<LaneBasedGTU>newSource - T; the sourcenewSimulator - SimulatorInterface.TimeDoubleUnit; the simulatorNamingException - when animation context cannot be created or retrievedRemoteException - - when remote context cannot be foundpublic final String toString()
toString in class Renderable2D<LaneBasedGTU>public int hashCode()
hashCode in class Renderable2D<LaneBasedGTU>public boolean equals(Object object)
equals in class Renderable2D<LaneBasedGTU>Copyright © 2014–2019 Delft University of Technology. All rights reserved.