OSID Logo
OSID Specifications
offering rules package
Version 3.0.0
Release Candidate Preview
Interfaceosid.offering.rules.CanonicalUnitEnablerAdminSession
Implementsosid.OsidSession
Description

This session creates and removes canonical unit enablers. The data for create and update is provided via the CanonicalUnitEnablerForm.

MethodgetCatalogueId
Description

Gets the Catalogue Id associated with this session.

Returnosid.id.Idthe Catalogue Id associated with this session
CompliancemandatoryThis method must be implemented.
MethodgetCatalogue
Description

Gets the Catalogue associated with this session.

Returnosid.offering.Cataloguethe catalogue
ErrorsOPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodcanCreateCanonicalUnitEnabler
Description

Tests if this user can create canonical unit enablers. A return of true does not guarantee successful authorization. A return of false indicates that it is known creating a CanonicalUnitEnabler will result in a PERMISSION_DENIED. This is intended as a hint to an application that may opt not to offer create operations to an unauthorized user.

Returnboolean false if CanonicalUnitEnabler creation is not authorized, true otherwise
CompliancemandatoryThis method must be implemented.
MethodcanCreateCanonicalUnitEnablerWithRecordTypes
Description

Tests if this user can create a single CanonicalUnitEnabler using the desired record types. While OfferingRulesManager.getCanonicalUnitEnablerRecordTypes() can be used to examine which records are supported, this method tests which record(s) are required for creating a specific CanonicalUnitEnabler. Providing an empty array tests if a CanonicalUnitEnabler can be created with no records.

Parametersosid.type.Type[]canonicalUnitEnablerRecordTypesarray of canonical unit enabler record types
Returnboolean true if CanonicalUnitEnabler creation using the specified record Types is supported, false otherwise
ErrorsNULL_ARGUMENT canonicalUnitEnablerRecordTypes is null
CompliancemandatoryThis method must be implemented.
MethodgetCanonicalUnitEnablerFormForCreate
Description

Gets the canonical unit enabler form for creating new canonical unit enablers. A new form should be requested for each create transaction.

Parametersosid.type.Type[]canonicalUnitEnablerRecordTypesarray of canonical unit enabler record types
Returnosid.offering.rules.CanonicalUnitEnablerFormthe canonical unit enabler form
ErrorsNULL_ARGUMENT canonicalUnitEnablerRecordTypes is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
UNSUPPORTEDunable to get form for requested record types
CompliancemandatoryThis method must be implemented.
MethodcreateCanonicalUnitEnabler
Description

Creates a new CanonicalUnitEnabler.

Parametersosid.offering.rules.CanonicalUnitEnablerFormcanonicalUnitEnablerFormthe form for this CanonicalUnitEnabler
Returnosid.offering.rules.CanonicalUnitEnablerthe new CanonicalUnitEnabler
ErrorsILLEGAL_STATE canonicalUnitEnablerForm already used in a create transaction
INVALID_ARGUMENTone or more of the form elements is invalid
NULL_ARGUMENT canonicalUnitEnablerForm is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
UNSUPPORTED canonicalUnitEnablerForm did not originate from getCanonicalUnitEnablerFormForCreate()
CompliancemandatoryThis method must be implemented.
MethodcanUpdateCanonicalUnitEnablers
Description

Tests if this user can update canonical unit enablers. A return of true does not guarantee successful authorization. A return of false indicates that it is known updating a CanonicalUnitEnabler will result in a PERMISSION_DENIED. This is intended as a hint to an application that may opt not to offer update operations to an unauthorized user.

Returnboolean false if CanonicalUnitEnabler modification is not authorized, true otherwise
CompliancemandatoryThis method must be implemented.
MethodgetCanonicalUnitEnablerFormForUpdate
Description

Gets the canonical unit enabler form for updating an existing canonical unit enabler. A new canonical unit enabler form should be requested for each update transaction.

Parametersosid.id.IdcanonicalUnitEnablerIdthe Id of the CanonicalUnitEnabler
Returnosid.offering.rules.CanonicalUnitEnablerFormthe canonical unit enabler form
ErrorsNOT_FOUND canonicalUnitEnablerId is not found
NULL_ARGUMENT canonicalUnitEnablerId is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodupdateCanonicalUnitEnabler
Description

Updates an existing canonical unit enabler.

Parametersosid.offering.rules.CanonicalUnitEnablerFormcanonicalUnitEnablerFormthe form containing the elements to be updated
ErrorsILLEGAL_STATE canonicalUnitEnablerForm already used in an update transaction
INVALID_ARGUMENTthe form contains an invalid value
NULL_ARGUMENT canonicalUnitEnablerForm is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
UNSUPPORTED canonicalUnitEnablerForm did not originate from getCanonicalUnitEnablerFormForUpdate()
CompliancemandatoryThis method must be implemented.
MethodcanDeleteCanonicalUnitEnablers
Description

Tests if this user can delete canonical unit enablers. A return of true does not guarantee successful authorization. A return of false indicates that it is known deleting a CanonicalUnitEnabler will result in a PERMISSION_DENIED. This is intended as a hint to an application that may opt not to offer delete operations to an unauthorized user.

Returnboolean false if CanonicalUnitEnabler deletion is not authorized, true otherwise
CompliancemandatoryThis method must be implemented.
MethoddeleteCanonicalUnitEnabler
Description

Deletes a CanonicalUnitEnabler.

Parametersosid.id.IdcanonicalUnitEnablerIdthe Id of the CanonicalUnitEnabler to remove
ErrorsNOT_FOUND canonicalUnitEnablerId not found
NULL_ARGUMENT canonicalUnitEnablerId is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodcanManageCanonicalUnitEnablerAliases
Description

Tests if this user can manage Id aliases for canonical unit enablers. A return of true does not guarantee successful authorization. A return of false indicates that it is known changing an alias will result in a PERMISSION_DENIED. This is intended as a hint to an application that may opt not to offer alias operations to an unauthorized user.

Returnboolean false if CanonicalUnitEnabler aliasing is not authorized, true otherwise
CompliancemandatoryThis method must be implemented.
MethodaliasCanonicalUnitEnabler
Description

Adds an Id to a CanonicalUnitEnabler for the purpose of creating compatibility. The primary Id of the CanonicalUnitEnabler is determined by the provider. The new Id performs as an alias to the primary Id . If the alias is a pointer to another canonical unit enabler. it is reassigned to the given canonical unit enabler Id.

Parametersosid.id.IdcanonicalUnitEnablerIdthe Id of a CanonicalUnitEnabler
osid.id.IdaliasIdthe alias Id
ErrorsALREADY_EXISTS aliasId is already assigned
NOT_FOUND canonicalUnitEnablerId not found
NULL_ARGUMENT canonicalUnitEnablerId or aliasId is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.