Package hudson.plugins.copyartifact
Class DownstreamBuildSelector
java.lang.Object
hudson.model.AbstractDescribableImpl<BuildSelector>
hudson.plugins.copyartifact.BuildSelector
hudson.plugins.copyartifact.DownstreamBuildSelector
- All Implemented Interfaces:
ExtensionPoint,Describable<BuildSelector>
Select a build which is a downstream of a specified build.
-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from interface hudson.ExtensionPoint
ExtensionPoint.LegacyInstancesAreScopedToHudson -
Constructor Summary
ConstructorsConstructorDescriptionDownstreamBuildSelector(String upstreamProjectName, String upstreamBuildNumber) Constructor. -
Method Summary
Modifier and TypeMethodDescriptionRun<?,?> getBuild(Job<?, ?> job, EnvVars env, BuildFilter filter, Run<?, ?> parent) Find a build to copy artifacts from.protected booleanisSelectable(Run<?, ?> run, EnvVars env) Should this build be selected? Override just this method to use a standard loop through completed builds, starting with the most recent.Methods inherited from class hudson.plugins.copyartifact.BuildSelector
getArtifacts, getBuild, getSourceDirectory, isBuildResultBetterOrEqualToMethods inherited from class hudson.model.AbstractDescribableImpl
getDescriptor
-
Constructor Details
-
Method Details
-
getUpstreamProjectName
- Returns:
- upstream project name. May include variable expression.
-
getUpstreamBuildNumber
- Returns:
- upstream build number. May include variable expression.
-
getBuild
Description copied from class:BuildSelectorFind a build to copy artifacts from.- Overrides:
getBuildin classBuildSelector- Parameters:
job- Source projectenv- Environment for build that is copying artifactsfilter- Additional filter; returned result should return true (return null otherwise)parent- Build to which artifacts are being copied- Returns:
- Build to use, or null if no appropriate build was found
-
isSelectable
Description copied from class:BuildSelectorShould this build be selected? Override just this method to use a standard loop through completed builds, starting with the most recent.- Overrides:
isSelectablein classBuildSelector- Parameters:
run- Build to checkenv- Environment for build that is copying artifacts- Returns:
- True to select this build
-