public class ListSequence<T> extends BaseFieldGenerator<T>
| Constructor and Description |
|---|
ListSequence(List<T> values) |
ListSequence(T... values) |
| Modifier and Type | Method and Description |
|---|---|
T |
current()
Returns the current sequence value.
|
boolean |
hasNext()
Returns
true if the list has more elements (In other words, returns true if next() would
return a value rather than throwing an exception.) |
T |
next()
Returns the next value in list.
|
void |
reset()
Resets the
ListSequence. |
String |
toString() |
removepublic ListSequence(T... values)
values - the values.public void reset()
public T current()
next() if next was never called before since
creation of last reset().public boolean hasNext()
true if the list has more elements (In other words, returns true if next() would
return a value rather than throwing an exception.)true if the iteration has more value.public T next()
NoSuchElementException - if the iteration has no more value.Copyright © 2014. All Rights Reserved.