Wrapper around a linear constraint stored in the ModelBuilderHelper instance.
More...
|
int | Index [get] |
| Returns the index of the constraint in the model.
|
|
ModelBuilderHelper | Helper [get] |
| Returns the constraint builder.
|
|
double | LowerBound [get, set] |
| The lower bound of the constraint.
|
|
double | UpperBound [get, set] |
| The upper bound of the constraint.
|
|
String | Name [get, set] |
| The name of the variable given upon creation.
|
|
Wrapper around a linear constraint stored in the ModelBuilderHelper instance.
Definition at line 27 of file ModelBuilderConstraint.cs.
◆ LinearConstraint() [1/2]
Google.OrTools.ModelBuilder.LinearConstraint.LinearConstraint |
( |
ModelBuilderHelper | helper | ) |
|
|
inline |
◆ LinearConstraint() [2/2]
Google.OrTools.ModelBuilder.LinearConstraint.LinearConstraint |
( |
ModelBuilderHelper | helper, |
|
|
int | index ) |
|
inline |
◆ AddTerm()
void Google.OrTools.ModelBuilder.LinearConstraint.AddTerm |
( |
Variable | var, |
|
|
double | coeff ) |
|
inline |
Adds var * coeff to the constraint.
- Parameters
-
var | the variable of the term to add |
coeff | the coefficient of the term to add |
Definition at line 105 of file ModelBuilderConstraint.cs.
◆ ClearTerms()
void Google.OrTools.ModelBuilder.LinearConstraint.ClearTerms |
( |
| ) |
|
|
inline |
◆ SetVariableCoefficient()
void Google.OrTools.ModelBuilder.LinearConstraint.SetVariableCoefficient |
( |
Variable | var, |
|
|
double | coeff ) |
|
inline |
Sets the coefficient of var to coeff, adding or removing a term if needed.
- Parameters
-
var | the variable of the term to set |
coeff | the coefficient of the term to set |
Definition at line 115 of file ModelBuilderConstraint.cs.
◆ WithName()
LinearConstraint Google.OrTools.ModelBuilder.LinearConstraint.WithName |
( |
String | name | ) |
|
|
inline |
◆ Helper
◆ Index
int Google.OrTools.ModelBuilder.LinearConstraint.Index |
|
get |
◆ LowerBound
double Google.OrTools.ModelBuilder.LinearConstraint.LowerBound |
|
getset |
◆ Name
String Google.OrTools.ModelBuilder.LinearConstraint.Name |
|
getset |
◆ UpperBound
double Google.OrTools.ModelBuilder.LinearConstraint.UpperBound |
|
getset |
The documentation for this class was generated from the following file: