CMS 3D CMS Logo

List of all members | Public Member Functions | Protected Attributes
hcaldqm::quantity::Quantity Class Reference

#include <Quantity.h>

Inheritance diagram for hcaldqm::quantity::Quantity:
hcaldqm::quantity::DetectorQuantity hcaldqm::quantity::ElectronicsQuantity hcaldqm::quantity::TrigTowerQuantity hcaldqm::quantity::ValueQuantity hcaldqm::quantity::CrateQuantity hcaldqm::quantity::FEDQuantity hcaldqm::quantity::EventNumber hcaldqm::quantity::EventType hcaldqm::quantity::FlagQuantity hcaldqm::quantity::LumiSection hcaldqm::quantity::LumiSectionCoarse hcaldqm::quantity::RunNumber

Public Member Functions

virtual uint32_t getBin (double)
 
virtual uint32_t getBin (HcalDetId const &)
 
virtual uint32_t getBin (HcalElectronicsId const &)
 
virtual uint32_t getBin (HcalTrigTowerDetId const &)
 
virtual uint32_t getBin (int)
 
virtual std::vector< std::string > getLabels ()
 
virtual double getValue (double x)
 
virtual int getValue (HcalDetId const &)
 
virtual int getValue (HcalElectronicsId const &)
 
virtual int getValue (HcalTrigTowerDetId const &)
 
virtual int getValue (int x)
 
virtual bool isCoordinate ()
 
virtual bool isLog ()
 
virtual QuantitymakeCopy ()
 
virtual double max ()
 
virtual double min ()
 
virtual std::string name ()
 
virtual int nbins ()
 
 Quantity ()
 
 Quantity (std::string const &name, bool isLog)
 
virtual void setAxisType (AxisType at)
 
virtual void setBits (TH1 *o)
 
virtual void setLog (TH1 *o)
 
virtual void setMax (double)
 
virtual void setMin (double)
 
virtual void setNbins (int)
 
virtual void showOverflow (bool showOverflow)
 
virtual QuantityType type ()
 
virtual int wofnbins ()
 
virtual ~Quantity ()
 

Protected Attributes

AxisType _axistype
 
bool _isLog
 
std::string _name
 
bool _showOverflow
 

Detailed Description

Definition at line 27 of file Quantity.h.

Constructor & Destructor Documentation

◆ Quantity() [1/2]

hcaldqm::quantity::Quantity::Quantity ( )
inline

Definition at line 29 of file Quantity.h.

29 : _name("Quantity"), _isLog(false), _showOverflow(false) {}

Referenced by makeCopy().

◆ Quantity() [2/2]

hcaldqm::quantity::Quantity::Quantity ( std::string const &  name,
bool  isLog 
)
inline

Definition at line 30 of file Quantity.h.

30 : _name(name), _isLog(isLog), _showOverflow(false) {}

◆ ~Quantity()

virtual hcaldqm::quantity::Quantity::~Quantity ( )
inlinevirtual

Definition at line 31 of file Quantity.h.

31 {}

Member Function Documentation

◆ getBin() [1/5]

virtual uint32_t hcaldqm::quantity::Quantity::getBin ( double  )
inlinevirtual

Definition at line 43 of file Quantity.h.

43 { return 1; }

Referenced by BTagWeightCalculator.BTagWeightCalculator::calcJetWeightImpl().

◆ getBin() [2/5]

virtual uint32_t hcaldqm::quantity::Quantity::getBin ( HcalDetId const &  )
inlinevirtual

◆ getBin() [3/5]

virtual uint32_t hcaldqm::quantity::Quantity::getBin ( HcalElectronicsId const &  )
inlinevirtual

◆ getBin() [4/5]

virtual uint32_t hcaldqm::quantity::Quantity::getBin ( HcalTrigTowerDetId const &  )
inlinevirtual

Reimplemented in hcaldqm::quantity::TrigTowerQuantity.

Definition at line 41 of file Quantity.h.

41 { return 1; }

Referenced by BTagWeightCalculator.BTagWeightCalculator::calcJetWeightImpl().

◆ getBin() [5/5]

virtual uint32_t hcaldqm::quantity::Quantity::getBin ( int  )
inlinevirtual

◆ getLabels()

virtual std::vector<std::string> hcaldqm::quantity::Quantity::getLabels ( )
inlinevirtual

◆ getValue() [1/5]

virtual double hcaldqm::quantity::Quantity::getValue ( double  x)
inlinevirtual

Reimplemented in hcaldqm::quantity::ValueQuantity.

Definition at line 49 of file Quantity.h.

49 { return x; }

◆ getValue() [2/5]

virtual int hcaldqm::quantity::Quantity::getValue ( HcalDetId const &  )
inlinevirtual

◆ getValue() [3/5]

virtual int hcaldqm::quantity::Quantity::getValue ( HcalElectronicsId const &  )
inlinevirtual

Reimplemented in hcaldqm::quantity::ElectronicsQuantity, hcaldqm::quantity::CrateQuantity, and hcaldqm::quantity::FEDQuantity.

Definition at line 46 of file Quantity.h.

46 { return 0; }

◆ getValue() [4/5]

virtual int hcaldqm::quantity::Quantity::getValue ( HcalTrigTowerDetId const &  )
inlinevirtual

Reimplemented in hcaldqm::quantity::TrigTowerQuantity.

Definition at line 47 of file Quantity.h.

47 { return 0; }

◆ getValue() [5/5]

virtual int hcaldqm::quantity::Quantity::getValue ( int  x)
inlinevirtual

◆ isCoordinate()

virtual bool hcaldqm::quantity::Quantity::isCoordinate ( )
inlinevirtual

◆ isLog()

virtual bool hcaldqm::quantity::Quantity::isLog ( )
inlinevirtual

Definition at line 35 of file Quantity.h.

35 { return _isLog; }

References _isLog.

◆ makeCopy()

virtual Quantity* hcaldqm::quantity::Quantity::makeCopy ( )
inlinevirtual

◆ max()

virtual double hcaldqm::quantity::Quantity::max ( )
inlinevirtual

◆ min()

virtual double hcaldqm::quantity::Quantity::min ( )
inlinevirtual

◆ name()

virtual std::string hcaldqm::quantity::Quantity::name ( void  )
inlinevirtual

◆ nbins()

virtual int hcaldqm::quantity::Quantity::nbins ( )
inlinevirtual

◆ setAxisType()

virtual void hcaldqm::quantity::Quantity::setAxisType ( AxisType  at)
inlinevirtual

◆ setBits()

virtual void hcaldqm::quantity::Quantity::setBits ( TH1 *  o)
inlinevirtual

◆ setLog()

virtual void hcaldqm::quantity::Quantity::setLog ( TH1 *  o)
inlinevirtual

Definition at line 52 of file Quantity.h.

52  {
53  if (_isLog)
54  o->SetBit(BIT(constants::BIT_OFFSET + _axistype));
55  }

References _axistype, _isLog, hcaldqm::constants::BIT_OFFSET, and EcalTangentSkim_cfg::o.

Referenced by setBits().

◆ setMax()

virtual void hcaldqm::quantity::Quantity::setMax ( double  )
inlinevirtual

◆ setMin()

virtual void hcaldqm::quantity::Quantity::setMin ( double  )
inlinevirtual

Definition at line 65 of file Quantity.h.

65 {}

◆ setNbins()

virtual void hcaldqm::quantity::Quantity::setNbins ( int  )
inlinevirtual

Definition at line 66 of file Quantity.h.

66 {}

◆ showOverflow()

virtual void hcaldqm::quantity::Quantity::showOverflow ( bool  showOverflow)
inlinevirtual

◆ type()

virtual QuantityType hcaldqm::quantity::Quantity::type ( )
inlinevirtual

◆ wofnbins()

virtual int hcaldqm::quantity::Quantity::wofnbins ( )
inlinevirtual

Definition at line 58 of file Quantity.h.

58 { return nbins() + 2; }

References nbins().

Referenced by hcaldqm::Container2D::getBinEntries(), and hcaldqm::ContainerSingle2D::getBinEntries().

Member Data Documentation

◆ _axistype

AxisType hcaldqm::quantity::Quantity::_axistype
protected

Definition at line 73 of file Quantity.h.

Referenced by setAxisType(), and setLog().

◆ _isLog

bool hcaldqm::quantity::Quantity::_isLog
protected

◆ _name

std::string hcaldqm::quantity::Quantity::_name
protected

Definition at line 71 of file Quantity.h.

Referenced by plotting.Subtract::__str__(), plotting.Transform::__str__(), plotting.FakeDuplicate::__str__(), plotting.CutEfficiency::__str__(), plotting.AggregateBins::__str__(), plotting.AggregateHistos::__str__(), plotting.ROC::__str__(), trackingPlots.TimePerEventPlot::__str__(), trackingPlots.TimePerTrackPlot::__str__(), SequenceTypes.SequencePlaceholder::_clonesequence(), trackingPlots.TimePerEventPlot::_create(), plotting.PlotGroup::_drawSeparate(), plotting.PlotGroup::_save(), SequenceTypes.SequencePlaceholder::copy(), SequenceTypes.TaskPlaceholder::copy(), plotting.Subtract::create(), plotting.Transform::create(), plotting.FakeDuplicate::create(), plotting.CutEfficiency::create(), plotting.AggregateBins::create(), plotting.AggregateHistos::create(), trackingPlots.TimePerTrackPlot::create(), plotting.Plot::create(), plotting.PlotGroup::draw(), SequenceTypes.SequencePlaceholder::dumpPython(), SequenceTypes.TaskPlaceholder::dumpPython(), SequenceTypes.SequencePlaceholder::dumpSequenceConfig(), SequenceTypes.SequencePlaceholder::dumpSequencePython(), SequenceTypes.TaskPlaceholder::dumpSequencePython(), plotting.Plot::getName(), plotting.PlotGroup::getName(), plotting.PlotterFolder::getName(), plotting.PlotterItem::getName(), plotting.PlotterFolder::getSelectionNameIterator(), SequenceTypes.SequencePlaceholder::insertInto(), SequenceTypes.TaskPlaceholder::insertInto(), makeCopy(), name(), validation.SimpleSample::name(), trackingPlots.Iteration::name(), plotting.PlotterItem::readDirs(), plotting.PlotGroup::remove(), SequenceTypes.SequencePlaceholder::resolve(), and SequenceTypes.TaskPlaceholder::resolve().

◆ _showOverflow

bool hcaldqm::quantity::Quantity::_showOverflow
protected

Definition at line 74 of file Quantity.h.

Referenced by hcaldqm::quantity::ValueQuantity::getValue(), and showOverflow().

hcaldqm::quantity::Quantity::showOverflow
virtual void showOverflow(bool showOverflow)
Definition: Quantity.h:68
DDAxes::x
hcaldqm::constants::BIT_OFFSET
const int BIT_OFFSET
Definition: Constants.h:279
EcalTangentSkim_cfg.o
o
Definition: EcalTangentSkim_cfg.py:36
hcaldqm::quantity::Quantity::isLog
virtual bool isLog()
Definition: Quantity.h:35
hcaldqm::quantity::Quantity::nbins
virtual int nbins()
Definition: Quantity.h:57
hcaldqm::quantity::fNone
Definition: Quantity.h:21
hcaldqm::quantity::Quantity::_showOverflow
bool _showOverflow
Definition: Quantity.h:74
hcaldqm::quantity::Quantity::setLog
virtual void setLog(TH1 *o)
Definition: Quantity.h:52
hcaldqm::quantity::Quantity::name
virtual std::string name()
Definition: Quantity.h:34
hcaldqm::quantity::Quantity::Quantity
Quantity()
Definition: Quantity.h:29
hcaldqm::quantity::Quantity::_isLog
bool _isLog
Definition: Quantity.h:72
hcaldqm::quantity::Quantity::_axistype
AxisType _axistype
Definition: Quantity.h:73
hcaldqm::quantity::Quantity::_name
std::string _name
Definition: Quantity.h:71