Interface CanonicalUnitEnablerCatalogueAssignmentSession
- All Superinterfaces:
AutoCloseable, Closeable, OsidSession, OsidSession
This session provides methods to re-assign CanonicalUnitEnabler
to Catalogue mappings. A CanonicalUnitEnabler may appear
in multiple Catalogue objects and removing the last reference to a
CanonicalUnitEnabler is the equivalent of deleting it. Each
Catalogue may have its own authorizations governing who is allowed to
operate on it.
Adding a reference of a CanonicalUnitEnabler to another
Catalogue is not a copy operation (eg: does not change its Id ).
-
Method Summary
Modifier and TypeMethodDescriptionvoidassignCanonicalUnitEnablerToCatalogue(Id canonicalUnitEnablerId, Id catalogueId) Adds an existingCanonicalUnitEnablerto aCatalogue.booleanTests if this user can alter canonical unit enabler/catalogue mappings.booleancanAssignCanonicalUnitEnablersToCatalogue(Id catalogueId) Tests if this user can alter canonical unit enabler/catalogue mappings.getAssignableCatalogueIds(Id catalogueId) Gets a list of catalogues including and under the given catalogue node in which any canonical unit enabler can be assigned.getAssignableCatalogueIdsForCanonicalUnitEnabler(Id catalogueId, Id canonicalUnitEnablerId) Gets a list of catalogues including and under the given catalogue node in which a specific canonical unit enabler can be assigned.voidreassignCanonicalUnitEnablerToCatalogue(Id canonicalUnitEnablerId, Id fromCatalogueId, Id toCatalogueId) Moves aCanonicalUnitEnablerrfrom oneCatalogueto another.voidunassignCanonicalUnitEnablerFromCatalogue(Id canonicalUnitEnablerId, Id catalogueId) Removes aCanonicalUnitEnablerfrom aCatalogue.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
-
canAssignCanonicalUnitEnablers
boolean canAssignCanonicalUnitEnablers()Tests if this user can alter canonical unit enabler/catalogue 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.
-
canAssignCanonicalUnitEnablersToCatalogue
Tests if this user can alter canonical unit enabler/catalogue 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:
catalogueId- theIdof theCatalogue- Returns:
falseif mapping is not authorized,trueotherwise- Throws:
NullArgumentException-catalogueIdisnull- Compliance:
mandatory- This method must be implemented.
-
getAssignableCatalogueIds
Gets a list of catalogues including and under the given catalogue node in which any canonical unit enabler can be assigned.- Parameters:
catalogueId- theIdof theCatalogue- Returns:
- list of assignable catalogue
Ids - Throws:
NullArgumentException-catalogueIdisnullOperationFailedException- unable to complete request- Compliance:
mandatory- This method must be implemented.
-
getAssignableCatalogueIdsForCanonicalUnitEnabler
IdList getAssignableCatalogueIdsForCanonicalUnitEnabler(Id catalogueId, Id canonicalUnitEnablerId) throws OperationFailedException Gets a list of catalogues including and under the given catalogue node in which a specific canonical unit enabler can be assigned.- Parameters:
catalogueId- theIdof theCataloguecanonicalUnitEnablerId- theIdof theCanonicalUnitEnabler- Returns:
- list of assignable catalogue
Ids - Throws:
NullArgumentException-catalogueIdorcanonicalUnitEnablerIdisnullOperationFailedException- unable to complete request- Compliance:
mandatory- This method must be implemented.
-
assignCanonicalUnitEnablerToCatalogue
void assignCanonicalUnitEnablerToCatalogue(Id canonicalUnitEnablerId, Id catalogueId) throws AlreadyExistsException, NotFoundException, OperationFailedException, PermissionDeniedException Adds an existingCanonicalUnitEnablerto aCatalogue.- Parameters:
canonicalUnitEnablerId- theIdof theCanonicalUnitEnablercatalogueId- theIdof theCatalogue- Throws:
AlreadyExistsException-canonicalUnitEnablerIdalready assigned tocatalogueIdNotFoundException-canonicalUnitEnablerIdorcatalogueIdnot foundNullArgumentException-canonicalUnitEnablerIdorcatalogueIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
unassignCanonicalUnitEnablerFromCatalogue
void unassignCanonicalUnitEnablerFromCatalogue(Id canonicalUnitEnablerId, Id catalogueId) throws NotFoundException, OperationFailedException, PermissionDeniedException Removes aCanonicalUnitEnablerfrom aCatalogue.- Parameters:
canonicalUnitEnablerId- theIdof theCanonicalUnitEnablercatalogueId- theIdof theCatalogue- Throws:
NotFoundException-canonicalUnitEnablerIdorcatalogueIdnot found orcanonicalUnitEnablerIdalready assigned tocatalogueIdNullArgumentException-canonicalUnitEnablerIdorcatalogueIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
reassignCanonicalUnitEnablerToCatalogue
void reassignCanonicalUnitEnablerToCatalogue(Id canonicalUnitEnablerId, Id fromCatalogueId, Id toCatalogueId) throws AlreadyExistsException, NotFoundException, OperationFailedException, PermissionDeniedException Moves aCanonicalUnitEnablerrfrom oneCatalogueto another. Mappings to otherCataloguesare unaffected.- Parameters:
canonicalUnitEnablerId- theIdof theCanonicalUnitEnablerfromCatalogueId- theIdof the currentCataloguetoCatalogueId- theIdof the destinationCatalogue- Throws:
AlreadyExistsException-canonicalUnitEnablerIdalready assigned totoCatalogueIdNotFoundException-canonicalUnitEnablerId, fromCatalogueId, ortoCatalogueIdnot found orcanonicalUnitEnablerId, not mapped tofromCatalogueIdNullArgumentException-canonicalUnitEnablerId, fromCatalogueId, ortoCatalogueIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-