QgsGraphDirector class

Determine making the graph.

Contents

QgsGraphBuilder and QgsGraphDirector implemented using "builder" design patter.

Derived classes

class QgsVectorLayerDirector
Determine making the graph from vector line layer.

Public functions

void addStrategy(QgsNetworkStrategy* prop)
Add optimization strategy.
void makeGraph(QgsGraphBuilderInterface* builder, const QVector<QgsPointXY>& additionalPoints, QVector<QgsPointXY>& snappedPoints, QgsFeedback* feedback = nullptr) const virtual
Make a graph using QgsGraphBuilder.
auto name() const -> QString pure virtual
Returns director name.

Function documentation

void QgsGraphDirector::makeGraph(QgsGraphBuilderInterface* builder, const QVector<QgsPointXY>& additionalPoints, QVector<QgsPointXY>& snappedPoints, QgsFeedback* feedback = nullptr) const virtual

Make a graph using QgsGraphBuilder.

Parameters
builder the graph builder
additionalPoints list of points that should be snapped to the graph
snappedPoints list of snapped points
feedback feedback object for reporting progress