RMsgStoreSearchCriteria Class Reference

class RMsgStoreSearchCriteria

This class represents the criteria for a search request

Constructor & Destructor Documentation

RMsgStoreSearchCriteria()

IMPORT_CRMsgStoreSearchCriteria()

Consturctor()

Member Functions Documentation

AddFolderId(TMsgStoreId)

IMPORT_C voidAddFolderId(TMsgStoreIdaFolderId)

Call this method to repeatly to specify the folders to be searched.

The order they are searched is the same as the order they are added. For example, to search the messages in "Inbox", "Sent Items", "Drafts" "Outbox", and other user-defined folders, add "Inbox" id first, followed by "Sent Item" id, than "Draft",etc.,

Parameters

TMsgStoreId aFolderId

AddResultPropertyL(const TDesC8 &)

IMPORT_C voidAddResultPropertyL(const TDesC8 &aPropertyKey)

Call this method to repeatly to specfy all the properties that the search result should include.

For example, in the folder view, the UI may only want to display "sender", "subject", "received date", and "flags", and not to display the rest of the properties. In this case, only add KMsgStorePropertySender, KMsgStorePropertySubject, KMsgStorePropertyReceivedAt, and KMsgStorePropertyFlags to this list and the sorted results will only include these properties.

Parameters

const TDesC8 & aPropertyKey

AddSearchStringL(const TDesC &)

IMPORT_C voidAddSearchStringL(const TDesC &aSearchString)

Call this method to repeatly to specfy all the search strings.

/note the logical expression among these search strings is: "AND". A message is consider match if each of the search string appears at least once in the any of the search fields.

Parameters

const TDesC & aSearchString

Close()

IMPORT_C voidClose()

Close() must be called before this object goes out of scope

FolderIds()

RArray< TMsgStoreId > &FolderIds()[inline]

Internal use only, not exported

PropertyKeys()

const RPointerArray< TDesC8 > &PropertyKeys()[inline]

Internal use only, not exported

SearchStrings()

RPointerArray< TDesC > &SearchStrings()[inline]

Internal use only, not exported Note, the return value should be a const, it's removed for unit testing purpose.

Member Data Documentation

RArray< TMsgStoreId > iFolderIds

RArray< TMsgStoreId >iFolderIds[private]

RPointerArray< TDesC8 > iPropertyKeys

RPointerArray< TDesC8 >iPropertyKeys[private]

TUint iSearchFields

TUint iSearchFields

Stores the search field masks defined as TMsgStoreSearchFieldMasks. By default, all search fields are enabled.

/note this field is not used in the current release. The server searches all the fields defined in TMsgStoreSearchFieldMasks.

RPointerArray< TDesC > iSearchStrings

RPointerArray< TDesC >iSearchStrings[private]

TMsgStoreSortOrder iSecondarySortOrder

TMsgStoreSortOrder iSecondarySortOrder

When the iSortBy field is not EMsgStoreSortByReceivedDate, the received date becomes secondary sorting field. This specifies whether the secondary should be ascending or descending.

Deafult value is EMsgStoreSortDescending.

TMsgStoreSortByField iSortBy

TMsgStoreSortByField iSortBy

Specifies the sort field. Default value is EMsgStoreSortByReceivedDate.

TMsgStoreSortOrder iSortOrder

TMsgStoreSortOrder iSortOrder

Specifies the sort order. Deafult value is EMsgStoreSortDescending.