Java turns to Kotlin and points north

preface Java is actually an interpretative language. Java source code is compiled to generate class files that can be executed by the JVMThe files generated by the Kotlin compiler can be recognized and executed by the JVM, so KT can still be executed in the same environment even if its syntax is very different from JavaKotlin is a simplifi ...

Posted by Jmz on Wed, 22 Sep 2021 07:34:16 -0700

Jetpack: Room database upgrade detailed actual combat!

Catalogue of series articles Related articles: Jetpack: Room super detailed use pit guide! Jetpack:Room+kotlin collaboration? Transaction problem analysis, detailed explanation of withTransaction API Jetpack:Room use error FAQ Jetpack:Room is optimized with LiveData/Flow, and Room+Flow uses principle analysis. Introduction to Room upg ...

Posted by falcon8253 on Sun, 19 Sep 2021 23:47:53 -0700

[Correct] Use Kotlin Flow for search optimization, kotlin interview questions

If you don't understand it yet, look at the simplified code below: // Article Error Codeđź™…Simplification for (i in 0..100) { // Simulate Generated Data flow<Int> { emit(i) }.debounce(500) // This is an invalid limit because emit of flow only executes once... .collect { println("-----------------& ...

Posted by langer on Mon, 06 Sep 2021 12:24:35 -0700

LiveData overview, kotlin interview questions

Typically, LiveData provides updates only when the data changes and only when the observer is active. An exception to this behavior is that observers also receive updates when they change from inactive to active. In addition, if the observer changes from inactive to active for the second time, it will receive an update only if the value has c ...

Posted by Anim9or on Fri, 03 Sep 2021 20:20:09 -0700