Expand description
§generic_graph
generic_graph
defines a series of traits for the implementation of either directed and
non directed graphs. This library also provides a few default implementation if the programmer
doesn’t have special requirements for his graphs.
All traits make large use of generic types, allowing for deep customization of the graph structure
Modules§
- adjacency_
list - This module provide an implementation of a growable directed graph. The graph is implemented as a set of adjacency list (list of vertex adjacent to one vertex).
Structs§
- Simple
Vertex - A default implementation for vertexes. This implementation should be suitable for most of the problem one can encounter requiring graph.
Enums§
- Edge
Side EdgeSide
is used to indicate which side of the edge caused an error. Usually returned as Result::Err(EdgeSide) by the VariableEdges::add_edge() method when it was impossible to add the edge due to the absence of one of the concerned vertexes.
Traits§
- Directed
Graph - This trait define the behaviour of a directed graph it requires the for vertexes (T), edges (E), vertex’s keys (K), vertex’s values (v), edge’s weights (W) and edge’s keys (C)
- Edge
- Generic behaviour of an edge
- Graph
- This trait does not add methods. It just indicates that the graph is not directed.
- Variable
Edges - This trait adds to a Directed graph the methods to add and remove edges
- Variable
Vertexes - This trait adds to a Directed graph the methods to add and remove edges
- Vertex
- Generic behaviour of a vertex