forked from KeRNeLith/QuikGraph
-
Notifications
You must be signed in to change notification settings - Fork 0
Using Quikgraph
Alexandre Rabérin edited this page May 12, 2020
·
1 revision
- Add a package reference to
QuikGraphto your project. (<PackageReference Include="QuikGraph" Version="X.Y.Z" />). Or if you're not in an environment supporting NuGet, simply add a reference to theQuikGraph.dllthat fit your constraint target version. - Most data structures are defined under the
QuikGraphnamespace, and algorithms are under theQuikGraph.Algorithmsnamespace.
The vertex type can be any type as all QuikGraph data structure are generic. The edge type must implement the IEdge<TVertex> interface:
class FooVertex {} // Custom vertex type
class FooEdge : Edge<FooVertex> {} // Custom edge type
class FooGraph : AdjacencyGraph<FooVertex, FooEdge> {} // Custom graph type- You can learn more about creating graphs, walking graphs or mutating graphs.