Passing lambdas to functions in Kotlin can cause runtime overhead. Correct use of the inline modifier can remove these runtime overhead and improve performance.
Passing lambdas to functions in Kotlin can cause runtime overhead. Correct use of the inline modifier can remove these runtime overhead and improve performance.
Kotlin’s by keyword allows us to easily implement the Delegation Pattern. When we use Kotlin’s by keywords, we don’t need to implement these delegation code. This makes the code quite compact.
KDoc is the language for documenting Kotlin code, and Dokka is the engine for generating documentation from KDoc. Dokka can generate documentation in pretty nice HTML format.
Kotlin coroutine flow includes cold flow and hot flow. SharedFlow and StateFlow are two of the hot flows. They can broadcast values to several receivers, so can be used to implement the publisher-subscriber pattern.
Kotlin’s coroutines are used to replace threads. They do not block threads, and they can be cancelled. Coroutine core helps you manage the number of threads.