Class AbstractReportAction
- java.lang.Object
-
- de.tracetronic.jenkins.plugins.ecutest.report.AbstractRequestHandler
-
- de.tracetronic.jenkins.plugins.ecutest.report.AbstractReportAction
-
- All Implemented Interfaces:
Action
,ModelObject
,IconSpec
- Direct Known Subclasses:
AbstractATXAction
,AbstractETLogAction
,AbstractReportGeneratorAction
,AbstractTraceAnalysisAction
,AbstractTRFAction
public abstract class AbstractReportAction extends AbstractRequestHandler implements Action, IconSpec
Common base class forAbstractATXAction
andAbstractTRFAction
.
-
-
Constructor Summary
Constructors Constructor Description AbstractReportAction(boolean projectLevel)
Instantiates a newAbstractReportAction
.
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description protected VirtualFile
getArchiveTargetDir(File rootDir)
Gets the archive target directory for use inAbstractRequestHandler.doZipDownload(org.kohsuke.stapler.StaplerRequest, org.kohsuke.stapler.StaplerResponse)
.Run<?,?>
getBuild(org.kohsuke.stapler.StaplerRequest req)
Gets the build that have report artifacts this action handles.String
getIconFileName()
protected abstract Run<?,?>
getLastReportBuild(Job<?,?> project)
Gets the last build with report artifacts in a project.boolean
isProjectLevel()
Returns whether archiving is restricted to project level only.-
Methods inherited from class de.tracetronic.jenkins.plugins.ecutest.report.AbstractRequestHandler
doZipDownload, getAnchestorBuild, getAnchestorProject, getBuildAction, getOwner
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface hudson.model.Action
getDisplayName, getUrlName
-
Methods inherited from interface org.jenkins.ui.icon.IconSpec
getIconClassName
-
-
-
-
Constructor Detail
-
AbstractReportAction
public AbstractReportAction(boolean projectLevel)
Instantiates a newAbstractReportAction
.- Parameters:
projectLevel
- specifies whether archiving is restricted to project level only
-
-
Method Detail
-
isProjectLevel
public boolean isProjectLevel()
Returns whether archiving is restricted to project level only.- Returns:
true
if archiving is restricted to project level,false
otherwise
-
getBuild
public Run<?,?> getBuild(org.kohsuke.stapler.StaplerRequest req)
Description copied from class:AbstractRequestHandler
Gets the build that have report artifacts this action handles.If called in a project context, returns the last build that contains report artifacts.
- Specified by:
getBuild
in classAbstractRequestHandler
- Parameters:
req
- theStaplerRequest
used for access this action- Returns:
- the build with report artifacts to handle or
null
if no proper build exists
-
getArchiveTargetDir
protected VirtualFile getArchiveTargetDir(File rootDir)
Description copied from class:AbstractRequestHandler
Gets the archive target directory for use inAbstractRequestHandler.doZipDownload(org.kohsuke.stapler.StaplerRequest, org.kohsuke.stapler.StaplerResponse)
.- Specified by:
getArchiveTargetDir
in classAbstractRequestHandler
- Parameters:
rootDir
- the root directory- Returns:
- the archive target directory
-
getLastReportBuild
@CheckForNull protected abstract Run<?,?> getLastReportBuild(Job<?,?> project)
Gets the last build with report artifacts in a project.- Parameters:
project
- the project- Returns:
- the last build with report artifacts or
null
if no proper build exists
-
getIconFileName
public String getIconFileName()
- Specified by:
getIconFileName
in interfaceAction
-
-