Class ParetoConstraintComparator
java.lang.Object
org.moeaframework.core.comparator.ParetoConstraintComparator
- All Implemented Interfaces:
DominanceComparator
Compares solutions based on the Pareto efficiency of their constraints.
-
Constructor Summary
Constructors -
Method Summary
-
Constructor Details
-
ParetoConstraintComparator
public ParetoConstraintComparator()Constructs a Pareto constraint comparator.
-
-
Method Details
-
compare
Description copied from interface:DominanceComparatorCompares the two solutions using a dominance relation, returning-1ifsolution1dominatessolution2,1ifsolution2dominatessolution1, and0if the solutions are non-dominated.- Specified by:
comparein interfaceDominanceComparator- Parameters:
solution1- the first solutionsolution2- the second solution- Returns:
-1ifsolution1dominatessolution2,1ifsolution2dominatessolution1, and0if the solutions are non-dominated
-