Module prepona::provide[][src]

Collection of traits that each define a set of functionalities exposed by a graph.

Algorithms only depend on functionalities that are defined in this module and not on specific structures like graphs. This enables us to decouple algorithms from data structures that they receive as input. So you can define your own structure wether it’s a graph, subgraph or an augmented graph and run algorithms defined in algo module on them. All you have to do is to implement the traits that are needed by the algorithm you want to use.

Note

Functions defined in each trait are abstractions of what is expected from the graphs that implement them. For concrete information about why/when these functions may panic or return Err, refer to the specific graph struct that you are using.

Structs

IdMap

Stores a two-way mapping between set of real and virtual ids.

Traits

Edges

Provides access to edges of the graph.

Graph

Provides basic functionalities to store graph information.

Neighbors

Provides access to neighbors of an arbitrary vertex.

Vertices

Provides access to vertices of the graph.