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.
| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
PROPERTY_APPROVER_PREFIX
The prefix to use for looking up
jspwiki.properties approval roles. |
static java.lang.String |
WF_UP_CREATE_SAVE_APPROVER
The name of the key from jspwiki.properties which defines who shall approve the workflow of creating a user profile.
|
static java.lang.String |
WF_UP_CREATE_SAVE_ATTR_SAVED_PROFILE
The workflow attribute which stores the user profile.
|
static java.lang.String |
WF_UP_CREATE_SAVE_DECISION_MESSAGE_KEY
The message key for storing the Decision text for saving a user profile.
|
static java.lang.String |
WF_UP_CREATE_SAVE_FACT_PREFS_EMAIL
Fact name for storing the preferences' email.
|
static java.lang.String |
WF_UP_CREATE_SAVE_FACT_PREFS_FULL_NAME
Fact name for storing the preferences' full name.
|
static java.lang.String |
WF_UP_CREATE_SAVE_FACT_PREFS_LOGIN_NAME
Fact name for storing the preferences' login name.
|
static java.lang.String |
WF_UP_CREATE_SAVE_FACT_SUBMITTER
Fact name for storing a the submitter name.
|
static java.lang.String |
WF_WP_SAVE_APPROVER
The name of the key from jspwiki.properties which defines who shall approve the workflow of storing a wikipage.
|
static java.lang.String |
WF_WP_SAVE_DECISION_MESSAGE_KEY
The message key for storing the Decision text for saving a page.
|
static java.lang.String |
WF_WP_SAVE_FACT_CURRENT_TEXT
Fact name for storing the current text.
|
static java.lang.String |
WF_WP_SAVE_FACT_DIFF_TEXT
Fact name for storing a diff text.
|
static java.lang.String |
WF_WP_SAVE_FACT_IS_AUTHENTICATED
Fact name for storing whether the user is authenticated or not.
|
static java.lang.String |
WF_WP_SAVE_FACT_PAGE_NAME
Fact name for storing the page name.
|
static java.lang.String |
WF_WP_SAVE_FACT_PROPOSED_TEXT
Fact name for storing the proposed (edited) text.
|
static java.lang.String |
WF_WP_SAVE_REJECT_MESSAGE_KEY
The message key for rejecting the decision to save the page.
|
| Modifier and Type | Method and Description |
|---|---|
java.security.Principal |
getApprover(java.lang.String messageKey)
Looks up and resolves the actor who approves a Decision for a particular Workflow, based on the Workflow's message key.
|
java.util.List<Workflow> |
getCompletedWorkflows()
Returns a collection of finished workflows; that is, those that have aborted or completed.
|
DecisionQueue |
getDecisionQueue()
Returns the DecisionQueue associated with this WorkflowManager
|
java.util.List<Workflow> |
getOwnerWorkflows(Session session)
Returns the current workflows a wiki session owns.
|
java.util.Set<Workflow> |
getWorkflows()
Returns a collection of the currently active workflows.
|
boolean |
requiresApproval(java.lang.String messageKey)
Returns
true if a workflow matching a particular key contains an approval step. |
actionPerformedinitializestatic final java.lang.String WF_WP_SAVE_APPROVER
static final java.lang.String WF_WP_SAVE_DECISION_MESSAGE_KEY
static final java.lang.String WF_WP_SAVE_REJECT_MESSAGE_KEY
static final java.lang.String WF_WP_SAVE_FACT_PAGE_NAME
static final java.lang.String WF_WP_SAVE_FACT_DIFF_TEXT
static final java.lang.String WF_WP_SAVE_FACT_CURRENT_TEXT
static final java.lang.String WF_WP_SAVE_FACT_PROPOSED_TEXT
static final java.lang.String WF_WP_SAVE_FACT_IS_AUTHENTICATED
static final java.lang.String WF_UP_CREATE_SAVE_ATTR_SAVED_PROFILE
static final java.lang.String WF_UP_CREATE_SAVE_APPROVER
static final java.lang.String WF_UP_CREATE_SAVE_DECISION_MESSAGE_KEY
static final java.lang.String WF_UP_CREATE_SAVE_FACT_SUBMITTER
static final java.lang.String WF_UP_CREATE_SAVE_FACT_PREFS_LOGIN_NAME
static final java.lang.String WF_UP_CREATE_SAVE_FACT_PREFS_FULL_NAME
static final java.lang.String WF_UP_CREATE_SAVE_FACT_PREFS_EMAIL
static final java.lang.String PROPERTY_APPROVER_PREFIX
jspwiki.properties approval roles.java.util.Set<Workflow> getWorkflows()
java.util.List<Workflow> getCompletedWorkflows()
boolean requiresApproval(java.lang.String messageKey)
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().java.security.Principal getApprover(java.lang.String messageKey) throws WikiException
AdminmessageKey - the Decision's message keyWikiException - if the message key was not found, or the
Principal value corresponding to the key could not be resolvedDecisionQueue getDecisionQueue()
java.util.List<Workflow> getOwnerWorkflows(Session session)
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 sessionCopyright (c) 2001-2022 The Apache Software Foundation. All rights reserved.