ID - The type of ID, e.g., String or Integerpublic abstract class AbstractGTU<ID> extends Object implements GTU<ID>
Copyright (c) 2013-2015 Delft University of Technology, PO Box 5, 2600 AA, Delft, the Netherlands. All rights reserved.
BSD-style license. See OpenTrafficSim License.
| Constructor and Description |
|---|
AbstractGTU(ID id,
GTUType<?> gtuType,
Route<?,?> route) |
| Modifier and Type | Method and Description |
|---|---|
GTUType<?> |
getGTUType() |
ID |
getId() |
RelativePosition |
getReference() |
Route<?,?> |
getRoute() |
void |
setRoute(Route<?,?> route) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitdestroy, getAcceleration, getFront, getLength, getMaximumVelocity, getOdometer, getRear, getRelativePositions, getSimulator, getVelocity, getWidthgetBounds, getLocationpublic AbstractGTU(ID id, GTUType<?> gtuType, Route<?,?> route) throws GTUException
id - the id of the GTU, could be String or IntegergtuType - the type of GTU, e.g. TruckType, CarType, BusTyperoute - Route; the route that the GTU will takeGTUException - when route is nullpublic final ID getId()
public GTUType<?> getGTUType()
getGTUType in interface GTU<ID>public final Route<?,?> getRoute()
public final void setRoute(Route<?,?> route)
route - set route.public final RelativePosition getReference()
getReference in interface GTU<ID>Copyright © 2014–2015 Delft University of Technology. All rights reserved.