INNER CODE UNIT · Kotlin
subIdent
kosi-libs/Kodein · kodein-di/src/commonMain/kotlin/org/kodein/di/BindingsMap.kt:36
val subIdent = keyDescription.length - 4
it.value.subList(1, it.value.size).forEach {
append("${" ".repeat(subIdent)}overrides ${it.binding.bindingDisp()}")
}
}
append("\n")
}
val byModule = entries.groupBy { it.value.first().fromModule }
val modules = byModule.keys.filterNotNull().sorted()
return buildString {
byModule[null]?.let { appendBindings(ident, it) }
modules.forEach {
append("${" ".repeat(ident)}module $it {\n")
appendBindings(ident + 4, byModule[it]!!)
append("${" ".repeat(ident)}}\n")