01 package net.sourceforge.pmd.lang.rule;
02
03 import net.sourceforge.pmd.Rule;
04 import net.sourceforge.pmd.RuleContext;
05 import net.sourceforge.pmd.lang.ast.Node;
06
07 /**
08 * This class handles of producing a Language specific RuleViolation and adding
09 * to a Report.
10 */
11 public interface RuleViolationFactory {
12 /**
13 * Adds a violation to the report.
14 *
15 * @param ruleContext
16 * the RuleContext
17 * @param rule
18 * the rule
19 * @param node
20 * the node that produces the violation
21 * @param message
22 * specific message to put in the report
23 * @param args
24 * arguments to embed in the rule violation message
25 */
26 void addViolation(RuleContext ruleContext, Rule rule, Node node, String message, Object[] args);
27 }
|