hudson.plugins.tasks
Class TasksResult

java.lang.Object
  extended by hudson.plugins.analysis.core.BuildResult
      extended by hudson.plugins.tasks.TasksResult
All Implemented Interfaces:
hudson.model.ModelObject, hudson.plugins.analysis.util.model.AnnotationProvider, java.io.Serializable
Direct Known Subclasses:
TasksMavenResult

public class TasksResult
extends hudson.plugins.analysis.core.BuildResult

Represents the results of the task scanner. One instance of this class is persisted for each build via an XML file.

Author:
Ulli Hafner
See Also:
Serialized Form

Field Summary
 
Fields inherited from class hudson.plugins.analysis.core.BuildResult
high, low, normal
 
Constructor Summary
TasksResult(hudson.model.AbstractBuild<?,?> build, java.lang.String defaultEncoding, TasksParserResult result, java.lang.String highTags, java.lang.String normalTags, java.lang.String lowTags)
          Creates a new instance of TasksResult.
 
Method Summary
protected  void configure(com.thoughtworks.xstream.XStream xstream)
          
protected  java.lang.String createDeltaMessage()
          
 java.lang.String getDisplayName()
          Returns the display name (bread crumb name) of this result.
 java.lang.Object getDynamic(java.lang.String link, org.kohsuke.stapler.StaplerRequest request, org.kohsuke.stapler.StaplerResponse response)
          Returns the dynamic result of this tasks detail view.
 int getNumberOfFiles()
          Returns the number of scanned files in this project.
 java.lang.String getPackageCategoryName()
          Returns the package category name for the scanned files.
 hudson.plugins.analysis.util.model.Priority[] getPriorities()
          Returns the actually used priorities.
protected  java.lang.Class<? extends hudson.plugins.analysis.core.ResultAction<? extends hudson.plugins.analysis.core.BuildResult>> getResultActionType()
          
protected  java.lang.String getSerializationFileName()
          
 java.lang.String getSummary()
          Returns a summary message for the summary.jelly file.
 java.lang.String getTags(hudson.plugins.analysis.util.model.Priority priority)
          Returns the tags for the specified priority.
 
Methods inherited from class hudson.plugins.analysis.core.BuildResult
createHighScoreMessage, createListItem, createNoWarningsMessage, createSuccessfulHighScoreMessage, getAnnotation, getAnnotation, getAnnotations, getAnnotations, getAnnotations, getApi, getContainer, getDataFile, getDays, getDefaultEncoding, getDelta, getDetails, getErrors, getFixedWarnings, getHighDelta, getHighScoreGap, getLowDelta, getModules, getNewWarnings, getNormalDelta, getNumberOfAnnotations, getNumberOfAnnotations, getNumberOfAnnotations, getNumberOfFixedWarnings, getNumberOfModules, getNumberOfNewWarnings, getNumberOfWarnings, getOwner, getPreviousResult, getProject, getResultIcon, getSuccessfulHighScore, getSuccessfulHighScoreGap, getSuccessfulSinceBuild, getSuccessfulSinceDate, getWarningsDelta, getZeroWarningsHighScore, getZeroWarningsSinceBuild, getZeroWarningsSinceDate, hasAnnotations, hasAnnotations, hasAnnotations, hasError, hasNoAnnotations, hasNoAnnotations, hasNoAnnotations, hasPreviousResult, isCurrent, isNewSuccessfulHighScore, isNewZeroWarningsHighScore, isSuccessful, isSuccessfulTouched, readResolve, setHighWarnings, setLowWarnings, setNormalWarnings, setResult, setWarnings, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

TasksResult

public TasksResult(hudson.model.AbstractBuild<?,?> build,
                   java.lang.String defaultEncoding,
                   TasksParserResult result,
                   java.lang.String highTags,
                   java.lang.String normalTags,
                   java.lang.String lowTags)
Creates a new instance of TasksResult.

Parameters:
build - the current build as owner of this action
defaultEncoding - the default encoding to be used when reading and parsing files
result - the parsed annotations
highTags - tag identifiers indicating high priority
normalTags - tag identifiers indicating normal priority
lowTags - tag identifiers indicating low priority
Method Detail

configure

protected void configure(com.thoughtworks.xstream.XStream xstream)

Overrides:
configure in class hudson.plugins.analysis.core.BuildResult

getSummary

public java.lang.String getSummary()
Returns a summary message for the summary.jelly file.

Returns:
the summary message

createDeltaMessage

protected java.lang.String createDeltaMessage()

Overrides:
createDeltaMessage in class hudson.plugins.analysis.core.BuildResult

getNumberOfFiles

public int getNumberOfFiles()
Returns the number of scanned files in this project.

Returns:
the number of scanned files in this project

getDisplayName

public java.lang.String getDisplayName()
Returns the display name (bread crumb name) of this result.

Returns:
the display name of this result.

getSerializationFileName

protected java.lang.String getSerializationFileName()

Specified by:
getSerializationFileName in class hudson.plugins.analysis.core.BuildResult

getDynamic

public java.lang.Object getDynamic(java.lang.String link,
                                   org.kohsuke.stapler.StaplerRequest request,
                                   org.kohsuke.stapler.StaplerResponse response)
Returns the dynamic result of this tasks detail view. Depending on the number of modules and packages, one of the following detail objects is returned:

Overrides:
getDynamic in class hudson.plugins.analysis.core.BuildResult
Parameters:
link - the link to the source code
request - Stapler request
response - Stapler response
Returns:
the dynamic result of the FindBugs analysis (detail page for a package).

getPriorities

public hudson.plugins.analysis.util.model.Priority[] getPriorities()
Returns the actually used priorities.

Overrides:
getPriorities in class hudson.plugins.analysis.core.BuildResult
Returns:
the actually used priorities.

getTags

public final java.lang.String getTags(hudson.plugins.analysis.util.model.Priority priority)
Returns the tags for the specified priority.

Parameters:
priority - the priority
Returns:
the tags for the specified priority

getPackageCategoryName

public java.lang.String getPackageCategoryName()
Returns the package category name for the scanned files. Currently, only java and c# files are supported.

Returns:
the package category name for the scanned files

getResultActionType

protected java.lang.Class<? extends hudson.plugins.analysis.core.ResultAction<? extends hudson.plugins.analysis.core.BuildResult>> getResultActionType()

Specified by:
getResultActionType in class hudson.plugins.analysis.core.BuildResult


Copyright © 2004-2011. All Rights Reserved.