pub struct Components { /* private fields */ }Expand description
Which component each node is in.
What counts as a component is the algorithm’s business. wcc() fills this
in with the weakly connected ones, where an edge joins its two ends whichever
way it points, and scc() with the strongly connected ones, where two
nodes are together only if each can be reached from the other. The shape of
the answer is the same either way, and so is the rule about the label.
Implementations§
Source§impl Components
impl Components
Sourcepub fn of(&self, node: u32) -> u32
pub fn of(&self, node: u32) -> u32
The component node is in, named by the lowest numbered node in it.
§Panics
If node is not a node of the snapshot this was computed from.
Sourcepub fn count(&self) -> u32
pub fn count(&self) -> u32
How many components there are, counting an isolated node as its own.
Trait Implementations§
Source§impl Clone for Components
impl Clone for Components
Source§fn clone(&self) -> Components
fn clone(&self) -> Components
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for Components
impl RefUnwindSafe for Components
impl Send for Components
impl Sync for Components
impl Unpin for Components
impl UnsafeUnpin for Components
impl UnwindSafe for Components
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more