Class DirectedCycle

java.lang.Object
fr.gouv.vitam.common.graph.DirectedCycle

public class DirectedCycle extends Object
DirectedCycle Class
  • Constructor Details

    • DirectedCycle

      public DirectedCycle(DirectedGraph graph)
      DirectedCycle a constructor :fired when a cycle is found.
      Parameters:
      graph - the DirectedCycle
      Throws:
      CycleFoundException
  • Method Details

    • hasCycle

      public boolean hasCycle()
      Does the DirectedCycle have a directed cycle
      Returns:
      true if the Graph has a directed cycle, false otherwise
    • isCyclic

      public boolean isCyclic()
      isCyclic know of a graph is cyclic or not
      Returns:
      boolean
    • getCycle

      public Stack<Integer> getCycle()
      Return the directed cycle if isCyclic
      Returns:
      the directed cycle or null