#include <app/cntvcard.h>
class CContactVCardConverter : public CContactEcomConverter, public CContactEcomConverter |
Public Member Enumerations | |
---|---|
enum | TOptions { EDefault, EIncludeX, ETTFormat, EExcludeUid, ..., EReplaceIfExists } |
enum | TVersitPropertyType { EPropertyValueSingle, EPropertyValueComposite, EPropertyValueHandlingNotImplemented } |
Public Member Functions | |
---|---|
TBool | ContainsExportableData(const TDesC &) |
TBool | ContainsImportableData(const TDesC &, TVersitPropertyType, TCntVCardImportType) |
virtual void | ExportL(CContactDatabase &, const CContactIdArray &, RWriteStream &, TInt, const Versit::TVersitCharSet, TBool, TInt) |
virtual CArrayPtr< CContactItem > * | ImportL(CContactDatabase &, RReadStream &, TBool &, TInt, TBool) |
CContactVCardConverter * | NewL() |
Plug-in vCard to CContactItem converter.
Import and export format flags. Contacts can be imported into or exported from the contact database as vCards.
The following options are available during import and export.
Enumerator | Value | Description |
---|---|---|
EDefault | CContactDatabase::EDefault | |
EIncludeX | CContactDatabase::EIncludeX |
Handle Symbian's extended vCard format options. |
ETTFormat | CContactDatabase::ETTFormat |
Support non-standard extensions requried by Symbian PC connectivity software and Microsoft, amongst others. |
EExcludeUid | CContactDatabase::EExcludeUid |
Don't export the contact ID (for exporting only). |
EDecreaseAccessCount | CContactDatabase::EDecreaseAccessCount |
Decrease the contact's access count when importing and exporting. |
EImportSingleContact | CContactDatabase::EImportSingleContact |
Only import the first contact in the read stream (for importing only). |
EIncreaseAccessCount | CContactDatabase::EIncreaseAccessCount |
Increase the contact's access count when importing and exporting. |
ELocalTime | CContactDatabase::ELocalTime |
Sets a contact item to the local time when importing. |
ENullTemplateId | CContactDatabase::ENullTemplateId |
Allows to set a template to a contact item that does not exist. |
EConnectWhitespace | 0x0100 |
Allows to set white spaces as value for an empty field. |
EIgnoreUid | CContactDatabase::EConverterReserved1 |
During import ignore the UID property value of the vCard. By ignoring the UID the client is indicating that it knows that the contact does not already exist in the database (i.e. the contact is being added rather than being updated). Within the CContactVCardConverter::ImportL() method no attempt to search for the UID in the database will be made. For a series of addition of vCards with UIDs use of this option will give a performance improvement since the search for the UID in the Contacts database can become very costly as the number of contacts grows. |
EReplaceIfExists | CContactDatabase::EConverterReserved2 |
During import, if it is determined that the contact item being imported already exists in the database then the contact item in the database will be deleted before being replaced by the vCard being imported. This option should be used when the client does not want a merge type behaviour for existing contact items. This option will typically be used in a sync use case where the vCard data that the client is provided with has already been through a process of conflict resolution and so the existing contact item should be replaced not merged. |
Enumerator | Value | Description |
---|---|---|
EPropertyValueSingle | ||
EPropertyValueComposite | ||
EPropertyValueHandlingNotImplemented |
TBool | ContainsImportableData | ( | const TDesC & | aText, |
TVersitPropertyType | aType, | |||
TCntVCardImportType | aImportType | |||
) | [static] |
void | ExportL | ( | CContactDatabase & | aDb, |
const CContactIdArray & | aSelectedContactIds, | |||
RWriteStream & | aWriteStream, | |||
TInt | aOptions, | |||
const Versit::TVersitCharSet | aCharSet, | |||
TBool | aExportPrivateFields, | |||
TInt | aCommitNumber | |||
) | [virtual] |
Reimplemented from CContactConverter::ExportL(CContactDatabase &,const CContactIdArray &,RWriteStream &,TInt,const Versit::TVersitCharSet,TBool,TInt)
CArrayPtr< CContactItem > * | ImportL | ( | CContactDatabase & | aDb, |
RReadStream & | aReadStream, | |||
TBool & | aImportSuccessful, | |||
TInt | aOptions, | |||
TBool | aImportSingle | |||
) | [virtual] |