ContactsContract: Adding joined columns to the Data class definition.
The rationale is this. Since all these joined columns are currently on
different classes, we routinely see code like this:
private static final String[] PROJECTION_PHONE = {
Data._ID, // 0
RawContacts.CONTACT_ID, // 1
Phone.TYPE, // 2
Phone.NUMBER, // 3
Phone.LABEL, // 4
Contacts.DISPLAY_NAME, // 5
};
The most noxious line is RawContacts.CONTACT_ID
After this change, the above declaration changes to:
private static final String[] PROJECTION_PHONE = {
Data._ID, // 0
Data.CONTACT_ID, // 1
Phone.TYPE, // 2
Phone.NUMBER, // 3
Phone.LABEL, // 4
Data.DISPLAY_NAME, // 5
};
Change-Id: I03bfc700e4c8c58a175bc885bf7b807d7fed0744
diff --git a/core/java/android/provider/ContactsContract.java b/core/java/android/provider/ContactsContract.java
index 93ee3ba..bdddc28 100644
--- a/core/java/android/provider/ContactsContract.java
+++ b/core/java/android/provider/ContactsContract.java
@@ -682,7 +682,8 @@
* definition and some generic columns. Each data type can define the meaning for each of
* the generic columns.
*/
- public static final class Data implements BaseColumns, DataColumns {
+ public static final class Data implements BaseColumns, DataColumns, RawContactsColumns,
+ ContactsColumns {
/**
* This utility class cannot be instantiated
*/