public interface PositionNotificationSession extends OsidSession
This session defines methods to receive notifications on adds/changes
to Position
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.
Modifier and Type | Method and Description |
---|---|
boolean |
canRegisterForPositionNotifications()
Tests if this user can register for
Position
notifications. |
Realm |
getRealm()
Gets the
Realm associated with this session. |
Id |
getRealmId()
Gets the
Realm Id associated with this
session. |
void |
registerForChangedPosition(Id positionId)
Registers for notification of an updated position.
|
void |
registerForChangedPositions()
Registers for notification of updated positions.
|
void |
registerForChangedPositionsForOrganization(Id organizationId)
Register for notifications of changed positions for the given
organization.
|
void |
registerForDeletedPosition(Id positionId)
Registers for notification of a deleted position.
|
void |
registerForDeletedPositions()
Registers for notification of deleted positions.
|
void |
registerForDeletedPositionsForOrganization(Id organizationId)
Register for notifications of deleted positions for the given
organization.
|
void |
registerForNewPositions()
Register for notifications of new positions.
|
void |
registerForNewPositionsForOrganization(Id organizationId)
Register for notifications of new positions for an organization.
|
void |
useFederatedRealmView()
Federates the view for methods in this session.
|
void |
useIsolatedRealmView()
Isolates the view for methods in this session.
|
getAuthenticatedAgent, getAuthenticatedAgentId, getClockRate, getDate, getEffectiveAgent, getEffectiveAgentId, getFormatType, getLocale, isAuthenticated, startTransaction, supportsTransactions
close
Id getRealmId()
Realm
Id
associated with this
session. Realm Id
associated with this sessionmandatory
- This method must be implemented. Realm getRealm() throws OperationFailedException, PermissionDeniedException
Realm
associated with this session.OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. boolean canRegisterForPositionNotifications()
Position
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 useFederatedRealmView()
mandatory
- This method is must be implemented. void useIsolatedRealmView()
mandatory
- This method is must be implemented. void registerForNewPositions() throws OperationFailedException, PermissionDeniedException
PositionReceiver.newPosition()
is invoked when a new
Position
is appears in this realm.OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. void registerForNewPositionsForOrganization(Id organizationId) throws OperationFailedException, PermissionDeniedException
PositionReceiver.newPosition()
is invoked when a new
Position
appears in this realm.organizationId
- an organization to monitorNullArgumentException
- organizationId
is null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. void registerForChangedPositions() throws OperationFailedException, PermissionDeniedException
PositionReceiver.changedPosition()
is invoked when a position
in this realm is changed.OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. void registerForChangedPositionsForOrganization(Id organizationId) throws OperationFailedException, PermissionDeniedException
PositionReceiver.changedPosition()
is
invoked when a Position
for the organization in this
realm is changed.organizationId
- an organization to monitorNullArgumentException
- organizationId
is null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. void registerForChangedPosition(Id positionId) throws NotFoundException, OperationFailedException, PermissionDeniedException
PositionReceiver.changedPosition()
is invoked when the
specified position in this realm is changed.positionId
- the Id
of the Position
to monitorNotFoundException
- a position was not found identified
by the given Id
NullArgumentException
- positionId
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. void registerForDeletedPositions() throws OperationFailedException, PermissionDeniedException
PositionReceiver.deletedPosition()
is invoked when a position
is removed from this realm.OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. void registerForDeletedPositionsForOrganization(Id organizationId) throws OperationFailedException, PermissionDeniedException
PositionReceiver.deletedPosition()
is
invoked when a Position
for the organization is removed
from this realm.organizationId
- an organization to monitorNullArgumentException
- organizationId
is null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. void registerForDeletedPosition(Id positionId) throws NotFoundException, OperationFailedException, PermissionDeniedException
PositionReceiver.deletedPosition()
is invoked when the
specified position is removed from this realm.positionId
- the Id
of the Position
to monitorNotFoundException
- a position was not found identified
by the given Id
NullArgumentException
- positionId
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented.