org.drools.planner.core.heuristic.selector.move.decorator
Class CachingMoveSelector
java.lang.Object
org.drools.planner.core.heuristic.selector.AbstractSelector
org.drools.planner.core.heuristic.selector.move.AbstractMoveSelector
org.drools.planner.core.heuristic.selector.move.decorator.AbstractCachingMoveSelector
org.drools.planner.core.heuristic.selector.move.decorator.CachingMoveSelector
- All Implemented Interfaces:
- Iterable<Move>, EventListener, SelectionCacheLifecycleListener, MoveSelector, Selector, SolverPhaseLifecycleListener, SolverLifecycleListener
public class CachingMoveSelector
- extends AbstractCachingMoveSelector
A MoveSelector
that caches the result of its child MoveSelector
.
Keep this code in sync with CachingEntitySelector
and CachingValueSelector
.
randomSelection
protected final boolean randomSelection
CachingMoveSelector
public CachingMoveSelector(MoveSelector childMoveSelector,
SelectionCacheType cacheType,
boolean randomSelection)
isNeverEnding
public boolean isNeverEnding()
- Description copied from interface:
Selector
- Is true if
Selector.isContinuous()
is true
or if this selector is in random order (for most cases).
Is never true when this selector is in shuffled order (which is less scalable but more exact).
- Returns:
- true if the
Iterator.hasNext()
of the Iterator
created by Iterable.iterator()
never returns false.
iterator
public Iterator<Move> iterator()
toString
public String toString()
- Overrides:
toString
in class Object
Copyright © 2001-2012 JBoss by Red Hat. All Rights Reserved.