reduce method
Tries to simplify the Sort structure to avoid redundancy.
Implementation
@override
Sort reduce() {
final reducedSorts = sorts
.map((e) => e.reduce())
.where((element) => !element.isEmpty)
.toList(growable: false);
if (reducedSorts.isEmpty) {
return Sort.empty;
}
return SortGroup(reducedSorts);
}