OSID Logo
OSID Specifications
subscription package
Version 3.0.0
Release Candidate Preview
Interfaceosid.subscription.SubscriptionPublisherAssignmentSession
Implementsosid.OsidSession
Description

This session provides methods to re-assign Subscriptions to Publishers. A Subscription may map to multiple Publishers and removing the last reference to a Subscription is the equivalent of deleting it. Each Publisher may have its own authorizations governing who is allowed to operate on it.

Adding a reference of a Subscription to another Publisher is not a copy operation (eg: does not change its Id ).

MethodcanAssignSubscriptions
Description

Tests if this user can alter subscription/publisher 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. This 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
CompliancemandatoryThis method must be implemented.
MethodcanAssignSubscriptionsToPublisher
Description

Tests if this user can alter subscription/publisher 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. This is intended as a hint to an application that may opt not to offer assignment operations to unauthorized users.

Parametersosid.id.IdpublisherIdthe Id of the Publisher
Returnboolean false if mapping is not authorized, true otherwise
ErrorsNULL_ARGUMENT publisherId is null
CompliancemandatoryThis method must be implemented.
MethodgetAssignablePublisherIds
Description

Gets a list of publishers including and under the given publisher node in which any subscription can be assigned.

Parametersosid.id.IdpublisherIdthe Id of the Publisher
Returnosid.id.IdListlist of assignable publisher Ids
ErrorsNULL_ARGUMENT publisherId is null
OPERATION_FAILEDunable to complete request
CompliancemandatoryThis method must be implemented.
MethodgetAssignablePublisherIdsForSubscription
Description

Gets a list of publishers including and under the given publisher node in which a specific subscription can be assigned.

Parametersosid.id.IdpublisherIdthe Id of the Publisher
osid.id.IdsubscriptionIdthe Id of the Subscription
Returnosid.id.IdListlist of assignable publisher Ids
ErrorsNULL_ARGUMENT publisherId or subscriptionId is null
OPERATION_FAILEDunable to complete request
CompliancemandatoryThis method must be implemented.
MethodassignSubscriptionToPublisher
Description

Adds an existing Subscription to a Publisher.

Parametersosid.id.IdsubscriptionIdthe Id of the Subscription
osid.id.IdpublisherIdthe Id of the Publisher
ErrorsALREADY_EXISTS subscriptionId is already assigned to publisherId
NOT_FOUND subscriptionId or publisherId not found
NULL_ARGUMENT subscriptionId or publisherId is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodunassignSubscriptionFromPublisher
Description

Removes a Subscription from a Publisher.

Parametersosid.id.IdsubscriptionIdthe Id of the Subscription
osid.id.IdpublisherIdthe Id of the Publisher
ErrorsNOT_FOUND subscriptionId or publisherId not found or subscriptionId not assigned to publisherId
NULL_ARGUMENT subscriptionId or publisherId is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodreassignSubscriptionToPublisher
Description

Moves a Subscription from one Publisher to another. Mappings to other Publishers are unaffected.

Parametersosid.id.IdsubscriptionIdthe Id of the Subscription
osid.id.IdfromPublisherIdthe Id of the current Publisher
osid.id.IdtoPublisherIdthe Id of the destination Publisher
ErrorsNOT_FOUND subscriptionId, fromPublisherId, or toPublisherId not found or subscriptionId not mapped to fromPublisherId
NULL_ARGUMENT subscriptionId, fromPublisherId, or toPublisherId is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.