]> git.uio.no Git - u/mrichter/AliRoot.git/blob - ITS/AliITSdigit.h
Default track number set to -3 and not 0.
[u/mrichter/AliRoot.git] / ITS / AliITSdigit.h
1 #ifndef ALIITSDIGIT_H
2 #define ALIITSDIGIT_H
3
4 ////////////////////////////////////////////////
5 //  Digits classes for set:ITS                //
6 ////////////////////////////////////////////////
7
8 #include <TObject.h>
9 #include <TObjArray.h>
10
11 //___________________________________________
12 class AliITSdigit: public TObject  {
13   
14 public:
15   
16   Int_t fCoord1;  // Cell number on Z axis (SPD+SDD) , flag for side type (SSD)
17   Int_t fCoord2 ; // Cell number on X axis (SPD+SDD) , strip number (SSD)
18   Int_t fSignal;  // Signal in ADC counts
19   
20 public:
21   AliITSdigit() {
22     // constructor
23     fSignal=fCoord1=fCoord2=0;
24   }
25   AliITSdigit(Int_t *digits);
26   virtual ~AliITSdigit() {
27     // destructor
28   }
29   
30   ClassDef(AliITSdigit,1)     // Real data digit object for set:ITS
31     };
32
33 //___________________________________________
34 class AliITSdigitSPD: public AliITSdigit {
35   
36 public:
37   
38     // debugging  -- goes to the dictionary
39   Int_t       fTracks[3];         // tracks making this digit 
40   Int_t       fHits[3];           // hits associated to the tracks 
41                                   // 3 hits temporarily - it will be only 1
42   
43 public:
44   AliITSdigitSPD() {
45     // constructor
46     fSignal=fCoord1=fCoord2=0;
47     fTracks[0]=fTracks[1]=fTracks[2]=-3;
48     fHits[0]=fHits[1]=fHits[2]=-1;
49   }
50   
51   AliITSdigitSPD(Int_t *digits);
52   AliITSdigitSPD(Int_t *digits, Int_t *tracks, Int_t *hits);
53   
54   virtual ~AliITSdigitSPD(){
55     // destructor
56   }
57   virtual int *GetTracks() {
58     // returns pointer to the array of tracks which make this digit
59     return &fTracks[0];
60   }
61   
62     ClassDef(AliITSdigitSPD,1)   // Simulated digit object for SPD
63       };
64
65 //___________________________________________
66 class AliITSdigitSDD: public AliITSdigit {
67   
68 public:
69   
70   // debugging  -- goes to the dictionary
71   Int_t       fTracks[3];         // tracks making this digit 
72   Int_t       fHits[3];           // hits associated to the tracks
73                                   // 3 hits temporarily - it will be only 1
74   Float_t     fTcharges[3];       // charge per track making this digit 
75   Float_t     fPhysics;           // signal particles contribution to signal
76   
77 public:
78   AliITSdigitSDD() {
79     // constructor
80     fSignal=fCoord1=fCoord2=0;
81     fTracks[0]=fTracks[1]=fTracks[2]=-3;
82     fHits[0]=fHits[1]=fHits[2]=-1;
83     fPhysics=0; fTcharges[0]=fTcharges[1]=fTcharges[2]=0;
84   }
85   
86   AliITSdigitSDD(Float_t phys,Int_t *digits);
87   AliITSdigitSDD( Float_t phys, Int_t *digits, Int_t *tracks, Int_t *hits, Float_t *charges);
88   
89   virtual ~AliITSdigitSDD(){
90     // destructor
91   }
92   virtual int *GetTracks() {
93     // returns pointer to the array of tracks which make this digit
94     return &fTracks[0];
95   }
96   
97   ClassDef(AliITSdigitSDD,1)   // Simulated digit object for SDD
98     };
99
100 //_____________________________________________________________________________
101
102 class AliITSTransientDigit : public AliITSdigitSDD {
103 public:
104   TObjArray     *fTrackList;  // track list 
105 public:
106   AliITSTransientDigit() {
107     // constructor
108     fTrackList=0;
109   }
110   AliITSTransientDigit(Float_t phys,Int_t *digits);
111   virtual ~AliITSTransientDigit() {
112     // destructor
113     delete fTrackList;
114   }
115   AliITSTransientDigit(const AliITSTransientDigit &source); // copy constructor
116   AliITSTransientDigit& operator=(const AliITSTransientDigit &source); // ass. operator
117   TObjArray  *TrackList()   {
118     // returns pointer to the TObjArray of tracks and associated charges
119     return fTrackList;
120   }
121   
122   ClassDef(AliITSTransientDigit,1)  // Transient digit for set: ITS
123     };
124
125 //___________________________________________
126 class AliITSdigitSSD: public AliITSdigit {
127   
128 public:
129   
130   // debugging  -- goes to the dictionary
131   Int_t       fTracks[3];         // tracks making this digit 
132   Int_t       fHits[3];           // hits associated to the tracks
133                                   // 3 hits temporarily - it will be only 1
134   
135 public:
136   AliITSdigitSSD() {
137     // constructor
138     fSignal=fCoord1=fCoord2=0;
139     fTracks[0]=fTracks[1]=fTracks[2]=-3;
140     fHits[0]=fHits[1]=fHits[2]=-1;
141   }
142   
143   AliITSdigitSSD(Int_t *digits);
144   AliITSdigitSSD(Int_t *digits, Int_t *tracks, Int_t *hits);
145   
146   virtual ~AliITSdigitSSD(){
147     // destructor
148   }
149   
150   Int_t  GetSignal() const {
151     // returns signal
152     return fSignal;
153   }
154
155   Int_t  GetStripNumber() const {
156     // returns strip number
157     return fCoord2;
158   }
159   
160   Int_t  IsSideP() const {
161     //returns 1  when side P and 0 when side N     
162     return fCoord1;
163   }
164   
165   virtual int *GetTracks() {
166     // returns pointer to the array of tracks which make this digit
167     return &fTracks[0];
168     }
169   
170   ClassDef(AliITSdigitSSD,1)   // Simulated digit object for SSD
171     };
172
173
174 #endif