BDSIM
BDSIM is a Geant4 extension toolkit for simulation of particle transport in accelerator beamlines.
|
Modulator class for parser. More...
#include <modulator.h>
Public Member Functions | |
Modulator () | |
Constructor. | |
void | clear () |
Reset. | |
void | print () const |
Print some properties. | |
template<typename T > | |
void | set_value (std::string property, T value) |
Set methods by property name and value. | |
![]() | |
bool | NameExists (const std::string &name) const |
Published< Modulator >::template AttributeMap< T > & | attribute_map () const |
Data Fields | |
std::string | name |
std::string | type |
double | frequency |
frequency of modulation on top of rf cavity in Hz | |
double | phase |
phase of modulation oscillator on top of rf cavity | |
double | tOffset |
time offset used for phase calculation (ns) for modulator on top of rf cavity | |
double | amplitudeOffset |
numerical value added to -1 -> 1 modulator as offset | |
double | amplitudeScale |
multiplier for amplitude of modulation | |
double | T0 |
'on' time | |
double | T1 |
'off' time | |
Private Member Functions | |
void | PublishMembers () |
publish members | |
Additional Inherited Members | |
![]() | |
using | AttributeMap = typename std::unordered_map< std::string, T C::* > |
Define AttributeMap of string and class member pointer. | |
![]() | |
void | publish (const std::string &name, T C::*mp) |
Make pointer to member from class C and type T with accessible with a name. | |
void | set (Modulator *instance, const Modulator *instance2, const std::string &name) |
Set member with name of class instance to value of second instance. | |
AttributeMap< T > & | attribute_map () const |
Access method to static map for type T and class C. | |
T | get (const Modulator *instance, const std::string &name) const |
Get method for class C. | |
void | set (Modulator *instance, const std::string &name, double value) |
void | set (Modulator *instance, const std::string &name, GMAD::Array *const &value) |
void | set (Modulator *instance, const std::string &name, const T &value) |
Modulator class for parser.
Definition at line 36 of file modulator.h.
Modulator::Modulator | ( | ) |
Constructor.
Definition at line 23 of file modulator.cc.
References clear(), and PublishMembers().
void Modulator::clear | ( | ) |
Reset.
Definition at line 29 of file modulator.cc.
References amplitudeOffset, amplitudeScale, frequency, phase, T0, T1, and tOffset.
Referenced by Modulator().
void Modulator::print | ( | ) | const |
Print some properties.
Definition at line 55 of file modulator.cc.
References amplitudeOffset, amplitudeScale, frequency, phase, T0, T1, and tOffset.
|
private |
publish members
Definition at line 42 of file modulator.cc.
References amplitudeOffset, amplitudeScale, frequency, phase, GMAD::Published< Modulator >::publish(), T0, T1, and tOffset.
Referenced by Modulator().
void GMAD::Modulator::set_value | ( | std::string | property, |
T | value | ||
) |
Set methods by property name and value.
Definition at line 66 of file modulator.h.
References GMAD::Published< Modulator >::set().
double GMAD::Modulator::amplitudeOffset |
numerical value added to -1 -> 1 modulator as offset
Definition at line 44 of file modulator.h.
Referenced by clear(), print(), and PublishMembers().
double GMAD::Modulator::amplitudeScale |
multiplier for amplitude of modulation
Definition at line 45 of file modulator.h.
Referenced by clear(), print(), and PublishMembers().
double GMAD::Modulator::frequency |
frequency of modulation on top of rf cavity in Hz
Definition at line 41 of file modulator.h.
Referenced by clear(), print(), and PublishMembers().
std::string GMAD::Modulator::name |
Definition at line 39 of file modulator.h.
double GMAD::Modulator::phase |
phase of modulation oscillator on top of rf cavity
Definition at line 42 of file modulator.h.
Referenced by clear(), print(), and PublishMembers().
double GMAD::Modulator::T0 |
'on' time
Definition at line 47 of file modulator.h.
Referenced by clear(), print(), and PublishMembers().
double GMAD::Modulator::T1 |
'off' time
Definition at line 48 of file modulator.h.
Referenced by clear(), print(), and PublishMembers().
double GMAD::Modulator::tOffset |
time offset used for phase calculation (ns) for modulator on top of rf cavity
Definition at line 43 of file modulator.h.
Referenced by clear(), print(), and PublishMembers().
std::string GMAD::Modulator::type |
Definition at line 40 of file modulator.h.