aboutsummaryrefslogtreecommitdiffstats
path: root/sonar-plugin-api
diff options
context:
space:
mode:
authorJulien Lancelot <julien.lancelot@sonarsource.com>2019-06-05 11:51:31 +0200
committerSonarTech <sonartech@sonarsource.com>2019-06-14 20:21:10 +0200
commitf6028da2015f64cb71146b1c8736e800c9ed7b54 (patch)
tree20462b8054ac13eb5ee7e98edfc954e4f83ddf01 /sonar-plugin-api
parent00e91c1362a5c02384ba9145ad02d9289ba5e686 (diff)
downloadsonarqube-f6028da2015f64cb71146b1c8736e800c9ed7b54.tar.gz
sonarqube-f6028da2015f64cb71146b1c8736e800c9ed7b54.zip
SONAR-12131 Compute Security Review Rating measures on projects
* Compute Security Review Rating measures on projects * Live update Security Review Rating measures
Diffstat (limited to 'sonar-plugin-api')
-rw-r--r--sonar-plugin-api/src/main/java/org/sonar/api/measures/CoreMetrics.java17
1 files changed, 17 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 6a7d13c32b7..4b2a1605da7 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
@@ -1506,6 +1506,23 @@ public final class CoreMetrics {
.setWorstValue(5.0)
.create();
+ /**
+ * @since 7.8
+ */
+ public static final String SECURITY_REVIEW_RATING_KEY = "security_review_rating";
+
+ /**
+ * @since 7.8
+ */
+ public static final Metric<Integer> SECURITY_REVIEW_RATING = new Metric.Builder(SECURITY_REVIEW_RATING_KEY, "Security Review Rating", Metric.ValueType.RATING)
+ .setDescription("Security Review Rating")
+ .setDomain(DOMAIN_SECURITY)
+ .setDirection(Metric.DIRECTION_WORST)
+ .setQualitative(true)
+ .setBestValue(1d)
+ .setWorstValue(5d)
+ .create();
+
// --------------------------------------------------------------------------------------------------------------------
//
// FILE DATA