diff options
author | Godin <mandrikov@gmail.com> | 2010-12-06 13:41:41 +0000 |
---|---|---|
committer | Godin <mandrikov@gmail.com> | 2010-12-06 13:41:41 +0000 |
commit | 5fc0fb0a845571f855956015aaba03d9b7fa34a7 (patch) | |
tree | 833c2246b7779e9ec53e6dbdb23c5910c4c786e4 /sonar-plugin-api | |
parent | 73c870d39a1d5a9af9fa7c4b75e3920d555a6400 (diff) | |
download | sonarqube-5fc0fb0a845571f855956015aaba03d9b7fa34a7.tar.gz sonarqube-5fc0fb0a845571f855956015aaba03d9b7fa34a7.zip |
NewViolationsDecorator should count new violations by priority and by rule
Diffstat (limited to 'sonar-plugin-api')
-rw-r--r-- | sonar-plugin-api/src/main/java/org/sonar/api/measures/CoreMetrics.java | 28 |
1 files changed, 24 insertions, 4 deletions
diff --git a/sonar-plugin-api/src/main/java/org/sonar/api/measures/CoreMetrics.java b/sonar-plugin-api/src/main/java/org/sonar/api/measures/CoreMetrics.java index b51e25ac688..09d826610ca 100644 --- a/sonar-plugin-api/src/main/java/org/sonar/api/measures/CoreMetrics.java +++ b/sonar-plugin-api/src/main/java/org/sonar/api/measures/CoreMetrics.java @@ -353,10 +353,6 @@ public final class CoreMetrics { public static final Metric VIOLATIONS = new Metric(VIOLATIONS_KEY, "Violations", "Violations", Metric.ValueType.INT, Metric.DIRECTION_WORST, true, DOMAIN_RULES).setBestValue(0.0).setOptimizedBestValue(true); - public static final String NEW_VIOLATIONS_KEY = "new_violations"; - public static final Metric NEW_VIOLATIONS = new Metric(NEW_VIOLATIONS_KEY, "New Violations", "New Violations", Metric.ValueType.INT, - Metric.DIRECTION_WORST, true, DOMAIN_RULES); - public static final String BLOCKER_VIOLATIONS_KEY = "blocker_violations"; public static final Metric BLOCKER_VIOLATIONS = new Metric(BLOCKER_VIOLATIONS_KEY, "Blocker violations", "Blocker violations", Metric.ValueType.INT, Metric.DIRECTION_WORST, true, DOMAIN_RULES).setBestValue(0.0).setOptimizedBestValue(true); @@ -377,6 +373,30 @@ public final class CoreMetrics { public static final Metric INFO_VIOLATIONS = new Metric(INFO_VIOLATIONS_KEY, "Info violations", "Info violations", Metric.ValueType.INT, Metric.DIRECTION_WORST, true, DOMAIN_RULES).setBestValue(0.0).setOptimizedBestValue(true); + public static final String NEW_VIOLATIONS_KEY = "new_violations"; + public static final Metric NEW_VIOLATIONS = new Metric(NEW_VIOLATIONS_KEY, "New Violations", "New Violations", Metric.ValueType.INT, + Metric.DIRECTION_WORST, true, DOMAIN_RULES); + + public static final String NEW_BLOCKER_VIOLATIONS_KEY = "new_blocker_violations"; + public static final Metric NEW_BLOCKER_VIOLATIONS = new Metric(NEW_BLOCKER_VIOLATIONS_KEY, "New Blocker violations", "New Blocker violations", + Metric.ValueType.INT, Metric.DIRECTION_WORST, true, DOMAIN_RULES); + + public static final String NEW_CRITICAL_VIOLATIONS_KEY = "new_critical_violations"; + public static final Metric NEW_CRITICAL_VIOLATIONS = new Metric(NEW_CRITICAL_VIOLATIONS_KEY, "New Critical violations", "New Critical violations", + Metric.ValueType.INT, Metric.DIRECTION_WORST, true, DOMAIN_RULES); + + public static final String NEW_MAJOR_VIOLATIONS_KEY = "new_major_violations"; + public static final Metric NEW_MAJOR_VIOLATIONS = new Metric(NEW_MAJOR_VIOLATIONS_KEY, "New Major violations", "New Major violations", + Metric.ValueType.INT, Metric.DIRECTION_WORST, true, DOMAIN_RULES); + + public static final String NEW_MINOR_VIOLATIONS_KEY = "new_minor_violations"; + public static final Metric NEW_MINOR_VIOLATIONS = new Metric(NEW_MINOR_VIOLATIONS_KEY, "New Minor violations", "New Minor violations", + Metric.ValueType.INT, Metric.DIRECTION_WORST, true, DOMAIN_RULES); + + public static final String NEW_INFO_VIOLATIONS_KEY = "new_info_violations"; + public static final Metric NEW_INFO_VIOLATIONS = new Metric(NEW_INFO_VIOLATIONS_KEY, "New Info violations", "New Info violations", + Metric.ValueType.INT, Metric.DIRECTION_WORST, true, DOMAIN_RULES); + /* Design */ public static final String ABSTRACTNESS_KEY = "abstractness"; |