]> source.dussan.org Git - sonarqube.git/commitdiff
define new_violations metrics as 'optimized with best value'
authorsimonbrandhof <simon.brandhof@gmail.com>
Wed, 22 Dec 2010 00:11:19 +0000 (00:11 +0000)
committersimonbrandhof <simon.brandhof@gmail.com>
Wed, 22 Dec 2010 00:11:19 +0000 (00:11 +0000)
sonar-plugin-api/src/main/java/org/sonar/api/measures/CoreMetrics.java

index e5533d3937b5a3ccfe61dbd7f7efb4b38ec9790b..35f270d3c4df6a697956dcb9c56075f5dc7c144a 100644 (file)
@@ -375,27 +375,27 @@ public final class CoreMetrics {
 
   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).setHidden(true);
+      Metric.DIRECTION_WORST, true, DOMAIN_RULES).setHidden(true).setBestValue(0.0).setOptimizedBestValue(true);
 
   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).setHidden(true);
+      Metric.ValueType.INT, Metric.DIRECTION_WORST, true, DOMAIN_RULES).setHidden(true).setBestValue(0.0).setOptimizedBestValue(true);
 
   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).setHidden(true);
+      Metric.ValueType.INT, Metric.DIRECTION_WORST, true, DOMAIN_RULES).setHidden(true).setBestValue(0.0).setOptimizedBestValue(true);
 
   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).setHidden(true);
+      Metric.ValueType.INT, Metric.DIRECTION_WORST, true, DOMAIN_RULES).setHidden(true).setBestValue(0.0).setOptimizedBestValue(true);
 
   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).setHidden(true);
+      Metric.ValueType.INT, Metric.DIRECTION_WORST, true, DOMAIN_RULES).setHidden(true).setBestValue(0.0).setOptimizedBestValue(true);
 
   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).setHidden(true);
+      Metric.ValueType.INT, Metric.DIRECTION_WORST, true, DOMAIN_RULES).setHidden(true).setBestValue(0.0).setOptimizedBestValue(true);
 
   /* Design */