[763] | 1 | // Classe d'initialisation du module HiStats
|
---|
| 2 | // (Histogram and Statistics)
|
---|
| 3 |
|
---|
[2615] | 4 | #include "sopnamsp.h"
|
---|
[763] | 5 | #include "machdefs.h"
|
---|
| 6 | #include "histinit.h"
|
---|
| 7 |
|
---|
| 8 | #include "histos.h"
|
---|
| 9 | #include "histos2.h"
|
---|
| 10 | #include "hisprof.h"
|
---|
[2603] | 11 | #include "histerr.h"
|
---|
[3121] | 12 | #include "hist2err.h"
|
---|
[763] | 13 | #include "ntuple.h"
|
---|
| 14 | #include "xntuple.h"
|
---|
[2688] | 15 | #include "datatable.h"
|
---|
[2699] | 16 | #include "swppfdtable.h"
|
---|
[763] | 17 |
|
---|
[920] | 18 | /*!
|
---|
| 19 | \defgroup HiStats HiStats module
|
---|
[2808] | 20 | This module contains histograms (1D, 2D) and
|
---|
| 21 | classes for management of data sets as tables (NTuple, DataTable ...)
|
---|
[920] | 22 | */
|
---|
| 23 |
|
---|
[763] | 24 | int HiStatsInitiator::FgInit = 0;
|
---|
| 25 |
|
---|
[3019] | 26 | // Module version number - 2.0 , Jul 2006
|
---|
| 27 | #define MOD_VERS 2.0
|
---|
| 28 |
|
---|
[920] | 29 | /*!
|
---|
| 30 | \class SOPHYA::HiStatsInitiator
|
---|
| 31 | \ingroup HiStats
|
---|
[2808] | 32 | This class performs the initialisation for HiStats module.
|
---|
| 33 | More specifically, it registers PPF handlers for the following classes :
|
---|
| 34 | - Histo
|
---|
| 35 | - HProf
|
---|
[3121] | 36 | - Histo2D
|
---|
[2808] | 37 | - HistoErr
|
---|
[3121] | 38 | - Histo2DErr
|
---|
[2808] | 39 | - NTuple
|
---|
| 40 | - XNTuple
|
---|
| 41 | - DataTable
|
---|
| 42 | - SwPPFDataTable
|
---|
| 43 |
|
---|
| 44 | If the system linker/loader handles correctly static object initialisation, there
|
---|
| 45 | is no action required when writing programs. If not, an instance of the class must
|
---|
| 46 | be present before any other operation on the libray classes.
|
---|
[920] | 47 | */
|
---|
[2808] | 48 |
|
---|
[763] | 49 | HiStatsInitiator::HiStatsInitiator()
|
---|
| 50 | : NToolsInitiator()
|
---|
| 51 | {
|
---|
| 52 | FgInit++;
|
---|
| 53 | if (FgInit > 1) return;
|
---|
| 54 |
|
---|
| 55 | // Enregistrement des classes PPersist du modules HiStats
|
---|
| 56 |
|
---|
| 57 | PPRegister(ObjFileIO<Histo>);
|
---|
[809] | 58 | DObjRegister(ObjFileIO<Histo>, Histo);
|
---|
[763] | 59 | PPRegister(ObjFileIO<Histo2D>);
|
---|
[809] | 60 | DObjRegister(ObjFileIO<Histo2D>, Histo2D);
|
---|
[763] | 61 | PPRegister(ObjFileIO<HProf>);
|
---|
[809] | 62 | DObjRegister(ObjFileIO<HProf>, HProf);
|
---|
[3121] | 63 |
|
---|
[2603] | 64 | PPRegister(ObjFileIO<HistoErr>);
|
---|
| 65 | DObjRegister(ObjFileIO<HistoErr>, HistoErr);
|
---|
[3121] | 66 | PPRegister(ObjFileIO<Histo2DErr>);
|
---|
| 67 | DObjRegister(ObjFileIO<Histo2DErr>, Histo2DErr);
|
---|
[763] | 68 |
|
---|
| 69 | PPRegister(ObjFileIO<NTuple>);
|
---|
[809] | 70 | DObjRegister(ObjFileIO<NTuple>, NTuple);
|
---|
[763] | 71 | PPRegister(ObjFileIO<XNTuple>);
|
---|
[809] | 72 | DObjRegister(ObjFileIO<XNTuple>, XNTuple);
|
---|
[763] | 73 |
|
---|
[2699] | 74 | PPRegister(ObjFileIO<BaseDataTable>);
|
---|
| 75 | DObjRegister(ObjFileIO<BaseDataTable>, DataTable);
|
---|
| 76 | DObjRegister(ObjFileIO<BaseDataTable>, SwPPFDataTable);
|
---|
[2688] | 77 |
|
---|
[3019] | 78 | SophyaInitiator::RegisterModule("HiStats", MOD_VERS); // Module name and version number registration
|
---|
| 79 |
|
---|
[763] | 80 | }
|
---|
| 81 |
|
---|
| 82 | HiStatsInitiator::~HiStatsInitiator()
|
---|
| 83 | {
|
---|
| 84 | FgInit--;
|
---|
| 85 | }
|
---|
| 86 |
|
---|
| 87 |
|
---|
| 88 | // On met un objet initiator en statique, pour les loaders qui savent
|
---|
| 89 | // appeler le constructeur des objets statiques Reza 08/98
|
---|
| 90 | static HiStatsInitiator histatsinit;
|
---|
| 91 |
|
---|