/** * Return the lexeme representing or held by this token. * * @return The lexeme string. */ public String lexeme() { if (kind.hasStaticLexeme()) { return kind.default_lexeme; } else { return lexeme; } }
public String toString() { String str = kind.name(); if (!kind.hasStaticLexeme()) str += "(" + lexeme() + ")"; str += "("; str += "lineNum:" + lineNum; str += ", "; str += "charPos:" + charPos; str += ")"; return str; }
public String lexeme() { return kind.hasStaticLexeme() ? kind.default_lexeme : lexeme; }