aroundbad.blogg.se

Kotlin data class serializable
Kotlin data class serializable












kotlin data class serializable

Under the hood, both implementations save data on disk, in a file, using protocol buffers. In our previous posts, we’ve covered how Preferences and Proto DataStore approach structuring and serializing your persisted data: Proto uses typed objects backed by Protocol Buffers, while Preferences uses key-value pairs as our data representation, similarly to SharedPreferences. We will be referring to the Preferences and Proto codelabs throughout this post, for code samples.

kotlin data class serializable

In this post, we will be focusing on Kotlin serialization.

kotlin data class serializable

In the following posts from our Jetpack DataStore series, we will cover several additional concepts to understand how DataStore interacts with other APIs, so that you’d have everything at your disposal to use it in a production environment.














Kotlin data class serializable