Interface ResourceRouteNotificationSession
- All Superinterfaces:
AutoCloseable, Closeable, OsidSession, OsidSession
This session defines methods to receive notifications on adds/changes
to resources on routes in this Map . 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 TypeMethodDescriptionvoidacknowledgeResourceRouteNotification(Id notificationId) Acknowledge a resource route notification.booleanTests if this user can register for notifications.getMap()Gets theMapassociated with this session.getMapId()Gets theMapIdassociated with this session.voidregisterForCancelledRoute(Id routeId) Register for notifications of a cancelled route.voidRegisters for notification of cancelled routes.voidregisterForCancelledRoutesByEndingLocation(Id locationId) Registers for notification of cancelled routes from the specified ending location.voidregisterForCancelledRoutesByStartingLocation(Id locationId) Registers for notification of cancelled routes from the specified starting location.voidregisterForCancelledRoutesForResource(Id resourceId) Registers for notification of cancelled routes for the given resource.voidregisterForCancelledRoutesForResourcesByGenusType(Type resourceGenusType) Registers for notification of cancelled routes for resources of the given resource genus type.voidregisterForCompletedRoute(Id routeId) Register for notifications of a completed route.voidRegisters for notification of completed routes.voidregisterForCompletedRoutesByEndingLocation(Id locationId) Registers for notification of a completed route from the specified ending location.voidregisterForCompletedRoutesByStartingLocation(Id locationId) Registers for notification of a completed route from the specified starting location.voidregisterForCompletedRoutesForResource(Id resourceId) Registers for notification of a completed route for the given resource.voidregisterForCompletedRoutesForResourcesByGenusType(Type resourceGenusType) Registers for notification of a completed route for resources of the given resource genus type.voidregisterForNewRouteSegment(Id routeSegmentId) Registers for notification of new route segments.voidRegisters for notification of new route segments.voidregisterForNewRouteSegmentsForResource(Id resourceId) Registers for notification of new route segments for the given resource.voidregisterForNewRouteSegmentsForResourcesByGenusType(Type resourceGenusType) Registers for notification of new route segments for resources of the given genus type.voidregisterForStartedRoute(Id routeId) Register for notifications of a started route.voidRegister for notifications of new routes for a resource.voidregisterForStartedRoutesByEndingLocation(Id locationId) Register for notifications of a started route to the specified location.voidregisterForStartedRoutesByStartingLocation(Id locationId) Register for notifications of a started route from the specified location.voidregisterForStartedRoutesForResource(Id resourceId) Register for notifications of a started route for the given resource.voidregisterForStartedRoutesForResourcesByGenusType(Type resourceGenusType) Register for notifications of a started route for resources of the given resource genus type.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
-
getMapId
Id getMapId()Gets theMapIdassociated with this session.- Returns:
- the
Map Idassociated with this session - Compliance:
mandatory- This method must be implemented.
-
getMap
Gets theMapassociated with this session.- Returns:
- the map
- Throws:
OperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
canRegisterForResourceRouteNotifications
boolean canRegisterForResourceRouteNotifications()Tests if this user can register for 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 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.
-
useFederatedMapView
void useFederatedMapView()Federates the view for methods in this session. A federated view will include locations in maps which are children of this map in the map hierarchy.- Compliance:
mandatory- This method is must be implemented.
-
useIsolatedMapView
void useIsolatedMapView()Isolates the view for methods in this session. An isolated view restricts notifications to this map only.- Compliance:
mandatory- This method is must be implemented.
-
reliableResourceRouteNotifications
void reliableResourceRouteNotifications()Reliable notifications are desired. In reliable mode, notifications are to be acknowledged usingacknowledgeResourceRouteNotification().- Compliance:
mandatory- This method is must be implemented.
-
unreliableResourceRouteNotifications
void unreliableResourceRouteNotifications()Unreliable notifications are desired. In unreliable mode, notifications do not need to be acknowledged.- Compliance:
mandatory- This method is must be implemented.
-
acknowledgeResourceRouteNotification
void acknowledgeResourceRouteNotification(Id notificationId) throws OperationFailedException, PermissionDeniedException Acknowledge a resource route notification.- Parameters:
notificationId- theIdof the notification- Throws:
OperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
registerForStartedRoutes
Register for notifications of new routes for a resource.ResourceRouteReceiver.startedRoute()is invoked when a resource begins a route.- Throws:
OperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
registerForStartedRoute
Register for notifications of a started route.ResourceRouteReceiver.startedRoute()is invoked when a resource begins the specified route.- Parameters:
routeId- theIdof theRouteto monitor- Throws:
NullArgumentException-routeIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
registerForStartedRoutesByStartingLocation
void registerForStartedRoutesByStartingLocation(Id locationId) throws OperationFailedException, PermissionDeniedException Register for notifications of a started route from the specified location.ResourceRouteReceiver.startedRoute()is invoked when the specified resource begins a route.- Parameters:
locationId- theIdof theLocationto monitor- Throws:
NullArgumentException-locationIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
registerForStartedRoutesByEndingLocation
void registerForStartedRoutesByEndingLocation(Id locationId) throws OperationFailedException, PermissionDeniedException Register for notifications of a started route to the specified location.ResourceRouteReceiver.startedRoute()is invoked when the specified resource begins a route.- Parameters:
locationId- theIdof theLocationto monitor- Throws:
NullArgumentException-locationIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
registerForStartedRoutesForResource
void registerForStartedRoutesForResource(Id resourceId) throws OperationFailedException, PermissionDeniedException Register for notifications of a started route for the given resource.ResourceRouteReceiver.startedRoute()is invoked when the specified resource begins a route.- Parameters:
resourceId- theIdof theResourceto monitor- Throws:
NullArgumentException-resourceIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
registerForStartedRoutesForResourcesByGenusType
void registerForStartedRoutesForResourcesByGenusType(Type resourceGenusType) throws OperationFailedException, PermissionDeniedException Register for notifications of a started route for resources of the given resource genus type.ResourceRouteReceiver.startedRoute()is invoked when the specified resource begins a route.- Parameters:
resourceGenusType- the genus type of theResourceto monitor- Throws:
NullArgumentException-resourceGenusTypeisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
registerForCompletedRoutes
Registers for notification of completed routes.ResourceRouteReceiver.completedRoute()is invoked when a resource completes a route.- Throws:
OperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
registerForCompletedRoute
void registerForCompletedRoute(Id routeId) throws OperationFailedException, PermissionDeniedException Register for notifications of a completed route.ResourceRouteReceiver.completedRoute()is invoked when a resource completes the specified route.- Parameters:
routeId- theIdof theRouteto monitor- Throws:
NullArgumentException-routeIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
registerForCompletedRoutesByStartingLocation
void registerForCompletedRoutesByStartingLocation(Id locationId) throws OperationFailedException, PermissionDeniedException Registers for notification of a completed route from the specified starting location.ResourceRouteReceiver.completedRoute()is invoked when the specified resource completes a route.- Parameters:
locationId- theIdof theLocationto monitor- Throws:
NullArgumentException-locationIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
registerForCompletedRoutesByEndingLocation
void registerForCompletedRoutesByEndingLocation(Id locationId) throws OperationFailedException, PermissionDeniedException Registers for notification of a completed route from the specified ending location.ResourceRouteReceiver.completedRoute()is invoked when the specified resource completes a route.- Parameters:
locationId- theIdof theLocationto monitor- Throws:
NullArgumentException-locationIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
registerForCompletedRoutesForResource
void registerForCompletedRoutesForResource(Id resourceId) throws OperationFailedException, PermissionDeniedException Registers for notification of a completed route for the given resource.ResourceRouteReceiver.completedRoute()is invoked when the specified resource completes a route.- Parameters:
resourceId- theIdof theResourceto monitor- Throws:
NullArgumentException-resourceIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
registerForCompletedRoutesForResourcesByGenusType
void registerForCompletedRoutesForResourcesByGenusType(Type resourceGenusType) throws OperationFailedException, PermissionDeniedException Registers for notification of a completed route for resources of the given resource genus type.ResourceRouteReceiver.completedRoute()is invoked when the specified resource completes a route.- Parameters:
resourceGenusType- the genus type of theResourceto monitor- Throws:
NullArgumentException-resourceGenusTYpeisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
registerForCancelledRoutes
Registers for notification of cancelled routes.ResourceRouteReceiver.cancelledRoute()is invoked when a resource cancels a route.- Throws:
OperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
registerForCancelledRoute
void registerForCancelledRoute(Id routeId) throws OperationFailedException, PermissionDeniedException Register for notifications of a cancelled route.ResourceRouteReceiver.completedRoute()is invoked when a resource cancels the specified route.- Parameters:
routeId- theIdof theRouteto monitor- Throws:
NullArgumentException-routeIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
registerForCancelledRoutesByStartingLocation
void registerForCancelledRoutesByStartingLocation(Id locationId) throws OperationFailedException, PermissionDeniedException Registers for notification of cancelled routes from the specified starting location.ResourceRouteReceiver.cancelledRoute()is invoked when a specified resource cancels a route.- Parameters:
locationId- theIdof theLocationto monitor- Throws:
NullArgumentException-locationIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
registerForCancelledRoutesByEndingLocation
void registerForCancelledRoutesByEndingLocation(Id locationId) throws OperationFailedException, PermissionDeniedException Registers for notification of cancelled routes from the specified ending location.ResourceRouteReceiver.cancelledRoute()is invoked when a specified resource cancels a route.- Parameters:
locationId- theIdof theLocationto monitor- Throws:
NullArgumentException-locationIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
registerForCancelledRoutesForResource
void registerForCancelledRoutesForResource(Id resourceId) throws OperationFailedException, PermissionDeniedException Registers for notification of cancelled routes for the given resource.ResourceRouteReceiver.cancelledRoute()is invoked when a specified resource cancels a route.- Parameters:
resourceId- theIdof theResourceto monitor- Throws:
NullArgumentException-resourceIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
registerForCancelledRoutesForResourcesByGenusType
void registerForCancelledRoutesForResourcesByGenusType(Type resourceGenusType) throws OperationFailedException, PermissionDeniedException Registers for notification of cancelled routes for resources of the given resource genus type.ResourceRouteReceiver.cancelledRoute()is invoked when a specified resource cancels a route.- Parameters:
resourceGenusType- the genus type of theResourceto monitor- Throws:
NullArgumentException-resourceGenusTypeisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
registerForNewRouteSegments
Registers for notification of new route segments.ResourceRouteReceiver.newRouteSegment()is invoked when a resource moves on to a new route segment.- Throws:
OperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
registerForNewRouteSegment
void registerForNewRouteSegment(Id routeSegmentId) throws OperationFailedException, PermissionDeniedException Registers for notification of new route segments.ResourceRouteReceiver.newRouteSegment()is invoked when a resource moves on to the desigtnated route segment.- Parameters:
routeSegmentId- theIdof theRouteSegmentto monitor- Throws:
NullArgumentException-routeSegmentIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
registerForNewRouteSegmentsForResource
void registerForNewRouteSegmentsForResource(Id resourceId) throws OperationFailedException, PermissionDeniedException Registers for notification of new route segments for the given resource.ResourceRouteReceiver.newRouteSegment()is invoked when the specified resource moves on to a new route segment.- Parameters:
resourceId- theIdof theResourceto monitor- Throws:
NullArgumentException-resourceIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
registerForNewRouteSegmentsForResourcesByGenusType
void registerForNewRouteSegmentsForResourcesByGenusType(Type resourceGenusType) throws OperationFailedException, PermissionDeniedException Registers for notification of new route segments for resources of the given genus type.ResourceRouteReceiver.newRouteSegment()is invoked when the specified resource moves on to a new route segment.- Parameters:
resourceGenusType- the genus type of theResourceto monitor- Throws:
NullArgumentException-resourceGenusTypeisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-