Interface Output

All Superinterfaces:
AutoCloseable
All Known Implementing Classes:
ContiguousOutputChunker, CycleLogOutput, CycleResultsRLEBufferTarget, LoggingOutput, ReorderingConcurrentResultBuffer

public interface Output extends AutoCloseable
A cycle output is simply a type that knows how to do something useful with the result of a particular cycle. Outputs are required to be thread-safe.
  • Method Details

    • onCycleResult

      boolean onCycleResult(long completedCycle, int result)
      Mark the result of the numbered cycle with an integer value. The meaning of the value provided is contextual to the way it is used. (Each process will have its own status tables, etc.)
      Parameters:
      completedCycle - The cycle number being marked.
      result - the result ordinal
      Returns:
      true on success, false if the marking should be retried differently
    • onCycleResult

      default boolean onCycleResult(CycleResult result)
    • onCycleResultSegment

      default void onCycleResultSegment(CycleResultsSegment segment)
    • close

      default void close() throws Exception
      Specified by:
      close in interface AutoCloseable
      Throws:
      Exception