Interface WorkflowManager

All Superinterfaces:
java.util.EventListener, Initializable, WikiEventListener
All Known Implementing Classes:

public interface WorkflowManager
extends WikiEventListener, Initializable

Monitor class that tracks running Workflows. The WorkflowManager also keeps track of the names of users or groups expected to approve particular Workflows.

  • Field Details

  • Method Details

    • getWorkflows

      java.util.Set<Workflow> getWorkflows()
      Returns a collection of the currently active workflows.
      the current workflows
    • getCompletedWorkflows

      java.util.List<Workflow> getCompletedWorkflows()
      Returns a collection of finished workflows; that is, those that have aborted or completed.
      the finished workflows
    • requiresApproval

      boolean requiresApproval​(java.lang.String messageKey)
      Returns true if a workflow matching a particular key contains an approval step.
      messageKey - the name of the workflow; corresponds to the value returned by Workflow.getMessageKey().
      the result
    • getApprover getApprover​(java.lang.String messageKey) throws WikiException
      Looks up and resolves the actor who approves a Decision for a particular Workflow, based on the Workflow's message key. If not found, or if Principal is Unresolved, throws WikiException. This particular implementation always returns the GroupPrincipal Admin
      messageKey - the Decision's message key
      the actor who approves Decisions
      WikiException - if the message key was not found, or the Principal value corresponding to the key could not be resolved
    • getDecisionQueue

      Returns the DecisionQueue associated with this WorkflowManager
      the decision queue
    • getOwnerWorkflows

      java.util.List<Workflow> getOwnerWorkflows​(Session session)
      Returns the current workflows a wiki session owns. These are workflows whose Workflow.getOwner() method returns a Principal also possessed by the wiki session (see Session.getPrincipals()). If the wiki session is not authenticated, this method returns an empty Collection.
      session - the wiki session
      the collection workflows the wiki session owns, which may be empty