/[PAMELA software]/DarthVader/RunInfo/inc/RunInfo.h
ViewVC logotype

Contents of /DarthVader/RunInfo/inc/RunInfo.h

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.10 - (show annotations) (download)
Wed Aug 27 14:44:33 2014 UTC (10 years, 3 months ago) by mocchiut
Branch: MAIN
CVS Tags: v10RED, v10REDr01, HEAD
Changes since 1.9: +23 -0 lines
File MIME type: text/plain
New ProcInfo class and new ProcessingInfo tree in the level2 files+ printouts commented

1 #ifndef RunInfo_h
2 #define RunInfo_h
3 //
4 #include <TObject.h>
5 #include <TTree.h>
6 #include <TChain.h>
7 #include <TFile.h>
8 #include <TArrayI.h>
9 #include <TSQLServer.h>
10 //
11 #include <GLTables.h>
12 //
13 #include <RunInfoStruct.h>
14
15 class ProcInfo : public TObject {
16
17 private:
18
19 public:
20 UInt_t runID; ///< ID of the processed run (input from DV)
21 TString date; ///< processing date and time
22 TString commandLine; ///< input command line
23 TString outputFilename; ///< output filename
24 TString localDir; ///< workiing directory
25 TString uname; ///< local machine and arch (output of "uname -a")
26 TString DB; ///< database used for this processing
27 //
28 // Default constructor
29 //
30 ProcInfo();
31
32 void Clear(Option_t *t="");
33 ProcInfo* GetProcInfo(){return this;};
34 //
35 ClassDef(ProcInfo,1);
36 //
37 };
38
39 class SoftInfo : public TObject {
40
41 private:
42
43 public:
44 TString DV_ver;
45 TString ORB_ver;
46 TString TRIG_ver;
47 TString TOF_ver;
48 TString AC_ver;
49 TString TRK_ver;
50 TString CAL_ver;
51 TString S4_ver;
52 TString ND_ver;
53 //
54 // Default constructor
55 //
56 SoftInfo();
57
58 void Clear(Option_t *t="");
59 void GetLevel2Struct(cSoftInfo *l2) const;
60 SoftInfo* GetSoftInfo(){return this;};
61 UInt_t GetSWinfo(TString DEC);
62
63 //
64 ClassDef(SoftInfo,2);
65 //
66 };
67
68 class ItoRunInfo : public GL_RUN {
69
70 private:
71 UInt_t file_entries;
72 UInt_t totnorun;
73 Int_t first_file_entry;
74 Int_t last_file_entry;
75 UInt_t norun;
76 Bool_t reprocessing;
77 Bool_t updating;
78 Bool_t isreadonly;
79 TFile *file;
80 TTree *newtree;
81 TArrayI *runlist;
82 UInt_t idRun;
83 TSQLServer *dbc;
84 TString processFolder;
85 TString Detector;
86 void CopyFromTo(GL_RUN *, GL_RUN *, SoftInfo *, SoftInfo *);
87
88 public:
89 //
90 SoftInfo *version;
91 //
92 // GL_RUN *glrun;
93 //
94 // Default constructor
95 //
96 ItoRunInfo();
97 ~ItoRunInfo();
98 //
99 // Other constructors...
100 //
101 // ... for updating GL_RUN informations by RunInfo exec
102 //
103 ItoRunInfo(TSQLServer *db, TFile *processFl, TString processFld);
104 //
105 // ... for updating versioning informations by programs and to read only data
106 //
107 ItoRunInfo(TFile *processFile);
108 //
109 //
110 //
111 Int_t Update(UInt_t run, TString Detector, TString Version);
112 Int_t Read(UInt_t run);
113 void Write();
114 Int_t GetRunInfo(UInt_t run);
115 UInt_t GetRunForEntry(UInt_t entry);
116 void Close();
117 void Clear(Option_t *t="");
118 //
119 void *GetPointerToSI(){return &version;};
120 void *GetPointerToRI(){return this;};
121 //void *GetPointerToRI(){return &glrun;};
122 TChain *GetRunTree(TList *fl);
123 //
124 UInt_t GetRunEntries(){return(totnorun);};
125 UInt_t GetNoRun(){return(norun);};
126 TArrayI *GetRunList(){return(runlist);};
127 Bool_t IsReprocessing(){return(reprocessing);};
128 UInt_t GetFirstEntry(){return(first_file_entry);};
129 UInt_t GetLastEntry(){return(last_file_entry-1);};
130 UInt_t GetEntries(){Long64_t en = last_file_entry-1-first_file_entry; if ( en < 0LL ) en = 0LL; return((UInt_t)en);};
131 UInt_t GetFileEntries(){return(file_entries);};
132 //
133 ClassDef(ItoRunInfo,3);
134 //
135 };
136
137 #endif
138

  ViewVC Help
Powered by ViewVC 1.1.23