Trait GraphNodesEnumerableInterface

Source
pub trait GraphNodesEnumerableInterface: GraphNodesNominalInterface {
    // Required method
    fn nodes<'a, 'b>(
        &'a self,
    ) -> Box<dyn Iterator<Item = (<Self::NodeHandle as HasId>::Id, &'a Self::NodeHandle)> + 'b>
       where 'a: 'b;

    // Provided method
    fn nnodes(&self) -> usize { ... }
}
Expand description

Graph nodes of which is possible to enumerate.

Required Methods§

Source

fn nodes<'a, 'b>( &'a self, ) -> Box<dyn Iterator<Item = (<Self::NodeHandle as HasId>::Id, &'a Self::NodeHandle)> + 'b>
where 'a: 'b,

Iterate over all nodes.

Provided Methods§

Source

fn nnodes(&self) -> usize

Number of nodes. Order of the graph.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§

Source§

impl<NodeId, EdgeId, Kind> GraphNodesEnumerableInterface for CellNodeFactory<NodeId, EdgeId, Kind>

Source§

impl<NodeId, EdgeId, Kind> GraphNodesEnumerableInterface for NodeFactory<NodeId, EdgeId, Kind>