|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectchoco.kernel.solver.propagation.Propagator
choco.kernel.solver.constraints.AbstractSConstraint<IntDomainVar>
choco.kernel.solver.constraints.integer.AbstractIntSConstraint
choco.kernel.solver.constraints.integer.AbstractBinIntSConstraint
choco.cp.solver.constraints.integer.Element
public final class Element
Field Summary |
---|
Fields inherited from class choco.kernel.solver.constraints.integer.AbstractBinIntSConstraint |
---|
v0, v1 |
Fields inherited from class choco.kernel.solver.constraints.AbstractSConstraint |
---|
cIndices, constraintType, extensions, vars |
Fields inherited from class choco.kernel.solver.propagation.Propagator |
---|
active, constAwakeEvent, priority, propagationEngine |
Fields inherited from interface choco.kernel.solver.constraints.SConstraint |
---|
LOGGER |
Constructor Summary | |
---|---|
Element(IntDomainVar index,
int[] values,
IntDomainVar var)
|
|
Element(IntDomainVar index,
int[] values,
IntDomainVar var,
int offset)
|
Method Summary | |
---|---|
void |
awake()
Propagation: Propagating the constraint for the very first time until local consistency is reached. |
void |
awakeOnInst(int i)
Default propagation on instantiation: full constraint re-propagation. |
void |
awakeOnRem(int i,
int x)
Default propagation on one value removal: propagation on domain revision. |
Object |
clone()
Clone the constraint |
int |
getFilteredEventMask(int idx)
|
Boolean |
isEntailed()
Indicates if the constraint is entailed, from now on will be always satisfied |
boolean |
isSatisfied(int[] tuple)
TEMPORARY: if not overriden by the constraint, throws an error to avoid bug using reified constraints in constraints that have not been changed to fulfill this api yet ! |
String |
pretty()
pretty printing of the object. |
void |
propagate()
Propagation: Propagating the constraint until local consistency is reached. |
String |
toString()
|
protected void |
updateIndexFromValue()
|
protected void |
updateValueFromIndex()
|
Methods inherited from class choco.kernel.solver.constraints.integer.AbstractIntSConstraint |
---|
awakeOnBounds, awakeOnInf, awakeOnRemovals, awakeOnSup, getConstraintType, isConsistent, isSatisfied |
Methods inherited from class choco.kernel.solver.constraints.AbstractSConstraint |
---|
addExtension, addListener, getAbstractSConstraintExtensionNumber, getConstraintIdx, getExtension, getFineDegree, getNbVarNotInst, getNbVars, getVar, getVarQuick, isCompletelyInstantiated, opposite, setConstraintIndex, setExtension, setVar |
Methods inherited from class choco.kernel.solver.propagation.Propagator |
---|
activate, constAwake, fail, getEvent, getPriority, isActive, setActive, setActiveSilently, setEntailed, setPassive, setPropagationEngine |
Methods inherited from class java.lang.Object |
---|
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public Element(IntDomainVar index, int[] values, IntDomainVar var, int offset)
public Element(IntDomainVar index, int[] values, IntDomainVar var)
Method Detail |
---|
public Object clone() throws CloneNotSupportedException
AbstractSConstraint
clone
in class AbstractSConstraint<IntDomainVar>
CloneNotSupportedException
- Clone not supported exceptionpublic String toString()
toString
in class AbstractSConstraint<IntDomainVar>
public int getFilteredEventMask(int idx)
getFilteredEventMask
in class Propagator
public void propagate() throws ContradictionException
propagate
in class Propagator
ContradictionException
- contradiction exceptionpublic String pretty()
IPretty
pretty
in interface IPretty
pretty
in class AbstractSConstraint<IntDomainVar>
protected void updateValueFromIndex() throws ContradictionException
ContradictionException
protected void updateIndexFromValue() throws ContradictionException
ContradictionException
public void awake() throws ContradictionException
Propagator
awake
in class Propagator
ContradictionException
- contradiction exceptionpublic void awakeOnInst(int i) throws ContradictionException
AbstractIntSConstraint
awakeOnInst
in interface IntPropagator
awakeOnInst
in class AbstractIntSConstraint
ContradictionException
public void awakeOnRem(int i, int x) throws ContradictionException
AbstractIntSConstraint
awakeOnRem
in interface IntPropagator
awakeOnRem
in class AbstractIntSConstraint
ContradictionException
public Boolean isEntailed()
AbstractSConstraint
isEntailed
in class AbstractSConstraint<IntDomainVar>
public boolean isSatisfied(int[] tuple)
AbstractIntSConstraint
isSatisfied
in interface IntPropagator
isSatisfied
in class AbstractIntSConstraint
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |