java.lang.Object
org.maxicp.cp.engine.core.AbstractCPConstraint
org.maxicp.cp.engine.constraints.AtLeastNValueDC
- All Implemented Interfaces:
CPConstraint,ConcreteConstraint<ConcreteCPModel>
- Direct Known Subclasses:
AllDifferentDC
Domain Consistency Filtering for AtLeastNValue constraint.
- Author:
- Pierre Schaus pschaus@gmail.com
-
Constructor Summary
ConstructorsConstructorDescriptionAtLeastNValueDC(CPIntVar[] x, CPIntVar nVal) AtLeastNValueDC(CPIntVar[] x, CPIntVar nval, boolean dontPostFWC) -
Method Summary
Modifier and TypeMethodDescriptionintgetValInBestAssignment(int i) booleanhasValInBestAssignment(int i) voidpost()Initializes the constraint when it is posted to the solver.voidPropagates the constraint.Methods inherited from class org.maxicp.cp.engine.core.AbstractCPConstraint
getSolver, isActive, isScheduled, priority, registerDelta, setActive, setScheduled, updateDeltas
-
Constructor Details
-
AtLeastNValueDC
-
AtLeastNValueDC
-
-
Method Details
-
post
public void post()Description copied from interface:CPConstraintInitializes the constraint when it is posted to the solver.- Specified by:
postin interfaceCPConstraint- Overrides:
postin classAbstractCPConstraint
-
hasValInBestAssignment
public boolean hasValInBestAssignment(int i) -
getValInBestAssignment
public int getValInBestAssignment(int i) -
propagate
public void propagate()Description copied from interface:CPConstraintPropagates the constraint.- Specified by:
propagatein interfaceCPConstraint- Overrides:
propagatein classAbstractCPConstraint
-