public class TriggeringRunSelector extends RunSelector
Modifier and Type | Class and Description |
---|---|
static class |
TriggeringRunSelector.DescriptorImpl
the descriptor for
TriggeringRunSelector |
static class |
TriggeringRunSelector.UpstreamFilterStrategy
Which build should be used if triggered by multiple upstream builds.
|
Constructor and Description |
---|
TriggeringRunSelector() |
Modifier and Type | Method and Description |
---|---|
hudson.model.Run<?,?> |
getNextBuild(hudson.model.Job<?,?> job,
RunSelectorContext context)
Override this method to implement
RunSelector . |
TriggeringRunSelector.UpstreamFilterStrategy |
getUpstreamFilterStrategy() |
boolean |
isAllowUpstreamDependencies() |
boolean |
isUseNewest() |
void |
setAllowUpstreamDependencies(boolean allowUpstreamDependencies) |
void |
setUpstreamFilterStrategy(TriggeringRunSelector.UpstreamFilterStrategy upstreamFilterStrategy) |
getDisplayName, select
@DataBoundSetter public void setUpstreamFilterStrategy(TriggeringRunSelector.UpstreamFilterStrategy upstreamFilterStrategy)
upstreamFilterStrategy
- which build should be used if triggered by multiple upstream builds.@DataBoundSetter public void setAllowUpstreamDependencies(boolean allowUpstreamDependencies)
allowUpstreamDependencies
- whether to include upstream dependencies.@CheckForNull public TriggeringRunSelector.UpstreamFilterStrategy getUpstreamFilterStrategy()
public boolean isUseNewest()
public boolean isAllowUpstreamDependencies()
@CheckForNull public hudson.model.Run<?,?> getNextBuild(@Nonnull hudson.model.Job<?,?> job, @Nonnull RunSelectorContext context)
RunSelector
.
Use RunSelectorContext.getLastMatchBuild()
to
continue enumerating builds.
Or you can save the execution state
with RunSelectorContext.addExtension(Object)
getNextBuild
in class RunSelector
job
- the job to pick a build from.context
- context for the current execution of runselector.Copyright © 2016–2020. All rights reserved.