Class FlatteningHardSoftScoreComparator
java.lang.Object
org.optaplanner.core.impl.score.comparator.FlatteningHardSoftScoreComparator
- All Implemented Interfaces:
Comparator<Score>
Compares 2
HardSoftScore
s based on the calculation of the hard multiplied by a weight, summed with the soft.-
Constructor Summary
-
Method Summary
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface java.util.Comparator
equals, reversed, thenComparing, thenComparing, thenComparing, thenComparingDouble, thenComparingInt, thenComparingLong
-
Constructor Details
-
FlatteningHardSoftScoreComparator
public FlatteningHardSoftScoreComparator(int hardWeight)
-
-
Method Details
-
getHardWeight
public int getHardWeight() -
compare
- Specified by:
compare
in interfaceComparator<Score>
-