choco.real.var
Class RealVarEvent

java.lang.Object
  extended by choco.prop.VarEvent
      extended by choco.real.var.RealVarEvent
All Implemented Interfaces:
PropagationEvent, IPrioritizable
Direct Known Subclasses:
PalmRealVarEvent

public class RealVarEvent
extends VarEvent

An event for real interval variable modifications.


Field Summary
static int BOUNDSEVENT
           
static int DECSUP
           
static int EMPTYEVENT
           
static int INCINF
           
static int INFEVENT
           
static int SUPEVENT
           
 
Fields inherited from class choco.prop.VarEvent
cause, eventType, logger, modifiedVar, NOCAUSE, NOEVENT
 
Fields inherited from interface choco.prop.PropagationEvent
POPPING
 
Constructor Summary
RealVarEvent(AbstractVar var)
           
 
Method Summary
 void clear()
          Clears the var: delegates to the basic events.
protected  void freeze()
          freezes the state of the "delta domain": the set of values that are considered for removal from the domain.
 int getEventType()
          Retrieves the event type
 boolean getReleased()
           
 void propagateBoundsEvent(int evtCause)
          Propagates the update to the domain lower and upper bounds
 boolean propagateEvent()
          Propagates the event through calls to the propagation engine.
 void propagateInfEvent(int evtCause)
          Propagates the update to the lower bound
 void propagateSupEvent(int evtCause)
          Propagates the update to the upper bound
protected  boolean release()
           
 java.lang.String toString()
           
 
Methods inherited from class choco.prop.VarEvent
getCause, getModifiedObject, getModifiedVar, getPriority, getProblem, isActive, isEnqueued, recordEventTypeAndCause
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

INCINF

public static final int INCINF
See Also:
Constant Field Values

DECSUP

public static final int DECSUP
See Also:
Constant Field Values

EMPTYEVENT

public static final int EMPTYEVENT
See Also:
Constant Field Values

BOUNDSEVENT

public static final int BOUNDSEVENT
See Also:
Constant Field Values

INFEVENT

public static final int INFEVENT
See Also:
Constant Field Values

SUPEVENT

public static final int SUPEVENT
See Also:
Constant Field Values
Constructor Detail

RealVarEvent

public RealVarEvent(AbstractVar var)
Method Detail

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

clear

public void clear()
Description copied from class: VarEvent
Clears the var: delegates to the basic events.

Specified by:
clear in interface PropagationEvent
Specified by:
clear in class VarEvent

release

protected boolean release()
Overrides:
release in class VarEvent

freeze

protected void freeze()
Description copied from class: VarEvent
freezes the state of the "delta domain": the set of values that are considered for removal from the domain. Further removals will be treated as a further event.

Overrides:
freeze in class VarEvent

getReleased

public boolean getReleased()

propagateEvent

public boolean propagateEvent()
                       throws ContradictionException
Description copied from class: VarEvent
Propagates the event through calls to the propagation engine.

Specified by:
propagateEvent in interface PropagationEvent
Specified by:
propagateEvent in class VarEvent
Returns:
true if the event has been fully propagated (and can thus be discarded), false otherwise
Throws:
ContradictionException

propagateSupEvent

public void propagateSupEvent(int evtCause)
                       throws ContradictionException
Propagates the update to the upper bound

Throws:
ContradictionException

propagateInfEvent

public void propagateInfEvent(int evtCause)
                       throws ContradictionException
Propagates the update to the lower bound

Throws:
ContradictionException

propagateBoundsEvent

public void propagateBoundsEvent(int evtCause)
                          throws ContradictionException
Propagates the update to the domain lower and upper bounds

Throws:
ContradictionException

getEventType

public int getEventType()
Retrieves the event type