Class AbstractArchiveFileReport
- java.lang.Object
-
- de.tracetronic.jenkins.plugins.ecutest.report.AbstractRequestHandler
-
- de.tracetronic.jenkins.plugins.ecutest.report.AbstractTestReport
-
- de.tracetronic.jenkins.plugins.ecutest.report.AbstractArchiveFileReport
-
- All Implemented Interfaces:
ModelObject
- Direct Known Subclasses:
ATXZipReport
,ETLogReport
,GeneratorReport
,TraceAnalysisReport
,TRFReport
public abstract class AbstractArchiveFileReport extends AbstractTestReport
Common base class forTRFReport
andETLogReport
holding the archive file information. The build that holds the artifact is resolved byStaplerRequest.findAncestorObject(Class)
at runtime.
-
-
Constructor Summary
Constructors Constructor Description AbstractArchiveFileReport(String id, String title, String fileName, long fileSize)
Instantiates a newAbstractArchiveFileReport
.
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description void
doDynamic(org.kohsuke.stapler.StaplerRequest req, org.kohsuke.stapler.StaplerResponse rsp)
Send contents of the archive file that is requested via HTTP.abstract String
getArchiveDir()
Gets the archive directory containing the stored files.protected VirtualFile
getArchiveTargetDir(File rootDir)
Gets the archive target directory for use inAbstractRequestHandler.doZipDownload(org.kohsuke.stapler.StaplerRequest, org.kohsuke.stapler.StaplerResponse)
.String
getFileName()
long
getFileSize()
-
Methods inherited from class de.tracetronic.jenkins.plugins.ecutest.report.AbstractTestReport
addSubReport, addSubReports, getBuild, getDisplayName, getId, getSubReports, getTitle, getUrl
-
Methods inherited from class de.tracetronic.jenkins.plugins.ecutest.report.AbstractRequestHandler
doZipDownload, getAnchestorBuild, getAnchestorProject, getBuildAction, getOwner
-
-
-
-
Constructor Detail
-
AbstractArchiveFileReport
public AbstractArchiveFileReport(String id, String title, String fileName, long fileSize)
Instantiates a newAbstractArchiveFileReport
.- Parameters:
id
- the id used in the report URLtitle
- the report titlefileName
- the log file namefileSize
- the log file size
-
-
Method Detail
-
getFileName
public String getFileName()
-
getFileSize
public long getFileSize()
-
getArchiveDir
public abstract String getArchiveDir()
Gets the archive directory containing the stored files.- Returns:
- the archive directory
-
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
-
doDynamic
public void doDynamic(org.kohsuke.stapler.StaplerRequest req, org.kohsuke.stapler.StaplerResponse rsp) throws IOException, javax.servlet.ServletException
Send contents of the archive file that is requested via HTTP.- Parameters:
req
- theStaplerRequest
used for access this reportrsp
- theStaplerResponse
used for serving the file- Throws:
IOException
- signals that an I/O exception has occurredjavax.servlet.ServletException
- if serving the file failed
-
-