summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDaisuke Miyakawa <dmiyakawa@google.com>2011-07-24 17:53:47 -0700
committerAndroid (Google) Code Review <android-gerrit@google.com>2011-07-24 17:53:47 -0700
commitc82cc94db08810ca238643b85c75b3593b2d8067 (patch)
tree706fca3fb0cfaed123c142cb41672fcef073b29f
parent17b8451019543bc226e012bab09cd6da55c91cd2 (diff)
parent15dec3967efcff339fb14a84b85320ba85ed47f0 (diff)
downloadframeworks_base-c82cc94db08810ca238643b85c75b3593b2d8067.zip
frameworks_base-c82cc94db08810ca238643b85c75b3593b2d8067.tar.gz
frameworks_base-c82cc94db08810ca238643b85c75b3593b2d8067.tar.bz2
Merge "Introduce param/column for group count"
-rw-r--r--core/java/android/provider/ContactsContract.java26
1 files changed, 26 insertions, 0 deletions
diff --git a/core/java/android/provider/ContactsContract.java b/core/java/android/provider/ContactsContract.java
index 4a719ec..a0f1eec 100644
--- a/core/java/android/provider/ContactsContract.java
+++ b/core/java/android/provider/ContactsContract.java
@@ -6514,6 +6514,32 @@ public final class ContactsContract {
public static final String SUMMARY_COUNT = "summ_count";
/**
+ * A boolean query parameter that can be used with {@link Groups#CONTENT_SUMMARY_URI}.
+ * It will additionally return {@link #SUMMARY_GROUP_COUNT_PER_ACCOUNT}.
+ *
+ * @hide
+ */
+ public static final String PARAM_RETURN_GROUP_COUNT_PER_ACCOUNT =
+ "return_group_count_per_account";
+
+ /**
+ * The total number of groups of the account that a group belongs to.
+ * This column is available only when the parameter
+ * {@link #PARAM_RETURN_GROUP_COUNT_PER_ACCOUNT} is specified in
+ * {@link Groups#CONTENT_SUMMARY_URI}.
+ *
+ * For example, when the account "A" has two groups "group1" and "group2", and the account
+ * "B" has a group "group3", the rows for "group1" and "group2" return "2" and the row for
+ * "group3" returns "1" for this column.
+ *
+ * Note: This counts only non-favorites, non-auto-add, and not deleted groups.
+ *
+ * Type: INTEGER
+ * @hide
+ */
+ public static final String SUMMARY_GROUP_COUNT_PER_ACCOUNT = "group_count_per_account";
+
+ /**
* The total number of {@link Contacts} that have both
* {@link CommonDataKinds.GroupMembership} in this group, and also have phone numbers.
* Read-only value that is only present when querying