Class SecurityAnnotations


  • public final class SecurityAnnotations
    extends java.lang.Object
    Convenience utility methods for creating instances of security annotations.
    • Constructor Summary

      Constructors 
      Modifier Constructor Description
      private SecurityAnnotations()
      Prevent instantiation.
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static javax.annotation.security.DenyAll denyAll()
      Create DenyAll annotation implementation.
      static javax.annotation.security.PermitAll permitAll()
      Create PermitAll annotation implementation.
      static javax.annotation.security.RolesAllowed rolesAllowed​(java.lang.String... roles)
      Create RolesAllowed annotation implementation for given set of roles.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • SecurityAnnotations

        private SecurityAnnotations()
        Prevent instantiation.
    • Method Detail

      • rolesAllowed

        public static javax.annotation.security.RolesAllowed rolesAllowed​(java.lang.String... roles)
        Create RolesAllowed annotation implementation for given set of roles.
        Parameters:
        roles - roles to be part of the annotation.
        Returns:
        annotation implementation.
      • permitAll

        public static javax.annotation.security.PermitAll permitAll()
        Create PermitAll annotation implementation.
        Returns:
        annotation implementation.
      • denyAll

        public static javax.annotation.security.DenyAll denyAll()
        Create DenyAll annotation implementation.
        Returns:
        annotation implementation.