Interface AuthorizationEnablerVaultAssignmentSession
- All Superinterfaces:
AutoCloseable, Closeable, OsidSession, 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 Summary
Modifier and TypeMethodDescriptionvoidassignAuthorizationEnablerToVault(Id authorizationEnablerId, Id vaultId) Adds an existingAuthorizationEnablerto aVault.booleanTests if this user can alter authorization enabler/vault mappings.booleancanAssignAuthorizationEnablersToVault(Id vaultId) Tests if this user can alter authorization enabler/vault mappings.getAssignableVaultIds(Id vaultId) Gets a list of vaults including and under the given vault node in which any authorization enabler can be assigned.getAssignableVaultIdsForAuthorizationEnabler(Id vaultId, Id authorizationEnablerId) Gets a list of vaults including and under the given vault node in which a specific authorization enabler can be assigned.voidreassignAuthorizationEnablerToVault(Id authorizationEnablerId, Id fromVaultId, Id toVaultId) Moves anAuthorizationEnablerfrom oneVaultto another.voidunassignAuthorizationEnablerFromVault(Id authorizationEnablerId, Id vaultId) Removes anAuthorizationEnablerfrom aVault.Methods inherited from interface OsidSession
closeMethods inherited from interface OsidSession
getAuthenticatedAgent, getAuthenticatedAgentId, getClockRate, getDate, getEffectiveAgent, getEffectiveAgentId, getFormatType, getLocale, isAuthenticated, startTransaction, supportsTransactionsModifier and TypeMethodDescriptionGets the agent authenticated to this session.Gets theIdof the agent authenticated to this session.Gets the rate of the service clock.getDate()Gets the service date which may be the current date or the effective date in which this session exists.Gets the effective agent in use by this session.Gets theIdof the effective agent in use by this session.Gets theDisplayTextformatTypepreference in effect for this session.Gets the locale indicating the localization preferences in effect for this session.booleanTests if an agent is authenticated to this session.Starts a new transaction for this sesson.booleanTests for the availability of transactions.
-
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 aPERMISSION_DENIED. This is intended as a hint to an application that may opt not to offer lookup operations to unauthorized users.- Returns:
falseif mapping is not authorized,trueotherwise- Compliance:
mandatory- This method must be implemented.
-
canAssignAuthorizationEnablersToVault
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 aPERMISSION_DENIED. This is intended as a hint to an application that may opt not to offer lookup operations to unauthorized users.- Parameters:
vaultId- theIdof theVault- Returns:
falseif mapping is not authorized,trueotherwise- Throws:
NullArgumentException-vaultIdisnull- Compliance:
mandatory- This method must be implemented.
-
getAssignableVaultIds
Gets a list of vaults including and under the given vault node in which any authorization enabler can be assigned.- Parameters:
vaultId- theIdof theVault- Returns:
- list of assignable vault
Ids - Throws:
NullArgumentException-vaultIdisnullOperationFailedException- 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- theIdof theVaultauthorizationEnablerId- theIdof theAuthorizationEnabler- Returns:
- list of assignable vault
Ids - Throws:
NullArgumentException-vaultIdorauthorizationEnablerIdisnullOperationFailedException- 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 existingAuthorizationEnablerto aVault.- Parameters:
authorizationEnablerId- theIdof theAuthorizationEnablervaultId- theIdof theVault- Throws:
AlreadyExistsException-authorizationEnablerIdalready assigned tovaultINotFoundException-authorizationEnablerIdorvaultIdnot foundNullArgumentException-authorizationEnablerIdorvaultIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
unassignAuthorizationEnablerFromVault
void unassignAuthorizationEnablerFromVault(Id authorizationEnablerId, Id vaultId) throws NotFoundException, OperationFailedException, PermissionDeniedException Removes anAuthorizationEnablerfrom aVault.- Parameters:
authorizationEnablerId- theIdof theAuthorizationEnablervaultId- theIdof theVault- Throws:
NotFoundException-authorizationEnablerIdorvaultIdnot found orauthorizationEnablerIdnot assigned tovaultIdNullArgumentException-authorizationEnablerIdorvaultIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
reassignAuthorizationEnablerToVault
void reassignAuthorizationEnablerToVault(Id authorizationEnablerId, Id fromVaultId, Id toVaultId) throws AlreadyExistsException, NotFoundException, OperationFailedException, PermissionDeniedException Moves anAuthorizationEnablerfrom oneVaultto another. Mappings to otherVaultsare unaffected.- Parameters:
authorizationEnablerId- theIdof theAuthorizationEnablerfromVaultId- theIdof the currentVaulttoVaultId- theIdof the destinationVault- Throws:
AlreadyExistsException-authorizationEnablerIdalready assigned totoUVaultIdNotFoundException-authorizationEnablerId, fromVaultId, ortoVaultIdnot found orauthorizationEnablerIdnot mapped tofromVaultIdNullArgumentException-authorizationEnablerId, fromVaultId, ortoVaultIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-