| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public final boolean | equals(Object o)
Implements abstract java. Indicates whether some other object is "equal to" this one. |
| public int | |
| public int | getCharPositionInLine()
Implements org. The index of the first character of this token relative to the beginning of the line at which it occurs, 0..n-1 |
| public CharStream | getInputStream()
Implements org. Gets the |
| public int | getLine()
Implements org. The line number on which the 1st character of this token was matched, line=1..n |
| public int | getStartIndex()
Implements org. The starting character index of the token This method is optional; return -1 if not implemented. |
| public int | getStopIndex()
Implements org. The last character index of the token. |
| public String | |
| public int | getTokenIndex()
Implements org. An index from 0..n-1 of the token object in the input stream. |
| public TokenSource | getTokenSource()
Implements org. Gets the |
| public int | |
| public final int | |
| public Token | |
| public String | |
| public final String | toString()
Implements abstract java. Returns a string representation of the record. |
| origin | back to summary |
|---|---|
| private final Token origin Record Component accessed by origin(). | |
| text | back to summary |
|---|---|
| private final String text Record Component accessed by text(). | |
| FragmentToken | back to summary |
|---|---|
| public FragmentToken(Token origin, String text) | |
| equals | back to summary |
|---|---|
| public final boolean equals(Object o) Implements abstract java. Doc from java. Indicates whether some other object is "equal to" this one. In addition
to the general contract of
R copy = new R(r.c1(), r.c2(), ..., r.cn());
then it must be the case that r.equals(copy).
| |
| getChannel | back to summary |
|---|---|
| public int getChannel() Implements org. Doc from org. Return the channel this token. Each token can arrive at the parser on a different channel, but the parser only "tunes" to a single channel. The parser ignores everything not on DEFAULT_CHANNEL.
| |
| getCharPositionInLine | back to summary |
|---|---|
| public int getCharPositionInLine() Implements org. Doc from org. The index of the first character of this token relative to the beginning of the line at which it occurs, 0..n-1
| |
| getInputStream | back to summary |
|---|---|
| public CharStream getInputStream() Implements org. Doc from org. Gets the
| |
| getLine | back to summary |
|---|---|
| public int getLine() Implements org. Doc from org. The line number on which the 1st character of this token was matched, line=1..n
| |
| getStartIndex | back to summary |
|---|---|
| public int getStartIndex() Implements org. Doc from org. The starting character index of the token This method is optional; return -1 if not implemented.
| |
| getStopIndex | back to summary |
|---|---|
| public int getStopIndex() Implements org. Doc from org. The last character index of the token. This method is optional; return -1 if not implemented.
| |
| getText | back to summary |
|---|---|
| public String getText() Implements org. Doc from org. Get the text of the token.
| |
| getTokenIndex | back to summary |
|---|---|
| public int getTokenIndex() Implements org. Doc from org. An index from 0..n-1 of the token object in the input stream. This must be valid in order to print token streams and use TokenRewriteStream. Return -1 to indicate that this token was conjured up since it doesn't have a valid index.
| |
| getTokenSource | back to summary |
|---|---|
| public TokenSource getTokenSource() Implements org. Doc from org. Gets the
| |
| getType | back to summary |
|---|---|
| public int getType() Implements org. Doc from org. Get the token type of the token
| |
| hashCode | back to summary |
|---|---|
| public final int hashCode() Implements abstract java. Doc from java. Returns a hash code value for the record.
Obeys the general contract of | |
| origin | back to summary |
|---|---|
| public Token origin() Record Component getter of origin. | |
| text | back to summary |
|---|---|
| public String text() Record Component getter of text. | |
| toString | back to summary |
|---|---|
| public final String toString() Implements abstract java. Doc from java. Returns a string representation of the record.
In accordance with the general contract of In addition to this general contract, record classes must further participate in the invariant that any two records which are equal must produce equal strings. This invariant is necessarily relaxed in the rare case where corresponding equal component values might fail to produce equal strings for themselves. | |