@Override
    public T next() {
      if (!hasNext()) {
        throw new NoSuchElementException();
      }
      currentCount.incrementAndGet();
      return wrappedIterator.next();
    }
Wraps a {@link ClosableIterator} to only return the specified number of values

@param <T> the type of values in the iterator
samza-core/src/main/java/org/apache/samza/operators/impl/store/TimeSeriesStoreImpl.java