Most visited

Recently visited

Added in API level 1
Deprecated since API level 5

Contacts.People

public static final class Contacts.People
extends Object implements BaseColumns, Contacts.PeopleColumns, Contacts.PhonesColumns, Contacts.PresenceColumns

java.lang.Object
   ↳ android.provider.Contacts.People


此类已在API级别5中弃用。
ContactsContract

此表包含人员。

Summary

Nested classes

class Contacts.People.ContactMethods

此类已在API级别5中弃用。请参阅ContactsContract

class Contacts.People.Extensions

此类已在API级别5中弃用。请参阅ContactsContract

class Contacts.People.Phones

此类已在API级别5中弃用。请参阅ContactsContract

Constants

String CONTENT_ITEM_TYPE

此常数在API级别5中已弃用。请参阅ContactsContract

String CONTENT_TYPE

此常数在API级别5中已弃用。请参阅ContactsContract

String DEFAULT_SORT_ORDER

此常数在API级别5中已弃用。请参阅ContactsContract

String PRIMARY_EMAIL_ID

此常数在API级别5中已弃用。请参阅ContactsContract

String PRIMARY_ORGANIZATION_ID

此常数在API级别5中已弃用。请参阅ContactsContract

String PRIMARY_PHONE_ID

此常数在API级别5中已弃用。请参阅ContactsContract

Inherited constants

From interface android.provider.BaseColumns
From interface android.provider.Contacts.PeopleColumns
From interface android.provider.Contacts.PhonesColumns
From interface android.provider.Contacts.PresenceColumns

Fields

public static final Uri CONTENT_FILTER_URI

此字段在API级别5中已弃用。请参阅ContactsContract

public static final Uri CONTENT_URI

该字段在API级别5中已弃用。请参阅ContactsContract

public static final Uri DELETED_CONTENT_URI

该字段在API级别5中已弃用。请参阅ContactsContract

Public methods

static Uri addToGroup(ContentResolver resolver, long personId, long groupId)

此方法在API级别5中已弃用。请参阅ContactsContract

static Uri addToGroup(ContentResolver resolver, long personId, String groupName)

此方法在API级别5中已弃用。请参阅ContactsContract

static Uri addToMyContactsGroup(ContentResolver resolver, long personId)

此方法在API级别5中已弃用。请参阅ContactsContract

static Uri createPersonInMyContactsGroup(ContentResolver resolver, ContentValues values)

此方法在API级别5中已弃用。请参阅ContactsContract

static Bitmap loadContactPhoto(Context context, Uri person, int placeholderImageResource, BitmapFactory.Options options)

此方法在API级别5中已弃用。请参阅ContactsContract

static void markAsContacted(ContentResolver resolver, long personId)

此方法在API级别5中已弃用。请参阅ContactsContract

static InputStream openContactPhotoInputStream(ContentResolver cr, Uri person)

此方法在API级别5中已弃用。请参阅ContactsContract

static Cursor queryGroups(ContentResolver resolver, long person)

此方法在API级别5中已弃用。请参阅ContactsContract

static void setPhotoData(ContentResolver cr, Uri person, byte[] data)

此方法在API级别5中已弃用。请参阅ContactsContract

Inherited methods

From class java.lang.Object

Constants

CONTENT_ITEM_TYPE

Added in API level 1
String CONTENT_ITEM_TYPE

此常数在API级别5中已弃用。
ContactsContract

一个人的 CONTENT_URI子目录的MIME类型。

常量值:“vnd.android.cursor.item / person”

CONTENT_TYPE

Added in API level 1
String CONTENT_TYPE

此常数在API级别5中已弃用。
ContactsContract

提供人员目录的MIME类型 CONTENT_URI

常量值:“vnd.android.cursor.dir / person”

DEFAULT_SORT_ORDER

Added in API level 1
String DEFAULT_SORT_ORDER

此常数在API级别5中已弃用。
ContactsContract

此表的默认排序顺序

常数值:“名称ASC”

PRIMARY_EMAIL_ID

Added in API level 1
String PRIMARY_EMAIL_ID

此常数在API级别5中已弃用。
ContactsContract

这些人的ID最喜欢电子邮件。

类型:INTEGER(_ID字段上的contact_methods表的外键)

常量值:“primary_email”

PRIMARY_ORGANIZATION_ID

Added in API level 1
String PRIMARY_ORGANIZATION_ID

此常数在API级别5中已弃用。
ContactsContract

个人首选组织的ID。

类型:INTEGER(_ID字段上的组织表的外键)

常数值:“primary_organization”

PRIMARY_PHONE_ID

Added in API level 1
String PRIMARY_PHONE_ID

此常数在API级别5中已弃用。
ContactsContract

人员的首选电话号码。

类型:INTEGER(_ID字段中的手机表的外键)

常数值:“primary_phone”

Fields

CONTENT_FILTER_URI

Added in API level 1
Uri CONTENT_FILTER_URI

此字段在API级别5中已弃用。
ContactsContract

用于按名称过滤人员的内容://样式网址。 过滤器参数应该在此URI之后作为附加路径段传递。

CONTENT_URI

Added in API level 1
Uri CONTENT_URI

此字段在API级别5中已弃用。
ContactsContract

此表格的内容://样式网址

DELETED_CONTENT_URI

Added in API level 1
Uri DELETED_CONTENT_URI

此字段在API级别5中已弃用。
ContactsContract

包含已删除联系人的表格的内容://样式网址。

Public methods

addToGroup

Added in API level 1
Uri addToGroup (ContentResolver resolver, 
                long personId, 
                long groupId)

此方法在API级别5中已被弃用。
ContactsContract

添加一个人到一个组。

Parameters
resolver ContentResolver: the resolver to use
personId long: the person to add to the group
groupId long: the group to add the person to
Returns
Uri the URI of the group membership row

addToGroup

Added in API level 1
Uri addToGroup (ContentResolver resolver, 
                long personId, 
                String groupName)

此方法在API级别5中已被弃用。
ContactsContract

将一个人添加到按名称引用的组中。

Parameters
resolver ContentResolver: the resolver to use
personId long: the person to add to the group
groupName String: the name of the group to add the contact to
Returns
Uri the URI of the group membership row
Throws
IllegalStateException if the group can't be found

addToMyContactsGroup

Added in API level 1
Uri addToMyContactsGroup (ContentResolver resolver, 
                long personId)

此方法在API级别5中已被弃用。
ContactsContract

向“我的联系人”组添加一个人。

Parameters
resolver ContentResolver: the resolver to use
personId long: the person to add to the group
Returns
Uri the URI of the group membership row
Throws
IllegalStateException if the My Contacts group can't be found

createPersonInMyContactsGroup

Added in API level 1
Uri createPersonInMyContactsGroup (ContentResolver resolver, 
                ContentValues values)

此方法在API级别5中已被弃用。
ContactsContract

创建一个新的联系人并将其添加到“我的联系人”组。

Parameters
resolver ContentResolver: the ContentResolver to use
values ContentValues: the values to use when creating the contact
Returns
Uri the URI of the contact, or null if the operation fails

loadContactPhoto

Added in API level 1
Bitmap loadContactPhoto (Context context, 
                Uri person, 
                int placeholderImageResource, 
                BitmapFactory.Options options)

此方法在API级别5中已被弃用。
ContactsContract

打开人物照片的InputStream并将照片作为位图返回。 如果该人的照片不存在,则返回placeholderImageResource。

Parameters
context Context: the Context
person Uri: the person whose photo should be used
placeholderImageResource int: the image resource to use if the person doesn't have a photo
options BitmapFactory.Options: the decoding options, can be set to null
Returns
Bitmap

markAsContacted

Added in API level 1
void markAsContacted (ContentResolver resolver, 
                long personId)

此方法在API级别5中已被弃用。
ContactsContract

将某人标记为已被联系。

Parameters
resolver ContentResolver: the ContentResolver to use
personId long: the person who was contacted

openContactPhotoInputStream

Added in API level 1
InputStream openContactPhotoInputStream (ContentResolver cr, 
                Uri person)

此方法在API级别5中已被弃用。
ContactsContract

打开人物照片的InputStream并将照片作为位图返回。 如果该人的照片不存在,则返回placeholderImageResource。

Parameters
cr ContentResolver
person Uri: the person whose photo should be used
Returns
InputStream

queryGroups

Added in API level 1
Cursor queryGroups (ContentResolver resolver, 
                long person)

此方法在API级别5中已被弃用。
ContactsContract

Parameters
resolver ContentResolver
person long
Returns
Cursor

setPhotoData

Added in API level 1
void setPhotoData (ContentResolver cr, 
                Uri person, 
                byte[] data)

此方法在API级别5中已被弃用。
ContactsContract

为这个人设置照片。 数据可能为空

Parameters
cr ContentResolver: the ContentResolver to use
person Uri: the Uri of the person whose photo is to be updated
data byte: the byte[] that represents the photo

Hooray!