hudson.tasks
Class BuildStepCompatibilityLayer

java.lang.Object
  extended by hudson.tasks.BuildStepCompatibilityLayer
All Implemented Interfaces:
BuildStep
Direct Known Subclasses:
Builder, Publisher

Deprecated. since 1.150

public abstract class BuildStepCompatibilityLayer
extends Object
implements BuildStep

Provides compatibility with BuildStep before 1.150 so that old plugin binaries can continue to function with new Hudson.

Since:
1.150
Author:
Kohsuke Kawaguchi

Nested Class Summary
 
Nested classes/interfaces inherited from interface hudson.tasks.BuildStep
BuildStep.PublisherList
 
Field Summary
 
Fields inherited from interface hudson.tasks.BuildStep
BUILDERS, PUBLISHERS
 
Constructor Summary
BuildStepCompatibilityLayer()
          Deprecated.  
 
Method Summary
 Action getProjectAction(AbstractProject<?,?> project)
          Deprecated.  
 Action getProjectAction(Project<?,?> project)
          Deprecated. Use getProjectAction(AbstractProject) instead.
 Collection<? extends Action> getProjectActions(AbstractProject<?,?> project)
          Deprecated. Returns action objects if this BuildStep has actions to contribute to a Project.
 boolean perform(AbstractBuild<?,?> build, Launcher launcher, BuildListener listener)
          Deprecated. Runs the step over the given build and reports the progress to the listener.
 boolean perform(Build<?,?> build, Launcher launcher, BuildListener listener)
          Deprecated. Use perform(AbstractBuild, Launcher, BuildListener) instead.
 boolean prebuild(AbstractBuild<?,?> build, BuildListener listener)
          Deprecated. Runs before the build begins.
 boolean prebuild(Build<?,?> build, BuildListener listener)
          Deprecated. Use prebuild(AbstractBuild, BuildListener) instead.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface hudson.tasks.BuildStep
getRequiredMonitorService
 

Constructor Detail

BuildStepCompatibilityLayer

public BuildStepCompatibilityLayer()
Deprecated. 
Method Detail

prebuild

public boolean prebuild(AbstractBuild<?,?> build,
                        BuildListener listener)
Deprecated. 
Description copied from interface: BuildStep
Runs before the build begins.

Specified by:
prebuild in interface BuildStep
Returns:
true if the build can continue, false if there was an error and the build needs to be aborted.

Using the return value to indicate success/failure should be considered deprecated, and implementations are encouraged to throw AbortException to indicate a failure.


perform

public boolean perform(AbstractBuild<?,?> build,
                       Launcher launcher,
                       BuildListener listener)
                throws InterruptedException,
                       IOException
Deprecated. 
Description copied from interface: BuildStep
Runs the step over the given build and reports the progress to the listener.

A plugin can contribute the action object to Actionable.getActions() so that a 'report' becomes a part of the persisted data of Build. This is how JUnit plugin attaches the test report to a build page, for example.

Specified by:
perform in interface BuildStep
Returns:
true if the build can continue, false if there was an error and the build needs to be aborted.

Using the return value to indicate success/failure should be considered deprecated, and implementations are encouraged to throw AbortException to indicate a failure.

Throws:
InterruptedException - If the build is interrupted by the user (in an attempt to abort the build.) Normally the BuildStep implementations may simply forward the exception it got from its lower-level functions.
IOException - If the implementation wants to abort the processing when an IOException happens, it can simply propagate the exception to the caller. This will cause the build to fail, with the default error message. Implementations are encouraged to catch IOException on its own to provide a better error message, if it can do so, so that users have better understanding on why it failed.

getProjectAction

public Action getProjectAction(AbstractProject<?,?> project)
Deprecated. 
Specified by:
getProjectAction in interface BuildStep

getProjectActions

public Collection<? extends Action> getProjectActions(AbstractProject<?,?> project)
Deprecated. 
Description copied from interface: BuildStep
Returns action objects if this BuildStep has actions to contribute to a Project.

Project calls this method for every BuildStep that it owns when the rendering is requested.

This action can have optional jobMain.jelly view, which will be aggregated into the main panel of the job top page. The jelly file should have an <h2> tag that shows the section title, followed by some block elements to render the details of the section.

Specified by:
getProjectActions in interface BuildStep
Parameters:
project - Project that owns this build step, since BuildStep object doesn't usually have this "parent" pointer.
Returns:
can be empty but never null.

prebuild

public boolean prebuild(Build<?,?> build,
                        BuildListener listener)
Deprecated. Use prebuild(AbstractBuild, BuildListener) instead.


perform

public boolean perform(Build<?,?> build,
                       Launcher launcher,
                       BuildListener listener)
                throws InterruptedException,
                       IOException
Deprecated. Use perform(AbstractBuild, Launcher, BuildListener) instead.

Throws:
InterruptedException
IOException

getProjectAction

public Action getProjectAction(Project<?,?> project)
Deprecated. Use getProjectAction(AbstractProject) instead.



Copyright © 2004-2013. All Rights Reserved.