Package edu.umd.cs.findbugs
Class Tokenizer
- java.lang.Object
-
- edu.umd.cs.findbugs.Tokenizer
-
public class Tokenizer extends java.lang.ObjectA simple tokenizer for Java source text. This is not intended to be a compliant lexer; instead, it is for quick and dirty scanning.- See Also:
Token
-
-
Field Summary
Fields Modifier and Type Field Description private java.io.PushbackReaderreaderprivate static java.util.BitSetsingleprivate static java.util.BitSetwhiteSpace
-
Constructor Summary
Constructors Constructor Description Tokenizer(java.io.Reader reader)Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description private TokenmaybeComment()private TokenmunchString(int delimiter)Tokennext()Get the next Token in the stream.private TokenparseWord()private voidskipWhitespace()
-
-
-
Method Detail
-
next
public Token next() throws java.io.IOException
Get the next Token in the stream.- Returns:
- the Token
- Throws:
java.io.IOException
-
skipWhitespace
private void skipWhitespace() throws java.io.IOException- Throws:
java.io.IOException
-
munchString
private Token munchString(int delimiter) throws java.io.IOException
- Throws:
java.io.IOException
-
maybeComment
private Token maybeComment() throws java.io.IOException
- Throws:
java.io.IOException
-
parseWord
private Token parseWord() throws java.io.IOException
- Throws:
java.io.IOException
-
-