Class IsAdminRule

  • All Implemented Interfaces:
    AuthorizationRule

    public class IsAdminRule
    extends java.lang.Object
    implements AuthorizationRule
    Author:
    Emmanuel Duchastenier, Anthony Birembaut
    • Constructor Summary

      Constructors 
      Constructor Description
      IsAdminRule()  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.lang.String getId()  
      boolean isAllowed​(java.lang.String key, java.util.Map<java.lang.String,​java.io.Serializable> context)
      Execute this rule and, according to the context, says whether the rule is valid.
      • Methods inherited from class java.lang.Object

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

      • IsAdminRule

        public IsAdminRule()
    • Method Detail

      • isAllowed

        public boolean isAllowed​(java.lang.String key,
                                 java.util.Map<java.lang.String,​java.io.Serializable> context)
        Description copied from interface: AuthorizationRule
        Execute this rule and, according to the context, says whether the rule is valid.
        Specified by:
        isAllowed in interface AuthorizationRule
        Parameters:
        key - the page mapping key
        context - the information necessary to execute this rule.
        Returns:
        true if allowed, false otherwise.If determination cannot be fulfilled, an Exception should be thrown.
      • getId

        public java.lang.String getId()
        Specified by:
        getId in interface AuthorizationRule
        Returns:
        the identifier for this authorization rule