Overture  Version 25
Public Member Functions | Protected Attributes | List of all members
Checker Class Reference

#include <Checker.h>

Public Member Functions

 Checker (const aString &checkFileName)
 Build a class for writing a "check file" for regression testing.
 
 ~Checker ()
 
void setCutOff (real cutOff)
 Set the cutOff for errors (errors below this value are set to zero)
 
void setLabel (const aString &label, const int index)
 Set the checkLabel[index].
 
void printMessage (const aString &label, real error, real time, real timeInit=-1.)
 print a message to the check file and to stdout.
 

Protected Attributes

real errorCutOff
 
FILE * checkFile
 
aString checkFileLabel [4]
 
aString fileName
 

Constructor & Destructor Documentation

Checker::Checker ( const aString checkFileName)

Build a class for writing a "check file" for regression testing.

Each line in the check file consists of a unique key and a result:

<<key1>> result1 <<key2>> result2 <<key3>> result3 <<key4>> result4

The key is formed from a set of default labels plus the label passed to the printMessage function key = checkLabel[0]/checkLabel[1]/checkLabel[2]/checkLabel[3]/label

The labels should be chosen to make the key unique so that the smartDiff.p perl script can perform a smart diff on two check files.

References checkFile, errorCutOff, fileName, and REAL_EPSILON.

Checker::~Checker ( )

References checkFile, fileName, and printF().

Member Function Documentation

void Checker::printMessage ( const aString label,
real  error,
real  time,
real  timeInit = -1. 
)

print a message to the check file and to stdout.

References assert, aString, checkFile, checkFileLabel, errorCutOff, fPrintF(), max(), NULL, printF(), and REAL_EPSILON.

void Checker::setCutOff ( real  cutOff)

Set the cutOff for errors (errors below this value are set to zero)

References errorCutOff.

void Checker::setLabel ( const aString label,
const int  index 
)

Set the checkLabel[index].

Each "key" consists of a sequence of labels. This function sets one of these labels.

References assert, and checkFileLabel.

Member Data Documentation

FILE* Checker::checkFile
protected

Referenced by Checker(), printMessage(), and ~Checker().

aString Checker::checkFileLabel[4]
protected

Referenced by printMessage(), and setLabel().

real Checker::errorCutOff
protected

Referenced by Checker(), printMessage(), and setCutOff().

aString Checker::fileName
protected

Referenced by Checker(), and ~Checker().


The documentation for this class was generated from the following files: