Package com.tangosol.util
Class ConverterCollections.ConverterListIterator<F,T>
java.lang.Object
com.tangosol.util.ConverterCollections.ConverterListIterator<F,T>
- Type Parameters:
F- the type of elements in the underlying ListIteratorT- the type that the elements should be converted to
- All Implemented Interfaces:
Iterator<T>,ListIterator<T>
- Enclosing class:
- ConverterCollections
public static class ConverterCollections.ConverterListIterator<F,T>
extends Object
implements ListIterator<T>
A Converter ListIterator views an underlying ListIterator through a
Converter.
-
Field Summary
FieldsModifier and TypeFieldDescriptionThe Converter from this ListIterator to the underlying ListIterator.The Converter from the underlying ListIterator to this ListIterator.protected final ListIterator<F>The underlying ListIterator. -
Constructor Summary
ConstructorsConstructorDescriptionConverterListIterator(ListIterator<F> iter, Converter<F, T> convUp, Converter<T, F> convDown) Constructor. -
Method Summary
Modifier and TypeMethodDescriptionvoidReturn the Converter used to pass values down to the underlying ListIterator.Return the Converter used to view the underlying ListIterator's values through.Return the underlying ListIterator.booleanhasNext()booleannext()intprevious()intvoidremove()voidMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface java.util.Iterator
forEachRemaining
-
Field Details
-
m_iter
The underlying ListIterator. -
m_convUp
The Converter from the underlying ListIterator to this ListIterator. -
m_convDown
The Converter from this ListIterator to the underlying ListIterator.
-
-
Constructor Details
-
ConverterListIterator
Constructor.- Parameters:
iter- the underlying ListIteratorconvUp- the Converter from the underlying ListIteratorconvDown- the Converter to the underlying ListIterator
-
-
Method Details
-
hasNext
public boolean hasNext() -
next
-
hasPrevious
public boolean hasPrevious()- Specified by:
hasPreviousin interfaceListIterator<F>
-
previous
- Specified by:
previousin interfaceListIterator<F>
-
nextIndex
public int nextIndex()- Specified by:
nextIndexin interfaceListIterator<F>
-
previousIndex
public int previousIndex()- Specified by:
previousIndexin interfaceListIterator<F>
-
remove
public void remove() -
set
- Specified by:
setin interfaceListIterator<F>
-
add
- Specified by:
addin interfaceListIterator<F>
-
getListIterator
Return the underlying ListIterator.- Returns:
- the underlying ListIterator
-
getConverterUp
Return the Converter used to view the underlying ListIterator's values through.- Returns:
- the Converter from the underlying ListIterator
-
getConverterDown
Return the Converter used to pass values down to the underlying ListIterator.- Returns:
- the Converter to the underlying ListIterator
-