Belle II Software development
|
Provides a type-safe way to pass members of the chargedStableSet set. More...
#include <Const.h>
Public Member Functions | |
ChargedStable (const ParticleType &p) | |
Constructor from the more general ParticleType. | |
ChargedStable (int pdg) | |
Constructor from PDG code. | |
bool | operator< (const ParticleType &other) const |
Comparison operator to be usable in sets. | |
bool | operator== (const ParticleType &o) const |
Test equality. | |
bool | operator!= (const ParticleType &o) const |
Test inequality. | |
ParticleType & | operator* () |
dummy dereferencing for range-based for. | |
ParticleType & | operator++ () |
Prefix increment. | |
ParticleType | operator++ (int) |
Postfix increment. | |
operator ParticleSet () const | |
Conversion of ParticleType to ParticleSet. | |
int | getIndex () const |
This particle's index in the associated set. | |
const TParticlePDG * | getParticlePDG () const |
Accessor for ROOT TParticlePDG object. | |
int | getPDGCode () const |
PDG code. | |
double | getMass () const |
Particle mass. | |
std::string | __repr__ () const |
String for printing in python. | |
Static Public Attributes | |
static const unsigned int | c_SetSize = 6 |
Number of elements (for use in array bounds etc.) | |
Private Attributes | |
int | m_pdgCode |
PDG code of the particle. | |
const ParticleSet * | m_set |
set this particle belongs to, or NULL if stand-alone. | |
int | m_index |
index in the associated set, -1 if there's no set. | |
Provides a type-safe way to pass members of the chargedStableSet set.
As the defined static members (Const::electron, etc. ) are members of this set, this also defines a fixed index from 0 to 4 for each particle.
|
inline |
Constructor from the more general ParticleType.
Throws a runtime_error if p is not in chargedStableSet.
Definition at line 596 of file Const.h.
|
inlineexplicit |
|
inherited |
String for printing in python.
Definition at line 361 of file UnitConst.cc.
|
inlineinherited |
This particle's index in the associated set.
In case the particle has no set, -1 is returned.
Definition at line 461 of file Const.h.
|
inherited |
|
inherited |
Accessor for ROOT TParticlePDG object.
Definition at line 351 of file UnitConst.cc.
|
inlineinherited |
|
inlineinherited |
Conversion of ParticleType to ParticleSet.
Definition at line 455 of file Const.h.
|
inlineinherited |
|
inlineinherited |
|
inherited |
Prefix increment.
Incrementing past the last element of a set will return an invalid particle.
Definition at line 333 of file UnitConst.cc.
|
inherited |
Postfix increment.
Incrementing past the last element of a set will yield an invalid particle.
Definition at line 344 of file UnitConst.cc.
|
inherited |
Comparison operator to be usable in sets.
other | the type of the other particle for the comparison. |
Definition at line 328 of file UnitConst.cc.
|
inlineinherited |
|
static |
|
privateinherited |
|
privateinherited |