public abstract class MoveSelectorConfig<C extends MoveSelectorConfig> extends SelectorConfig<C>
ChangeMoveSelectorConfig
, etc.Modifier and Type | Field and Description |
---|---|
protected SelectionCacheType |
cacheType |
protected List<Class<? extends SelectionFilter>> |
filterClassList |
protected Class<? extends SelectionProbabilityWeightFactory> |
probabilityWeightFactoryClass |
protected Long |
selectedCountLimit |
protected SelectionOrder |
selectionOrder |
protected Class<? extends SelectionSorter> |
sorterClass |
protected Class<? extends Comparator> |
sorterComparatorClass |
protected SelectionSorterOrder |
sorterOrder |
protected Class<? extends SelectionSorterWeightFactory> |
sorterWeightFactoryClass |
Constructor and Description |
---|
MoveSelectorConfig() |
validateCacheTypeVersusSelectionOrder
copyConfig, deduceEntityDescriptor, deduceVariableDescriptor, deduceVariableDescriptorList, toString
protected SelectionCacheType cacheType
protected SelectionOrder selectionOrder
protected List<Class<? extends SelectionFilter>> filterClassList
protected Class<? extends Comparator> sorterComparatorClass
protected Class<? extends SelectionSorterWeightFactory> sorterWeightFactoryClass
protected SelectionSorterOrder sorterOrder
protected Class<? extends SelectionSorter> sorterClass
protected Class<? extends SelectionProbabilityWeightFactory> probabilityWeightFactoryClass
protected Long selectedCountLimit
public SelectionCacheType getCacheType()
public void setCacheType(SelectionCacheType cacheType)
public SelectionOrder getSelectionOrder()
public void setSelectionOrder(SelectionOrder selectionOrder)
public List<Class<? extends SelectionFilter>> getFilterClassList()
public void setFilterClassList(List<Class<? extends SelectionFilter>> filterClassList)
public Class<? extends Comparator> getSorterComparatorClass()
public void setSorterComparatorClass(Class<? extends Comparator> sorterComparatorClass)
public Class<? extends SelectionSorterWeightFactory> getSorterWeightFactoryClass()
public void setSorterWeightFactoryClass(Class<? extends SelectionSorterWeightFactory> sorterWeightFactoryClass)
public SelectionSorterOrder getSorterOrder()
public void setSorterOrder(SelectionSorterOrder sorterOrder)
public Class<? extends SelectionSorter> getSorterClass()
public void setSorterClass(Class<? extends SelectionSorter> sorterClass)
public Class<? extends SelectionProbabilityWeightFactory> getProbabilityWeightFactoryClass()
public void setProbabilityWeightFactoryClass(Class<? extends SelectionProbabilityWeightFactory> probabilityWeightFactoryClass)
public Long getSelectedCountLimit()
public void setSelectedCountLimit(Long selectedCountLimit)
public Double getFixedProbabilityWeight()
public void setFixedProbabilityWeight(Double fixedProbabilityWeight)
public MoveSelectorConfig withCacheType(SelectionCacheType cacheType)
public MoveSelectorConfig withSelectionOrder(SelectionOrder selectionOrder)
public MoveSelectorConfig withFilterClassList(List<Class<? extends SelectionFilter>> filterClassList)
public MoveSelectorConfig withSorterComparatorClass(Class<? extends Comparator> sorterComparatorClass)
public MoveSelectorConfig withSorterWeightFactoryClass(Class<? extends SelectionSorterWeightFactory> sorterWeightFactoryClass)
public MoveSelectorConfig withSorterOrder(SelectionSorterOrder sorterOrder)
public MoveSelectorConfig withSorterClass(Class<? extends SelectionSorter> sorterClass)
public MoveSelectorConfig withProbabilityWeightFactoryClass(Class<? extends SelectionProbabilityWeightFactory> probabilityWeightFactoryClass)
public MoveSelectorConfig withSelectedCountLimit(Long selectedCountLimit)
public MoveSelectorConfig withFixedProbabilityWeight(Double fixedProbabilityWeight)
public MoveSelector buildMoveSelector(HeuristicConfigPolicy configPolicy, SelectionCacheType minimumCacheType, SelectionOrder inheritedSelectionOrder)
configPolicy
- never nullminimumCacheType
- never null, If caching is used (different from SelectionCacheType.JUST_IN_TIME
),
then it should be at least this SelectionCacheType
because an ancestor already uses such caching
and less would be pointless.inheritedSelectionOrder
- never nullprotected MoveSelectorConfig buildUnfoldedMoveSelectorConfig(HeuristicConfigPolicy configPolicy)
configPolicy
- never nullprotected boolean determineBaseRandomSelection(SelectionCacheType resolvedCacheType, SelectionOrder resolvedSelectionOrder)
protected boolean isBaseInherentlyCached()
protected abstract MoveSelector buildBaseMoveSelector(HeuristicConfigPolicy configPolicy, SelectionCacheType minimumCacheType, boolean randomSelection)
configPolicy
- never nullminimumCacheType
- never null, If caching is used (different from SelectionCacheType.JUST_IN_TIME
),
then it should be at least this SelectionCacheType
because an ancestor already uses such caching
and less would be pointless.randomSelection
- true is equivalent to SelectionOrder.RANDOM
,
false is equivalent to SelectionOrder.ORIGINAL
public void extractLeafMoveSelectorConfigsIntoList(List<MoveSelectorConfig> leafMoveSelectorConfigList)
MoveSelectorConfig
s
except for UnionMoveSelectorConfig
and CartesianProductMoveSelectorConfig
.leafMoveSelectorConfigList
- not nullpublic C inherit(C inheritedConfig)
AbstractConfig
inheritedConfig
unless that property (or a semantic alternative)
is defined by this instance (which overwrites the inherited behaviour).
After the inheritance, if a property on this AbstractConfig
composition is replaced,
it should not affect the inherited composition instance.
inherit
in class AbstractConfig<C extends MoveSelectorConfig>
inheritedConfig
- never nullpublic void inheritFolded(MoveSelectorConfig foldedConfig)
foldedConfig
can be of a different type.foldedConfig
- never nullCopyright © 2006–2020 JBoss by Red Hat. All rights reserved.