|
QGIS API Documentation
3.4.15-Madeira (e83d02e274)
|
Strategy for calculating edge cost based on travel time. More...
#include <qgsnetworkspeedstrategy.h>

Public Member Functions | |
| QgsNetworkSpeedStrategy (int attributeId, double defaultValue, double toMetricFactor) | |
| Default constructor. More... | |
| QVariant | cost (double distance, const QgsFeature &f) const override |
| Returns edge cost. More... | |
| QSet< int > | requiredAttributes () const override |
| Returns a list of the source layer attributes needed for cost calculation. More... | |
Public Member Functions inherited from QgsNetworkStrategy | |
| QgsNetworkStrategy ()=default | |
| Default constructor. More... | |
| virtual | ~QgsNetworkStrategy ()=default |
Strategy for calculating edge cost based on travel time.
Should be used for finding fastest path between two points.
Definition at line 29 of file qgsnetworkspeedstrategy.h.
| QgsNetworkSpeedStrategy::QgsNetworkSpeedStrategy | ( | int | attributeId, |
| double | defaultValue, | ||
| double | toMetricFactor | ||
| ) |
Default constructor.
Definition at line 18 of file qgsnetworkspeedstrategy.cpp.
|
overridevirtual |
Returns edge cost.
Implements QgsNetworkStrategy.
Definition at line 25 of file qgsnetworkspeedstrategy.cpp.
|
overridevirtual |
Returns a list of the source layer attributes needed for cost calculation.
This is method called by QgsGraphDirector.
Reimplemented from QgsNetworkStrategy.
Definition at line 39 of file qgsnetworkspeedstrategy.cpp.
1.8.11