compareTo
method of the first argument to generate the result. Using sortWith
and a Comparator instance is equivalent to using the sort method and
no comparator.
caselessCompareTo
method to determine order. The String class implements caselessCompareTo,
so the CaselessComparator can be used to sort arrays of strings independent of case.
stableSortWith method is recommended to ensure the results of
previous sort operations are retained.