pub struct LinkedListGraph<ID = u32, N = (), E = ()> { /* private fields */ }
Expand description
The linked list based graph data structure.
Implementations§
Source§impl<ID, N, E> LinkedListGraph<ID, N, E>
impl<ID, N, E> LinkedListGraph<ID, N, E>
pub fn new() -> LinkedListGraph<ID, N, E>
Trait Implementations§
Source§impl<ID, N, E> Buildable for LinkedListGraph<ID, N, E>
impl<ID, N, E> Buildable for LinkedListGraph<ID, N, E>
Source§impl<ID, N, E> Default for LinkedListGraph<ID, N, E>
impl<ID, N, E> Default for LinkedListGraph<ID, N, E>
Source§impl<'de, ID, N, E> Deserialize<'de> for LinkedListGraph<ID, N, E>
impl<'de, ID, N, E> Deserialize<'de> for LinkedListGraph<ID, N, E>
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl<ID, N, E> Directed for LinkedListGraph<ID, N, E>
impl<ID, N, E> Directed for LinkedListGraph<ID, N, E>
Source§type OutIt<'a> = OutIt<ID>
where
N: 'a,
E: 'a
type OutIt<'a> = OutIt<ID> where N: 'a, E: 'a
Type of a graph iterator over edges leaving a node.
Source§type InIt<'a> = NeighIt<ID>
where
N: 'a,
E: 'a
type InIt<'a> = NeighIt<ID> where N: 'a, E: 'a
Type of a graph iterator over edges entering a node.
Source§type IncidentIt<'a> = NeighIt<ID>
where
N: 'a,
E: 'a
type IncidentIt<'a> = NeighIt<ID> where N: 'a, E: 'a
Type of an iterator over all incident edges.
Source§type DirectedEdge<'a> = <LinkedListGraph<ID, N, E> as GraphType>::Edge<'a>
where
N: 'a,
E: 'a
type DirectedEdge<'a> = <LinkedListGraph<ID, N, E> as GraphType>::Edge<'a> where N: 'a, E: 'a
Type of a directed edge.
Source§fn out_iter(&self, u: Self::Node<'_>) -> Self::OutIt<'_>
fn out_iter(&self, u: Self::Node<'_>) -> Self::OutIt<'_>
Return a graph iterator over the edges leaving a node.
Source§fn in_iter(&self, u: Self::Node<'_>) -> Self::InIt<'_>
fn in_iter(&self, u: Self::Node<'_>) -> Self::InIt<'_>
Return a graph iterator over the edges leaving a node.
Source§fn incident_iter(&self, u: Self::Node<'_>) -> Self::IncidentIt<'_>
fn incident_iter(&self, u: Self::Node<'_>) -> Self::IncidentIt<'_>
Return an iterator over all directed edges incident with a node.
Source§fn outedges(
&self,
u: Self::Node<'_>,
) -> GraphIter<'_, Self, <Self as Directed>::OutIt<'_>> ⓘwhere
Self: Sized,
fn outedges(
&self,
u: Self::Node<'_>,
) -> GraphIter<'_, Self, <Self as Directed>::OutIt<'_>> ⓘwhere
Self: Sized,
Return an iterator over the edges leaving a node.
Source§fn outgoing(&self) -> OutEdges<'_, Self>where
Self: Sized,
fn outgoing(&self) -> OutEdges<'_, Self>where
Self: Sized,
Return access to the outgoing arcs via an
Adjacencies
trait. Read moreSource§fn inedges(
&self,
u: Self::Node<'_>,
) -> GraphIter<'_, Self, <Self as Directed>::InIt<'_>> ⓘwhere
Self: Sized,
fn inedges(
&self,
u: Self::Node<'_>,
) -> GraphIter<'_, Self, <Self as Directed>::InIt<'_>> ⓘwhere
Self: Sized,
Return an iterator over the edges leaving a node.
Source§fn incoming(&self) -> InEdges<'_, Self>where
Self: Sized,
fn incoming(&self) -> InEdges<'_, Self>where
Self: Sized,
Return access to the incoming arcs via an
Adjacencies
trait. Read moreSource§fn incident_edges(
&self,
u: Self::Node<'_>,
) -> GraphIter<'_, Self, <Self as Directed>::IncidentIt<'_>> ⓘwhere
Self: Sized,
fn incident_edges(
&self,
u: Self::Node<'_>,
) -> GraphIter<'_, Self, <Self as Directed>::IncidentIt<'_>> ⓘwhere
Self: Sized,
Return an iterator over all directed edges incident with a node.
Source§impl<ID, N, E> EdgeAttributes<LinkedListGraph<ID, N, E>, E> for LinkedListGraph<ID, N, E>
impl<ID, N, E> EdgeAttributes<LinkedListGraph<ID, N, E>, E> for LinkedListGraph<ID, N, E>
Source§impl<ID, N, E> FiniteDigraph for LinkedListGraph<ID, N, E>
impl<ID, N, E> FiniteDigraph for LinkedListGraph<ID, N, E>
Source§impl<ID, N, E> FiniteGraph for LinkedListGraph<ID, N, E>
impl<ID, N, E> FiniteGraph for LinkedListGraph<ID, N, E>
Source§fn nodes_iter(&self) -> Self::NodeIt<'_>
fn nodes_iter(&self) -> Self::NodeIt<'_>
Return a graph iterator over all nodes.
Source§fn edges_iter(&self) -> Self::EdgeIt<'_>
fn edges_iter(&self) -> Self::EdgeIt<'_>
Return a graph iterator over all edges. Read more
Source§fn enodes(&self, e: Self::Edge<'_>) -> (Self::Node<'_>, Self::Node<'_>)
fn enodes(&self, e: Self::Edge<'_>) -> (Self::Node<'_>, Self::Node<'_>)
Return the nodes connected by an edge. Read more
Source§fn nodes(&self) -> NodeIterator<'_, Self>where
Self: Sized,
fn nodes(&self) -> NodeIterator<'_, Self>where
Self: Sized,
Return an iterator over all nodes.
Source§impl<ID, N, E> GraphIterator<LinkedListGraph<ID, N, E>> for EdgeIt<ID>
impl<ID, N, E> GraphIterator<LinkedListGraph<ID, N, E>> for EdgeIt<ID>
type Item = Edge<ID>
fn next(&mut self, _g: &LinkedListGraph<ID, N, E>) -> Option<Self::Item>
fn size_hint(&self, _g: &LinkedListGraph<ID, N, E>) -> (usize, Option<usize>)
fn count(self, _g: &LinkedListGraph<ID, N, E>) -> usize
fn iter(self, g: &G) -> GraphIter<'_, G, Self> ⓘwhere
G: Sized,
Source§impl<ID, N, E> GraphIterator<LinkedListGraph<ID, N, E>> for NeighIt<ID>
impl<ID, N, E> GraphIterator<LinkedListGraph<ID, N, E>> for NeighIt<ID>
Source§impl<ID, N, E> GraphIterator<LinkedListGraph<ID, N, E>> for NodeIt<ID>
impl<ID, N, E> GraphIterator<LinkedListGraph<ID, N, E>> for NodeIt<ID>
type Item = Node<ID>
fn next(&mut self, _g: &LinkedListGraph<ID, N, E>) -> Option<Self::Item>
fn size_hint(&self, _g: &LinkedListGraph<ID, N, E>) -> (usize, Option<usize>)
fn count(self, _g: &LinkedListGraph<ID, N, E>) -> usize
fn iter(self, g: &G) -> GraphIter<'_, G, Self> ⓘwhere
G: Sized,
Source§impl<ID, N, E> GraphIterator<LinkedListGraph<ID, N, E>> for OutIt<ID>
impl<ID, N, E> GraphIterator<LinkedListGraph<ID, N, E>> for OutIt<ID>
Source§impl<ID, N, E> GraphType for LinkedListGraph<ID, N, E>
impl<ID, N, E> GraphType for LinkedListGraph<ID, N, E>
Source§impl<ID, N, E> IndexGraph for LinkedListGraph<ID, N, E>
impl<ID, N, E> IndexGraph for LinkedListGraph<ID, N, E>
Source§impl<ID, N, E> NodeAttributes<LinkedListGraph<ID, N, E>, N> for LinkedListGraph<ID, N, E>
impl<ID, N, E> NodeAttributes<LinkedListGraph<ID, N, E>, N> for LinkedListGraph<ID, N, E>
Source§impl<ID, N, E> Serialize for LinkedListGraph<ID, N, E>
impl<ID, N, E> Serialize for LinkedListGraph<ID, N, E>
Source§impl<ID, N, E> Undirected for LinkedListGraph<ID, N, E>
impl<ID, N, E> Undirected for LinkedListGraph<ID, N, E>
Source§type NeighIt<'a> = NeighIt<ID>
where
N: 'a,
E: 'a
type NeighIt<'a> = NeighIt<ID> where N: 'a, E: 'a
Type of a graph iterator over all incident edges.
Source§fn neigh_iter(&self, u: Self::Node<'_>) -> Self::NeighIt<'_>
fn neigh_iter(&self, u: Self::Node<'_>) -> Self::NeighIt<'_>
Return a graph iterator over the edges adjacent to some node.
Auto Trait Implementations§
impl<ID, N, E> Freeze for LinkedListGraph<ID, N, E>
impl<ID, N, E> RefUnwindSafe for LinkedListGraph<ID, N, E>
impl<ID, N, E> Send for LinkedListGraph<ID, N, E>
impl<ID, N, E> Sync for LinkedListGraph<ID, N, E>
impl<ID, N, E> Unpin for LinkedListGraph<ID, N, E>
impl<ID, N, E> UnwindSafe for LinkedListGraph<ID, N, E>
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
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more