CMS 3D CMS Logo

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