PosLandmarkSerialization Class Reference

#include <mw/epos_poslandmarkserialization.h>

Link against: eposlandmarks.lib

class PosLandmarkSerialization
Public Member Functions
IMPORT_C HBufC8 *PackL(const CPosLandmark &)
IMPORT_C CPosLandmark *UnpackL(const TDesC8 &)

Detailed Description

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

Since
S60 3.1

Member Function Documentation

PackL ( const CPosLandmark & )

IMPORT_C HBufC8 *PackL(const CPosLandmark &aLandmark)[static]

Packs landmark object into a buffer.

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

ParameterDescription
aLandmarkThe landmark to be packed.

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

UnpackL ( const TDesC8 & )

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

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

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

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

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