PosLmCategorySerialization Class Reference

#include <mw/epos_poslmcategoryserialization.h>

Link against: eposlandmarks.lib

class PosLmCategorySerialization
Public Member Functions
IMPORT_C HBufC8 *PackL(const CPosLandmarkCategory &)
IMPORT_C CPosLandmarkCategory *UnpackL(const TDesC8 &)

Detailed Description

This class contains helper methods for landmark category serialization. A landmark category can be packed into a buffer with PackL method and unpacked back with UnpackL method.

Since
S60 3.1

Member Function Documentation

PackL ( const CPosLandmarkCategory & )

IMPORT_C HBufC8 *PackL(const CPosLandmarkCategory &aCategory)[static]

Packs category object into a buffer.

All the data is preserved when packing. Database information is not stored. Packed category can be unpacked with UnpackL method.

ParameterDescription
aCategoryThe category to be packed.

Returns: The buffer with the category data packed. Ownership is transferred to the client.

UnpackL ( const TDesC8 & )

IMPORT_C CPosLandmarkCategory *UnpackL(const TDesC8 &aBuffer)[static]

Unpacks a category object, packed with PackL method, from buffer.

All the data is preserved when packing, and restored exactly when unpacking. It means that category ID is valid only for the database, this category was read from.

leave
KErrCorrupt if buffer does not contain valid category package.
ParameterDescription
aBufferThe buffer containing category.

Returns: The category unpacked. Ownership is transferred to client.