diff options
author | Julien Lancelot <julien.lancelot@sonarsource.com> | 2016-03-07 17:17:22 +0100 |
---|---|---|
committer | Julien Lancelot <julien.lancelot@sonarsource.com> | 2016-03-09 11:33:57 +0100 |
commit | 346cbb08757dd55935a4f85b57faf00d91d049ff (patch) | |
tree | a4b2c418a4fdad5494a1ba7b1d5f33415e704ab7 /sonar-plugin-api | |
parent | ae68d2d72fb2f426455b82f9f3b2abacc40b8165 (diff) | |
download | sonarqube-346cbb08757dd55935a4f85b57faf00d91d049ff.tar.gz sonarqube-346cbb08757dd55935a4f85b57faf00d91d049ff.zip |
SONAR-7426 Add new characteristic rating metrics
Diffstat (limited to 'sonar-plugin-api')
-rw-r--r-- | sonar-plugin-api/src/main/java/org/sonar/api/measures/CoreMetrics.java | 33 |
1 files changed, 33 insertions, 0 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 729c0c01ba6..c2ef7cee88f 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 @@ -2311,6 +2311,23 @@ public final class CoreMetrics { .setDeleteHistoricalData(true) .create(); + /** + * @since 5.5 + */ + public static final String RELIABILITY_RATING_KEY = "reliability_rating"; + + /** + * @since 5.5 + */ + public static final Metric<Integer> RELIABILITY_RATING = new Metric.Builder(RELIABILITY_RATING_KEY, "Reliability Rating", Metric.ValueType.RATING) + .setDomain(DOMAIN_RELIABILITY) + .setDirection(Metric.DIRECTION_WORST) + .setQualitative(true) + .setBestValue(1.0) + .setWorstValue(5.0) + .create(); + + // -------------------------------------------------------------------------------------------------------------------- // // SECURITY CHARACTERISTIC @@ -2352,6 +2369,22 @@ public final class CoreMetrics { .setDeleteHistoricalData(true) .create(); + /** + * @since 5.5 + */ + public static final String SECURITY_RATING_KEY = "security_rating"; + + /** + * @since 5.5 + */ + public static final Metric<Integer> SECURITY_RATING = new Metric.Builder(SECURITY_RATING_KEY, "Security Rating", Metric.ValueType.RATING) + .setDomain(DOMAIN_SECURITY) + .setDirection(Metric.DIRECTION_WORST) + .setQualitative(true) + .setBestValue(1.0) + .setWorstValue(5.0) + .create(); + // -------------------------------------------------------------------------------------------------------------------- // // FILE DATA |