Class ScalaTokenizer

  • All Implemented Interfaces:
    net.sourceforge.pmd.cpd.Tokenizer

    public class ScalaTokenizer
    extends Object
    implements net.sourceforge.pmd.cpd.Tokenizer
    Scala Tokenizer class. Uses the Scala Meta Tokenizer.
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static String SCALA_VERSION_PROPERTY
      Denotes the version of the scala dialect to use.
      • Fields inherited from interface net.sourceforge.pmd.cpd.Tokenizer

        DEFAULT_SKIP_BLOCKS_PATTERN, IGNORE_ANNOTATIONS, IGNORE_IDENTIFIERS, IGNORE_LITERALS, IGNORE_USINGS, OPTION_SKIP_BLOCKS, OPTION_SKIP_BLOCKS_PATTERN
    • Constructor Summary

      Constructors 
      Constructor Description
      ScalaTokenizer()
      Create the Tokenizer using properties from the system environment.
      ScalaTokenizer​(Properties properties)
      Create the Tokenizer given a set of properties.
    • Field Detail

      • SCALA_VERSION_PROPERTY

        public static final String SCALA_VERSION_PROPERTY
        Denotes the version of the scala dialect to use. Based on the values in BaseLanguageModule.getVersions()
        See Also:
        Constant Field Values
    • Constructor Detail

      • ScalaTokenizer

        public ScalaTokenizer()
        Create the Tokenizer using properties from the system environment.
      • ScalaTokenizer

        public ScalaTokenizer​(Properties properties)
        Create the Tokenizer given a set of properties.
        Parameters:
        properties - the Properties object to use
    • Method Detail

      • tokenize

        public void tokenize​(net.sourceforge.pmd.cpd.SourceCode sourceCode,
                             net.sourceforge.pmd.cpd.Tokens tokenEntries)
                      throws IOException
        Specified by:
        tokenize in interface net.sourceforge.pmd.cpd.Tokenizer
        Throws:
        IOException