Class LateAcceptanceAcceptor<Solution_>
java.lang.Object
ai.timefold.solver.core.impl.solver.event.SolverLifecycleListenerAdapter<Solution_>
ai.timefold.solver.core.impl.localsearch.event.LocalSearchPhaseLifecycleListenerAdapter<Solution_>
ai.timefold.solver.core.impl.localsearch.decider.acceptor.AbstractAcceptor<Solution_>
ai.timefold.solver.core.impl.localsearch.decider.acceptor.lateacceptance.LateAcceptanceAcceptor<Solution_>
- All Implemented Interfaces:
Acceptor<Solution_>,LocalSearchPhaseLifecycleListener<Solution_>,SolverLifecycleListener<Solution_>,EventListener
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected booleanprotected intprotected intprotected InnerScore<?>[]Fields inherited from class ai.timefold.solver.core.impl.localsearch.decider.acceptor.AbstractAcceptor
logger -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanisAccepted(LocalSearchMoveScope<Solution_> moveScope) voidphaseEnded(LocalSearchPhaseScope<Solution_> phaseScope) voidphaseStarted(LocalSearchPhaseScope<Solution_> phaseScope) voidsetHillClimbingEnabled(boolean hillClimbingEnabled) voidsetLateAcceptanceSize(int lateAcceptanceSize) voidstepEnded(LocalSearchStepScope<Solution_> stepScope) Methods inherited from class ai.timefold.solver.core.impl.localsearch.event.LocalSearchPhaseLifecycleListenerAdapter
stepStartedMethods inherited from class ai.timefold.solver.core.impl.solver.event.SolverLifecycleListenerAdapter
solvingEnded, solvingStartedMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface ai.timefold.solver.core.impl.localsearch.event.LocalSearchPhaseLifecycleListener
stepStartedMethods inherited from interface ai.timefold.solver.core.impl.solver.event.SolverLifecycleListener
solvingEnded, solvingError, solvingStarted
-
Field Details
-
lateAcceptanceSize
protected int lateAcceptanceSize -
hillClimbingEnabled
protected boolean hillClimbingEnabled -
previousScores
-
lateScoreIndex
protected int lateScoreIndex
-
-
Constructor Details
-
LateAcceptanceAcceptor
public LateAcceptanceAcceptor()
-
-
Method Details
-
setLateAcceptanceSize
public void setLateAcceptanceSize(int lateAcceptanceSize) -
setHillClimbingEnabled
public void setHillClimbingEnabled(boolean hillClimbingEnabled) -
phaseStarted
- Specified by:
phaseStartedin interfaceLocalSearchPhaseLifecycleListener<Solution_>- Overrides:
phaseStartedin classLocalSearchPhaseLifecycleListenerAdapter<Solution_>
-
isAccepted
- Parameters:
moveScope- not null- Returns:
- true if accepted
-
stepEnded
- Specified by:
stepEndedin interfaceLocalSearchPhaseLifecycleListener<Solution_>- Overrides:
stepEndedin classLocalSearchPhaseLifecycleListenerAdapter<Solution_>
-
phaseEnded
- Specified by:
phaseEndedin interfaceLocalSearchPhaseLifecycleListener<Solution_>- Overrides:
phaseEndedin classLocalSearchPhaseLifecycleListenerAdapter<Solution_>
-