ContactInformation 類別
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
代表沒有與連絡人存放區關聯的連絡人。
public ref class ContactInformation sealed : IContactInformation
/// [Windows.Foundation.Metadata.Activatable(65536, "Windows.Phone.PhoneContract")]
/// [Windows.Foundation.Metadata.ContractVersion(Windows.Phone.PhoneContract, 65536)]
/// [Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
class ContactInformation final : IContactInformation
[Windows.Foundation.Metadata.Activatable(65536, "Windows.Phone.PhoneContract")]
[Windows.Foundation.Metadata.ContractVersion(typeof(Windows.Phone.PhoneContract), 65536)]
[Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
public sealed class ContactInformation : IContactInformation
function ContactInformation()
Public NotInheritable Class ContactInformation
Implements IContactInformation
- 繼承
- 屬性
- 實作
Windows 需求
裝置系列 |
Windows Mobile Extension SDK (已於 10.0.10240.0 引進)
|
API contract |
Windows.Phone.PhoneContract (已於 v1.0 引進)
|
應用程式功能 |
ID_CAP_CONTACTS [Windows Phone]
|
備註
這個類別可用來儲存連絡人的相關資訊。 它有一組常用的內建屬性,例如系列名稱和描述,也可讓您將自訂屬性儲存為名稱/值組。 StoredContact類別會共用所有這些屬性,但您必須開啟應用程式的自訂連絡人存放區,才能取得 類別的實例。 許多應用程式都會直接使用 StoredContact ,而且絕對不需要使用 ContactInformation。 如果您需要暫時儲存連絡人資訊而不開啟連絡人存放區,或者如果您需要使用 ParseVcardAsync 從 vCard剖析連絡人資訊,您可以使用 ContactInformation,然後將物件傳遞至 StoredContact 建構函式。
建構函式
ContactInformation() |
初始化 ContactInformation 類別的新實例。 |
屬性
DisplayName |
取得或設定連絡人的顯示名稱。 |
DisplayPicture |
取得連絡人的顯示圖片。 |
FamilyName |
取得或設定連絡人的系列名稱。 |
GivenName |
取得或設定連絡人的指定名稱。 |
HonorificPrefix |
取得或設定連絡人的接受前置詞。 |
HonorificSuffix |
取得或設定連絡人的接受尾碼。 |
方法
GetDisplayPictureAsync() |
取得連絡人的顯示圖片。 |
GetPropertiesAsync() |
取得連絡人的屬性,做為名稱/值組的對應。 |
ParseVcardAsync(IInputStream) |
從資料流程剖析 vCard,並傳回填入的 ContactInformation 物件。 |
SetDisplayPictureAsync(IInputStream) |
使用 IInputStream 物件設定連絡人的顯示圖片。 |
ToVcardAsync() |
使用 vCard 3.0 版格式擷取連絡人的 vCard 標記法。 |
ToVcardAsync(VCardFormat) |
使用指定的 vCard 格式擷取連絡人的 vCard 標記法。 |