CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
CSCMonitorModule.h
Go to the documentation of this file.
1 /*
2  * =====================================================================================
3  *
4  * Filename: CSCMonitorModule.h
5  *
6  * Description: Updated CSC Monitor module
7  *
8  * Version: 1.0
9  * Created: 11/13/2008 01:36:45 PM
10  * Revision: none
11  * Compiler: gcc
12  *
13  * Author: Valdas Rapsevicius (VR), valdas.rapsevicius@cern.ch
14  * Company: CERN, CH
15  *
16  * =====================================================================================
17  */
18 
19 
20 #ifndef CSCMonitorModule_H
21 #define CSCMonitorModule_H
22 
24 #include <iostream>
25 #include <cstring>
26 #include <vector>
27 #include <map>
28 #include <set>
29 
38 
44 
49 
52 
54 static const char INPUT_TAG_LABEL[] = "source";
55 static const char DIR_EVENTINFO[] = "CSC/EventInfo/";
56 static const char DIR_DCSINFO[] = "CSC/EventInfo/DCSContents/";
57 static const char DIR_DAQINFO[] = "CSC/EventInfo/DAQContents/";
58 static const char DIR_CRTINFO[] = "CSC/EventInfo/CertificationContents/";
59 
60 static const unsigned int MIN_CRATE_ID = 1;
61 static const unsigned int MAX_CRATE_ID = 60;
62 static const unsigned int MIN_DMB_SLOT = 1;
63 static const unsigned int MAX_DMB_SLOT = 10;
64 
70 
75  public:
76 
78  virtual ~CSCMonitorModule();
79 
80  private:
81 
88 
91 
96  public:
97 
98  bool getCSCDetId(const unsigned int crateId, const unsigned int dmbId, CSCDetId& detId) const {
99  // Check parameter values
100  if (crateId < MIN_CRATE_ID || crateId > MAX_CRATE_ID || dmbId < MIN_DMB_SLOT || dmbId > MAX_DMB_SLOT) {
101  return false;
102  }
103  detId = pcrate->detId(crateId, dmbId, 0, 0);
104  return (detId.rawId() != 0);
105  }
106 
108 
113  protected:
114 
115  void beginJob() { }
116  void beginRun(const edm::Run& r, const edm::EventSetup& c);
117  void setup() { }
118  void analyze(const edm::Event& e, const edm::EventSetup& c);
119  void beginLuminosityBlock(const edm::LuminosityBlock& lumiSeg, const edm::EventSetup& context) { }
120  void endRun(const edm::Run& r, const edm::EventSetup& c) { }
121  void endJob() { }
122 
123 };
124 
125 #endif
cscdqm::Configuration config
static const unsigned int MAX_CRATE_ID
static const char DIR_DAQINFO[]
CSCMonitorModule(const edm::ParameterSet &ps)
Constructor.
Monitoring Object interface used to cover Root object and provide common interface to EventProcessor ...
CSCDetId detId(int vme, int dmb, int cfeb, int layer=0) const
Definition: CSCCrateMap.cc:11
virtual ~CSCMonitorModule()
Destructor.
cscdqm::Dispatcher * dispatcher
CSCDQM Framework frontend and Histogram Cache controller.
Common CSC DQM Module that uses CSCDQM Framework.
void beginRun(const edm::Run &r, const edm::EventSetup &c)
Begin the run.
uint32_t rawId() const
get the raw id
Definition: DetId.h:45
CSCDQM Framework Global Configuration.
void analyze(const edm::Event &e, const edm::EventSetup &c)
Analyze Event.
cscdqm::MonitorObject * bookMonitorObject(const cscdqm::HistoBookRequest &p_req)
Book Monitor Object on Request.
static const unsigned int MIN_CRATE_ID
static const char DIR_DCSINFO[]
const CSCCrateMap * pcrate
static const char INPUT_TAG_LABEL[]
Global stuff.
static const char DIR_EVENTINFO[]
edm::InputTag inputTag
static const unsigned int MIN_DMB_SLOT
bool getCSCDetId(const unsigned int crateId, const unsigned int dmbId, CSCDetId &detId) const
static const char DIR_CRTINFO[]
void beginLuminosityBlock(const edm::LuminosityBlock &lumiSeg, const edm::EventSetup &context)
Interface for Histogram providing objects. Used by Event Processor to retrieve MonitorObject &#39;s and b...
static const unsigned int MAX_DMB_SLOT
void endRun(const edm::Run &r, const edm::EventSetup &c)
Definition: Run.h:32