public abstract class Token
extends java.lang.Object
implements java.io.Serializable
| Constructor and Description |
|---|
Token(java.lang.String source)
Create a token.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(java.lang.Object arg) |
int |
getColumnNumber() |
int |
getLength()
Gets the length of the source text matched by this token
|
int |
getLineNumber() |
java.lang.String |
getSource()
Gets the source text matched by this token
|
int |
hashCode() |
boolean |
isBinary() |
boolean |
isComment() |
boolean |
isFunction() |
boolean |
isIdentifier() |
boolean |
isImplicitMulRhs()
Whether the token can appear on the right hand side of implicit multiplication '2 x'.
|
boolean |
isNumber() |
boolean |
isOperator() |
boolean |
isPrefix() |
boolean |
isString() |
boolean |
isSuffix() |
boolean |
isSymbol() |
boolean |
isTerminal() |
boolean |
isTernary() |
boolean |
isWhiteSpace() |
void |
setPosition(int line,
int column)
Sets the position of the token.
|
java.lang.String |
toString() |
public Token(java.lang.String source)
MultiLineMatcher.source - public java.lang.String getSource()
public int getLength()
public java.lang.String toString()
toString in class java.lang.Objectpublic boolean isWhiteSpace()
public boolean isIdentifier()
public boolean isFunction()
public boolean isOperator()
public boolean isBinary()
public boolean isPrefix()
public boolean isSuffix()
public boolean isTernary()
public boolean isNumber()
public boolean isComment()
public boolean isString()
public boolean isSymbol()
public boolean isImplicitMulRhs()
public boolean equals(java.lang.Object arg)
equals in class java.lang.Objectpublic int hashCode()
hashCode in class java.lang.Objectpublic boolean isTerminal()
public void setPosition(int line,
int column)
line - line numbercolumn - column numberpublic int getLineNumber()
public int getColumnNumber()
Copyright © 2018 Singular Systems http://www.singularsys.com/jep