Skip to main content

DenseNodeIndex

Trait DenseNodeIndex 

Source
pub trait DenseNodeIndex: DenseElementIndex {
    // 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 DenseElementIndex. Lets graph algorithms allocate per-node scratch storage such as visited sets or distance arrays.

Provided Methods§

Source

fn node_bound(&self) -> usize

Returns the exclusive upper bound for node indexes in this graph view.

Source

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".

Implementors§