BDSIM
BDSIM is a Geant4 extension toolkit for simulation of particle transport in accelerator beamlines.
|
#include <material.h>
Public Member Functions | |
Material () | |
constructor More... | |
void | clear () |
reset More... | |
void | print () const |
printout More... | |
template<typename T > | |
void | set_value (const std::string &property, T value) |
set methods by property name and value More... | |
void | set_value (const std::string &property, Array *value) |
Set method for lists. More... | |
![]() | |
bool | NameExists (const std::string &name) const |
Published< Material >::template AttributeMap< T > & | attribute_map () const |
Data Fields | |
std::string | name |
name More... | |
double | A |
g*mol^-1 More... | |
double | Z |
double | density |
g*cm-3 More... | |
double | temper |
Kelvin. More... | |
double | pressure |
atm More... | |
std::string | state |
"solid", "liquid", or "gas" More... | |
std::list< std::string > | components |
std::list< double > | componentsFractions |
std::list< int > | componentsWeights |
Private Member Functions | |
void | PublishMembers () |
publish members so these can be looked up from parser More... | |
Additional Inherited Members | |
![]() | |
using | AttributeMap = typename std::unordered_map< std::string, T C::* > |
Define AttributeMap of string and class member pointer. More... | |
![]() | |
void | publish (const std::string &name, T C::*mp) |
Make pointer to member from class C and type T with accessible with a name. More... | |
void | set (Material *instance, const Material *instance2, const std::string &name) |
Set member with name of class instance to value of second instance. More... | |
AttributeMap< T > & | attribute_map () const |
Access method to static map for type T and class C. | |
T | get (const Material *instance, const std::string &name) const |
Get method for class C. More... | |
void | set (Material *instance, const std::string &name, double value) |
void | set (Material *instance, const std::string &name, GMAD::Array *const &value) |
void | set (Material *instance, const std::string &name, const T &value) |
Material class.
Definition at line 39 of file material.h.
Material::Material | ( | ) |
constructor
Definition at line 25 of file material.cc.
References clear(), and PublishMembers().
void Material::clear | ( | ) |
reset
Definition at line 31 of file material.cc.
References A, density, pressure, state, and temper.
Referenced by Material().
void Material::print | ( | ) | const |
|
private |
publish members so these can be looked up from parser
Definition at line 45 of file material.cc.
References A, density, name, pressure, GMAD::Published< Material >::publish(), state, and temper.
Referenced by Material().
void Material::set_value | ( | const std::string & | property, |
Array * | value | ||
) |
Set method for lists.
Definition at line 77 of file material.cc.
References GMAD::Array::set_vector().
void GMAD::Material::set_value | ( | const std::string & | property, |
T | value | ||
) |
set methods by property name and value
Definition at line 72 of file material.h.
References GMAD::Published< Material >::set().
double GMAD::Material::A |
g*mol^-1
Definition at line 43 of file material.h.
Referenced by clear(), print(), and PublishMembers().
std::list<std::string> GMAD::Material::components |
Definition at line 49 of file material.h.
std::list<double> GMAD::Material::componentsFractions |
Definition at line 50 of file material.h.
std::list<int> GMAD::Material::componentsWeights |
Definition at line 51 of file material.h.
double GMAD::Material::density |
g*cm-3
Definition at line 45 of file material.h.
Referenced by clear(), print(), and PublishMembers().
std::string GMAD::Material::name |
double GMAD::Material::pressure |
std::string GMAD::Material::state |
"solid", "liquid", or "gas"
Definition at line 48 of file material.h.
Referenced by clear(), print(), and PublishMembers().
double GMAD::Material::temper |
Kelvin.
Definition at line 46 of file material.h.
Referenced by clear(), print(), and PublishMembers().
double GMAD::Material::Z |
Definition at line 44 of file material.h.