public class RandomLaneBasedRouteNavigator extends AbstractLaneBasedRouteNavigator
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.
$LastChangedDate: 2015-07-16 10:20:53 +0200 (Thu, 16 Jul 2015) $, @version $Revision: 1124 $, by $Author: pknoppers $,
initial version Jul 22, 2015
| Modifier and Type | Field and Description |
|---|---|
protected org.opentrafficsim.core.network.Node |
lastVisitedNode
last visited node on the route (given -- I have been there).
|
protected org.opentrafficsim.core.network.Link |
nextNextLinkToVisit
link to take after the next node to visit on the route (look ahead to choose the right lane).
|
protected org.opentrafficsim.core.network.Node |
nextNextNodeToVisit
node to take after the next node to visit on the route (look ahead to choose the right lane).
|
protected org.opentrafficsim.core.network.Node |
nextNodeToVisit
next node to visit on the route (given -- I am on this route).
|
GETOFFTHISLANENOW, NOLANECHANGENEEDED| Constructor and Description |
|---|
RandomLaneBasedRouteNavigator(org.opentrafficsim.core.network.Link generationLink)
Create a navigator.
|
| Modifier and Type | Method and Description |
|---|---|
protected void |
determineNextNextNode()
Choose a random link out.
|
org.opentrafficsim.core.network.Node |
lastVisitedNode() |
org.opentrafficsim.core.network.Node |
nextNextNodeToVisit() |
org.opentrafficsim.core.network.Node |
nextNodeToVisit() |
org.djunits.value.vdouble.scalar.Length.Rel |
suitability(Lane lane,
org.djunits.value.vdouble.scalar.Length.Rel longitudinalPosition,
LaneBasedGTU gtu,
org.djunits.value.vdouble.scalar.Time.Rel timeHorizon)
Determine the suitability of being at a particular longitudinal position in a particular Lane for following this Route.
|
org.opentrafficsim.core.network.Node |
visitNextNode() |
computeSuitabilityWithLaneChanges, countCompatibleLanesprotected org.opentrafficsim.core.network.Node lastVisitedNode
protected org.opentrafficsim.core.network.Node nextNodeToVisit
protected org.opentrafficsim.core.network.Node nextNextNodeToVisit
protected org.opentrafficsim.core.network.Link nextNextLinkToVisit
public RandomLaneBasedRouteNavigator(org.opentrafficsim.core.network.Link generationLink)
generationLink - the link on which the GTU is generatedpublic final org.opentrafficsim.core.network.Node lastVisitedNode()
throws org.opentrafficsim.core.network.NetworkException
org.opentrafficsim.core.network.NetworkExceptionpublic final org.opentrafficsim.core.network.Node nextNodeToVisit()
throws org.opentrafficsim.core.network.NetworkException
org.opentrafficsim.core.network.NetworkExceptionpublic final org.opentrafficsim.core.network.Node nextNextNodeToVisit()
public final org.opentrafficsim.core.network.Node visitNextNode()
throws org.opentrafficsim.core.network.NetworkException
org.opentrafficsim.core.network.NetworkExceptionprotected void determineNextNextNode()
public final org.djunits.value.vdouble.scalar.Length.Rel suitability(Lane lane, org.djunits.value.vdouble.scalar.Length.Rel longitudinalPosition, LaneBasedGTU gtu, org.djunits.value.vdouble.scalar.Time.Rel timeHorizon) throws org.opentrafficsim.core.network.NetworkException
lane - Lane; the lane to considerlongitudinalPosition - DoubleScalar.Rel<LengthUnit>; the longitudinal position in the lanegtu - GTU; the GTU (used to check lane compatibility of lanes, and current lane the GTU is on)timeHorizon - DoubleScalar.Rel<TimeUnit>; the maximum time that a driver may want to look aheadorg.opentrafficsim.core.network.NetworkException - on network inconsistency, or when the continuation Link at a branch cannot be determinedCopyright © 2014–2015 Delft University of Technology. All rights reserved.