public class NeighborsPerception extends LaneBasedAbstractPerceptionCategory
Copyright (c) 2013-2016 Delft University of Technology, PO Box 5, 2600 AA, Delft, the Netherlands. All rights reserved.
BSD-style license. See OpenTrafficSim License.
| Constructor and Description |
|---|
NeighborsPerception(LanePerception perception) |
| Modifier and Type | Method and Description |
|---|---|
SortedSet<AbstractHeadwayGTU> |
getFirstFollowers(org.opentrafficsim.core.network.LateralDirectionality lat)
Set of followers on a lane, which is usually 0 or 1, but possibly more in case of an upstream merge with no intermediate
GTU.
|
SortedSet<AbstractHeadwayGTU> |
getFirstLeaders(org.opentrafficsim.core.network.LateralDirectionality lat)
Set of leaders on a lane, which is usually 0 or 1, but possibly more in case of a downstream split with no intermediate
GTU.
|
SortedSet<AbstractHeadwayGTU> |
getFollowers(RelativeLane lane)
Set of followers on a lane, including adjacent GTU's who's REAR is back of the own vehicle REAR.
|
LanePathInfo |
getLanePathInfo()
Retrieve the last perceived lane path info.
|
SortedSet<AbstractHeadwayGTU> |
getLeaders(RelativeLane lane)
Set of leaders on a lane, including adjacent GTU's who's FRONT is ahead of the own vehicle FRONT.
|
org.opentrafficsim.core.gtu.perception.TimeStampedObject<SortedSet<AbstractHeadwayGTU>> |
getTimeStampedFirstFollowers(org.opentrafficsim.core.network.LateralDirectionality lat)
Set of followers on a lane, which is usually 0 or 1, but possibly more in case of an upstream merge with no intermediate
GTU.
|
org.opentrafficsim.core.gtu.perception.TimeStampedObject<SortedSet<AbstractHeadwayGTU>> |
getTimeStampedFirstLeaders(org.opentrafficsim.core.network.LateralDirectionality lat)
Set of leaders on a lane, which is usually 0 or 1, but possibly more in case of a downstream split with no intermediate
GTU.
|
org.opentrafficsim.core.gtu.perception.TimeStampedObject<SortedSet<AbstractHeadwayGTU>> |
getTimeStampedFollowers(RelativeLane lane)
Set of followers on a lane, including adjacent GTU's who's REAR is back of the own vehicle REAR.
|
org.opentrafficsim.core.gtu.perception.TimeStampedObject<LanePathInfo> |
getTimeStampedLanePathInfo()
Retrieve the time stamped last perceived lane path info.
|
org.opentrafficsim.core.gtu.perception.TimeStampedObject<SortedSet<AbstractHeadwayGTU>> |
getTimeStampedLeaders(RelativeLane lane)
Set of leaders on a lane, including adjacent GTU's who's FRONT is ahead of the own vehicle FRONT.
|
boolean |
isGtuAlongside(org.opentrafficsim.core.network.LateralDirectionality lat)
Whether there is a GTU alongside, i.e.
|
org.opentrafficsim.core.gtu.perception.TimeStampedObject<Boolean> |
isGtuAlongsideTimeStamped(org.opentrafficsim.core.network.LateralDirectionality lat)
Whether there is a GTU alongside, i.e.
|
String |
toString() |
void |
updateAll() |
void |
updateFirstFollowers(org.opentrafficsim.core.network.LateralDirectionality lat)
Update set of followers on a lane, which is usually 0 or 1, but possibly more in case of an upstream merge with no
intermediate GTU.
|
void |
updateFirstLeaders(org.opentrafficsim.core.network.LateralDirectionality lat)
Update set of leaders on a lane, which is usually 0 or 1, but possibly more in case of a downstream split with no
intermediate GTU.
|
void |
updateFollowers(RelativeLane lane)
Update set of followers on a lane, including adjacent GTU's who's REAR is back of the own vehicle REAR.
|
void |
updateGtuAlongside(org.opentrafficsim.core.network.LateralDirectionality lat)
Update whether there is a GTU alongside, i.e.
|
void |
updateLanePathInfo() |
void |
updateLeaders(RelativeLane lane)
Update set of leaders on a lane, including adjacent GTU's who's FRONT is ahead of the own vehicle FRONT.
|
getGtu, getPerceptionpublic NeighborsPerception(LanePerception perception)
perception - perceptionpublic final void updateAll()
throws org.opentrafficsim.core.gtu.GTUException,
org.opentrafficsim.core.network.NetworkException,
org.opentrafficsim.core.gtu.behavioralcharacteristics.ParameterException
updateAll in class org.opentrafficsim.core.gtu.perception.AbstractPerceptionCategoryorg.opentrafficsim.core.gtu.GTUExceptionorg.opentrafficsim.core.network.NetworkExceptionorg.opentrafficsim.core.gtu.behavioralcharacteristics.ParameterExceptionpublic final void updateFirstLeaders(org.opentrafficsim.core.network.LateralDirectionality lat)
throws org.opentrafficsim.core.gtu.behavioralcharacteristics.ParameterException,
org.opentrafficsim.core.gtu.GTUException,
org.opentrafficsim.core.network.NetworkException
lat - LEFT or RIGHTorg.opentrafficsim.core.network.NetworkException - in case of a network exceptionorg.opentrafficsim.core.gtu.GTUException - if the GTU was not initializedorg.opentrafficsim.core.gtu.behavioralcharacteristics.ParameterException - if a parameter was not present or out of boundsNullPointerException - if lat is nullIllegalArgumentException - if lat is NONEpublic final void updateFirstFollowers(org.opentrafficsim.core.network.LateralDirectionality lat)
throws org.opentrafficsim.core.gtu.GTUException,
org.opentrafficsim.core.gtu.behavioralcharacteristics.ParameterException,
org.opentrafficsim.core.network.NetworkException
lat - LEFT or RIGHTorg.opentrafficsim.core.network.NetworkException - in case of a network exceptionorg.opentrafficsim.core.gtu.GTUException - if the GTU was not initializedorg.opentrafficsim.core.gtu.behavioralcharacteristics.ParameterException - if a parameter was not present or out of boundsNullPointerException - if lat is nullIllegalArgumentException - if lat is NONEpublic final void updateGtuAlongside(org.opentrafficsim.core.network.LateralDirectionality lat)
throws org.opentrafficsim.core.gtu.GTUException,
org.opentrafficsim.core.gtu.behavioralcharacteristics.ParameterException
lat - LEFT or RIGHTorg.opentrafficsim.core.gtu.GTUException - if the GTU was not initializedorg.opentrafficsim.core.gtu.behavioralcharacteristics.ParameterException - if parameter is not definedNullPointerException - if lat is nullIllegalArgumentException - if lat is NONEpublic final void updateLeaders(RelativeLane lane) throws org.opentrafficsim.core.gtu.behavioralcharacteristics.ParameterException, org.opentrafficsim.core.gtu.GTUException, org.opentrafficsim.core.network.NetworkException
lane - relative lateral laneorg.opentrafficsim.core.network.NetworkException - in case of a network exceptionorg.opentrafficsim.core.gtu.GTUException - if the GRU was not initializedorg.opentrafficsim.core.gtu.behavioralcharacteristics.ParameterException - if a parameter was not present or out of boundspublic final void updateFollowers(RelativeLane lane) throws org.opentrafficsim.core.gtu.GTUException, org.opentrafficsim.core.network.NetworkException, org.opentrafficsim.core.gtu.behavioralcharacteristics.ParameterException
lane - relative lateral laneorg.opentrafficsim.core.network.NetworkException - in case of a network exceptionorg.opentrafficsim.core.gtu.GTUException - if the GRU was not initializedorg.opentrafficsim.core.gtu.behavioralcharacteristics.ParameterException - if a parameter was not present or out of boundspublic final SortedSet<AbstractHeadwayGTU> getFirstLeaders(org.opentrafficsim.core.network.LateralDirectionality lat) throws org.opentrafficsim.core.gtu.behavioralcharacteristics.ParameterException, NullPointerException, IllegalArgumentException
| |
_________/B/_____
_ _?_ _ _~_ _C_ _
_ _A_ _ _ _ _ _ _
_________________
lat - LEFT or RIGHTorg.opentrafficsim.core.gtu.behavioralcharacteristics.ParameterException - if parameter is not definedNullPointerException - if lat is nullIllegalArgumentException - if lat is NONEpublic final SortedSet<AbstractHeadwayGTU> getFirstFollowers(org.opentrafficsim.core.network.LateralDirectionality lat) throws org.opentrafficsim.core.gtu.behavioralcharacteristics.ParameterException, NullPointerException, IllegalArgumentException
| |
|C|
________\ \______
_ _B_|_ _ _ _ _?_
_ _ _|_ _ _ _ _A_
_____|___________
lat - LEFT or RIGHTorg.opentrafficsim.core.gtu.behavioralcharacteristics.ParameterException - if parameter is not definedNullPointerException - if lat is nullIllegalArgumentException - if lat is NONEpublic final boolean isGtuAlongside(org.opentrafficsim.core.network.LateralDirectionality lat)
throws org.opentrafficsim.core.gtu.behavioralcharacteristics.ParameterException,
NullPointerException,
IllegalArgumentException
lat - LEFT or RIGHTorg.opentrafficsim.core.gtu.behavioralcharacteristics.ParameterException - if parameter is not definedNullPointerException - if lat is nullIllegalArgumentException - if lat is NONEpublic final SortedSet<AbstractHeadwayGTU> getLeaders(RelativeLane lane)
lane - relative lateral lanepublic final SortedSet<AbstractHeadwayGTU> getFollowers(RelativeLane lane)
lane - relative lateral lanepublic final org.opentrafficsim.core.gtu.perception.TimeStampedObject<SortedSet<AbstractHeadwayGTU>> getTimeStampedFirstLeaders(org.opentrafficsim.core.network.LateralDirectionality lat) throws org.opentrafficsim.core.gtu.behavioralcharacteristics.ParameterException, NullPointerException, IllegalArgumentException
| |
_________/B/_____
_ _?_ _ _~_ _C_ _
_ _A_ _ _ _ _ _ _
_________________
lat - LEFT or RIGHTorg.opentrafficsim.core.gtu.behavioralcharacteristics.ParameterException - if parameter is not definedNullPointerException - if lat is nullIllegalArgumentException - if lat is NONEpublic final org.opentrafficsim.core.gtu.perception.TimeStampedObject<SortedSet<AbstractHeadwayGTU>> getTimeStampedFirstFollowers(org.opentrafficsim.core.network.LateralDirectionality lat) throws org.opentrafficsim.core.gtu.behavioralcharacteristics.ParameterException, NullPointerException, IllegalArgumentException
| |
|C|
________\ \______
_ _B_|_ _ _ _ _?_
_ _ _|_ _ _ _ _A_
_____|___________
lat - LEFT or RIGHTorg.opentrafficsim.core.gtu.behavioralcharacteristics.ParameterException - if parameter is not definedNullPointerException - if lat is nullIllegalArgumentException - if lat is NONEpublic final org.opentrafficsim.core.gtu.perception.TimeStampedObject<Boolean> isGtuAlongsideTimeStamped(org.opentrafficsim.core.network.LateralDirectionality lat) throws org.opentrafficsim.core.gtu.behavioralcharacteristics.ParameterException, NullPointerException, IllegalArgumentException
lat - LEFT or RIGHTorg.opentrafficsim.core.gtu.behavioralcharacteristics.ParameterException - if parameter is not definedNullPointerException - if lat is nullIllegalArgumentException - if lat is NONEpublic final org.opentrafficsim.core.gtu.perception.TimeStampedObject<SortedSet<AbstractHeadwayGTU>> getTimeStampedLeaders(RelativeLane lane)
lane - relative lateral lanepublic final org.opentrafficsim.core.gtu.perception.TimeStampedObject<SortedSet<AbstractHeadwayGTU>> getTimeStampedFollowers(RelativeLane lane)
lane - relative lateral lanepublic final void updateLanePathInfo()
throws org.opentrafficsim.core.gtu.GTUException,
org.opentrafficsim.core.network.NetworkException,
org.opentrafficsim.core.gtu.behavioralcharacteristics.ParameterException
org.opentrafficsim.core.gtu.GTUException - when the GTU was not initialized yet.org.opentrafficsim.core.network.NetworkException - when the speed limit for a GTU type cannot be retrieved from the network.org.opentrafficsim.core.gtu.behavioralcharacteristics.ParameterException - in case of not being able to retrieve parameter ParameterTypes.LOOKAHEADpublic final LanePathInfo getLanePathInfo()
public final org.opentrafficsim.core.gtu.perception.TimeStampedObject<LanePathInfo> getTimeStampedLanePathInfo()
Copyright © 2014–2016 Delft University of Technology. All rights reserved.