Jpp
16.0.3
the software that should make you happy
|
Interface to read input and write output for TObject tests. More...
#include <JTest_t.hh>
Public Member Functions | |
JTest_t (const std::string &name, const std::string &type) | |
Constructor. More... | |
virtual std::istream & | read (std::istream &in)=0 |
Read test parameters from input. More... | |
std::ostream & | write (std::ostream &out, const char delimiter= ' ', const bool onlyFailures=false) const |
Write test result to output. More... | |
virtual void | test (TObject *o1, TObject *o2)=0 |
Tests compatibility between two TObjects. More... | |
virtual void | save (TFile *f, const std::string &path, const bool onlyFailures=false) |
Writes the test result to root file. More... | |
virtual void | clear () |
Clear results. More... | |
const std::string & | getTestName () |
Get test name. More... | |
const std::string & | getResultType () |
Get result type. More... | |
Public Attributes | |
std::vector< JTestResult > | results |
Buffer to store results of multiple tests.*/. More... | |
Protected Attributes | |
const std::string | testName |
test name More... | |
const std::string | resultType |
result type More... | |
Interface to read input and write output for TObject tests.
This is an abstract class from which the different tests are derived.
All tests have in common the methods from this interface.
For each test, the parameters are passed through an istream, and parsed by the read() method.
For each test, the different results are stored in the results buffer.
The write() method is used to print a message with the result of the test.
The save() method is used to save a graphical output with the test results into a .root file.
The clear() method clears the results buffer. For a list of available tests see JTestDictionary()
Definition at line 46 of file JTest_t.hh.
|
inline |
Constructor.
name | test name |
type | result type |
Definition at line 57 of file JTest_t.hh.
|
pure virtual |
Read test parameters from input.
in | input stream |
Implemented in JCOMPAREHISTOGRAMS::JTestZero, JCOMPAREHISTOGRAMS::JTestKolmogorov_1D, JCOMPAREHISTOGRAMS::JTestKolmogorov_2D, JCOMPAREHISTOGRAMS::JTestKolmogorovSlice, JCOMPAREHISTOGRAMS::JTestChi2_2D, JCOMPAREHISTOGRAMS::JTestRuns_2D, JCOMPAREHISTOGRAMS::JTestChi2R_1D, JCOMPAREHISTOGRAMS::JTestChi2R_2D, JCOMPAREHISTOGRAMS::JTestChi2_1D, JCOMPAREHISTOGRAMS::JTestIdentical_2D, JCOMPAREHISTOGRAMS::JTestIdentical_3D, JCOMPAREHISTOGRAMS::JTestIdentical_1D, JCOMPAREHISTOGRAMS::JTestChi2_Bin, JCOMPAREHISTOGRAMS::JTestSignificance_1D, JCOMPAREHISTOGRAMS::JTestSignificance_2D, and JCOMPAREHISTOGRAMS::JTestRuns_1D.
|
inline |
Write test result to output.
out | output stream |
delimiter | field delimiter |
onlyFailures | if true, write only failures. |
Definition at line 81 of file JTest_t.hh.
Tests compatibility between two TObjects.
o1 | First object |
o2 | Second object |
Implemented in JCOMPAREHISTOGRAMS::JTestRuns_2D, JCOMPAREHISTOGRAMS::JTestZero, JCOMPAREHISTOGRAMS::JTestKolmogorov_1D, JCOMPAREHISTOGRAMS::JTestKolmogorov_2D, JCOMPAREHISTOGRAMS::JTestKolmogorovSlice, JCOMPAREHISTOGRAMS::JTestChi2_2D, JCOMPAREHISTOGRAMS::JTestChi2R_1D, JCOMPAREHISTOGRAMS::JTestChi2R_2D, JCOMPAREHISTOGRAMS::JTestChi2_1D, JCOMPAREHISTOGRAMS::JTestChi2_Bin, JCOMPAREHISTOGRAMS::JTestIdentical_2D, JCOMPAREHISTOGRAMS::JTestIdentical_3D, JCOMPAREHISTOGRAMS::JTestIdentical_1D, JCOMPAREHISTOGRAMS::JTestSignificance_1D, JCOMPAREHISTOGRAMS::JTestSignificance_2D, and JCOMPAREHISTOGRAMS::JTestRuns_1D.
|
inlinevirtual |
Writes the test result to root file.
f | A ROOT file |
path | Path in root file. |
onlyFailures | If true, write only failures. |
Definition at line 113 of file JTest_t.hh.
|
inlinevirtual |
Clear results.
Definition at line 137 of file JTest_t.hh.
|
inline |
|
inline |
Get result type.
Definition at line 157 of file JTest_t.hh.
std::vector<JTestResult> JCOMPAREHISTOGRAMS::JTest_t::results |
Buffer to store results of multiple tests.*/.
Definition at line 162 of file JTest_t.hh.
|
protected |
test name
Definition at line 166 of file JTest_t.hh.
|
protected |
result type
Definition at line 167 of file JTest_t.hh.