Class AbstractFinalistPodium<Solution_>
- java.lang.Object
-
- org.optaplanner.core.impl.solver.event.SolverLifecycleListenerAdapter<Solution_>
-
- org.optaplanner.core.impl.localsearch.event.LocalSearchPhaseLifecycleListenerAdapter<Solution_>
-
- org.optaplanner.core.impl.localsearch.decider.forager.finalist.AbstractFinalistPodium<Solution_>
-
- All Implemented Interfaces:
EventListener
,FinalistPodium<Solution_>
,LocalSearchPhaseLifecycleListener<Solution_>
,SolverLifecycleListener<Solution_>
- Direct Known Subclasses:
HighestScoreFinalistPodium
,StrategicOscillationByLevelFinalistPodium
public abstract class AbstractFinalistPodium<Solution_> extends LocalSearchPhaseLifecycleListenerAdapter<Solution_> implements FinalistPodium<Solution_>
Abstract superclass forFinalistPodium
.- See Also:
FinalistPodium
-
-
Field Summary
Fields Modifier and Type Field Description protected static int
FINALIST_LIST_MAX_SIZE
protected boolean
finalistIsAccepted
protected List<LocalSearchMoveScope<Solution_>>
finalistList
protected org.slf4j.Logger
logger
-
Constructor Summary
Constructors Constructor Description AbstractFinalistPodium()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
addFinalist(LocalSearchMoveScope<Solution_> moveScope)
protected void
clearAndAddFinalist(LocalSearchMoveScope<Solution_> moveScope)
List<LocalSearchMoveScope<Solution_>>
getFinalistList()
void
phaseEnded(LocalSearchPhaseScope<Solution_> phaseScope)
void
stepStarted(LocalSearchStepScope<Solution_> stepScope)
-
Methods inherited from class org.optaplanner.core.impl.localsearch.event.LocalSearchPhaseLifecycleListenerAdapter
phaseStarted, stepEnded
-
Methods inherited from class org.optaplanner.core.impl.solver.event.SolverLifecycleListenerAdapter
solvingEnded, solvingStarted
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.optaplanner.core.impl.localsearch.decider.forager.finalist.FinalistPodium
addMove
-
Methods inherited from interface org.optaplanner.core.impl.localsearch.event.LocalSearchPhaseLifecycleListener
phaseStarted, stepEnded
-
Methods inherited from interface org.optaplanner.core.impl.solver.event.SolverLifecycleListener
solvingEnded, solvingStarted
-
-
-
-
Field Detail
-
FINALIST_LIST_MAX_SIZE
protected static final int FINALIST_LIST_MAX_SIZE
- See Also:
- Constant Field Values
-
logger
protected final transient org.slf4j.Logger logger
-
finalistIsAccepted
protected boolean finalistIsAccepted
-
finalistList
protected List<LocalSearchMoveScope<Solution_>> finalistList
-
-
Method Detail
-
stepStarted
public void stepStarted(LocalSearchStepScope<Solution_> stepScope)
- Specified by:
stepStarted
in interfaceLocalSearchPhaseLifecycleListener<Solution_>
- Overrides:
stepStarted
in classLocalSearchPhaseLifecycleListenerAdapter<Solution_>
-
clearAndAddFinalist
protected void clearAndAddFinalist(LocalSearchMoveScope<Solution_> moveScope)
-
addFinalist
protected void addFinalist(LocalSearchMoveScope<Solution_> moveScope)
-
getFinalistList
public List<LocalSearchMoveScope<Solution_>> getFinalistList()
- Specified by:
getFinalistList
in interfaceFinalistPodium<Solution_>
- Returns:
- never null, sometimes empty
-
phaseEnded
public void phaseEnded(LocalSearchPhaseScope<Solution_> phaseScope)
- Specified by:
phaseEnded
in interfaceLocalSearchPhaseLifecycleListener<Solution_>
- Overrides:
phaseEnded
in classLocalSearchPhaseLifecycleListenerAdapter<Solution_>
-
-