I'm in the process of developing an Android application and I am conflicted about whether or not I should use Ormlite for updating and retrieving data in conjunction with Android Content Provider. The content provider would be used to primarily notify the app of changes in the data that have occurred in the app on other platforms. Perhaps I am making this more complicated than what it needs to be. Some more experienced opinions would be greatly appreciated!
Accessing a provider. When you want to access data in a content provider, you use the ContentResolver object in your application's Context to communicate with the provider as a client. The ContentResolver object communicates with the provider object, an instance of a class that implements ContentProvider .
At least one authority must be specified. Whether or not the content provider can be instantiated by the system — " true " if it can be, and " false " if not. The default value is " true ".
onCreate() which is called to initialize the provider.
https://github.com/blandware/android-atleap library is an example of using ContentProvider in conjunction with OrmLite
Give it a try. Experience gained is usually worth the effort, even if you end up discarding the result. Oh, and let us know how it goes, because I've been curious about OrmLite too. :-)
You can use OrmLiteContentProvider or Android AtLeap accelerator in conjunction with OrmLite. Both libraries allows you to define content provider easily on top of the OrmLite data model.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With