Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2022-04-20 23:56:37

0001 #ifndef Framework_TestBeginEndJobAnalyzer_h
0002 #define Framework_TestBeginEndJobAnalyzer_h
0003 // -*- C++ -*-
0004 //
0005 // Package:     test
0006 // Class  :     TestBeginEndJobAnalyzer
0007 //
0008 /**\class TestBeginEndJobAnalyzer TestBeginEndJobAnalyzer.h Framework/test/interface/TestBeginEndJobAnalyzer.h
0009 
0010  Description: <one line class summary>
0011 
0012  Usage:
0013     <usage>
0014 
0015 */
0016 //
0017 // Original Author:  Chris Jones
0018 //         Created:  Fri Sep  2 14:17:17 EDT 2005
0019 //
0020 
0021 // system include files
0022 #include "FWCore/Framework/interface/one/EDAnalyzer.h"
0023 // user include files
0024 
0025 // forward declarations
0026 class TestBeginEndJobAnalyzer : public edm::one::EDAnalyzer<edm::one::WatchRuns, edm::one::WatchLuminosityBlocks> {
0027 public:
0028   explicit TestBeginEndJobAnalyzer(const edm::ParameterSet&);
0029   ~TestBeginEndJobAnalyzer();
0030 
0031   void analyze(const edm::Event&, const edm::EventSetup&) override;
0032 
0033   void beginJob() override;
0034   void endJob() override;
0035   void beginRun(edm::Run const&, edm::EventSetup const&) override;
0036   void endRun(edm::Run const&, edm::EventSetup const&) override;
0037   void beginLuminosityBlock(edm::LuminosityBlock const&, edm::EventSetup const&) override;
0038   void endLuminosityBlock(edm::LuminosityBlock const&, edm::EventSetup const&) override;
0039 
0040   struct Control {
0041     bool beginJobCalled = false;
0042     bool endJobCalled = false;
0043     bool beginRunCalled = false;
0044     bool endRunCalled = false;
0045     bool beginLumiCalled = false;
0046     bool endLumiCalled = false;
0047     bool destructorCalled = false;
0048   };
0049 
0050   static Control& control();
0051 
0052 private:
0053   // ----------member data ---------------------------
0054 };
0055 
0056 #endif /* test_TestBeginEndJobAnalyzer_h */