API Overview API Index Package Overview Direct link to this page
JDK 1.6
  java.util. ListIterator View Source
Author(s)
Josh Bloch
Since
1.2
Version
1.28, 04/21/06
Serial
Hierarchy
 Iterator
      ListIterator
Subinterfaces
Description
public interface ListIterator
  An iterator for lists that allows the programmer to traverse the list in either direction, modify the list during iteration, and obtain the iterator's current position in the list.
Methods
Hide/Show inherited methods
public void add ( E e)
  Inserts the specified element into the list (optional operation).
public boolean hasNext () [Specified in Iterator]
  Returns true if this list iterator has more elements when traversing the list in the forward direction.
public boolean hasPrevious ()
  Returns true if this list iterator has more elements when traversing the list in the reverse direction.
public E next () [Specified in Iterator]
  Returns the next element in the list.
public int nextIndex ()
  Returns the index of the element that would be returned by a subsequent call to next.
public E previous ()
  Returns the previous element in the list.
public int previousIndex ()
  Returns the index of the element that would be returned by a subsequent call to previous.
public void remove () [Specified in Iterator]
  Removes from the list the last element that was returned by next or previous (optional operation).
public void set ( E e)
  Replaces the last element returned by next or previous with the specified element (optional operation).
Fields
Hide/Show inherited fields
Generated By: JavaOnTracks Doclet 0.1.4     ©Thibaut Colar