net.sourceforge.jaulp.collections.iterators
Class ArrayIterator<E>

java.lang.Object
  extended by net.sourceforge.jaulp.collections.iterators.ArrayIterator<E>
All Implemented Interfaces:
java.util.Iterator<E>

public class ArrayIterator<E>
extends java.lang.Object
implements java.util.Iterator<E>

An Iterator for an Array.

Author:
Asterios Raptis

Constructor Summary
ArrayIterator(E[] array)
          Default constructor.
 
Method Summary
 boolean hasNext()
          
 E next()
          
 void remove()
          
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ArrayIterator

public ArrayIterator(E[] array)
Default constructor.

Parameters:
array - The array to iterate.
Method Detail

hasNext

public boolean hasNext()

Specified by:
hasNext in interface java.util.Iterator<E>
See Also:
Iterator.hasNext()

next

public E next()
       throws java.util.NoSuchElementException

Specified by:
next in interface java.util.Iterator<E>
Throws:
java.util.NoSuchElementException
See Also:
Iterator.next()

remove

public void remove()

Specified by:
remove in interface java.util.Iterator<E>
See Also:
Iterator.remove()


Copyright © 2010. All Rights Reserved.