public interface HierarchyStructureNotificationSession extends OsidSession
This session defines methods to receive notifications on adds/changes to a hierarchical structure. 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 structure of a
hierarchy. For notifications of changes to the Hierarchy
object use HierarchyNotificationSession.
Modifier and Type | Method and Description |
---|---|
void |
acknowledgeHierarchyStructureNotification(Id notificationId)
Acknowledge a hierarchy structure notification.
|
boolean |
canRegisterForHierarchyStructureNotifications()
Tests if this user can register for
Hierarchy node
notifications. |
Hierarchy |
getHierarchy()
Gets the
Hierarchy associated with this session. |
Id |
getHierarchyId()
Gets the hierarchy
Id associated with this session. |
void |
registerForChangedHierarchy()
Registers for notification of an updated hierarchy structure.
|
void |
registerForChangedHierarchyForAncestors(Id billingId)
Registers for notification of an updated hierarchy structure.
|
void |
registerForChangedHierarchyForDescendants(Id nodeId)
Registers for notification of an updated hierarchy structure.
|
void |
registerForDeletedHierarchyNode(Id nodeId)
Registers for notification of a deleted hierarchy node.
|
void |
registerForDeletedHierarchyNodes()
Registers for notification of deleted hierarchy nodes.
|
void |
registerForNewHierarchyNodes()
Register for notifications of new hierarchy nodes.
|
void |
reliableHierarchyStructureNotifications()
Reliable notifications are desired.
|
void |
unreliableHierarchyStructureNotifications()
Unreliable notifications are desired.
|
getAuthenticatedAgent, getAuthenticatedAgentId, getClockRate, getDate, getEffectiveAgent, getEffectiveAgentId, getFormatType, getLocale, isAuthenticated, startTransaction, supportsTransactions
close
Id getHierarchyId()
Id
associated with this session. Id
associated with this sessionmandatory
- This method must be implemented. Hierarchy getHierarchy() throws OperationFailedException, PermissionDeniedException
Hierarchy
associated with this session. Hierarchy
associated with this sessionOperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. boolean canRegisterForHierarchyStructureNotifications()
Hierarchy
node
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 reliableHierarchyStructureNotifications()
acknowledgeHierarchyStructureNotification()
.mandatory
- This method is must be implemented. void unreliableHierarchyStructureNotifications()
mandatory
- This method is must be implemented. void acknowledgeHierarchyStructureNotification(Id notificationId) throws OperationFailedException, PermissionDeniedException
notificationId
- the Id
of the notificationOperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. void registerForNewHierarchyNodes() throws OperationFailedException, PermissionDeniedException
HierarchyStructureReceiver.newNodes()
is invoked when a new
Hierarchy
node is added.OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. void registerForDeletedHierarchyNodes() throws OperationFailedException, PermissionDeniedException
HierarchyStructureReceiver.deletedNodes()
is invoked when a
hierarchy ndoe is deleted.OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. void registerForDeletedHierarchyNode(Id nodeId) throws OperationFailedException, PermissionDeniedException
HierarchyStructureReceiver.deletedNodes()
is invoked when the
specified hierarchy node is deleted.nodeId
- the Id
of the Hierarchy
node to monitorNullArgumentException
- nodeId
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. void registerForChangedHierarchy() throws OperationFailedException, PermissionDeniedException
HierarchyStructureReceiver.changedChildOfNodes()
is invoked
when a node experiences a change in its children.OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. void registerForChangedHierarchyForAncestors(Id billingId) throws OperationFailedException, PermissionDeniedException
BillingReceiver.changedChildOfBillings()
is invoked when the
specified node or any of its ancestors experiences a change in its
children.billingId
- the Id
of the node to monitorNullArgumentException
- nodeId
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. void registerForChangedHierarchyForDescendants(Id nodeId) throws OperationFailedException, PermissionDeniedException
HierarchyStructureReceiver.changedChildOfNodes()
is invoked
when the specified node or any of its descendants experiences a change
in its children.nodeId
- the Id
of the node to monitorNullArgumentException
- nodeId
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented.