#include <app/MVPbkStoreContactFieldCollection.h>
class MVPbkStoreContactFieldCollection : public MVPbkBaseContactFieldCollection |
Public Member Functions | |
---|---|
virtual | ~MVPbkStoreContactFieldCollection() |
pure virtual const MVPbkStoreContactField & | FieldAt(TInt) |
pure virtual MVPbkStoreContactField & | FieldAt(TInt) |
pure virtual MVPbkStoreContactField * | FieldAtLC(TInt) |
pure virtual MVPbkStoreContact & | ParentStoreContact() |
pure virtual MVPbkStoreContactField * | RetrieveField(const MVPbkContactLink &) |
virtual TAny * | StoreContactFieldCollectionExtension(TUid) |
An interface for the field collection of the store contact
A field collection interface can be used for looping the contact fields.
~MVPbkStoreContactFieldCollection | ( | ) | [inline, virtual] |
Destructor.
const MVPbkStoreContactField & | FieldAt | ( | TInt | aIndex | ) | const [pure virtual] |
Reimplemented from MVPbkBaseContactFieldCollection::FieldAt(TInt)const
Returns a read-only field in this collection.
See also: MVPbkBaseContactFieldCollection::ConstFieldAt aIndex >= 0 && aIndex < FieldCount() Panic VPbkError::EInvalidFieldIndex is raised if the precondition does not hold.
Parameter | Description |
---|---|
aIndex | Zero-based index of the field to return. |
Returns: Reference to a field at aIndex. Reference is valid until FieldAt is called again.
MVPbkStoreContactField & | FieldAt | ( | TInt | aIndex | ) | [pure virtual] |
Returns a field in this collection.
See also: MVPbkStoreContactField::CloneLC aIndex >= 0 && aIndex < FieldCount() VPbkError::Panic(VPbkError::EInvalidFieldIndex) is raised if the precondition does not hold.
Parameter | Description |
---|---|
aIndex | A zero-based index of the field to return. |
Returns: A reference to the field at aIndex. Reference is valid until FieldAt is called again. If you need a permanent copy, call MVPbkStoreContactField::CloneLC to the returned field.
MVPbkStoreContactField * | FieldAtLC | ( | TInt | aIndex | ) | const [pure virtual] |
Returns a copy of the field in this collection.
Client gets the ownership of the field.
Parameter | Description |
---|---|
aIndex | A zero-based index of the field to return. |
Returns: A new instance to the field at aIndex. The field is valid as long as the parent contact is valid aIndex >= 0 && aIndex < FieldCount() VPbkError::Panic(VPbkError::EInvalidFieldIndex) is raised if the precondition does not hold.
MVPbkStoreContact & | ParentStoreContact | ( | ) | const [pure virtual] |
Returns the parent contact of the field collection
Returns: the parent contact of the field collection
MVPbkStoreContactField * | RetrieveField | ( | const MVPbkContactLink & | aContactLink | ) | const [pure virtual] |
Returns a field in this collection identified by a contact field link.
A contact field link can be created using the MVPbkStoreContactField interface. The same link works then as a contact link and a field link.
NOTE: implementations of stores are possibly using an index of the field as an identifier so clients should prefer not to save field links permanently. E.g modifying the contact can invalidate the link in some store implementations. A field link is practical in use cases where the link is created and immediately given to another component.
Parameter | Description |
---|---|
aContactLink | A valid contact field link. |
Returns: A field in this collection identified by aContactLink or NULL if the link does not contain field information or if the link does not refer to the parent contact of this field collection.