BornAgain
1.19.0
Simulate and fit neutron and x-ray scattering at grazing incidence
|
Wraps a parameter of type double. More...
Public Member Functions | |
RealParameter (const std::string &name, double *par, const std::string &parent_name="", const std::function< void()> &onChange=std::function< void()>(), const RealLimits &limits=RealLimits::limitless(), const Attributes &attr=Attributes::free()) | |
RealParameter * | clone (const std::string &new_name="") const |
RealLimits | limits () const |
RealParameter & | setLimited (double lower, double upper) |
RealParameter & | setLimits (const RealLimits &limits) |
RealParameter & | setNonnegative () |
RealParameter & | setPositive () |
RealParameter & | setUnit (const std::string &name) |
void | setValue (double value) |
Sets value of wrapped parameter and emit signal. | |
std::string | unit () const |
double | value () const |
Returns value of wrapped parameter. | |
Protected Attributes | |
Attributes | m_attr |
RealLimits | m_limits |
Unit | m_unit |
Wraps a parameter of type double.
In addition to name and on-change callback held by the parent class IParameter, this class holds Limits, Attributes (currently only fixed or not), and a Unit.