EclipseLink 2.4.2, build 'v20130514-5956486' API Reference

org.eclipse.persistence.jpa.jpql.util.iterator
Class ArrayIterator<E>

java.lang.Object
  extended by org.eclipse.persistence.jpa.jpql.util.iterator.ArrayIterator<E>
All Implemented Interfaces:
java.lang.Iterable<E>, java.util.Iterator<E>, IterableIterator<E>
Direct Known Subclasses:
ArrayListIterator

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

An ArrayIterator provides a Iterator for an array of objects.

Version:
2.4
Since:
2.4

Constructor Summary
ArrayIterator(T... array)
          Creates a new ArrayIterator for the specified array.
ArrayIterator(T[] array, int start, int length)
          Creates a new ArrayIterator for the specified array, starting at the specified start index and continuing for the specified length.
 
Method Summary
 boolean hasNext()
          
 java.util.Iterator<E> iterator()
          
 E next()
          
 void remove()
          
 java.lang.String toString()
          
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ArrayIterator

public ArrayIterator(T... array)
Creates a new ArrayIterator for the specified array.

Parameters:
array - The object containing the items to iterate over

ArrayIterator

public ArrayIterator(T[] array,
                     int start,
                     int length)
Creates a new ArrayIterator for the specified array, starting at the specified start index and continuing for the specified length.

Parameters:
array - The object containing the items to iterate over
start - The beginning of the iteration
length - The length of the iteration
Throws:
java.lang.IllegalArgumentException - The start index is either a negative value or greater than the length of the array or the length to copy goes beyond the length of the array
Method Detail

hasNext

public boolean hasNext()

Specified by:
hasNext in interface java.util.Iterator<E>

iterator

public java.util.Iterator<E> iterator()

Specified by:
iterator in interface java.lang.Iterable<E>

next

public E next()

Specified by:
next in interface java.util.Iterator<E>

remove

public void remove()

Specified by:
remove in interface java.util.Iterator<E>

toString

public java.lang.String toString()

Overrides:
toString in class java.lang.Object

EclipseLink 2.4.2, build 'v20130514-5956486' API Reference