ATLAS Offline Software
|
Hold information about an option setting request. More...
#include <AuxDataOption.h>
Public Member Functions | |
AuxDataOption (const std::string &name, int val) | |
Constructor, with an integer value. More... | |
AuxDataOption (const std::string &name, float val) | |
Constructor, with a float value. More... | |
AuxDataOption (const std::string &name, double val) | |
Constructor, with a double value. More... | |
const std::string & | name () const |
The name of the option. More... | |
int | intVal () const |
Return the option value as an integer. More... | |
float | floatVal () const |
Return the option value as a float. More... | |
Private Attributes | |
std::string | m_name |
The option name. More... | |
bool | m_isInt |
Are we holding an int or a float? More... | |
union { | |
float f | |
int i | |
} | m_val |
The stored value. More... | |
Hold information about an option setting request.
This is used to pass an option setting through the setOption
interface, which is used to decouple the user interface from the auxiliary store representation classes.
This class holds a name and a value, which can be either an int or a float.
Definition at line 36 of file AuxDataOption.h.
SG::AuxDataOption::AuxDataOption | ( | const std::string & | name, |
int | val | ||
) |
Constructor, with an integer value.
name | The option name. |
val | The option value. |
SG::AuxDataOption::AuxDataOption | ( | const std::string & | name, |
float | val | ||
) |
Constructor, with a float value.
name | The option name. |
val | The option value. |
SG::AuxDataOption::AuxDataOption | ( | const std::string & | name, |
double | val | ||
) |
Constructor, with a double value.
name | The option name. |
val | The option value. |
float SG::AuxDataOption::floatVal | ( | ) | const |
Return the option value as a float.
int SG::AuxDataOption::intVal | ( | ) | const |
Return the option value as an integer.
const std::string& SG::AuxDataOption::name | ( | ) | const |
The name of the option.
float SG::AuxDataOption::f |
Definition at line 90 of file AuxDataOption.h.
int SG::AuxDataOption::i |
Definition at line 91 of file AuxDataOption.h.
|
private |
Are we holding an int or a float?
Definition at line 86 of file AuxDataOption.h.
|
private |
The option name.
Definition at line 83 of file AuxDataOption.h.
union { ... } SG::AuxDataOption::m_val |
The stored value.