OSID Logo
OSID Specifications
ordering package
Version 3.0.0
Release Candidate Preview
Interfaceosid.ordering.ProductNotificationSession
Implementsosid.OsidSession
Description

This session defines methods to receive notifications on adds/changes to Product objects. 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.

Notifications are triggered with changes to the Product object itself. Adding and removing orders result in notifications available from the notification session for orders.

MethodgetStoreId
Description

Gets the Store Id associated with this session.

Returnosid.id.Idthe Store Id associated with this session
CompliancemandatoryThis method must be implemented.
MethodgetStore
Description

Gets the Store associated with this session.

Returnosid.ordering.Storethe store
ErrorsOPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodcanRegisterForProductNotifications
Description

Tests if this user can register for Product 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.
MethoduseFederatedStoreView
Description

Federates the view for methods in this session. A federated view will include products in stores which are children of this store in the store hierarchy.

CompliancemandatoryThis method is must be implemented.
MethoduseIsolatedStoreView
Description

Isolates the view for methods in this session. An isolated view restricts retrievals to this store only.

CompliancemandatoryThis method is must be implemented.
MethodregisterForNewProducts
Description

Register for notifications of new products. ProductReceiver.newProducts() is invoked when a new Product is created.

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

Registers for notification of updated products. ProductReceiver.changedProducts() is invoked when a product is changed.

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

Registers for notification of an updated product. ProductReceiver.changedProducts() is invoked when the specified product is changed.

Parametersosid.id.IdproductIdthe Id of the Product to monitor
ErrorsNULL_ARGUMENT productId is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodregisterForDeletedProducts
Description

Registers for notification of deleted products. ProductReceiver.deletedProducts() is invoked when a product is deleted.

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

Registers for notification of a deleted product. ProductReceiver.deletedProducts() is invoked when the specified product is deleted.

Parametersosid.id.IdproductIdthe Id of the Product to monitor
ErrorsNULL_ARGUMENT productId is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.