V
- VariableT
- Valuepublic class SearchIntensification<V extends Variable<V,T>,T extends Value<V,T>> extends ExtensionWithContext<V,T,SearchIntensification.Context> implements SolutionListener<V,T>
Modifier and Type | Class and Description |
---|---|
class |
SearchIntensification.Context
Assignment context
|
sMaxSize
Constructor and Description |
---|
SearchIntensification(Solver<V,T> solver,
DataProperties properties) |
Modifier and Type | Method and Description |
---|---|
void |
afterAssigned(Assignment<V,T> assignment,
long iteration,
T value)
Called after a value is assigned to a variable
|
void |
bestCleared(Solution<V,T> solution)
Called by the solution when method
Solution.clearBest() is
called. |
void |
bestRestored(Solution<V,T> solution)
Called by the solution when method
Solution.restoreBest() is
called. |
void |
bestSaved(Solution<V,T> solution)
Called by the solution when method
Solution.saveBest() is called. |
SearchIntensification.Context |
createAssignmentContext(Assignment<V,T> assignment)
Create a new assignment context for the given assignment.
|
void |
getInfo(Solution<V,T> solution,
Map<String,String> info)
Called by the solution when it is asked to produce info table, see
Solution.getInfo() . |
void |
getInfo(Solution<V,T> solution,
Map<String,String> info,
Collection<V> variables)
Called by the solution when it is asked to produce info table, see
Solution.getInfo() . |
boolean |
init(Solver<V,T> solver)
Initialization -- called before the solver is started
|
void |
register(Model<V,T> model)
Registration of a model.
|
void |
solutionUpdated(Solution<V,T> solution)
Called by the solution when it is updated, see
Solution.update(double) . |
void |
unregister(Model<V,T> model)
Unregistration of a model.
|
getAssignmentContextReference, getContext, getContext, setAssignmentContextReference
afterUnassigned, beforeAssigned, beforeUnassigned, constraintAdded, constraintRemoved, getModel, getProperties, getSolver, isRegistered, variableAdded, variableRemoved
public SearchIntensification(Solver<V,T> solver, DataProperties properties)
public boolean init(Solver<V,T> solver)
Extension
public void register(Model<V,T> model)
Extension
public void unregister(Model<V,T> model)
Extension
unregister
in class ExtensionWithContext<V extends Variable<V,T>,T extends Value<V,T>,SearchIntensification.Context>
model
- problem modelpublic void afterAssigned(Assignment<V,T> assignment, long iteration, T value)
Extension
public void bestSaved(Solution<V,T> solution)
SolutionListener
Solution.saveBest()
is called.public void solutionUpdated(Solution<V,T> solution)
SolutionListener
Solution.update(double)
.solutionUpdated
in interface SolutionListener<V extends Variable<V,T>,T extends Value<V,T>>
solution
- source solutionpublic void bestCleared(Solution<V,T> solution)
SolutionListener
Solution.clearBest()
is
called.bestCleared
in interface SolutionListener<V extends Variable<V,T>,T extends Value<V,T>>
solution
- source solutionpublic void bestRestored(Solution<V,T> solution)
SolutionListener
Solution.restoreBest()
is
called.bestRestored
in interface SolutionListener<V extends Variable<V,T>,T extends Value<V,T>>
solution
- source solutionpublic void getInfo(Solution<V,T> solution, Map<String,String> info)
SolutionListener
Solution.getInfo()
. A listener can also add some its info into
this table.public void getInfo(Solution<V,T> solution, Map<String,String> info, Collection<V> variables)
SolutionListener
Solution.getInfo()
. A listener can also add some its info into
this table.public SearchIntensification.Context createAssignmentContext(Assignment<V,T> assignment)
HasAssignmentContext
createAssignmentContext
in interface HasAssignmentContext<V extends Variable<V,T>,T extends Value<V,T>,SearchIntensification.Context>
assignment
- an assignment for which there needs to be an assignment context