public interface Lexer
This is NOT part of any supported API. If you write code that depends on this, you do so at your own risk. This code and its internal interfaces are subject to change or deletion without notice.
Modifier and Type | Method and Description |
---|---|
int |
errPos()
Return the position where a lexical error occurred;
|
void |
errPos(int pos)
Set the position where a lexical error occurred;
|
Position.LineMap |
getLineMap()
Build a map for translating between line numbers and
positions in the input.
|
void |
nextToken()
Consume the next token.
|
Tokens.Token |
prevToken()
Return the last character position of the previous token.
|
Tokens.Token |
split()
Splits the current token in two and return the first (splitted) token.
|
Tokens.Token |
token()
Return current token.
|
Tokens.Token |
token(int lookahead)
Return token with given lookahead.
|
void nextToken()
Tokens.Token token()
Tokens.Token token(int lookahead)
Tokens.Token prevToken()
Tokens.Token split()
int errPos()
void errPos(int pos)
Position.LineMap getLineMap()
Copyright © 2017 earcam. All rights reserved.