Interface WorkflowEventNotificationSession

All Superinterfaces:
AutoCloseable, Closeable, OsidSession, OsidSession

public interface WorkflowEventNotificationSession extends OsidSession

This session defines methods to receive notifications on adds/changes to WorkflowEvents in this Office . This also includes existing workflow events that may appear or disappear due to changes in the Office hierarc hy, 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 two views defined in this session correspond to the views in the WorkflowEventLookupSession .

  • Method Details

    • getOfficeId

      Id getOfficeId()
      Gets the Office Id associated with this session.
      Returns:
      the Office Id associated with this session
      Compliance:
      mandatory - This method must be implemented.
    • getOffice

      Gets the Office associated with this session.
      Returns:
      the office
      Throws:
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • canRegisterForWorkflowEventNotifications

      boolean canRegisterForWorkflowEventNotifications()
      Tests if this user can register for WorkflowEvent 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.
    • useFederatedOfficeView

      void useFederatedOfficeView()
      Federates the view for methods in this session. A federated view will include workflow events in offices which are children of this office in the office hierarchy.
      Compliance:
      mandatory - This method is must be implemented.
    • useIsolatedOfficeView

      void useIsolatedOfficeView()
      Isolates the view for methods in this session. An isolated view restricts notifications to this office only.
      Compliance:
      mandatory - This method is must be implemented.
    • reliableWorkflowEventNotifications

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

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

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

      void registerForNewWorkflowEvents() throws OperationFailedException, PermissionDeniedException
      Register for notifications of new workflow events. WorkflowEventReceiver.newWorkflowEvents() is invoked when a new WorkflowEvent appears in this office.
      Throws:
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • registerForNewWorkflowEventsForProcess

      void registerForNewWorkflowEventsForProcess(Id processId) throws OperationFailedException, PermissionDeniedException
      Register for notifications of new workflow events for the given process. WorkflowEventReceiver.newWorkflowEvents() is invoked when a new WorkflowEvent appears in this process.
      Parameters:
      processId - the Id of the Process to monitor
      Throws:
      NullArgumentException - processId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • registerForNewWorkflowEventsForStep

      void registerForNewWorkflowEventsForStep(Id stepId) throws OperationFailedException, PermissionDeniedException
      Register for notifications of new workflow events for the given step. WorkflowEventReceiver.newWorkflowEvents() is invoked when a new WorkflowEvent appears in this process.
      Parameters:
      stepId - the Id of the Step to monitor
      Throws:
      NullArgumentException - stepId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • registerForNewWorkflowEventsForWork

      void registerForNewWorkflowEventsForWork(Id workId) throws OperationFailedException, PermissionDeniedException
      Register for notifications of new workflow events for the given work. WorkflowEventReceiver.newWorkflowEvents() is invoked when a new WorkflowEvent appears in this process.
      Parameters:
      workId - the Id of the Work to monitor
      Throws:
      NullArgumentException - workId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • registerForNewWorkflowEventsForWorker

      void registerForNewWorkflowEventsForWorker(Id resourceId) throws OperationFailedException, PermissionDeniedException
      Register for notifications of new workflow events for the given resource. WorkflowEventReceiver.newWorkflowEvents() is invoked when a new WorkflowEvent appears in this process.
      Parameters:
      resourceId - the Id of the Resource to monitor
      Throws:
      NullArgumentException - resourceId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • registerForChangedWorkflowEvents

      void registerForChangedWorkflowEvents() throws OperationFailedException, PermissionDeniedException
      Register for notifications of updated workflow events. WorkflowEventReceiver.changedWorkflowEvents() is invoked when a WorkflowEvent in this office is changed.
      Throws:
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • registerForChangedWorkflowEventsForProcess

      void registerForChangedWorkflowEventsForProcess(Id processId) throws OperationFailedException, PermissionDeniedException
      Register for notifications of updated workflow events for the given process. WorkflowEventReceiver.changedWorkflowEvents() is invoked when a WorkflowEvent in this office is changed.
      Parameters:
      processId - the Id of the Process to monitor
      Throws:
      NullArgumentException - processId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • registerForChangedWorkflowEventsForStep

      void registerForChangedWorkflowEventsForStep(Id stepId) throws OperationFailedException, PermissionDeniedException
      Register for notifications of updated workflow events for the given step. WorkflowEventReceiver.changedWorkflowEvents() is invoked when a WorkflowEvent in this office is changed.
      Parameters:
      stepId - the Id of the Step to monitor
      Throws:
      NullArgumentException - stepId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • registerForChangedWorkflowEventsForWork

      void registerForChangedWorkflowEventsForWork(Id workId) throws OperationFailedException, PermissionDeniedException
      Register for notifications of updated workflow events for the given work. WorkflowEventReceiver.changedWorkflowEvents() is invoked when a WorkflowEvent in this office is changed.
      Parameters:
      workId - the Id of the Work to monitor
      Throws:
      NullArgumentException - workId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • registerForChangedWorkflowEventsForWorker

      void registerForChangedWorkflowEventsForWorker(Id resourceId) throws OperationFailedException, PermissionDeniedException
      Register for notifications of updated workflow events for the given resource. WorkflowEventReceiver.changedWorkflowEvents() is invoked when a WorkflowEvent in this office is changed.
      Parameters:
      resourceId - the Id of the Resource to monitor
      Throws:
      NullArgumentException - resourceId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • registerForChangedWorkflowEvent

      void registerForChangedWorkflowEvent(Id workflowEventId) throws OperationFailedException, PermissionDeniedException
      Register for notifications of an updated workflow event. WorkflowEventReceiver.changedWorkflowEvents() is invoked when the specified WorkflowEvent in this office is changed.
      Parameters:
      workflowEventId - the Id of the WorkflowEvent to monitor
      Throws:
      NullArgumentException - workflowEventId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • registerForDeletedWorkflowEvents

      void registerForDeletedWorkflowEvents() throws OperationFailedException, PermissionDeniedException
      Registers for notification of deleted workflow events. WorkflowEventReceiver.deletedWorkflowEvents() is invoked when a workflow event is deleted or removed from this office.
      Throws:
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • registerForDeletedWorkflowEventsForProcess

      void registerForDeletedWorkflowEventsForProcess(Id processId) throws OperationFailedException, PermissionDeniedException
      Registers for notification of deleted workflow events for the given process. WorkflowEventReceiver.deletedWorkflowEvents() is invoked when a workflow event is deleted or removed from this office.
      Parameters:
      processId - the Id of the Process to monitor
      Throws:
      NullArgumentException - processId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • registerForDeletedWorkflowEventsForStep

      void registerForDeletedWorkflowEventsForStep(Id stepId) throws OperationFailedException, PermissionDeniedException
      Registers for notification of deleted workflow events for the given step. WorkflowEventReceiver.deletedWorkflowEvents() is invoked when a workflow event is deleted or removed from this office.
      Parameters:
      stepId - the Id of the Step to monitor
      Throws:
      NullArgumentException - stepId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • registerForDeletedWorkflowEventsForWork

      void registerForDeletedWorkflowEventsForWork(Id workId) throws OperationFailedException, PermissionDeniedException
      Registers for notification of deleted workflow events for the given work. WorkflowEventReceiver.deletedWorkflowEvents() is invoked when a workflow event is deleted or removed from this office.
      Parameters:
      workId - the Id of the Work to monitor
      Throws:
      NullArgumentException - workId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • registerForDeletedWorkflowEventsForWorker

      void registerForDeletedWorkflowEventsForWorker(Id resourceId) throws OperationFailedException, PermissionDeniedException
      Registers for notification of deleted workflow events for the given resource. WorkflowEventReceiver.deletedWorkflowEvents() is invoked when a workflow event is deleted or removed from this office.
      Parameters:
      resourceId - the Id of the Resource to monitor
      Throws:
      NullArgumentException - resourceId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • registerForDeletedWorkflowEvent

      void registerForDeletedWorkflowEvent(Id workflowEventId) throws OperationFailedException, PermissionDeniedException
      Registers for notification of a deleted workflow event. WorkflowEventReceiver.deletedWorkflowEvents() is invoked when the specified workflow event is deleted or removed from this office.
      Parameters:
      workflowEventId - the Id of the WorkflowEvent to monitor
      Throws:
      NullArgumentException - workflowEventId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.