public class CompleteRouteNavigator extends Object implements RouteNavigator, Serializable
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 CompleteRoute |
completeRoute
The complete route.
|
protected int |
lastVisitedNodeIndex
last visited node on the route.
|
| Constructor and Description |
|---|
CompleteRouteNavigator(CompleteRoute completeRoute)
Create a navigator.
|
| Modifier and Type | Method and Description |
|---|---|
CompleteRoute |
getRoute() |
Node |
lastVisitedNode() |
Node |
nextNodeToVisit()
This method does not advance the route pointer.
|
String |
toString() |
Node |
visitNextNode()
This method does advance the route pointer (if possible).
|
protected final CompleteRoute completeRoute
protected int lastVisitedNodeIndex
public CompleteRouteNavigator(CompleteRoute completeRoute)
completeRoute - the route to followpublic final Node lastVisitedNode() throws NetworkException
lastVisitedNode in interface RouteNavigatorNetworkException - when the index is out of bounds (should never happen).public final Node nextNodeToVisit() throws NetworkException
nextNodeToVisit in interface RouteNavigatorNetworkException - when the index is out of bounds (should never happen).public final Node visitNextNode() throws NetworkException
visitNextNode in interface RouteNavigatorNetworkException - when the index is out of bounds (should never happen).public final CompleteRoute getRoute()
Copyright © 2014–2015 Delft University of Technology. All rights reserved.