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

This session defines methods to receive notifications on adds/changes to Asset objects in this Repository. This also includes existing assets that may appear or disappear due to changes in the Repository hierarchy, This session is intended for consumers needing to synchronize their state with this service without the use of polling. Notifications are cancelled when this session is closed.

The two views defined in this session correspond to the views in the AssetLookupSession.

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 associated with this session
ErrorsOPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodcanRegisterForAssetNotifications
Description

Tests if this user can register for Asset notifications. A return of true does not guarantee successful authorization. A return of false indicates that it is known all methods in this session will result in a PERMISSION_DENIED. This is intended as a hint to an application that may opt not to offer notification operations.

Returnboolean false if notification methods are not authorized, true otherwise
CompliancemandatoryThis method must be implemented.
MethoduseFederatedRepositoryView
Description

Federates the view for methods in this session. A federated view will include assets in repositories which are children of this repository in the repository hierarchy.

CompliancemandatoryThis method is must be implemented.
MethoduseIsolatedRepositoryView
Description

Isolates the view for methods in this session. An isolated view restricts notifications to this repository only.

CompliancemandatoryThis method is must be implemented.
MethodregisterForNewAssets
Description

Register for notifications of new assets. AssetReceiver.newAssets() is invoked when a new Asset appears in this repository.

ErrorsOPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodregisterForNewAssetsByGenusType
Description

Registers for notification of new assets of the given asset genus type. AssetReceiver.newAssets() is invoked when an asset is appears in this repository.

Parametersosid.type.TypeassetGenusTypethe genus type of the Asset to monitor
ErrorsNULL_ARGUMENT assetGenusType is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodregisterForChangedAssets
Description

Registers for notification of updated assets. AssetReceiver.changedAssets() is invoked when an asset in this repository is changed.

ErrorsOPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodregisterForChangedAssetsByGenusType
Description

Registers for notification of updated assets of the given asset genus type. AssetReceiver.changedAssets() is invoked when an asset in this repository is changed.

Parametersosid.type.TypeassetGenusTypethe genus type of the Asset to monitor
ErrorsNULL_ARGUMENT assetGenusType is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodregisterForChangedAsset
Description

Registers for notification of an updated asset. AssetReceiver.changedAssets() is invoked when the specified asset in this repository is changed.

Parametersosid.id.IdassetIdthe Id of the Asset to monitor
ErrorsNULL_ARGUMENT assetId is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodregisterForDeletedAssets
Description

Registers for notification of deleted assets. AssetReceiver.deletedAssets() is invoked when an asset is deleted or removed from this repository.

ErrorsOPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodregisterForDeletedAssetsByGenusType
Description

Registers for notification of deleted assets of the given asset genus type. AssetReceiver.deletedAssets() is invoked when an asset is deleted or removed from this repository.

Parametersosid.type.TypeassetGenusTypethe genus type of the Asset to monitor
ErrorsNULL_ARGUMENT assetGenusType is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodregisterForDeletedAsset
Description

Registers for notification of a deleted asset. AssetReceiver.deletedAssets() is invoked when the specified asset is deleted or removed from this repository.

Parametersosid.id.IdassetIdthe Id of the Asset to monitor
ErrorsNULL_ARGUMENT assetId is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.