CMS 3D CMS Logo

ShallowCloneCandidate.h
Go to the documentation of this file.
1 #ifndef Candidate_ShallowCloneCandidate_h
2 #define Candidate_ShallowCloneCandidate_h
3 
13 
14 namespace reco {
16  public:
27  Charge q,
28  const LorentzVector& p4,
29  const Point& vtx = Point(0, 0, 0))
33  Charge q,
34  const PolarLorentzVector& p4,
35  const Point& vtx = Point(0, 0, 0))
38  ~ShallowCloneCandidate() override;
40  ShallowCloneCandidate* clone() const override;
42  size_t numberOfDaughters() const override;
44  size_t numberOfMothers() const override;
46  const Candidate* daughter(size_type i) const override;
48  const Candidate* mother(size_type i) const override;
50  Candidate* daughter(size_type i) override;
51  using reco::LeafCandidate::daughter; // avoid hiding the base
53  bool hasMasterClone() const override;
55  const CandidateBaseRef& masterClone() const override;
56 
57  bool isElectron() const override;
58  bool isMuon() const override;
59  bool isGlobalMuon() const override;
60  bool isStandAloneMuon() const override;
61  bool isTrackerMuon() const override;
62  bool isCaloMuon() const override;
63  bool isPhoton() const override;
64  bool isConvertedPhoton() const override;
65  bool isJet() const override;
66 
67  private:
69  bool overlap(const Candidate& c) const override { return masterClone_->overlap(c); }
72  };
73 
74 } // namespace reco
75 
76 #endif
mps_fire.i
i
Definition: mps_fire.py:428
reco::ShallowCloneCandidate::numberOfMothers
size_t numberOfMothers() const override
number of daughters
Definition: ShallowCloneCandidate.cc:10
reco::LeafCandidate::Point
math::XYZPoint Point
point in the space
Definition: LeafCandidate.h:27
reco::ShallowCloneCandidate::isMuon
bool isMuon() const override
Definition: ShallowCloneCandidate.cc:24
reco::Candidate::PolarLorentzVector
math::PtEtaPhiMLorentzVector PolarLorentzVector
Lorentz vector.
Definition: Candidate.h:38
reco::Candidate::Charge
int Charge
electric charge type
Definition: Candidate.h:34
reco::ShallowCloneCandidate::mother
const Candidate * mother(size_type i) const override
return daughter at a given position (throws an exception)
Definition: ShallowCloneCandidate.cc:14
reco::ShallowCloneCandidate::isConvertedPhoton
bool isConvertedPhoton() const override
Definition: ShallowCloneCandidate.cc:36
reco::ShallowCloneCandidate::daughters
CandidateCollection daughters
collection of daughter candidates
Definition: ShallowCloneCandidate.h:18
reco
fixed size matrix
Definition: AlignmentAlgorithmBase.h:45
reco::ShallowCloneCandidate::isGlobalMuon
bool isGlobalMuon() const override
Definition: ShallowCloneCandidate.cc:26
reco::ShallowCloneCandidate::numberOfDaughters
size_t numberOfDaughters() const override
number of daughters
Definition: ShallowCloneCandidate.cc:8
reco::ShallowCloneCandidate::overlap
bool overlap(const Candidate &c) const override
check overlap with another Candidate
Definition: ShallowCloneCandidate.h:69
reco::ShallowCloneCandidate::ShallowCloneCandidate
ShallowCloneCandidate(const CandidateBaseRef &masterClone, Charge q, const LorentzVector &p4, const Point &vtx=Point(0, 0, 0))
constructor from values
Definition: ShallowCloneCandidate.h:26
reco::ShallowCloneCandidate::isCaloMuon
bool isCaloMuon() const override
Definition: ShallowCloneCandidate.cc:32
LeafCandidate.h
Point
Structure Point Contains parameters of Gaussian fits to DMRs.
Definition: DMRtrends.cc:57
reco::LeafCandidate::daughter
const Candidate * daughter(size_type) const override
return daughter at a given position (throws an exception)
Definition: LeafCandidate.cc:29
reco::ShallowCloneCandidate::ShallowCloneCandidate
ShallowCloneCandidate(const CandidateBaseRef &masterClone, Charge q, const PolarLorentzVector &p4, const Point &vtx=Point(0, 0, 0))
constructor from values
Definition: ShallowCloneCandidate.h:32
reco::ShallowCloneCandidate::isPhoton
bool isPhoton() const override
Definition: ShallowCloneCandidate.cc:34
reco::ShallowCloneCandidate::hasMasterClone
bool hasMasterClone() const override
has master clone
Definition: ShallowCloneCandidate.cc:18
reco::ShallowCloneCandidate::masterClone_
CandidateBaseRef masterClone_
CandidateBaseReference to master clone.
Definition: ShallowCloneCandidate.h:71
reco::LeafCandidate::p4
const LorentzVector & p4() const final
four-momentum Lorentz vector
Definition: LeafCandidate.h:114
submitPVResolutionJobs.q
q
Definition: submitPVResolutionJobs.py:84
reco::ShallowCloneCandidate::isTrackerMuon
bool isTrackerMuon() const override
Definition: ShallowCloneCandidate.cc:30
reco::ShallowCloneCandidate::isJet
bool isJet() const override
Definition: ShallowCloneCandidate.cc:38
reco::Candidate
Definition: Candidate.h:27
reco::ShallowCloneCandidate::clone
ShallowCloneCandidate * clone() const override
returns a clone of the Candidate object
Definition: ShallowCloneCandidate.cc:6
reco::ShallowCloneCandidate::ShallowCloneCandidate
ShallowCloneCandidate()
default constructor
Definition: ShallowCloneCandidate.h:20
reco::ShallowCloneCandidate::ShallowCloneCandidate
ShallowCloneCandidate(const CandidateBaseRef &masterClone)
constructor from Particle
Definition: ShallowCloneCandidate.h:22
reco::ShallowCloneCandidate::isElectron
bool isElectron() const override
Definition: ShallowCloneCandidate.cc:22
extraflags_cff.vtx
vtx
Definition: extraflags_cff.py:18
edm::RefToBase< Candidate >
reco::ShallowCloneCandidate::isStandAloneMuon
bool isStandAloneMuon() const override
Definition: ShallowCloneCandidate.cc:28
reco::ShallowCloneCandidate
Definition: ShallowCloneCandidate.h:15
reco::LeafCandidate
Definition: LeafCandidate.h:16
reco::Candidate::LorentzVector
math::XYZTLorentzVector LorentzVector
Lorentz vector.
Definition: Candidate.h:36
c
auto & c
Definition: CAHitNtupletGeneratorKernelsImpl.h:46
reco::ShallowCloneCandidate::~ShallowCloneCandidate
~ShallowCloneCandidate() override
destructor
Definition: ShallowCloneCandidate.cc:4
reco::ShallowCloneCandidate::daughter
const Candidate * daughter(size_type i) const override
return daughter at a given position (throws an exception)
Definition: ShallowCloneCandidate.cc:12
reco::Candidate::size_type
size_t size_type
Definition: Candidate.h:29
edm::OwnVector
Definition: OwnVector.h:24
reco::ShallowCloneCandidate::masterClone
const CandidateBaseRef & masterClone() const override
returns reference to master clone
Definition: ShallowCloneCandidate.cc:20