ViewVC Help
View File | Revision Log | Show Annotations | Root Listing
root/cvsroot/CMSSW/Alignment/CommonAlignmentAlgorithm/interface/AlignmentIORootBase.h
Revision: 1.1
Committed: Mon Aug 7 08:49:00 2006 UTC (18 years, 9 months ago) by fronga
Content type: text/plain
Branch: MAIN
CVS Tags: CMSSW_1_1_2, CMSSW_1_2_0_pre7, V00-07-01, V00-07-00, V00-06-00, CMSSW_1_2_0_pre4, V00-05-00, CMSSW_1_1_1, CMSSW_1_2_0_pre3, V00-04-00, CMSSW_1_0_6, V00-03-00, CMSSW_1_2_0_pre2, CMSSW_1_0_5, CMSSW_1_1_0, CMSSW_1_2_0_pre1, CMSSW_1_0_4, CMSSW_1_1_0_pre4, CMSSW_1_0_3, CMSSW_1_0_0_g4_81, CMSSW_1_1_0_pre3, CMSSW_1_0_2, CMSSW_1_0_1, CMSSW_1_1_0_pre2, CMSSW_1_0_0, CMSSW_1_0_0_pre5, CMSSW_1_1_0_pre1, CMSSW_1_0_0_pre4, CMSSW_1_0_0_pre3, CMSSW_1_0_0_pre2, V00-02-00, CMSSW_1_0_0_pre1, V00-01-00
Log Message:
Ported ORCA version of I/O.

File Contents

# User Rev Content
1 fronga 1.1 #ifndef Alignment_CommonAlignmentAlgorithm_AlignmentIORootBase_h
2     #define Alignment_CommonAlignmentAlgorithm_AlignmentIORootBase_h
3    
4     #include "TFile.h"
5     #include "TTree.h"
6     #include "TVector.h"
7     #include "TString.h"
8    
9     #include <string>
10     #include <iostream>
11     #include <vector>
12     #include <map>
13    
14     #include "Alignment/CommonAlignment/interface/Alignable.h"
15    
16     /// Base class for ROOT-based I/O of Alignment parameters etc.
17    
18     class AlignmentIORootBase
19     {
20    
21     protected:
22    
23     /// destructor
24     virtual ~AlignmentIORootBase(){};
25    
26     /// open IO
27     int openRoot(char* filename, int iteration, bool writemode);
28    
29     /// close IO
30     int closeRoot(void);
31    
32     /// create root branches
33     virtual void createBranches(void) = 0;
34    
35     /// set root branches
36     virtual void setBranchAddresses(void) = 0;
37    
38     /// test if file is existing and if so, what the highest iteration is
39     int testFile(char* filename, TString tname);
40    
41     /// compose tree name
42     TString treeName(int iter,TString tname);
43    
44     // data members
45    
46     TFile* IORoot; // root file
47     TTree* tree; // root tree
48     TString treename; // tree identifier name
49     TString treetxt; // tree text
50     bool bWrite; // if true we are writing, else reading
51    
52     const static int nParMax = 6; // maximal number of Parameters
53     const static int itermax = 1000; // max iteration to test for
54    
55     };
56    
57     #endif