aboutsummaryrefslogtreecommitdiffstats
path: root/sonar-plugin-api/src/main/java/org/sonar/api/web/UserRole.java
diff options
context:
space:
mode:
Diffstat (limited to 'sonar-plugin-api/src/main/java/org/sonar/api/web/UserRole.java')
-rw-r--r--sonar-plugin-api/src/main/java/org/sonar/api/web/UserRole.java9
1 files changed, 9 insertions, 0 deletions
diff --git a/sonar-plugin-api/src/main/java/org/sonar/api/web/UserRole.java b/sonar-plugin-api/src/main/java/org/sonar/api/web/UserRole.java
index 196218cdc51..fb582ea5b7c 100644
--- a/sonar-plugin-api/src/main/java/org/sonar/api/web/UserRole.java
+++ b/sonar-plugin-api/src/main/java/org/sonar/api/web/UserRole.java
@@ -23,6 +23,10 @@ import java.lang.annotation.ElementType;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;
+import java.util.Arrays;
+import java.util.Collections;
+import java.util.HashSet;
+import java.util.Set;
/**
* @since 1.11
@@ -49,4 +53,9 @@ public @interface UserRole {
String[] value() default {};
+ /**
+ * Permissions which are implicitly available for any user, any group and to group "AnyOne" on public components.
+ */
+ Set<String> PUBLIC_PERMISSIONS = Collections.unmodifiableSet(new HashSet<>(Arrays.asList(UserRole.USER, UserRole.CODEVIEWER)));
+
}