}
}
protected void backPropRemPoss() throws ContradictionException {
for (int i = poss.getFirstElement(); i >= 0; i = poss.getNextElement()) {
IntVar v = vars[i];
if (v.hasEnumeratedDomain()) {
for (int value : values) {
v.removeValue(value, this);
}
poss.remove(i);
} else {
int newLB = v.getLB();
int newUB = v.getUB();
for (int val = v.getLB(); val <= newUB; val = v.nextValue(val)) {
if (setValues.contains(val)) {
newLB = val + 1;
} else {
break;
}
}
for (int val = newUB; val >= newLB; val = v.previousValue(val)) {
if (setValues.contains(val)) {
newUB = val - 1;
} else {
break;
}
}
v.updateLowerBound(newLB, this);
v.updateUpperBound(newUB, this);
if (newLB > values[values.length - 1] || newUB < values[0]) {
poss.remove(i);
}
}
}