|
||
These tables list the UIDs that Symbian OS uses to identify vCard
properties and property parameters. The mapping between vCard properties and
Symbian OS-specific constants is done by the cntvcard component
(cntvcard.dll
).
The first column describes the properties and the second lists the
property names as they appear in a vCard. The third and fourth columns list the
corresponding Symbian UIDs. The combination of one or more field type UIDs and
an optional mapping UID uniquely identify each property. Field type and vCard
mapping UIDs are defined in cntdef.h
.
Description |
vCard property |
Field type UID |
Mapping UID |
PO Box |
|
|
|
Extended address |
|
|
|
Street |
|
|
|
City |
|
|
|
Region |
|
|
|
Postcode |
|
|
|
Country |
|
|
|
Agent |
|
None |
|
Birthday |
|
|
|
|
|
|
|
Formatted name |
|
None |
|
Longitude and latitude |
|
None |
|
Public encryption key |
|
None |
|
Label |
|
None |
|
Company logo |
|
|
|
Email software |
|
None |
|
Title |
|
|
|
First name |
|
|
|
Middle name |
|
|
|
Last name |
|
|
|
Suffix |
|
|
|
Notes |
|
|
|
Company |
|
|
|
Photograph |
|
|
|
Last Revision |
|
n/a – not stored in a field. See
|
|
Occupation |
|
None |
|
Sound |
|
None |
|
Given name pronunciation |
|
|
|
Family name pronunciation |
|
|
|
Company name pronunciation |
|
|
|
Tel |
|
|
|
Fax |
|
|
|
Job title |
|
|
|
Unique Identifier |
|
n/a – not stored in a field. See
|
|
Web page |
|
|
|
Version support |
|
n/a – not stored in a field. |
|
USIM second name (*) |
|
|
|
SIP address |
|
|
|
Other vCard extension properties |
|
None |
|
Assistant name |
X-ASSISTANT |
KUidContactFieldAssistant |
KUidContactFieldVCardMapAssistant |
Assistant phone |
X-ASSISTANTTEL |
|
KUidContactFieldVCardMapAssistantTel |
Anniversary |
X-ANNIVERSARY |
KUidContactFieldAnniversary |
KUidContactFieldVCardMapAnniversary |
Spouse |
X-SPOUSE |
KUidContactFieldSpouse |
KUidContactFieldVCardMapSpouse |
Children |
X-CHILDREN |
KUidContactFieldChildren |
KUidContactFieldVCardMapChildren |
Class |
X-CLASS |
KUidContactFieldClass |
KUidContactFieldVCardMapClass |
Department |
X-DEPARTMENT |
KUidContactFieldDepartmentName |
KUidContactFieldVCardMapDepartment |
(*) This field stores an additional representation of the contact's name, such as a nickname or a different representation. An example is a Japanese contact which has a Romanised name and an alternative representation using kanji (pictogram) characters.
ADR:
vCard property parameter |
Field type UID |
|
|
|
|
|
|
EMAIL:
vCard property parameter |
Field type UID |
|
|
|
|
|
|
|
|
|
|
(*) If HOME, WORK and CELL are absent then INTERNET is inserted by default.
KEY:
vCard property parameter |
Field type UID |
|
|
|
|
LABEL:
vCard property parameter |
Field type UID |
|
|
|
|
|
|
|
|
PHOTO:/LOGO:
vCard property parameter |
Field type UID |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
TEL:
vCard property parameter |
Field type UID |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
(*) |
(*) Fax numbers are not stored using a telephone number field type
(KUidContactFieldPhoneNumber
), but a fax field type
(KUidContactFieldFax
;
mapping=KUidContactFieldVCardMapFAX
).
URL:
vCard property parameter |
Field type UID |
|
|
|
|
X-SIP:
vCard property parameter |
Field type UID |
|
|
|
|
|
|
The following example demonstrates how a contact item
(newCard
) is created and assigned fields of different types using
some of the UIDs listed in the tables above.
#include <cntitem.h>
#include <cntfield.h>
#include <cntfldst.h>
#include <cntdef.h>
#include <cntdef.hrh>
// Create a contact card and add a work phone number. Numeric values are
// stored in a text field (storage type = KStorageTypeText).
CContactCard* newCard = CContactCard::NewLC();
_LIT(KWorkNumber,"02071234567");
// First create the field to hold the phone number
CContactItemField* phonefield=CContactItemField::NewLC(KStorageTypeText);
// Set the field types and mapping UIDs for a work phone number property
phonefield->AddFieldTypeL(KUidContactFieldPhoneNumber);
phonefield->AddFieldTypeL(KUidContactFieldVCardMapWORK);
// Make it the preferred number
phonefield->AddFieldTypeL(KUidContactFieldVCardMapPREF);
phonefield->SetMapping(KUidContactFieldVCardMapTEL);
// Add the telephone number to the field and the field to the card
phonefield->TextStorage()->SetTextL(KWorkNumber);
newCard->AddFieldL(*phonefield); // newCard takes ownership
CleanupStack::Pop(); // phonefield
// Add a birthday property. Date property values are stored using "date/time"
// fields (storage type=KStorageTypeDateTime).
CContactItemField* birthdayfield=CContactItemField::NewLC(KStorageTypeDateTime);
birthdayfield->AddFieldTypeL(KUidContactFieldBirthday);
birthdayfield->SetMapping(KUidContactFieldVCardMapBDAY);
// Set birthday - 10 Jan 1970
birthdayfield->DateTimeStorage()->SetTime(TDateTime(1970,EJanuary,9,0,0,0,0));
newCard->AddFieldL(*birthdayfield); // newCard takes ownership
CleanupStack::Pop(); // birthdayfield