public class StringTracker
extends java.lang.Object
| Constructor and Description |
|---|
StringTracker(java.lang.String[] source,
int offset)
Constructor
|
| Modifier and Type | Method and Description |
|---|---|
int |
countRemaining()
Get count of entries remaining.
|
boolean |
hasNext()
Check if another string is available.
|
int |
length()
Get length of array.
|
java.lang.String |
next()
Get next string from array, advancing past that string.
|
int |
nextOffset()
Get position of next string in array.
|
java.lang.String |
peek()
Peek next string from array.
|
public StringTracker(java.lang.String[] source,
int offset)
source - array supplying string dataoffset - initial string position within source arraypublic java.lang.String next()
java.lang.ArrayIndexOutOfBoundsException - if past end of arraypublic java.lang.String peek()
java.lang.ArrayIndexOutOfBoundsException - if past end of arraypublic boolean hasNext()
true if a string is available,
false if at endpublic int nextOffset()
public int length()
public int countRemaining()