IntStream
ANTLRFileStream
, ANTLRInputStream
, ANTLRReaderStream
, ANTLRStringStream
public interface CharStream extends IntStream
Modifier and Type | Field | Description |
---|---|---|
static int |
EOF |
Modifier and Type | Method | Description |
---|---|---|
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.
|
static final int EOF
String substring(int start, int stop)
int LT(int i)
int getLine()
void setLine(int line)
void setCharPositionInLine(int pos)
int getCharPositionInLine()
Copyright © 1992–2018 ANTLR. All rights reserved.