|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.sat4j.sat.RemoteControlStrategy
public class RemoteControlStrategy
Strategy used by the solver when launched with the remote control.
Constructor Summary | |
---|---|
RemoteControlStrategy()
|
|
RemoteControlStrategy(ICDCLLogger log)
|
Method Summary | |
---|---|
void |
assignLiteral(int p)
indicate that a literal has been satisfied. |
void |
clickedOnClean()
|
ICDCLLogger |
getLogger()
|
int |
getNbClausesAtWhichWeShouldClean()
|
IPhaseSelectionStrategy |
getPhaseSelectionStrategy()
|
RestartStrategy |
getRestartStrategy()
|
SearchParams |
getSearchParams()
|
ICDCL |
getSolver()
|
void |
init(int nlength)
that method has the responsibility to initialize all arrays in the heuristics. |
void |
init(int var,
int p)
initialize the phase of a given variable to the given value. |
void |
init(SearchParams params)
Hook method called just before the search starts. |
boolean |
isHasClickedOnClean()
|
boolean |
isHasClickedOnRestart()
|
boolean |
isUseTelecomStrategyAsLearnedConstraintsDeletionStrategy()
|
void |
newConflict()
|
void |
newLearnedClause(Constr learned,
int trailLevel)
|
long |
nextRestartNumberOfConflict()
Ask for the next restart in number of conflicts. |
void |
onBackjumpToRootLevel()
Called when the solver backjumps to the root level. |
void |
onRestart()
Hook method called when a restart occurs (once the solver has backtracked to top decision level). |
void |
reset()
|
int |
select(int var)
selects the phase of the variable according to a phase selection strategy. |
void |
setHasClickedOnClean(boolean hasClickedOnClean)
|
void |
setHasClickedOnRestart(boolean hasClickedOnRestart)
|
void |
setInterrupted(boolean b)
|
void |
setLogger(ICDCLLogger logger)
|
void |
setNbClausesAtWhichWeShouldClean(int nbClausesAtWhichWeShouldClean)
|
void |
setPhaseSelectionStrategy(IPhaseSelectionStrategy phaseSelectionStrategy)
|
void |
setRestartStrategy(RestartStrategy restart)
|
void |
setSolver(ICDCL solver)
|
void |
setUseTelecomStrategyAsLearnedConstraintsDeletionStrategy(boolean useTelecomStrategyAsLearnedConstraintsDeletionStrategy)
|
boolean |
shouldRestart()
Ask the strategy if the solver should restart. |
String |
toString()
|
void |
updateVar(int p)
To be called when the activity of a literal changed. |
void |
updateVarAtDecisionLevel(int q)
Allow to perform a specific action when a literal of the current decision level is updated. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public RemoteControlStrategy(ICDCLLogger log)
public RemoteControlStrategy()
Method Detail |
---|
public boolean isHasClickedOnRestart()
public void setHasClickedOnRestart(boolean hasClickedOnRestart)
public boolean isHasClickedOnClean()
public void setHasClickedOnClean(boolean hasClickedOnClean)
public boolean isUseTelecomStrategyAsLearnedConstraintsDeletionStrategy()
public void setUseTelecomStrategyAsLearnedConstraintsDeletionStrategy(boolean useTelecomStrategyAsLearnedConstraintsDeletionStrategy)
public void clickedOnClean()
public RestartStrategy getRestartStrategy()
public IPhaseSelectionStrategy getPhaseSelectionStrategy()
public void setPhaseSelectionStrategy(IPhaseSelectionStrategy phaseSelectionStrategy)
public void setRestartStrategy(RestartStrategy restart)
public int getNbClausesAtWhichWeShouldClean()
public void setNbClausesAtWhichWeShouldClean(int nbClausesAtWhichWeShouldClean)
public ICDCLLogger getLogger()
public void setLogger(ICDCLLogger logger)
public void init(SearchParams params)
RestartStrategy
init
in interface RestartStrategy
params
- the user's search parameters.public long nextRestartNumberOfConflict()
RestartStrategy
nextRestartNumberOfConflict
in interface RestartStrategy
public boolean shouldRestart()
RestartStrategy
shouldRestart
in interface RestartStrategy
public void onRestart()
RestartStrategy
onRestart
in interface RestartStrategy
public void onBackjumpToRootLevel()
RestartStrategy
onBackjumpToRootLevel
in interface RestartStrategy
public SearchParams getSearchParams()
getSearchParams
in interface RestartStrategy
public ICDCL getSolver()
public void setSolver(ICDCL solver)
public void reset()
reset
in interface ConflictTimer
public void newConflict()
newConflict
in interface ConflictTimer
public void updateVar(int p)
IPhaseSelectionStrategy
updateVar
in interface IPhaseSelectionStrategy
p
- a literal. The associated variable will be updated.public void init(int nlength)
IPhaseSelectionStrategy
init
in interface IPhaseSelectionStrategy
nlength
- the number of variables managed by the heuristics.public void init(int var, int p)
IPhaseSelectionStrategy
init
in interface IPhaseSelectionStrategy
var
- a variablep
- it's initial phasepublic void assignLiteral(int p)
IPhaseSelectionStrategy
assignLiteral
in interface IPhaseSelectionStrategy
public int select(int var)
IPhaseSelectionStrategy
select
in interface IPhaseSelectionStrategy
var
- a variable chosen by the heuristics
public void updateVarAtDecisionLevel(int q)
IPhaseSelectionStrategy
IPhaseSelectionStrategy.updateVar(int)
.
updateVarAtDecisionLevel
in interface IPhaseSelectionStrategy
q
- a literalpublic String toString()
toString
in class Object
public void setInterrupted(boolean b)
public void newLearnedClause(Constr learned, int trailLevel)
newLearnedClause
in interface RestartStrategy
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |