|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectkiwi.util.ArraySequence
An implementation of Sequence
for wrapping arrays.
Field Summary | |
private java.lang.Object[] |
array
|
private int |
offset
|
Constructor Summary | |
ArraySequence(java.lang.Object[] array)
Construct a new ArraySequence . |
Method Summary | |
int |
getSize()
Get the size of the sequence. |
boolean |
hasMoreElements()
Check if the sequence has more elements. |
java.lang.Object |
nextElement()
Get the next element in the sequence. |
void |
rewind()
Rewind the sequence to the beginning. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
private java.lang.Object[] array
private int offset
Constructor Detail |
public ArraySequence(java.lang.Object[] array)
ArraySequence
.
array
- The array to wrap.Method Detail |
public boolean hasMoreElements()
hasMoreElements
in interface java.util.Enumeration
true if there are more elements, and false
otherwise.
public java.lang.Object nextElement()
nextElement
in interface java.util.Enumeration
null
if the
end has been reached.public void rewind()
rewind
in interface Sequence
public int getSize()
getSize
in interface Sequence
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |