14package com.google.ortools.modelbuilder;
20 this.index = helper.addEnforcedLinearConstraint();
25 throw new IllegalArgumentException(
26 "the given index does not refer to an enforced linear constraint");
44 return helper.getEnforcedConstraintLowerBound(index);
49 helper.setEnforcedConstraintLowerBound(index, lb);
54 return helper.getEnforcedConstraintUpperBound(index);
59 helper.setEnforcedConstraintUpperBound(index, ub);
64 return helper.getEnforcedConstraintName(index);
69 helper.setEnforcedConstraintName(index, name);
74 helper.safeAddEnforcedConstraintTerm(index, v.
getIndex(), coeff);
79 helper.setEnforcedConstraintCoefficient(index, v.
getIndex(), coeff);
84 helper.clearEnforcedConstraintTerms(index);
89 return new Variable(helper, helper.getEnforcedIndicatorVariableIndex(index));
94 helper.setEnforcedIndicatorVariableIndex(index, v.
index);
99 return helper.getEnforcedIndicatorValue(index);
104 helper.setEnforcedIndicatorValue(index, b);
114 private final int index;