Hi

On Tuesday, July 5, 2011 6:26:42 PM UTC+2, doles wrote:
>
> Hello,
>
> How is in-memory caching achieved in android? For example, i have static 
> data such as state list in the United States. I would like to keep that list 
> in a file or somewhere in an online service. However, when the app is 
> running, I'd rather store in memory in the app itself. How is that achieved? 
> I could create a singleton and initialize that on startup. What are the best 
> practices if any? Thank you for reading and responding!
>
> I think that generally you should try and follow Android design patterns. 
That means that your data should be kept either in a service or perhaps even 
better in a content provider. This allows Android to better manage situation 
where it wants or needs to free up some memory.

Greetings

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to