Debug options

This commit is contained in:
Dominik Schürmann 2015-03-05 11:14:19 +01:00
parent 18a827eeed
commit 7ccdd7d38e
3 changed files with 6 additions and 2 deletions

View File

@ -28,6 +28,8 @@ import java.io.File;
public final class Constants {
public static final boolean DEBUG = BuildConfig.DEBUG;
public static final boolean DEBUG_LOG_DB_QUERIES = false;
public static final boolean DEBUG_SYNC_REMOVE_CONTACTS = false;
public static final String TAG = "Keychain";

View File

@ -650,7 +650,7 @@ public class KeychainProvider extends ContentProvider {
cursor.setNotificationUri(getContext().getContentResolver(), uri);
}
if (Constants.DEBUG) {
if (Constants.DEBUG && Constants.DEBUG_LOG_DB_QUERIES) {
Log.d(Constants.TAG,
"Query: "
+ qb.buildQuery(projection, selection, selectionArgs, null, null,

View File

@ -296,7 +296,9 @@ public class ContactHelper {
ContentResolver resolver = context.getContentResolver();
Set<Long> deletedKeys = getRawContactMasterKeyIds(resolver);
// debugDeleteRawContacts(resolver);
if (Constants.DEBUG_SYNC_REMOVE_CONTACTS) {
debugDeleteRawContacts(resolver);
}
// ContentProviderClient client = resolver.acquireContentProviderClient(ContactsContract.AUTHORITY_URI);
// ContentValues values = new ContentValues();