Matt Williams wrote: > I hope you are over the head cold by now :D Mostly -- thanks!
> Thoroughly enjoying the books by the way - they far exceed the level > of detail of the others in my collection. Glad you like 'em! > I'm only disappointed that I didn't discover them weeks ago :) Clearly, I need more billboards. > The 50000 records is of course an exaggeration, I just want to achieve > fast load times on a small subsection (2-3 screens) of potentially > large data sets and provide the ability (for no reason other than its > possibility) to scroll through them all. OK. > These all seem like great options. I will do some reading over them - > particularly option 4, as it sounds exactly like what I am looking > for. Yeah, if I had to choose one of them, I'd probably go that route, only because it'd give me more fine-grained control over what got loaded when. > As an aside, what is there any disadvantage in using a ContentProvider > where data doesn't need to be exposed to other applications? 1. Overhead. ContentProvider is designed to run out-of-process. At minimum, there is extra layers of local stuff (e.g., dealing with Uri instances). At worst, even if you are using it locally, ContentResolver might still use Binder to schlep your Cursor contents across the non-existent process boundary, because it might not know any better. I don't know enough of the underlying implementation to know its behavior for certain. 2. Reduced API. You can put LIMIT clauses in SQLite calls but not in ContentProvider calls, for example. 3. Extra code. Why have a ContentProvider implementation if it's not doing anything other than transcoding between ContentProvider and SQLite APIs? I'd reverse the question: if you aren't exposing the data to other applications, what are you *gaining* by using ContentProvider? If you want a model class to hide your database internals, you can roll one of those without ContentProvider. -- Mark Murphy (a Commons Guy) http://commonsware.com | http://twitter.com/commonsguy Android App Developer Books: http://commonsware.com/books.html --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---

