Class MultiTargetBFS

Inheritance Relationships

Base Type

Class Documentation

class MultiTargetBFS : public NetworKit::STSP

Computes the shortest-path distance from a single source to multiple targets in unweighted graphs.

Public Functions

template<class InputIt>
inline MultiTargetBFS(const Graph &G, node source, InputIt targetsFirst, InputIt targetsLast)

Creates the MultiTargetBFS class for a graph G, source node source, and multiple target nodes.

Parameters:
  • G – The graph.

  • source – The source node.

  • targetsFirst, targetsLast – Range of target nodes.

virtual void run() override

The generic run method which calls runImpl() and takes care of setting hasRun to the appropriate value.