Interface MapNotificationSession

All Superinterfaces:
AutoCloseable, Closeable, OsidSession, OsidSession

public interface MapNotificationSession extends OsidSession

This session defines methods to receive notifications on adds/changes to Maps . 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 Details

    • canRegisterForMapNotifications

      boolean canRegisterForMapNotifications()
      Tests if this user can register for Map 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.
      Returns:
      false if notification methods are not authorized, true otherwise
      Compliance:
      mandatory - This method must be implemented.
    • reliableMapNotifications

      void reliableMapNotifications()
      Reliable notifications are desired. In reliable mode, notifications are to be acknowledged using acknowledgeMapNotification() .
      Compliance:
      mandatory - This method is must be implemented.
    • unreliableMapNotifications

      void unreliableMapNotifications()
      Unreliable notifications are desired. In unreliable mode, notifications do not need to be acknowledged.
      Compliance:
      mandatory - This method is must be implemented.
    • acknowledgeMapNotification

      void acknowledgeMapNotification(Id notificationId) throws OperationFailedException, PermissionDeniedException
      Acknowledge a map notification.
      Parameters:
      notificationId - the Id of the notification
      Throws:
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • registerForNewMaps

      void registerForNewMaps() throws OperationFailedException, PermissionDeniedException
      Register for notifications of new maps. MapReceiver.newMaps() is invoked when a new Map is created.
      Throws:
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • registerForChangedMaps

      void registerForChangedMaps() throws OperationFailedException, PermissionDeniedException
      Registers for notification of updated maps. MapReceiver.changedMaps() is invoked when a map is changed.
      Throws:
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • registerForChangedMap

      void registerForChangedMap(Id mapId) throws OperationFailedException, PermissionDeniedException
      Registers for notification of an updated map. MapReceiver.changedMaps() is invoked when the specified map is changed.
      Parameters:
      mapId - the Id of the Map to monitor
      Throws:
      NullArgumentException - E
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • registerForDeletedMaps

      void registerForDeletedMaps() throws OperationFailedException, PermissionDeniedException
      Registers for notification of deleted maps. MapReceiver.deletedMaps() is invoked when a map is deleted.
      Throws:
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • registerForDeletedMap

      void registerForDeletedMap(Id mapId) throws OperationFailedException, PermissionDeniedException
      Registers for notification of a deleted map. MapReceiver.deletedMaps() is invoked when the specified map is deleted.
      Parameters:
      mapId - the Id of the Map to monitor
      Throws:
      NullArgumentException - mapId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • registerForChangedMapHierarchy

      void registerForChangedMapHierarchy() throws OperationFailedException, PermissionDeniedException
      Registers for notification of an updated map hierarchy structure. MapReceiver.changedChildOfMaps() is invoked when a node experiences a change in its children.
      Throws:
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • registerForChangedMapHierarchyForAncestors

      void registerForChangedMapHierarchyForAncestors(Id mapId) throws OperationFailedException, PermissionDeniedException
      Registers for notification of an updated map hierarchy structure. MapReceiver.changedChildOfMaps() is invoked when the specified node or any of its ancestors experiences a change in its children.
      Parameters:
      mapId - the Id of the Map node to monitor
      Throws:
      NullArgumentException - mapId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • registerForChangedMapHierarchyForDescendants

      void registerForChangedMapHierarchyForDescendants(Id mapId) throws OperationFailedException, PermissionDeniedException
      Registers for notification of an updated map hierarchy structure. MapReceiver.changedChildOfMaps() is invoked when the specified node or any of its descendants experiences a change in its children.
      Parameters:
      mapId - the Id of the Map node to monitor
      Throws:
      NullArgumentException - mapId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.