|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectchoco.kernel.solver.propagation.event.VarEvent<E>
public abstract class VarEvent<E extends Var>
Implements an
PropagationEvent
for the variable events.
Field Summary | |
---|---|
protected SConstraint |
cause
Cause of this basic var. |
static int |
DOWDCAUSE
Semantic of the cause of an event: -1 means that the event is active without any precise cause. |
static int |
EMPTYEVENT
empty bitvector for the event type. |
protected int |
eventType
stores the type of update performed on the variable |
protected E |
modifiedVar
The touched variable. |
static int |
NOCAUSE
Semantic of the cause of an event: -1 means that the event is active without any precise cause. |
static int |
NOEVENT
empty bitvector for the event type. |
protected int |
propagatedEvents
The events that should be fired for the constraints |
Fields inherited from interface choco.kernel.solver.propagation.event.PropagationEvent |
---|
LOGGER |
Constructor Summary | |
---|---|
VarEvent(E var)
Constructs a variable event for the specified variable and with the given basic events. |
Method Summary | |
---|---|
void |
addPropagatedEvents(int bitsmask)
|
abstract void |
clear()
Clears the var: delegates to the basic events. |
static int |
domOverWDegIdx(int idx)
Deprecated. |
static int |
domOverWDegInitialIdx(int idx)
Deprecated. |
protected void |
freeze()
freezes the state of the "delta domain": the set of values that are considered for removal from the domain. |
SConstraint |
getCause()
Returns the cause of this basic var. |
int |
getEventType()
|
Object |
getModifiedObject()
Returns the touched variable. |
E |
getModifiedVar()
Returns the touched variable. |
int |
getPriority()
Returns the priority of the object. |
int |
getPropagatedEvents()
|
boolean |
isActive(int idx)
Checks if a given listener is active or not |
boolean |
isEnqueued()
tests whether the event is currently active (present in some queue) or not |
abstract boolean |
propagateEvent()
Propagates the event through calls to the propagation engine. |
void |
recordEventTypeAndCause(int basicEvt,
SConstraint constraint,
boolean forceAwake)
|
protected boolean |
release()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final int NOEVENT
public static final int NOCAUSE
public static final int DOWDCAUSE
protected SConstraint cause
public static final int EMPTYEVENT
protected E extends Var modifiedVar
protected int eventType
protected int propagatedEvents
Constructor Detail |
---|
public VarEvent(E var)
Method Detail |
---|
public final void addPropagatedEvents(int bitsmask)
public final int getPropagatedEvents()
public final E getModifiedVar()
public final Object getModifiedObject()
getModifiedObject
in interface PropagationEvent
protected void freeze()
protected boolean release()
public abstract boolean propagateEvent() throws ContradictionException
propagateEvent
in interface PropagationEvent
ContradictionException
public abstract void clear()
clear
in interface PropagationEvent
public final boolean isActive(int idx)
isActive
in interface PropagationEvent
idx
- the index of the listener among all listeners connected to the variablepublic final SConstraint getCause()
public int getPriority()
IPrioritizable
getPriority
in interface IPrioritizable
public final int getEventType()
@Deprecated public static int domOverWDegIdx(int idx)
idx
- constraint idx
@Deprecated public static int domOverWDegInitialIdx(int idx)
idx
- modified constraint idx
public final boolean isEnqueued()
public void recordEventTypeAndCause(int basicEvt, SConstraint constraint, boolean forceAwake)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |