开发者

How to persist nested Bundle in Android?

I have a Bundle with a nested nature that I want to pr开发者_如何学编程eserve, how can I persist the whole Bundle most easily? SharedPreferences lacks a bundle feature.


Don't use a Bundle. A Bundle is not meant to be persisted. Use a different data model (POJOs, HashMap, whatever) and write persistence logic (serialize, serialize to JSON, serialize to XML, write to SQLite, etc.).

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜