Skip to content

Instantly share code, notes, and snippets.

@imandaliya
Last active December 15, 2022 11:52
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save imandaliya/3027e483f7fcb77f07e696f3452af5dd to your computer and use it in GitHub Desktop.
Save imandaliya/3027e483f7fcb77f07e696f3452af5dd to your computer and use it in GitHub Desktop.
thanks to link : https://stackoverflow.com/a/45459675
var repeatDays = ArrayList<String>()
for read :
repeatDays = arrayListOf<String>().apply {
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.TIRAMISU) {
parcel.readList(this, String::class.java.classLoader, String::class.java)
} else {
parcel.readList(this, String::class.java.classLoader)
}
}
for write :
parcel.writeList(repeatDays)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment