]> git.uio.no Git - u/mrichter/AliRoot.git/blob - ITS/AliITSOnlineCalibrationSPD.h
Mainly changes related to the added treatment of inactive detector parts in
[u/mrichter/AliRoot.git] / ITS / AliITSOnlineCalibrationSPD.h
1 #ifndef ALI_ITS_ONLINECALIBRATIONSPD_H
2 #define ALI_ITS_ONLINECALIBRATIONSPD_H
3
4 ///////////////////////////////////////////////////////////////////////
5 // Author: Henrik Tydesjo                                            //
6 // This class is used as a container to keep the dead,noisy,active   //
7 // pixels online. Each object corresponds to one DDL (eq).           //
8 // Note: This class should not be used directly.                     //
9 // Use it via AliITSOnlineCalibrationSPDhandler instead.             //
10 ///////////////////////////////////////////////////////////////////////
11
12 /* $Id$  */
13
14 #include <TObject.h>
15 #include <TArrayI.h>
16
17 class AliITSOnlineCalibrationSPD : public TObject {
18
19  public:
20     AliITSOnlineCalibrationSPD();
21     virtual ~AliITSOnlineCalibrationSPD() {}
22
23     void   SetEqNr(UInt_t eq) {fEqNr=eq;}
24     UInt_t GetEqNr() const {return fEqNr;}
25     void   SetBadList(TArrayI badlist) {fBadChannels=badlist;}
26     void   SetNrBad(UInt_t nr) {fNrBad=nr;}
27
28     UInt_t GetNrBad() const {return fNrBad;}
29     Int_t  GetKeyAt(UInt_t index) const; //returns -1 if out of bounds
30
31     void   ClearBad() {fBadChannels.Reset(); fNrBad=0;}
32
33     Bool_t IsActiveEq() const;
34     Bool_t IsActiveHS(UInt_t hs) const;
35     Bool_t IsActiveChip(UInt_t hs, UInt_t chip) const;
36
37     void   ActivateALL();
38     void   ActivateEq(Bool_t setval = kTRUE);
39     void   ActivateHS(UInt_t hs, Bool_t setval = kTRUE);
40     void   ActivateChip(UInt_t hs, UInt_t chip, Bool_t setval = kTRUE);
41
42  private:
43     UInt_t   fEqNr;            // eq nr
44     UInt_t   fNrBad;           // nr of bad pixels
45     TArrayI  fBadChannels;     // array of keys for the bad
46     Bool_t   fActiveEq;        // active bit for each equipment
47     Bool_t   fActiveHS[6];     // active bit for each half-stave
48     Bool_t   fActiveChip[60];  // active bit for each chip
49
50     ClassDef(AliITSOnlineCalibrationSPD,2)
51 };
52
53 #endif