Fresh news from Droid zone
Hello, you're reading Infinum Android Sweets, bringing you the latest Android related news straight to your inbox every week.
Asynchronous Data Loading With New Kotlin Flow
When we call an asynchronous function like a service call, retrieving data from the database, reading files or anything, we need a callback so that we know that the operation is finished and we can resume the actual work like in mobiles updating the UI after receiving data from your servers. Yup, that’s fine, but when in real-time, it won’t be that easy.
Read More
Lots of object models primarily track application state. For example, OkHttp’s Http2Connection.kt has state for whether a ping’s reply is outstanding: private var awaitingPong = false This is set to true each time a ping is sent and then false again when its reply is received.
We can then understand the power of these rules, and how they can help developers to quickly identify and fix bugs in a systematic way. However, the default set of lint rules is limited and in some situations we could benefit from creating custom rules that identify issues that are specific to our projects.
In this blog post we will understand how to use VerticalScroller or HorizontalScroller to have a list like functionality in Jetpack Compose.
Learn transition animations technique from the open source Topeka App.
Libraries and useful resources
A Pokedex app using ViewModel, LiveData, Room and Navigation.
Android library for enabling edge-to-edge content and insetting views using simple Kotlin DSL.
🔎 A quick and easy in-app database viewer and manager library for your Room databases.
Two years ago, #Android announced first-class support for the Kotlin programming language. Both the language and the platform evolved a lot during this time, with more focus from the engineering teams at Google on helping developers use the full power of Kotlin. In fact, we’ve seen tremendous adoption of the language among top Android app developers. That's why, just 2 years later, we announced that, going forward, Android will become Kotlin-first.
Class of the week
This class provides information about and manages roles. A role is a unique name within the system associated with certain privileges. The list of available roles might change with a system app update, so apps should not make assumption about the availability of roles. Instead, they should always query if the role is available.
Beyond Android
Our team was agile in the sense that we called our meetings stand-ups and developers were empowered to change and improve things—as long as the enterprise architects agreed to it and we spent a number of weeks writing documents first. The code was awful in ways that were entirely new to me but, despite the best efforts of the architecture team, we managed to gradually improve things.