CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
HcalPedestal.h
Go to the documentation of this file.
1 #ifndef HcalPedestal_h
2 #define HcalPedestal_h
3 
12 #include <boost/cstdint.hpp>
13 
14 class HcalPedestal {
15  public:
17  const float* getValues () const {return &mValue0;}
19  float getValue (int fCapId) const {return *(getValues () + fCapId);}
20 
22  const float* getWidths () const {return &mWidth0;}
24  float getWidth (int fCapId) const {return *(getWidths () + fCapId);}
25 
26  // functions below are not supposed to be used by consumer applications
27 
28  HcalPedestal () : mId (0), mValue0 (0), mValue1 (0), mValue2 (0), mValue3 (0),
29  mWidth0 (0), mWidth1 (0), mWidth2 (0), mWidth3 (0) {}
30 
31  HcalPedestal (unsigned long fId, float fCap0, float fCap1, float fCap2, float fCap3,
32  float wCap0 = 0, float wCap1 = 0, float wCap2 = 0, float wCap3 = 0) :
33  mId (fId), mValue0 (fCap0), mValue1 (fCap1), mValue2 (fCap2), mValue3 (fCap3),
34  mWidth0 (wCap0), mWidth1 (wCap1), mWidth2 (wCap2), mWidth3 (wCap3) {}
35 
36  uint32_t rawId () const {return mId;}
37  private:
38  uint32_t mId;
39  float mValue0;
40  float mValue1;
41  float mValue2;
42  float mValue3;
43  float mWidth0;
44  float mWidth1;
45  float mWidth2;
46  float mWidth3;
47 };
48 
49 #endif
float getWidth(int fCapId) const
get width for capId = 0..3
Definition: HcalPedestal.h:24
uint32_t rawId() const
Definition: HcalPedestal.h:36
const float * getWidths() const
get width for all capId = 0..3
Definition: HcalPedestal.h:22
float getValue(int fCapId) const
get value for capId = 0..3
Definition: HcalPedestal.h:19
HcalPedestal(unsigned long fId, float fCap0, float fCap1, float fCap2, float fCap3, float wCap0=0, float wCap1=0, float wCap2=0, float wCap3=0)
Definition: HcalPedestal.h:31
uint32_t mId
Definition: HcalPedestal.h:38
const float * getValues() const
get value for all capId = 0..3
Definition: HcalPedestal.h:17