1 #ifndef GAUDIKERNEL_STATENTITY_H
2 #define GAUDIKERNEL_STATENTITY_H 1
13 #include "GaudiKernel/Kernel.h"
84 const double minFlag ,
85 const double maxFlag ) ;
92 const unsigned long& nEntries ()
const {
return m_se_nEntries ; }
94 const double&
sum ()
const {
return m_se_accumulatedFlag ; }
96 const double& sum2 ()
const {
return m_se_accumulatedFlag2 ; }
98 double mean ()
const ;
100 double rms ()
const ;
102 double meanErr ()
const ;
104 const double& min ()
const {
return m_se_minimalFlag ; }
106 const double& max ()
const {
return m_se_maximalFlag ; }
142 double efficiency ()
const ;
179 double efficiencyErr ()
const ;
181 double eff ()
const {
return efficiency () ; }
183 double effErr ()
const {
return efficiencyErr () ; }
228 StatEntity& operator++ () {
return (*
this)+= 1 ; }
247 StatEntity& operator++ (
int) {
return ++(*this) ; }
289 StatEntity& operator-- () {
return (*
this)-=1 ; }
307 StatEntity& operator-- (
int) {
return --(*this) ; }
357 unsigned long add (
const double Flag ) ;
361 void setnEntriesBeforeReset (
unsigned long nEntriesBeforeReset );
367 std::ostream& print ( std::ostream& o = std::cout )
const ;
371 std::ostream& fillStream ( std::ostream& o )
const {
return print ( o ) ; }
376 inline double Sum ()
const {
return sum () ; }
378 inline double Mean ()
const {
return mean () ; }
380 inline double MeanErr ()
const {
return meanErr () ; }
382 inline double Rms ()
const {
return rms () ; }
384 inline double RMS ()
const {
return rms () ; }
386 inline double Eff ()
const {
return eff () ; }
388 inline double Min ()
const {
return min () ; }
390 inline double Max ()
const {
return max () ; }
395 inline double flag ()
const {
return sum () ; }
397 inline double flag2 ()
const {
return sum2 () ; }
399 inline double flagMean ()
const {
return mean () ; }
401 inline double flagRMS ()
const {
return rms () ; }
403 inline double flagMeanErr ()
const {
return meanErr () ; }
405 inline double flagMin ()
const {
return min () ; }
407 inline double flagMax ()
const {
return max () ; }
412 inline unsigned long addFlag (
const double Flag ) {
return add ( Flag ) ; }
422 static const std::string&
format () ;
434 unsigned long m_se_nEntries ;
436 double m_se_accumulatedFlag ;
437 double m_se_accumulatedFlag2 ;
438 double m_se_minimalFlag ;
439 double m_se_maximalFlag ;
441 long m_se_nEntriesBeforeReset ;
514 const std::string& format1 =
515 " |%|7d| |%|11.7g| |%|#11.5g| |%|#10.5g| |%|#10.5g| |%|#10.5g| |" ,
516 const std::string& format2 =
517 "*|%|7d| |%|11.5g| |(%|#9.7g| +- %|-#8.6g|)%%| ----- | ----- |" );
580 (
const std::string&
name ,
582 const bool flag =
true ,
583 const std::string& format1 =
584 " %|-15.15s|%|17t||%|7d| |%|11.7g| |%|#11.5g| |%|#10.5g| |%|#10.5g| |%|#10.5g| |" ,
585 const std::string& format2 =
586 "*%|-15.15s|%|17t||%|7d| |%|11.5g| |(%|#9.7g| +- %|-#8.6g|)%%| ----- | ----- |" );
656 (
const std::string&
name ,
657 const std::string& group ,
659 const bool flag =
true ,
660 const std::string& format1 =
661 " %|15.15s|%|-15.15s|%|32t||%|7d| |%|11.7g| |%|#11.5g| |%|#10.5g| |%|#10.5g| |%|#10.5g| |" ,
662 const std::string& format2 =
663 "*%|15.15s|%|-15.15s|%|32t||%|7d| |%|11.5g| |(%|#9.7g| +- %|-#8.6g|)%%| ----- | ----- |" ) ;
671 #endif // GAUDIKERNEL_STATENTITY_H
double sum(double x, double y, double z)
std::string toString(const TYPE &obj)
the generic implementation of the type conversion to the string
GAUDI_API StatEntity operator+(const StatEntity &entity, const double value)
external operator for addition of StatEntity and a number
GAUDI_API StatEntity operator-(const StatEntity &entity, const double value)
external operator for subtraction of StatEntity and a number
GAUDI_API std::ostream & operator<<(std::ostream &stream, const StatEntity &entity)
external printout operator to std::ostream
GAUDI_API std::string formatAsTableRow(const StatEntity &counter, const bool flag, const std::string &format1=" |%|7d| |%|11.7g| |%|#11.5g| |%|#10.5g| |%|#10.5g| |%|#10.5g| |", const std::string &format2="*|%|7d| |%|11.5g| |(%|#9.7g| +- %|-#8.6g|)%%| ----- | ----- |")
print the counter in a form of the table row
bool operator<(const Gaudi::Time &t1, const Gaudi::Time &t2)
The basic counter used for Monitoring purposes.
Helper functions to set/get the application return code.
GAUDI_API std::string format(const char *,...)
MsgStream format utility "a la sprintf(...)".