Sonar

if you are using sonar with checkstyle and PMD can suppress warnings using @SuppressWarnings

Annotations
You can use a JDK 1.5 annotation to suppress PMD warnings, like this: Or you can suppress one rule with an annotation like this:

PMD also obeys the JDK annotation @SuppressWarnings("unused"), which will apply to all rules in the unused ruleset