Interface AuthorizationEnablerVaultAssignmentSession

All Superinterfaces:
AutoCloseable, Closeable, OsidSession, OsidSession

public interface AuthorizationEnablerVaultAssignmentSession extends OsidSession

This session provides methods to re-assign AuthorizationEnabler to Vault mappings. An AuthorizationEnabler may appear in multiple Vaults and removing the last reference to an AuthorizationEnabler is the equivalent of deleting it. Each Vault may have its own authorizations governing who is allowed to operate on it.

Adding a reference of an AuthorizationEnabler to another Vault is not a copy operation (eg: does not change its Id ).

  • Method Details

    • canAssignAuthorizationEnablers

      boolean canAssignAuthorizationEnablers()
      Tests if this user can alter authorization enabler/vault 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.
    • canAssignAuthorizationEnablersToVault

      boolean canAssignAuthorizationEnablersToVault(Id vaultId)
      Tests if this user can alter authorization enabler/vault 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.
      Parameters:
      vaultId - the Id of the Vault
      Returns:
      false if mapping is not authorized, true otherwise
      Throws:
      NullArgumentException - vaultId is null
      Compliance:
      mandatory - This method must be implemented.
    • getAssignableVaultIds

      IdList getAssignableVaultIds(Id vaultId) throws OperationFailedException
      Gets a list of vaults including and under the given vault node in which any authorization enabler can be assigned.
      Parameters:
      vaultId - the Id of the Vault
      Returns:
      list of assignable vault Ids
      Throws:
      NullArgumentException - vaultId is null
      OperationFailedException - unable to complete request
      Compliance:
      mandatory - This method must be implemented.
    • getAssignableVaultIdsForAuthorizationEnabler

      IdList getAssignableVaultIdsForAuthorizationEnabler(Id vaultId, Id authorizationEnablerId) throws OperationFailedException
      Gets a list of vaults including and under the given vault node in which a specific authorization enabler can be assigned.
      Parameters:
      vaultId - the Id of the Vault
      authorizationEnablerId - the Id of the AuthorizationEnabler
      Returns:
      list of assignable vault Ids
      Throws:
      NullArgumentException - vaultId or authorizationEnablerId is null
      OperationFailedException - unable to complete request
      Compliance:
      mandatory - This method must be implemented.
    • assignAuthorizationEnablerToVault

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

      void unassignAuthorizationEnablerFromVault(Id authorizationEnablerId, Id vaultId) throws NotFoundException, OperationFailedException, PermissionDeniedException
      Removes an AuthorizationEnabler from a Vault .
      Parameters:
      authorizationEnablerId - the Id of the AuthorizationEnabler
      vaultId - the Id of the Vault
      Throws:
      NotFoundException - authorizationEnablerId or vaultId not found or authorizationEnablerId not assigned to vaultId
      NullArgumentException - authorizationEnablerId or vaultId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • reassignAuthorizationEnablerToVault

      void reassignAuthorizationEnablerToVault(Id authorizationEnablerId, Id fromVaultId, Id toVaultId) throws AlreadyExistsException, NotFoundException, OperationFailedException, PermissionDeniedException
      Moves an AuthorizationEnabler from one Vault to another. Mappings to other Vaults are unaffected.
      Parameters:
      authorizationEnablerId - the Id of the AuthorizationEnabler
      fromVaultId - the Id of the current Vault
      toVaultId - the Id of the destination Vault
      Throws:
      AlreadyExistsException - authorizationEnablerId already assigned to toUVaultId
      NotFoundException - authorizationEnablerId, fromVaultId , or toVaultId not found or authorizationEnablerId not mapped to fromVaultId
      NullArgumentException - authorizationEnablerId, fromVaultId , or toVaultId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.