CMS 3D CMS Logo

ElectronDqmAnalyzerBase.h
Go to the documentation of this file.
1 
2 #ifndef ElectronDqmAnalyzerBase_h
3 #define ElectronDqmAnalyzerBase_h
4 
5 class DQMStore ;
6 class MonitorElement ;
7 
10 #include <Rtypes.h>
11 #include <string>
12 #include <vector>
13 
14 //DQM
18 
19 namespace edab {
20  struct Empty {};
21 }
23  {
24 
25  protected:
26 
27  explicit ElectronDqmAnalyzerBase( const edm::ParameterSet & conf ) ;
28  ~ElectronDqmAnalyzerBase() override ;
29 
30  // specific implementation of EDAnalyzer
31  void bookHistograms( DQMStore::IBooker &, edm::Run const &, edm::EventSetup const &) override;
32 
33  // interface to implement in derived classes
34  void analyze( const edm::Event & e, const edm::EventSetup & c ) override {}
35 
36  // utility methods
37  int verbosity() { return verbosity_ ; }
38 
39  void setBookPrefix( const std::string & ) ;
40  void setBookIndex( short ) ;
41  void setBookEfficiencyFlag( const bool & ) ;
42  void setBookStatOverflowFlag ( const bool & ) ;
43 
44  MonitorElement * bookH1
45  ( DQMStore::IBooker & , const std::string & name, const std::string & title,
46  int nchX, double lowX, double highX,
47  const std::string & titleX ="", const std::string & titleY ="Events",
48  Option_t * option = "E1 P" ) ;
49 
50  MonitorElement * bookH1withSumw2
51  ( DQMStore::IBooker & , const std::string & name, const std::string & title,
52  int nchX, double lowX, double highX,
53  const std::string & titleX ="", const std::string & titleY ="Events",
54  Option_t * option = "E1 P" ) ;
55 
56  MonitorElement * bookH2
57  ( DQMStore::IBooker & , const std::string & name, const std::string & title,
58  int nchX, double lowX, double highX,
59  int nchY, double lowY, double highY,
60  const std::string & titleX ="", const std::string & titleY ="",
61  Option_t * option = "COLZ" ) ;
62 
63  MonitorElement * bookH2withSumw2
64  ( DQMStore::IBooker & , const std::string & name, const std::string & title,
65  int nchX, double lowX, double highX,
66  int nchY, double lowY, double highY,
67  const std::string & titleX ="", const std::string & titleY ="",
68  Option_t * option = "COLZ" ) ;
69 
70  MonitorElement * bookP1
71  ( DQMStore::IBooker & , const std::string & name, const std::string & title,
72  int nchX, double lowX, double highX,
73  double lowY, double highY,
74  const std::string & titleX ="", const std::string & titleY ="",
75  Option_t * option = "E1 P" ) ;
76 
77  MonitorElement * cloneH1
78  ( DQMStore::IBooker & iBooker, const std::string & name, MonitorElement * original,
79  const std::string & title ="" ) ;
80 
81  MonitorElement * cloneH1
82  ( DQMStore::IBooker & iBooker, const std::string & name, const std::string & original,
83  const std::string & title ="" ) ;
84 
85  private:
86 
87  int verbosity_ ;
89  short bookIndex_ ;
90  bool bookEfficiencyFlag_ = false;
91  bool bookStatOverflowFlag_ = false;
93  std::vector<std::string> histoNames_ ;
99 
100  // utility methods
101  std::string newName( const std::string & name ) ;
102  } ;
103 
104 #endif
105 
106 
107 
string newName
Definition: mps_merge.py:86
void analyze(const edm::Event &e, const edm::EventSetup &c) override
std::vector< std::string > histoNames_
example_stream void bookHistograms(DQMStore::IBooker &,@example_stream edm::Run const &,@example_stream edm::EventSetup const &) override
Definition: Run.h:45