CMS 3D CMS Logo

List of all members | Public Member Functions | Static Public Member Functions | Private Member Functions | Private Attributes
DemoNormalDQMEDAnalyzer Class Reference

#include <DQMServices/Demo/plugins/DemoNormalDQMEDAnalyzer.cc>

Inheritance diagram for DemoNormalDQMEDAnalyzer:
DQMEDAnalyzer edm::stream::EDProducer< edm::GlobalCache< DQMEDAnalyzerGlobalCache >, edm::EndRunProducer, edm::EndLuminosityBlockProducer, edm::Accumulator >

Public Member Functions

 DemoNormalDQMEDAnalyzer (const edm::ParameterSet &)
 
 ~DemoNormalDQMEDAnalyzer () override
 
- Public Member Functions inherited from DQMEDAnalyzer
void accumulate (edm::Event const &event, edm::EventSetup const &setup) final
 
void beginLuminosityBlock (edm::LuminosityBlock const &lumi, edm::EventSetup const &setup) final
 
void beginRun (edm::Run const &run, edm::EventSetup const &setup) final
 
void beginStream (edm::StreamID id) final
 
virtual void dqmBeginRun (edm::Run const &, edm::EventSetup const &)
 
 DQMEDAnalyzer ()
 
void endLuminosityBlock (edm::LuminosityBlock const &lumi, edm::EventSetup const &setup) final
 
void endRun (edm::Run const &run, edm::EventSetup const &setup) final
 
virtual bool getCanSaveByLumi ()
 
- Public Member Functions inherited from edm::stream::EDProducer< edm::GlobalCache< DQMEDAnalyzerGlobalCache >, edm::EndRunProducer, edm::EndLuminosityBlockProducer, edm::Accumulator >
 EDProducer ()=default
 
 EDProducer (const EDProducer &)=delete
 
bool hasAbilityToProduceInBeginLumis () const final
 
bool hasAbilityToProduceInBeginProcessBlocks () const final
 
bool hasAbilityToProduceInBeginRuns () const final
 
bool hasAbilityToProduceInEndLumis () const final
 
bool hasAbilityToProduceInEndProcessBlocks () const final
 
bool hasAbilityToProduceInEndRuns () const final
 
const EDProduceroperator= (const EDProducer &)=delete
 

Static Public Member Functions

static void fillDescriptions (edm::ConfigurationDescriptions &descriptions)
 
- Static Public Member Functions inherited from DQMEDAnalyzer
static void globalEndJob (DQMEDAnalyzerGlobalCache const *)
 
static void globalEndLuminosityBlockProduce (edm::LuminosityBlock &lumi, edm::EventSetup const &setup, LuminosityBlockContext const *context)
 
static void globalEndRunProduce (edm::Run &run, edm::EventSetup const &setup, RunContext const *context)
 
static std::unique_ptr< DQMEDAnalyzerGlobalCacheinitializeGlobalCache (edm::ParameterSet const &)
 

Private Member Functions

void analyze (const edm::Event &, const edm::EventSetup &) override
 
void bookHistograms (DQMStore::IBooker &, edm::Run const &, edm::EventSetup const &) override
 

Private Attributes

MonitorElementexample2D_
 
MonitorElementexample3D_
 
MonitorElementexample_
 
MonitorElementexampleTProfile2D_
 
MonitorElementexampleTProfile_
 
std::string folder_
 

Additional Inherited Members

- Public Types inherited from DQMEDAnalyzer
typedef dqm::reco::DQMStore DQMStore
 
typedef dqm::reco::MonitorElement MonitorElement
 
- Public Types inherited from edm::stream::EDProducer< edm::GlobalCache< DQMEDAnalyzerGlobalCache >, edm::EndRunProducer, edm::EndLuminosityBlockProducer, edm::Accumulator >
using CacheTypes = CacheContexts< T... >
 
using GlobalCache = typename CacheTypes::GlobalCache
 
using HasAbility = AbilityChecker< T... >
 
using InputProcessBlockCache = typename CacheTypes::InputProcessBlockCache
 
using LuminosityBlockCache = typename CacheTypes::LuminosityBlockCache
 
using LuminosityBlockContext = LuminosityBlockContextT< LuminosityBlockCache, RunCache, GlobalCache >
 
using LuminosityBlockSummaryCache = typename CacheTypes::LuminosityBlockSummaryCache
 
using RunCache = typename CacheTypes::RunCache
 
using RunContext = RunContextT< RunCache, GlobalCache >
 
using RunSummaryCache = typename CacheTypes::RunSummaryCache
 
- Protected Member Functions inherited from DQMEDAnalyzer
uint64_t meId () const
 
- Protected Attributes inherited from DQMEDAnalyzer
edm::EDPutTokenT< DQMTokenlumiToken_
 
edm::EDPutTokenT< DQMTokenrunToken_
 
unsigned int streamId_
 

Detailed Description

Description: [one line class summary]

Implementation: [Notes on implementation]

Definition at line 28 of file DemoNormalDQMEDAnalyzer.cc.

Constructor & Destructor Documentation

◆ DemoNormalDQMEDAnalyzer()

DemoNormalDQMEDAnalyzer::DemoNormalDQMEDAnalyzer ( const edm::ParameterSet iConfig)
explicit

Definition at line 48 of file DemoNormalDQMEDAnalyzer.cc.

49  : folder_(iConfig.getParameter<std::string>("folder")) {
50  // now do what ever initialization is needed
51 }

◆ ~DemoNormalDQMEDAnalyzer()

DemoNormalDQMEDAnalyzer::~DemoNormalDQMEDAnalyzer ( )
override

Definition at line 53 of file DemoNormalDQMEDAnalyzer.cc.

53  {
54  // do anything here that needs to be done at desctruction time
55  // (e.g. close files, deallocate resources etc.)
56 }

Member Function Documentation

◆ analyze()

void DemoNormalDQMEDAnalyzer::analyze ( const edm::Event iEvent,
const edm::EventSetup iSetup 
)
overrideprivatevirtual

Reimplemented from DQMEDAnalyzer.

Definition at line 59 of file DemoNormalDQMEDAnalyzer.cc.

59  {
60  using namespace edm;
61  example_->Fill(5);
62  example2D_->Fill(1.0, 2.0);
63  example3D_->Fill(1.0, 2.0, 3.0);
64  exampleTProfile_->Fill(1.0, 2.0);
65  exampleTProfile2D_->Fill(1.0, 2.0, 3.0);
66 }

References example2D_, example3D_, example_, exampleTProfile2D_, exampleTProfile_, and dqm::impl::MonitorElement::Fill().

◆ bookHistograms()

void DemoNormalDQMEDAnalyzer::bookHistograms ( DQMStore::IBooker ibook,
edm::Run const &  run,
edm::EventSetup const &  iSetup 
)
overrideprivatevirtual

Implements DQMEDAnalyzer.

Definition at line 68 of file DemoNormalDQMEDAnalyzer.cc.

70  {
72 
73  example_ = ibook.book1D(
74  "EXAMPLE", "Example 1D", 20, 0., 10., [](TH1*) { edm::LogInfo("DemoNormalDQMEDAnalyzer") << "booked!\n"; });
75  example2D_ = ibook.book2D("EXAMPLE_2D", "Example 2D", 20, 0, 20, 15, 0, 15);
76  example3D_ = ibook.book3D("EXAMPLE_3D", "Example 3D", 20, 0, 20, 15, 0, 15, 25, 0, 25);
77  exampleTProfile_ = ibook.bookProfile("EXAMPLE_TPROFILE", "Example TProfile", 20, 0, 20, 15, 0, 15);
78  exampleTProfile2D_ = ibook.bookProfile2D("EXAMPLE_TPROFILE2D", "Example TProfile 2D", 20, 0, 20, 15, 0, 15, 0, 100);
79 }

References dqm::implementation::IBooker::book1D(), dqm::implementation::IBooker::book2D(), dqm::implementation::IBooker::book3D(), dqm::implementation::IBooker::bookProfile(), dqm::implementation::IBooker::bookProfile2D(), example2D_, example3D_, example_, exampleTProfile2D_, exampleTProfile_, folder_, and dqm::implementation::NavigatorBase::setCurrentFolder().

◆ fillDescriptions()

void DemoNormalDQMEDAnalyzer::fillDescriptions ( edm::ConfigurationDescriptions descriptions)
static

Definition at line 82 of file DemoNormalDQMEDAnalyzer.cc.

82  {
84  desc.add<std::string>("folder", "MY_FOLDER");
85  descriptions.add("demo", desc);
86 }

References edm::ConfigurationDescriptions::add(), submitPVResolutionJobs::desc, and AlCaHLTBitMon_QueryRunRegistry::string.

Member Data Documentation

◆ example2D_

MonitorElement* DemoNormalDQMEDAnalyzer::example2D_
private

Definition at line 42 of file DemoNormalDQMEDAnalyzer.cc.

Referenced by analyze(), and bookHistograms().

◆ example3D_

MonitorElement* DemoNormalDQMEDAnalyzer::example3D_
private

Definition at line 43 of file DemoNormalDQMEDAnalyzer.cc.

Referenced by analyze(), and bookHistograms().

◆ example_

MonitorElement* DemoNormalDQMEDAnalyzer::example_
private

Definition at line 41 of file DemoNormalDQMEDAnalyzer.cc.

Referenced by analyze(), and bookHistograms().

◆ exampleTProfile2D_

MonitorElement* DemoNormalDQMEDAnalyzer::exampleTProfile2D_
private

Definition at line 45 of file DemoNormalDQMEDAnalyzer.cc.

Referenced by analyze(), and bookHistograms().

◆ exampleTProfile_

MonitorElement* DemoNormalDQMEDAnalyzer::exampleTProfile_
private

Definition at line 44 of file DemoNormalDQMEDAnalyzer.cc.

Referenced by analyze(), and bookHistograms().

◆ folder_

std::string DemoNormalDQMEDAnalyzer::folder_
private

Definition at line 40 of file DemoNormalDQMEDAnalyzer.cc.

Referenced by bookHistograms().

DemoNormalDQMEDAnalyzer::exampleTProfile2D_
MonitorElement * exampleTProfile2D_
Definition: DemoNormalDQMEDAnalyzer.cc:45
edm
HLT enums.
Definition: AlignableModifier.h:19
dqm::implementation::IBooker::bookProfile2D
MonitorElement * bookProfile2D(TString const &name, TString const &title, int nchX, double lowX, double highX, int nchY, double lowY, double highY, double lowZ, double highZ, char const *option="s", FUNC onbooking=NOOP())
Definition: DQMStore.h:399
DemoNormalDQMEDAnalyzer::example_
MonitorElement * example_
Definition: DemoNormalDQMEDAnalyzer.cc:41
edm::ParameterSetDescription
Definition: ParameterSetDescription.h:52
dqm::implementation::NavigatorBase::setCurrentFolder
virtual void setCurrentFolder(std::string const &fullpath)
Definition: DQMStore.cc:32
edm::LogInfo
Log< level::Info, false > LogInfo
Definition: MessageLogger.h:125
DemoNormalDQMEDAnalyzer::exampleTProfile_
MonitorElement * exampleTProfile_
Definition: DemoNormalDQMEDAnalyzer.cc:44
edm::ConfigurationDescriptions::add
void add(std::string const &label, ParameterSetDescription const &psetDescription)
Definition: ConfigurationDescriptions.cc:57
dqm::impl::MonitorElement::Fill
void Fill(long long x)
Definition: MonitorElement.h:290
dqm::implementation::IBooker::bookProfile
MonitorElement * bookProfile(TString const &name, TString const &title, int nchX, double lowX, double highX, int, double lowY, double highY, char const *option="s", FUNC onbooking=NOOP())
Definition: DQMStore.h:322
DemoNormalDQMEDAnalyzer::folder_
std::string folder_
Definition: DemoNormalDQMEDAnalyzer.cc:40
DemoNormalDQMEDAnalyzer::example2D_
MonitorElement * example2D_
Definition: DemoNormalDQMEDAnalyzer.cc:42
AlCaHLTBitMon_QueryRunRegistry.string
string string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
submitPVResolutionJobs.desc
string desc
Definition: submitPVResolutionJobs.py:251
dqm::implementation::IBooker::book2D
MonitorElement * book2D(TString const &name, TString const &title, int nchX, double lowX, double highX, int nchY, double lowY, double highY, FUNC onbooking=NOOP())
Definition: DQMStore.h:177
dqm::implementation::IBooker::book3D
MonitorElement * book3D(TString const &name, TString const &title, int nchX, double lowX, double highX, int nchY, double lowY, double highY, int nchZ, double lowZ, double highZ, FUNC onbooking=NOOP())
Definition: DQMStore.h:290
edm::ParameterSet::getParameter
T getParameter(std::string const &) const
Definition: ParameterSet.h:303
DemoNormalDQMEDAnalyzer::example3D_
MonitorElement * example3D_
Definition: DemoNormalDQMEDAnalyzer.cc:43
dqm::implementation::IBooker::book1D
MonitorElement * book1D(TString const &name, TString const &title, int const nchX, double const lowX, double const highX, FUNC onbooking=NOOP())
Definition: DQMStore.h:98