public class TokenTool
extends java.lang.Object
| Modifier and Type | Field and Description | 
|---|---|
static java.lang.String | 
LEXER_RULE_PREFIX  | 
| Constructor and Description | 
|---|
TokenTool()  | 
| Modifier and Type | Method and Description | 
|---|---|
static int | 
getLength(org.antlr.runtime.Token t)  | 
static java.lang.String | 
getLexerRuleName(java.lang.String antlrTokenDef)  | 
static int | 
getLine(org.antlr.runtime.Token t)  | 
static int | 
getOffset(org.antlr.runtime.Token t)  | 
static java.lang.String | 
getText(org.antlr.runtime.Token t)  | 
static boolean | 
isLexerRule(java.lang.String antlrTokenDef)  | 
public static final java.lang.String LEXER_RULE_PREFIX
public static java.lang.String getText(org.antlr.runtime.Token t)
t - the tokennull if the Token t was null or the token's text was null.public static int getLine(org.antlr.runtime.Token t)
t - the token-1 if the Token t was null or the token did not provide line information.public static int getOffset(org.antlr.runtime.Token t)
t - the token-1 if the Token t was null or the token did not provide offset information.public static int getLength(org.antlr.runtime.Token t)
t - the token0 if the Token t was null or the token did not provide line information.public static boolean isLexerRule(java.lang.String antlrTokenDef)
public static java.lang.String getLexerRuleName(java.lang.String antlrTokenDef)