code: public static <T> Spliterator<T> wrap(Spliterator<T> sp, ProgressBarBuilder pbb) {
          long size = sp.getExactSizeIfKnown();
          if (size != -1)
              pbb.setInitialMax(size);
          return new ProgressBarWrappedSpliterator<>(sp, pbb.build());
      }
docs: Wraps a {@link Spliterator} so that when iterated, a progress bar is shown to track the traversal progress.
  For this function the progress bar can be fully customized by using a {@link ProgressBarBuilder}.
  @param sp Underlying spliterator
  @param pbb An instance of a {@link ProgressBarBuilder}