AmpGen
2.1
Toggle main menu visibility
Loading...
Searching...
No Matches
ParticlePropertiesList.h
Go to the documentation of this file.
1
#ifndef AMPGEN_PARTICLEPROPERTIESLIST_H
2
#define AMPGEN_PARTICLEPROPERTIESLIST_H
3
// author: Jonas Rademacker (Jonas.Rademacker@bristol.ac.uk)
4
// status: Mon 9 Feb 2009 19:18:04 GMT
5
6
#include <iostream>
7
#include <map>
8
#include <string>
9
#include <utility>
10
#include <vector>
11
12
#include "
AmpGen/ParticleProperties.h
"
13
14
namespace
AmpGen
{
15
class
ParticlePropertiesList {
16
static
ParticlePropertiesList *ptr;
17
std::map<int, std::pair<std::string, std::string>> m_latexLabels;
18
std::string m_fname;
19
std::vector<ParticleProperties> m_theList;
20
std::map<std::string, ParticleProperties *> m_byName;
21
std::map<int, ParticleProperties *> m_byID;
22
23
explicit
ParticlePropertiesList(
const
std::string &fname_in =
"mass_width.csv"
);
24
25
protected
:
26
const
std::vector<std::string>
dirList
()
const
;
27
28
public
:
29
bool
readFile
(
const
std::string &fname);
30
static
const
ParticlePropertiesList *
getMe
();
31
static
ParticlePropertiesList *
getMutable
();
32
static
const
ParticleProperties
*
get
(
const
std::string &name,
const
bool
&quiet =
false
);
33
static
const
ParticleProperties
*
get
(
const
int
&PDG,
const
bool
&quiet =
false
);
34
void
makeAlias
(
const
std::string &name,
const
std::string &alias);
35
const
ParticleProperties
*
find
(
const
std::string &name,
bool
quiet =
false
)
const
;
36
const
ParticleProperties
*
find
(
int
pdg_id,
bool
quiet =
false
)
const
;
37
38
std::vector<std::string>
getParticleNames
()
const
;
39
std::vector<int>
getParticleIds
()
const
;
40
41
std::vector<ParticleProperties>::const_iterator
begin
()
const
{
return
m_theList.cbegin(); }
42
std::vector<ParticleProperties>::const_iterator
end
()
const
{
return
m_theList.cend(); }
43
void
print
(std::ostream &out = std::cout)
const
;
44
bool
readLatexLabels
(
const
std::string &name);
45
void
makeMappings
();
46
void
addParticle
(
const
std::vector<std::string> &properties);
47
};
48
std::ostream &
operator<<
(std::ostream &out,
const
ParticlePropertiesList
&ppl);
49
}
// namespace AmpGen
50
#endif
ParticleProperties.h
AmpGen::ParticleProperties
Class that contains the PDG properties (mass, width, charges, etc.) for a single particle species,...
Definition
ParticleProperties.h:24
AmpGen::ParticlePropertiesList
Definition
ParticlePropertiesList.h:15
AmpGen::ParticlePropertiesList::get
static const ParticleProperties * get(const int &PDG, const bool &quiet=false)
AmpGen::ParticlePropertiesList::getMe
static const ParticlePropertiesList * getMe()
AmpGen::ParticlePropertiesList::readFile
bool readFile(const std::string &fname)
AmpGen::ParticlePropertiesList::getParticleIds
std::vector< int > getParticleIds() const
AmpGen::ParticlePropertiesList::readLatexLabels
bool readLatexLabels(const std::string &name)
AmpGen::ParticlePropertiesList::find
const ParticleProperties * find(const std::string &name, bool quiet=false) const
AmpGen::ParticlePropertiesList::get
static const ParticleProperties * get(const std::string &name, const bool &quiet=false)
AmpGen::ParticlePropertiesList::end
std::vector< ParticleProperties >::const_iterator end() const
Definition
ParticlePropertiesList.h:42
AmpGen::ParticlePropertiesList::begin
std::vector< ParticleProperties >::const_iterator begin() const
Definition
ParticlePropertiesList.h:41
AmpGen::ParticlePropertiesList::find
const ParticleProperties * find(int pdg_id, bool quiet=false) const
AmpGen::ParticlePropertiesList::makeMappings
void makeMappings()
AmpGen::ParticlePropertiesList::dirList
const std::vector< std::string > dirList() const
AmpGen::ParticlePropertiesList::getMutable
static ParticlePropertiesList * getMutable()
AmpGen::ParticlePropertiesList::addParticle
void addParticle(const std::vector< std::string > &properties)
AmpGen::ParticlePropertiesList::print
void print(std::ostream &out=std::cout) const
AmpGen::ParticlePropertiesList::makeAlias
void makeAlias(const std::string &name, const std::string &alias)
AmpGen::ParticlePropertiesList::getParticleNames
std::vector< std::string > getParticleNames() const
AmpGen
Definition
AddCPConjugate.h:2
AmpGen::operator<<
std::ostream & operator<<(std::ostream &os, const CompiledExpressionBase &expression)
AmpGen
ParticlePropertiesList.h
Generated on
for AmpGen by
1.17.0