1

I am altering my application to start using SyncAdapter to sync with a server instead of my current implementation.

I created a ContentProvider class (MyDB) which uses an SQLiteOpenHelper to create an SQLiteDatabase and handle basic crud operations in the database

ContentProvider's impementation uses my class' methods in order to perform the crud operations needed by the SyncAdapter

So for example

Uri insert(Uri uri, ContentValues values)

uses my class's

int do_insert(string table, string[] columns, string[] values)

and

 Cursor query(Uri uri, String[] projection, String selection, String[] selectionArgs, String sortOrder) {

uses my class's

Cursor do_query(string table, string[] columns, string query, string order) 

do I have to declare my base methods (do_insert, do_query) as synchronized? does the SyncAdapter using the ContentProvider have ways to make sure that there are no problems? do I have to do something else to make sure no conflicts arise?

thanks in advance for any help you can provide

Cruces
  • 3,029
  • 1
  • 26
  • 55

0 Answers0