01: package org.acm.seguin.pmd;
02:
03: import java.util.List;
04:
05: public interface Rule {
06: public static final int LOWEST_PRIORITY = 5;
07: public static final String[] PRIORITIES = { "High", "Medium High",
08: "Medium", "Medium Low", "Low" };
09:
10: String getName();
11:
12: String getMessage();
13:
14: String getDescription();
15:
16: String getExample();
17:
18: void setName(String name);
19:
20: void setMessage(String message);
21:
22: void setDescription(String description);
23:
24: void setExample(String example);
25:
26: void apply(List astCompilationUnits, RuleContext ctx);
27:
28: boolean hasProperty(String name);
29:
30: void addProperty(String name, String property);
31:
32: int getIntProperty(String name);
33:
34: boolean getBooleanProperty(String name);
35:
36: String getStringProperty(String name);
37:
38: double getDoubleProperty(String name);
39:
40: RuleProperties getProperties();
41:
42: boolean include();
43:
44: void setInclude(boolean include);
45:
46: int getPriority();
47:
48: String getPriorityName();
49:
50: void setPriority(int priority);
51: }
|