Interface AppointmentNotificationSession
- All Superinterfaces:
AutoCloseable, Closeable, OsidSession, OsidSession
This session defines methods to receive notifications on adds/changes
to Appointment 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.
-
Method Summary
Modifier and TypeMethodDescriptionvoidacknowledgeAppointmentNotification(Id notificationId) Acknowledge an appointment notification.booleanTests if this user can register forAppointmentnotifications.getRealm()Gets theRealmassociated with this session.Gets theRealmIdassociated with this session.voidregisterForChangedAppointment(Id appointmentId) Registers for notification of an updated appointment.voidRegisters for notification of updated appointments.voidregisterForChangedAppointmentsForPerson(Id personId) Register for notifications of changed appointments for the given personId.voidregisterForChangedAppointmentsForPosition(Id positionId) Register for notifications of changed appointments for the given positionId.voidregisterForDeletedAppointment(Id appointmentId) Registers for notification of a deleted appointment.voidRegisters for notification of deleted appointments.voidregisterForDeletedAppointmentsForPerson(Id personId) Register for notifications of deleted appointments for the given personId.voidregisterForDeletedAppointmentsForPosition(Id positionId) Register for notifications of deleted appointments for the given positionId.voidRegister for notifications of new appointments.voidregisterForNewAppointmentsForPerson(Id personId) Register for notifications of new appointments for the given personId.voidregisterForNewAppointmentsForPosition(Id positionId) Register for notifications of new appointments for the given positionId.voidReliable notifications are desired.voidUnreliable notifications are desired.voidFederates the view for methods in this session.voidIsolates the view for methods in this session.Methods inherited from interface OsidSession
closeMethods inherited from interface OsidSession
getAuthenticatedAgent, getAuthenticatedAgentId, getClockRate, getDate, getEffectiveAgent, getEffectiveAgentId, getFormatType, getLocale, isAuthenticated, startTransaction, supportsTransactionsModifier and TypeMethodDescriptionGets the agent authenticated to this session.Gets theIdof the agent authenticated to this session.Gets the rate of the service clock.getDate()Gets the service date which may be the current date or the effective date in which this session exists.Gets the effective agent in use by this session.Gets theIdof the effective agent in use by this session.Gets theDisplayTextformatTypepreference in effect for this session.Gets the locale indicating the localization preferences in effect for this session.booleanTests if an agent is authenticated to this session.Starts a new transaction for this sesson.booleanTests for the availability of transactions.
-
Method Details
-
getRealmId
Id getRealmId()Gets theRealmIdassociated with this session.- Returns:
- the
Realm Idassociated with this session - Compliance:
mandatory- This method must be implemented.
-
getRealm
Gets theRealmassociated with this session.- Returns:
- the realm
- Throws:
OperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
canRegisterForAppointmentNotifications
boolean canRegisterForAppointmentNotifications()Tests if this user can register forAppointmentnotifications. 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 aPERMISSION_DENIED. This is intended as a hint to an application that may opt not to offer notification operations.- Returns:
falseif notification methods are not authorized,trueotherwise- Compliance:
mandatory- This method must be implemented.
-
useFederatedRealmView
void useFederatedRealmView()Federates the view for methods in this session. A federated view will include notifications for appointmentss in realms which are children of this realm in the realm hierarchy.- Compliance:
mandatory- This method is must be implemented.
-
useIsolatedRealmView
void useIsolatedRealmView()Isolates the view for methods in this session. An isolated view restricts notifications to this realm only.- Compliance:
mandatory- This method is must be implemented.
-
reliableAppointmentNotifications
void reliableAppointmentNotifications()Reliable notifications are desired. In reliable mode, notifications are to be acknowledged usingacknowledgeAppointmentNotification().- Compliance:
mandatory- This method is must be implemented.
-
unreliableAppointmentNotifications
void unreliableAppointmentNotifications()Unreliable notifications are desired. In unreliable mode, notifications do not need to be acknowledged.- Compliance:
mandatory- This method is must be implemented.
-
acknowledgeAppointmentNotification
void acknowledgeAppointmentNotification(Id notificationId) throws OperationFailedException, PermissionDeniedException Acknowledge an appointment notification.- Parameters:
notificationId- theIdof the notification- Throws:
OperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
registerForNewAppointments
Register for notifications of new appointments.AppointmentReceiver.newAppointments()is invoked when a newAppointmentis created.- Throws:
OperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
registerForNewAppointmentsForPerson
void registerForNewAppointmentsForPerson(Id personId) throws OperationFailedException, PermissionDeniedException Register for notifications of new appointments for the given personId.AppointmentReceiver.newAppointments()is invoked when a newAppointmentappears in this realm.- Parameters:
personId- the person to monitor- Throws:
NullArgumentException-personIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
registerForNewAppointmentsForPosition
void registerForNewAppointmentsForPosition(Id positionId) throws OperationFailedException, PermissionDeniedException Register for notifications of new appointments for the given positionId.AppointmentReceiver.newAppointments()is invoked when a newAppointmentappears in this realm.- Parameters:
positionId- theIdof the position to monitor- Throws:
NullArgumentException-positionIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
registerForChangedAppointments
Registers for notification of updated appointments.AppointmentReceiver.changedAppointments()is invoked when an appointment in this realm is changed.- Throws:
OperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
registerForChangedAppointmentsForPerson
void registerForChangedAppointmentsForPerson(Id personId) throws OperationFailedException, PermissionDeniedException Register for notifications of changed appointments for the given personId.AppointmentReceiver.changedAppointments()is invoked when anAppointmentfor the reference in this realm is changed.- Parameters:
personId- theIdof the person to monitor- Throws:
NullArgumentException-personIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
registerForChangedAppointmentsForPosition
void registerForChangedAppointmentsForPosition(Id positionId) throws OperationFailedException, PermissionDeniedException Register for notifications of changed appointments for the given positionId.AppointmentReceiver.changedAppointments()is invoked when anAppointmentfor the resource is changed in this realm.- Parameters:
positionId- theIdof the position to monitor- Throws:
NullArgumentException-positionIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
registerForChangedAppointment
void registerForChangedAppointment(Id appointmentId) throws NotFoundException, OperationFailedException, PermissionDeniedException Registers for notification of an updated appointment.AppointmentReceiver.changedAppointments()is invoked when the specified appointment in this realm is changed.- Parameters:
appointmentId- theIdof theAppointmentto monitor- Throws:
NotFoundException- an appointment was not found identified by the givenIdNullArgumentException-appointmentIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
registerForDeletedAppointments
Registers for notification of deleted appointments.AppointmentReceiver.deletedAppointments()is invoked when an appointment is removed from this realm.- Throws:
OperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
registerForDeletedAppointmentsForPerson
void registerForDeletedAppointmentsForPerson(Id personId) throws OperationFailedException, PermissionDeniedException Register for notifications of deleted appointments for the given personId.AppointmentReceiver.deletedAppointments()is invoked when anAppointmentfor the reference is removed from this realm.- Parameters:
personId- theIdof the person to monitor- Throws:
NullArgumentException-personIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
registerForDeletedAppointmentsForPosition
void registerForDeletedAppointmentsForPosition(Id positionId) throws OperationFailedException, PermissionDeniedException Register for notifications of deleted appointments for the given positionId.AppointmentReceiver.deletedAppointments()is invoked when anAppointmentfor the resource is removed from this realm.- Parameters:
positionId- theIdof the position to monitor- Throws:
NullArgumentException-positionIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
registerForDeletedAppointment
void registerForDeletedAppointment(Id appointmentId) throws NotFoundException, OperationFailedException, PermissionDeniedException Registers for notification of a deleted appointment.AppointmentReceiver.deletedAppointments()is invoked when the specified appointment is removed from this realm.- Parameters:
appointmentId- theIdof theAppointmentto monitor- Throws:
NotFoundException- an appointment was not found identified by the givenIdNullArgumentException-appointmentIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-