56 throw Exception(
"ConstantDistribution::restrictToConstraint: Non-interval exception");
virtual void restrictToConstraint(const ConstraintInterface &c)
Restricts the distribution to the domain where the constraint is respected, in addition of other pred...
ConstantDistribution & operator=(const ConstantDistribution &)
Partial implementation of the DiscreteDistribution interface.
An interval, either bounded or not, which can also have infinite bounds.
The constraint interface.
This class is designed to facilitate the manipulation of parameters.
void addParameter_(Parameter *parameter)
virtual void setConstraint(std::shared_ptr< ConstraintInterface > constraint)
Set a constraint to this parameter.
double getParameterValue(const std::string &name) const override
Get the value for parameter of name 'name'.
The parameter list object.
virtual void fireParameterChanged(const ParameterList ¶meters)
Notify the class when one or several parameters have changed.
AbstractDiscreteDistribution & operator=(const AbstractDiscreteDistribution &adde)
std::shared_ptr< IntervalConstraint > intMinMax_
the interval where the distribution is defined/restricted.
std::map< double, double, Order > distribution_
ConstantDistribution(double value)
Builds a new ConstantDistribution object from a value.
Exception base class. Overload exception constructor (to control the exceptions mechanism). Destructor is already virtual (from std::exception)
Constant discrete distribution.
void restrictToConstraint(const ConstraintInterface &c)
Restricts the distribution to the domain where the constraint is respected, in addition of other pred...
Exception thrown when a value do not match a given constraint.
Parameter & getParameter_(const std::string &name)
void fireParameterChanged(const ParameterList ¶meters)
Notify the class when one or several parameters have changed.
size_t getNumberOfParameters() const override
Get the number of parameters.
virtual bool isCorrect(double value) const override
Tell if a given value is correct.