OSID Logo
OSID Specifications
repository package
Version 3.1.0
Interfaceosid.repository.AssetContentRepositoryAssignmentSession
Implementsosid.OsidSession
Used Byosid.repository.RepositoryManager
osid.repository.RepositoryProxyManager
Description

This session provides methods to re-assign AssetContents to Repository mappings. An AssetContent may appear in multiple Repository catalogs and removing the last reference to an AssetContent is the equivalent of deleting it. Each Repository may have its own authorizations governing who is allowed to operate on it.

Adding a reference of an AssetContent to another Repository is n ot a copy operation (eg: does not change its Id).

MethodcanAssignAssetContents
Description

Tests if this user can alter asset content/repository 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 a PERMISSION_DENIED. T his is intended as a hint to an application that may opt not to offer assignment operations to unauthorized users.

Returnboolean false if mapping is not authorized, true otherwise
Compliancemandatory This method must be implemented.
MethodcanAssignAssetContentToRepository
Description

Tests if this user can alter asset content/repository 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 a PERMISSION_DENIED. T his is intended as a hint to an application that may opt not to offer assignment operations to unauthorized users.

Parametersosid.id.IdrepositoryId the Id of the Repository
Returnboolean false if mapping is not authorized, true otherwise
ErrorsNULL_ARGUMENT repositoryId is null
Compliancemandatory This method must be implemented.
MethodgetAssignableRepositoryIds
Description

Gets a list of repositories including and under the given repository node in which any asset content can be assigned.

Parametersosid.id.IdrepositoryId the Id of the Repository
Returnosid.id.IdList list of assignable repository Ids
ErrorsNULL_ARGUMENT repositoryId is null
OPERATION_FAILED unable to complete request
Compliancemandatory This method must be implemented.
MethodgetAssignableRepositoryIdsForAssetContent
Description

Gets a list of repositories including and under the given repository node in which a specific asset content can be assigned.

Parametersosid.id.IdrepositoryId the Id of the Repository
osid.id.IdassetContentId the Id of the AssetContent
Returnosid.id.IdList list of assignable repository Ids
ErrorsNULL_ARGUMENT repositoryId or assetContentId is null
OPERATION_FAILED unable to complete request
Compliancemandatory This method must be implemented.
MethodassignAssetContentToRepository
Description

Adds an existing AssetContent to a Repository.

Parametersosid.id.IdassetContentId the Id of the AssetContent
osid.id.IdrepositoryId the Id of the Repository
ErrorsALREADY_EXISTS assetContentId is already assigned to repositoryId
NOT_FOUND assetContentId or repositoryId not found
NULL_ARGUMENT assetContentId or repositoryId is null
OPERATION_FAILED unable to complete request
PERMISSION_DENIED authorization failure
Compliancemandatory This method must be implemented.
MethodunassignAssetContentFromRepository
Description

Removes an AssetContent from a Repository.

Parametersosid.id.IdassetContentId the Id of the AssetContent
osid.id.IdrepositoryId the Id of the Repository
ErrorsNOT_FOUND assetContentId or repositoryId not found or assetContentId not assigned to repositoryId
NULL_ARGUMENT assetContentId or repositoryId is null
OPERATION_FAILED unable to complete request
PERMISSION_DENIED authorization failure
Compliancemandatory This method must be implemented.
MethodreassignAssetContentToRepository
Description

Moves an AssetContent from one Repository to another. Mappings to other Repositories are unaffected.

Parametersosid.id.IdassetContentId the Id of the AssetContent
osid.id.IdfromRepositoryId the Id of the current Repository
osid.id.IdtoRepositoryId the Id of the destination Repository
ErrorsALREADY_EXISTS assetContentId already assigned to torepositoryId
NOT_FOUND assetContentId, fromRepositoryId, or toRepositoryeId not found or assetContentId not mapped to fromRepositoryId
NULL_ARGUMENT assetContentId, fromRepositoryId, or toRepositoryId is null
OPERATION_FAILED unable to complete request
PERMISSION_DENIED authorization failure
Compliancemandatory This method must be implemented.