Package com.atlassian.bamboo.plan.branch
Class ChainBranchImpl
- java.lang.Object
-
- com.atlassian.core.bean.EntityObject
-
- All Implemented Interfaces:
Chain,BambooIdProvider,BambooObject,BambooObjectWithOid,EntityWithOid,ImmutableEntityWithOid,Deletable,Describable,ChainBranch,ChainBranchIdentifier,ImmutableChain,ImmutableChainBranch,ImmutableDeletable,ImmutablePlan,Plan,PlanIdentifier,PlanKeyProvider,Triggerable,DescriptionProvider,NameProvider,Versionable,Cloneable,Comparable<Plan>
@Entity public class ChainBranchImpl extends AbstractChain implements ChainBranch
-
-
Field Summary
-
Fields inherited from class com.atlassian.bamboo.plan.AbstractChain
master, NUMBER_OF_RESULTS
-
Fields inherited from class com.atlassian.bamboo.plan.AbstractPlan
resultsSummaryManager
-
Fields inherited from interface com.atlassian.bamboo.plan.cache.ImmutablePlan
MAX_PREVIOUS_BUILD_FOR_AVE, STATUS_CURRENTLY_BUILDING, STATUS_FAIL, STATUS_NO_BUILDS, STATUS_NOT_RUN, STATUS_SUCCESS
-
Fields inherited from interface com.atlassian.bamboo.plan.PlanIdentifier
NAME_DELIMITER
-
Fields inherited from interface com.atlassian.bamboo.plan.PlanKeyProvider
getPlanKey
-
-
Constructor Summary
Constructors Constructor Description ChainBranchImpl()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static List<PlanRepositoryDefinition>createEffectivePlanRepositoryDefinitions(List<PlanRepositoryDefinition> branchRepositories, List<PlanRepositoryDefinition> masterRepositories)BranchCommitInformationgetCommitInformation()@NotNull List<RepositoryDefinition>getEffectiveRepositoryDefinitions()Return list of repositories available to the chain.StringgetLinkedJiraIssue()Branches can be linked to a specific jira issue.@NotNull ChaingetMaster()Return the master plan if one exists.PlanBranchMetadatagetMetadata()NotificationSetgetNotificationSet()Get notifications defined for this plan.@NotNull List<PlanRepositoryDefinition>getPlanRepositoryDefinitions()Return list of repositories available to the chain.@NotNull PlanTypegetPlanType()booleanisDivergent()Is branch divergent.booleanisRemoteJiraLinkRequired()Stores whether a JIRA Issue exists but the remote issue link has not successfully been created for this branchvoidsetCommitInformation(@Nullable BranchCommitInformation commitInformation)voidsetDivergent(boolean divergent)voidsetLinkedJiraIssue(String linkedJiraIssue)voidsetMaster(@NotNull Plan master)Set which plan is the master of this plan.voidsetMetadata(@NotNull PlanBranchMetadata planBranchMetadata)voidsetRemoteJiraLinkRequired(boolean remoteJiraIssueLinkRequired)-
Methods inherited from class com.atlassian.bamboo.plan.AbstractChain
addNewStage, addStage, addStage, containsStage, getAllJobs, getAllStages, getAverageBuildDuration, getCurrentStatus, getJobCount, getLastResultKey, getNotificationSetField, getStages, getStorageTag, getTriggerDefinitions, getVcsBambooSpecsSource, isActive, isExecuting, isSuspended, removeStage, removeStagesIf, setAllStages, setBambooSpecsManager, setChainExecutionManager, setNotificationSet, setRepositoryDefinitionManager, setStorageTag, setVcsBambooSpecsSource
-
Methods inherited from class com.atlassian.bamboo.plan.AbstractPlan
compareTo, equals, getBuildDefinition, getBuildDefinitionXml, getBuildKey, getBuildLogger, getBuildName, getDatabaseId, getDescription, getDiscriminator, getEffectiveVariables, getFirstBuildNumber, getKey, getLabellings, getLabelNames, getLastBuildNumber, getLatestResultsSummary, getMasterId, getMasterIdIfExists, getName, getPlanKey, getProject, getRelatedLabellings, getType, getVariables, getVersion, hashCode, hasMaster, isBusy, isMarkedForDeletion, isSuspendedFromBuilding, setBuildDefinitionManager, setBuildDefinitionXml, setBuildKey, setBuildLoggerManager, setBuildName, setDescription, setDiscriminator, setKey, setLabellings, setLabelManager, setMarkedForDeletion, setName, setPlanExecutionManager, setPlanKey, setProject, setResultsSummaryManager, setSuspendedFromBuilding, setVariableDefinitionManager, setVersion
-
Methods inherited from class com.atlassian.bamboo.hibernate.HibernateBambooEntityWithOid
getId, getOid, setId, setOid
-
Methods inherited from class com.atlassian.core.bean.EntityObject
clone, getCreationDate, getCurrentDate, getLastModificationDate, setClock, setCreationDate, setLastModificationDate
-
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.atlassian.bamboo.core.BambooObject
setId
-
Methods inherited from interface com.atlassian.bamboo.chains.Chain
addNewStage, addStage, addStage, getAllJobs, getAllStages, getStages, removeStage, removeStagesIf, setNotificationSet, setStorageTag
-
Methods inherited from interface com.atlassian.bamboo.deletion.Deletable
setMarkedForDeletion
-
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.core.EntityWithOid
setOid
-
Methods inherited from interface com.atlassian.bamboo.plan.cache.ImmutableChain
containsStage, getCreationDate, getEntityType, getJobCount, getLastResultKey, getStorageTag, getVcsBambooSpecsSource
-
Methods inherited from interface com.atlassian.bamboo.core.ImmutableEntityWithOid
getOid
-
Methods inherited from interface com.atlassian.bamboo.plan.cache.ImmutablePlan
getAverageBuildDuration, getBuildDefinition, getBuildLogger, getCurrentStatus, getEffectiveVariables, getFirstBuildNumber, getKey, getLabelNames, getLastBuildNumber, getProject, getType, getVariables, hasMaster, isActive, isBusy, isExecuting, isMarkedForDeletion
-
Methods inherited from interface com.atlassian.bamboo.plan.Plan
getBuildDefinitionXml, getLabellings, getLatestResultsSummary, getRelatedLabellings, setBuildDefinitionXml, setBuildKey, setBuildName, setKey, setLabellings, setPlanKey, setProject, setSuspendedFromBuilding
-
Methods inherited from interface com.atlassian.bamboo.plan.PlanIdentifier
getBuildKey, getBuildName, getDatabaseId, getId, getMasterId, getMasterIdIfExists, getName, getPlanKey, isSuspendedFromBuilding
-
Methods inherited from interface com.atlassian.bamboo.trigger.Triggerable
getTriggerDefinitions, isSuspended
-
Methods inherited from interface com.atlassian.bamboo.versioning.Versionable
getVersion
-
-
-
-
Method Detail
-
getMaster
@NotNull public @NotNull Chain getMaster()
Description copied from interface:ImmutablePlanReturn the master plan if one exists. The master is the plan which this one is derived from. Configuration is pulled from the master if one exists.- Specified by:
getMasterin interfaceChain- Specified by:
getMasterin interfaceImmutableChain- Specified by:
getMasterin interfaceImmutablePlan- Overrides:
getMasterin classAbstractChain- Returns:
- the master
Planif one exists.
-
getPlanType
@NotNull public @NotNull PlanType getPlanType()
- Specified by:
getPlanTypein interfacePlanIdentifier- Returns:
- the type of this plan
-
setCommitInformation
public void setCommitInformation(@Nullable @Nullable BranchCommitInformation commitInformation)- Specified by:
setCommitInformationin interfaceChainBranch
-
getCommitInformation
public BranchCommitInformation getCommitInformation()
- Specified by:
getCommitInformationin interfaceImmutableChainBranch
-
getMetadata
public PlanBranchMetadata getMetadata()
- Specified by:
getMetadatain interfaceImmutableChainBranch
-
setMetadata
public void setMetadata(@NotNull @NotNull PlanBranchMetadata planBranchMetadata)- Specified by:
setMetadatain interfaceChainBranch
-
getLinkedJiraIssue
public String getLinkedJiraIssue()
Description copied from interface:ChainBranchIdentifierBranches can be linked to a specific jira issue. This is the issue key of that issue.- Specified by:
getLinkedJiraIssuein interfaceChainBranchIdentifier- Returns:
-
setLinkedJiraIssue
public void setLinkedJiraIssue(String linkedJiraIssue)
- Specified by:
setLinkedJiraIssuein interfaceChainBranch
-
isRemoteJiraLinkRequired
public boolean isRemoteJiraLinkRequired()
Description copied from interface:ChainBranchIdentifierStores whether a JIRA Issue exists but the remote issue link has not successfully been created for this branch- Specified by:
isRemoteJiraLinkRequiredin interfaceChainBranchIdentifier- Returns:
- true if a remote issue link has not yet been created.
-
setRemoteJiraLinkRequired
public void setRemoteJiraLinkRequired(boolean remoteJiraIssueLinkRequired)
- Specified by:
setRemoteJiraLinkRequiredin interfaceChainBranch
-
getEffectiveRepositoryDefinitions
@NotNull public @NotNull List<RepositoryDefinition> getEffectiveRepositoryDefinitions()
Description copied from interface:ImmutableChainReturn list of repositories available to the chain. In case of non-master object it will return list of master's repository definitions with default repository overridden by a private copy of default repository.- Specified by:
getEffectiveRepositoryDefinitionsin interfaceImmutableChain- Overrides:
getEffectiveRepositoryDefinitionsin classAbstractChain- Returns:
- ordered
Listof repositories available to this plan
-
getPlanRepositoryDefinitions
@NotNull public @NotNull List<PlanRepositoryDefinition> getPlanRepositoryDefinitions()
Description copied from interface:ImmutableChainReturn list of repositories available to the chain. In case of non-master object it will return list of master's repository definitions with default repository overridden by a private copy of default repository.- Specified by:
getPlanRepositoryDefinitionsin interfaceImmutableChain- Overrides:
getPlanRepositoryDefinitionsin classAbstractChain- Returns:
- ordered
Listof repositories available to this plan
-
createEffectivePlanRepositoryDefinitions
public static List<PlanRepositoryDefinition> createEffectivePlanRepositoryDefinitions(List<PlanRepositoryDefinition> branchRepositories, List<PlanRepositoryDefinition> masterRepositories)
-
getNotificationSet
public NotificationSet getNotificationSet()
Description copied from interface:ImmutableChainGet notifications defined for this plan.- Specified by:
getNotificationSetin interfaceImmutableChain- Overrides:
getNotificationSetin classAbstractChain- Returns:
NotificationSetcontaining notifications for this plan.
-
setMaster
public void setMaster(@NotNull @NotNull Plan master)Description copied from interface:PlanSet which plan is the master of this plan. The master is the plan which this one is derived from. Configuration is pulled from the master if one exists.- Specified by:
setMasterin interfaceChainBranch- Specified by:
setMasterin interfacePlan
-
isDivergent
public boolean isDivergent()
Description copied from interface:ImmutableChainBranchIs branch divergent.- Specified by:
isDivergentin interfaceImmutableChainBranch
-
setDivergent
public void setDivergent(boolean divergent)
- Specified by:
setDivergentin interfaceChainBranch
-
-