On Apr 7, 11:22 am, Dianne Hackborn <hack...@android.com> wrote: > Don't do that. Only open the database once. If you are not using a content > provider, implement a singleton that takes care of opening the database once > for all code in your app.
"The database"? I guess that would work if you only use ONE, statically determined database. Since I don't have just one, I think I need a singleton hash table of opened databases, like I mentioned. > > And let me be clear -- there is NOTHING wrong with the content provider > never closing the database. I'll take your word for it. So if the user opens 10 or 100 databases in a session, I'll just leave them all open. That simplifies the singleton implementation if I don't have to do reference counting. Nathan -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en