pub trait NodeIndex: ElementIndex {
// Provided methods
fn node_bound(&self) -> usize { ... }
fn node_index(&self, node: Self::ElementId) -> usize { ... }
}Expand description
Dense node-index capability for graph views.
Graph-facing name for ElementIndex. Lets graph algorithms allocate
per-node scratch storage such as visited sets or distance arrays.
Provided Methods§
Sourcefn node_bound(&self) -> usize
fn node_bound(&self) -> usize
Returns the exclusive upper bound for node indexes in this graph view.
Sourcefn node_index(&self, node: Self::ElementId) -> usize
fn node_index(&self, node: Self::ElementId) -> usize
Returns the dense index for node in this graph view.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".