This module integrates with the PMD static code analyzer. PMD XPath rules can be designed and imported into Watchtower to scan Java, Ecmascript, Scala, and XML files.
Watchtower has limited support for PMD Java rules. If you would like to add a Java rule, add the Java code as a file to the PMD Module's resources folder, then deploy Watchtower and create a rule that references the Java file.
PMD
pmd_schema_history
db/pmd
Field | Description | Example |
---|---|---|
parserLanguage | Language the rule is associated with | "java" |
ruleClass | Java class the rule is associated with | For XPath rules, "net.sourceforge.pmd.lang.rule.XPathRule" ; for Java rules, name of the Java class containing rule code. |
description | Longer description of the issue this rule identifies | "This is a bad practice because...." |
properties | Any PMD properties for the rule | name="xpath" and value="//PrimaryPrefix[Name[starts-with(@Image,"System.out")]]" (More info here.) |