CbmRoot
Loading...
Searching...
No Matches
CbmQaCheckerResult.h
Go to the documentation of this file.
1/* Copyright (C) 2025 GSI/VECC, Darmstadt/Kolkata
2 SPDX-License-Identifier: GPL-3.0-only
3 Authors: Sergei Zharko, Souvik Chattopadhyay[committer] */
4#ifndef CbmQaCheckerResult_h
5
6#define CbmQaCheckerResult_h 1
7
8
10
11#include <Rtypes.h> // for ClassDef
12#include <TNamed.h> // for TObject
13
14#include <limits>
15
16
17namespace cbm::qa::checker
18
19{
20
22
24
25 class Result : public TNamed {
26
27 public:
29
30 Result() = default;
31
32
34
35 Result(const Result&) = default;
36
37
39
40 Result(Result&&) = default;
41
42
49
50 Result(ECmpInference inference, bool exactEqual, double ratioMin, double ratioMax, double pVal)
51
52 : fRatioMin(ratioMin)
53
54 , fRatioMax(ratioMax)
55
56 , fPval(pVal)
57
58 , fbExactEqual(exactEqual)
59
60 , fCmpInference(inference)
61
62 {
63 }
64
65
67
68 ~Result() = default;
69
70
72
73 Result& operator=(const Result&) = default;
74
75
77
78 Result& operator=(Result&&) = default;
79
80
81 double GetRatioMin() const { return fRatioMin; }
82
83 double GetRatioMax() const { return fRatioMax; }
84
85 double GetPVal() const { return fPval; }
86
87 bool GetExactEqual() const { return fbExactEqual; }
88
90
91
92 void SetRatioMin(double ratioMin) { fRatioMin = ratioMin; }
93
94 void SetRatioMax(double ratioMax) { fRatioMax = ratioMax; }
95
96 void SetPVal(double pVal) { fPval = pVal; }
97
98 void SetExactEqual(bool exactEqual) { fbExactEqual = exactEqual; }
99
100 void SetCmpInference(ECmpInference inference) { fCmpInference = inference; }
101
102
104
105
106 private:
107 double fRatioMin{std::numeric_limits<double>::quiet_NaN()};
108
109 double fRatioMax{std::numeric_limits<double>::quiet_NaN()};
110
111 double fPval{std::numeric_limits<double>::quiet_NaN()};
112
113 bool fbExactEqual{true};
114
116 };
117
118} // namespace cbm::qa::checker
119
120
121#endif
Common definitions for QA-Checker framework.
Result & operator=(const Result &)=default
Copy assignment operator.
ECmpInference GetCmpInference() const
double fRatioMin
Minimal value of ratio.
Result & operator=(Result &&)=default
Move assignment operator.
void SetExactEqual(bool exactEqual)
~Result()=default
Destructor.
void SetRatioMin(double ratioMin)
Result(ECmpInference inference, bool exactEqual, double ratioMin, double ratioMax, double pVal)
Constructor from parameters.
bool fbExactEqual
Result of exact comparison.
Result(const Result &)=default
Copy constructor.
double fPval
Comparison p-value.
void SetCmpInference(ECmpInference inference)
Result()=default
Default constructor.
ECmpInference fCmpInference
Comparison inference.
double fRatioMax
Maximal value of ratio.
void SetRatioMax(double ratioMax)
Result(Result &&)=default
Move construction.
ECmpInference
The object comparison inference.
@ Different
Neither of the comparison methods showed equality.