org.apache.uima.test.junit_extension
Class PerformanceTestResultImpl

java.lang.Object
  extended by org.apache.uima.test.junit_extension.PerformanceTestResultImpl
All Implemented Interfaces:
PerformanceTestResult

public class PerformanceTestResultImpl
extends java.lang.Object
implements PerformanceTestResult

PerformanceTestResultImpl implements the PerformanceTestResult interface and provides the results of a performance test run.


Constructor Summary
PerformanceTestResultImpl()
           
 
Method Summary
 TimeSpan getAeCleanupTime()
           
 java.lang.String getAeDescFilePath()
           
 TimeSpan getAeInitTime()
           
 TimeSpan getAeProcessingTime()
           
 TimeSpan getAeWarmupTime()
           
 TimeSpan getDocumentPreparationTime()
           
 TimeSpan getFileIoTime()
           
 int getNumberOfCreatedAnnotations()
           
 int getNumberOfProcessedCharacters()
           
 int getNumberOfProcessedFiles()
           
 int getNumberOfRepeatedRuns()
           
 TimeSpan getOverallTime()
           
 long getProcessedFileSize()
           
 java.lang.String getTestFileDirectoryPath()
           
 java.lang.String getUIMADatapath()
           
 boolean isDoAeWarmup()
           
 boolean isRepeatSingleMode()
           
 void setAeDescFilePath(java.io.File aeDescFile)
           
 void setCleanupTime(TimeSpan cleanupTime)
           
 void setDatapath(java.lang.String datapath)
           
 void setDocumentPreparationTime(TimeSpan documentPreparationTime)
           
 void setDoWarmup(boolean doWarmup)
           
 void setInitTime(TimeSpan initTime)
           
 void setIoTime(TimeSpan ioTime)
           
 void setNumberOfCharacters(int numberOfCharacters)
           
 void setNumberOfCreatedAnnotations(int numberOfCreatedAnnotations)
           
 void setNumberOfFiles(int numberOfFiles)
           
 void setNumsToRun(int numsToRun)
           
 void setOverallTime(TimeSpan overallTime)
           
 void setProcessingTime(TimeSpan processingTime)
           
 void setRepeatSingleMode(boolean repeatSingleMode)
           
 void setTestFileDir(java.io.File testFileDir)
           
 void setTotalFileSize(long collectionFileSize)
           
 void setWarmupTime(TimeSpan warmupTime)
           
 java.lang.String toString()
          returns a performance report with the current performance results.
 void writePerfResultsAsColumn(java.lang.String level, java.io.File file)
          write performance results as colum.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

PerformanceTestResultImpl

public PerformanceTestResultImpl()
Method Detail

getNumberOfProcessedCharacters

public int getNumberOfProcessedCharacters()
Specified by:
getNumberOfProcessedCharacters in interface PerformanceTestResult
Returns:
Returns the number of processed characters.

setNumberOfCharacters

public void setNumberOfCharacters(int numberOfCharacters)
Parameters:
numberOfCharacters - The number of characters.

getNumberOfProcessedFiles

public int getNumberOfProcessedFiles()
Specified by:
getNumberOfProcessedFiles in interface PerformanceTestResult
Returns:
Returns the number of processed files.

setNumberOfFiles

public void setNumberOfFiles(int numberOfFiles)
Parameters:
numberOfFiles - The number of files.

getUIMADatapath

public java.lang.String getUIMADatapath()
Specified by:
getUIMADatapath in interface PerformanceTestResult
Returns:
Returns the UIMA datapath setting used for the performance test.

setDatapath

public void setDatapath(java.lang.String datapath)
Parameters:
datapath - The UIMA datapath.

getAeInitTime

public TimeSpan getAeInitTime()
Specified by:
getAeInitTime in interface PerformanceTestResult
Returns:
Returns the analysis engine initialization time.

setInitTime

public void setInitTime(TimeSpan initTime)
Parameters:
initTime - The analysis engine init time.

getFileIoTime

public TimeSpan getFileIoTime()
Specified by:
getFileIoTime in interface PerformanceTestResult
Returns:
Returns the file I/O time.

setIoTime

public void setIoTime(TimeSpan ioTime)
Parameters:
ioTime - The file io time to set.

getNumberOfCreatedAnnotations

public int getNumberOfCreatedAnnotations()
Specified by:
getNumberOfCreatedAnnotations in interface PerformanceTestResult
Returns:
Returns the number of created annotations.

setNumberOfCreatedAnnotations

public void setNumberOfCreatedAnnotations(int numberOfCreatedAnnotations)
Parameters:
numberOfCreatedAnnotations - The number of created annotations to set.

getNumberOfRepeatedRuns

public int getNumberOfRepeatedRuns()
Specified by:
getNumberOfRepeatedRuns in interface PerformanceTestResult
Returns:
Returns the setting for the number of repeated runs.

setNumsToRun

public void setNumsToRun(int numsToRun)
Parameters:
numsToRun - The number of repeated runs.

getOverallTime

public TimeSpan getOverallTime()
Specified by:
getOverallTime in interface PerformanceTestResult
Returns:
Returns the overall time of the performance run

setOverallTime

public void setOverallTime(TimeSpan overallTime)
Parameters:
overallTime - The overall processing time.

getAeProcessingTime

public TimeSpan getAeProcessingTime()
Specified by:
getAeProcessingTime in interface PerformanceTestResult
Returns:
Returns the analysis engine processing time.

setProcessingTime

public void setProcessingTime(TimeSpan processingTime)
Parameters:
processingTime - The analysis engine processing time.

isRepeatSingleMode

public boolean isRepeatSingleMode()
Specified by:
isRepeatSingleMode in interface PerformanceTestResult
Returns:
Returns the setting of the repeat mode mode.

setRepeatSingleMode

public void setRepeatSingleMode(boolean repeatSingleMode)
Parameters:
repeatSingleMode - The repeat single mode setting

getAeDescFilePath

public java.lang.String getAeDescFilePath()
Specified by:
getAeDescFilePath in interface PerformanceTestResult
Returns:
Returns the analysis engine descriptor file path.

setAeDescFilePath

public void setAeDescFilePath(java.io.File aeDescFile)
Parameters:
aeDescFile - The analysis engine descriptor file.

getTestFileDirectoryPath

public java.lang.String getTestFileDirectoryPath()
Specified by:
getTestFileDirectoryPath in interface PerformanceTestResult
Returns:
Returns the test file directory used for the performance run.

setTestFileDir

public void setTestFileDir(java.io.File testFileDir)
Parameters:
testFileDir - The test file directory.

getAeWarmupTime

public TimeSpan getAeWarmupTime()
Specified by:
getAeWarmupTime in interface PerformanceTestResult
Returns:
Returns the analysis engine warmup time.

setWarmupTime

public void setWarmupTime(TimeSpan warmupTime)
Parameters:
warmupTime - The analysis engine warmup time.

isDoAeWarmup

public boolean isDoAeWarmup()
Specified by:
isDoAeWarmup in interface PerformanceTestResult
Returns:
Returns the setting the the analysis engine warmup.

setDoWarmup

public void setDoWarmup(boolean doWarmup)
Parameters:
doWarmup - the doWarmup setting

toString

public java.lang.String toString()
returns a performance report with the current performance results.

Overrides:
toString in class java.lang.Object
See Also:
Object.toString()

writePerfResultsAsColumn

public void writePerfResultsAsColumn(java.lang.String level,
                                     java.io.File file)
                              throws java.lang.Exception
write performance results as colum.

Specified by:
writePerfResultsAsColumn in interface PerformanceTestResult
Parameters:
level - Test level name of the performance test
file - Output file where the results are written to
Throws:
java.lang.Exception

getAeCleanupTime

public TimeSpan getAeCleanupTime()
Specified by:
getAeCleanupTime in interface PerformanceTestResult
Returns:
Returns the analysis engine cleanup time.

setCleanupTime

public void setCleanupTime(TimeSpan cleanupTime)
Parameters:
cleanupTime - the analysis engine cleanup time

getDocumentPreparationTime

public TimeSpan getDocumentPreparationTime()
Specified by:
getDocumentPreparationTime in interface PerformanceTestResult
Returns:
Returns the document preparation time.

setDocumentPreparationTime

public void setDocumentPreparationTime(TimeSpan documentPreparationTime)
Parameters:
documentPreparationTime - the document preparation time

getProcessedFileSize

public long getProcessedFileSize()
Specified by:
getProcessedFileSize in interface PerformanceTestResult
Returns:
Returns the processed file collection size.

setTotalFileSize

public void setTotalFileSize(long collectionFileSize)
Parameters:
collectionFileSize - the collection file size


Copyright © 2012. All Rights Reserved.