Interface Graph.Visitor<U>

Type Parameters:
U - the type of the node
Enclosing class:
Graph<DataT,NodeT extends Node<DataT,NodeT>>

protected static interface Graph.Visitor<U>
Represents a visitor to be implemented by the consumer who want to visit the graph's nodes in DFS order by calling visit method.
  • Method Details

    • visitNode

      void visitNode(U node)
      visit a node.
      Parameters:
      node - the node to visited
    • visitEdge

      void visitEdge(String fromKey, String toKey, Graph.EdgeType edgeType)
      visit an edge.
      Parameters:
      fromKey - key of the from node
      toKey - key of the to node
      edgeType - the edge type