|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectariba.util.core.SubsetIterator
public final class SubsetIterator
A SubsetIterator produces a series of subsets of the requested size from a source array of objects.
Constructor Summary | |
---|---|
SubsetIterator(java.lang.Object[] source,
int subsetSize)
Creates a new SubsetIterator for the given source array, where each subset will be of the given subsetSize. |
|
SubsetIterator(java.lang.Object[] source,
int subsetSize,
java.lang.Object[] result)
Creates a new SubsetIterator for the given source array, where each subset will be of the given subsetSize. |
Method Summary | |
---|---|
boolean |
hasNext()
Returns true if the SubsetIterator has more elements. |
static void |
main(java.lang.String[] args)
The first argument is assumed to be an integer which is the requested subset size. |
java.lang.Object |
next()
Returns the next element of this SubsetIterator as an array of Objects. |
void |
remove()
|
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public SubsetIterator(java.lang.Object[] source, int subsetSize)
public SubsetIterator(java.lang.Object[] source, int subsetSize, java.lang.Object[] result)
Method Detail |
---|
public boolean hasNext()
hasNext
in interface java.util.Iterator
public java.lang.Object next()
next
in interface java.util.Iterator
public void remove()
remove
in interface java.util.Iterator
public static void main(java.lang.String[] args)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |