1 |
| package net.sourceforge.pmd.dfa; |
2 |
| |
3 |
| import net.sourceforge.pmd.Rule; |
4 |
| import net.sourceforge.pmd.RuleContext; |
5 |
| import net.sourceforge.pmd.RuleViolation; |
6 |
| import net.sourceforge.pmd.ast.SimpleNode; |
7 |
| |
8 |
| |
9 |
| |
10 |
| |
11 |
| |
12 |
| |
13 |
| |
14 |
| |
15 |
| public class DaaRuleViolation extends RuleViolation { |
16 |
| private String variableName; |
17 |
| private int beginLine; |
18 |
| private int endLine; |
19 |
| private String type; |
20 |
| |
21 |
7
| public DaaRuleViolation(Rule rule, RuleContext ctx, SimpleNode node, String type, String msg, String var, int beginLine, int endLine) {
|
22 |
7
| super(rule, ctx, node, msg);
|
23 |
7
| this.variableName = var;
|
24 |
7
| this.beginLine = beginLine;
|
25 |
7
| this.endLine = endLine;
|
26 |
7
| this.type = type;
|
27 |
| } |
28 |
| |
29 |
3
| public String getVariableName() {
|
30 |
3
| return variableName;
|
31 |
| } |
32 |
| |
33 |
41
| public int getBeginLine() {
|
34 |
41
| return beginLine;
|
35 |
| } |
36 |
| |
37 |
2
| public int getEndLine() {
|
38 |
2
| return endLine;
|
39 |
| } |
40 |
| |
41 |
1
| public String getType() {
|
42 |
1
| return type;
|
43 |
| } |
44 |
| } |