CLbsRefLocationSourceBase Class Reference

class CLbsRefLocationSourceBase : public CBase

Defines the interface which needs to be implemented by the ECOM plugins which can return a reference position. The interface allows for a request to a reference position and for cancelling that request. The requests are asynchronous, the result being given through an observer interface. So when the implementation manages to obtain the reference position it returns it through the calls in MLbsRefLocationObserver . If there is an error retrieving the reference position then this error should be reported through the call-back. The interface allows also cancelling of the request made. If no request is outstanding nothing should be done. If a second request is made while one is already active then the second request can just be ignored (since the request doesn't really have any parameters and all it's doing is retrieving something that is stored, there is no need to pass through the second request when the first one is still outstanding).

The implementer of the interface needs to call the BaseConstructL() method as part of the construction procedure to ensure the object is build fully.

MLbsRefLocationObserver

Inherits from

Constructor & Destructor Documentation

CLbsRefLocationSourceBase(MLbsRefLocationObserver &)

IMPORT_C CLbsRefLocationSourceBase ( MLbsRefLocationObserver & aObserver ) [protected]

Constructor

Parameters

MLbsRefLocationObserver & aObserver Reference to the class that should receive all the callbacks

~CLbsRefLocationSourceBase()

IMPORT_C ~CLbsRefLocationSourceBase ( )

Destructor

Member Functions Documentation

BaseConstructL()

IMPORT_C void BaseConstructL ( ) [protected]

Base 2nd stage constructor. The implementer of the interface needs to call this method as part of the construction procedure to ensure the object is build fully.

CancelRefPositionInfoRequest()

void CancelRefPositionInfoRequest ( ) [pure virtual]

Interface definition. This method is used to cancel a previous request for reference position information.

ExtendedInterface(TInt, TAny *, TAny *)

IMPORT_C TAny * ExtendedInterface ( TInt aFunctionNumber,
TAny * aPtr1,
TAny * aPtr2
) [private, virtual]

This method is used to allow polymorphic extensions to the API without breaking BC.

Reserved for future expansion.

Parameters

TInt aFunctionNumber contains the Id of the function to be invoked internally.
TAny * aPtr1 a pointer to any data.
TAny * aPtr2 a pointer to any data.

NewL(MLbsRefLocationObserver &, TUid)

IMPORT_C CLbsRefLocationSourceBase * NewL ( MLbsRefLocationObserver & aObserver,
TUid aEcomModuleId
) [static]

Two-phase constructor that loads the right ECOM implementation of the interface and provides a pointer to it.

Parameters

MLbsRefLocationObserver & aObserver Reference to the class that should receive all the callbacks
TUid aEcomModuleId The UID of the ECOM implementation that should be loaded

RequestRefPositionInfo()

void RequestRefPositionInfo ( ) [pure virtual]

Interface definition. This method is used to make a request for reference position information.

Making a request while another one is outstanding should not affect anything and can be ignored.

SetRequestorAddress(const TDesC &)

void SetRequestorAddress ( const TDesC & aAddress ) [pure virtual]

Method used to set the address of the original requester of the reference location.

Parameters

const TDesC & aAddress The adress of the originator of the request

Version()

IMPORT_C TVersion Version ( ) const

Method which shows which version of the interface the implementation is using

Member Data Documentation

TUid iDtor_ID_Key

TUid iDtor_ID_Key [private]

the ID key used for destroying the ECom interface

MLbsRefLocationObserver & iObserver

MLbsRefLocationObserver & iObserver [protected]

Observer which receives call-backs with the ref position information

TAny * iReserved

TAny * iReserved [private]

reserved for future use

TVersion iVersion

TVersion iVersion [private]

The version of the interface