com.atlassian.bamboo.v2.build
Class BuildContextImpl

java.lang.Object
  extended by com.atlassian.bamboo.v2.build.BuildIdentifierImpl
      extended by com.atlassian.bamboo.v2.build.BuildContextImpl
All Implemented Interfaces:
BuildContext, BuildIdentifier, java.io.Serializable

public class BuildContextImpl
extends BuildIdentifierImpl
implements BuildContext

See Also:
Serialized Form

Constructor Summary
BuildContextImpl(Plan buildPlan, int buildNumber, TriggerReason triggerReason, BuildDefinition buildDefinition, BuildChanges buildChanges)
           
BuildContextImpl(Plan buildPlan, int buildNumber, TriggerReason triggerReason, BuildDefinition buildDefinition, BuildChanges buildChanges, BuildContext parentBuildContext)
           
 
Method Summary
 BuildChanges getBuildChanges()
          Returns the build changes, if any, that represents the changes that triggered this build.
 BuildDefinition getBuildDefinition()
           
 BuildPlanDefinition getBuildPlanDefinition()
           
 CurrentBuildResult getBuildResult()
          The information about the results of a build
 ErrorCollection getErrorCollection()
          Any errors associated with the build
 BuildContext getParentBuildContext()
           
 BuildIdentifier getParentBuildIdentifier()
           
 TriggerReason getTriggerReason()
          The reason this build was triggered
 
Methods inherited from class com.atlassian.bamboo.v2.build.BuildIdentifierImpl
equals, getBuildNumber, getBuildResultKey, getPlanId, getPlanKey, getPlanName, getPlanResultKey, getShortName, hashCode
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.atlassian.bamboo.v2.build.BuildIdentifier
getBuildNumber, getBuildResultKey, getPlanId, getPlanKey, getPlanName, getPlanResultKey, getShortName
 

Constructor Detail

BuildContextImpl

public BuildContextImpl(Plan buildPlan,
                        int buildNumber,
                        TriggerReason triggerReason,
                        BuildDefinition buildDefinition,
                        BuildChanges buildChanges,
                        BuildContext parentBuildContext)

BuildContextImpl

public BuildContextImpl(Plan buildPlan,
                        int buildNumber,
                        TriggerReason triggerReason,
                        BuildDefinition buildDefinition,
                        BuildChanges buildChanges)
Method Detail

getParentBuildIdentifier

public BuildIdentifier getParentBuildIdentifier()
Specified by:
getParentBuildIdentifier in interface BuildIdentifier
Overrides:
getParentBuildIdentifier in class BuildIdentifierImpl
Returns:
the BuildContext of the parent Plan execution. Should return null if the current BuildContext is for a TopLevelPlan

getParentBuildContext

public BuildContext getParentBuildContext()
Specified by:
getParentBuildContext in interface BuildContext
Returns:
the BuildContext of the parent Plan execution. Should return null if the current BuildContext is for a TopLevelPlan

getTriggerReason

@NotNull
public TriggerReason getTriggerReason()
Description copied from interface: BuildContext
The reason this build was triggered

Specified by:
getTriggerReason in interface BuildContext
Returns:
triggerReason

getBuildPlanDefinition

@NotNull
public BuildPlanDefinition getBuildPlanDefinition()
Specified by:
getBuildPlanDefinition in interface BuildContext
Returns:
buildPlanDefinition

getBuildDefinition

@NotNull
public BuildDefinition getBuildDefinition()
Specified by:
getBuildDefinition in interface BuildContext
Returns:
BuildDefinition associated with Plan this context relates to

getBuildChanges

@NotNull
public BuildChanges getBuildChanges()
Description copied from interface: BuildContext
Returns the build changes, if any, that represents the changes that triggered this build.

Specified by:
getBuildChanges in interface BuildContext
Returns:
Never null. WIll return a build changes object with the approriate list of changes, the list will be null if no changes were found.

getBuildResult

@NotNull
public CurrentBuildResult getBuildResult()
Description copied from interface: BuildContext
The information about the results of a build

Specified by:
getBuildResult in interface BuildContext
Returns:
CurrentBuildResult

getErrorCollection

@NotNull
public ErrorCollection getErrorCollection()
Description copied from interface: BuildContext
Any errors associated with the build

Specified by:
getErrorCollection in interface BuildContext


Copyright © 2010 Atlassian. All Rights Reserved.