Interface BaseCacheStream.SegmentCompletionListener

All Superinterfaces:
Consumer<Supplier<PrimitiveIterator.OfInt>>
Enclosing interface:
BaseCacheStream<T,S extends BaseStream<T,S>>
Functional Interface:
This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.

@FunctionalInterface public static interface BaseCacheStream.SegmentCompletionListener extends Consumer<Supplier<PrimitiveIterator.OfInt>>
Functional interface that is used as a callback when segments are completed. Please see BaseCacheStream.segmentCompletionListener(SegmentCompletionListener) for more details.
Since:
9.0
Author:
wburns
  • Method Summary

    Modifier and Type
    Method
    Description
    default void
    Invoked each time a given number of segments have completed and the terminal operation has consumed all entries in the given segment
    void
    Deprecated.
    This method requires boxing for each segment.

    Methods inherited from interface java.util.function.Consumer

    andThen
  • Method Details

    • segmentCompleted

      @Deprecated void segmentCompleted(Set<Integer> segments)
      Deprecated.
      This method requires boxing for each segment. Please use accept(Supplier) instead
      Method invoked when the segment has been found to be consumed properly by the terminal operation.
      Parameters:
      segments - The segments that were completed
    • accept

      default void accept(Supplier<PrimitiveIterator.OfInt> segments)
      Invoked each time a given number of segments have completed and the terminal operation has consumed all entries in the given segment
      Specified by:
      accept in interface Consumer<Supplier<PrimitiveIterator.OfInt>>
      Parameters:
      segments - The segments that were completed