public interface ObjectiveNotificationSession extends OsidSession
This session defines methods to receive asynchronous notifications on
adds/changes to Objective
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.
The views defined in this session correspond to the views in the
ObjectiveLookupSession.
Modifier and Type | Method and Description |
---|---|
boolean |
canRegisterForObjectiveNotifications()
Tests if this user can register for
Objective
notifications. |
ObjectiveBank |
getObjectiveBank()
Gets the
ObjectiveBank associated with this session. |
Id |
getObjectiveBankId()
Gets the
ObjectiveBank Id associated
with this session. |
void |
registerForChangedObjective(Id objectiveId)
Registers for notification of an updated objective.
|
void |
registerForChangedObjectives()
Registers for notification of updated objectives.
|
void |
registerForDeletedObjective(Id objectiveId)
Registers for notification of a deleted objective.
|
void |
registerForDeletedObjectiveAncestors(Id objectiveId)
Registers for notification if an ancestor is removed from the
specified objective in the objective hierarchy.
|
void |
registerForDeletedObjectiveDescendants(Id objectiveId)
Registers for notification if a descendant is removed from fthe
specified objective in the objective hierarchy.
|
void |
registerForDeletedObjectives()
Registers for notification of deleted objectives.
|
void |
registerForNewObjectiveAncestors(Id objectiveId)
Registers for notification if an ancestor is added to the specified
objective in the objective hierarchy.
|
void |
registerForNewObjectiveDescendants(Id objectiveId)
Registers for notification if a descendant is added to the specified
objective in the objective hierarchy.
|
void |
registerForNewObjectives()
Register for notifications of new objectives.
|
void |
useFederatedObjectiveBankView()
Federates the view for methods in this session.
|
void |
useIsolatedObjectiveBankView()
Isolates the view for methods in this session.
|
getAuthenticatedAgent, getAuthenticatedAgentId, getClockRate, getDate, getEffectiveAgent, getEffectiveAgentId, getFormatType, getLocale, isAuthenticated, startTransaction, supportsTransactions
close
Id getObjectiveBankId()
ObjectiveBank
Id
associated
with this session. ObjectiveBank Id
associated with this
sessionmandatory
- This method must be implemented. ObjectiveBank getObjectiveBank() throws OperationFailedException, PermissionDeniedException
ObjectiveBank
associated with this session. ObjectiveBank
associated with this sessionOperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. boolean canRegisterForObjectiveNotifications()
Objective
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 useFederatedObjectiveBankView()
mandatory
- This method is must be implemented. void useIsolatedObjectiveBankView()
mandatory
- This method is must be implemented. void registerForNewObjectives() throws OperationFailedException, PermissionDeniedException
ObjectiveReceiver.newObjective()
is invoked when a new
objective is created.OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. void registerForNewObjectiveAncestors(Id objectiveId) throws OperationFailedException, PermissionDeniedException
ObjectiveReceiver.newObjectiveAncestor()
is invoked when the
specified objetcive experiences an addition in ancestry.objectiveId
- the Id
of the objective to monitorNullArgumentException
- objectiveId is null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failure
occurredmandatory
- This method must be implemented. void registerForNewObjectiveDescendants(Id objectiveId) throws OperationFailedException, PermissionDeniedException
ObjectiveReceiver.newObjectiveDescendant()
is invoked when the
specified objective experiences an addition in descendants.objectiveId
- the Id of the objective to monitorNullArgumentException
- objectiveId is null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failure
occurredmandatory
- This method must be implemented. void registerForChangedObjectives() throws OperationFailedException, PermissionDeniedException
ObjectiveReceiver.changedObjective()
is invoked when an
objective is changed.OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. void registerForChangedObjective(Id objectiveId) throws OperationFailedException, PermissionDeniedException
ObjectiveReceiver.changedObjective()
is invoked when the
specified objective is changed.objectiveId
- the Id
of the Objective
to monitorNullArgumentException
- objectiveId is null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. void registerForDeletedObjectives() throws OperationFailedException, PermissionDeniedException
ObjectiveReceiver.deletedObjective()
is invoked when an
objective is removed from this objective bank.OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. void registerForDeletedObjective(Id objectiveId) throws OperationFailedException, PermissionDeniedException
ObjectiveReceiver.changedObjective()
is invoked when the
specified objective is removed from this objective bank.objectiveId
- the Id
of the Objective
to monitorNullArgumentException
- objectiveid is null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. void registerForDeletedObjectiveAncestors(Id objectiveId) throws OperationFailedException, PermissionDeniedException
ObjectiveReceiver.deletedObjectiveAncestor()
is invoked when
the specified objective experiences a removal of an ancestor.objectiveId
- the Id
of the objective to monitorNullArgumentException
- objectiveId is null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failure
occurredmandatory
- This method must be implemented. void registerForDeletedObjectiveDescendants(Id objectiveId) throws OperationFailedException, PermissionDeniedException
ObjectiveReceiver.deletedObjectiveDescednant()
is invoked when
the specified objective experiences a removal of one of its
descendants.objectiveId
- the Id
of the objective to monitorNullArgumentException
- objectiveId is null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failure
occurredmandatory
- This method must be implemented.