Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2024-04-06 12:06:58

0001 /*
0002  * =====================================================================================
0003  *
0004  *       Filename:  CSCOfflineClient.h
0005  *
0006  *    Description:  CSC Offline module that preocess merged histograms and
0007  *    creates/updates fractional and efficiency objects.
0008  *
0009  *        Version:  1.0
0010  *        Created:  09/20/2009 01:36:45 PM
0011  *       Revision:  none
0012  *       Compiler:  gcc
0013  *
0014  *         Author:  Valdas Rapsevicius (VR), valdas.rapsevicius@cern.ch
0015  *        Company:  CERN, CH
0016  *
0017  * =====================================================================================
0018  */
0019 
0020 #ifndef CSCOfflineClient_H
0021 #define CSCOfflineClient_H
0022 
0023 /// Global stuff
0024 #include <iostream>
0025 #include <cstring>
0026 #include <vector>
0027 #include <map>
0028 #include <set>
0029 
0030 /// DQM Framework stuff
0031 #include <FWCore/ParameterSet/interface/ParameterSet.h>
0032 
0033 #include <DQMServices/Core/interface/DQMStore.h>
0034 #include "DQMServices/Core/interface/DQMEDHarvester.h"
0035 
0036 #include <FWCore/ServiceRegistry/interface/Service.h>
0037 #include <FWCore/Framework/interface/ESHandle.h>
0038 #include <FWCore/Framework/interface/EventSetup.h>
0039 
0040 /// CSC Framework stuff
0041 #include "DataFormats/MuonDetId/interface/CSCDetId.h"
0042 #include "CondFormats/CSCObjects/interface/CSCCrateMap.h"
0043 #include "CondFormats/DataRecord/interface/CSCCrateMapRcd.h"
0044 
0045 /// CSCDQM Framework stuff
0046 #include "CSCDQM_Logger.h"
0047 #include "CSCDQM_Configuration.h"
0048 #include "CSCDQM_Dispatcher.h"
0049 #include "CSCMonitorModule.h"
0050 
0051 /// Local stuff
0052 #include "CSCMonitorObject.h"
0053 
0054 /// Local Constants
0055 //static const char DIR_EVENTINFO[]        = "CSC/EventInfo/";
0056 //static const char DIR_DCSINFO[]          = "CSC/EventInfo/DCSContents/";
0057 //static const char DIR_DAQINFO[]          = "CSC/EventInfo/DAQContents/";
0058 //static const char DIR_CRTINFO[]          = "CSC/EventInfo/CertificationContents/";
0059 
0060 /**
0061  * @class CSCOfflineClient
0062  * @brief CSC Offline DQM Client that uses CSCDQM Framework 
0063  */
0064 class CSCOfflineClient : public DQMEDHarvester, public cscdqm::MonitorObjectProvider {
0065   /**
0066    * Global stuff
0067    */
0068 
0069 public:
0070   CSCOfflineClient(const edm::ParameterSet &ps);
0071   ~CSCOfflineClient() override;
0072 
0073 private:
0074   cscdqm::Configuration config;
0075   cscdqm::Dispatcher *dispatcher;
0076   // DQMStore                 *dbe;
0077   DQMStore::IBooker *ibooker;
0078   std::vector<std::string> maskedHW;
0079 
0080   /**
0081    * MonitorObjectProvider Implementation
0082    */
0083 
0084 public:
0085   bool getCSCDetId(const unsigned int crateId, const unsigned int dmbId, CSCDetId &detId) const override {
0086     return false;
0087   }
0088   cscdqm::MonitorObject *bookMonitorObject(const cscdqm::HistoBookRequest &p_req) override;
0089 
0090   /** 
0091    * EDAnalyzer Implementation
0092    */
0093 
0094 protected:
0095   // void beginJob() { }
0096   // void beginRun(const edm::Run& r, const edm::EventSetup& c) { }
0097   void setup() {}
0098   //void analyze(const edm::Event& e, const edm::EventSetup& c) { }
0099   // void beginLuminosityBlock(const edm::LuminosityBlock& lumiSeg, const edm::EventSetup& context) { }
0100   // void endLuminosityBlock(edm::LuminosityBlock const& lumiSeg, edm::EventSetup const& iSetup) { }
0101   // void endRun(const edm::Run& r, const edm::EventSetup& c);
0102   // void endJob() { }
0103   void dqmEndJob(DQMStore::IBooker &, DQMStore::IGetter &) override;  //performed in the endJob
0104 };
0105 
0106 #endif