org.gjt.rec.util
Class ArrayIterator

java.lang.Object
  |
  +--org.gjt.rec.util.ArrayIterator
All Implemented Interfaces:
Iterator

public class ArrayIterator
extends Object
implements Iterator

An Iterator that iterates over the elements of an array.

Author:
Neil Stockbridge

Field Summary
static String REVISION
           
 
Constructor Summary
ArrayIterator(Object array)
          Constructs a new array iterator that can iterate over the elements of an array.
 
Method Summary
 boolean hasNext()
           
 Object next()
           
 void remove()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

REVISION

public static final String REVISION
See Also:
Constant Field Values
Constructor Detail

ArrayIterator

public ArrayIterator(Object array)
Constructs a new array iterator that can iterate over the elements of an array.

Parameters:
array - the array with the elements to iterate over
Throws:
IllegalArgumentException - if the specified reference is null or if it is not null but does not refer to an array.
Method Detail

hasNext

public boolean hasNext()
Specified by:
hasNext in interface Iterator

next

public Object next()
Specified by:
next in interface Iterator

remove

public void remove()
Specified by:
remove in interface Iterator