Package org.jacop.search
Class IndomainHierarchical<T extends Var>
java.lang.Object
org.jacop.search.IndomainHierarchical<T>
- Type Parameters:
T
- type of variable being used in the search.
- All Implemented Interfaces:
Indomain<T>
IndomainHierarchical - implements enumeration method based on the selection
of the preferred indomain for each variable. The initial idea of having such
functionality was proposed by Ben Weiner.
- Version:
- 4.9
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
-
Field Details
-
defIndomain
It defines the default indomain if there is no mapping provided. -
hashmap
It defines for each variable and indomain method which should be used.
-
-
Constructor Details
-
IndomainHierarchical
Constructor which specifies the mapping and default indomain to be used if mapping does not give specific indomain for some variables.- Parameters:
hashmap
- a mapping from variable to indomain heuristic used.defIndomain
- default indomain used if hashmap does not contain an entry.
-
-
Method Details
-
indomain
Description copied from interface:Indomain
It returns value within a variable which should be used in current assignment. This function only returns value, it is not required to do any changes to variable, its domain, etc.- Specified by:
indomain
in interfaceIndomain<T extends Var>
- Parameters:
v
- defines variable for which value for assignment is suggested.- Returns:
- defines value for current assignment.
- Throws:
RuntimeException
-