pub trait WalkableGraph: GraphBase + Sized {
// Provided methods
fn create_node_walk<WalkType: NodeWalk<Self, SubwalkType> + FromIterator<Self::NodeIndex>, SubwalkType: NodeWalk<Self, SubwalkType> + ?Sized>(
&self,
walk: &[Self::NodeIndex],
) -> WalkType { ... }
fn create_empty_node_walk<WalkType: NodeWalk<Self, SubwalkType> + Default, SubwalkType: NodeWalk<Self, SubwalkType> + ?Sized>(
&self,
) -> WalkType { ... }
fn create_edge_walk<WalkType: EdgeWalk<Self, SubwalkType> + FromIterator<Self::EdgeIndex>, SubwalkType: EdgeWalk<Self, SubwalkType> + ?Sized>(
&self,
walk: &[Self::EdgeIndex],
) -> WalkType { ... }
fn create_empty_edge_walk<WalkType: EdgeWalk<Self, SubwalkType> + Default, SubwalkType: EdgeWalk<Self, SubwalkType> + ?Sized>(
&self,
) -> WalkType { ... }
}
Expand description
A helper trait to get the correct walk type from a graph. This is the factory pattern, where a graph is a factory for walks.
Provided Methods§
Sourcefn create_node_walk<WalkType: NodeWalk<Self, SubwalkType> + FromIterator<Self::NodeIndex>, SubwalkType: NodeWalk<Self, SubwalkType> + ?Sized>(
&self,
walk: &[Self::NodeIndex],
) -> WalkType
fn create_node_walk<WalkType: NodeWalk<Self, SubwalkType> + FromIterator<Self::NodeIndex>, SubwalkType: NodeWalk<Self, SubwalkType> + ?Sized>( &self, walk: &[Self::NodeIndex], ) -> WalkType
Create a node-centric walk over the given nodes in this graph.
Sourcefn create_empty_node_walk<WalkType: NodeWalk<Self, SubwalkType> + Default, SubwalkType: NodeWalk<Self, SubwalkType> + ?Sized>(
&self,
) -> WalkType
fn create_empty_node_walk<WalkType: NodeWalk<Self, SubwalkType> + Default, SubwalkType: NodeWalk<Self, SubwalkType> + ?Sized>( &self, ) -> WalkType
Create an empty node-centric walk in this graph.
Sourcefn create_edge_walk<WalkType: EdgeWalk<Self, SubwalkType> + FromIterator<Self::EdgeIndex>, SubwalkType: EdgeWalk<Self, SubwalkType> + ?Sized>(
&self,
walk: &[Self::EdgeIndex],
) -> WalkType
fn create_edge_walk<WalkType: EdgeWalk<Self, SubwalkType> + FromIterator<Self::EdgeIndex>, SubwalkType: EdgeWalk<Self, SubwalkType> + ?Sized>( &self, walk: &[Self::EdgeIndex], ) -> WalkType
Create an edge-centric walk over the given edges in this 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.