#include <app/cntviewbase.h>
class CContactRemoteViewBase : public CContactViewBase |
Protected Attributes | |
---|---|
RContactRemoteView | iView |
Public Member Functions | |
---|---|
virtual HBufC * | AllFieldsLC(TInt, const TDesC &) |
virtual TContactItemId | AtL(TInt) |
virtual TAny * | CContactViewBase_Reserved_1(TFunction, TAny *) |
virtual const CViewContact & | ContactAtL(TInt) |
virtual TContactViewPreferences | ContactViewPreferences() |
virtual void | ContactsMatchingCriteriaL(const MDesCArray &, RPointerArray< CViewContact > &) |
virtual void | ContactsMatchingPrefixL(const MDesCArray &, RPointerArray< CViewContact > &) |
virtual TInt | CountL() |
virtual TInt | FindL(TContactItemId) |
virtual void | GetContactIdsL(const CArrayFix< TInt > &, CContactIdArray &) |
void | GetContactsMatchingFilterL(TInt, RArray< TContactIdWithMapping > &) |
virtual const RContactViewSortOrder & | SortOrderL() |
Protected Member Functions | |
---|---|
CContactRemoteViewBase(const CContactDatabase &) | |
~CContactRemoteViewBase() | |
void | ConstructL(MContactViewObserver &) |
Inherited Attributes | |
---|---|
CContactViewBase::iDb | |
CContactViewBase::iExtension | |
CContactViewBase::iState |
Inherited Enumerations | |
---|---|
CContactViewBase:TFunction | |
CContactViewBase:TSearchType | |
CContactViewBase:TState |
Base class for all remote contact view classes.
It implements all the pure virtual functions in CContactViewBase and additionally it handles remote view notifications. The data associated with remote views is allocated within the memory space of the contacts server. This means that multiple clients can share the same server side view object, thereby reducing the overhead associated with initial sorting of the view data and keeping it in sync with the underlying data. Remote views should therefore be used when the same view is likely to be needed by more than one client.
CContactRemoteViewBase | ( | const CContactDatabase & | aDb | ) | [protected] |
Protected C++ constructor.
Parameter | Description |
---|---|
aDb | The underlying database containing the contact items. |
~CContactRemoteViewBase | ( | ) | [protected] |
Reimplemented from CContactViewBase::AllFieldsLC(TInt,const TDesC &)const
Gets a descriptor containing the contents of all fields specified in the server side view's sort order for an item in the view.
The field separator is used to separate the contents of each field. It is not appended to the last field.
Parameter | Description |
---|---|
aIndex | The index of the contact item into the view. |
aSeparator | The string to use to separate the fields. |
Returns: Pointer to the contact item descriptor.
TContactItemId | AtL | ( | TInt | aIndex | ) | const [virtual] |
Reimplemented from CContactViewBase::AtL(TInt)const
Returns the ID of the contact item at a specified index into the the server side view.
Parameter | Description |
---|---|
aIndex | An index into the server side view. |
Returns: The ID of the contact item at the specified index.
Reimplemented from CContactViewBase::CContactViewBase_Reserved_1(TFunction,TAny *)
This is a reserved virtual exported function that is used for BC proofing against present and future additions of new exported virtual functions.
void | ConstructL | ( | MContactViewObserver & | aObserver | ) | [protected] |
Protected second phase constructor.
Starts an active object which notifies this view (by calling its HandleContactViewEvent() function) when view events occur in the server side view. This remote view in turn passes the events to its observers.
Parameter | Description |
---|---|
aObserver | An observer that receives notifications when this view is ready for use and when changes take place in it. The observer receives a TContactViewEvent::EReady event when the view is ready. An attempt to use the view before this notification causes a panic. |
const CViewContact & | ContactAtL | ( | TInt | aIndex | ) | const [virtual] |
Reimplemented from CContactViewBase::ContactAtL(TInt)const
Returns the contact item at a specified index into the server side view.
Parameter | Description |
---|---|
aIndex | An index into the server side view. |
Returns: The contact item at the specified index.
TContactViewPreferences | ContactViewPreferences | ( | ) | [virtual] |
Reimplemented from CContactViewBase::ContactViewPreferences()
Gets the server side view's view preferences.
Returns: The view preferences.
void | ContactsMatchingCriteriaL | ( | const MDesCArray & | aFindWords, |
RPointerArray< CViewContact > & | aMatchedContacts | |||
) | [virtual] |
Reimplemented from CContactViewBase::ContactsMatchingCriteriaL(const MDesCArray &,RPointerArray< CViewContact > &)
Searches all contact items in the server side view for fields that contain all of the search strings specified.
The search uses wildcard matching so that the search strings can occur anywhere in the item's fields. For a match to occur, all of the search strings must be found in a contact item.
Parameter | Description |
---|---|
aFindWords | A descriptor array containing one or more search strings. |
aMatchedContacts | On return, an array of matching contact items. |
void | ContactsMatchingPrefixL | ( | const MDesCArray & | aFindWords, |
RPointerArray< CViewContact > & | aMatchedContacts | |||
) | [virtual] |
Reimplemented from CContactViewBase::ContactsMatchingPrefixL(const MDesCArray &,RPointerArray< CViewContact > &)
Searches all contact items in the server side view for fields that contain all of the search strings specified.
Unlike ContactsMatchingCriteriaL(), the search term can only occur at the beginning of a field.
Parameter | Description |
---|---|
aFindWords | A descriptor array containing one or more search strings. |
aMatchedContacts | On return, an array of matching contact items. |
TInt | CountL | ( | ) | const [virtual] |
Reimplemented from CContactViewBase::CountL()const
Gets the total number of contact items in the server side view.
Returns: The number of contact items in the view.
TInt | FindL | ( | TContactItemId | aId | ) | const [virtual] |
Reimplemented from CContactViewBase::FindL(TContactItemId)const
Searches for a contact item in the server side view with the specified ID.
Parameter | Description |
---|---|
aId | The ID of the contact item to search for. |
Returns: If found, the index into the view of the matching item. Otherwise, KErrNotFound.
void | GetContactIdsL | ( | const CArrayFix< TInt > & | aIndexes, |
CContactIdArray & | aContactIds | |||
) | [virtual] |
Gets an array containing the IDs of the contact items at the specified indexes into the server side view.
The IDs are appended to the array.
Parameter | Description |
---|---|
aIndexes | An array of indexes into the server side view. |
aContactIds | On return, an array to which the contact item IDs of each of the indexed items are appended. |
void | GetContactsMatchingFilterL | ( | TInt | aFilter, |
RArray< TContactIdWithMapping > & | aMatchingContacts | |||
) |
Reimplemented from CContactViewBase::GetContactsMatchingFilterL(TInt,RArray< TContactIdWithMapping > &)
Requests an array of contact IDs from the server-side view which match the filter provided by the client.
const RContactViewSortOrder & | SortOrderL | ( | ) | const [virtual] |
Reimplemented from CContactViewBase::SortOrderL()const
Gets the server side view's sort order.
Returns: The sort order.