Class AccessControlContext


  • public class AccessControlContext
    extends Object
    This class permits to define the context of access to a resource.
    • Method Detail

      • init

        public static AccessControlContext init()
        Gets an initialized instance of access control context.
        Returns:
      • getOperations

        public Set<AccessControlOperation> getOperations()
        Gets the operations performed into the context.
        Returns:
      • put

        public <T> AccessControlContext put​(String key,
                                            T value)
        Puts into context a value linked to a key.
        Type Parameters:
        T -
        Parameters:
        key - the key.
        value - the value.
        Returns:
        the current instance.
      • get

        public <T> T get​(String key,
                         Class<T> classType)
        Gets from context a value from a key that has been stored into the context instance.
        Type Parameters:
        T -
        Parameters:
        key - the key associated to the searched value.
        classType - the type of expected value.
        Returns:
        the value if any, null if the expected type does not match with the one of the existing value.