fn create_index<N: Idx + Ord>(
num_nodes: usize,
sorted_edge_sources: &mut dyn Iterator<Item = N>,
associated_edge_targets: &mut dyn Iterator<Item = N>,
edge_targets: &mut Vec<N>,
node_starts: &mut IndexVec<N, usize>,
)
Expand description
Creates/initializes the index for the VecGraph
. A helper for VecGraph::new
.
num_nodes
is the target number of nodes in the graphsorted_edge_sources
are the edge sources, sortedassociated_edge_targets
are the edge targets in the same order as sourcesedge_targets
is the vec of targets to be extendednode_starts
is the index to be filled