|
MOEA Framework 2.5 API Specification |
|||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||
java.lang.Objectorg.moeaframework.core.comparator.FitnessComparator
public class FitnessComparator
Compares two solutions based on their FITNESS_ATTRIBUTE value.
FitnessEvaluator,
Serialized Form| Constructor Summary | |
|---|---|
FitnessComparator()
Deprecated. Use FitnessComparator(boolean) instead; this method
will be removed in a future version |
|
FitnessComparator(boolean largerValuesPreferred)
Constructs a dominance comparator for comparing solutions based on their FITNESS_ATTRIBUTE value. |
|
| Method Summary | |
|---|---|
int |
compare(Solution solution1,
Solution solution2)
Compares the two solutions using a dominance relation, returning -1 if solution1 dominates solution2, 1 if
solution2 dominates solution1, and 0 if the
solutions are non-dominated. |
| 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 |
| Constructor Detail |
|---|
@Deprecated public FitnessComparator()
FitnessComparator(boolean) instead; this method
will be removed in a future version
FITNESS_ATTRIBUTE value. By default, smaller fitness values
are preferred.
public FitnessComparator(boolean largerValuesPreferred)
FITNESS_ATTRIBUTE value.
largerValuesPreferred - true if larger fitness values are
preferred; otherwise smaller fitness values are preferred| Method Detail |
|---|
public int compare(Solution solution1,
Solution solution2)
DominanceComparator-1 if solution1 dominates solution2, 1 if
solution2 dominates solution1, and 0 if the
solutions are non-dominated.
compare in interface Comparator<Solution>compare in interface DominanceComparatorsolution1 - the first solutionsolution2 - the second solution
-1 if solution1 dominates solution2,
1 if solution2 dominates solution1, and
0 if the solutions are non-dominated
|
MOEA Framework 2.5 API Specification |
|||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||