CMS 3D CMS Logo

List of all members | Public Member Functions | Protected Member Functions | Static Protected Member Functions | Private Member Functions | Private Attributes
BPHPlusMinusVertex Class Reference

#include <BPHPlusMinusVertex.h>

Inheritance diagram for BPHPlusMinusVertex:
BPHDecayVertex BPHDecayMomentum BPHPlusMinusCandidate

Public Member Functions

 BPHPlusMinusVertex (const BPHPlusMinusVertex &x)=delete
 
virtual const ClosestApproachInRPhicAppInRPhi () const
 compute distance of closest approach More...
 
BPHPlusMinusVertexoperator= (const BPHPlusMinusVertex &x)=delete
 
 ~BPHPlusMinusVertex () override
 
- Public Member Functions inherited from BPHDecayVertex
 BPHDecayVertex (const BPHDecayVertex &x)=delete
 
const BPHEventSetupWrappergetEventSetup () const
 retrieve EventSetup More...
 
char getTMode (const reco::Candidate *cand) const
 get Track mode for a daughter More...
 
const reco::TrackgetTrack (const reco::Candidate *cand) const
 get Track for a daughter More...
 
const std::string & getTrackSearchList (const reco::Candidate *cand) const
 retrieve track search list More...
 
reco::TransientTrackgetTransientTrack (const reco::Candidate *cand) const
 get TransientTrack for a daughter More...
 
BPHDecayVertexoperator= (const BPHDecayVertex &x)=delete
 
const std::vector< const reco::Track * > & tracks () const
 get list of Tracks More...
 
const std::vector< reco::TransientTrack > & transientTracks () const
 get list of TransientTracks More...
 
virtual bool validTracks () const
 check for valid reconstructed vertex More...
 
virtual bool validVertex () const
 
virtual const reco::Vertexvertex (VertexFitter< 5 > *fitter=nullptr, const reco::BeamSpot *bs=nullptr, const GlobalPoint *priorPos=nullptr, const GlobalError *priorError=nullptr) const
 get reconstructed vertex More...
 
 ~BPHDecayVertex () override
 
- Public Member Functions inherited from BPHDecayMomentum
 BPHDecayMomentum (const BPHDecayMomentum &x)=delete
 
const std::map< std::string, BPHRecoConstCandPtr > & compMap () const
 
virtual const std::vector< std::string > & compNames () const
 
virtual const pat::CompositeCandidatecomposite () const
 get a composite by the simple sum of simple particles More...
 
virtual const std::vector< BPHRecoConstCandPtr > & daughComp () const
 
virtual const std::vector< const reco::Candidate * > & daughFull () const
 
virtual const std::vector< const reco::Candidate * > & daughters () const
 
const std::map< std::string, const reco::Candidate * > & daugMap () const
 
virtual const std::vector< std::string > & daugNames () const
 
virtual BPHRecoConstCandPtr getComp (const std::string &name) const
 
virtual const reco::CandidategetDaug (const std::string &name) const
 
BPHDecayMomentumoperator= (const BPHDecayMomentum &x)=delete
 
virtual const reco::CandidateoriginalReco (const reco::Candidate *daug) const
 get the original particle from the clone More...
 
virtual ~BPHDecayMomentum ()
 

Protected Member Functions

 BPHPlusMinusVertex (const BPHEventSetupWrapper *es)
 
bool chkSize (const std::string &msg) const
 
void setNotUpdated () const override
 
- Protected Member Functions inherited from BPHDecayVertex
virtual void addV (const std::string &name, const reco::Candidate *daug, const std::string &searchList, double mass)
 
virtual void addV (const std::string &name, const BPHRecoConstCandPtr &comp)
 
 BPHDecayVertex (const BPHEventSetupWrapper *es, int daugNum=2, int compNum=2)
 
 BPHDecayVertex (const BPHDecayVertex *ptr, const BPHEventSetupWrapper *es)
 
- Protected Member Functions inherited from BPHDecayMomentum
virtual void addP (const std::string &name, const reco::Candidate *daug, double mass=-1.0)
 
virtual void addP (const std::string &name, const BPHRecoConstCandPtr &comp)
 
 BPHDecayMomentum (int daugNum=2, int compNum=2)
 
 BPHDecayMomentum (const std::map< std::string, Component > &daugMap, int compNum=2)
 
 BPHDecayMomentum (const std::map< std::string, Component > &daugMap, const std::map< std::string, BPHRecoConstCandPtr > compMap)
 
const std::vector< Component > & componentList () const
 
virtual void fill (BPHRecoCandidate *ptr, int level) const =0
 

Static Protected Member Functions

template<class T >
static bool chkName (const T &cont, const std::string &name, const std::string &msg)
 
template<class T >
static bool chkSize (const T &cont, const std::string &msg)
 

Private Member Functions

virtual void computeApp () const
 

Private Attributes

ClosestApproachInRPhiinRPhi
 
bool oldA
 

Detailed Description

Description: class for reconstructed decay vertices to opposite charge particle pairs

Author
Paolo Ronchese INFN Padova

Definition at line 35 of file BPHPlusMinusVertex.h.

Constructor & Destructor Documentation

◆ BPHPlusMinusVertex() [1/2]

BPHPlusMinusVertex::BPHPlusMinusVertex ( const BPHPlusMinusVertex x)
delete

Constructor is protected this object can exist only as part of a derived class

◆ ~BPHPlusMinusVertex()

BPHPlusMinusVertex::~BPHPlusMinusVertex ( )
override

Destructor

Definition at line 37 of file BPHPlusMinusVertex.cc.

References inRPhi.

37 { delete inRPhi; }
ClosestApproachInRPhi * inRPhi

◆ BPHPlusMinusVertex() [2/2]

BPHPlusMinusVertex::BPHPlusMinusVertex ( const BPHEventSetupWrapper es)
protected

Definition at line 31 of file BPHPlusMinusVertex.cc.

32  : BPHDecayVertex(es), oldA(true), inRPhi(nullptr) {}
BPHDecayVertex(const BPHDecayVertex &x)=delete
ClosestApproachInRPhi * inRPhi

Member Function Documentation

◆ cAppInRPhi()

const ClosestApproachInRPhi & BPHPlusMinusVertex::cAppInRPhi ( ) const
virtual

compute distance of closest approach

Operations

Definition at line 42 of file BPHPlusMinusVertex.cc.

References computeApp(), inRPhi, and oldA.

42  {
43  if (oldA)
44  computeApp();
45  if (inRPhi == nullptr) {
46  static const ClosestApproachInRPhi ca;
47  return ca;
48  }
49  return *inRPhi;
50 }
virtual void computeApp() const
ClosestApproachInRPhi * inRPhi

◆ chkName()

template<class T >
bool BPHPlusMinusVertex::chkName ( const T cont,
const std::string &  name,
const std::string &  msg 
)
staticprotected

Definition at line 76 of file BPHPlusMinusVertex.h.

References generateEDF::cont, mps_check::msg, and Skims_PA_cff::name.

76  {
77  if (cont.find(name) != cont.end())
78  return true;
79  edm::LogPrint("ParticleNotFound") << msg << ", " << name << " not found";
80  return false;
81 }
Log< level::Warning, true > LogPrint
tuple msg
Definition: mps_check.py:285
cont
load Luminosity info ##
Definition: generateEDF.py:628

◆ chkSize() [1/2]

template<class T >
bool BPHPlusMinusVertex::chkSize ( const T cont,
const std::string &  msg 
)
staticprotected

Definition at line 84 of file BPHPlusMinusVertex.h.

References generateEDF::cont, mps_check::msg, and dqmiodumpmetadata::n.

Referenced by BPHPlusMinusCandidate::composite(), computeApp(), BPHPlusMinusCandidate::isCowboy(), and BPHPlusMinusCandidate::isSailor().

84  {
85  int n = cont.size();
86  if (n == 2)
87  return true;
88  edm::LogPrint("WrongDataSize") << msg << ", size = " << n;
89  return false;
90 }
Log< level::Warning, true > LogPrint
tuple msg
Definition: mps_check.py:285
cont
load Luminosity info ##
Definition: generateEDF.py:628

◆ chkSize() [2/2]

bool BPHPlusMinusVertex::chkSize ( const std::string &  msg) const
protected

◆ computeApp()

void BPHPlusMinusVertex::computeApp ( ) const
privatevirtual

Definition at line 60 of file BPHPlusMinusVertex.cc.

References ClosestApproachInRPhi::calculate(), chkSize(), reco::TransientTrack::impactPointTSCP(), inRPhi, mps_check::msg, oldA, TrajectoryStateClosestToPoint::theState(), and BPHDecayVertex::transientTracks().

Referenced by cAppInRPhi().

60  {
61  static const string msg = "BPHPlusMinusVertex::computeApp: incomplete, no closest approach available";
62  delete inRPhi;
63  if (!chkSize(msg)) {
64  inRPhi = nullptr;
65  return;
66  }
68  const vector<reco::TransientTrack>& ttk = transientTracks();
69  const reco::TransientTrack& ttp = ttk[0];
70  const reco::TransientTrack& ttn = ttk[1];
72  oldA = false;
73  return;
74 }
static bool chkSize(const T &cont, const std::string &msg)
TrajectoryStateClosestToPoint impactPointTSCP() const
bool calculate(const TrajectoryStateOnSurface &sta, const TrajectoryStateOnSurface &stb) override
const std::vector< reco::TransientTrack > & transientTracks() const
get list of TransientTracks
const FreeTrajectoryState & theState() const
tuple msg
Definition: mps_check.py:285
ClosestApproachInRPhi * inRPhi

◆ operator=()

BPHPlusMinusVertex& BPHPlusMinusVertex::operator= ( const BPHPlusMinusVertex x)
delete

◆ setNotUpdated()

void BPHPlusMinusVertex::setNotUpdated ( ) const
overrideprotectedvirtual

Reimplemented from BPHDecayVertex.

Definition at line 54 of file BPHPlusMinusVertex.cc.

References oldA, and BPHDecayVertex::setNotUpdated().

Referenced by BPHPlusMinusCandidate::setNotUpdated().

54  {
56  oldA = true;
57  return;
58 }
void setNotUpdated() const override

Member Data Documentation

◆ inRPhi

ClosestApproachInRPhi* BPHPlusMinusVertex::inRPhi
mutableprivate

Definition at line 69 of file BPHPlusMinusVertex.h.

Referenced by cAppInRPhi(), computeApp(), and ~BPHPlusMinusVertex().

◆ oldA

bool BPHPlusMinusVertex::oldA
mutableprivate

Definition at line 68 of file BPHPlusMinusVertex.h.

Referenced by cAppInRPhi(), computeApp(), and setNotUpdated().