Main Page
Namespaces
Classes
Package Documentation
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Properties
Friends
Macros
Groups
Pages
DataFormats
L1TParticleFlow
src
PFCandidate.cc
Go to the documentation of this file.
1
#include "
DataFormats/L1TParticleFlow/interface/PFCandidate.h
"
2
3
l1t::PFCandidate::PFCandidate
(
4
ParticleType
kind
,
int
charge
,
const
PolarLorentzVector
&
p
,
float
puppiWeight,
int
hwpt,
int
hweta,
int
hwphi)
5
:
L1Candidate
(p, hwpt, hweta, hwphi,
/*hwQuality=*/
int(kind)), puppiWeight_(puppiWeight) {
6
setCharge
(charge);
7
setPdgIdFromParticleType
(charge, kind);
8
}
9
10
void
l1t::PFCandidate::setPdgIdFromParticleType
(
int
charge
,
ParticleType
kind
) {
11
switch
(kind) {
12
case
ChargedHadron:
13
setPdgId(charge > 0 ? 211 : -211);
14
break
;
15
case
Electron
:
16
setPdgId(charge > 0 ? -11 : +11);
17
break
;
18
case
NeutralHadron:
19
setPdgId(130);
20
break
;
21
case
Photon
:
22
setPdgId(22);
23
break
;
24
case
Muon
:
25
setPdgId(charge > 0 ? -13 : +13);
26
break
;
27
};
28
}
configurableAnalysis::Photon
constexpr char Photon[]
Definition:
modules.cc:14
class-composition.kind
list kind
Definition:
class-composition.py:107
reco::LeafCandidate::setCharge
void setCharge(Charge q) final
set electric charge
Definition:
LeafCandidate.h:108
l1t::L1Candidate
Definition:
L1Candidate.h:15
l1t::Muon
Definition:
Muon.h:21
l1t::PFCandidate::PFCandidate
PFCandidate()
Definition:
PFCandidate.h:17
AlCaHLTBitMon_ParallelJobs.p
tuple p
Definition:
AlCaHLTBitMon_ParallelJobs.py:153
l1t::PFCandidate::setPdgIdFromParticleType
void setPdgIdFromParticleType(int charge, ParticleType kind)
Definition:
PFCandidate.cc:10
configurableAnalysis::Electron
constexpr char Electron[]
Definition:
modules.cc:12
RecoTauCleanerPlugins.charge
tuple charge
Definition:
RecoTauCleanerPlugins.py:37
PFCandidate.h
l1t::PFCandidate::ParticleType
ParticleType
Definition:
PFCandidate.h:15
reco::Candidate::PolarLorentzVector
math::PtEtaPhiMLorentzVector PolarLorentzVector
Lorentz vector.
Definition:
Candidate.h:38
Generated for CMSSW Reference Manual by
1.8.5