Interface Output
-
- All Superinterfaces:
java.lang.AutoCloseable
- All Known Implementing Classes:
ContiguousOutputChunker,CycleLogOutput,CycleResultsRLEBufferTarget,LoggingOutput,ReorderingConcurrentResultBuffer
public interface Output extends java.lang.AutoCloseableA cycle marker 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 Summary
Modifier and Type Method Description default voidclose()booleanonCycleResult(long completedCycle, int result)Mark the result of the numbered cycle with an integer value.default booleanonCycleResult(CycleResult result)default voidonCycleResultSegment(CycleResultsSegment segment)
-
-
-
Method Detail
-
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 java.lang.Exception- Specified by:
closein interfacejava.lang.AutoCloseable- Throws:
java.lang.Exception
-
-