BornAgain
1.18.0
Simulate and fit neutron and x-ray scattering at grazing incidence
|
Pure virtual base class for parameter wrapper classes RealParameter, ComponentParameter. More...
Public Member Functions | |
IParameter (const std::string &name, T *data, const std::string &parent_name, const std::function< void()> &onChange) | |
virtual IParameter * | clone (const std::string &new_name="") const =0 |
virtual bool | isNull () const |
Returns true if wrapped parameter was not initialized with proper real value. | |
T & | getData () const |
void | setData (T &data) |
bool | hasSameData (const IParameter &other) |
Returns true if two parameters are pointing to the same raw data. | |
const std::string & | getName () const |
Protected Member Functions | |
std::string | fullName () const |
For use in error messages. | |
Protected Attributes | |
const std::string | m_name |
T * | m_data |
const std::string | m_parent_name |
const std::function< void()> | m_onChange |
Pure virtual base class for parameter wrapper classes RealParameter, ComponentParameter.
Holds a pointer to the wrapped parameter, a name, and a callback function to be called when the parameter is changed. This class is templated on the data type of the wrapped parameter.
Definition at line 28 of file IParameter.h.