CMS 3D CMS Logo

BPHPlusMinusVertex.h
Go to the documentation of this file.
1 #ifndef HeavyFlavorAnalysis_RecoDecay_BPHPlusMinusVertex_h
2 #define HeavyFlavorAnalysis_RecoDecay_BPHPlusMinusVertex_h
3 
13 //----------------------
14 // Base Class Headers --
15 //----------------------
17 
18 //------------------------------------
19 // Collaborating Class Declarations --
20 //------------------------------------
24 
26 
27 //---------------
28 // C++ Headers --
29 //---------------
30 
31 // ---------------------
32 // -- Class Interface --
33 // ---------------------
34 
35 class BPHPlusMinusVertex : public virtual BPHDecayVertex {
36 public:
40  // deleted copy constructor and assignment operator
41  BPHPlusMinusVertex(const BPHPlusMinusVertex& x) = delete;
43 
46  ~BPHPlusMinusVertex() override;
47 
50  virtual const ClosestApproachInRPhi& cAppInRPhi() const;
52 
53 protected:
55 
56  // utility functions to check/enforce the number of decay particles at 2
57  template <class T>
58  static bool chkName(const T& cont, const std::string& name, const std::string& msg);
59  template <class T>
60  static bool chkSize(const T& cont, const std::string& msg);
61  bool chkSize(const std::string& msg) const;
62 
63  // utility function used to cash reconstruction results
64  void setNotUpdated() const override;
65 
66 private:
67  // reconstruction results cache
68  mutable bool oldA;
70 
71  // compute closest approach distance and cache it
72  virtual void computeApp() const;
73 };
74 
75 template <class T>
77  if (cont.find(name) != cont.end())
78  return true;
79  edm::LogPrint("ParticleNotFound") << msg << ", " << name << " not found";
80  return false;
81 }
82 
83 template <class T>
85  int n = cont.size();
86  if (n == 2)
87  return true;
88  edm::LogPrint("WrongDataSize") << msg << ", size = " << n;
89  return false;
90 }
91 
92 #endif
void setNotUpdated() const override
static bool chkSize(const T &cont, const std::string &msg)
virtual void computeApp() const
Log< level::Warning, true > LogPrint
~BPHPlusMinusVertex() override
BPHPlusMinusVertex(const BPHPlusMinusVertex &x)=delete
tuple msg
Definition: mps_check.py:286
virtual const ClosestApproachInRPhi & cAppInRPhi() const
compute distance of closest approach
static bool chkName(const T &cont, const std::string &name, const std::string &msg)
ClosestApproachInRPhi * inRPhi
BPHPlusMinusVertex & operator=(const BPHPlusMinusVertex &x)=delete
long double T
cont
load Luminosity info ##
Definition: generateEDF.py:628