CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Classes | Static Public Member Functions | Private Member Functions | Static Private Member Functions | Static Private Attributes
EcalDQMStatusDictionary Class Reference

#include <EcalDQMStatusDictionary.h>

Classes

struct  codeDef
 

Static Public Member Functions

static void getCodes (std::vector< codeDef > &codeVec, uint32_t code)
 
static void getDictionary (std::vector< codeDef > &dict)
 

Private Member Functions

 EcalDQMStatusDictionary ()
 
 ~EcalDQMStatusDictionary ()
 

Static Private Member Functions

static codeDef getDef (unsigned int i)
 

Static Private Attributes

static const unsigned int DICTSIZE1 = 30
 
static const unsigned int DICTSIZE2 = 7
 

Detailed Description

Definition at line 16 of file EcalDQMStatusDictionary.h.

Constructor & Destructor Documentation

EcalDQMStatusDictionary::EcalDQMStatusDictionary ( )
inlineprivate

Definition at line 41 of file EcalDQMStatusDictionary.h.

41 {}; // Hidden to force static use
EcalDQMStatusDictionary::~EcalDQMStatusDictionary ( )
inlineprivate

Definition at line 42 of file EcalDQMStatusDictionary.h.

42 {}; // Hidden to force static use

Member Function Documentation

static void EcalDQMStatusDictionary::getCodes ( std::vector< codeDef > &  codeVec,
uint32_t  code 
)
inlinestatic

Definition at line 30 of file EcalDQMStatusDictionary.h.

References DICTSIZE1, DICTSIZE2, getDef(), and i.

Referenced by EcalDQMStatusReader::beginRun().

30  {
31  codeVec.clear();
32  for (unsigned int i=0; i<DICTSIZE1+DICTSIZE2; i++) {
33  if (code & getDef(i).code) {
34  codeVec.push_back(getDef(i));
35  }
36  }
37  }
int i
Definition: DBlmapReader.cc:9
static const unsigned int DICTSIZE2
static const unsigned int DICTSIZE1
static codeDef getDef(unsigned int i)
static codeDef EcalDQMStatusDictionary::getDef ( unsigned int  i)
inlinestaticprivate

Definition at line 47 of file EcalDQMStatusDictionary.h.

References EcalDQMStatusHelper::CH_GAIN_SWITCH_ERROR, EcalDQMStatusHelper::CH_GAIN_ZERO_ERROR, EcalDQMStatusHelper::CH_ID_ERROR, DICTSIZE1, DICTSIZE2, i, EcalDQMStatusHelper::LASER_MEAN_ERROR, EcalDQMStatusHelper::LASER_RMS_ERROR, EcalDQMStatusHelper::LASER_TIMING_MEAN_ERROR, EcalDQMStatusHelper::LASER_TIMING_RMS_ERROR, EcalDQMStatusHelper::LED_MEAN_ERROR, EcalDQMStatusHelper::LED_RMS_ERROR, EcalDQMStatusHelper::LED_TIMING_MEAN_ERROR, EcalDQMStatusHelper::LED_TIMING_RMS_ERROR, EcalDQMStatusHelper::PEDESTAL_HIGH_GAIN_MEAN_ERROR, EcalDQMStatusHelper::PEDESTAL_HIGH_GAIN_RMS_ERROR, EcalDQMStatusHelper::PEDESTAL_LOW_GAIN_MEAN_ERROR, EcalDQMStatusHelper::PEDESTAL_LOW_GAIN_RMS_ERROR, EcalDQMStatusHelper::PEDESTAL_MIDDLE_GAIN_MEAN_ERROR, EcalDQMStatusHelper::PEDESTAL_MIDDLE_GAIN_RMS_ERROR, EcalDQMStatusHelper::PEDESTAL_ONLINE_HIGH_GAIN_MEAN_ERROR, EcalDQMStatusHelper::PEDESTAL_ONLINE_HIGH_GAIN_RMS_ERROR, EcalDQMStatusHelper::PHYSICS_BAD_CHANNEL_ERROR, EcalDQMStatusHelper::PHYSICS_BAD_CHANNEL_WARNING, EcalDQMStatusHelper::STATUS_FLAG_ERROR, EcalDQMStatusHelper::TESTPULSE_HIGH_GAIN_MEAN_ERROR, EcalDQMStatusHelper::TESTPULSE_HIGH_GAIN_RMS_ERROR, EcalDQMStatusHelper::TESTPULSE_LOW_GAIN_MEAN_ERROR, EcalDQMStatusHelper::TESTPULSE_LOW_GAIN_RMS_ERROR, EcalDQMStatusHelper::TESTPULSE_MIDDLE_GAIN_MEAN_ERROR, EcalDQMStatusHelper::TESTPULSE_MIDDLE_GAIN_RMS_ERROR, EcalDQMStatusHelper::TT_ID_ERROR, and EcalDQMStatusHelper::TT_SIZE_ERROR.

Referenced by getCodes(), and getDictionary().

47  {
48  const static codeDef DICT[DICTSIZE1+DICTSIZE2] =
49  {
50 
51  // single status codes
52 
53  { ((uint32_t) 1 << EcalDQMStatusHelper::CH_ID_ERROR), "CH_ID_ERROR" },
54  { ((uint32_t) 1 << EcalDQMStatusHelper::CH_GAIN_ZERO_ERROR), "CH_GAIN_ZERO_ERROR" },
55  { ((uint32_t) 1 << EcalDQMStatusHelper::CH_GAIN_SWITCH_ERROR), "CH_GAIN_SWITCH_ERROR" },
56  { ((uint32_t) 1 << EcalDQMStatusHelper::TT_ID_ERROR), "TT_ID_ERROR"},
57  { ((uint32_t) 1 << EcalDQMStatusHelper::TT_SIZE_ERROR), "TT_SIZE_ERROR"},
58 
59  { ((uint32_t) 1 << EcalDQMStatusHelper::PEDESTAL_LOW_GAIN_MEAN_ERROR), "PEDESTAL_LOW_GAIN_MEAN_ERROR"},
60  { ((uint32_t) 1 << EcalDQMStatusHelper::PEDESTAL_MIDDLE_GAIN_MEAN_ERROR), "PEDESTAL_MIDDLE_GAIN_MEAN_ERROR"},
61  { ((uint32_t) 1 << EcalDQMStatusHelper::PEDESTAL_HIGH_GAIN_MEAN_ERROR), "PEDESTAL_HIGH_GAIN_MEAN_ERROR"},
62  { ((uint32_t) 1 << EcalDQMStatusHelper::PEDESTAL_LOW_GAIN_RMS_ERROR), "PEDESTAL_LOW_GAIN_RMS_ERROR"},
63  { ((uint32_t) 1 << EcalDQMStatusHelper::PEDESTAL_MIDDLE_GAIN_RMS_ERROR), "PEDESTAL_MIDDLE_GAIN_RMS_ERROR"},
64  { ((uint32_t) 1 << EcalDQMStatusHelper::PEDESTAL_HIGH_GAIN_RMS_ERROR), "PEDESTAL_HIGH_GAIN_RMS_ERROR"},
65 
66  { ((uint32_t) 1 << EcalDQMStatusHelper::PEDESTAL_ONLINE_HIGH_GAIN_MEAN_ERROR), "PEDESTAL_ONLINE_HIGH_GAIN_MEAN_ERROR"},
67  { ((uint32_t) 1 << EcalDQMStatusHelper::PEDESTAL_ONLINE_HIGH_GAIN_RMS_ERROR), "PEDESTAL_ONLINE_HIGH_GAIN_RMS_ERROR"},
68 
69  { ((uint32_t) 1 << EcalDQMStatusHelper::TESTPULSE_LOW_GAIN_MEAN_ERROR), "TESTPULSE_LOW_GAIN_MEAN_ERROR"},
70  { ((uint32_t) 1 << EcalDQMStatusHelper::TESTPULSE_MIDDLE_GAIN_MEAN_ERROR), "TESTPULSE_MIDDLE_GAIN_MEAN_ERROR"},
71  { ((uint32_t) 1 << EcalDQMStatusHelper::TESTPULSE_HIGH_GAIN_MEAN_ERROR), "TESTPULSE_HIGH_GAIN_MEAN_ERROR"},
72  { ((uint32_t) 1 << EcalDQMStatusHelper::TESTPULSE_LOW_GAIN_RMS_ERROR), "TESTPULSE_LOW_GAIN_RMS_ERROR"},
73  { ((uint32_t) 1 << EcalDQMStatusHelper::TESTPULSE_MIDDLE_GAIN_RMS_ERROR), "TESTPULSE_MIDDLE_GAIN_RMS_ERROR"},
74  { ((uint32_t) 1 << EcalDQMStatusHelper::TESTPULSE_HIGH_GAIN_RMS_ERROR), "TESTPULSE_HIGH_GAIN_RMS_ERROR"},
75 
76  { ((uint32_t) 1 << EcalDQMStatusHelper::LASER_MEAN_ERROR), "LASER_MEAN_ERROR"},
77  { ((uint32_t) 1 << EcalDQMStatusHelper::LASER_RMS_ERROR), "LASER_RMS_ERROR"},
78  { ((uint32_t) 1 << EcalDQMStatusHelper::LASER_TIMING_MEAN_ERROR), "LASER_TIMING_MEAN_ERROR"},
79  { ((uint32_t) 1 << EcalDQMStatusHelper::LASER_TIMING_RMS_ERROR), "LASER_TIMING_RMS_ERROR"},
80 
81  { ((uint32_t) 1 << EcalDQMStatusHelper::LED_MEAN_ERROR), "LED_MEAN_ERROR"},
82  { ((uint32_t) 1 << EcalDQMStatusHelper::LED_RMS_ERROR), "LED_RMS_ERROR"},
83  { ((uint32_t) 1 << EcalDQMStatusHelper::LED_TIMING_MEAN_ERROR), "LED_TIMING_MEAN_ERROR"},
84  { ((uint32_t) 1 << EcalDQMStatusHelper::LED_TIMING_RMS_ERROR), "LED_TIMING_RMS_ERROR"},
85 
86  { ((uint32_t) 1 << EcalDQMStatusHelper::STATUS_FLAG_ERROR), "STATUS_FLAG_ERROR"},
87 
88  { ((uint32_t) 1 << EcalDQMStatusHelper::PHYSICS_BAD_CHANNEL_WARNING), "PHYSICS_BAD_CHANNEL_WARNING"},
89  { ((uint32_t) 1 << EcalDQMStatusHelper::PHYSICS_BAD_CHANNEL_ERROR), "PHYSICS_BAD_CHANNEL_ERROR"},
90 
91  // combined status codes
92 
93  { ((uint32_t) 1 << EcalDQMStatusHelper::TT_SIZE_ERROR |
104  1 << EcalDQMStatusHelper::PHYSICS_BAD_CHANNEL_ERROR), "disabled_channel"},
105 
129  1 << EcalDQMStatusHelper::PHYSICS_BAD_CHANNEL_ERROR), "dead_channel"},
130 
139 
145  1 << EcalDQMStatusHelper::TESTPULSE_HIGH_GAIN_RMS_ERROR), "testpulse_problem"},
146 
147  { ((uint32_t) 1 << EcalDQMStatusHelper::LASER_MEAN_ERROR |
150  1 << EcalDQMStatusHelper::LASER_TIMING_RMS_ERROR), "laser_problem"},
151 
152  { ((uint32_t) 1 << EcalDQMStatusHelper::LED_MEAN_ERROR |
155  1 << EcalDQMStatusHelper::LED_TIMING_RMS_ERROR), "led_problem"},
156 
161  1 << EcalDQMStatusHelper::PHYSICS_BAD_CHANNEL_ERROR), "noise_problem"}
162 
163  };
164 
165  return DICT[i];
166  }
static const int LED_MEAN_ERROR
int i
Definition: DBlmapReader.cc:9
static const int PEDESTAL_MIDDLE_GAIN_RMS_ERROR
static const int LASER_MEAN_ERROR
static const int TESTPULSE_LOW_GAIN_RMS_ERROR
static const int PHYSICS_BAD_CHANNEL_WARNING
static const int LASER_TIMING_RMS_ERROR
static const int PEDESTAL_HIGH_GAIN_MEAN_ERROR
static const int PEDESTAL_ONLINE_HIGH_GAIN_RMS_ERROR
static const unsigned int DICTSIZE2
static const int PHYSICS_BAD_CHANNEL_ERROR
static const int TT_SIZE_ERROR
static const int CH_GAIN_SWITCH_ERROR
static const int TESTPULSE_MIDDLE_GAIN_MEAN_ERROR
static const int PEDESTAL_LOW_GAIN_RMS_ERROR
static const int PEDESTAL_HIGH_GAIN_RMS_ERROR
static const int STATUS_FLAG_ERROR
static const int TESTPULSE_MIDDLE_GAIN_RMS_ERROR
static const unsigned int DICTSIZE1
static const int TESTPULSE_HIGH_GAIN_RMS_ERROR
static const int LED_TIMING_MEAN_ERROR
static const int PEDESTAL_LOW_GAIN_MEAN_ERROR
static const int TESTPULSE_LOW_GAIN_MEAN_ERROR
static const int LED_TIMING_RMS_ERROR
static const int CH_GAIN_ZERO_ERROR
static const int PEDESTAL_ONLINE_HIGH_GAIN_MEAN_ERROR
static const int LASER_TIMING_MEAN_ERROR
static const int TT_ID_ERROR
static const int LED_RMS_ERROR
static const int PEDESTAL_MIDDLE_GAIN_MEAN_ERROR
static const int TESTPULSE_HIGH_GAIN_MEAN_ERROR
static const int LASER_RMS_ERROR
static const int CH_ID_ERROR
static void EcalDQMStatusDictionary::getDictionary ( std::vector< codeDef > &  dict)
inlinestatic

Definition at line 25 of file EcalDQMStatusDictionary.h.

References DICTSIZE1, DICTSIZE2, getDef(), and i.

Referenced by EcalDQMStatusReader::beginRun(), EcalDQMStatusWriter::readEcalDQMChannelStatusFromFile(), and EcalDQMStatusWriter::readEcalDQMTowerStatusFromFile().

25  {
26  dict.clear();
27  for (unsigned int i=0; i<DICTSIZE1+DICTSIZE2; i++) dict.push_back(getDef(i));
28  }
int i
Definition: DBlmapReader.cc:9
static const unsigned int DICTSIZE2
static const unsigned int DICTSIZE1
static codeDef getDef(unsigned int i)

Member Data Documentation

const unsigned int EcalDQMStatusDictionary::DICTSIZE1 = 30
staticprivate

Definition at line 44 of file EcalDQMStatusDictionary.h.

Referenced by getCodes(), getDef(), and getDictionary().

const unsigned int EcalDQMStatusDictionary::DICTSIZE2 = 7
staticprivate

Definition at line 45 of file EcalDQMStatusDictionary.h.

Referenced by getCodes(), getDef(), and getDictionary().