Module org.chocosolver
Class PropCondAllDiffInst
- java.lang.Object
-
- org.chocosolver.solver.constraints.Propagator<IntVar>
-
- org.chocosolver.solver.constraints.nary.alldifferent.PropAllDiffInst
-
- org.chocosolver.solver.constraints.nary.alldifferent.conditions.PropCondAllDiffInst
-
- All Implemented Interfaces:
Comparable<Propagator>
,ICause
,Identity
public class PropCondAllDiffInst extends PropAllDiffInst
Propagator for ConditionnalAllDifferent that only reacts on instantiation- Author:
- Jean-Guillaume Fages
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.chocosolver.solver.constraints.nary.alldifferent.PropAllDiffInst
PropAllDiffInst.FastResetArrayStack
-
-
Field Summary
-
Fields inherited from class org.chocosolver.solver.constraints.nary.alldifferent.PropAllDiffInst
n, toCheck
-
Fields inherited from class org.chocosolver.solver.constraints.Propagator
ACTIVE, constraint, DEFAULT_EXPL, model, operations, OUTPUT_DEFAULT_EXPL, priority, reactToFineEvt, state, vars
-
-
Constructor Summary
Constructors Constructor Description PropCondAllDiffInst(IntVar[] variables, Condition c, boolean mode)
ConditionnalAllDifferent constraint for integer variables enables to control the cardinality of the matching IF mode for all X in vars, condition(X) => X !
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
fixpoint()
ESat
isEntailed()
Check wetherthis
is entailed according to the current state of its internal structure.-
Methods inherited from class org.chocosolver.solver.constraints.nary.alldifferent.PropAllDiffInst
explain, getPropagationConditions, propagate, propagate
-
Methods inherited from class org.chocosolver.solver.constraints.Propagator
addVariable, arity, compareTo, defaultExplain, doFinePropagation, doFlush, doSchedule, doScheduleEvent, dynPriority, equals, fails, forcePropagate, forcePropagationOnBacktrack, forEachIntVar, getConstraint, getId, getModel, getNbVars, getPosition, getPriority, getVar, getVars, getVIndice, getVIndices, hashCode, isActive, isCompletelyInstantiated, isPassive, isReified, isReifiedAndSilent, isScheduled, isStateLess, linkVariables, reactToFineEvent, reifiedWith, setActive, setActive0, setPassive, setPosition, setReifiedSilent, setReifiedTrue, setVIndices, toString, unlinkVariables, unschedule
-
-
-
-
Constructor Detail
-
PropCondAllDiffInst
public PropCondAllDiffInst(IntVar[] variables, Condition c, boolean mode)
ConditionnalAllDifferent constraint for integer variables enables to control the cardinality of the matching IF mode for all X in vars, condition(X) => X != Y, for all Y in vars ELSE for all X,Y in vars, condition(X) AND condition(Y) => X != Y- Parameters:
variables
- array of integer variablesc
- a condition to define the subset of variables subject to the AllDiff cstrmode
- defines how to apply filtering
-
-
Method Detail
-
fixpoint
protected void fixpoint() throws ContradictionException
- Overrides:
fixpoint
in classPropAllDiffInst
- Throws:
ContradictionException
-
isEntailed
public ESat isEntailed()
Description copied from class:Propagator
Check wetherthis
is entailed according to the current state of its internal structure. At least, should check the satisfaction ofthis
(when all is instantiated).- Overrides:
isEntailed
in classPropAllDiffInst
- Returns:
- ESat.TRUE if entailed, ESat.FALSE if not entailed, ESat.UNDEFINED if unknown
-
-