hudson.plugins.warnings
Class WarningsResultAction

java.lang.Object
  extended by hudson.plugins.warnings.util.AbstractResultAction<WarningsResult>
      extended by hudson.plugins.warnings.WarningsResultAction
All Implemented Interfaces:
hudson.model.Action, hudson.model.HealthReportingAction, hudson.model.ModelObject, ResultAction<WarningsResult>, ToolTipProvider, org.kohsuke.stapler.StaplerProxy

public class WarningsResultAction
extends AbstractResultAction<WarningsResult>

Controls the live cycle of the warnings results. This action persists the results of the warnings analysis of a build and displays the results on the build page. The actual visualization of the results is defined in the matching summary.jelly file.

Moreover, this class renders the warnings result trend.

Author:
Ulli Hafner

Constructor Summary
WarningsResultAction(hudson.model.AbstractBuild<?,?> owner, HealthDescriptor healthDescriptor)
          Creates a new instance of WarningsResultAction.
WarningsResultAction(hudson.model.AbstractBuild<?,?> owner, HealthDescriptor healthDescriptor, WarningsResult result)
          Creates a new instance of WarningsResultAction.
 
Method Summary
protected  PluginDescriptor getDescriptor()
          Returns the descriptor of the associated plug-in.
 java.lang.String getDisplayName()
          
 java.lang.String getMultipleItemsTooltip(int numberOfItems)
          Returns the tooltip for several items.
 WarningsResultAction getPreviousResultAction()
          Gets the warnings result of the previous build.
 java.lang.String getSingleItemTooltip()
          Returns the tooltip for exactly one item.
 
Methods inherited from class hudson.plugins.warnings.util.AbstractResultAction
addModule, createAggregatedResult, createResult, getBuild, getBuildHealth, getHealthDescriptor, getIconFileName, getOwner, getPreviousBuild, getResult, getTarget, getTooltip, getToolTipProvider, getUrlName, hasPreviousResultAction, setResult, updateBuildHealth
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

WarningsResultAction

public WarningsResultAction(hudson.model.AbstractBuild<?,?> owner,
                            HealthDescriptor healthDescriptor,
                            WarningsResult result)
Creates a new instance of WarningsResultAction.

Parameters:
owner - the associated build of this action
healthDescriptor - health descriptor to use
result - the result in this build

WarningsResultAction

public WarningsResultAction(hudson.model.AbstractBuild<?,?> owner,
                            HealthDescriptor healthDescriptor)
Creates a new instance of WarningsResultAction.

Parameters:
owner - the associated build of this action
healthDescriptor - health descriptor to use
Method Detail

getDisplayName

public java.lang.String getDisplayName()


getDescriptor

protected PluginDescriptor getDescriptor()
Returns the descriptor of the associated plug-in.

Specified by:
getDescriptor in class AbstractResultAction<WarningsResult>
Returns:
the descriptor of the associated plug-in

getPreviousResultAction

public WarningsResultAction getPreviousResultAction()
Gets the warnings result of the previous build.

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

getMultipleItemsTooltip

public java.lang.String getMultipleItemsTooltip(int numberOfItems)
Returns the tooltip for several items.

Specified by:
getMultipleItemsTooltip in class AbstractResultAction<WarningsResult>
Parameters:
numberOfItems - the number of items to display the tooltip for
Returns:
the tooltip for several items

getSingleItemTooltip

public java.lang.String getSingleItemTooltip()
Returns the tooltip for exactly one item.

Specified by:
getSingleItemTooltip in class AbstractResultAction<WarningsResult>
Returns:
the tooltip for exactly one item


Copyright © 2009. All Rights Reserved.