开发者

Storing a Parcelable object to a File in Android

开发者 https://www.devze.com 2023-03-29 07:17 出处:网络
I am trying to store an ArrayList of ResolveI开发者_StackOverflownfo objects to a file so that I don\'t have to rebuild it each time my application launches (about 4-6 seconds) ResolveInfo objects are

I am trying to store an ArrayList of ResolveI开发者_StackOverflownfo objects to a file so that I don't have to rebuild it each time my application launches (about 4-6 seconds) ResolveInfo objects are Parcelable, but not Serializable so I get a java.io error when I try to write the objects.

I have stored them in my savedInstanceState bundle, but that doesn't help when closing the application. Am I doing something plain wrong?


savedInstance info will not save across multiple sessions. You will really want to implement Serializable to save your ResolveInfo.

0

精彩评论

暂无评论...
验证码 换一张
取 消