|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.atlassian.bamboo.build.BuildObjectForTests
public class BuildObjectForTests
Information about a build under Continuous Integration.
| Field Summary | |
|---|---|
protected java.util.List |
myBuildResultSummaries
|
| 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 |
| Constructor Summary | |
|---|---|
BuildObjectForTests()
Simple package constructor for testing |
|
BuildObjectForTests(Repository repository,
java.lang.String name)
Create a build |
|
BuildObjectForTests(Repository repository,
java.lang.String name,
java.lang.String emailAddress)
Create a build |
|
| Method Summary | |
|---|---|
java.lang.String |
addBuildLogEntry(LogEntry logEntry)
|
java.lang.String |
addBuildLogEntry(java.lang.String entryDescription)
Add a new entry to the build log |
void |
addBuildResultSummary(BuildResultsSummary buildResultsSummary)
Add the given build results summary to the build. |
void |
clearBuildLog()
|
boolean |
equals(java.lang.Object o)
We're only using the build name to compare builds |
java.util.Collection<Artifact> |
getArtifactDefinitions()
|
long |
getAverageBuildDuration()
Returns an average duration of the recent builds |
java.util.List |
getBuildChangedEmailList()
Who wants to know when the build changes? A list of individual email addresses. |
java.lang.String |
getBuildChangedEmails()
Who wants to know when the build changes? One or more email addresses (comma separated list) |
BuildDefinition |
getBuildDefinition()
Returns the BuildDefinition that backs this buildd |
BuildDefinitionForBuild |
getBuildDefinitionXml()
|
Builder |
getBuilder()
Obtain the build's Builder. |
BuilderManager |
getBuilderManager()
|
BuilderV2 |
getBuilderV2()
|
java.lang.String |
getBuildKey()
Thie returns the build portion of the build key |
java.util.Collection |
getBuildLog()
Provide the latest build details. |
BuildLogger |
getBuildLogger()
Returns the helper object to deal with logging |
java.lang.String |
getBuildName()
Returns the name for the build in the form of "build name" e.g. |
BuildResultsSummaryManager |
getBuildResultsSummaryManager()
|
java.util.List |
getBuildResultSummaries()
Obtains the builds total collection of BuildResultsSummary objects (most
recent first), one for each build. |
BuildStrategy |
getBuildStrategy()
Returns to BuildStrategy that the user actually selects |
java.util.Map |
getConfigObjects()
Returns a map of objects generated by the plugins. |
BuildStrategy |
getCurrentBuildStrategy()
|
java.lang.String |
getCurrentStatus()
Returns the string representation the current status of a build. |
java.util.Map |
getCustomConfiguration()
A map consisting of String key and String value pairs. |
BuildDefinition |
getDefaultBuildDefinition()
|
java.lang.String |
getDescription()
|
java.util.List |
getFieldValueItems()
|
int |
getFirstBuildNumber()
What the number of the first build we have? It may not be 1 as some may have been removed! |
BuildResultsSummary |
getFirstBuildSummary()
Get the first build result |
long |
getId()
|
java.lang.String |
getKey()
Returns key of the project. |
java.util.List<Labelling> |
getLabellings()
|
int |
getLastBuildNumber()
What was the number of the lastest build (may be being built) |
java.util.Date |
getLastBuildStartTime()
When was the last time this build was built? |
java.lang.String |
getLastVcsRevisionKey()
The string value representing the last build triggered. |
BuildResultsSummary |
getLatestBuildSummary()
Get the summary from the latest build |
ResultsSummary |
getLatestResultsSummary()
Get the summary from the latest completed plan |
java.lang.String |
getName()
Obtain the build's name |
int |
getNextBuildNumber()
The next build number represents the number of the next build result that's to be executed |
BuildResults |
getNextBuildResults(int buildNumber)
|
NotificationSet |
getNotificationSet()
|
long |
getNumberOfBuildSummaries()
|
int |
getNumberOfConcurrentlyRunningBuilds()
Gets the number of currently running concurrent build instances for the build |
Plan |
getPlan()
|
PlanKey |
getPlanKey()
Get the PlanKey identifier for this Plan |
java.util.List<Plan> |
getPlans()
Returns all Plan associated with the Project. |
int |
getPollingPeriod()
How long should we wait between checking the build to see if it need building? |
BuildResults |
getPreviousBuildResults(int buildNumber)
Gets the first BuildResultsImpl before the passed number |
Project |
getProject()
Returns the parent Project |
java.util.List<Labelling> |
getRelatedLabellings()
|
Repository |
getRepository()
Obtain the build's Repository. |
RepositoryV2 |
getRepositoryV2()
A repository object that can be used to perform |
RequirementSet |
getRequirementSet()
|
java.io.File |
getSourceCodeDirectory()
Returns a file representing the source directory from the Repository |
java.util.List<TaskDefinition> |
getTaskDefinitions()
All tasks defined for this build. |
java.util.List<TestClass> |
getTestClasses()
|
java.util.List<TopLevelPlan> |
getTopLevelPlans()
This methods returns all TopLevelPlans, including the ones marked for deletion This collection is a lazy relationship for performance reasons. |
java.lang.String |
getType()
|
WebRepositoryViewer |
getWebRepositoryViewer()
Get the module responsible for displaying commits for this build. |
java.lang.String |
getXmlData()
|
XmppMessageSender |
getXmppMessageSender()
The build's option IM message server configuration |
boolean |
hasBuildResults()
Has the build got any build results to display? |
int |
hashCode()
IntelliJ generated hash |
boolean |
hasTests()
Helper method checking if plan has tests defined |
boolean |
isActive()
Checks if the plan has an active build(s). |
boolean |
isBusy()
Is the Plan busy |
boolean |
isExecuting()
Is the build currenlty being executed? |
boolean |
isInBuildQueue()
Is the build currenlty being built? |
boolean |
isInheritRepository()
Whether the BuildDefinition will use its own Repository or not or
will it use its parents' Repository |
boolean |
isMarkedForDeletion()
|
boolean |
isMarkedForEditBuild()
|
boolean |
isMarkedForManualBuild()
Has a manual build been requested for this build? |
boolean |
isSuspendedFromBuilding()
Checks if the build has been |
void |
markAsNeedingBuilding(ReasonForBuild reasonForBuild)
|
void |
markForDeletion()
|
void |
removeBuildResultSummary(int buildNumber)
Remove buildResultSummary and all persisted files for given build number |
void |
save()
|
void |
setBuildChangedEmails(java.lang.String emailAddress)
Define who is notified of build results by email |
void |
setBuildDefinition(BuildDefinitionForBuild buildDefinition)
|
void |
setBuildDefinitionXml(BuildDefinitionForBuild buildDefinitionXml)
|
void |
setBuilder(Builder builder)
Set the build's builder. |
void |
setBuilderManager(BuilderManager builderManager)
|
void |
setBuildKey(java.lang.String buildKey)
Define the build's unique key (uppercase alphanumeric) |
void |
setBuildName(java.lang.String buildName)
|
void |
setBuildResultsSummaryManager(BuildResultsSummaryManager buildResultsSummaryManager)
|
void |
setBuildResultSummaries(java.util.List buildResultSummaries)
Legacy left over method (this is the extreme version of build result summaries) |
void |
setBuildStrategy(BuildStrategy buildStrategy)
Set the strategy to override the default build strategy. |
void |
setConfigObjects(java.util.Map configObjects)
|
void |
setCustomConfiguration(java.util.Map configMap)
A map of String key and String value pairs, representing custom |
void |
setDescription(java.lang.String description)
|
void |
setFieldValueItems(java.util.List fieldValueItems)
|
void |
setFirstBuildNumber(int firstBuildNumber)
|
void |
setId(long id)
|
void |
setInBuildQueue(boolean isBuilding)
Set the is-building flag. |
void |
setInheritRepository(boolean inheritRepositoryFromParent)
Sets if the BuildDefinition should use the parents' Repository |
void |
setKey(java.lang.String key)
Sets the key for the project. |
void |
setLabellings(java.util.List labellings)
|
void |
setLastBuildNumber(int lastBuildNumber)
|
void |
setLastBuildStartTime(java.util.Date lastBuildTime)
Set the time of the last build |
void |
setLastVcsRevisionKey(java.lang.String lastVcsRevisionKey)
|
void |
setMarkedForDeletion(boolean markedForDeletion)
|
void |
setName(java.lang.String name)
|
void |
setNextBuildNumber(int nextBuildNumber)
|
void |
setNotificationSet(NotificationSet notificationSet)
|
void |
setPlan(Plan build)
|
void |
setPollingPeriod(int pollingPeriod)
How long should we wait between checking the build to see if it need building? |
void |
setProject(Project project)
|
void |
setRepository(Repository repository)
Set the build's source code repository. |
void |
setRequirementSet(RequirementSet requirementSet)
|
void |
setSuspendedFromBuilding(boolean suspendFromBuilding)
Sets the build to suspend temporarily |
void |
setTaskDefinitions(java.util.List<TaskDefinition> taskConfigs)
|
void |
setWebRepositoryViewer(WebRepositoryViewer webRepositoryViewer)
Set the module responsibile for displaying commits for this build. |
void |
setWorkingDirectory(java.lang.String buildDirectory)
|
void |
setXmlData(java.lang.String xmlData)
|
void |
setXmppMessageSender(XmppMessageSender xmppMessageSender)
The build's option IM message server configuration |
void |
unmarkBuild()
|
void |
unMarkForDeletion()
|
ErrorCollection |
validateBuild()
Validates the build's builder and source code locations |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected java.util.List myBuildResultSummaries
| Constructor Detail |
|---|
public BuildObjectForTests()
public BuildObjectForTests(Repository repository,
java.lang.String name)
repository - The Repository containing the buildname - The name of the build
public BuildObjectForTests(Repository repository,
java.lang.String name,
java.lang.String emailAddress)
repository - The Repository containing the buildname - The name of the buildemailAddress - The build email notification address| Method Detail |
|---|
@NotNull public java.util.List<TaskDefinition> getTaskDefinitions()
BuildDefinition
getTaskDefinitions in interface BuildDefinitionList of TaskDefinitions
public void setTaskDefinitions(@NotNull
java.util.List<TaskDefinition> taskConfigs)
setTaskDefinitions in interface BuildDefinitionpublic boolean isInheritRepository()
BuildDefinitionBuildDefinition will use its own Repository or not or
will it use its parents' Repository
isInheritRepository in interface BuildDefinitionpublic void setInheritRepository(boolean inheritRepositoryFromParent)
BuildDefinitionBuildDefinition should use the parents' Repository
setInheritRepository in interface BuildDefinitionpublic java.lang.String getLastVcsRevisionKey()
Plan
getLastVcsRevisionKey in interface Planpublic void setLastVcsRevisionKey(java.lang.String lastVcsRevisionKey)
setLastVcsRevisionKey in interface Planpublic BuildLogger getBuildLogger()
Plan
getBuildLogger in interface PlanBuildLogger. @NotNullpublic BuilderV2 getBuilderV2()
getBuilderV2 in interface BuildPlanDefinitionpublic RepositoryV2 getRepositoryV2()
BuildPlanDefinition
getRepositoryV2 in interface BuildPlanDefinitionpublic java.util.Collection<Artifact> getArtifactDefinitions()
public java.lang.String getCurrentStatus()
ProjectBuild@getCurrentStatus.
It will return "current" if any plan is building, and "fail" if any plan is failing.
getCurrentStatus in interface PlangetCurrentStatus in interface Projectpublic java.lang.String getBuildName()
Plan
getBuildName in interface Planpublic void setBuildName(java.lang.String buildName)
setBuildName in interface Planpublic BuildDefinitionForBuild getBuildDefinitionXml()
getBuildDefinitionXml in interface Planpublic void setBuildDefinitionXml(BuildDefinitionForBuild buildDefinitionXml)
setBuildDefinitionXml in interface Planpublic void setFieldValueItems(java.util.List fieldValueItems)
public void setNextBuildNumber(int nextBuildNumber)
setNextBuildNumber in interface Planpublic void setLastBuildNumber(int lastBuildNumber)
setLastBuildNumber in interface Planpublic void setFirstBuildNumber(int firstBuildNumber)
setFirstBuildNumber in interface Planpublic int getNextBuildNumber()
Plan
getNextBuildNumber in interface Planpublic void setKey(java.lang.String key)
Project
setKey in interface PlansetKey in interface Project@NotNull public PlanKey getPlanKey()
PlanPlanKey identifier for this Plan
getPlanKey in interface Planpublic java.lang.String getBuildKey()
Plan
getBuildKey in interface Planpublic void setProject(Project project)
setProject in interface Planpublic void setPlan(Plan build)
setPlan in interface BuildDefinitionForBuildpublic void setBuildDefinition(BuildDefinitionForBuild buildDefinition)
public java.lang.String getXmlData()
getXmlData in interface BuildDefinitionXmlpublic void setXmlData(java.lang.String xmlData)
setXmlData in interface BuildDefinitionXml@NotNull public BuildDefinition getBuildDefinition()
PlanBuildDefinition that backs this buildd
getBuildDefinition in interface PlanBuildDefinition object.public long getId()
getId in interface BambooObjectpublic void setId(long id)
setId in interface BambooObjectpublic Project getProject()
PlanProject
getProject in interface PlanProject. Never nullpublic Plan getPlan()
getPlan in interface BuildDefinitionForBuildpublic BuildStrategy getCurrentBuildStrategy()
public BuildStrategy getBuildStrategy()
BuildDefinitionBuildStrategy that the user actually selects
getBuildStrategy in interface BuildDefinitionBuildStrategypublic void save()
public void setBuildStrategy(BuildStrategy buildStrategy)
setBuildStrategy in interface BuildDefinitionbuildStrategy - The next build strategy to use.public Repository getRepository()
Repository.
getRepository in interface BuildDefinitiongetRepository in interface BuildPlanDefinitionpublic void setRepository(Repository repository)
setRepository in interface BuildDefinitionrepository - The source repoisitorypublic int getPollingPeriod()
getPollingPeriod in interface BuildDefinitionpublic void setPollingPeriod(int pollingPeriod)
setPollingPeriod in interface BuildDefinitionpollingPeriod - The time in secondspublic Builder getBuilder()
Builder.
getBuilder in interface BuildDefinitionpublic void setBuilder(Builder builder)
setBuilder in interface BuildDefinitionbuilder - the builderpublic java.lang.String getName()
getName in interface PlangetName in interface ProjectgetName in interface DescriptionProvidergetName in interface NameProviderpublic void setName(java.lang.String name)
setName in interface DescribablesetName in interface Projectpublic java.lang.String getDescription()
getDescription in interface DescriptionProviderpublic void setDescription(java.lang.String description)
setDescription in interface Describablepublic java.lang.String getKey()
Project
getKey in interface PlangetKey in interface Projectpublic BuildDefinition getDefaultBuildDefinition()
@NotNull public java.util.List<Plan> getPlans()
ProjectPlan associated with the Project. Returns Collections.emptyList() if
there are no Plans for the project.
This collection is a lazy relationship for performance reasons.
If you need to guarantee that these collections are available use PlanManager.getPlansByProject(Project, Class)
getPlans in interface ProjectList of Plans. Collections.emptyList() if no plans.@NotNull public java.util.List<TopLevelPlan> getTopLevelPlans()
ProjectPlanManager.getPlansByProject(Project, Class)
Use this method only if all you need is present in TopLevelPlan interface, otherwise consider using getAllChains.
getTopLevelPlans in interface Projectpublic java.util.List<Labelling> getLabellings()
getLabellings in interface PlangetLabellings in interface Projectpublic java.util.List<Labelling> getRelatedLabellings()
getRelatedLabellings in interface PlangetRelatedLabellings in interface Projectpublic void setLabellings(java.util.List labellings)
setLabellings in interface PlansetLabellings in interface Projectpublic void setBuildKey(java.lang.String buildKey)
Plan
setBuildKey in interface PlanbuildKey - The value of the keypublic java.lang.String getBuildChangedEmails()
getBuildChangedEmails in interface BuildDefinitionpublic void setBuildChangedEmails(java.lang.String emailAddress)
setBuildChangedEmails in interface BuildDefinitionemailAddress - The build email addresspublic java.util.List getBuildChangedEmailList()
getBuildChangedEmailList in interface BuildDefinitionpublic int getLastBuildNumber()
getLastBuildNumber in interface Planpublic int getFirstBuildNumber()
getFirstBuildNumber in interface Planpublic void addBuildResultSummary(BuildResultsSummary buildResultsSummary)
addBuildResultSummary in interface BuildablebuildResultsSummary - The build summarypublic void setBuildResultSummaries(java.util.List buildResultSummaries)
buildResultSummaries - public java.util.List getBuildResultSummaries()
BuildResultsSummary objects (most
recent first), one for each build.
EW 01/11/2006 - Moved to a hibernated source for build result summaries.
getBuildResultSummaries in interface Buildablepublic void setInBuildQueue(boolean isBuilding)
isBuilding - Is the build currently in the build pipeline?public boolean isInBuildQueue()
isInBuildQueue in interface Buildablepublic int getNumberOfConcurrentlyRunningBuilds()
Buildable
getNumberOfConcurrentlyRunningBuilds in interface Buildablepublic boolean isActive()
Plan
isActive in interface Planpublic boolean isExecuting()
Plan
isExecuting in interface Planpublic java.util.Date getLastBuildStartTime()
public void setLastBuildStartTime(java.util.Date lastBuildTime)
lastBuildTime - the timepublic void setWorkingDirectory(java.lang.String buildDirectory)
setWorkingDirectory in interface BuildDefinitionpublic boolean hasBuildResults()
hasBuildResults in interface Buildablepublic java.util.Map getCustomConfiguration()
BuildDefinition
getCustomConfiguration in interface BuildDefinitiongetCustomConfiguration in interface BuildPlanDefinitionpublic void setCustomConfiguration(java.util.Map configMap)
BuildDefinition
setCustomConfiguration in interface BuildDefinitionconfigMap - - can be nullpublic BuildResultsSummary getLatestBuildSummary()
getLatestBuildSummary in interface Buildablepublic ResultsSummary getLatestResultsSummary()
Plan
getLatestResultsSummary in interface Planpublic BuildResultsSummary getFirstBuildSummary()
Buildable
getFirstBuildSummary in interface Buildablepublic long getNumberOfBuildSummaries()
public XmppMessageSender getXmppMessageSender()
BuildDefinition
getXmppMessageSender in interface BuildDefinitionpublic void setXmppMessageSender(XmppMessageSender xmppMessageSender)
BuildDefinition
setXmppMessageSender in interface BuildDefinitionpublic java.util.Collection getBuildLog()
public java.lang.String addBuildLogEntry(java.lang.String entryDescription)
entryDescription - The entry to addpublic java.lang.String addBuildLogEntry(LogEntry logEntry)
public boolean isMarkedForManualBuild()
public boolean isMarkedForEditBuild()
public void markAsNeedingBuilding(ReasonForBuild reasonForBuild)
public void unmarkBuild()
public ErrorCollection validateBuild()
Plan
validateBuild in interface PlanErrorCollection with relevent error messagespublic java.util.List getFieldValueItems()
public java.io.File getSourceCodeDirectory()
throws RepositoryException
PlanRepository
getSourceCodeDirectory in interface PlanRepositoryExceptionpublic long getAverageBuildDuration()
Plan
getAverageBuildDuration in interface Plan@Nullable public BuildResults getPreviousBuildResults(int buildNumber)
BuildableBuildResultsImpl before the passed number
getPreviousBuildResults in interface BuildableBuildResultsImpl. null if no build results can be found before that
number@Nullable public BuildResults getNextBuildResults(int buildNumber)
getNextBuildResults in interface Buildablepublic void markForDeletion()
public void unMarkForDeletion()
public boolean isMarkedForDeletion()
isMarkedForDeletion in interface Deletablepublic void setMarkedForDeletion(boolean markedForDeletion)
setMarkedForDeletion in interface Deletablepublic void setSuspendedFromBuilding(boolean suspendFromBuilding)
Plan
setSuspendedFromBuilding in interface Planpublic boolean isSuspendedFromBuilding()
Plan
isSuspendedFromBuilding in interface Planpublic void clearBuildLog()
public boolean equals(java.lang.Object o)
equals in class java.lang.Objecto - object we are comparing
public int hashCode()
hashCode in class java.lang.Objectpublic BuilderManager getBuilderManager()
public void setBuilderManager(BuilderManager builderManager)
public BuildResultsSummaryManager getBuildResultsSummaryManager()
public void setBuildResultsSummaryManager(BuildResultsSummaryManager buildResultsSummaryManager)
public NotificationSet getNotificationSet()
getNotificationSet in interface TopLevelPlanpublic void setNotificationSet(NotificationSet notificationSet)
setNotificationSet in interface TopLevelPlan@NotNull public RequirementSet getRequirementSet()
getRequirementSet in interface Buildablepublic void setRequirementSet(RequirementSet requirementSet)
setRequirementSet in interface Buildablepublic boolean isBusy()
PlanPlan busy
isBusy in interface Planpublic void removeBuildResultSummary(int buildNumber)
Buildable
removeBuildResultSummary in interface Buildablepublic java.util.Map getConfigObjects()
BuildDefinition
getConfigObjects in interface BuildDefinitionMap with a String as a key and an arbritary objects as the value.public void setConfigObjects(java.util.Map configObjects)
setConfigObjects in interface BuildDefinitionpublic WebRepositoryViewer getWebRepositoryViewer()
getWebRepositoryViewer in interface BuildDefinition
public void setWebRepositoryViewer(@Nullable
WebRepositoryViewer webRepositoryViewer)
setWebRepositoryViewer in interface BuildDefinitionwebRepositoryViewer - the class responsible for rendering the commits for a build result@NotNull public java.util.List<TestClass> getTestClasses()
@NotNull public java.lang.String getType()
getType in interface Planpublic boolean hasTests()
Plan
hasTests in interface Plan
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||