[−][src]Struct algorithms_edu::graph::UnweightedAdjacencyList
Implementations
impl UnweightedAdjacencyList
[src]
pub fn is_isomorphic_with(&self, other: &UnweightedAdjacencyList) -> bool
[src]
impl UnweightedAdjacencyList
[src]
pub fn with_size(n: usize) -> Self
[src]
Initialize an empty adjacency list that can hold up to n nodes.
pub fn len(&self) -> usize
[src]
Number of nodes
pub fn is_empty(&self) -> bool
[src]
pub fn add_directed_edge(&mut self, u: usize, v: usize)
[src]
Add a directed edge from node u
to node v
pub fn add_undirected_edge(&mut self, u: usize, v: usize)
[src]
Add an undirected edge between nodes u
and v
.
Trait Implementations
impl Index<usize> for UnweightedAdjacencyList
[src]
type Output = Vec<usize>
The returned type after indexing.
pub fn index(&self, index: usize) -> &Self::Output
[src]
impl TreeCenter for UnweightedAdjacencyList
[src]
Auto Trait Implementations
impl RefUnwindSafe for UnweightedAdjacencyList
impl Send for UnweightedAdjacencyList
impl Sync for UnweightedAdjacencyList
impl Unpin for UnweightedAdjacencyList
impl UnwindSafe for UnweightedAdjacencyList
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,