org.optaplanner.core.impl.localsearch.decider.acceptor
Class CompositeAcceptor
java.lang.Object
org.optaplanner.core.impl.solver.event.SolverLifecycleListenerAdapter
org.optaplanner.core.impl.localsearch.event.LocalSearchPhaseLifecycleListenerAdapter
org.optaplanner.core.impl.localsearch.decider.acceptor.AbstractAcceptor
org.optaplanner.core.impl.localsearch.decider.acceptor.CompositeAcceptor
- All Implemented Interfaces:
- EventListener, Acceptor, LocalSearchPhaseLifecycleListener, SolverLifecycleListener
public class CompositeAcceptor
- extends AbstractAcceptor
Combines several acceptors into one.
Does a logical AND over the accepted status of its acceptors.
For example: combine planning entity and planning value tabu to do tabu on both.
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
acceptorList
protected List<Acceptor> acceptorList
CompositeAcceptor
public CompositeAcceptor()
setAcceptorList
public void setAcceptorList(List<Acceptor> acceptorList)
solvingStarted
public void solvingStarted(DefaultSolverScope solverScope)
- Specified by:
solvingStarted in interface SolverLifecycleListener- Overrides:
solvingStarted in class SolverLifecycleListenerAdapter
phaseStarted
public void phaseStarted(LocalSearchPhaseScope phaseScope)
- Specified by:
phaseStarted in interface LocalSearchPhaseLifecycleListener- Overrides:
phaseStarted in class LocalSearchPhaseLifecycleListenerAdapter
stepStarted
public void stepStarted(LocalSearchStepScope stepScope)
- Specified by:
stepStarted in interface LocalSearchPhaseLifecycleListener- Overrides:
stepStarted in class LocalSearchPhaseLifecycleListenerAdapter
isAccepted
public boolean isAccepted(LocalSearchMoveScope moveScope)
- Parameters:
moveScope - not null
- Returns:
- true if accepted
stepEnded
public void stepEnded(LocalSearchStepScope stepScope)
- Specified by:
stepEnded in interface LocalSearchPhaseLifecycleListener- Overrides:
stepEnded in class LocalSearchPhaseLifecycleListenerAdapter
phaseEnded
public void phaseEnded(LocalSearchPhaseScope phaseScope)
- Specified by:
phaseEnded in interface LocalSearchPhaseLifecycleListener- Overrides:
phaseEnded in class LocalSearchPhaseLifecycleListenerAdapter
solvingEnded
public void solvingEnded(DefaultSolverScope solverScope)
- Specified by:
solvingEnded in interface SolverLifecycleListener- Overrides:
solvingEnded in class SolverLifecycleListenerAdapter
Copyright © 2006-2014 JBoss by Red Hat. All Rights Reserved.