CMS 3D CMS Logo

/data/refman/pasoursint/CMSSW_5_3_9_patch3/src/DQM/HcalMonitorClient/interface/HcalMonitorClient.h

Go to the documentation of this file.
00001 #ifndef HcalMonitorClient_GUARD_H
00002 #define HcalMonitorClient_GUARD_H
00003 
00004 /*
00005  * \file HcalMonitorClient.h
00006  * 
00007  * $Date: 2011/04/12 18:25:42 $
00008  * $Revision: 1.49 $
00009  * \author J. Temple
00010  * 
00011  */
00012 
00013 #include "FWCore/Framework/interface/Event.h"
00014 #include "FWCore/Framework/interface/EventSetup.h"
00015 #include "FWCore/ParameterSet/interface/ParameterSet.h"
00016 #include "FWCore/Framework/interface/EDAnalyzer.h"
00017 #include "CalibFormats/HcalObjects/interface/HcalDbService.h"
00018 
00019 #include "DQM/HcalMonitorClient/interface/HcalBaseDQClient.h"
00020 #include "DQM/HcalMonitorTasks/interface/HcalEtaPhiHists.h"
00021 
00022 class DQMStore;
00023 class HcalChannelQuality;
00024 class HcalSummaryClient;
00025 
00026 class HcalMonitorClient: public edm::EDAnalyzer
00027 {
00028 
00029 public:
00030 
00031   // Constructor
00032   HcalMonitorClient(const edm::ParameterSet & ps);
00033   
00034   // Destructor
00035   virtual ~HcalMonitorClient();
00036 
00038   void analyze(int LS=-1);
00039   void analyze(const edm::Event & e, const edm::EventSetup & c);
00040   
00042   void beginJob(void);
00043   
00045   void endJob(void);
00046   
00048   void beginRun();
00049   void beginRun(const edm::Run & r, const edm::EventSetup & c);
00050   
00052   void endRun();
00053   void endRun(const edm::Run & r, const edm::EventSetup & c);
00054   
00056   void beginLuminosityBlock(const edm::LuminosityBlock & l, const edm::EventSetup & c);
00057   
00059   void endLuminosityBlock(const edm::LuminosityBlock & l, const edm::EventSetup & c);
00060   
00062   void reset(void);
00063   
00065   void setup(void);
00066   
00068   void cleanup(void);
00069   
00071   void softReset(bool flag);
00072  
00073   // Write channelStatus info
00074   void writeChannelStatus();
00075   
00076   // Write html output
00077   void writeHtml();
00078 
00079   void PlotPedestalValues(const HcalDbService& cond);
00080 
00081 private:
00082   // Event counters
00083   int ievt_; // all events
00084   int jevt_; // events in current run
00085   int run_;
00086   int evt_;
00087   bool begin_run_;
00088   bool end_run_;
00089 
00090   // parameter set inputs
00091   int debug_;
00092   std::string inputFile_;
00093   bool mergeRuns_;
00094   bool cloneME_;
00095   int prescaleFactor_;
00096   std::string prefixME_;
00097   bool enableCleanup_;
00098   std::vector<std::string > enabledClients_;
00099 
00100   int updateTime_; // update time for updating histograms 
00101   std::string baseHtmlDir_;
00102   int htmlUpdateTime_; //update time for updating histograms
00103   std::string databasedir_;
00104   int databaseUpdateTime_; //update time for dumping db info (offset by 10 minutes, so that always dump after 10 minutes)
00105   int databaseFirstUpdate_; // first update time (in minutes)
00106   int htmlFirstUpdate_; // first update for html
00107   
00108   int htmlcounter_;
00109 
00110   bool saveByLumiSection_;  //produces separate LS certification values when enabled
00111   bool Online_;  // fix to April 2011 problem where online DQM client crashes in endJob.  Is endRun perhaps not called?
00112 
00113   // time parameters
00114   time_t current_time_;
00115   time_t last_time_update_;
00116   time_t last_time_html_;
00117   time_t last_time_db_;
00118 
00119   std::vector<HcalBaseDQClient*> clients_;  
00120 
00121   DQMStore* dqmStore_;
00122   HcalChannelQuality* chanquality_;
00123 
00124   HcalSummaryClient* summaryClient_;
00125   EtaPhiHists* ChannelStatus;
00126   EtaPhiHists* ADC_PedestalFromDBByDepth;
00127   EtaPhiHists* ADC_WidthFromDBByDepth;
00128   EtaPhiHists* fC_PedestalFromDBByDepth;
00129   EtaPhiHists* fC_WidthFromDBByDepth;
00130 
00131 };
00132 
00133 #endif