public class GenericLexer extends Object
| Modifier and Type | Class and Description |
|---|---|
static interface |
GenericLexer.ErrorReporter |
static class |
GenericLexer.Span |
static interface |
GenericLexer.Tokens |
| Modifier and Type | Field and Description |
|---|---|
static int |
TOKEN_SIZE |
| Constructor and Description |
|---|
GenericLexer(Reader stream,
GenericLexer.ErrorReporter reporter,
LexerData lexerData,
Grammar grammar) |
| Modifier and Type | Method and Description |
|---|---|
protected void |
advance() |
protected boolean |
createToken(GenericLexer.Span token,
int ruleIndex) |
int |
getLine() |
int |
getOffset() |
int |
getState() |
int |
getTokenLine() |
GenericLexer.Span |
next() |
void |
reset(Reader stream) |
void |
setLine(int currLine) |
void |
setOffset(int currOffset) |
void |
setState(int state) |
int |
tokenSize() |
String |
tokenText() |
public static final int TOKEN_SIZE
public GenericLexer(Reader stream, GenericLexer.ErrorReporter reporter, LexerData lexerData, Grammar grammar) throws IOException
IOExceptionpublic void reset(Reader stream) throws IOException
IOExceptionprotected void advance()
throws IOException
IOExceptionpublic int getState()
public void setState(int state)
public int getTokenLine()
public int getLine()
public void setLine(int currLine)
public int getOffset()
public void setOffset(int currOffset)
public String tokenText()
public int tokenSize()
public GenericLexer.Span next() throws IOException
IOExceptionprotected boolean createToken(GenericLexer.Span token, int ruleIndex) throws IOException
IOExceptionCopyright © 2014. All rights reserved.