Package org.jacop.set.constraints
Class Lex
- java.lang.Object
-
- org.jacop.constraints.DecomposedConstraint<Constraint>
-
- org.jacop.constraints.Constraint
-
- org.jacop.set.constraints.Lex
-
- All Implemented Interfaces:
Stateful
@Deprecated public class Lex extends Constraint implements Stateful
Deprecated.As of release 4.5.1 replaced by AltB and AleB constraints.
-
-
Field Summary
Fields Modifier and Type Field Description SetVar
a
Deprecated.It specifies a list on which element a lex relationship holds for every two consecutive variables.SetVar
b
Deprecated.It specifies a list on which element a lex relationship holds for every two consecutive variables.(package private) static java.util.concurrent.atomic.AtomicInteger
idNumber
Deprecated.protected int
inclusionLevel
Deprecated.protected TimeStamp<IntDomain>
inDifference
Deprecated.protected int
inSupport
Deprecated.protected TimeStamp<IntDomain>
smallerDifference
Deprecated.protected int
smallerElLevel
Deprecated.protected int
smallerElSupport
Deprecated.boolean
strict
Deprecated.It specifies if the relation is strict or not.-
Fields inherited from class org.jacop.constraints.Constraint
atomicExecution, consistencyPruningEvents, constraintScope, earlyTerminationOK, increaseWeight, numberId, scope, trace
-
Fields inherited from class org.jacop.constraints.DecomposedConstraint
queueIndex
-
-
Constructor Summary
Constructors Constructor Description Lex(SetVar a, SetVar b)
Deprecated.It constructs an Lexical ordering constraint to restrict the domain of the variables a and b.Lex(SetVar a, SetVar b, boolean strict)
Deprecated.It constructs an Lexical ordering constraint to restrict the domain of the variables a and b.
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description void
consistency(Store store)
Deprecated.It is a (most probably incomplete) consistency function which removes the values from variables domains.int
getDefaultConsistencyPruningEvent()
Deprecated.void
impose(Store store)
Deprecated.It imposes the constraint in a given store.void
removeLevel(int level)
Deprecated.This function is called in case of the backtrack, so a constraint can clear the queue of changed variables which is no longer valid.java.lang.String
toString()
Deprecated.It produces a string representation of a constraint state.-
Methods inherited from class org.jacop.constraints.Constraint
afc, arguments, cleanAfterFailure, decompose, getConsistencyPruningEvent, getGuideConstraint, getGuideValue, getGuideVariable, grounded, grounded, id, impose, imposeDecomposition, increaseWeight, intArrayToString, numberArgs, queueVariable, removeConstraint, requiresMonotonicity, setConsistencyPruningEvent, setConstraintScope, setScope, setScope, setScope, setScope, setScope, setWatchedVariableGrounded, supplyGuideFeedback, updateAFC, watchedVariableGrounded
-
Methods inherited from class org.jacop.constraints.DecomposedConstraint
auxiliaryVariables, checkInput, checkInput, checkInputForDuplication, checkInputForDuplicationSkipSingletons, checkInputForNullness, checkInputForNullness, checkInputForNullness, derivative, getDubletonsSkipSingletons, imposeDecomposition
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.jacop.api.Stateful
isStateful
-
-
-
-
Field Detail
-
idNumber
static java.util.concurrent.atomic.AtomicInteger idNumber
Deprecated.
-
a
public SetVar a
Deprecated.It specifies a list on which element a lex relationship holds for every two consecutive variables.
-
b
public SetVar b
Deprecated.It specifies a list on which element a lex relationship holds for every two consecutive variables.
-
strict
public boolean strict
Deprecated.It specifies if the relation is strict or not.
-
inSupport
protected int inSupport
Deprecated.
-
inclusionLevel
protected int inclusionLevel
Deprecated.
-
smallerElSupport
protected int smallerElSupport
Deprecated.
-
smallerElLevel
protected int smallerElLevel
Deprecated.
-
-
Constructor Detail
-
Lex
public Lex(SetVar a, SetVar b)
Deprecated.It constructs an Lexical ordering constraint to restrict the domain of the variables a and b. It is strict by default.- Parameters:
a
- variable that is restricted to be less than b with lexical order.b
- variable that is restricted to be greater than a with lexical order.
-
Lex
public Lex(SetVar a, SetVar b, boolean strict)
Deprecated.It constructs an Lexical ordering constraint to restrict the domain of the variables a and b.- Parameters:
a
- variable that is restricted to be less than b with lexical order.b
- variable that is restricted to be greater than a with lexical order.strict
- specifies if the lex relation is strict.
-
-
Method Detail
-
consistency
public void consistency(Store store)
Deprecated.Description copied from class:Constraint
It is a (most probably incomplete) consistency function which removes the values from variables domains. Only values which do not have any support in a solution space are removed.- Specified by:
consistency
in classConstraint
- Parameters:
store
- constraint store within which the constraint consistency is being checked.
-
getDefaultConsistencyPruningEvent
public int getDefaultConsistencyPruningEvent()
Deprecated.- Specified by:
getDefaultConsistencyPruningEvent
in classConstraint
-
impose
public void impose(Store store)
Deprecated.Description copied from class:Constraint
It imposes the constraint in a given store.- Overrides:
impose
in classConstraint
- Parameters:
store
- the constraint store to which the constraint is imposed to.
-
removeLevel
public void removeLevel(int level)
Deprecated.Description copied from interface:Stateful
This function is called in case of the backtrack, so a constraint can clear the queue of changed variables which is no longer valid. This function is called *before* all timestamps, variables, mutablevariables have reverted to their previous value.- Specified by:
removeLevel
in interfaceStateful
- Parameters:
level
- the level which is being removed.
-
toString
public java.lang.String toString()
Deprecated.Description copied from class:Constraint
It produces a string representation of a constraint state.- Overrides:
toString
in classConstraint
-
-