public abstract class AbstractImmutablePlan extends Object implements ImmutablePlan
| Modifier and Type | Field and Description |
|---|---|
protected io.atlassian.util.concurrent.LazyReference<Long> |
averageBuildDuration |
protected ResultsSummaryManager |
resultsSummaryManager |
MAX_NUMBER_LOG_ENTRIES, MAX_PREVIOUS_BUILD_FOR_AVE, STATUS_CURRENTLY_BUILDING, STATUS_FAIL, STATUS_NO_BUILDS, STATUS_NOT_RUN, STATUS_SUCCESSgetPlanKeyFunction, NAME_DELIMITERgetPlanKey| Modifier | Constructor and Description |
|---|---|
|
AbstractImmutablePlan(Long databaseId,
ImmutablePlan plan,
BuildLoggerManager buildLoggerManager,
LabelManager labelManager,
VariableDefinitionManager variableDefinitionManager,
BuildDefinition buildDefinition,
ResultsSummaryManager resultsSummaryManager) |
protected |
AbstractImmutablePlan(Long databaseId,
ImmutablePlan plan,
PlanKey planKey,
String name,
BuildLoggerManager buildLoggerManager,
LabelManager labelManager,
VariableDefinitionManager variableDefinitionManager,
BuildDefinition buildDefinition,
ResultsSummaryManager resultsSummaryManager) |
| Modifier and Type | Method and Description |
|---|---|
int |
compareTo(ImmutablePlan plan) |
boolean |
equals(Object o) |
protected void |
exceptionOnModification() |
long |
getAverageBuildDuration()
Returns an average duration of the recent builds
|
BuildDefinition |
getBuildDefinition()
Returns the
BuildDefinition that backs this Plan |
String |
getBuildKey()
This objects specific portion of the key.
|
BuildLogger |
getBuildLogger()
Returns the helper object to deal with logging
|
String |
getBuildName() |
String |
getCurrentStatus() |
Optional<Long> |
getDatabaseId() |
String |
getDescription() |
List<VariableDefinition> |
getEffectiveVariables()
Return effective list of
VariableDefinitions bind to this Plan. |
int |
getFirstBuildNumber()
What the number of the first build we have? It may not be 1 as some may have been removed!
|
long |
getId()
Returns database id of the plan.
|
String |
getKey()
Obtain the plan's unique key (uppercase alphanumeric).
|
List<Labelling> |
getLabellings() |
List<String> |
getLabelNames() |
int |
getLastBuildNumber()
What was the number of the latest build (may be being built)
|
long |
getMasterId() |
Optional<Long> |
getMasterIdIfExists() |
String |
getName()
Returns the full name for the build in the form of "project name - build name" e.g.
|
BambooEntityOid |
getOid()
OID assigned to this object.
|
PlanKey |
getPlanKey()
|
PlanType |
getPlanType() |
Project |
getProject()
Returns the parent
Project |
List<Labelling> |
getRelatedLabellings() |
String |
getType()
Returns the string representation of the type.
|
List<VariableDefinition> |
getVariables()
Return list of
VariableDefinitions bind to this Plan |
int |
hashCode() |
boolean |
hasMaster() |
boolean |
isMarkedForDeletion()
Is the plan set to be deleted in the future
|
boolean |
isSuspendedFromBuilding()
Checks if the build has been enabled / disabled.
|
abstract void |
resetLatestResultsSummary(int latestKnownBuildNumber) |
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, waitgetLatestResultsSummary, getMaster, isActive, isBusy, isExecutinggetEntityTypeprotected final ResultsSummaryManager resultsSummaryManager
protected io.atlassian.util.concurrent.LazyReference<Long> averageBuildDuration
public AbstractImmutablePlan(@Nullable
Long databaseId,
@NotNull
ImmutablePlan plan,
BuildLoggerManager buildLoggerManager,
@NotNull
LabelManager labelManager,
VariableDefinitionManager variableDefinitionManager,
@NotNull
BuildDefinition buildDefinition,
ResultsSummaryManager resultsSummaryManager)
protected AbstractImmutablePlan(@Nullable
Long databaseId,
@NotNull
ImmutablePlan plan,
@NotNull
PlanKey planKey,
@NotNull
String name,
BuildLoggerManager buildLoggerManager,
@NotNull
LabelManager labelManager,
VariableDefinitionManager variableDefinitionManager,
@NotNull
BuildDefinition buildDefinition,
ResultsSummaryManager resultsSummaryManager)
public long getId()
PlanIdentifierPlanIdentifier.getDatabaseId() should be preferred.getId in interface BambooIdProvidergetId in interface PlanIdentifier@NotNull public Optional<Long> getDatabaseId()
getDatabaseId in interface PlanIdentifierpublic String getDescription()
getDescription in interface DescriptionProvider@NotNull public PlanKey getPlanKey()
PlanIdentifiergetPlanKey in interface PlanIdentifiergetPlanKey in interface PlanKeyProvider@NotNull public String getKey()
ImmutablePlanPlanIdentifier.getPlanKey()getKey in interface ImmutablePlan@NotNull public String getBuildKey()
PlanIdentifierPlanIdentifier.getPlanKey().getBuildKey in interface PlanIdentifier@NotNull public String getName()
PlanIdentifiergetName in interface PlanIdentifiergetName in interface DescriptionProvidergetName in interface NameProvider@NotNull public String getBuildName()
getBuildName in interface PlanIdentifierPlanIdentifier.getName()@NotNull public PlanType getPlanType()
getPlanType in interface PlanIdentifier@NotNull public String getType()
ImmutablePlanPlanType and used in Freemarker.getType in interface ImmutablePlanpublic boolean isMarkedForDeletion()
ImmutablePlanisMarkedForDeletion in interface ImmutablePlanpublic boolean hasMaster()
hasMaster in interface ImmutablePlan@NotNull public List<VariableDefinition> getVariables()
ImmutablePlanVariableDefinitions bind to this PlangetVariables in interface ImmutablePlanVariableDefinition@NotNull public List<VariableDefinition> getEffectiveVariables()
ImmutablePlanVariableDefinitions bind to this Plan.
For master Plans this will return the same result as ImmutablePlan.getVariables().
Non-master plans will produce the sum of:
- all master's variables which keys do not appear in result of ImmutablePlan.getVariables()
- result of ImmutablePlan.getVariables()getEffectiveVariables in interface ImmutablePlanVariableDefinitionpublic boolean isSuspendedFromBuilding()
PlanIdentifierisSuspendedFromBuilding in interface PlanIdentifierpublic int getFirstBuildNumber()
ImmutablePlangetFirstBuildNumber in interface ImmutablePlanpublic int getLastBuildNumber()
ImmutablePlangetLastBuildNumber in interface ImmutablePlan@NotNull public BuildDefinition getBuildDefinition()
ImmutablePlanBuildDefinition that backs this PlangetBuildDefinition in interface ImmutablePlanBuildDefinition object.@NotNull public Project getProject()
ImmutablePlanProjectgetProject in interface ImmutablePlangetProject in interface PlanIdentifierProject. Never nullpublic long getAverageBuildDuration()
ImmutablePlangetAverageBuildDuration in interface ImmutablePlanpublic long getMasterId()
getMasterId in interface PlanIdentifier@NotNull public Optional<Long> getMasterIdIfExists()
getMasterIdIfExists in interface PlanIdentifier@NotNull public List<String> getLabelNames()
getLabelNames in interface ImmutablePlan@NotNull public String getCurrentStatus()
getCurrentStatus in interface ImmutablePlanpublic BambooEntityOid getOid()
ImmutableEntityWithOidBambooEntityOid.getEntityType() should be the same as this object's
ImmutableEntityWithOid.getEntityType().getOid in interface ImmutableEntityWithOid@Internal public abstract void resetLatestResultsSummary(int latestKnownBuildNumber)
protected void exceptionOnModification()
@NotNull public BuildLogger getBuildLogger()
ImmutablePlangetBuildLogger in interface ImmutablePlanBuildLogger.public int compareTo(ImmutablePlan plan)
Copyright © 2019 Atlassian Software Systems Pty Ltd. All rights reserved.