FindBugs™ 1.3.9

edu.umd.cs.findbugs
Class Token

java.lang.Object
  extended by edu.umd.cs.findbugs.Token

public class Token
extends java.lang.Object

Simple token class.

Author:
David Hovemeyer
See Also:
Tokenizer

Field Summary
static int COMMENT
          A comment.
static int EOF
          End of file.
static int EOL
          End of line.
static int SINGLE
          A single character token.
static int STRING
          A string or character literal.
static int WORD
          An ordinary word, number, etc.
 
Constructor Summary
Token(int kind)
          Constructor when there is no text.
Token(int kind, java.lang.String lexeme)
          Constructor.
 
Method Summary
 int getKind()
          Get the kind of token.
 java.lang.String getLexeme()
          Get the text value of the token.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

EOF

public static final int EOF
End of file.

See Also:
Constant Field Values

EOL

public static final int EOL
End of line.

See Also:
Constant Field Values

WORD

public static final int WORD
An ordinary word, number, etc.

See Also:
Constant Field Values

STRING

public static final int STRING
A string or character literal.

See Also:
Constant Field Values

SINGLE

public static final int SINGLE
A single character token.

See Also:
Constant Field Values

COMMENT

public static final int COMMENT
A comment.

See Also:
Constant Field Values
Constructor Detail

Token

public Token(int kind,
             java.lang.String lexeme)
Constructor.

Parameters:
kind - the kind of token
lexeme - 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 Detail

getKind

public int getKind()
Get the kind of token.


getLexeme

public java.lang.String getLexeme()
Get the text value of the token.


FindBugs™ 1.3.9

FindBugs™ is licenced under the LGPL. Copyright © 2006 University of Maryland.