class CMnGeocodingServiceBase : public CMnServiceBase |
Provider Application must derive its geocoding service class from this one. This base implementation hides IPC communication details and provides native methods for accessing various parameters, specified by client.
Provider Application must return pointer to instance of its class, derived from this class, in response to CAknAppService::CreateServiceL() call, if given parameter is KMnAppGeocodingService.
This class defines handlers of particular requests from client as pure virtual methods, which derived class must implement. The parameters, which client application may specify in CMnGeocoder are accessible via other methods of this class. Implementation must obey these parameters and use them as specified in CMnGeocoder .
See parent CMnServiceBase class documentation for other details.
Public Member Functions | |
---|---|
IMPORT_C void | CompleteGeocodingRequestL(const CPosLandmark &) |
IMPORT_C CMnGeocoder::TOptions | Options() |
Protected Member Functions | |
---|---|
CMnGeocodingServiceBase() | |
~CMnGeocodingServiceBase() | |
IMPORT_C void | BaseConstructL() |
void | HandleFindAddressByCoordinateL(const CPosLandmark &) |
void | HandleFindCoordinateByAddressL(const CPosLandmark &) |
void | HandleFindCoordinateByAddressL(const TDesC &) |
IMPORT_C void | ServiceL(const RMessage2 &) |
Private Member Functions | |
---|---|
void | HandleGetConversionResultL(const RMessage2 &) |
void | StartAsyncRequestL(const RMessage2 &) |
void | UnpackOptionsL(const RMessage2 &) |
HBufC * | UnpackPlainAddressLC(const RMessage2 &) |
Inherited Enumerations | |
---|---|
CSession2:TPanicNo |
Private Attributes | |
---|---|
CMnGeocoder::TOptions | iOptions |
HBufC8 * | iResult |
TInt | iResultType |
Inherited Attributes | |
---|---|
CMnServiceBase::iMessage |
IMPORT_C void | BaseConstructL | ( | ) | [protected] |
This method must be called from derived class' ConstructL to allow internal initialization of this class.
IMPORT_C void | CompleteGeocodingRequestL | ( | const CPosLandmark & | aLandmark | ) |
Implementation must call this method to signal successful completion of conversion request. Result of conversion is supplied as landmark object. It must contain only data, which is part of conversion result, any other fields shall be left empty.
const CPosLandmark & aLandmark | Landmark containing result of conversion. |
void | HandleFindAddressByCoordinateL | ( | const CPosLandmark & | aLandmark | ) | [protected, pure virtual] |
Derived class must implement this method obeying specification of CMnGeocoder::FindAddressByCoordinateL() and if KMnSvcFeatureCoordToAddr feature is specified in SERVICE_INFO.
If given landmark coordinates cannot be resolved to address due to some ambiguity, then user shall be queried, if allowed by options (see Options() ). If it is not allowed, the operation shall be completed with KErrNotFound (CompleteRequest() ).
This is asynchronous request. Client's request must be completed (when resolving succeeded) with CompleteGeocodingRequest().
const CPosLandmark & aLandmark | Contains coordinate information to be resolved to address. |
void | HandleFindCoordinateByAddressL | ( | const CPosLandmark & | aLandmark | ) | [protected, pure virtual] |
Derived class must implement this method obeying specification of CMnGeocoder::FindCoordinateByAddressL (const CPosLandmark&, TRequestStatus&) and if KMnSvcFeatureAddrToCoord feature is specified in SERVICE_INFO.
If given address cannot be resolved to coordinates due to some ambiguity, then user shall be queried, if allowed by options (see Options() ).If it is not allowed, the result of the operation shall be KErrNotFound.
This is asynchronous request. Client's request must be completed (when resolving succeeded) with CompleteGeocodingRequest().
const CPosLandmark & aLandmark | Contains address information to be resolved to coordinate. |
void | HandleFindCoordinateByAddressL | ( | const TDesC & | aAddress | ) | [protected, pure virtual] |
This overload is for cases when address is specified as plain string. Derived class must implement this method obeying specification of CMnGeocoder::FindCoordinateByAddressL (const TDesC& aAddress, TRequestStatus& aRequest) and if KMnSvcFeaturePlainAddrToCoord feature is specified in SERVICE_INFO.
If given address cannot be resolved to coordinates due to some ambiguity, then user shall be queried, if allowed by options (see Options() ).If it is not allowed, the result of the operation shall be KErrNotFound.
This is asynchronous request. Client's request must be completed (when resolving succeeded) with CompleteGeocodingRequest().
const TDesC & aAddress | Address information to be resolved to coordinate. |
void | HandleGetConversionResultL | ( | const RMessage2 & | aMsg | ) | [private] |
const RMessage2 & aMsg |
IMPORT_C CMnGeocoder::TOptions | Options | ( | ) | const |
This options must be utilized in request handlers as specified in CMnGeocoder .
IMPORT_C void | ServiceL | ( | const RMessage2 & | aMessage | ) | [protected, virtual] |
Override of CSession2::ServiceL(). If further overridden, this function must be base-called.
const RMessage2 & aMessage | The client message |
void | StartAsyncRequestL | ( | const RMessage2 & | aMessage | ) | [private] |
const RMessage2 & aMessage |
void | UnpackOptionsL | ( | const RMessage2 & | aMsg | ) | [private] |
const RMessage2 & aMsg |
HBufC * | UnpackPlainAddressLC | ( | const RMessage2 & | aMsg | ) | [private] |
const RMessage2 & aMsg |
Copyright ©2010 Nokia Corporation and/or its subsidiary(-ies).
All rights
reserved. Unless otherwise stated, these materials are provided under the terms of the Eclipse Public License
v1.0.