Class CountingIterator<T>
- java.lang.Object
-
- org.apache.commons.collections4.iterators.AbstractUntypedIteratorDecorator<E,E>
-
- org.apache.commons.collections4.iterators.AbstractIteratorDecorator<T>
-
- com.norconex.commons.lang.collection.CountingIterator<T>
-
- Type Parameters:
T- iterator type
- All Implemented Interfaces:
Iterator<T>
public class CountingIterator<T> extends AbstractIteratorDecorator<T>
Counts the number of timenext()was invoked.- Since:
- 2.0.0
- Author:
- Pascal Essiembre
-
-
Constructor Summary
Constructors Constructor Description CountingIterator(Iterator<T> iterator)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description intgetCount()Tnext()-
Methods inherited from class org.apache.commons.collections4.iterators.AbstractUntypedIteratorDecorator
getIterator, hasNext, remove
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface java.util.Iterator
forEachRemaining
-
-