OSID Logo
OSID Specifications
repository rules package
Version 3.0.0
Release Candidate Preview
Interfaceosid.repository.rules.CompositionEnablerAdminSession
Implementsosid.OsidSession
Description

This session creates and removes composition enablers. The data for create and update is provided via the CompositionEnablerForm.

MethodgetRepositoryId
Description

Gets the Repository Id associated with this session.

Returnosid.id.Idthe Repository Id associated with this session
CompliancemandatoryThis method must be implemented.
MethodgetRepository
Description

Gets the Repository associated with this session.

Returnosid.repository.Repositorythe repository
ErrorsOPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodcanCreateCompositionEnabler
Description

Tests if this user can create composition enablers. A return of true does not guarantee successful authorization. A return of false indicates that it is known creating a CompositionEnabler 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 CompositionEnabler creation is not authorized, true otherwise
CompliancemandatoryThis method must be implemented.
MethodcanCreateCompositionEnablerWithRecordTypes
Description

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

Parametersosid.type.Type[]compositionEnablerRecordTypesarray of composition enabler types
Returnboolean true if CompositionEnabler creation using the specified record Types is supported, false otherwise
ErrorsNULL_ARGUMENT compositionEnablerRecordTypes is null
CompliancemandatoryThis method must be implemented.
MethodgetCompositionEnablerFormForCreate
Description

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

Parametersosid.type.Type[]compositionEnablerRecordTypesarray of composition enabler types
Returnosid.repository.rules.CompositionEnablerFormthe composition enabler form
ErrorsNULL_ARGUMENT compositionEnablerRecordTypes is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
UNSUPPORTEDunable to get form for requested record types
CompliancemandatoryThis method must be implemented.
MethodcreateCompositionEnabler
Description

Creates a new CompositionEnabler.

Parametersosid.repository.rules.CompositionEnablerFormcompositionEnablerFormthe form for this CompositionEnabler
Returnosid.repository.rules.CompositionEnablerthe new CompositionEnabler
ErrorsILLEGAL_STATE compositionEnablerForm already used in a create transaction
INVALID_ARGUMENTone or more of the form elements is invalid
NULL_ARGUMENT compositionEnablerForm is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
UNSUPPORTED compositionEnablerForm did not originate from getCompositionEnablerFormForCreate()
CompliancemandatoryThis method must be implemented.
MethodcanUpdateCompositionEnablers
Description

Tests if this user can update composition enablers. A return of true does not guarantee successful authorization. A return of false indicates that it is known updating a CompositionEnabler 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 CompositionEnabler modification is not authorized, true otherwise
CompliancemandatoryThis method must be implemented.
MethodgetCompositionEnablerFormForUpdate
Description

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

Parametersosid.id.IdcompositionEnablerIdthe Id of the CompositionEnabler
Returnosid.repository.rules.CompositionEnablerFormthe composition enabler form
ErrorsNOT_FOUND compositionEnablerId is not found
NULL_ARGUMENT compositionEnablerId is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodupdateCompositionEnabler
Description

Updates an existing composition enabler.

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

Tests if this user can delete composition enablers. A return of true does not guarantee successful authorization. A return of false indicates that it is known deleting a CompositionEnabler 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 CompositionEnabler deletion is not authorized, true otherwise
CompliancemandatoryThis method must be implemented.
MethoddeleteCompositionEnabler
Description

Deletes a CompositionEnabler.

Parametersosid.id.IdcompositionEnablerIdthe Id of the CompositionEnabler to remove
ErrorsNOT_FOUND compositionEnablerId not found
NULL_ARGUMENT compositionEnablerId is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodcanManageCompositionEnablerAliases
Description

Tests if this user can manage Id aliases for composition 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 CompositionEnabler aliasing is not authorized, true otherwise
CompliancemandatoryThis method must be implemented.
MethodaliasCompositionEnabler
Description

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

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