public abstract class AbstractLaneBasedIndividualGTU extends AbstractLaneBasedGTU
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.
CACHED_POSITION, CACHING, initialLocationThresholdDifference, NON_CACHED_POSITION
ALIGN_COUNT, ALIGNED, operationalPlan
listeners
LANE_CHANGE_EVENT, LANE_ENTER_EVENT, LANE_EXIT_EVENT, LANEBASED_DESTROY_EVENT, LANEBASED_INIT_EVENT, LANEBASED_MOVE_EVENT, LINK_ENTER_EVENT, LINK_EXIT_EVENT
DESTROY_EVENT, INIT_EVENT, MOVE_EVENT
FIRST_POSITION, LAST_POSITION
Constructor and Description |
---|
AbstractLaneBasedIndividualGTU(String id,
GTUType gtuType,
Length length,
Length width,
Speed maximumSpeed,
OTSSimulatorInterface simulator,
OTSNetwork network)
Construct a new AbstractLaneBasedIndividualGTU.
|
Modifier and Type | Method and Description |
---|---|
Length |
getLength() |
Speed |
getMaximumSpeed() |
Length |
getWidth() |
boolean |
laneChangeAllowed()
Returns whether a lane change is allowed.
|
void |
setNoLaneChangeDistance(Length distance)
Set distance over which the GTU should not change lane after being created.
|
addGtuToLane, addTrigger, changeLaneInstantaneously, destroy, enterLane, finalizeLaneChange, fractionalPosition, fractionalPosition, fractionalPositions, fractionalPositions, getBounds, getCarFollowingAcceleration, getDesiredSpeed, getDirection, getReferencePosition, getStrategicalPlanner, getStrategicalPlanner, getTurnIndicatorStatus, getTurnIndicatorStatus, getVehicleModel, init, initLaneChange, isSafeToChange, leaveLane, leaveLane, move, position, position, positions, positions, projectedPosition, reinit, scheduleEnterLeaveTriggers, setFinalizeLaneChangeEvent, setParent, setTurnIndicatorStatus, setVehicleModel, toString, translatedPosition
addGtu, equals, getAcceleration, getAcceleration, getChildren, getGTUType, getId, getLocation, getMaximumAcceleration, getMaximumDeceleration, getNextMoveEvent, getOdometer, getOdometer, getOperationalPlan, getOperationalPlan, getParameters, getParent, getPerceivableContext, getReference, getSimulator, getSpeed, getSpeed, hashCode, init, interruptMove, isDestroyed, removeGtu, setMaximumAcceleration, setMaximumDeceleration, setParameters
addListener, addListener, addListener, addListener, fireEvent, fireEvent, fireEvent, fireEvent, fireEvent, fireEvent, fireEvent, fireEvent, fireEvent, fireEvent, fireTimedEvent, fireTimedEvent, fireTimedEvent, fireTimedEvent, fireTimedEvent, fireTimedEvent, fireTimedEvent, removeAllListeners, removeAllListeners, removeListener
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
getLocation, getTacticalPlanner, getTacticalPlanner, isBrakingLightsOn, isBrakingLightsOn
addGtu, getAcceleration, getAcceleration, getCenter, getChildren, getContourPoints, getFront, getGTUType, getId, getMaximumAcceleration, getMaximumDeceleration, getOdometer, getOdometer, getOperationalPlan, getOperationalPlan, getParameters, getParent, getRear, getReference, getRelativePositions, getSimulator, getSpeed, getSpeed, isDestroyed, removeGtu, setParameters
addListener, addListener, addListener, addListener, removeListener
public AbstractLaneBasedIndividualGTU(String id, GTUType gtuType, Length length, Length width, Speed maximumSpeed, OTSSimulatorInterface simulator, OTSNetwork network) throws GTUException
id
- String; the id of the GTUgtuType
- GTUType; the type of GTU, e.g. TruckType, CarType, BusTypelength
- Length; the maximum length of the GTU (parallel with driving direction)width
- Length; the maximum width of the GTU (perpendicular to driving direction)maximumSpeed
- Speed; the maximum speed of the GTU (in the driving direction)simulator
- OTSSimulatorInterface; the simulatornetwork
- OTSNetwork; the network that the GTU is initially registered inGTUException
- when a parameter is invalidpublic final Length getLength()
public final Length getWidth()
public final Speed getMaximumSpeed()
public final void setNoLaneChangeDistance(Length distance)
distance
- Length; distance over which the GTU should not change lane after being createdpublic final boolean laneChangeAllowed()
Copyright © 2014–2019 Delft University of Technology. All rights reserved.