Bernhard
02/20/2020, 12:28 PMdeactivateduser
02/20/2020, 12:29 PMdeactivateduser
02/20/2020, 12:30 PMkqr
02/20/2020, 12:35 PMdeactivateduser
02/20/2020, 12:36 PMBernhard
02/20/2020, 12:37 PMspand
02/20/2020, 12:37 PMspand
02/20/2020, 12:38 PMBernhard
02/20/2020, 12:38 PMBernhard
02/20/2020, 12:38 PMBernhard
02/20/2020, 12:39 PMif (this is Collection) {
return when (size) {
0 -> emptySet()
1 -> setOf(if (this is List) this[0] else iterator().next())
else -> toCollection(LinkedHashSet<T>(mapCapacity(size)))
}
}
return toCollection(LinkedHashSet<T>()).optimizeReadOnlySet()
Bernhard
02/20/2020, 12:41 PMESchouten
02/20/2020, 1:36 PM