compareFixes static method
Sorts fixes by their relevance.
A fix with a higher relevance is sorted before a fix with a lower relevance. Fixes with the same relevance are sorted alphabetically.
Implementation
static int compareFixes(Fix a, Fix b) {
if (a.kind.priority != b.kind.priority) {
// A higher priority indicates a higher relevance
// and should be sorted before a lower priority.
return b.kind.priority - a.kind.priority;
}
return a.change.message.compareTo(b.change.message);
}