Class for particle data access in GenBase.
More...
#include <GenData.h>
Class for particle data access in GenBase.
Definition at line 37 of file GenData.h.
◆ GenData()
◆ ~GenData()
| virtual GenData::~GenData |
( |
| ) |
|
|
inlinevirtual |
◆ particleData()
| const HepPDT::ParticleData * GenData::particleData |
( |
int | pid | ) |
const |
|
inline |
Access an element in the particle data table.
Definition at line 75 of file GenData.h.
75 {
76 return pdt().particle(HepPDT::ParticleID(std::abs(pid)));
77 }
const HepPDT::ParticleDataTable & pdt() const
Shorter alias to get a particle data table.
◆ particleLifetime()
| std::optional< double > GenData::particleLifetime |
( |
int | pdgId | ) |
const |
|
inline |
Definition at line 87 of file GenData.h.
87 {
89 if (!particle) {
90 return std::nullopt;
91 }
93 }
const HepPDT::ParticleData * particleData(int pid) const
Access an element in the particle data table.
constexpr ParticleHypothesis particle[PARTICLEHYPOTHESES]
the array of masses
◆ particleMass()
| std::optional< double > GenData::particleMass |
( |
int | pdgId | ) |
const |
|
inline |
Definition at line 79 of file GenData.h.
79 {
81 if (!particle) {
82 return std::nullopt;
83 }
85 }
◆ particleName()
| std::optional< std::string > GenData::particleName |
( |
int | pdgId | ) |
const |
|
inline |
Definition at line 94 of file GenData.h.
94 {
96 if (!particle) {
97 return std::nullopt;
98 }
100 }
◆ particleTable()
| const HepPDT::ParticleDataTable & GenData::particleTable |
( |
| ) |
const |
|
inline |
Get a particle data table.
Definition at line 60 of file GenData.h.
60 {
62 if (
m_ppSvc.retrieve().isFailure()) {
63 std::cerr<< "GenData: failed to retrieve PartPropSvc\n";
64 std::abort();
65 }
67 }
69 }
ServiceHandle< IPartPropSvc > m_ppSvc
Handle on the particle property service.
std::atomic< bool > m_initialized
◆ partPropSvc()
Access the particle property service.
Definition at line 55 of file GenData.h.
◆ pdt()
| const HepPDT::ParticleDataTable & GenData::pdt |
( |
| ) |
const |
|
inline |
Shorter alias to get a particle data table.
Definition at line 72 of file GenData.h.
const HepPDT::ParticleDataTable & particleTable() const
Get a particle data table.
◆ m_initialized
| std::atomic<bool> GenData::m_initialized {false} |
|
mutableprivate |
◆ m_ppSvc
| ServiceHandle<IPartPropSvc> GenData::m_ppSvc {"PartPropSvc", "GenData"} |
|
private |
Handle on the particle property service.
Definition at line 109 of file GenData.h.
109{"PartPropSvc", "GenData"};
The documentation for this class was generated from the following file: