Class BuildFlowAction
- java.lang.Object
-
- com.axis.system.jenkins.plugins.downstream.yabv.BuildFlowAction
-
- All Implemented Interfaces:
Action,ModelObject
@ExportedBean public class BuildFlowAction extends Object implements Action
Produces Transient Actions for visualizing the flow of downstream builds.- Author:
- Gustaf Lundh (C) Axis 2018
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classBuildFlowAction.BuildActionFactorystatic classBuildFlowAction.ProjectActionFactory
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description MatrixbuildMatrix()voiddoBuildFlow(org.kohsuke.stapler.StaplerRequest req, org.kohsuke.stapler.StaplerResponse rsp)List<Set<Object>>getAllItemsInFlow(int lookBack)Returns all items in the build flow, populated from the root.ApigetApi()Remote API access.BuildFlowOptionsgetBuildFlowOptions()StringgetDisplayName()StringgetIconFileName()RungetRootUpstreamBuild()RungetTarget()StringgetUrlName()static booleanhasUpstreamOrDownstreamBuilds(Run target)booleanisAnyBuildOngoing()booleanisCacheRefreshing()booleanshouldDisplayBuildFlow()
-
-
-
Method Detail
-
getRootUpstreamBuild
public Run getRootUpstreamBuild()
-
getBuildFlowOptions
public BuildFlowOptions getBuildFlowOptions()
-
isAnyBuildOngoing
@Exported(visibility=1) public boolean isAnyBuildOngoing()
-
isCacheRefreshing
@Exported(visibility=1) public boolean isCacheRefreshing()
-
shouldDisplayBuildFlow
public boolean shouldDisplayBuildFlow()
-
hasUpstreamOrDownstreamBuilds
public static boolean hasUpstreamOrDownstreamBuilds(Run target)
-
getTarget
public Run getTarget()
-
buildMatrix
public Matrix buildMatrix()
-
getAllItemsInFlow
public List<Set<Object>> getAllItemsInFlow(int lookBack)
Returns all items in the build flow, populated from the root. Which target is root depends onBuildFlowOptions.isShowUpstreamBuilds().- Parameters:
lookBack- number of historic build flows to fetch, based on the root target's previous builds.- Returns:
- A list of sets of Objects. Each set represents all items in a flow, starting from the root. The first set is calculated from the root, the next set is from the root target's previous build and so on.
-
getDisplayName
public String getDisplayName()
- Specified by:
getDisplayNamein interfaceAction- Specified by:
getDisplayNamein interfaceModelObject
-
getUrlName
public String getUrlName()
- Specified by:
getUrlNamein interfaceAction
-
getIconFileName
public String getIconFileName()
- Specified by:
getIconFileNamein interfaceAction
-
doBuildFlow
public void doBuildFlow(org.kohsuke.stapler.StaplerRequest req, org.kohsuke.stapler.StaplerResponse rsp) throws IOException, javax.servlet.ServletException- Throws:
IOExceptionjavax.servlet.ServletException
-
getApi
public Api getApi()
Remote API access.
-
-