Package com.atlassian.bamboo.ww2.beans
Class DecoratedNavObjectFactoryImpl
- java.lang.Object
-
- com.atlassian.bamboo.ww2.beans.DecoratedNavObjectFactoryImpl
-
- All Implemented Interfaces:
DecoratedNavObjectFactory
public class DecoratedNavObjectFactoryImpl extends Object implements DecoratedNavObjectFactory
-
-
Constructor Summary
Constructors Constructor Description DecoratedNavObjectFactoryImpl(CachedPlanManager cachedPlanManager, com.opensymphony.xwork2.TextProvider textProvider, CustomVariableContext customVariableContext, DeploymentProjectService deploymentProjectService, PlanExecutionManager planExecutionManager)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description @Nullable DecoratedPlandecoratePlan(@NotNull ImmutablePlan possiblyMutablePlan)Decorate plan@NotNull DecoratedResultdecorateResult(ResultsSummary summary)Gets the decorated result for the given result summary, including the full object hierarchy around it, such as parent if it is a job summary, and plan.com.google.common.collect.ImmutableList<DecoratedPlan>getDecoratedChainBranches(@NotNull DecoratedPlan master)Returns a list of branches associated with the master.com.google.common.collect.ImmutableList<DecoratedPlan.DecoratedPlanBranchGist>getDecoratedChainBranchIdentifiers(@NotNull DecoratedPlan master)Returns a list of branches associated with the master.DecoratedPlangetDecoratedPlan(ChainResultsSummary resultSummary)Gets the decorated plan for the given result summary.com.google.common.base.Function<ImmutableChainStage,DecoratedStage>getStageDecorator(@NotNull DecoratedPlan parent)Return a function that could be used to decorate stagescom.google.common.base.Function<ChainStageResult,DecoratedStage>getStageResultDecorator(@NotNull DecoratedPlan parent)@Nullable StringgetSubstitutedBranchName(@NotNull ImmutableChain chain)Gets the branch name from the default repository if the chain has one.
-
-
-
Constructor Detail
-
DecoratedNavObjectFactoryImpl
public DecoratedNavObjectFactoryImpl(CachedPlanManager cachedPlanManager, com.opensymphony.xwork2.TextProvider textProvider, CustomVariableContext customVariableContext, DeploymentProjectService deploymentProjectService, PlanExecutionManager planExecutionManager)
-
-
Method Detail
-
decoratePlan
@Nullable public @Nullable DecoratedPlan decoratePlan(@NotNull @NotNull ImmutablePlan possiblyMutablePlan)
Description copied from interface:DecoratedNavObjectFactoryDecorate plan- Specified by:
decoratePlanin interfaceDecoratedNavObjectFactory- Parameters:
possiblyMutablePlan-Planto be decorated- Returns:
DecoratedPlanobject
-
getStageDecorator
public com.google.common.base.Function<ImmutableChainStage,DecoratedStage> getStageDecorator(@NotNull @NotNull DecoratedPlan parent)
Description copied from interface:DecoratedNavObjectFactoryReturn a function that could be used to decorate stages- Specified by:
getStageDecoratorin interfaceDecoratedNavObjectFactory- Parameters:
parent-DecoratedPlanobject that was created from a chain- Returns:
- function object
-
getStageResultDecorator
public com.google.common.base.Function<ChainStageResult,DecoratedStage> getStageResultDecorator(@NotNull @NotNull DecoratedPlan parent)
- Specified by:
getStageResultDecoratorin interfaceDecoratedNavObjectFactory
-
getDecoratedChainBranches
public com.google.common.collect.ImmutableList<DecoratedPlan> getDecoratedChainBranches(@NotNull @NotNull DecoratedPlan master)
Description copied from interface:DecoratedNavObjectFactoryReturns a list of branches associated with the master.- Specified by:
getDecoratedChainBranchesin interfaceDecoratedNavObjectFactory- Returns:
- list of decorated branches for the Nav Object
-
getDecoratedChainBranchIdentifiers
public com.google.common.collect.ImmutableList<DecoratedPlan.DecoratedPlanBranchGist> getDecoratedChainBranchIdentifiers(@NotNull @NotNull DecoratedPlan master)
Description copied from interface:DecoratedNavObjectFactoryReturns a list of branches associated with the master.- Specified by:
getDecoratedChainBranchIdentifiersin interfaceDecoratedNavObjectFactory- Returns:
- list of decorated branches for the Nav Object
-
getDecoratedPlan
public DecoratedPlan getDecoratedPlan(ChainResultsSummary resultSummary)
Description copied from interface:DecoratedNavObjectFactoryGets the decorated plan for the given result summary. If possible will look to the plan cache for the plan.- Specified by:
getDecoratedPlanin interfaceDecoratedNavObjectFactory- Parameters:
resultSummary- a chain result summary.- Returns:
- Decorated Plan for the given result summary's plan
-
getSubstitutedBranchName
@Nullable public @Nullable String getSubstitutedBranchName(@NotNull @NotNull ImmutableChain chain)
Description copied from interface:DecoratedNavObjectFactoryGets the branch name from the default repository if the chain has one. Will perform variable substitution on the branch name- Specified by:
getSubstitutedBranchNamein interfaceDecoratedNavObjectFactory- Returns:
- Branch name of the default repository after substitution, if one exists.
-
decorateResult
@NotNull public @NotNull DecoratedResult decorateResult(ResultsSummary summary)
Description copied from interface:DecoratedNavObjectFactoryGets the decorated result for the given result summary, including the full object hierarchy around it, such as parent if it is a job summary, and plan.- Specified by:
decorateResultin interfaceDecoratedNavObjectFactory
-
-