/
githubmirror
/
cmssw
Обзор
Документация
Войти
/
githubmirror
/
cmssw
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
master
Alignment/CommonAlignmentAlgorithm/interface/AlignmentIORootBase.h
50 строк
1 KB
Cms Build
Clang-Format
09 май 2019, 07:16
09 май 2019, 07:16
7f0c057
Код
Авторство
О чём код?
#ifndef Alignment_CommonAlignmentAlgorithm_AlignmentIORootBase_h #define Alignment_CommonAlignmentAlgorithm_AlignmentIORootBase_h #include "TString.h" class TFile; class TTree; /// Base class for ROOT-based I/O of Alignment parameters etc. class AlignmentIORootBase { protected: /// constructor AlignmentIORootBase() : tree(nullptr), myFile(nullptr) {} /// destructor virtual ~AlignmentIORootBase(); /// open IO int openRoot(const char* filename, int iteration, bool writemode); /// close IO int closeRoot(void); /// create root branches virtual void createBranches(void) = 0; /// set root branches virtual void setBranchAddresses(void) = 0; /// test if file is existing and if so, what the highest iteration is int testFile(const char* filename, const TString& tname); /// compose tree name TString treeName(int iter, const TString& tname); // data members TTree* tree; // root tree TString treename; // tree identifier name TString treetxt; // tree text bool bWrite; // if true we are writing, else reading const static int nParMax = 20; // maximal number of Parameters const static int itermax = 1000; // max iteration to test for private: TFile* myFile; // root file }; #endif