-
- All Superinterfaces:
ArExpression
,Cloneable
,Comparable<Variable>
,ICause
,Identity
,ILogical
,IntVar
,Iterable<Integer>
,ReExpression
,Variable
- All Known Implementing Classes:
BoolNotView
,BoolVarImpl
,EqView
,FixedBoolVarImpl
,IntBoolView
,LeqView
public interface BoolVar extends IntVar, ILogical, ReExpression
CPRU r544: remove default implementation- Since:
- 18 nov. 2010
- Author:
- Charles Prud'homme
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.chocosolver.solver.expression.discrete.arithmetic.ArExpression
ArExpression.Operator
-
Nested classes/interfaces inherited from interface org.chocosolver.solver.expression.discrete.relational.ReExpression
ReExpression.Operator
-
-
Field Summary
Fields Modifier and Type Field Description static int
kFALSE
static int
kTRUE
static int
kUNDEF
-
Fields inherited from interface org.chocosolver.solver.expression.discrete.arithmetic.ArExpression
NO_CHILD
-
Fields inherited from interface org.chocosolver.solver.variables.IntVar
MAX_INT_BOUND, MIN_INT_BOUND
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description void
_setNot(BoolVar not)
default BoolVar
boolVar()
default void
extractVar(HashSet<IntVar> variables)
Extract the variables from this expressionESat
getBooleanValue()
boolean
hasNot()
default IntVar
intVar()
BoolVar
not()
boolean
setToFalse(ICause cause)
boolean
setToTrue(ICause cause)
-
Methods inherited from interface org.chocosolver.solver.expression.discrete.arithmetic.ArExpression
abs, add, add, add, dist, dist, div, div, eq, eq, eq, ge, ge, getExpressionChild, gt, gt, le, le, lt, lt, max, max, max, min, min, min, mod, mod, mul, mul, mul, ne, ne, neg, pow, pow, sqr, sub, sub
-
Methods inherited from interface java.lang.Comparable
compareTo
-
Methods inherited from interface org.chocosolver.solver.constraints.nary.cnf.ILogical
isLit, isNot, setNot
-
Methods inherited from interface org.chocosolver.solver.variables.IntVar
contains, forEachIntVar, getDomainSize, getLB, getNoChild, getRange, getRangeIterator, getUB, getValue, getValueIterator, hasEnumeratedDomain, instantiateTo, isBool, isExpressionLeaf, isInstantiatedTo, monitorDelta, nextValue, nextValueOut, previousValue, previousValueOut, removeAllValuesBut, removeInterval, removeValue, removeValues, transformEvent, updateBounds, updateLowerBound, updateUpperBound
-
Methods inherited from interface java.lang.Iterable
forEach, iterator, spliterator
-
Methods inherited from interface org.chocosolver.solver.expression.discrete.relational.ReExpression
and, beval, decompose, extension, getModel, ieval, iff, ift, ift, ift, ift, imp, or, post, xor
-
Methods inherited from interface org.chocosolver.solver.variables.Variable
addMonitor, asBoolVar, asIntVar, asRealVar, asSetVar, clearEvents, contradiction, createDelta, getCause, getDelta, getDindex, getEnvironment, getEvtScheduler, getIndexInPropagator, getMask, getModel, getName, getNbProps, getNbViews, getPIndices, getPropagator, getPropagators, getTypeAndKind, getView, isAConstant, isInstantiated, link, notifyMonitors, notifyPropagators, notifyViews, removeMonitor, setPIndice, storeEvents, subscribeView, swapOnActivate, swapOnPassivate, unlink
-
-
-
-
Field Detail
-
kFALSE
static final int kFALSE
- See Also:
- Constant Field Values
-
kTRUE
static final int kTRUE
- See Also:
- Constant Field Values
-
kUNDEF
static final int kUNDEF
- See Also:
- Constant Field Values
-
-
Method Detail
-
getBooleanValue
ESat getBooleanValue()
-
setToTrue
boolean setToTrue(ICause cause) throws ContradictionException
- Throws:
ContradictionException
-
setToFalse
boolean setToFalse(ICause cause) throws ContradictionException
- Throws:
ContradictionException
-
not
BoolVar not()
- Specified by:
not
in interfaceReExpression
- Returns:
- return the expression "¬x" where this is "x"
-
hasNot
boolean hasNot()
-
_setNot
void _setNot(BoolVar not)
-
intVar
default IntVar intVar()
- Specified by:
intVar
in interfaceArExpression
- Specified by:
intVar
in interfaceIntVar
- Specified by:
intVar
in interfaceReExpression
- Returns:
- the arithmetic expression as an
IntVar
. If necessary, it creates intermediary variable and posts intermediary constraints
-
boolVar
default BoolVar boolVar()
- Specified by:
boolVar
in interfaceReExpression
- Returns:
- the relational expression as an
BoolVar
. If necessary, it creates intermediary variable and posts intermediary constraints
-
extractVar
default void extractVar(HashSet<IntVar> variables)
Description copied from interface:ArExpression
Extract the variables from this expression- Specified by:
extractVar
in interfaceArExpression
- Specified by:
extractVar
in interfaceReExpression
- Parameters:
variables
- set of variables
-
-