GraphTraversal
com.phasmidsoftware.gryphon.traverse.GraphTraversal
A family of graph traversal algorithms unified under a single abstraction.
All four classic algorithms — DFS, BFS, Dijkstra, Prim — share the same underlying Traversal engine from Visitor. They differ only in:
- the frontier type (Stack, Queue, IndexedPrioQueue)
- the frontier element type (V for DFS/BFS, (E,V) for Dijkstra/Prim)
- the cost-update strategy (none, cumulative, edge-only)
Type parameters
- E
-
the edge-attribute type (Unit for DFS/BFS)
- R
-
the result type recorded per vertex
- V
-
the vertex type
Attributes
- Graph
-
- Supertypes
-
class Objecttrait Matchableclass Any
- Known subtypes
-
class BFSTraversal[V]class DFSTraversal[V]
Members list
In this article