fun <K : Comparable<K>, V> Map<out K, V>.toSortedMap(): SortedMap<K, V>
Platform and version requirements: JVM
Converts this Map to a SortedMap so iteration order will be in key order.
fun <K, V> Map<out K, V>.toSortedMap( comparator: Comparator<in K> ): SortedMap<K, V>
Platform and version requirements: JVM
Converts this Map to a SortedMap using the given comparator so that iteration order will be in the order defined by the comparator.
© 2010–2017 JetBrains s.r.o.
Licensed under the Apache License, Version 2.0.
https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/to-sorted-map.html