![JAR search and dependency download from the Maven repository](/logo.png)
net.lenni0451.commons.collections.iterators.DelegateIterator Maven / Gradle / Ivy
package net.lenni0451.commons.collections.iterators;
import java.util.Iterator;
/**
* An iterator which delegates all calls to the given iterator.
*
* @param The type of the elements in this iterator
*/
public class DelegateIterator implements Iterator {
private final Iterator delegate;
public DelegateIterator(final Iterator delegate) {
this.delegate = delegate;
}
@Override
public boolean hasNext() {
return this.delegate.hasNext();
}
@Override
public E next() {
return this.delegate.next();
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy