CMS 3D CMS Logo

/data/refman/pasoursint/CMSSW_6_1_2_SLHC4_patch1/src/DQM/DTMonitorClient/src/DTDataIntegrityTest.h

Go to the documentation of this file.
00001 #ifndef DTDataIntegrity_Test_H
00002 #define DTDataIntegrity_Test_H
00003 
00013 #include <FWCore/Framework/interface/EDAnalyzer.h>
00014 #include "FWCore/ParameterSet/interface/ParameterSet.h"
00015 #include <FWCore/Framework/interface/Event.h>
00016 #include "FWCore/Framework/interface/ESHandle.h"
00017 #include <FWCore/Framework/interface/EventSetup.h>
00018 #include <FWCore/Framework/interface/LuminosityBlock.h>
00019 
00020 class DQMStore;
00021 class MonitorElement;
00022 class DTReadOutMapping;
00023 
00024 class DTDataIntegrityTest: public edm::EDAnalyzer{
00025 
00026 public:
00027 
00029   DTDataIntegrityTest(const edm::ParameterSet& ps);
00030 
00032  ~DTDataIntegrityTest();
00033 
00034 protected:
00035 
00037   void beginJob();
00038 
00040   void beginRun(const edm::Run& run, const edm::EventSetup& c);
00041  
00043   void analyze(const edm::Event& e, const edm::EventSetup& c);
00044 
00046   void endJob();
00047 
00049   std::string getMEName(std::string histoType, int FEDId);
00051   void bookHistos(std::string histoType, int dduId);
00052 
00053   void beginLuminosityBlock(edm::LuminosityBlock const& lumiSeg, edm::EventSetup const& context) ;
00054 
00056   void endLuminosityBlock(edm::LuminosityBlock const& lumiSeg, edm::EventSetup const& c);
00057 
00058 private:
00059   int readOutToGeometry(int dduId, int rosNumber, int& wheel, int& sector);
00060 
00061 private:
00062 
00063   //Number of onUpdates
00064   int nupdates;
00065 
00066   // prescale on the # of LS to update the test
00067   int prescaleFactor;
00068 
00069 
00070   //Counter between 0 and nTimeBin
00071   int counter;
00072 
00073   int nevents;
00074   unsigned int nLumiSegs;
00075 
00076   int run;
00077 
00078 
00079   DQMStore* dbe;
00080   edm::ESHandle<DTReadOutMapping> mapping;
00081   
00082 
00083   // Monitor Elements
00084   // <histoType, <DDU index , histo> >    
00085   std::map<std::string, std::map<int, MonitorElement*> > dduHistos;
00086   // <histoType, <DDU index , vector of histos> >    
00087   std::map<std::string, std::map<int, std::vector <MonitorElement*> > > dduVectorHistos;
00088 
00089   MonitorElement *summaryHisto;
00090   MonitorElement *summaryTDCHisto;
00091   MonitorElement *glbSummaryHisto;
00092  };
00093 
00094 #endif