hudson.plugins.dry.util
Interface ResultAction<T>

Type Parameters:
T - type of the result
All Superinterfaces:
hudson.model.Action, hudson.model.ModelObject
All Known Implementing Classes:
AbstractResultAction, DryResultAction, MavenDryResultAction

public interface ResultAction<T>
extends hudson.model.Action

Defines an action that is responsible for handling results of the given type T.

Author:
Ulli Hafner

Method Summary
 void doGraph(org.kohsuke.stapler.StaplerRequest request, org.kohsuke.stapler.StaplerResponse response, int height)
          Generates a PNG image showing the trend graph for this result action.
 void doGraphMap(org.kohsuke.stapler.StaplerRequest request, org.kohsuke.stapler.StaplerResponse response, int height)
          Generates a clickable map for the trend graph of this result action.
 HealthReportBuilder getHealthReportBuilder()
          Returns the associated health report builder.
 ResultAction<T> getPreviousResultAction()
          Returns the result action from the previous build.
 T getResult()
          Returns the current result of this action.
 boolean hasPreviousResultAction()
          Returns whether a previous build already has a result action of this type attached.
 void setResult(T result)
          Sets the result for this build.
 
Methods inherited from interface hudson.model.Action
getDisplayName, getIconFileName, getUrlName
 

Method Detail

getResult

T getResult()
Returns the current result of this action.

Returns:
the current result

setResult

void setResult(T result)
Sets the result for this build.

Parameters:
result - the result to set

hasPreviousResultAction

boolean hasPreviousResultAction()
Returns whether a previous build already has a result action of this type attached.

Returns:
true a previous build already has a result action of this type attached

getPreviousResultAction

ResultAction<T> getPreviousResultAction()
Returns the result action from the previous build.

Returns:
the result of the previous build.
Throws:
java.util.NoSuchElementException - if there is no previous result action is found

doGraph

void doGraph(org.kohsuke.stapler.StaplerRequest request,
             org.kohsuke.stapler.StaplerResponse response,
             int height)
             throws java.io.IOException
Generates a PNG image showing the trend graph for this result action.

Parameters:
request - Stapler request
response - Stapler response
height - the height of the trend graph
Throws:
java.io.IOException - in case of an error

doGraphMap

void doGraphMap(org.kohsuke.stapler.StaplerRequest request,
                org.kohsuke.stapler.StaplerResponse response,
                int height)
                throws java.io.IOException
Generates a clickable map for the trend graph of this result action.

Parameters:
request - Stapler request
response - Stapler response
height - the height of the trend graph
Throws:
java.io.IOException - in case of an error

getHealthReportBuilder

HealthReportBuilder getHealthReportBuilder()
Returns the associated health report builder.

Returns:
the associated health report builder


Copyright © 2009. All Rights Reserved.