]>
Commit | Line | Data |
---|---|---|
5919c40c | 1 | #ifndef ALITOFSDIGIT_H |
2 | #define ALITOFSDIGIT_H | |
3 | ||
4 | //////////////////////////////////////////////// | |
5 | // // | |
6 | // Class for TOF SDigits // | |
7 | // // | |
8 | //////////////////////////////////////////////// | |
9 | ||
10 | /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. * | |
11 | * See cxx source for full Copyright notice */ | |
12 | ||
13 | /* $Id$ */ | |
14 | ||
15 | #include "TArrayF.h" | |
16 | #include "TArrayI.h" | |
17 | #include "AliDigit.h" | |
18 | ||
19 | //class TArrayF; | |
d3c7bfac | 20 | class AliTOFGeometry; |
5919c40c | 21 | |
5919c40c | 22 | class AliTOFSDigit : public TObject { |
23 | ||
24 | //overloading of the streamer << operator | |
d3c7bfac | 25 | //friend ostream& operator << ( ostream& , const AliTOFSDigit&) ; |
5919c40c | 26 | |
27 | public: | |
d3c7bfac | 28 | AliTOFSDigit(); |
5919c40c | 29 | AliTOFSDigit(Int_t tracknum, Int_t* vol, Float_t* digit); |
30 | // new ctor for sdigits | |
31 | AliTOFSDigit(Int_t sector, Int_t plate, Int_t strip, Int_t padx, Int_t padz, Float_t tdc, Float_t adc); | |
32 | // copy ctor | |
33 | AliTOFSDigit(const AliTOFSDigit & digit) ; | |
7aeeaf38 | 34 | AliTOFSDigit& operator=(const AliTOFSDigit & digit) ; |
5919c40c | 35 | virtual ~AliTOFSDigit(); |
36 | void GetLocation(Int_t* Loc) const; | |
d3c7bfac | 37 | Int_t GetTotPad(AliTOFGeometry *tofGeom) const; |
5919c40c | 38 | |
b213b8bd | 39 | void Update(Float_t tdcbin, Int_t tdc, Int_t adc, Int_t track); |
8e72349e | 40 | void Update(AliTOFSDigit* sdig); |
5919c40c | 41 | |
42 | // getters for AliTOFSDigit object | |
43 | Int_t GetNDigits() const {return fNDigits;} | |
44 | Float_t GetTdc(Int_t i) const {return fTdc->At(i);} | |
45 | Float_t GetAdc(Int_t i) const {return fAdc->At(i);} | |
46 | // Int_t GetNTracks(Int_t i) const {return fTracks[i]->GetSize();} | |
47 | Int_t GetTrack(Int_t i, Int_t j) const {return fTracks->At(i*kMAXDIGITS+j);} | |
48 | Int_t GetSector() const {return fSector;} | |
49 | Int_t GetPlate() const {return fPlate;} | |
50 | Int_t GetStrip() const {return fStrip;} | |
51 | Int_t GetPadx() const {return fPadx;} | |
52 | Int_t GetPadz() const {return fPadz;} | |
53 | ||
7aeeaf38 | 54 | enum { |
55 | kMAXDIGITS = 3 // number 3 is a legacy from AliDigit object | |
56 | }; | |
57 | ||
5919c40c | 58 | protected: |
7aeeaf38 | 59 | |
5919c40c | 60 | Int_t fSector; // number of sector |
61 | Int_t fPlate; // number of plate | |
62 | Int_t fStrip; // number of strip | |
63 | Int_t fPadx; // number of pad along x | |
64 | Int_t fPadz; // number of pad along z | |
65 | Int_t fNDigits; // dimension of fTdc array | |
66 | TArrayF *fTdc; // tdc values for sdigit | |
67 | TArrayF *fAdc; // adc values for sdigit | |
68 | TArrayI *fTracks; // contributing tracks, kMAXDIGITS entries per | |
69 | // 1 tdc value | |
70 | ||
71 | // Float_t *fTdc; //[fNDigits] tdc values for sdigit | |
72 | // Float_t *fAdc; //[fNDigits] adc values for sdigit | |
73 | // Int_t **fTracks; //[fNDigits] contributing tracks, pointers to | |
d3c7bfac | 74 | //arrays with track indices |
75 | ||
5919c40c | 76 | ClassDef(AliTOFSDigit,1) // SDigit for Time Of Flight |
77 | }; | |
78 | ||
79 | #endif /* ALITOFSDIGIT_H */ |