PyANGKernel.GKODRoute¶
- class GKODRoute¶
An OD Route is a set of sections that go from an origin centroid to a destination centroid following a route.
Synopsis¶
Methods¶
Virtual methods¶
def
addNode()def
indexOfNode()def
removeNode()def
usesNode()
Note
This documentation may contain snippets that were automatically translated from C++ to Python. We always welcome contributions to the snippet translation. If you see an issue with the translation, you can also let us know by creating a ticket on https:/bugreports.qt.io/projects/PYSIDE
- __init__()¶
- __init__(odroute)
- Parameters:
odroute –
GKODRoute
- __init__(fromCentroid, fromSection, toCentroid, forest, tree, vehicleIndex)
- Parameters:
fromCentroid –
GKCentroidfromSection –
GKSectiontoCentroid –
GKCentroidforest –
BaseForesttree –
NSPPathvehicleIndex – int
- __init__(model, fromCentroidId, fromSectionId, toCentroidId, forest, tree, vehicleIndex)
- Parameters:
model –
GKModelfromCentroidId – int
fromSectionId – int
toCentroidId – int
forest –
BaseForesttree –
NSPPathvehicleIndex – int
- addNode(arg__1[, position=-1])¶
- Parameters:
arg__1 –
GKGeoObjectposition – int
Provided for convenience. Reimplemented only in
GKPedestrianODRoute.This method tries to find a valid origin or destination centroid to set it to this. The whichCentroid parameter sets which one of the two centroids is missing (0 means origin, 1 means destination). It returns false if it couldn’t be fixed.
- getCentroidConfiguration()¶
- Return type:
Returns the centroid configuration for which this OD Route is defined.
- getDestinationCentroid()¶
- Return type:
Returns the destination centroid.
- getOriginCentroid()¶
- Return type:
Returns the origin centroid.
- indexOfNode(arg__1)¶
- Parameters:
arg__1 –
GKGeoObject- Return type:
Provided for convenience. Reimplemented only in
GKPedestrianODRoute.- removeNode(arg__1)¶
- Parameters:
arg__1 –
GKGeoObject
Provided for convenience. Reimplemented only in
GKPedestrianODRoute.- setCentroidConfiguration(cent)¶
- Parameters:
cent –
GKCentroidConfiguration
Sets the centroid configuration for which this OD Route is defined.
- setCentroids(from, to)¶
- Parameters:
from –
GKCentroidto –
GKCentroid
Sets the origin (from) and destination (to) centroids.
- usesNode(arg__1)¶
- Parameters:
arg__1 –
GKGeoObject- Return type:
Provided for convenience. Reimplemented only in
GKPedestrianODRoute.