Class DefaultSingleConstraintAssertion<Solution_>
- java.lang.Object
-
- org.optaplanner.test.impl.score.stream.DefaultSingleConstraintAssertion<Solution_>
-
- All Implemented Interfaces:
SingleConstraintAssertion
public final class DefaultSingleConstraintAssertion<Solution_> extends Object implements SingleConstraintAssertion
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedDefaultSingleConstraintAssertion(ConstraintStreamScoreDirectorFactory<Solution_> scoreDirectorFactory, Map<String,ConstraintMatchTotal> constraintMatchTotalMap)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidpenalizesBy(int matchWeightTotal, String message)As defined bySingleConstraintAssertion.penalizesBy(int).voidpenalizesBy(long matchWeightTotal, String message)As defined bySingleConstraintAssertion.penalizesBy(int).voidpenalizesBy(BigDecimal matchWeightTotal, String message)As defined bySingleConstraintAssertion.penalizesBy(int).voidrewardsWith(int matchWeightTotal, String message)As defined bySingleConstraintAssertion.rewardsWith(int).voidrewardsWith(long matchWeightTotal, String message)As defined bySingleConstraintAssertion.rewardsWith(int).voidrewardsWith(BigDecimal matchWeightTotal, String message)As defined bySingleConstraintAssertion.rewardsWith(int).-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.optaplanner.test.api.score.stream.SingleConstraintAssertion
penalizesBy, penalizesBy, penalizesBy, rewardsWith, rewardsWith, rewardsWith
-
-
-
-
Constructor Detail
-
DefaultSingleConstraintAssertion
protected DefaultSingleConstraintAssertion(ConstraintStreamScoreDirectorFactory<Solution_> scoreDirectorFactory, Map<String,ConstraintMatchTotal> constraintMatchTotalMap)
-
-
Method Detail
-
penalizesBy
public void penalizesBy(int matchWeightTotal, String message)Description copied from interface:SingleConstraintAssertionAs defined bySingleConstraintAssertion.penalizesBy(int).- Specified by:
penalizesByin interfaceSingleConstraintAssertion- Parameters:
matchWeightTotal- at least 0, expected sum of match weights of matches of the constraint.message- sometimes null, description of the scenario being asserted
-
penalizesBy
public void penalizesBy(long matchWeightTotal, String message)Description copied from interface:SingleConstraintAssertionAs defined bySingleConstraintAssertion.penalizesBy(int).- Specified by:
penalizesByin interfaceSingleConstraintAssertion- Parameters:
matchWeightTotal- at least 0, expected sum of match weights of matches of the constraint.message- sometimes null, description of the scenario being asserted
-
penalizesBy
public void penalizesBy(BigDecimal matchWeightTotal, String message)
Description copied from interface:SingleConstraintAssertionAs defined bySingleConstraintAssertion.penalizesBy(int).- Specified by:
penalizesByin interfaceSingleConstraintAssertion- Parameters:
matchWeightTotal- at least 0, expected sum of match weights of matches of the constraint.message- sometimes null, description of the scenario being asserted
-
rewardsWith
public void rewardsWith(int matchWeightTotal, String message)Description copied from interface:SingleConstraintAssertionAs defined bySingleConstraintAssertion.rewardsWith(int).- Specified by:
rewardsWithin interfaceSingleConstraintAssertion- Parameters:
matchWeightTotal- at least 0, expected sum of match weights of matches of the constraint.message- sometimes null, description of the scenario being asserted
-
rewardsWith
public void rewardsWith(long matchWeightTotal, String message)Description copied from interface:SingleConstraintAssertionAs defined bySingleConstraintAssertion.rewardsWith(int).- Specified by:
rewardsWithin interfaceSingleConstraintAssertion- Parameters:
matchWeightTotal- at least 0, expected sum of match weights of matches of the constraint.message- sometimes null, description of the scenario being asserted
-
rewardsWith
public void rewardsWith(BigDecimal matchWeightTotal, String message)
Description copied from interface:SingleConstraintAssertionAs defined bySingleConstraintAssertion.rewardsWith(int).- Specified by:
rewardsWithin interfaceSingleConstraintAssertion- Parameters:
matchWeightTotal- at least 0, expected sum of match weights of matches of the constraint.message- sometimes null, description of the scenario being asserted
-
-