Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2021-03-17 23:26:15

0001 #ifndef MESetEcal_H
0002 #define MESetEcal_H
0003 
0004 #include "MESet.h"
0005 
0006 namespace ecaldqm {
0007 
0008   /* class MESetEcal
0009    implements plot <-> detector part relationship
0010    base class for channel-binned histograms
0011    MESetEcal is only filled given an object identifier and a bin (channel id
0012    does not give a bin)
0013 */
0014 
0015   class MESetEcal : public MESet {
0016   public:
0017     MESetEcal(std::string const &,
0018               binning::ObjectType,
0019               binning::BinningType,
0020               MonitorElement::Kind,
0021               unsigned,
0022               binning::AxisSpecs const * = nullptr,
0023               binning::AxisSpecs const * = nullptr,
0024               binning::AxisSpecs const * = nullptr);
0025     MESetEcal(MESetEcal const &);
0026     ~MESetEcal() override;
0027 
0028     MESet &operator=(MESet const &) override;
0029 
0030     MESet *clone(std::string const & = "") const override;
0031 
0032     void book(DQMStore::IBooker &, EcalElectronicsMapping const *) override;
0033     bool retrieve(EcalElectronicsMapping const *, DQMStore::IGetter &, std::string * = nullptr) const override;
0034 
0035     void fill(EcalDQMSetupObjects const, DetId const &, double = 1., double = 1., double = 1.) override;
0036     void fill(EcalDQMSetupObjects const, EcalElectronicsId const &, double = 1., double = 1., double = 1.) override;
0037     void fill(EcalDQMSetupObjects const, int, double = 1., double = 1., double = 1.) override;
0038     void fill(EcalDQMSetupObjects const, double, double = 1., double = 1.) override;
0039 
0040     void setBinContent(EcalDQMSetupObjects const, DetId const &, int, double) override;
0041     void setBinContent(EcalDQMSetupObjects const, EcalElectronicsId const &, int, double) override;
0042     void setBinContent(EcalDQMSetupObjects const, int, int, double) override;
0043 
0044     void setBinError(EcalDQMSetupObjects const, DetId const &, int, double) override;
0045     void setBinError(EcalDQMSetupObjects const, EcalElectronicsId const &, int, double) override;
0046     void setBinError(EcalDQMSetupObjects const, int, int, double) override;
0047 
0048     void setBinEntries(EcalDQMSetupObjects const, DetId const &, int, double) override;
0049     void setBinEntries(EcalDQMSetupObjects const, EcalElectronicsId const &, int, double) override;
0050     void setBinEntries(EcalDQMSetupObjects const, int, int, double) override;
0051 
0052     double getBinContent(EcalDQMSetupObjects const, DetId const &, int) const override;
0053     double getBinContent(EcalDQMSetupObjects const, EcalElectronicsId const &, int) const override;
0054     double getBinContent(EcalDQMSetupObjects const, int, int) const override;
0055 
0056     double getBinError(EcalDQMSetupObjects const, DetId const &, int) const override;
0057     double getBinError(EcalDQMSetupObjects const, EcalElectronicsId const &, int) const override;
0058     double getBinError(EcalDQMSetupObjects const, int, int) const override;
0059 
0060     double getBinEntries(EcalDQMSetupObjects const, DetId const &, int) const override;
0061     double getBinEntries(EcalDQMSetupObjects const, EcalElectronicsId const &, int) const override;
0062     double getBinEntries(EcalDQMSetupObjects const, int, int) const override;
0063 
0064     virtual int findBin(EcalDQMSetupObjects const, DetId const &, double, double = 0.) const;
0065     virtual int findBin(EcalDQMSetupObjects const, EcalElectronicsId const &, double, double = 0.) const;
0066     virtual int findBin(EcalDQMSetupObjects const, int, double, double = 0.) const;
0067 
0068     bool isVariableBinning() const override;
0069 
0070     std::vector<std::string> generatePaths(EcalElectronicsMapping const *) const;
0071 
0072   protected:
0073     unsigned logicalDimensions_;
0074     binning::AxisSpecs const *xaxis_;
0075     binning::AxisSpecs const *yaxis_;
0076     binning::AxisSpecs const *zaxis_;
0077 
0078   private:
0079     template <class Bookable>
0080     void doBook_(Bookable &);
0081   };
0082 
0083 }  // namespace ecaldqm
0084 
0085 #endif