Package net.sourceforge.pmd.cpd
Class JavaTokenizer
- java.lang.Object
-
- net.sourceforge.pmd.cpd.internal.JavaCCTokenizer
-
- net.sourceforge.pmd.cpd.JavaTokenizer
-
- All Implemented Interfaces:
Tokenizer
public class JavaTokenizer extends net.sourceforge.pmd.cpd.internal.JavaCCTokenizer
-
-
Field Summary
Fields Modifier and Type Field Description static String
CPD_END
static String
CPD_START
-
Fields inherited from interface net.sourceforge.pmd.cpd.Tokenizer
DEFAULT_SKIP_BLOCKS_PATTERN, IGNORE_ANNOTATIONS, IGNORE_IDENTIFIERS, IGNORE_LITERALS, IGNORE_USINGS, OPTION_IGNORE_LITERAL_SEQUENCES, OPTION_SKIP_BLOCKS, OPTION_SKIP_BLOCKS_PATTERN
-
-
Constructor Summary
Constructors Constructor Description JavaTokenizer()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected TokenManager
getLexerForSource(SourceCode sourceCode)
protected TokenFilter
getTokenFilter(TokenManager tokenManager)
protected TokenEntry
processToken(Tokens tokenEntries, GenericToken currentToken, String fileName)
void
setIgnoreAnnotations(boolean ignoreAnnotations)
void
setIgnoreIdentifiers(boolean ignore)
void
setIgnoreLiterals(boolean ignore)
void
setProperties(Properties properties)
void
tokenize(SourceCode sourceCode, Tokens tokenEntries)
-
-
-
Field Detail
-
CPD_START
public static final String CPD_START
- See Also:
- Constant Field Values
-
CPD_END
public static final String CPD_END
- See Also:
- Constant Field Values
-
-
Method Detail
-
setProperties
public void setProperties(Properties properties)
-
tokenize
public void tokenize(SourceCode sourceCode, Tokens tokenEntries) throws IOException
- Specified by:
tokenize
in interfaceTokenizer
- Overrides:
tokenize
in classnet.sourceforge.pmd.cpd.internal.JavaCCTokenizer
- Throws:
IOException
-
getLexerForSource
protected TokenManager getLexerForSource(SourceCode sourceCode)
- Specified by:
getLexerForSource
in classnet.sourceforge.pmd.cpd.internal.JavaCCTokenizer
-
getTokenFilter
protected TokenFilter getTokenFilter(TokenManager tokenManager)
- Overrides:
getTokenFilter
in classnet.sourceforge.pmd.cpd.internal.JavaCCTokenizer
-
processToken
protected TokenEntry processToken(Tokens tokenEntries, GenericToken currentToken, String fileName)
- Overrides:
processToken
in classnet.sourceforge.pmd.cpd.internal.JavaCCTokenizer
-
setIgnoreLiterals
public void setIgnoreLiterals(boolean ignore)
-
setIgnoreIdentifiers
public void setIgnoreIdentifiers(boolean ignore)
-
setIgnoreAnnotations
public void setIgnoreAnnotations(boolean ignoreAnnotations)
-
-