code: public static <T> void verify(Vertex<T> vertex) throws CyclicDependencyException
      {
          // We need a list of vertices that contains the entire graph, so build it.
          List<Vertex<T>> vertices = new ArrayList<Vertex<T>>();
          addDependencies(vertex, vertices);
  
          verify(vertices);
      }
docs: Verify that a vertex and its set of dependencies have no cycles.
  
  @param vertex  The vertex we want to test.
  
  @throws CyclicDependencyException  if there is a cycle.