Interface AuthorizationEnablerRuleApplicationSession

All Superinterfaces:
AutoCloseable, Closeable, OsidSession, OsidSession

public interface AuthorizationEnablerRuleApplicationSession extends OsidSession

This session provides methods to apply AuthorizationEnablers to Authorizations. An Authorization with multiple AuthorizationEnablers means any positive rule evaluation across the enablers result in an effective Authorization.

  • Method Details

    • getVaultId

      Id getVaultId()
      Gets the Vault Id associated with this session.
      Returns:
      the Vault Id associated with this session
      Compliance:
      mandatory - This method must be implemented.
    • getVault

      Gets the Vault associated with this session.
      Returns:
      the vault
      Throws:
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • canAssignAuthorizationEnablers

      boolean canAssignAuthorizationEnablers()
      Tests if this user can alter authorization enabler/authorization mappings. A return of true does not guarantee successful authorization. A return of false indicates that it is known mapping methods in this session will result in a PERMISSION_DENIED. This is intended as a hint to an application that may opt not to offer lookup operations to unauthorized users.
      Returns:
      false if mapping is not authorized, true otherwise
      Compliance:
      mandatory - This method must be implemented.
    • assignAuthorizationEnablerToAuthorization

      void assignAuthorizationEnablerToAuthorization(Id authorizationEnablerId, Id authorizationId) throws AlreadyExistsException, NotFoundException, OperationFailedException, PermissionDeniedException
      Adds an existing AuthorizationEnabler to an Authorization.
      Parameters:
      authorizationEnablerId - the Id of the AuthorizationEnabler
      authorizationId - the Id of the Authorization
      Throws:
      AlreadyExistsException - authorizationEnablerId already assigned to authorizationId
      NotFoundException - authorizationEnablerId or authorizationId not found
      NullArgumentException - authorizationEnablerId or authorizationId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • unassignAuthorizationEnablerFromAuthorization

      void unassignAuthorizationEnablerFromAuthorization(Id authorizationEnablerId, Id authorizationId) throws NotFoundException, OperationFailedException, PermissionDeniedException
      Removes an AuthorizationEnabler from an Authorization.
      Parameters:
      authorizationEnablerId - the Id of the AuthorizationEnabler
      authorizationId - the Id of the Authorization
      Throws:
      NotFoundException - authorizationEnablerId or authorizationId not found or not mapped
      NullArgumentException - authorizationEnablerId or authorizationId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • canSequenceAuthorizationEnablers

      boolean canSequenceAuthorizationEnablers()
      Tests if this user can order AuthorizationEnablers. A return of true does not guarantee successful authorization. A return of false indicates that it is known sequencing operations will result in a PERMISSION_DENIED. This is intended as a hint to an application that may opt not to offer sequencing operations to an unauthorized user.
      Returns:
      false if AuthorizationEnabler ordering is not authorized, true otherwise
      Compliance:
      mandatory - This method must be implemented.
    • moveAuthorizationEnablerAhead

      void moveAuthorizationEnablerAhead(Id authorizationEnablerId, Id authorizationId, Id referenceId) throws NotFoundException, OperationFailedException, PermissionDeniedException
      Reorders authorization enablers for an authorization by moving the specified authorization enabler in front of a reference authorization enabler.
      Parameters:
      authorizationEnablerId - the Id of an AuthorizationEnabler
      authorizationId - the Id of an Authorization
      referenceId - the reference authorization enabler Id
      Throws:
      NotFoundException - authorizationEnablerId, authorizationId, or referenceId not found or, authorizationEnablerId or referenceId not related to authorizationId
      NullArgumentException - authorizationEnablerId, authorizationId, or referenceId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • moveAuthorizationEnablerBehind

      void moveAuthorizationEnablerBehind(Id authorizationEnablerId, Id authorizationId, Id referenceId) throws NotFoundException, OperationFailedException, PermissionDeniedException
      Reorders authorization enablers for an authorization by moving the specified authorization enabler behind a reference authorization enabler.
      Parameters:
      authorizationEnablerId - the Id of an AuthorizationEnabler
      authorizationId - the Id of an Authorization
      referenceId - the reference authorization enabler Id
      Throws:
      NotFoundException - authorizationEnabelrId, authorizationId, or referenceId not found or, authorizationEnablerId or referenceId not related to authorizationId
      NullArgumentException - authorizationEnablerId, authorizationId, or referenceId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • orderAuthorizationEnablers

      void orderAuthorizationEnablers(Id[] authorizationEnablerIds, Id authorizationId) throws NotFoundException, OperationFailedException, PermissionDeniedException
      Reorders a set of authorization enablers for an authorization.
      Parameters:
      authorizationEnablerIds - the Ids for a set of AuthorizationEnablers
      authorizationId - the Id of an Authorization
      Throws:
      NotFoundException - authorizationId not found or, an authorizationEnablerId not related to authorizationId
      NullArgumentException - authorizationEnablerIds or authorizationId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.