org.jgrapht.alg.cycle

## Interface DirectedSimpleCycles<V,E>

- Type Parameters:
    `V` - the vertex type.
    `E` - the edge type.
  All Known Implementing Classes:
    HawickJamesSimpleCycles, JohnsonSimpleCycles, SzwarcfiterLauerSimpleCycles, TarjanSimpleCycles, TiernanSimpleCycles

      public interface DirectedSimpleCycles<V,E>

  A common interface for classes implementing algorithms for enumeration of the simple cycles of a directed graph.
  Author:
    Nikolay Ognyanov

- - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `List<List<V>>` | `findSimpleCycles()` Finds the simple cycles of the graph. Note that the full algorithm is executed on every call since the graph may have changed between calls.
    `DirectedGraph<V,E>` | `getGraph()` Returns the graph on which the simple cycle search algorithm is executed by this object.
    `void` | `setGraph(DirectedGraph<V,E> graph)` Sets the graph on which the simple cycle search algorithm is executed by this object.

- - ### Method Detail

    - #### getGraph

          DirectedGraph<V,E> getGraph()

      Returns the graph on which the simple cycle search algorithm is executed by this object.
      Returns:
        The graph.

    - #### setGraph

          void setGraph(DirectedGraph<V,E> graph)

      Sets the graph on which the simple cycle search algorithm is executed by this object.
      Parameters:
        `graph` - the graph.
      Throws:
        `IllegalArgumentException` - if the argument is `null`.

    - #### findSimpleCycles

          List<List<V>> findSimpleCycles()

      Finds the simple cycles of the graph.
      Note that the full algorithm is executed on every call since the graph may have changed between calls.
      Returns:
        The list of all simple cycles. Possibly empty but never `null`.
      Throws:
        `IllegalArgumentException` - if the current graph is null.

Copyright © 2016. All rights reserved.