]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - ITS/AliITSDetTypeRec.h
- AliITSInitGeometry.cxx (updated): fgkOldSSDcone changed from kTRUE to
[u/mrichter/AliRoot.git] / ITS / AliITSDetTypeRec.h
index f5f4d082b9b36230a6e759ec2cf1204655563ae2..1e1bb62f5ced862c013f7515010b645f6c8ec54b 100644 (file)
@@ -14,9 +14,14 @@ $Id$
 #include <TObject.h>
 #include <TObjArray.h>
 #include <TClonesArray.h>
+#include "AliITSDDLModuleMapSDD.h"
+#include "AliITSgeom.h"
 
-#include "AliITSLoader.h"
-#include "AliRunLoader.h"
+class TTree;
+class TBranch;
+
+//#include "AliITSLoader.h"
+//#include "AliRunLoader.h"
 
 class AliITSsegmentation;
 class AliITSCalibration;
@@ -24,25 +29,20 @@ class AliITSClusterFinder;
 class AliITSRawCluster;
 class AliITSRecPoint;
 class AliRawReader;
-class AliITSgeom;
 
 
 class AliITSDetTypeRec : public TObject {
   public:
     AliITSDetTypeRec(); // Default constructor
-    AliITSDetTypeRec(AliITSLoader *loader); // Standard constructor
-    AliITSDetTypeRec(const AliITSDetTypeRec& rec);
-    AliITSDetTypeRec& operator=(const AliITSDetTypeRec &source);
-
     virtual ~AliITSDetTypeRec(); // Proper Destructor
-    AliITSgeom* GetITSgeom()const{return GetLoader()->GetITSgeom();}
 
-    AliITSLoader* GetLoader() const {return fLoader;}
+    virtual AliITSgeom* GetITSgeom() const { return fITSgeom; }
+    virtual void SetITSgeom(AliITSgeom *geom) { fITSgeom = geom; }
     virtual void SetDefaults();
     virtual void SetDefaultClusterFinders();
     virtual void SetDefaultClusterFindersV2(Bool_t rawdata=kFALSE);
-    virtual void MakeBranch(Option_t *opt);
-    virtual void SetTreeAddress();
+    virtual void MakeBranch(TTree *tree,Option_t *opt);
     virtual void SetTreeAddressD(TTree* treeD);
 
     virtual void SetSegmentationModel(Int_t dettype, AliITSsegmentation *seg);
@@ -52,6 +52,7 @@ class AliITSDetTypeRec : public TObject {
     virtual AliITSsegmentation* GetSegmentationModel(Int_t dettype);
     virtual AliITSCalibration* GetCalibrationModel(Int_t iMod);
     virtual AliITSClusterFinder* GetReconstructionModel(Int_t dettype);
+    virtual AliITSDDLModuleMapSDD* GetDDLModuleMapSDD() const { return fDDLMapSDD;}
 
     virtual void SetDigitClassName(Int_t i,Char_t *digit) 
       {fDigClassName[i]=digit;}
@@ -69,13 +70,10 @@ class AliITSDetTypeRec : public TObject {
     TClonesArray *DigitsAddress(Int_t id) const {return ((TClonesArray*)(*fDigits)[id]);}
     virtual void SelectVertexer(TString sel=" "){fSelectedVertexer = sel;}
     //
-    virtual void MakeTreeC();
-    virtual void GetTreeC(Int_t event);
     virtual void AddCluster(Int_t branch, AliITSRawCluster *c);
     virtual void ResetClusters(); 
     virtual void ResetClusters(Int_t branch);
-    virtual void MakeBranchC();
-    TBranch* MakeBranchInTree(TTree *tree, const char* name, const char *classname, void* address,Int_t size, Int_t splitlevel, const char */*file*/);
+    TBranch* MakeBranchInTree(TTree *tree, const char* name, const char *classname, void* address,Int_t size, Int_t splitlevel);
 
     TObjArray    *Ctype()  {return fCtype;}
     Int_t        *Nctype() {return fNctype;}
@@ -83,38 +81,37 @@ class AliITSDetTypeRec : public TObject {
     virtual void ResetDigits();
     virtual void ResetDigits(Int_t branch);
 
-    void MakeBranchR(const char *file, Option_t *opt=" ");
+    void MakeBranchR(TTree *treeR,Option_t *opt=" ");
     void SetTreeAddressR(TTree *treeR);
     void AddRecPoint(const AliITSRecPoint &p);
     void ResetRecPoints(){if(fRecPoints) fRecPoints->Clear();fNRecPoints = 0;};
     // Return pointer to rec points 
     TClonesArray  *RecPoints()   {return fRecPoints;}
-    void MakeBranchRF(const char *file){MakeBranchR(file,"Fast");}
-    //    void HitsToFastRecPoints(Int_t evNumber,Int_t bgrev,Int_t size,
-    //             Option_t *add, Option_t *det, const char *filename);
-    void Digits2Reco(){
-        DigitsToRecPoints(fLoader->GetRunLoader()->GetEventNumber(),0,"All");}
-    void DigitsToRecPoints(Int_t evNumber,Int_t lastEntry,Option_t *det,Bool_t v2=kFALSE);
-    void DigitsToRecPoints(AliRawReader* rawReader);
-
-    virtual void SetRunNumber(Int_t rn=0){fRunNumber = rn;}
-    virtual Int_t GetRunNumber() const {return fRunNumber;}
+    void MakeBranchRF(TTree *treeR){MakeBranchR(treeR,"Fast");}
+    void DigitsToRecPoints(TTree *treeD,TTree *treeR,Int_t lastEntry,Option_t *det,Bool_t v2=kFALSE);
+    void DigitsToRecPoints(AliRawReader* rawReader,TTree *treeR,Option_t *det="All");
 
   private:
     // private methods
-    virtual void SetLoader(AliITSLoader* loader) {fLoader=loader;}
+    AliITSDetTypeRec(const AliITSDetTypeRec& rec);
+    AliITSDetTypeRec& operator=(const AliITSDetTypeRec &source);
+    //    virtual void SetLoader(AliITSLoader* loader) {fLoader=loader;}
     static const Int_t fgkNdettypes;          // number of det. types
     static const Int_t fgkDefaultNModulesSPD; // Total numbers of SPD modules by default
     static const Int_t fgkDefaultNModulesSDD; // Total numbers of SDD modules by default
     static const Int_t fgkDefaultNModulesSSD; // Total numbers of SSD modules by default
     Int_t *fNMod;     // numbers of modules from different types
 
+    AliITSgeom   *fITSgeom;       //! ITS geometry
+
     TObjArray    *fReconstruction;//! [NDet]
     TObjArray    *fSegmentation;  //! [NDet]
     TObjArray    *fCalibration;   //! [NMod]
     TObjArray    *fPreProcess;    //! [] e.g. Find Calibration values
     TObjArray    *fPostProcess;   //! [] e.g. find primary vertex
     TObjArray    *fDigits;        //! [NMod][NDigits]
+    AliITSDDLModuleMapSDD *fDDLMapSDD; //! mapping DDL/module -> SDD module number
     Int_t        *fNdtype;        //! detector types  
     Char_t*       fClusterClassName[3]; //! String with Cluster class name
     Char_t*       fDigClassName[3];     //! String with digit class name.
@@ -127,11 +124,9 @@ class AliITSDetTypeRec : public TObject {
     Int_t         fNRecPoints; // Number of rec points
 
     TString fSelectedVertexer; // Vertexer selected in CreateVertexer
-    AliITSLoader* fLoader;     //! ITS loader
-    Int_t         fRunNumber;  //! run number (to access DB)
     Bool_t fFirstcall;         //! flag
 
-    ClassDef(AliITSDetTypeRec,6) // ITS Reconstruction structure
+    ClassDef(AliITSDetTypeRec,8) // ITS Reconstruction structure
 };
 
 #endif