public interface PublisherNotificationSession extends OsidSession
This session defines methods to receive notifications on adds/changes
to Publisher
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 Publisher
object itself. Adding and removing subscriptions result in
notifications available from the notification session for subscriptions.
Modifier and Type | Method and Description |
---|---|
boolean |
canRegisterForPublisherNotifications()
Tests if this user can register for
Publisher
notifications. |
void |
registerForChangedPublisher(Id publisherId)
Registers for notification of an updated publisher.
|
void |
registerForChangedPublishers()
Registers for notification of updated publishers.
|
void |
registerForDeletedPublisher(Id publisherId)
Registers for notification of a deleted publisher.
|
void |
registerForDeletedPublisherAncestors(Id publisherId)
Registers for notification of an updated hierarchy structure that
removes an ancestor of the specified publisher
PublisherReceiver.deletedAncestor() is invoked when the
specified publisher node loses an ancestor. |
void |
registerForDeletedPublisherDescendants(Id publisherId)
Registers for notification of an updated hierarchy structure that
removes a descendant of the specified publisher.
|
void |
registerForDeletedPublishers()
Registers for notification of deleted publishers.
|
void |
registerForNewPublisherAncestors(Id publisherId)
Registers for notification of an updated hierarchy structure that
introduces a new ancestor of the specified publisher.
|
void |
registerForNewPublisherDescendants(Id publisherId)
Registers for notification of an updated hierarchy structure that
introduces a new descendant of the specified publisher.
|
void |
registerForNewPublishers()
Register for notifications of new publishers.
|
getAuthenticatedAgent, getAuthenticatedAgentId, getClockRate, getDate, getEffectiveAgent, getEffectiveAgentId, getFormatType, getLocale, isAuthenticated, startTransaction, supportsTransactions
close
boolean canRegisterForPublisherNotifications()
Publisher
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. false
if notification methods are not
authorized, true
otherwisemandatory
- This method must be implemented. void registerForNewPublishers() throws OperationFailedException, PermissionDeniedException
PublisherReceiver.newPublisher()
is invoked when a new
Publisher
is created.OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. void registerForNewPublisherAncestors(Id publisherId) throws OperationFailedException, PermissionDeniedException
PublisherReceiver.newAncestorPublisher()
is invoked when the
specified publisher node gets a new ancestor.publisherId
- the Id
of the Publisher
node to monitorNullArgumentException
- publisherId
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. void registerForNewPublisherDescendants(Id publisherId) throws OperationFailedException, PermissionDeniedException
PublisherReceiver.newDescendantPublisher()
is invoked when the
specified publisher node gets a new descendant.publisherId
- the Id
of the Publisher
node to monitorNullArgumentException
- publisherId
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. void registerForChangedPublishers() throws OperationFailedException, PermissionDeniedException
PublisherReceiver.changedPublisher()
is invoked when a
publisher is changed.OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. void registerForChangedPublisher(Id publisherId) throws OperationFailedException, PermissionDeniedException
PublisherReceiver.changedPublisher()
is invoked when the
specified publisher is changed.publisherId
- the Id
of the Publisher
to monitorNullArgumentException
- publisherId
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. void registerForDeletedPublishers() throws OperationFailedException, PermissionDeniedException
PublisherReceiver.deletedPublisher()
is invoked when a
publisher is deleted.OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. void registerForDeletedPublisher(Id publisherId) throws OperationFailedException, PermissionDeniedException
PublisherReceiver.deletedPublisher()
is invoked when the
specified publisher is deleted.publisherId
- the Id
of the Publisher
to monitorNullArgumentException
- publisherId
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. void registerForDeletedPublisherAncestors(Id publisherId) throws OperationFailedException, PermissionDeniedException
PublisherReceiver.deletedAncestor()
is invoked when the
specified publisher node loses an ancestor.publisherId
- the Id
of the Publisher
to monitorNullArgumentException
- publisherId
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. void registerForDeletedPublisherDescendants(Id publisherId) throws OperationFailedException, PermissionDeniedException
PublisherReceiver.deletedDescendant()
is invoked when the
specified publisher node loses a descendant.publisherId
- the Id
of the Publisher
to monitorNullArgumentException
- publisherId
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented.