java.util
Interface Iterator<E>

Type Parameters:
E - type of the elements
All Known Subinterfaces:
ListIterator<E>

public interface Iterator<E>

An iterator over a collection. Iterator takes the place of Enumeration in the Java collections framework

Author:
Juan Antonio Brena Moral, Sven Köhler

Method Summary
 boolean hasNext()
           
 E next()
           
 void remove()
          Removes from the underlying collection the last element returned by the iterator (optional operation).
 

Method Detail

hasNext

boolean hasNext()
Returns:
Returns true if the iteration has more elements.

next

E next()
Returns:
Returns the next element in the interation.

remove

void remove()
Removes from the underlying collection the last element returned by the iterator (optional operation).