net.sf.collections15
Interface OrderedIterator<E>

All Superinterfaces:
java.util.Iterator<E>
All Known Subinterfaces:
OrderedMapIterator<K,V>
All Known Implementing Classes:
AbstractLinkedList.LinkedListIterator, AbstractLinkedList.LinkedSubListIterator, CursorableLinkedList.Cursor

public interface OrderedIterator<E>
extends java.util.Iterator<E>

Defines an iterator that operates over an ordered collection.

This iterator allows both forward and reverse iteration through the collection.

Since:
Commons Collections 3.0
Version:
$Revision: 1.2 $ $Date: 2004/10/17 01:02:42 $
Author:
Stephen Colebourne

Method Summary
 boolean hasPrevious()
          Checks to see if there is a previous element that can be iterated to.
 E previous()
          Gets the previous element from the collection.
 
Methods inherited from interface java.util.Iterator
hasNext, next, remove
 

Method Detail

hasPrevious

boolean hasPrevious()
Checks to see if there is a previous element that can be iterated to.

Returns:
true if the iterator has a previous element

previous

E previous()
Gets the previous element from the collection.

Returns:
the previous element in the iteration
Throws:
java.util.NoSuchElementException - if the iteration is finished


Copyright © 2001-2005 SourceForge.net. All Rights Reserved.