com.atlassian.bamboo.chains
Interface Chain

All Superinterfaces:
BambooObject, Deletable, Describable, DescriptionProvider, NameProvider, Plan, TopLevelPlan
All Known Implementing Classes:
DefaultChain

public interface Chain
extends TopLevelPlan


Field Summary
 
Fields inherited from interface com.atlassian.bamboo.plan.Plan
MAX_NUMBER_LOG_ENTRIES, MAX_PREVIOUS_BUILD_FOR_AVE, STATUS_CURRENTLY_BUILDING, STATUS_FAIL, STATUS_NO_BUILDS, STATUS_NOT_RUN, STATUS_SUCCESS
 
Method Summary
 ChainStage addNewStage(java.lang.String name, java.lang.String description)
           
 void addStage(ChainStage chainStage)
           
 boolean containsStage(java.lang.String stageName)
          Checks whether or not a stage exists in this chain by stage name.
 java.util.List<Job> getAllJobs()
          Note: Does not include Jobs that are marked for deletion.
 java.util.List<ChainStage> getAllStages()
          Get Stages of the Chain Note that this includes ChainStages that have been marked for deletion
 int getJobCount()
          Note: Does not include Jobs that are marked for deletion.
 java.util.List<ChainStage> getStages()
          Get Stages of the chain.
 void removeStage(ChainStage chainStage)
           
 
Methods inherited from interface com.atlassian.bamboo.plan.TopLevelPlan
getNotificationSet, setNotificationSet
 
Methods inherited from interface com.atlassian.bamboo.plan.Plan
getAverageBuildDuration, getBuildDefinition, getBuildDefinitionXml, getBuildKey, getBuildLogger, getBuildName, getCurrentStatus, getFirstBuildNumber, getKey, getLabellings, getLastBuildNumber, getLastVcsRevisionKey, getLatestResultsSummary, getName, getNextBuildNumber, getPlanKey, getProject, getRelatedLabellings, getSourceCodeDirectory, getType, hasTests, isActive, isBusy, isExecuting, isSuspendedFromBuilding, setBuildDefinitionXml, setBuildKey, setBuildName, setFirstBuildNumber, setKey, setLabellings, setLastBuildNumber, setLastVcsRevisionKey, setNextBuildNumber, setProject, setSuspendedFromBuilding, validateBuild
 
Methods inherited from interface com.atlassian.bamboo.Describable
setDescription, setName
 
Methods inherited from interface com.atlassian.bamboo.utils.DescriptionProvider
getDescription
 
Methods inherited from interface com.atlassian.bamboo.deletion.Deletable
isMarkedForDeletion, setMarkedForDeletion
 
Methods inherited from interface com.atlassian.bamboo.core.BambooObject
getId, setId
 

Method Detail

getStages

@NotNull
java.util.List<ChainStage> getStages()
Get Stages of the chain. Note that this excludes ChainStages that have been marked for deletion

Returns:
stages

getAllStages

@NotNull
java.util.List<ChainStage> getAllStages()
Get Stages of the Chain Note that this includes ChainStages that have been marked for deletion

Returns:
stages

addNewStage

@NotNull
ChainStage addNewStage(@NotNull
                               java.lang.String name,
                               @NotNull
                               java.lang.String description)

addStage

void addStage(@NotNull
              ChainStage chainStage)

removeStage

void removeStage(@NotNull
                 ChainStage chainStage)

getJobCount

int getJobCount()
Note: Does not include Jobs that are marked for deletion.

Returns:
how many Jobs are currently contained within this chain

getAllJobs

java.util.List<Job> getAllJobs()
Note: Does not include Jobs that are marked for deletion.

Returns:
a list of all Jobs that are currently contained within this chain - no order guaranteed.

containsStage

boolean containsStage(@Nullable
                      java.lang.String stageName)
Checks whether or not a stage exists in this chain by stage name.

Parameters:
stageName - to check for
Returns:
true if a stage with the given name exists, otherwise false


Copyright © 2010 Atlassian. All Rights Reserved.