| Constructor and Description |
|---|
UniqueIterator(Iterator<? extends E> iterator)
Constructor.
|
UniqueIterator(Iterator<? extends E> iterator,
Comparator<? super E> comparator)
Constructor.
|
public UniqueIterator(Iterator<? extends E> iterator)
Object.equals(java.lang.Object) is used to detect duplicates.iterator - wrapped Iteratorpublic UniqueIterator(Iterator<? extends E> iterator, Comparator<? super E> comparator)
Comparator is used to detect duplicates.iterator - wrapped Iteratorcomparator - used to compare consecutive valuesIllegalArgumentException - if comparator is nullCopyright © 2016. All rights reserved.