weakly_connected_components

Function weakly_connected_components 

Source
pub fn weakly_connected_components(
    graph: &OsmGraph,
    nodes: &[OsmNodeId],
) -> Result<Vec<Vec<OsmNodeId>>, OsmError>
Expand description

runs a synchronous weakly-connected components algorithm over the directed graph.

§Arguments

  • fwd - forward traversal segments, the “out-edges” of the nodes
  • rev - reverse traversal segments, the “in-edges” of the nodes
  • nodes - the graph nodes included to find components. this can either be the complete set or a subset.

§Result

a vector of each found component as a node list