Annotation Interface RequiresAnyPermission
@ExperimentalJSentinelApi
@Retention(RUNTIME)
@Target({TYPE,METHOD})
public @interface RequiresAnyPermission
Requires the current subject to hold at least one
of the listed permissions (OR-semantics).
Contrast with RequiresPermission, which requires
all listed permissions. Pick @RequiresAnyPermission
when the admission rule is "subject has read- OR write-access on this
resource", and RequiresAllPermissions when the rule is
"subject has both X and Y" — the latter being explicit about the
AND-semantics that @RequiresPermission also offers.
-
Required Element Summary
Required Elements
-
Element Details
-
value
String[] valueRequired permission names. At least one must be held by the authenticated subject for access to be granted.- Returns:
- permission names; must contain at least one entry
-