Module org.chocosolver
Class GeneralizedMinDomVarSelector
- java.lang.Object
-
- org.chocosolver.solver.search.strategy.selectors.variables.GeneralizedMinDomVarSelector
-
- All Implemented Interfaces:
VariableSelector
public class GeneralizedMinDomVarSelector extends Object implements VariableSelector
First fail variable selector generalized to all variables. It chooses the variable with the smallest domain (instantiated variables are ignored).- Author:
- Jean-Guillaume Fages
-
-
Constructor Summary
Constructors Constructor Description GeneralizedMinDomVarSelector()
Chooses the non-instantiated variable with the smallest domain First fail generalization to all variable kinds.GeneralizedMinDomVarSelector(boolean leastFree)
Chooses the non-instantiated variable with the smallest domain First fail generalization to all variable kinds.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Variable
getVariable(Variable[] variables)
Provides access to the current selected variable amongvariables
.
-
-
-
Constructor Detail
-
GeneralizedMinDomVarSelector
public GeneralizedMinDomVarSelector()
Chooses the non-instantiated variable with the smallest domain First fail generalization to all variable kinds.
-
GeneralizedMinDomVarSelector
public GeneralizedMinDomVarSelector(boolean leastFree)
Chooses the non-instantiated variable with the smallest domain First fail generalization to all variable kinds.- Parameters:
leastFree
- chooses the most Free variable if set to false
-
-
Method Detail
-
getVariable
public Variable getVariable(Variable[] variables)
Description copied from interface:VariableSelector
Provides access to the current selected variable amongvariables
. If there is no variable left, returnnull
.- Specified by:
getVariable
in interfaceVariableSelector
- Returns:
- the current selected variable if any,
null
otherwise.
-
-