Interface WorkflowInitiationSession

All Superinterfaces:
AutoCloseable, Closeable, OsidSession, OsidSession

public interface WorkflowInitiationSession extends OsidSession

This session provides methods for initiating a workflow.

  • 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.
    • canInitiateWorkflow

      boolean canInitiateWorkflow()
      Tests if this user can initiate a workflow. 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 workflow operations to unauthorized users.
      Returns:
      false if workflow initiation methods are not authorized, true otherwise
      Compliance:
      mandatory - This method must be implemented.
    • canInitiateWorkflowForProcess

      boolean canInitiateWorkflowForProcess(Id processId)
      Tests if this user can initiate a workflow in a process. 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 workflow operations to unauthorized users.
      Parameters:
      processId - a process Id
      Returns:
      false if workflow initiation methods are not authorized, true otherwise
      Throws:
      NullArgumentException - processId is null
      Compliance:
      mandatory - This method must be implemented.
    • getAvailableWork

      Gets the list of available work for this workflow. Available work is Work that is compatible with this Process but not currently part of this Process .
      Parameters:
      processId - a process Id
      Returns:
      the returned Work list
      Throws:
      NotFoundException - processId is not found
      NullArgumentException - processId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • startWorkflow

      void startWorkflow(Id processId, Id workId) throws NotFoundException, OperationFailedException, PermissionDeniedException
      Starts a work in the workflow at the initial step of the process.
      Parameters:
      processId - a process Id
      workId - a work Id
      Throws:
      NotFoundException - processId or workId is not found
      NullArgumentException - processId or workId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.