choco.cp.solver.constraints.integer.extension
Class FCBinSConstraint

java.lang.Object
  extended by choco.kernel.solver.propagation.Propagator
      extended by choco.kernel.solver.constraints.AbstractSConstraint<IntDomainVar>
          extended by choco.kernel.solver.constraints.integer.AbstractIntSConstraint
              extended by choco.kernel.solver.constraints.integer.AbstractBinIntSConstraint
                  extended by choco.kernel.solver.constraints.integer.extension.CspBinSConstraint
                      extended by choco.cp.solver.constraints.integer.extension.FCBinSConstraint
All Implemented Interfaces:
IExtensionnable, IPretty, SConstraint<IntDomainVar>, IntPropagator, Cloneable, EventListener

public final class FCBinSConstraint
extends CspBinSConstraint

A binary constraint for simple forward checking


Field Summary
 
Fields inherited from class choco.kernel.solver.constraints.integer.extension.CspBinSConstraint
relation
 
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
FCBinSConstraint(IntDomainVar x0, IntDomainVar x1, BinRelation rela)
           
 
Method Summary
 void awakeOnInst(int idx)
          Default propagation on instantiation: full constraint re-propagation.
 Object clone()
          Clone the constraint
 int getFilteredEventMask(int idx)
           
 AbstractSConstraint<IntDomainVar> opposite(Solver solver)
          Get the opposite constraint
 String pretty()
          pretty printing of the object.
 void propagate()
          Propagation: Propagating the constraint until local consistency is reached.
 
Methods inherited from class choco.kernel.solver.constraints.integer.extension.CspBinSConstraint
getRelation, isEntailed, isSatisfied
 
Methods inherited from class choco.kernel.solver.constraints.integer.AbstractIntSConstraint
awakeOnBounds, awakeOnInf, awakeOnRem, 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, setConstraintIndex, setExtension, setVar, toString
 
Methods inherited from class choco.kernel.solver.propagation.Propagator
activate, awake, 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

FCBinSConstraint

public FCBinSConstraint(IntDomainVar x0,
                        IntDomainVar x1,
                        BinRelation rela)
Method Detail

getFilteredEventMask

public int getFilteredEventMask(int idx)
Overrides:
getFilteredEventMask in class Propagator

clone

public Object clone()
Description copied from class: AbstractSConstraint
Clone the constraint

Overrides:
clone in class AbstractSConstraint<IntDomainVar>
Returns:
the clone of the constraint

propagate

public void propagate()
               throws ContradictionException
Description copied from class: Propagator
Propagation: Propagating the constraint until local consistency is reached.

Specified by:
propagate in class Propagator
Throws:
ContradictionException - contradiction exception

awakeOnInst

public void awakeOnInst(int idx)
                 throws ContradictionException
Description copied from class: AbstractIntSConstraint
Default propagation on instantiation: full constraint re-propagation.

Specified by:
awakeOnInst in interface IntPropagator
Overrides:
awakeOnInst in class AbstractIntSConstraint
Throws:
ContradictionException

opposite

public AbstractSConstraint<IntDomainVar> opposite(Solver solver)
Description copied from class: AbstractSConstraint
Get the opposite constraint

Specified by:
opposite in interface SConstraint<IntDomainVar>
Overrides:
opposite in class AbstractSConstraint<IntDomainVar>
Parameters:
solver - the current solver
Returns:
the opposite constraint @param solver

pretty

public String pretty()
Description copied from interface: IPretty
pretty printing of the object. This String is not constant and may depend on the context.

Specified by:
pretty in interface IPretty
Overrides:
pretty in class AbstractSConstraint<IntDomainVar>
Returns:
a readable string representation of the object


Copyright © 2012. All Rights Reserved.