choco.cp.model.managers.variables
Class IntegerVariableManager

java.lang.Object
  extended by choco.cp.model.managers.variables.IntegerVariableManager
All Implemented Interfaces:
ExpressionManager, VariableManager<IntegerVariable>

public final class IntegerVariableManager
extends Object
implements VariableManager<IntegerVariable>

Created by IntelliJ IDEA. User: charles Date: 8 août 2008 Time: 10:14:01


Field Summary
 
Fields inherited from interface choco.kernel.model.constraints.ExpressionManager
LOGGER
 
Constructor Summary
IntegerVariableManager()
           
 
Method Summary
static int getIntelligentDomain(Model model, IntegerVariable v)
          try to find the most suitable domain for v regarding constraints wish a simple heuristic is applied to rank the domains
protected static IntDomainVar makeConstant(CPSolver solver, IntegerVariable iv)
           
 INode makeNode(Solver solver, Constraint[] cstrs, Variable[] vars)
          Build a expression node
 Var makeVariable(Solver solver, IntegerVariable var)
          Build a integer variable for the given solver
static int possibleArgMin(int[] tab, BitSet posDom)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

IntegerVariableManager

public IntegerVariableManager()
Method Detail

makeConstant

protected static IntDomainVar makeConstant(CPSolver solver,
                                           IntegerVariable iv)

makeVariable

public Var makeVariable(Solver solver,
                        IntegerVariable var)
Build a integer variable for the given solver

Specified by:
makeVariable in interface VariableManager<IntegerVariable>
Parameters:
solver - the solver defining the variable
var - model variable
Returns:
an integer variable

makeNode

public INode makeNode(Solver solver,
                      Constraint[] cstrs,
                      Variable[] vars)
Build a expression node

Specified by:
makeNode in interface ExpressionManager
Parameters:
solver - associated solver
cstrs - constraints
vars - variables
Returns:
a variable leaf or constant leaf (for expression tree)

getIntelligentDomain

public static int getIntelligentDomain(Model model,
                                       IntegerVariable v)
try to find the most suitable domain for v regarding constraints wish a simple heuristic is applied to rank the domains

Parameters:
v - unknown domain type variable
Returns:
a domain type

possibleArgMin

public static int possibleArgMin(int[] tab,
                                 BitSet posDom)


Copyright © 2012. All Rights Reserved.