Author: bayard Date: Tue Sep 15 05:56:29 2009 New Revision: 815091 URL: http://svn.apache.org/viewvc?rev=815091&view=rev Log: Merging from -r468106:814127 of collections_jdk5_branch - namely where this code was generified; mostly in r738956.
Also see the following revisions: ------------------------------------------------------------------------ r751849 | mbenson | 2009-03-09 14:32:22 -0700 (Mon, 09 Mar 2009) | 1 line comment ------------------------------------------------------------------------ Modified: commons/proper/collections/trunk/src/java/org/apache/commons/collections/OrderedIterator.java Modified: commons/proper/collections/trunk/src/java/org/apache/commons/collections/OrderedIterator.java URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/java/org/apache/commons/collections/OrderedIterator.java?rev=815091&r1=815090&r2=815091&view=diff ============================================================================== --- commons/proper/collections/trunk/src/java/org/apache/commons/collections/OrderedIterator.java (original) +++ commons/proper/collections/trunk/src/java/org/apache/commons/collections/OrderedIterator.java Tue Sep 15 05:56:29 2009 @@ -17,18 +17,21 @@ package org.apache.commons.collections; import java.util.Iterator; +import java.util.ListIterator; +import java.util.NoSuchElementException; /** - * Defines an iterator that operates over an ordered collection. + * Defines an iterator that operates over an ordered container. Subset of {...@link ListIterator}. * <p> - * This iterator allows both forward and reverse iteration through the collection. - * + * This iterator allows both forward and reverse iteration through the container. + * + * @param <E> the type to iterate over * @since Commons Collections 3.0 * @version $Revision$ $Date$ * * @author Stephen Colebourne */ -public interface OrderedIterator extends Iterator { +public interface OrderedIterator<E> extends Iterator<E> { /** * Checks to see if there is a previous element that can be iterated to. @@ -38,11 +41,11 @@ boolean hasPrevious(); /** - * Gets the previous element from the collection. + * Gets the previous element from the container. * * @return the previous element in the iteration - * @throws java.util.NoSuchElementException if the iteration is finished + * @throws NoSuchElementException if the iteration is finished */ - Object previous(); + E previous(); }