StRoot  1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
StSvtHybridBadAnodes.hh
1 /***************************************************************************
2  *
3  * $Id: StSvtHybridBadAnodes.hh,v 1.1 2002/02/15 22:44:07 munhoz Exp $
4  *
5  * Author: Marcelo Munhoz
6  *
7  ***************************************************************************
8  *
9  * Description: Flags Bad anodes on hybrids
10  *
11  ***************************************************************************/
12 
13 #ifndef STSVTHYBRIDBADANODE_HH
14 #define STSVTHYBRIDBADANODE_HH
15 
16 #include "StSvtClassLibrary/StSvtHybridObject.hh"
17 
18 #define MAX_NUMBER_OF_ANODES 240
19 
21 {
22 public:
24  StSvtHybridBadAnodes(int barrel, int ladder, int wafer, int hybrid);
26 
27  void setBadAnode(int anode);
28  void setNotBadAnode(int anode);
29  Bool_t isBadAnode(int anode);
30  void reset();
31 
32  void addOverloadedAdc(int anode, Bool_t isBad, int nEvents);
33  void addNullAdc(int anode, Bool_t isBad, int nEvents);
34  void addHighOccup(int anode, Bool_t isBad, int nEvents);
35  void addBadRMS(int anode, Bool_t isBad, int nEvents);
36 
37  float getOverloadedAdc(int anode){return mOverloadedAdc[anode-1];}
38  float getNullAdc(int anode){return mNullAdc[anode-1];}
39  float getHighOccup(int anode){return mHighOccup[anode-1];}
40  float getBadRMS(int anode){return mBadRMS[anode-1];}
41 
42 protected:
43 
44  Bool_t mBadAnode[MAX_NUMBER_OF_ANODES];
45  int mNBadAnodes;
46 
47  // fraction of events that anode is bad
48  float mOverloadedAdc[MAX_NUMBER_OF_ANODES];
49  float mNullAdc[MAX_NUMBER_OF_ANODES];
50  float mHighOccup[MAX_NUMBER_OF_ANODES];
51  float mBadRMS[MAX_NUMBER_OF_ANODES];
52 };
53 
54 #endif