T - type of the resultspublic abstract class BuildAction<T> extends Object implements jenkins.tasks.SimpleBuildStep.LastBuildAction, jenkins.model.RunAction2, Serializable
summary.jelly file.
This action also provides access to the detail views: these are rendered using a new view instance.| Constructor and Description |
|---|
BuildAction(hudson.model.Run<?,?> owner,
T result)
Creates a new instance of
BuildAction. |
BuildAction(hudson.model.Run<?,?> owner,
T result,
boolean canSerialize)
Creates a new instance of
BuildAction. |
| Modifier and Type | Method and Description |
|---|---|
protected abstract JobAction<? extends BuildAction<T>> |
createProjectAction() |
protected abstract AbstractXmlStream<T> |
createXmlStream() |
static <T extends BuildAction<?>> |
getBuildActionFromHistoryStartingFrom(hudson.model.Run<?,?> baseline,
Class<T> buildActionClass)
Returns a
BuildAction of the specified baseline build. |
protected abstract String |
getBuildResultBaseName() |
hudson.model.Run<?,?> |
getOwner() |
Collection<? extends hudson.model.Action> |
getProjectActions() |
T |
getResult()
Returns the repository statistics.
|
void |
onAttached(hudson.model.Run<?,?> r) |
void |
onLoad(hudson.model.Run<?,?> r) |
protected Object |
readResolve()
Called after de-serialization to improve the memory usage.
|
public BuildAction(hudson.model.Run<?,?> owner,
T result)
BuildAction.owner - the associated build that created the resultresult - the result to persist with this actionpublic BuildAction(hudson.model.Run<?,?> owner,
T result,
boolean canSerialize)
BuildAction.owner - the associated build that created the resultresult - the result to persist with this actioncanSerialize - determines whether the result should be persisted in the build folderprotected abstract AbstractXmlStream<T> createXmlStream()
public hudson.model.Run<?,?> getOwner()
public void onAttached(hudson.model.Run<?,?> r)
onAttached in interface jenkins.model.RunAction2public void onLoad(hudson.model.Run<?,?> r)
onLoad in interface jenkins.model.RunAction2protected Object readResolve()
public Collection<? extends hudson.model.Action> getProjectActions()
getProjectActions in interface jenkins.tasks.SimpleBuildStep.LastBuildActionprotected abstract JobAction<? extends BuildAction<T>> createProjectAction()
public T getResult()
WeakReference. So if the current instance has been destroyed by the garbage collector then a new instance will
be automatically created by reading the persisted XML data from Jenkins build folder.protected abstract String getBuildResultBaseName()
public static <T extends BuildAction<?>> Optional<T> getBuildActionFromHistoryStartingFrom(@Nullable hudson.model.Run<?,?> baseline, Class<T> buildActionClass)
BuildAction of the specified baseline build. If there is no such action for the baseline then
the previous build is inspected, and so on. If no previous build contains a BuildAction then an empty
result is returned.T - type of the resultsbaseline - the baseline to start the search withbuildActionClass - the type of the action to findBuildAction, or an empty result if there is no such actionCopyright © 2016–2019. All rights reserved.