]>
Commit | Line | Data |
---|---|---|
46d29e70 | 1 | #ifndef ALITRDCLUSTER_H |
2 | #define ALITRDCLUSTER_H | |
3 | /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. * | |
4 | * See cxx source for full Copyright notice */ | |
5 | ||
6 | /* $Id$ */ | |
7 | ||
6d50f529 | 8 | /////////////////////////////////////////////////////////////////////////////// |
9 | // // | |
10 | // TRD cluster // | |
11 | // // | |
12 | /////////////////////////////////////////////////////////////////////////////// | |
5443e65e | 13 | |
14 | #include "AliCluster.h" | |
46d29e70 | 15 | |
16 | class AliTRDrecPoint; | |
17 | ||
5443e65e | 18 | class AliTRDcluster : public AliCluster { |
46d29e70 | 19 | |
20 | public: | |
21 | ||
bdb68f8c | 22 | AliTRDcluster(); |
a2b90f83 | 23 | AliTRDcluster(const AliTRDcluster &c); |
24 | AliTRDcluster(const AliTRDrecPoint &p); | |
a2b90f83 | 25 | |
6d50f529 | 26 | virtual void AddTrackIndex(Int_t *i); |
a2b90f83 | 27 | |
6d50f529 | 28 | Int_t IsUsed() const { return (fQ < 0) ? 1 : 0; } |
29 | void Use(Int_t = 0) { fQ = -fQ; } | |
5443e65e | 30 | |
6d50f529 | 31 | Bool_t From2pad() const { return TestBit(k2pad); } |
32 | Bool_t From3pad() const { return TestBit(k3pad); } | |
33 | Bool_t From4pad() const { return TestBit(k4pad); } | |
34 | Bool_t From5pad() const { return TestBit(k5pad); } | |
35 | Bool_t FromLarge() const { return TestBit(kLarge); } | |
36 | Bool_t Isolated() const { return (TestBit(k2pad) || TestBit(k3pad)); } | |
abaf1f1d | 37 | |
6d50f529 | 38 | virtual void SetDetector(Int_t d) { fDetector = d; } |
39 | void SetLocalTimeBin(Int_t t) { fTimeBin = t; } | |
40 | void SetQ(Float_t q) { fQ = q; } | |
6d50f529 | 41 | void SetCenter(Float_t c) { fCenter = c; } |
524fc8fa | 42 | void SetPad(UChar_t pad) { fPad = pad; } |
6d50f529 | 43 | void SetSignals(Short_t *signals); |
44 | void Set2pad() { SetBit(k2pad); fNPads = 2; } | |
45 | void Set3pad() { SetBit(k3pad); fNPads = 3; } | |
46 | void Set4pad() { SetBit(k4pad); fNPads = 4; } | |
47 | void Set5pad() { SetBit(k5pad); fNPads = 5; } | |
48 | void SetLarge() { SetBit(kLarge); fNPads = 6; } | |
3551db50 | 49 | |
6d50f529 | 50 | virtual Int_t GetDetector() const { return fDetector; } |
51 | Int_t GetLocalTimeBin() const { return fTimeBin; } | |
52 | Float_t GetQ() const { return fQ; } | |
6d50f529 | 53 | Int_t GetNPads() const { return fNPads; } |
54 | Float_t GetCenter() const { return fCenter; } | |
524fc8fa | 55 | Int_t GetPad() const { return fPad; } |
77566f2a | 56 | Short_t *GetSignals() { return fSignals; } |
6d50f529 | 57 | Float_t GetSumS() const; |
5443e65e | 58 | |
46d29e70 | 59 | protected: |
60 | ||
6d50f529 | 61 | enum { |
62 | k2pad = 0x00000001, // 2 pad cluster | |
63 | k3pad = 0x00000002, // 3 pad cluster | |
64 | k4pad = 0x00000004, // 4 pad cluster | |
65 | k5pad = 0x00000008, // 5 pad cluster | |
66 | kLarge = 0x00000016 // Large cluster | |
67 | }; | |
5443e65e | 68 | |
6d50f529 | 69 | Int_t fDetector; // TRD detector number |
6d50f529 | 70 | Char_t fTimeBin; // Time bin number within the detector |
71 | Float_t fQ; // Amplitude | |
72 | Char_t fNPads; // Number of pads in cluster | |
73 | Float_t fCenter; // Center of the cluster relative to the pad | |
524fc8fa | 74 | UChar_t fPad; // Central pad number |
6d50f529 | 75 | Short_t fSignals[7]; // Signals in the cluster |
3551db50 | 76 | |
524fc8fa | 77 | ClassDef(AliTRDcluster,4) // Cluster for the TRD |
46d29e70 | 78 | |
79 | }; | |
80 | ||
bdb68f8c | 81 | |
46d29e70 | 82 | #endif |