|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface CharStream
A source of characters for an ANTLR lexer
| Field Summary | |
|---|---|
static int |
EOF
|
| Method Summary | |
|---|---|
int |
getCharPositionInLine()
The index of the character relative to the beginning of the line 0..n-1 |
int |
getLine()
ANTLR tracks the line information automatically |
int |
LT(int i)
Get the ith character of lookahead. |
void |
setCharPositionInLine(int pos)
|
void |
setLine(int line)
Because this stream can rewind, we need to be able to reset the line |
String |
substring(int start,
int stop)
For infinite streams, you don't need this; primarily I'm providing a useful interface for action code. |
| Methods inherited from interface org.antlr.runtime.IntStream |
|---|
consume, getSourceName, index, LA, mark, release, rewind, rewind, seek, size |
| Field Detail |
|---|
static final int EOF
| Method Detail |
|---|
String substring(int start,
int stop)
int LT(int i)
int getLine()
void setLine(int line)
void setCharPositionInLine(int pos)
int getCharPositionInLine()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||