Interface QualifierVaultAssignmentSession
- All Superinterfaces:
AutoCloseable, Closeable, OsidSession, OsidSession
This session provides methods to re-assign Qualifiers to
Vaults . A Qualifier may map to multiple Vaults and
removing the last reference to a Qualifier 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 a Qualifier to another Vault is
not a copy operation (eg: does not change its Id ).
-
Method Summary
Modifier and TypeMethodDescriptionvoidassignQualifierToVault(Id qualifierId, Id vaultId) Adds an existingQualifierto aVault.booleanTests if this user can alter qualifier/vault mappings.booleancanAssignQualifiersToVault(Id vaultId) Tests if this user can alter qualifier/vault mappings.getAssignableVaultIds(Id vaultId) Gets a list of vault including and under the given vault node in which any qualifier can be assigned.getAssignableVaultIdsForQualifier(Id vaultId, Id qualifierId) Gets a list of vault including and under the given vault node in which a specific qualifier can be assigned.voidreassignQualifierToVault(Id qualifierId, Id fromVaultId, Id toVaultId) Moves aQualifierfrom oneVaultto another.voidunassignQualifierFromVault(Id qualifierId, Id vaultId) Removes aQualifierfrom 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
-
canAssignQualifiers
boolean canAssignQualifiers()Tests if this user can alter qualifier/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 assignment operations to unauthorized users.- Returns:
falseif mapping is not authorized,trueotherwise- Compliance:
mandatory- This method must be implemented.
-
canAssignQualifiersToVault
Tests if this user can alter qualifier/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 assignment 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 vault including and under the given vault node in which any qualifier 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.
-
getAssignableVaultIdsForQualifier
IdList getAssignableVaultIdsForQualifier(Id vaultId, Id qualifierId) throws OperationFailedException Gets a list of vault including and under the given vault node in which a specific qualifier can be assigned.- Parameters:
vaultId- theIdof theVaultqualifierId- theIdof theQualifier- Returns:
- list of assignable vault
Ids - Throws:
NullArgumentException-vaultIdorqualifierIdisnullOperationFailedException- unable to complete request- Compliance:
mandatory- This method must be implemented.
-
assignQualifierToVault
void assignQualifierToVault(Id qualifierId, Id vaultId) throws AlreadyExistsException, NotFoundException, OperationFailedException, PermissionDeniedException Adds an existingQualifierto aVault.- Parameters:
qualifierId- theIdof theQualifiervaultId- theIdof theVault- Throws:
AlreadyExistsException-qualifierIdis already assigned tovaultIdNotFoundException-qualifierIdorvaultIdnot foundNullArgumentException-qualifierIdorvaultIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
unassignQualifierFromVault
void unassignQualifierFromVault(Id qualifierId, Id vaultId) throws NotFoundException, OperationFailedException, PermissionDeniedException Removes aQualifierfrom aVault.- Parameters:
qualifierId- theIdof theQualifiervaultId- theIdof theVault- Throws:
NotFoundException-qualifierIdorvaultIdnot found orqualifierIdnot assigned tovaultIdNullArgumentException-qualifierIdorvaultIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
reassignQualifierToVault
void reassignQualifierToVault(Id qualifierId, Id fromVaultId, Id toVaultId) throws AlreadyExistsException, NotFoundException, OperationFailedException, PermissionDeniedException Moves aQualifierfrom oneVaultto another. Mappings to otherVaultsare unaffected.- Parameters:
qualifierId- theIdof theQualifierfromVaultId- theIdof the currentVaulttoVaultId- theIdof the destinationVault- Throws:
AlreadyExistsException-qualifierIdalready assigned totoVaultIdNotFoundException-qualifierId, fromVaultId, ortoVaultIdnot found orqualifierId, not mapped tofromVaultIdNullArgumentException-qualifierId, fromVaultId, ortoVaultIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-