CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
EtaPtBin.h
Go to the documentation of this file.
1 #ifndef EtaPtBin_H
2 #define EtaPtBin_H
3 
4 #include <string>
5 
7 // #include "RecoBTag/MCTools/interface/JetFlavour.h"
8 
15 class EtaPtBin {
16 public:
17  EtaPtBin(const bool& etaActive_,
18  const double& etaMin_,
19  const double& etaMax_,
20  const bool& ptActive_,
21  const double& ptMin_,
22  const double& ptMax_);
23 
24  ~EtaPtBin(){};
25 
28 
31  static std::string buildDescriptionString(const bool& etaActive_,
32  const double& etaMin_,
33  const double& etaMax_,
34  const bool& ptActive_,
35  const double& ptMin_,
36  const double& ptMax_); // pt
37 
39  bool getEtaActive() const { return etaActive; }
40  double getEtaMin() const { return etaMin; }
41  double getEtaMax() const { return etaMax; }
42 
43  bool getPtActive() const { return ptActive; }
44  double getPtMin() const { return ptMin; }
45  double getPtMax() const { return ptMax; }
46 
48  bool inBin(const double& eta, const double& pt) const;
49  bool inBin(const reco::Jet& jet, const double jec) const;
50  // bool inBin(const BTagMCTools::JetFlavour & jetFlavour) const;
51 
52 private:
53  // definition of the bin
54 
55  bool etaActive; // should cuts be applied?
56  double etaMin;
57  double etaMax;
58 
59  bool ptActive; // should cuts be applied?
60  double ptMin;
61  double ptMax;
62 
63  // description string as built from bin definition
65 };
66 
67 #endif
std::string getDescriptionString() const
String describes rapidity/pt range.
Definition: EtaPtBin.h:27
Base class for all types of Jets.
Definition: Jet.h:20
double ptMin
Definition: EtaPtBin.h:60
std::string descriptionString
Definition: EtaPtBin.h:64
double getEtaMax() const
Definition: EtaPtBin.h:41
static std::string buildDescriptionString(const bool &etaActive_, const double &etaMin_, const double &etaMax_, const bool &ptActive_, const double &ptMin_, const double &ptMax_)
Definition: EtaPtBin.cc:16
double getEtaMin() const
Definition: EtaPtBin.h:40
double getPtMin() const
Definition: EtaPtBin.h:44
etaMax_(conf.getParameter< double >("etaMax"))
bool getEtaActive() const
Get rapidity/pt ranges and check whether rapidity/pt cuts are active.
Definition: EtaPtBin.h:39
ptMin_(conf.getParameter< double >("ptMin"))
bool getPtActive() const
Definition: EtaPtBin.h:43
bool inBin(const double &eta, const double &pt) const
Check if jet/parton are within rapidity/pt cuts.
Definition: EtaPtBin.cc:51
double etaMax
Definition: EtaPtBin.h:57
double etaMin
Definition: EtaPtBin.h:56
double getPtMax() const
Definition: EtaPtBin.h:45
EtaPtBin(const bool &etaActive_, const double &etaMin_, const double &etaMax_, const bool &ptActive_, const double &ptMin_, const double &ptMax_)
Definition: EtaPtBin.cc:6
bool ptActive
Definition: EtaPtBin.h:59
bool etaActive
Definition: EtaPtBin.h:55
double ptMax
Definition: EtaPtBin.h:61
~EtaPtBin()
Definition: EtaPtBin.h:24
etaMin_(conf.getParameter< double >("etaMin"))