CMS 3D CMS Logo

ProfilerAnalyzer.cc
Go to the documentation of this file.
1 // -*- C++ -*-
2 //
3 // Package: PerfTools/Callgrind
4 // Class: ProfilerAnalyzer
5 //
18 //
19 // Original Author: Andrea Rizzi
20 // Created: Thu Jan 18 10:34:18 CET 2007
21 
22 // system include files
23 
24 // user include files
27 
29 
32 
33 //
34 // class declaration
35 //
37 public:
38  explicit ProfilerAnalyzer(const edm::ParameterSet&);
39  ~ProfilerAnalyzer() override;
40 
41 private:
42  void beginJob() override;
43  void analyze(const edm::Event&, const edm::EventSetup&) override = 0;
44  void endJob() override;
45 };
46 
48 public:
50  ~StartProfilerAnalyzer() override {}
51 
52 private:
53  void analyze(const edm::Event&, const edm::EventSetup&) override;
54 };
55 
57 public:
59  ~StopProfilerAnalyzer() override {}
60 
61 private:
62  void analyze(const edm::Event&, const edm::EventSetup&) override;
63 };
64 
65 //
66 // constants, enums and typedefs
67 //
68 
69 //
70 // static data member definitions
71 //
72 
73 //
74 // constructors and destructor
75 //
77 
79  // do anything here that needs to be done at desctruction time
80  // (e.g. close files, deallocate resources etc.)
81 }
82 
83 //
84 // member functions
85 //
86 
87 // ------------ method called to for each event ------------
89  edm::Service<ProfilerService>()->startInstrumentation();
90 }
92  edm::Service<ProfilerService>()->stopInstrumentation();
93 }
94 
95 // ------------ method called once each job just before starting event loop ------------
97 
98 // ------------ method called once each job just after ending the event loop ------------
100 
101 //define this as a plug-in
StopProfilerAnalyzer(const edm::ParameterSet &pset)
~StartProfilerAnalyzer() override
void endJob() override
~ProfilerAnalyzer() override
void analyze(const edm::Event &, const edm::EventSetup &) override
#define DEFINE_FWK_MODULE(type)
Definition: MakerMacros.h:16
void analyze(const edm::Event &, const edm::EventSetup &) override
~StopProfilerAnalyzer() override
ProfilerAnalyzer(const edm::ParameterSet &)
void beginJob() override
StartProfilerAnalyzer(const edm::ParameterSet &pset)
void analyze(const edm::Event &, const edm::EventSetup &) override=0