GeneralConstraintDefinition
Definition of a general constraint. More...
#include <xpress_objects.hpp>

Public Member Functions |
|
template<typename Strm0 , typename Strm0IsStream = typename std::enable_if<xpress::is_stream<Strm0>::value>::type> | |
GeneralConstraintDefinition (Variable resultant, xpress::GenConsType type, Strm0 const &variables, std::optional< std::string > name) | |
Create a general constraint description. |
|
template<typename Strm0 , typename Strm1 , typename Strm0IsStream = typename std::enable_if<xpress::is_stream<Strm0>::value>::type, typename Strm1IsStream = typename std::enable_if<xpress::is_stream<Strm1>::value>::type> | |
GeneralConstraintDefinition (Variable resultant, xpress::GenConsType type, Strm0 const &variables, Strm1 const &value, std::optional< std::string > name) | |
Create a general constraint description. |
|
template<typename... VARIABLES, typename RestrictPack = typename std::enable_if<xpress::AllConvertible<Variable, VARIABLES...>::value>::type> | |
GeneralConstraintDefinition (Variable resultant, xpress::GenConsType type, VARIABLES... variables) | |
Create a general constraint description. |
|
GeneralConstraintDefinition (Variable resultant, xpress::GenConsType type, xpress::SizedArray< Variable const > const &variables) | |
Create a general constraint description. |
|
GeneralConstraintDefinition (Variable resultant, xpress::GenConsType type, xpress::SizedArray< Variable const > const &variables, xpress::SizedArray< double const > const &values) | |
Create a general constraint description. |
|
auto | setName (std::optional< std::string > newName) -> GeneralConstraintDefinition & |
Set the name of the constraint. |
|
Public Member Functions inherited from xpress::objects::ConstraintDefinition< GeneralConstraint > | |
virtual auto | getName () const -> std::optional< std::string > |
Get the name of this constraint. |
|
virtual auto | setConstraintName (std::optional< std::string > newName) -> ConstraintDefinition< GeneralConstraint > &final |
Set the name of this constraint. |
|
Detailed Description
Definition of a general constraint.
Instances of this class describe a constraint that has not yet been added but can be added using XpressProblem.addConstraint()
or XpressProblem.addConstraints()
. Users should usually not have to deal with this class explicitly.
- Since
- 44.00
Constructor & Destructor Documentation
GeneralConstraintDefinition() [1/5]
|
inline |
Create a general constraint description.
In order to actually add this constraint to a problem you must use the problem's addConstraint
function.
- Parameters
-
resultant The resultant variable. type Type of constraint. variables The variables in the general constraint. May be nullptr
.value The values in the general constraint. May be nullptr
.name The name of the general constraint. May be std::nullopt
.
- Template Parameters
-
Strm0 Something that supports begin()
andend()
and contains values of typeVariable
.Strm1 Something that supports begin()
andend()
and contains values of typedouble
.
- Since
- 44.00
GeneralConstraintDefinition() [2/5]
|
inline |
Create a general constraint description.
In order to actually add this constraint to a problem you must use the problem's addConstraint
function.
- Parameters
-
resultant The resultant variable. type Type of constraint. variables The variables in the general constraint. May be nullptr
.name Constraint name. May be std::nullopt
.
- Template Parameters
-
Strm0 Something that supports begin()
andend()
and contains values of typeVariable
.
- Since
- 44.00
GeneralConstraintDefinition() [3/5]
|
inline |
Create a general constraint description.
In order to actually add this constraint to a problem you must use the problem's addConstraint
function.
- Parameters
-
resultant The resultant variable. type Type of constraint. variables The variables in the general constraint. May be nullptr
.
- Since
- 44.00
GeneralConstraintDefinition() [4/5]
|
inline |
Create a general constraint description.
In order to actually add this constraint to a problem you must use the problem's addConstraint
function.
- Parameters
-
resultant The resultant variable. type Type of constraint. variables The variables in the general constraint. May be nullptr
.
- Since
- 44.00
GeneralConstraintDefinition() [5/5]
|
inline |
Create a general constraint description.
In order to actually add this constraint to a problem you must use the problem's addConstraint
function.
- Parameters
-
resultant The resultant variable. type Type of constraint. variables The variables in the general constraint. May be nullptr
.values The values in the general constraint. May be nullptr
.
- Since
- 44.00
Member Function Documentation
setName()
|
inline |
Set the name of the constraint.
This is the same as ConstraintDefinition#setConstraintName(std::optional<std::string>)
but with a different return type.
- Parameters
-
newName New name.
- Returns
- Always returns this instance.
- Since
- 44.00
The documentation for this class was generated from the following file:
- xpress_objects.hpp
© 2001-2025 Fair Isaac Corporation. All rights reserved. This documentation is the property of Fair Isaac Corporation (“FICO”). Receipt or possession of this documentation does not convey rights to disclose, reproduce, make derivative works, use, or allow others to use it except solely for internal evaluation purposes to determine whether to purchase a license to the software described in this documentation, or as otherwise set forth in a written software license agreement between you and FICO (or a FICO affiliate). Use of this documentation and the software described in it must conform strictly to the foregoing permitted uses, and no other use is permitted.