Class: QgsNetworkDistanceStrategy

Strategy for calculating edge cost based on its length. Should be used for finding shortest path between two points.

Class Hierarchy

Inheritance diagram of qgis.analysis.QgsNetworkDistanceStrategy

Base classes

QgsNetworkStrategy

QgsNetworkStrategy defines strategy used for calculation of the edge cost. For example it can take into account travel distance, amount of time or money. Currently there are two strategies implemented in the analysis library: QgsNetworkDistanceStrategy and QgsNetworkSpeedStrategy. QgsNetworkStrategy implemented using “strategy” design pattern.

class qgis.analysis.QgsNetworkDistanceStrategy[source]

Bases: QgsNetworkStrategy