Gecode::FloatVar Gecode::VarImpVar< Float::FloatVarImp > float.hh
Constructors and initialization
forceinline Gecode::FloatVar::FloatVar (void) FloatVar void Default constructor. forceinline Gecode::FloatVar::FloatVar (const FloatVar &y) FloatVar const FloatVar & y Initialize from float variable y. forceinline Gecode::FloatVar::FloatVar (const Float::FloatView &y) FloatVar const Float::FloatView & y Initialize from float view y. GECODE_FLOAT_EXPORT GECODE_FLOAT_EXPORT Gecode::FloatVar::FloatVar (Space &home, FloatNum min, FloatNum max) FloatVar Space & home FloatNum min FloatNum max Initialize variable with range domain. The variable is created with a domain ranging from min to max. The following exceptions might be thrown: If min is greater than max, an exception of type Gecode::Float::VariableEmptyDomain is thrown.If min or max exceed the limits for floats as defined in Gecode::Float::Limits, an exception of type Gecode::Float::OutOfLimits is thrown.
Value access
FloatVal forceinline FloatVal Gecode::FloatVar::domain (void) const domain void Return domain. FloatNum forceinline FloatNum Gecode::FloatVar::min (void) const min void Return minimum of domain. FloatNum forceinline FloatNum Gecode::FloatVar::max (void) const max void Return maximum of domain. FloatNum forceinline FloatNum Gecode::FloatVar::med (void) const med void Return median of domain. FloatNum forceinline FloatNum Gecode::FloatVar::size (void) const size void Return size of domain (distance between maximum and minimum) FloatVal forceinline FloatVal Gecode::FloatVar::val (void) const val void Return assigned value. Throws an exception of type Float::ValOfUnassignedVar if variable is not yet assigned.
Domain tests
bool forceinline bool Gecode::FloatVar::in (const FloatVal &n) const in const FloatVal & n Test whether n is contained in domain.
friend class friend class FloatVarArray FloatVarArray friend class friend class FloatVarArgs FloatVarArgs void forceinline void Gecode::FloatVar::_init (Space &home, FloatNum min, FloatNum max) _init Space & home FloatNum min FloatNum max Initialize variable with range domain. The variable is created with a domain ranging from min to max. No exceptions are thrown. class Char class Traits std::basic_ostream< Char, Traits > & std::basic_ostream< Char, Traits > & operator<< (std::basic_ostream< Char, Traits > &os, const FloatVar &x) operator<< std::basic_ostream< Char, Traits > & os const FloatVar & x Print float variable x. Float variables. x dom x Gecode::FloatVar_init Gecode::FloatVarafc Gecode::FloatVarassigned Gecode::FloatVarbefore Gecode::FloatVardegree Gecode::FloatVardomain Gecode::FloatVarFloatVar Gecode::FloatVarFloatVar Gecode::FloatVarFloatVar Gecode::FloatVarFloatVar Gecode::FloatVarFloatVarArgs Gecode::FloatVarFloatVarArray Gecode::FloatVarin Gecode::FloatVarmax Gecode::FloatVarmed Gecode::FloatVarmin Gecode::FloatVaroperator<< Gecode::FloatVarsame Gecode::FloatVarsize Gecode::FloatVarupdate Gecode::FloatVarval Gecode::FloatVarvarimp Gecode::FloatVarVarImpType Gecode::FloatVarVarImpVar Gecode::FloatVarVarImpVar Gecode::FloatVarx