MESetTrend

Macros

Line Code
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57
#ifndef MESetTrend_H
#define MESetTrend_H

#include "MESetEcal.h"

namespace ecaldqm {
  /* class MESetTrend
   time on xaxis
   channel id is used to identify the plot
*/

  class MESetTrend : public MESetEcal {
  public:
    MESetTrend(std::string const &,
               binning::ObjectType,
               binning::BinningType,
               MonitorElement::Kind,
               binning::AxisSpecs const * = nullptr,
               binning::AxisSpecs const * = nullptr);
    MESetTrend(MESetTrend const &);
    ~MESetTrend() override {}

    MESet &operator=(MESet const &) override;

    MESet *clone(std::string const & = "") const override;

    void book(DQMStore::IBooker &, EcalElectronicsMapping const *) override;

    void fill(EcalDQMSetupObjects const, DetId const &, double, double = 1., double = 1.) override;
    void fill(EcalDQMSetupObjects const, EcalElectronicsId const &, double, double = 1., double = 1.) override;
    void fill(EcalDQMSetupObjects const, int, double, double = 1., double = 1.) override;
    void fill(EcalDQMSetupObjects const, double, double = 1., double = 1.) override;

    int findBin(EcalDQMSetupObjects const, DetId const &, double, double = 0.) const override;
    int findBin(EcalDQMSetupObjects const, EcalElectronicsId const &, double, double = 0.) const override;
    int findBin(EcalDQMSetupObjects const, int, double, double = 0.) const override;
    int findBin(EcalDQMSetupObjects const, double, double = 0.) const;

    bool isVariableBinning() const override { return true; }

    void setMinutely() { minutely_ = true; }
    void setShiftAxis() { shiftAxis_ = true; }
    void setCumulative();
    bool isMinutely() const { return minutely_; }
    bool canShiftAxis() const { return shiftAxis_; }
    bool isCumulative() const { return currentBin_ > 0; }

  private:
    bool shift_(unsigned);

    bool minutely_;   // if true, bins in minutes instead of lumis
    bool shiftAxis_;  // if true, shift x values
    int currentBin_;  // only used for cumulative case
  };
}  // namespace ecaldqm

#endif