public static class RemoteDebugEventSocketListener.ProxyToken extends Object implements Token
DEFAULT_CHANNEL, DOWN, EOF, EOR_TOKEN_TYPE, HIDDEN_CHANNEL, INVALID_TOKEN, INVALID_TOKEN_TYPE, MIN_TOKEN_TYPE, SKIP_TOKEN, UP
Constructor and Description |
---|
ProxyToken(int index) |
ProxyToken(int index,
int type,
int channel,
int line,
int charPos,
String text) |
Modifier and Type | Method and Description |
---|---|
int |
getChannel() |
int |
getCharPositionInLine()
The index of the first character relative to the beginning of the line 0..n-1
|
CharStream |
getInputStream()
From what character stream was this token created? You don't have to
implement but it's nice to know where a Token comes from if you have
include files etc...
|
int |
getLine()
The line number on which this token was matched; line=1..n
|
String |
getText()
Get the text of the token
|
int |
getTokenIndex()
An index from 0..n-1 of the token object in the input stream.
|
int |
getType() |
void |
setChannel(int channel) |
void |
setCharPositionInLine(int pos) |
void |
setInputStream(CharStream input) |
void |
setLine(int line) |
void |
setText(String text) |
void |
setTokenIndex(int index) |
void |
setType(int ttype) |
String |
toString() |
public ProxyToken(int index)
public ProxyToken(int index, int type, int channel, int line, int charPos, String text)
public int getLine()
Token
public int getCharPositionInLine()
Token
getCharPositionInLine
in interface Token
public void setCharPositionInLine(int pos)
setCharPositionInLine
in interface Token
public int getChannel()
getChannel
in interface Token
public void setChannel(int channel)
setChannel
in interface Token
public int getTokenIndex()
Token
getTokenIndex
in interface Token
public void setTokenIndex(int index)
setTokenIndex
in interface Token
public CharStream getInputStream()
Token
getInputStream
in interface Token
public void setInputStream(CharStream input)
setInputStream
in interface Token
Copyright © 1992–2015 ANTLR. All rights reserved.