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
Modifier 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
ConstructorDescriptionConverterListIterator
(ListIterator<F> iter, Converter<F, T> convUp, Converter<T, F> convDown) Constructor. -
Method Summary
Modifier and TypeMethodDescriptionvoid
Return 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.boolean
hasNext()
boolean
next()
int
previous()
int
void
remove()
void
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
-
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:
hasPrevious
in interfaceListIterator<F>
-
previous
- Specified by:
previous
in interfaceListIterator<F>
-
nextIndex
public int nextIndex()- Specified by:
nextIndex
in interfaceListIterator<F>
-
previousIndex
public int previousIndex()- Specified by:
previousIndex
in interfaceListIterator<F>
-
remove
public void remove() -
set
- Specified by:
set
in interfaceListIterator<F>
-
add
- Specified by:
add
in 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
-