public abstract class AbstractJiraWorkflow extends Object implements JiraWorkflow
| Modifier and Type | Field and Description |
|---|---|
protected WorkflowManager |
workflowManager |
ACTION_ORIGIN_STEP_ID, ACTION_SCREEN_ATTRIBUTE, ACTION_TYPE_ALL, ACTION_TYPE_COMMON, ACTION_TYPE_GLOBAL, ACTION_TYPE_INITIAL, ACTION_TYPE_ORDINARY, DEFAULT_WORKFLOW_NAME, DRAFT, JIRA_META_ATTRIBUTE_ALLOWED_LIST, JIRA_META_ATTRIBUTE_EDIT_ALLOWED, JIRA_META_ATTRIBUTE_EXCLUDE_RESOLUTION, JIRA_META_ATTRIBUTE_I18N, JIRA_META_ATTRIBUTE_I18N_SUBMIT, JIRA_META_ATTRIBUTE_INCLUDE_RESOLUTION, JIRA_META_ATTRIBUTE_KEY_PREFIX, JIRA_META_ATTRIBUTE_PERMISSION, JIRA_META_UPDATE_AUTHOR_KEY, JIRA_META_UPDATE_AUTHOR_NAME, JIRA_META_UPDATED_DATE, LIVE, STEP_STATUS_KEY, WORKFLOW_DESCRIPTION_ATTRIBUTE, WORKFLOW_VIEW_FIELDLAYOUT_KEY_ATTRIBUTE| Modifier | Constructor and Description |
|---|---|
protected |
AbstractJiraWorkflow(WorkflowManager workflowManager,
com.opensymphony.workflow.loader.WorkflowDescriptor workflowDescriptor) |
| Modifier and Type | Method and Description |
|---|---|
int |
compareTo(JiraWorkflow o) |
boolean |
equals(Object o) |
Collection<com.opensymphony.workflow.loader.ActionDescriptor> |
getActionsByName(String name)
Get all actions in this workflow, global, common and from steps, whose name matched
name. |
Collection<com.opensymphony.workflow.loader.ActionDescriptor> |
getActionsForScreen(FieldScreen fieldScreen) |
Collection<com.opensymphony.workflow.loader.ActionDescriptor> |
getActionsWithResult(com.opensymphony.workflow.loader.StepDescriptor stepDescriptor)
Get all the actions which have a particular step as their unconditional result.
|
String |
getActionType(com.opensymphony.workflow.loader.ActionDescriptor actionDescriptor) |
Collection<com.opensymphony.workflow.loader.ActionDescriptor> |
getAllActions()
Get all the actions in this workflow, global, common and from steps.
|
String |
getDescription() |
com.opensymphony.workflow.loader.WorkflowDescriptor |
getDescriptor() |
String |
getDisplayName() |
Status |
getLinkedStatus(com.opensymphony.workflow.loader.StepDescriptor stepDescriptor)
Get the Status associated with the given StepDescriptor.
|
List<org.ofbiz.core.entity.GenericValue> |
getLinkedStatuses()
Returns all statuses for this workflow
|
String |
getLinkedStatusId(com.opensymphony.workflow.loader.StepDescriptor stepDescriptor)
Get the id of the
Status associated with the given StepDescriptor |
Set<String> |
getLinkedStatusIds()
Returns all status ids for this workflow
|
Status |
getLinkedStatusObject(com.opensymphony.workflow.loader.StepDescriptor stepDescriptor)
Get the Status associated with the given StepDescriptor.
|
List<Status> |
getLinkedStatusObjects()
Returns all statuses for this workflow
|
com.opensymphony.workflow.loader.StepDescriptor |
getLinkedStep(org.ofbiz.core.entity.GenericValue status)
Get the StepDescriptor linked to the given status for this workflow.
|
com.opensymphony.workflow.loader.StepDescriptor |
getLinkedStep(Status status)
Get the StepDescriptor linked to the given status for this workflow.
|
String |
getMode()
Returns either
JiraWorkflow.DRAFT or JiraWorkflow.LIVE depending on the workflow implementation. |
abstract String |
getName() |
int |
getNextActionId()
Get the next available action id
|
Collection<com.opensymphony.workflow.loader.FunctionDescriptor> |
getPostFunctionsForTransition(com.opensymphony.workflow.loader.ActionDescriptor actionDescriptor)
Returns all post-functions of the transition, including the ones on all conditional results,
unconditional results and 'global' (non-result) postfunctions.
|
Collection |
getStepsForTransition(com.opensymphony.workflow.loader.ActionDescriptor actionDescriptor)
Returns a collection of all step descriptors that reference the given common action.
|
Collection |
getStepsWithAction(com.opensymphony.workflow.loader.StepDescriptor stepDescriptor) |
ApplicationUser |
getUpdateAuthor()
Returns the most recent author
|
String |
getUpdateAuthorName()
Returns the most recent authors username.
|
Date |
getUpdatedDate()
Returns the date of the most recent update to this workflow.
|
boolean |
hasDraftWorkflow()
Determines if this workflow has a draft edit copy.
|
int |
hashCode() |
boolean |
isActive()
Determine whether this workflow object is currently active.
|
boolean |
isCommonAction(com.opensymphony.workflow.loader.ActionDescriptor actionDescriptor) |
boolean |
isDefault()
Determines if the workflow is the default JIRA workflow
|
boolean |
isEditable()
Determines if the workflow can be modifed within JIRA.
|
boolean |
isGlobalAction(com.opensymphony.workflow.loader.ActionDescriptor actionDescriptor) |
boolean |
isInitialAction(com.opensymphony.workflow.loader.ActionDescriptor actionDescriptor) |
boolean |
isOrdinaryAction(com.opensymphony.workflow.loader.ActionDescriptor actionDescriptor) |
boolean |
isSystemWorkflow()
Determines if the workflow is loaded from XML or the database
|
boolean |
removeStep(com.opensymphony.workflow.loader.StepDescriptor stepDescriptor)
Remove a step from the workflow.
|
void |
reset() |
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, waitisDraftWorkflowprotected final WorkflowManager workflowManager
protected AbstractJiraWorkflow(WorkflowManager workflowManager, com.opensymphony.workflow.loader.WorkflowDescriptor workflowDescriptor)
public abstract String getName()
getName in interface JiraWorkflowpublic String getDescription()
getDescription in interface JiraWorkflowpublic String getDisplayName()
getDisplayName in interface JiraWorkflowpublic com.opensymphony.workflow.loader.WorkflowDescriptor getDescriptor()
getDescriptor in interface JiraWorkflowpublic Collection<com.opensymphony.workflow.loader.ActionDescriptor> getAllActions()
JiraWorkflowgetAllActions in interface JiraWorkflowActionDescriptors.public Collection<com.opensymphony.workflow.loader.ActionDescriptor> getActionsByName(String name)
JiraWorkflowname.getActionsByName in interface JiraWorkflowname - of the action to match. This is case-insensitive.ActionDescriptor whose name matched the given name.public int getNextActionId()
JiraWorkflowgetNextActionId in interface JiraWorkflowpublic Collection<com.opensymphony.workflow.loader.ActionDescriptor> getActionsWithResult(com.opensymphony.workflow.loader.StepDescriptor stepDescriptor)
JiraWorkflowgetActionsWithResult in interface JiraWorkflowpublic Collection getStepsWithAction(com.opensymphony.workflow.loader.StepDescriptor stepDescriptor)
public boolean removeStep(com.opensymphony.workflow.loader.StepDescriptor stepDescriptor)
JiraWorkflowThis method will also remove all actions with this step ID as their unconditional result.
removeStep in interface JiraWorkflowtrue if the remove was successfulpublic com.opensymphony.workflow.loader.StepDescriptor getLinkedStep(org.ofbiz.core.entity.GenericValue status)
JiraWorkflowgetLinkedStep in interface JiraWorkflowstatus - the Statuspublic com.opensymphony.workflow.loader.StepDescriptor getLinkedStep(Status status)
JiraWorkflowgetLinkedStep in interface JiraWorkflowstatus - the Statuspublic Status getLinkedStatus(com.opensymphony.workflow.loader.StepDescriptor stepDescriptor)
JiraWorkflowgetLinkedStatus in interface JiraWorkflowstepDescriptor - the StepDescriptorpublic Status getLinkedStatusObject(com.opensymphony.workflow.loader.StepDescriptor stepDescriptor)
JiraWorkflowgetLinkedStatusObject in interface JiraWorkflowstepDescriptor - the StepDescriptorpublic String getLinkedStatusId(com.opensymphony.workflow.loader.StepDescriptor stepDescriptor)
JiraWorkflowStatus associated with the given StepDescriptorgetLinkedStatusId in interface JiraWorkflowstepDescriptor - the StepDescriptorpublic List<org.ofbiz.core.entity.GenericValue> getLinkedStatuses()
JiraWorkflowgetLinkedStatuses in interface JiraWorkflowList of GenericValuepublic List<Status> getLinkedStatusObjects()
JiraWorkflowgetLinkedStatusObjects in interface JiraWorkflowList of Status objectspublic Set<String> getLinkedStatusIds()
JiraWorkflowgetLinkedStatusIds in interface JiraWorkflowSet of String status id'spublic Collection getStepsForTransition(com.opensymphony.workflow.loader.ActionDescriptor actionDescriptor)
JiraWorkflowgetStepsForTransition in interface JiraWorkflowpublic Collection<com.opensymphony.workflow.loader.FunctionDescriptor> getPostFunctionsForTransition(com.opensymphony.workflow.loader.ActionDescriptor actionDescriptor)
JiraWorkflowgetPostFunctionsForTransition in interface JiraWorkflowpublic boolean isActive()
throws WorkflowException
JiraWorkflowisActive in interface JiraWorkflowtrue if this workflow object is active.WorkflowException - Runtime Exception indicating a problem in the WorkflowManager.public boolean isSystemWorkflow()
throws WorkflowException
JiraWorkflowisSystemWorkflow in interface JiraWorkflowtrue if this workflow object is the uneditable system workflow.WorkflowException - Runtime Exception indicating a problem in the WorkflowManager.public boolean isEditable()
throws WorkflowException
JiraWorkflowSystem workflows are never editable. The "published" version of an active workflow is not editable, but the draft version is. Inactive workflows are editable.
isEditable in interface JiraWorkflowtrue if this workflow is editable.WorkflowException - Runtime Exception indicating a problem in the WorkflowManager.public boolean isDefault()
JiraWorkflowisDefault in interface JiraWorkflowtrue if this is the workflow is the default JIRA workflow.public boolean isInitialAction(com.opensymphony.workflow.loader.ActionDescriptor actionDescriptor)
isInitialAction in interface JiraWorkflowpublic boolean isCommonAction(com.opensymphony.workflow.loader.ActionDescriptor actionDescriptor)
isCommonAction in interface JiraWorkflowpublic boolean isGlobalAction(com.opensymphony.workflow.loader.ActionDescriptor actionDescriptor)
isGlobalAction in interface JiraWorkflowpublic boolean isOrdinaryAction(com.opensymphony.workflow.loader.ActionDescriptor actionDescriptor)
isOrdinaryAction in interface JiraWorkflowpublic String getActionType(com.opensymphony.workflow.loader.ActionDescriptor actionDescriptor)
getActionType in interface JiraWorkflowpublic void reset()
reset in interface JiraWorkflowpublic Collection<com.opensymphony.workflow.loader.ActionDescriptor> getActionsForScreen(FieldScreen fieldScreen)
getActionsForScreen in interface JiraWorkflowpublic int compareTo(JiraWorkflow o)
compareTo in interface Comparable<JiraWorkflow>public String getUpdateAuthorName()
JiraWorkflowgetUpdateAuthorName in interface JiraWorkflowpublic ApplicationUser getUpdateAuthor()
JiraWorkflowUserManager.isUserExisting(com.atlassian.jira.user.ApplicationUser)
if you want to check user's existence.getUpdateAuthor in interface JiraWorkflowpublic Date getUpdatedDate()
JiraWorkflowgetUpdatedDate in interface JiraWorkflowpublic boolean hasDraftWorkflow()
JiraWorkflowhasDraftWorkflow in interface JiraWorkflowtrue if this workflow has a draft edit copy.public String getMode()
JiraWorkflowJiraWorkflow.DRAFT or JiraWorkflow.LIVE depending on the workflow implementation.getMode in interface JiraWorkflowJiraWorkflow.DRAFT or JiraWorkflow.LIVECopyright © 2002-2018 Atlassian. All Rights Reserved.