|
golib
0.5
|
Running through a Graph. More...
#include <gograph.h>
Public Member Functions | |
| bool | breadthFirst (NodeType *root) |
| BFS. More... | |
| bool | breadthFirstTree (NodeType *root) |
| bool | depthFirstRecursive (NodeType *root) |
| bool | depthFirst (NodeType *root) |
| bool | depthFirstTree (NodeType *root) |
| Same as depthFirst(), plus fills parent fields in the nodes. More... | |
| virtual bool | action (NodeType *node) |
| virtual bool | action (const NodeType *node) const |
Running through a Graph.
NodeType should be derived from goGraphNode or provide the same functionality. EdgeType should be derived from goGraphEdge or provide the same functionality.
|
inline |
BFS.
| root | Node to start at. |
|
inline |
Same as depthFirst(), plus fills parent fields in the nodes.
In order for all nodes to be visited, their status field must be set to NORMAL prior to calling any of the BFS or DFS methods.
| root | Root node (to start with). |
| nodeList | Node list of the complete graph. |