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
 T clearMappings()
          Remove all the mappings currently stored in the builder.
 String getDefaultWorkflow()
           
 String getDescription()
           
 Long getId()
           
 String getMapping(String issueTypeId)
           
 Map<String,String> getMappings()
           
 String getName()
           
 boolean isDefault()
           
 boolean isDraft()
           
 T removeDefault()
          Remove the default mapping from the scheme.
 T removeMapping(String issueTypeId)
          Remove the mapping for the passed issue type from the scheme.
 T removeWorkflow(String workflowName)
          Remove all explicit references to the passed workflow from the scheme.
 T setDefaultWorkflow(String workflowName)
          Set the default workflow for the scheme.
 T setMapping(String issueTypeId, String workflowName)
          Set the workflow for the passed issue type.
 T setMappings(Map<String,String> mappings)
          Set the workflow map for the scheme.
 

Method Detail

getDefaultWorkflow

String getDefaultWorkflow()

getMapping

String getMapping(@Nonnull
                  String issueTypeId)

getMappings

Map<String,String> getMappings()

getId

Long getId()

isDraft

boolean isDraft()

isDefault

boolean isDefault()

getDescription

String getDescription()

getName

String getName()

setDefaultWorkflow

@Nonnull
T setDefaultWorkflow(@Nonnull
                             String workflowName)
Set the default workflow for the scheme.

Parameters:
workflowName - the default workflow for the scheme.
Returns:
the builder.

setMapping

@Nonnull
T setMapping(@Nonnull
                     String issueTypeId,
                     @Nonnull
                     String workflowName)
Set the workflow for the passed issue type.

Parameters:
issueTypeId - the issue type to map.
workflowName - the workflow to map
Returns:
the builder.

setMappings

@Nonnull
T setMappings(@Nonnull
                      Map<String,String> mappings)
Set the workflow map for the scheme. Its basically a mapping from issueTypeId -> workflowName.

Parameters:
mappings - the mappings to set in the scheme.
Returns:
this builder.

removeMapping

@Nonnull
T removeMapping(@Nonnull
                        String issueTypeId)
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

@Nonnull
T removeDefault()
Remove the default mapping from the scheme.

Returns:
this builder.

clearMappings

@Nonnull
T clearMappings()
Remove all the mappings currently stored in the builder.

Returns:
this builder

removeWorkflow

@Nonnull
T removeWorkflow(@Nonnull
                         String workflowName)
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.


Copyright © 2002-2013 Atlassian. All Rights Reserved.