]> git.uio.no Git - u/mrichter/AliRoot.git/blob - FMD/AliFMDInput.h
Added classes to make fake calibration constants, and alignment data.
[u/mrichter/AliRoot.git] / FMD / AliFMDInput.h
1 #ifndef AliFMDInput_H
2 #define AliFMDInput_H
3 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights
4  * reserved. 
5  *
6  * See cxx source for full Copyright notice                               
7  */
8 //___________________________________________________________________
9 //
10 // The classes defined here, are utility classes for reading in data
11 // for the FMD.  They are  put in a seperate library to not polute the
12 // normal libraries.  The classes are intended to be used as base
13 // classes for customized class that do some sort of analysis on the
14 // various types of data produced by the FMD. 
15 //
16 #include <TObject.h>
17 #ifndef ROOT_TString
18 # include <TString.h>
19 #endif
20 class AliRunLoader;
21 class AliLoader;
22 class AliStack;
23 class AliRun;
24 class AliFMD;
25 class AliFMDHit;
26 class AliFMDDigit;
27 class AliFMDSDigit;
28 class AliFMDRecPoint;
29 class AliESD;
30 class AliESDFMD;
31 class TString;
32 class TClonesArray;
33 class TTree;
34 class TGeoManager;
35 class TParticle;
36 class TChain;
37
38 //___________________________________________________________________
39 class AliFMDInput : public TObject
40 {
41 public:
42   enum ETrees {
43     kHits       = 1,  // Hits
44     kKinematics,      // Kinematics (from sim)
45     kDigits,          // Digits
46     kSDigits,         // Summable digits 
47     kHeader,          // Header information 
48     kRecPoints,       // Reconstructed points
49     kESD,             // Load ESD's
50     kGeometry         // Not really a tree 
51   };
52   AliFMDInput();
53   AliFMDInput(const char* gAliceFile);
54   virtual ~AliFMDInput() {}
55
56   virtual void   AddLoad(ETrees tree)     { SETBIT(fTreeMask, tree); }
57   virtual void   RemoveLoad(ETrees tree)  { CLRBIT(fTreeMask, tree); }
58   virtual Int_t  NEvents() const;
59
60   virtual Bool_t Init();
61   virtual Bool_t Begin(Int_t event);
62   virtual Bool_t Event();
63   virtual Bool_t End();
64   virtual Bool_t Finish() { return kTRUE; }
65   virtual Bool_t Run();
66
67   virtual Bool_t ProcessHits();
68   virtual Bool_t ProcessDigits();
69   virtual Bool_t ProcessSDigits();
70   virtual Bool_t ProcessRecPoints();
71
72   virtual Bool_t ProcessHit(AliFMDHit*, TParticle*)  { return kTRUE; }
73   virtual Bool_t ProcessDigit(AliFMDDigit*)          { return kTRUE; }
74   virtual Bool_t ProcessSDigit(AliFMDSDigit*)        { return kTRUE; }
75   virtual Bool_t ProcessRecPoint(AliFMDRecPoint*)    { return kTRUE; }
76   virtual Bool_t ProcessESD(AliESDFMD*)              { return kTRUE; }
77   
78 protected:
79   TString       fGAliceFile; // File name of gAlice file
80   AliRunLoader* fLoader;     // Loader of FMD data 
81   AliRun*       fRun;        // Run information
82   AliStack*     fStack;      // Stack of particles 
83   AliLoader*    fFMDLoader;  // Loader of FMD data 
84   AliFMD*       fFMD;        // FMD object
85   AliESD*       fMainESD;    // ESD Object
86   AliESDFMD*    fESD;        // FMD ESD data  
87   TTree*        fTreeE;      // Header tree 
88   TTree*        fTreeH;      // Hits tree
89   TTree*        fTreeD;      // Digit tree 
90   TTree*        fTreeS;      // SDigit tree 
91   TTree*        fTreeR;      // RecPoint tree
92   TChain*       fChainE;     // Chain of ESD's
93   TClonesArray* fArrayE;     // Event info array
94   TClonesArray* fArrayH;     // Hit info array
95   TClonesArray* fArrayD;     // Digit info array
96   TClonesArray* fArrayS;     // SDigit info array
97   TClonesArray* fArrayR;     // Mult (single) info array
98   TGeoManager*  fGeoManager; // Geometry manager
99   Int_t         fTreeMask;   // Which tree's to load
100   Bool_t        fIsInit;
101   ClassDef(AliFMDInput,0)  //Hits for detector FMD
102 };
103
104
105 //____________________________________________________________________
106 class AliFMDHit;
107 class AliFMDInputHits : public AliFMDInput 
108 {
109 public:
110   AliFMDInputHits(const char* file="galice.root") 
111     : AliFMDInput(file) { AddLoad(kHits); }
112   ClassDef(AliFMDInputHits, 0);
113 };
114
115 //____________________________________________________________________
116 class AliFMDDigit;
117 class AliFMDInputDigits : public AliFMDInput 
118 {
119 public:
120   AliFMDInputDigits(const char* file="galice.root")
121     : AliFMDInput(file) { AddLoad(kDigits); }
122   ClassDef(AliFMDInputDigits, 0);
123 };
124
125 //____________________________________________________________________
126 class AliFMDSDigit;
127 class AliFMDInputSDigits : public AliFMDInput 
128 {
129 public:
130   AliFMDInputSDigits(const char* file="galice.root") 
131     : AliFMDInput(file) { AddLoad(kSDigits); }
132   ClassDef(AliFMDInputSDigits, 0);
133 };
134
135 //____________________________________________________________________
136 class AliFMDRecPoint;
137 class AliFMDInputRecPoints : public AliFMDInput 
138 {
139 public:
140   AliFMDInputRecPoints(const char* file="galice.root") 
141     : AliFMDInput(file) { AddLoad(kRecPoints); }
142   ClassDef(AliFMDInputRecPoints, 0);
143 };
144
145 #endif
146 //____________________________________________________________________
147 //
148 // Local Variables:
149 //   mode: C++
150 // End:
151 //
152 // EOF
153 //