CVasVPbkHandler Class Reference

class CVasVPbkHandler : public CBase

Phonebook handler that uses Virtual phonebook to access phonebook data

Since
3.2

Inherits from

Public Member Functions
~CVasVPbkHandler()
voidAttributeOperationComplete(MVPbkContactOperationBase &)
voidAttributeOperationFailed(MVPbkContactOperationBase &, TInt)
IMPORT_C voidChangeVoiceTagFieldL(TBool)
IMPORT_C voidCloseContactL(TBool)
IMPORT_C voidCompressL()
voidContactAddedToView(MVPbkContactViewBase &, TInt, const MVPbkContactLink &)
IMPORT_C CContactIdArray *ContactIdArrayLC()
voidContactOperationCompleted(TContactOpResult)
voidContactOperationFailed(TContactOp, TInt, TBool)
voidContactRemovedFromView(MVPbkContactViewBase &, TInt, const MVPbkContactLink &)
voidContactViewError(MVPbkContactViewBase &, TInt, TBool)
voidContactViewReady(MVPbkContactViewBase &)
voidContactViewUnavailable(MVPbkContactViewBase &)
IMPORT_C voidCreateContactObserverL(MVasContactObserver *)
IMPORT_C TIntFieldIdL()
IMPORT_C TFieldTypeFieldTypeL()
IMPORT_C voidFindContactFieldL(MNssTag *)
IMPORT_C voidFindContactL(MNssTag *)
IMPORT_C voidFindContactL(TInt32, TBool)
IMPORT_C voidFindDefaultContactFieldL(TInt)
IMPORT_C voidFindFieldL(MNssTag *)
IMPORT_C voidFindFieldL(TInt)
voidHandleStoreEventL(MVPbkContactStore &, TVPbkContactStoreEvent)
IMPORT_C voidInitializeL()
IMPORT_C TBoolIsFieldEmptyL()
IMPORT_C TPtrCLabelL()
IMPORT_C CVasVPbkHandler *NewL()
voidOpenComplete()
voidOperationComplete(MVPbkContactOperationBase &)
voidStepComplete(MVPbkContactOperationBase &, TInt)
TBool StepFailed(MVPbkContactOperationBase &, TInt, TInt)
voidStoreReady(MVPbkContactStore &)
voidStoreUnavailable(MVPbkContactStore &, TInt)
IMPORT_C TPtrCTextL()
voidVPbkSingleContactOperationComplete(MVPbkContactOperationBase &, MVPbkStoreContact *)
voidVPbkSingleContactOperationFailed(MVPbkContactOperationBase &, TInt)
Private Member Functions
CVasVPbkHandler()
TBool AcceptDefaultField(MVPbkStoreContactField &, TInt)
voidConstructL()
TVasContactEvent ConvertEvent(const TVPbkContactStoreEvent &)
TInt ConvertFieldId(MVPbkStoreContactField &)
TInt FieldPriority(MVPbkStoreContactField &)
TVPbkDefaultType SelectDefaultType(TInt)
Inherited Functions
CBase::CBase()
CBase::Delete(CBase *)
CBase::Extension_(TUint,TAny *&,TAny *)
CBase::operator new(TUint)
CBase::operator new(TUint,TAny *)
CBase::operator new(TUint,TLeave)
CBase::operator new(TUint,TLeave,TUint)
CBase::operator new(TUint,TUint)
CBase::~CBase()
Private Attributes
MVPbkStoreContact *iContact
CVPbkContactManager *iContactManager
CVPbkContactIdConverter *iConverter
TInt iError
MVPbkStoreContactField *iField
TBool iMMSSupported
MVasContactObserver *iObserver
MVPbkContactOperationBase *iOperation
CActiveSchedulerWait iWait

Constructor & Destructor Documentation

CVasVPbkHandler()

CVasVPbkHandler()[private]

C++ default constructor.

~CVasVPbkHandler()

IMPORT_C~CVasVPbkHandler()[virtual]

Destructor.

Since
3.2

Member Functions Documentation

AcceptDefaultField(MVPbkStoreContactField &, TInt)

TBool AcceptDefaultField(MVPbkStoreContactField &aField,
TIntaCommandType
)[private]

Checks if given field should be used

Parameters

MVPbkStoreContactField & aFieldField that is checked
TInt aCommandTypeCommand type that is used as a select parameter Must be one of TVasExtensionCommand types

AttributeOperationComplete(MVPbkContactOperationBase &)

voidAttributeOperationComplete(MVPbkContactOperationBase &aOperation)

Parameters

MVPbkContactOperationBase & aOperation

AttributeOperationFailed(MVPbkContactOperationBase &, TInt)

voidAttributeOperationFailed(MVPbkContactOperationBase &aOperation,
TIntaError
)

Parameters

MVPbkContactOperationBase & aOperation
TInt aError

ChangeVoiceTagFieldL(TBool)

IMPORT_C voidChangeVoiceTagFieldL(TBoolaSet)

Changes current field's voice tag field status

Since
3.2

Parameters

TBool aSetIf ETrue field is set else field is removed

CloseContactL(TBool)

IMPORT_C voidCloseContactL(TBoolaSaveChanges)

Closes contact with or without saving changes

Since
3.2

Parameters

TBool aSaveChangesETrue to save changes else EFalse

CompressL()

IMPORT_C voidCompressL()

Compresses database

Since
3.2

ConstructL()

voidConstructL()[private]

By default constructor is private.

ContactAddedToView(MVPbkContactViewBase &, TInt, const MVPbkContactLink &)

voidContactAddedToView(MVPbkContactViewBase &aView,
TIntaIndex,
const MVPbkContactLink &aContactLink
)

Parameters

MVPbkContactViewBase & aView
TInt aIndex
const MVPbkContactLink & aContactLink

ContactIdArrayLC()

IMPORT_C CContactIdArray *ContactIdArrayLC()

Returns all contact ids from database

Since
3.2

ContactOperationCompleted(TContactOpResult)

voidContactOperationCompleted(TContactOpResultaResult)

Parameters

TContactOpResult aResult

ContactOperationFailed(TContactOp, TInt, TBool)

voidContactOperationFailed(TContactOpaOpCode,
TIntaErrorCode,
TBoolaErrorNotified
)

Parameters

TContactOp aOpCode
TInt aErrorCode
TBool aErrorNotified

ContactRemovedFromView(MVPbkContactViewBase &, TInt, const MVPbkContactLink &)

voidContactRemovedFromView(MVPbkContactViewBase &aView,
TIntaIndex,
const MVPbkContactLink &aContactLink
)

Parameters

MVPbkContactViewBase & aView
TInt aIndex
const MVPbkContactLink & aContactLink

ContactViewError(MVPbkContactViewBase &, TInt, TBool)

voidContactViewError(MVPbkContactViewBase &aView,
TIntaError,
TBoolaErrorNotified
)

Parameters

MVPbkContactViewBase & aView
TInt aError
TBool aErrorNotified

ContactViewReady(MVPbkContactViewBase &)

voidContactViewReady(MVPbkContactViewBase &aView)

Parameters

MVPbkContactViewBase & aView

ContactViewUnavailable(MVPbkContactViewBase &)

voidContactViewUnavailable(MVPbkContactViewBase &aView)

Parameters

MVPbkContactViewBase & aView

ConvertEvent(const TVPbkContactStoreEvent &)

TVasContactEvent ConvertEvent(const TVPbkContactStoreEvent &aEvent)[private]

Converts contact event type

Parameters

const TVPbkContactStoreEvent & aEventEvent to be converted

ConvertFieldId(MVPbkStoreContactField &)

TInt ConvertFieldId(MVPbkStoreContactField &aField)[private]

Converts field id to old phonebook id

Parameters

MVPbkStoreContactField & aFieldField to be converted

CreateContactObserverL(MVasContactObserver *)

IMPORT_C voidCreateContactObserverL(MVasContactObserver *aObserver)

Creates the contact change notifier and sets observer as a listener

Since
3.2

Parameters

MVasContactObserver * aObserverContact change listener

FieldIdL()

IMPORT_C TIntFieldIdL()

Returns the field id

Since
3.2

FieldPriority(MVPbkStoreContactField &)

TInt FieldPriority(MVPbkStoreContactField &aField)[private]

Gets the priority of the given field

Parameters

MVPbkStoreContactField & aFieldField which priority is returned

FieldTypeL()

IMPORT_C TFieldTypeFieldTypeL()

Returns the field type

Since
3.2

FindContactFieldL(MNssTag *)

IMPORT_C voidFindContactFieldL(MNssTag *aTag)

Finds a field from contact

Since
3.2

Parameters

MNssTag * aTagTag that is used as a search parameter

FindContactL(MNssTag *)

IMPORT_C voidFindContactL(MNssTag *aTag)

Finds a contact from phonebook

Since
3.2

Parameters

MNssTag * aTagTag that is used as a search parameter

FindContactL(TInt32, TBool)

IMPORT_C voidFindContactL(TInt32aContactId,
TBoolaReadOnly
)

Finds a contact from phonebook

Since
3.2

Parameters

TInt32 aContactIdId of the contact that should be found
TBool aReadOnlyETrue if contact will not be edited else EFalse

FindDefaultContactFieldL(TInt)

IMPORT_C voidFindDefaultContactFieldL(TIntaCommandType)

Searches for a default field of a given type

Parameters

TInt aCommandTypeCommand type that is used as a select parameter Must be one of TVasExtensionCommand types

FindFieldL(MNssTag *)

IMPORT_C voidFindFieldL(MNssTag *aTag)

Finds a field from contact

Since
3.2

Parameters

MNssTag * aTagTag that is used as a search parameter

FindFieldL(TInt)

IMPORT_C voidFindFieldL(TIntaFieldId)

Finds a field from contact

Since
3.2

Parameters

TInt aFieldIdField id that is used as a search parameter

HandleStoreEventL(MVPbkContactStore &, TVPbkContactStoreEvent)

voidHandleStoreEventL(MVPbkContactStore &aContactStore,
TVPbkContactStoreEventaStoreEvent
)

Parameters

MVPbkContactStore & aContactStore
TVPbkContactStoreEvent aStoreEvent

InitializeL()

IMPORT_C voidInitializeL()

Opens phonebook connection and contact stores

Since
3.2

IsFieldEmptyL()

IMPORT_C TBoolIsFieldEmptyL()

Returns information if current field is empty

Since
3.2

LabelL()

IMPORT_C TPtrCLabelL()

Returns the field label

Since
3.2

NewL()

IMPORT_C CVasVPbkHandler *NewL()[static]

Two-phased constructor.

Since
3.2

OpenComplete()

voidOpenComplete()

OperationComplete(MVPbkContactOperationBase &)

voidOperationComplete(MVPbkContactOperationBase &aOperation)

Parameters

MVPbkContactOperationBase & aOperation

SelectDefaultType(TInt)

TVPbkDefaultType SelectDefaultType(TIntaCommandType)[private]

Selects default field type for the given tag

Parameters

TInt aCommandTypeCommand type that is used as a select parameter Must be one of TVasExtensionCommand types

StepComplete(MVPbkContactOperationBase &, TInt)

voidStepComplete(MVPbkContactOperationBase &aOperation,
TIntaStepSize
)

Parameters

MVPbkContactOperationBase & aOperation
TInt aStepSize

StepFailed(MVPbkContactOperationBase &, TInt, TInt)

TBool StepFailed(MVPbkContactOperationBase &aOperation,
TIntaStepSize,
TIntaError
)

Parameters

MVPbkContactOperationBase & aOperation
TInt aStepSize
TInt aError

StoreReady(MVPbkContactStore &)

voidStoreReady(MVPbkContactStore &aContactStore)

Parameters

MVPbkContactStore & aContactStore

StoreUnavailable(MVPbkContactStore &, TInt)

voidStoreUnavailable(MVPbkContactStore &aContactStore,
TIntaReason
)

Parameters

MVPbkContactStore & aContactStore
TInt aReason

TextL()

IMPORT_C TPtrCTextL()

Returns the field text

Since
3.2

VPbkSingleContactOperationComplete(MVPbkContactOperationBase &, MVPbkStoreContact *)

voidVPbkSingleContactOperationComplete(MVPbkContactOperationBase &aOperation,
MVPbkStoreContact *aContact
)

Parameters

MVPbkContactOperationBase & aOperation
MVPbkStoreContact * aContact

VPbkSingleContactOperationFailed(MVPbkContactOperationBase &, TInt)

voidVPbkSingleContactOperationFailed(MVPbkContactOperationBase &aOperation,
TIntaError
)

Parameters

MVPbkContactOperationBase & aOperation
TInt aError

Member Data Documentation

MVPbkStoreContact * iContact

MVPbkStoreContact *iContact[private]

CVPbkContactManager * iContactManager

CVPbkContactManager *iContactManager[private]

CVPbkContactIdConverter * iConverter

CVPbkContactIdConverter *iConverter[private]

TInt iError

TInt iError[private]

MVPbkStoreContactField * iField

MVPbkStoreContactField *iField[private]

TBool iMMSSupported

TBool iMMSSupported[private]

MVasContactObserver * iObserver

MVasContactObserver *iObserver[private]

MVPbkContactOperationBase * iOperation

MVPbkContactOperationBase *iOperation[private]

CActiveSchedulerWait iWait

CActiveSchedulerWait iWait[private]