Trait SwhBackwardGraph

Source
pub trait SwhBackwardGraph: SwhGraph {
    type Predecessors<'succ>: IntoIterator<Item = usize>
       where Self: 'succ;

    // Required methods
    fn predecessors(&self, node_id: NodeId) -> Self::Predecessors<'_>;
    fn indegree(&self, node_id: NodeId) -> usize;
}

Required Associated Types§

Source

type Predecessors<'succ>: IntoIterator<Item = usize> where Self: 'succ

Required Methods§

Source

fn predecessors(&self, node_id: NodeId) -> Self::Predecessors<'_>

Return an IntoIterator over the predecessors of a node.

Source

fn indegree(&self, node_id: NodeId) -> usize

Return the number of predecessors of a node.

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<G: SwhBackwardGraph> SwhBackwardGraph for GraphSpy<G>

Source§

type Predecessors<'succ> = <G as SwhBackwardGraph>::Predecessors<'succ> where Self: 'succ

Source§

impl<G: SwhBackwardGraph, NodeFilter: Fn(usize) -> bool, ArcFilter: Fn(usize, usize) -> bool> SwhBackwardGraph for Subgraph<G, NodeFilter, ArcFilter>

Source§

type Predecessors<'succ> = FilteredPredecessors<'succ, <<G as SwhBackwardGraph>::Predecessors<'succ> as IntoIterator>::IntoIter, NodeFilter, ArcFilter> where Self: 'succ

Source§

impl<G: SwhForwardGraph> SwhBackwardGraph for Transposed<G>

Source§

type Predecessors<'succ> = <G as SwhForwardGraph>::Successors<'succ> where Self: 'succ

Source§

impl<P, FG: UnderlyingGraph, BG: UnderlyingGraph> SwhBackwardGraph for SwhBidirectionalGraph<P, FG, BG>

Source§

type Predecessors<'succ> = <BG as UnderlyingGraph>::UnlabeledSuccessors<'succ> where Self: 'succ

Source§

impl<T: Deref> SwhBackwardGraph for T
where <T as Deref>::Target: SwhBackwardGraph,

Source§

type Predecessors<'succ> = <<T as Deref>::Target as SwhBackwardGraph>::Predecessors<'succ> where Self: 'succ