Package com.atlassian.jira.workflow
Interface WorkflowScheme.Builder<T extends WorkflowScheme.Builder<T>>
- Type Parameters:
T- the type of builder to return.
- All Known Subinterfaces:
AssignableWorkflowScheme.Builder,DraftWorkflowScheme.Builder
- All Known Implementing Classes:
DraftWorkflowSchemeBuilder,MockAssignableWorkflowScheme.MockBuilder,MockDraftWorkflowScheme.MockBuilder
- Enclosing interface:
- WorkflowScheme
public static interface WorkflowScheme.Builder<T extends WorkflowScheme.Builder<T>>
A builder that can be used to change a workflow scheme.
-
Method Summary
Modifier and TypeMethodDescriptionRemove all the mappings currently stored in the builder.getId()getMapping(String issueTypeId) getName()booleanbooleanisDraft()Remove the default mapping from the scheme.removeMapping(String issueTypeId) Remove the mapping for the passed issue type from the scheme.removeWorkflow(String workflowName) Remove all explicit references to the passed workflow from the scheme.setDefaultWorkflow(String workflowName) Set the default workflow for the scheme.setMapping(String issueTypeId, String workflowName) Set the workflow for the passed issue type.setMappings(Map<String, String> mappings) Set the workflow map for the scheme.
-
Method Details
-
getDefaultWorkflow
String getDefaultWorkflow() -
getMapping
-
getMappings
-
getId
Long getId() -
isDraft
boolean isDraft() -
isDefault
boolean isDefault() -
getDescription
String getDescription() -
getName
String getName() -
setDefaultWorkflow
Set the default workflow for the scheme.- Parameters:
workflowName- the default workflow for the scheme.- Returns:
- the builder.
-
setMapping
Set the workflow for the passed issue type.- Parameters:
issueTypeId- the issue type to map.workflowName- the workflow to map- Returns:
- the builder.
-
setMappings
Set the workflow map for the scheme. Its basically a mapping fromissueTypeId -> workflowName.- Parameters:
mappings- the mappings to set in the scheme.- Returns:
- this builder.
-
removeMapping
Remove the mapping for the passed issue type from the scheme.- Parameters:
issueTypeId- the issue type whose mapping is to be removed.- Returns:
- this builder.
-
removeDefault
Remove the default mapping from the scheme.- Returns:
- this builder.
-
clearMappings
Remove all the mappings currently stored in the builder.- Returns:
- this builder
-
removeWorkflow
Remove all explicit references to the passed workflow from the scheme. This method sets the default workflow to null if it matches the passed workflow.- Parameters:
workflowName- the name of the workflow to remove.- Returns:
- this builder.
-