Symbian
Symbian Developer Library

SYMBIAN OS V9.4

Feedback

[Index] [Previous] [Next]

#include <cntviewbase.h>
Link against: cntmodel.lib

Class RContactViewSortOrder

class RContactViewSortOrder;

Description

Specifies the sort order for a contact view.

It is implemented as an array of TFieldType UIDs, which define the fields whose contents are used to sort on, and their order.

The sort order for all concrete contact view classes can be retrieved using their implementation of CContactViewBase::SortOrderL(). The sort order is set during construction of local and remote views.

Members

Defined in RContactViewSortOrder:


Construction and destruction


RContactViewSortOrder()

IMPORT_C RContactViewSortOrder();

Description

Default C++ constructor.

[Top]


Member functions


Close()

IMPORT_C void Close();

Description

Closes the sort order array and frees all memory allocated to it.


CopyL()

IMPORT_C void CopyL(const RContactViewSortOrder &aSortOrder);

Description

Copies the field types contained in the specified sort order object into this object.

Any existing field types in this object are replaced.

Parameters

const RContactViewSortOrder &aSortOrder

The sort order to be copied.


InternalizeL()

IMPORT_C void InternalizeL(RReadStream &aStream);

Description

Internalises a sort order object from a read stream.

Parameters

RReadStream &aStream

The stream to read from.


ExternalizeL()

IMPORT_C void ExternalizeL(RWriteStream &aStream) const;

Description

Externalises a sort order object to a write stream.

Parameters

RWriteStream &aStream

The stream to write to.


ExternalizedSize()

IMPORT_C TInt ExternalizedSize() const;

Description

Retrieves the number of bytes required to store the sort order when externalised.

Return value

TInt

The size of the sort order object.


operator==()

IMPORT_C TBool operator==(const RContactViewSortOrder &aSortOrder) const;

Description

Compares two sort order objects for equivalence.

Parameters

const RContactViewSortOrder &aSortOrder

The sort order object to compare with this one.

Return value

TBool

ETrue if the two sort orders are the same, EFalse if not.


AppendL()

inline void AppendL(TFieldType aField);

Description

Appends a field type to the sort order object.

Parameters

TFieldType aField

The field type to append.


operator[]()

inline TFieldType operator[](TInt aIndex) const;

Description

Gets an indexed field type.

Parameters

TInt aIndex

Index of the required field type. A panic occurs if this is invalid.

Return value

TFieldType

The field type located at the indexed position in the array.


Count()

inline TInt Count() const;

Description

Gets the number of field types in the sort order array.

Return value

TInt

The number of field types in the array.