Package net.sourceforge.pmd.lang.rule
Class AbstractRuleViolationFactory
- java.lang.Object
-
- net.sourceforge.pmd.lang.rule.AbstractRuleViolationFactory
-
- All Implemented Interfaces:
RuleViolationFactory
public abstract class AbstractRuleViolationFactory extends Object implements RuleViolationFactory
-
-
Constructor Summary
Constructors Constructor Description AbstractRuleViolationFactory()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description voidaddViolation(RuleContext ruleContext, Rule rule, Node node, String message, int beginLine, int endLine, Object[] args)voidaddViolation(RuleContext ruleContext, Rule rule, Node node, String message, Object[] args)Adds a violation to the report.protected abstract RuleViolationcreateRuleViolation(Rule rule, RuleContext ruleContext, Node node, String message)protected abstract RuleViolationcreateRuleViolation(Rule rule, RuleContext ruleContext, Node node, String message, int beginLine, int endLine)
-
-
-
Method Detail
-
addViolation
public void addViolation(RuleContext ruleContext, Rule rule, Node node, String message, Object[] args)
Description copied from interface:RuleViolationFactoryAdds a violation to the report.- Specified by:
addViolationin interfaceRuleViolationFactory- Parameters:
ruleContext- the RuleContextrule- the rulenode- the node that produces the violationmessage- specific message to put in the reportargs- arguments to embed in the rule violation message
-
addViolation
public void addViolation(RuleContext ruleContext, Rule rule, Node node, String message, int beginLine, int endLine, Object[] args)
- Specified by:
addViolationin interfaceRuleViolationFactory
-
createRuleViolation
protected abstract RuleViolation createRuleViolation(Rule rule, RuleContext ruleContext, Node node, String message)
-
createRuleViolation
protected abstract RuleViolation createRuleViolation(Rule rule, RuleContext ruleContext, Node node, String message, int beginLine, int endLine)
-
-