Class Token
java.lang.Object
edu.umd.cs.findbugs.Token
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intA comment.static final intEnd of file.static final intEnd of line.private final intprivate final Stringstatic final intA single character token.static final intA string or character literal.static final intAn ordinary word, number, etc. -
Constructor Summary
Constructors -
Method Summary
-
Field Details
-
EOF
public static final int EOFEnd of file.- See Also:
-
EOL
public static final int EOLEnd of line.- See Also:
-
WORD
public static final int WORDAn ordinary word, number, etc.- See Also:
-
STRING
public static final int STRINGA string or character literal.- See Also:
-
SINGLE
public static final int SINGLEA single character token.- See Also:
-
COMMENT
public static final int COMMENTA comment.- See Also:
-
kind
private final int kind -
lexeme
-
-
Constructor Details
-
Token
Constructor.- Parameters:
kind- the kind of tokenlexeme- the text value of the token
-
Token
public Token(int kind) Constructor when there is no text. E.g., EOF and EOL.- Parameters:
kind- the kind of token
-
-
Method Details
-
getKind
public int getKind()Get the kind of token. -
getLexeme
Get the text value of the token.
-