File indexing completed on 2024-04-06 11:56:08
0001 #ifndef Alignment_CommonAlignmentAlgorithm_AlignmentIORootBase_h
0002 #define Alignment_CommonAlignmentAlgorithm_AlignmentIORootBase_h
0003
0004 #include "TString.h"
0005
0006 class TFile;
0007 class TTree;
0008
0009
0010
0011 class AlignmentIORootBase {
0012 protected:
0013
0014 AlignmentIORootBase() : tree(nullptr), myFile(nullptr) {}
0015
0016 virtual ~AlignmentIORootBase();
0017
0018
0019 int openRoot(const char* filename, int iteration, bool writemode);
0020
0021
0022 int closeRoot(void);
0023
0024
0025 virtual void createBranches(void) = 0;
0026
0027
0028 virtual void setBranchAddresses(void) = 0;
0029
0030
0031 int testFile(const char* filename, const TString& tname);
0032
0033
0034 TString treeName(int iter, const TString& tname);
0035
0036
0037
0038 TTree* tree;
0039 TString treename;
0040 TString treetxt;
0041 bool bWrite;
0042
0043 const static int nParMax = 20;
0044 const static int itermax = 1000;
0045
0046 private:
0047 TFile* myFile;
0048 };
0049
0050 #endif