janino.net

org.codehaus.janino.util.iterator
Class ReverseListIterator<T>

java.lang.Object
  extended by org.codehaus.janino.util.iterator.FilterListIterator<T>
      extended by org.codehaus.janino.util.iterator.ReverseListIterator<T>
Type Parameters:
T - The element type of the list iterator
All Implemented Interfaces:
Iterator<T>, ListIterator<T>

public class ReverseListIterator<T>
extends FilterListIterator<T>

A ListIterator that reverses the direction of all operations of a delegate ListIterator.


Field Summary
 
Fields inherited from class org.codehaus.janino.util.iterator.FilterListIterator
delegate
 
Constructor Summary
ReverseListIterator(ListIterator<T> delegate)
           
 
Method Summary
 boolean hasNext()
          Calls FilterListIterator.delegate.
 boolean hasPrevious()
          Calls FilterListIterator.delegate.
 T next()
          Calls FilterListIterator.delegate.
 int nextIndex()
          Throws an UnsupportedOperationException.
 T previous()
          Calls FilterListIterator.delegate.
 int previousIndex()
          Throws an UnsupportedOperationException.
 
Methods inherited from class org.codehaus.janino.util.iterator.FilterListIterator
add, remove, set
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ReverseListIterator

public ReverseListIterator(ListIterator<T> delegate)
Method Detail

hasNext

public boolean hasNext()
Calls FilterListIterator.delegate.ListIterator.hasPrevious()

Specified by:
hasNext in interface Iterator<T>
Specified by:
hasNext in interface ListIterator<T>
Overrides:
hasNext in class FilterListIterator<T>

hasPrevious

public boolean hasPrevious()
Calls FilterListIterator.delegate.ListIterator.hasNext()

Specified by:
hasPrevious in interface ListIterator<T>
Overrides:
hasPrevious in class FilterListIterator<T>

next

public T next()
Calls FilterListIterator.delegate.ListIterator.previous()

Specified by:
next in interface Iterator<T>
Specified by:
next in interface ListIterator<T>
Overrides:
next in class FilterListIterator<T>

previous

public T previous()
Calls FilterListIterator.delegate.ListIterator.next()

Specified by:
previous in interface ListIterator<T>
Overrides:
previous in class FilterListIterator<T>

nextIndex

public int nextIndex()
Throws an UnsupportedOperationException.

Specified by:
nextIndex in interface ListIterator<T>
Overrides:
nextIndex in class FilterListIterator<T>

previousIndex

public int previousIndex()
Throws an UnsupportedOperationException.

Specified by:
previousIndex in interface ListIterator<T>
Overrides:
previousIndex in class FilterListIterator<T>

janino.net