]> git.uio.no Git - u/mrichter/AliRoot.git/blame - ITS/AliITSDetTypeRec.h
compilation warnings
[u/mrichter/AliRoot.git] / ITS / AliITSDetTypeRec.h
CommitLineData
3b9df642 1#ifndef ALIITSDETTYPEREC_H
2#define ALIITSDETTYPEREC_H
3/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * See cxx source for full Copyright notice */
5
6/*
7$Id$
8*/
9
7d62fb64 10////////////////////////////////////////////////////////////////////////
11// This class contains all of the "external" information needed to do //
12// detector specific reconstruction for the ITS. //
13////////////////////////////////////////////////////////////////////////
3b9df642 14#include <TObject.h>
15#include <TObjArray.h>
16#include <TClonesArray.h>
979b5a5f 17#include "AliITSDDLModuleMapSDD.h"
253e68a0 18#include "AliITSresponseSDD.h"
979b5a5f 19#include "AliITSgeom.h"
3b9df642 20
6cae184e 21class TTree;
22class TBranch;
23
24//#include "AliITSLoader.h"
25//#include "AliRunLoader.h"
3b9df642 26
3b9df642 27class AliITSsegmentation;
fcf95fc7 28class AliITSCalibration;
253e68a0 29class AliITSresponseSDD;
7d62fb64 30class AliITSClusterFinder;
31class AliITSRawCluster;
32class AliITSRecPoint;
7d62fb64 33class AliRawReader;
3b9df642 34
8ba39da9 35
3b9df642 36class AliITSDetTypeRec : public TObject {
37 public:
38 AliITSDetTypeRec(); // Default constructor
e56160b8 39
3b9df642 40 virtual ~AliITSDetTypeRec(); // Proper Destructor
7d62fb64 41
6cae184e 42 virtual AliITSgeom* GetITSgeom() const { return fITSgeom; }
43 virtual void SetITSgeom(AliITSgeom *geom) { fITSgeom = geom; }
7d62fb64 44 virtual void SetDefaults();
45 virtual void SetDefaultClusterFinders();
3a7c3e6d 46 virtual void SetDefaultClusterFindersV2(Bool_t rawdata=kFALSE);
6cae184e 47 virtual void MakeBranch(TTree *tree,Option_t *opt);
7d62fb64 48 virtual void SetTreeAddressD(TTree* treeD);
49
50 virtual void SetSegmentationModel(Int_t dettype, AliITSsegmentation *seg);
fcf95fc7 51 virtual void SetCalibrationModel(Int_t iMod, AliITSCalibration *cal);
23197852 52 virtual void SetSPDDeadModel(Int_t iMod, AliITSCalibration *cal);
7d62fb64 53 virtual void SetReconstructionModel(Int_t dettype, AliITSClusterFinder *rec);
8ba39da9 54 virtual Bool_t GetCalibration();
7d62fb64 55 virtual AliITSsegmentation* GetSegmentationModel(Int_t dettype);
fcf95fc7 56 virtual AliITSCalibration* GetCalibrationModel(Int_t iMod);
23197852 57 virtual AliITSCalibration* GetSPDDeadModel(Int_t iMod);
7d62fb64 58 virtual AliITSClusterFinder* GetReconstructionModel(Int_t dettype);
979b5a5f 59 virtual AliITSDDLModuleMapSDD* GetDDLModuleMapSDD() const { return fDDLMapSDD;}
253e68a0 60 virtual AliITSresponseSDD* GetResponseSDD() const { return fRespSDD;}
7d62fb64 61
62 virtual void SetDigitClassName(Int_t i,Char_t *digit)
63 {fDigClassName[i]=digit;}
64 virtual void SetClusterClassName(Int_t i,Char_t *cluster)
65 {fClusterClassName[i]=cluster;}
66 virtual void SetRecPointClassName(Int_t i,Char_t *recpoint)
67 {fRecPointClassName[i]=recpoint;}
68
69 Char_t* GetDigitClassName(Int_t i) const {return fDigClassName[i];}
70 Char_t* GetClusterClassName(Int_t i) const {return fClusterClassName[i];}
71 Char_t* GetRecPointClassName(Int_t i) const {return fRecPointClassName[i];}
72
73 TObjArray* GetDigits() const {return fDigits;}
74 Int_t *Ndtype() {return fNdtype;}
75 TClonesArray *DigitsAddress(Int_t id) const {return ((TClonesArray*)(*fDigits)[id]);}
76 virtual void SelectVertexer(TString sel=" "){fSelectedVertexer = sel;}
77 //
7d62fb64 78 virtual void AddCluster(Int_t branch, AliITSRawCluster *c);
79 virtual void ResetClusters();
80 virtual void ResetClusters(Int_t branch);
6cae184e 81 TBranch* MakeBranchInTree(TTree *tree, const char* name, const char *classname, void* address,Int_t size, Int_t splitlevel);
7d62fb64 82
83 TObjArray *Ctype() {return fCtype;}
84 Int_t *Nctype() {return fNctype;}
85 TClonesArray *ClustersAddress(Int_t id) const {return ((TClonesArray*)(*fCtype)[id]);}
86 virtual void ResetDigits();
87 virtual void ResetDigits(Int_t branch);
88
6cae184e 89 void MakeBranchR(TTree *treeR,Option_t *opt=" ");
7d62fb64 90 void SetTreeAddressR(TTree *treeR);
91 void AddRecPoint(const AliITSRecPoint &p);
92 void ResetRecPoints(){if(fRecPoints) fRecPoints->Clear();fNRecPoints = 0;};
93 // Return pointer to rec points
94 TClonesArray *RecPoints() {return fRecPoints;}
6cae184e 95 void MakeBranchRF(TTree *treeR){MakeBranchR(treeR,"Fast");}
96 void DigitsToRecPoints(TTree *treeD,TTree *treeR,Int_t lastEntry,Option_t *det,Bool_t v2=kFALSE);
8484b32d 97 void DigitsToRecPoints(AliRawReader* rawReader,TTree *treeR,Option_t *det="All");
8ba39da9 98
3b9df642 99 private:
8e50d897 100 // private methods
e56160b8 101 AliITSDetTypeRec(const AliITSDetTypeRec& rec);
102 AliITSDetTypeRec& operator=(const AliITSDetTypeRec &source);
103
6cae184e 104 // virtual void SetLoader(AliITSLoader* loader) {fLoader=loader;}
8ba39da9 105 static const Int_t fgkNdettypes; // number of det. types
106 static const Int_t fgkDefaultNModulesSPD; // Total numbers of SPD modules by default
107 static const Int_t fgkDefaultNModulesSDD; // Total numbers of SDD modules by default
108 static const Int_t fgkDefaultNModulesSSD; // Total numbers of SSD modules by default
8e50d897 109 Int_t *fNMod; // numbers of modules from different types
8ba39da9 110
6cae184e 111 AliITSgeom *fITSgeom; //! ITS geometry
112
7d62fb64 113 TObjArray *fReconstruction;//! [NDet]
114 TObjArray *fSegmentation; //! [NDet]
115 TObjArray *fCalibration; //! [NMod]
23197852 116 TObjArray *fSPDDead; //! [fgkDefaultNModulesSPD]
7d62fb64 117 TObjArray *fPreProcess; //! [] e.g. Find Calibration values
118 TObjArray *fPostProcess; //! [] e.g. find primary vertex
119 TObjArray *fDigits; //! [NMod][NDigits]
979b5a5f 120 AliITSDDLModuleMapSDD *fDDLMapSDD; //! mapping DDL/module -> SDD module number
253e68a0 121 AliITSresponseSDD *fRespSDD; //! SDD response parameters
7d62fb64 122 Int_t *fNdtype; //! detector types
123 Char_t* fClusterClassName[3]; //! String with Cluster class name
124 Char_t* fDigClassName[3]; //! String with digit class name.
125 Char_t* fRecPointClassName[3];//! String with RecPoint class name
126
127 TObjArray *fCtype; //! List of clusters
128 Int_t *fNctype; //[fNDetTypes] Num. of clust. per type of det.
129
130 TClonesArray *fRecPoints; //! List of reconstructed points
131 Int_t fNRecPoints; // Number of rec points
132
7d62fb64 133 TString fSelectedVertexer; // Vertexer selected in CreateVertexer
b17dae48 134 Bool_t fFirstcall; //! flag
3b9df642 135
253e68a0 136 ClassDef(AliITSDetTypeRec,10) // ITS Reconstruction structure
7d62fb64 137};
138
3b9df642 139#endif