Interface GraphAlgorithmsInterface<T>

All Known Implementing Classes:
GraphAlgorithms

public interface GraphAlgorithmsInterface<T>
An interface of methods that process graphs.
Author:
Lindsay Kislingbury, Lea Wiranatha
  • Method Details

    • getBreadthFirstTraversal

      QueueInterface<T> getBreadthFirstTraversal(T origin)
      Performs a breadth-first traversal of this graph.
      Parameters:
      origin - An object that labels the origin vertex of the traversal.
      Returns:
      A queue of labels of the vertices in the traversal, with the label of the origin vertex at the queue's front.
    • getDepthFirstTraversal

      QueueInterface<T> getDepthFirstTraversal(T origin)
      Performs a depth-first traversal of this graph.
      Parameters:
      origin - An object that labels the origin vertex of the traversal.
      Returns:
      A queue of labels of the vertices in the traversal, with the label of the origin vertex at the queue's front.