public static class MappingsWriterConfig.Utils extends Object
| Modifier and Type | Method and Description |
|---|---|
static <T> Comparator<T> |
comparingLength(Function<? super T,String> keyExtractor)
Accepts a function that extracts a string sort key from a type
T,
and returns a comparator that compares using that key
when the lengths are both equal, and comparing based on length otherwise. |
public static <T> Comparator<T> comparingLength(Function<? super T,String> keyExtractor)
T,
and returns a comparator that compares using that key
when the lengths are both equal, and comparing based on length otherwise.T - The type of the object being comparedkeyExtractor - The function used to extract the sort key