Trait Graph

Source
pub trait Graph<T, E, K, V, W, C>: DirectedGraph<T, E, K, V, W, C>
where K: Hash + Eq + Clone, C: Hash + Eq + Clone, W: Add + Sub + Eq + Ord + Copy, T: Vertex<K, V>, E: Edge<K, W, C>,
{ }
Expand description

This trait does not add methods. It just indicates that the graph is not directed.

As such, the vectors returned by the method neighbors(&self, from: &K) and leading_to(&self, to: &K) contains the same keys, eventually in different order (Unless the graph muted between calls).

Also the outcome the methods accepting a pair of keys (adjacent(…), get_edge(…), get_mutable_edge(…)) must not be influenced by the order of the keys.

Implementors§