hudson.plugins.tasks
Class ModuleDetail

java.lang.Object
  extended by hudson.plugins.tasks.util.model.AnnotationContainer
      extended by hudson.plugins.tasks.AbstractTasksResult
          extended by hudson.plugins.tasks.ModuleDetail
All Implemented Interfaces:
hudson.model.ModelObject, AnnotationProvider, java.io.Serializable

public class ModuleDetail
extends AbstractTasksResult

Represents the details of a maven module.

See Also:
Serialized Form

Constructor Summary
ModuleDetail(hudson.model.AbstractBuild<?,?> owner, MavenModule module, java.lang.String high, java.lang.String normal, java.lang.String low)
          Creates a new instance of ModuleDetail.
 
Method Summary
 void doPackageStatistics(org.kohsuke.stapler.StaplerRequest request, org.kohsuke.stapler.StaplerResponse response)
          Generates a PNG image for high/normal/low distribution of a java package.
 java.lang.String getDisplayName()
          
 java.lang.Object getDynamic(java.lang.String link, org.kohsuke.stapler.StaplerRequest request, org.kohsuke.stapler.StaplerResponse response)
          Returns the dynamic result of this module detail view, which is either a task detail object for a single workspace file or a package detail object.
 java.util.Collection<WorkspaceFile> getFiles()
          Gets the files of this module that have open tasks.
 java.util.Collection<JavaPackage> getPackages()
          Gets the packages of this module that have open tasks.
 java.lang.String getToolTip(java.lang.String packageName)
          Returns a tooltip showing the distribution of priorities for the selected package.
 boolean isSinglePackageModule()
          Returns whether we only have a single module.
 
Methods inherited from class hudson.plugins.tasks.AbstractTasksResult
annotationAdded, createDetailGraph, getAvailablePriorities, getOwner, getPackageCategoryName, getPriorities, getTags, getTags, isCurrent
 
Methods inherited from class hudson.plugins.tasks.util.model.AnnotationContainer
addAnnotation, addAnnotations, addAnnotations, getAnnotation, getAnnotation, getAnnotations, getAnnotations, getAnnotations, getNumberOfAnnotations, getNumberOfAnnotations, getNumberOfAnnotations, getToolTip, hasAnnotations, hasAnnotations, hasAnnotations, rebuildPriorities
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ModuleDetail

public ModuleDetail(hudson.model.AbstractBuild<?,?> owner,
                    MavenModule module,
                    java.lang.String high,
                    java.lang.String normal,
                    java.lang.String low)
Creates a new instance of ModuleDetail.

Parameters:
owner - the current build as owner of this result object
high - tag identifiers indicating high priority
normal - tag identifiers indicating normal priority
low - tag identifiers indicating low priority
module - the selected module to show
Method Detail

getDisplayName

public java.lang.String getDisplayName()


getPackages

public java.util.Collection<JavaPackage> getPackages()
Gets the packages of this module that have open tasks.

Returns:
the modules

getFiles

public java.util.Collection<WorkspaceFile> getFiles()
Gets the files of this module that have open tasks.

Returns:
the files

getToolTip

public java.lang.String getToolTip(java.lang.String packageName)
Returns a tooltip showing the distribution of priorities for the selected package.

Parameters:
packageName - the package to show the distribution for
Returns:
a tooltip showing the distribution of priorities

doPackageStatistics

public final void doPackageStatistics(org.kohsuke.stapler.StaplerRequest request,
                                      org.kohsuke.stapler.StaplerResponse response)
                               throws java.io.IOException
Generates a PNG image for high/normal/low distribution of a java package.

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

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 module detail view, which is either a task detail object for a single workspace file or a package detail object.

Parameters:
link - the link containing the path to the selected workspace file (or package)
request - Stapler request
response - Stapler response
Returns:
the dynamic result of the FindBugs analysis (detail page for a package).
See Also:
isSinglePackageModule()

isSinglePackageModule

public boolean isSinglePackageModule()
Returns whether we only have a single module. In this case the module statistics are suppressed and only the package statistics are shown.

Returns:
true for single module projects


Copyright © 2008. All Rights Reserved.