|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.basex.util.TokenParser
public class TokenParser
This class can be used to iterate through all codepoints of a token.
Field Summary | |
---|---|
protected byte[] |
token
Token to be parsed. |
Constructor Summary | |
---|---|
TokenParser(byte[] tok)
Constructor. |
Method Summary | |
---|---|
boolean |
consume(int ch)
Tries to consume the specified codepoint. |
boolean |
more()
Checks if the parser will return more codepoints. |
int |
next()
Returns the current codepoint and advances the cursor. |
void |
reset()
Resets the cursor position. |
IntList |
toList()
Returns a list with all codepoints. |
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected final byte[] token
Constructor Detail |
---|
public TokenParser(byte[] tok)
tok
- tokenMethod Detail |
---|
public void reset()
public boolean more()
public int next()
-1
public boolean consume(int ch)
ch
- codepoint to be consumed
public final IntList toList()
public java.lang.String toString()
toString
in class java.lang.Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |