Class FixedSelectorProbabilityWeightFactory<Solution_,Selector_ extends Selector>
- java.lang.Object
-
- org.optaplanner.core.impl.heuristic.selector.common.decorator.FixedSelectorProbabilityWeightFactory<Solution_,Selector_>
-
- All Implemented Interfaces:
SelectionProbabilityWeightFactory<Solution_,Selector_>
public class FixedSelectorProbabilityWeightFactory<Solution_,Selector_ extends Selector> extends Object implements SelectionProbabilityWeightFactory<Solution_,Selector_>
-
-
Constructor Summary
Constructors Constructor Description FixedSelectorProbabilityWeightFactory(Map<Selector_,Double> fixedProbabilityWeightMap)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description double
createProbabilityWeight(ScoreDirector<Solution_> scoreDirector, Selector_ selector)
-
-
-
Method Detail
-
createProbabilityWeight
public double createProbabilityWeight(ScoreDirector<Solution_> scoreDirector, Selector_ selector)
- Specified by:
createProbabilityWeight
in interfaceSelectionProbabilityWeightFactory<Solution_,Selector_ extends Selector>
- Parameters:
scoreDirector
- never null, theScoreDirector
which has theScoreDirector.getWorkingSolution()
to which the selection belongs or applies toselector
- never null, aPlanningEntity
, a planningValue, aMove
or aSelector
to create the probabilityWeight for- Returns:
0.0 <= returnValue <
Double.POSITIVE_INFINITY
-
-