Class ProgressBarWrappedSpliterator<T>

  • All Implemented Interfaces:
    java.lang.AutoCloseable, java.util.Spliterator<T>

    public class ProgressBarWrappedSpliterator<T>
    extends java.lang.Object
    implements java.util.Spliterator<T>, java.lang.AutoCloseable
    Any spliterator whose parallel iteration is tracked by a multi-threaded progress bar.
    Since:
    0.7.2
    Author:
    Tongfei Chen
    • Nested Class Summary

      • Nested classes/interfaces inherited from interface java.util.Spliterator

        java.util.Spliterator.OfDouble, java.util.Spliterator.OfInt, java.util.Spliterator.OfLong, java.util.Spliterator.OfPrimitive<T extends java.lang.Object,​T_CONS extends java.lang.Object,​T_SPLITR extends java.util.Spliterator.OfPrimitive<T,​T_CONS,​T_SPLITR>>
    • Field Summary

      • Fields inherited from interface java.util.Spliterator

        CONCURRENT, DISTINCT, IMMUTABLE, NONNULL, ORDERED, SIZED, SORTED, SUBSIZED
    • Constructor Detail

      • ProgressBarWrappedSpliterator

        public ProgressBarWrappedSpliterator​(java.util.Spliterator<T> underlying,
                                             ProgressBar pb)
    • Method Detail

      • close

        public void close()
        Specified by:
        close in interface java.lang.AutoCloseable
      • tryAdvance

        public boolean tryAdvance​(java.util.function.Consumer<? super T> action)
        Specified by:
        tryAdvance in interface java.util.Spliterator<T>
      • trySplit

        public java.util.Spliterator<T> trySplit()
        Specified by:
        trySplit in interface java.util.Spliterator<T>
      • estimateSize

        public long estimateSize()
        Specified by:
        estimateSize in interface java.util.Spliterator<T>
      • characteristics

        public int characteristics()
        Specified by:
        characteristics in interface java.util.Spliterator<T>
      • getComparator

        public java.util.Comparator<? super T> getComparator()
        Specified by:
        getComparator in interface java.util.Spliterator<T>