Reputation: 2229
In my application I access drectly to database through a SQLiteOpenHelper object.
Now I want to use ContentProviders. In the database I have 14 tables and 6 views. What is the best practice between the following?
One Content Provider to access all tables and views
One Content Provider for each tables and views (total 20 Content Providers)
One Content Provider for each group of tables and views (totale 5/6 Content Providers)
Upvotes: 1
Views: 134
Reputation: 11230
One content provider to access all the tables and views in a database. Content Provider is a abstraction for application to share data with other applications. One Content Provider for a database should be the approach.
Upvotes: 5