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 
25 //---------------
26 // C++ Headers --
27 //---------------
28 #include <iostream>
29 
30 // ---------------------
31 // -- Class Interface --
32 // ---------------------
33 
34 class BPHPlusMinusVertex : public virtual BPHDecayVertex {
35 public:
42  ~BPHPlusMinusVertex() override;
43 
46  virtual const ClosestApproachInRPhi& cAppInRPhi() const;
48 
49 protected:
51 
52  // utility functions to check/enforce the number of decay particles
53  // at 2
54  template <class T>
55  static bool chkName(const T& cont, const std::string& name, const std::string& msg);
56  template <class T>
57  static bool chkSize(const T& cont, const std::string& msg);
58  bool chkSize(const std::string& msg) const;
59 
60  // utility function used to cash reconstruction results
61  void setNotUpdated() const override;
62 
63 private:
64  // reconstruction results cache
65  mutable bool oldA;
67 
68  // compute closest approach distance and cache it
69  virtual void computeApp() const;
70 };
71 
72 template <class T>
74  if (cont.find(name) != cont.end())
75  return true;
76  edm::LogPrint("ParticleNotFound") << msg << ", " << name << " not found";
77  return false;
78 }
79 
80 template <class T>
82  int n = cont.size();
83  if (n == 2)
84  return true;
85  edm::LogPrint("WrongDataSize") << msg << ", size = " << n;
86  return false;
87 }
88 
89 #endif
static bool chkSize(const T &cont, const std::string &msg)
virtual const ClosestApproachInRPhi & cAppInRPhi() const
compute distance of closest approach
~BPHPlusMinusVertex() override
void setNotUpdated() const override
BPHPlusMinusVertex(const edm::EventSetup *es)
tuple msg
Definition: mps_check.py:285
virtual void computeApp() const
static bool chkName(const T &cont, const std::string &name, const std::string &msg)
ClosestApproachInRPhi * inRPhi
long double T
cont
load Luminosity info ##
Definition: generateEDF.py:629