00001 /* 00002 * Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). 00003 * All rights reserved. 00004 * This component and the accompanying materials are made available 00005 * under the terms of "Eclipse Public License v1.0" 00006 * which accompanies this distribution, and is available 00007 * at the URL "http://www.eclipse.org/legal/epl-v10.html". 00008 * 00009 * Initial Contributors: 00010 * Nokia Corporation - initial contribution. 00011 * 00012 * Contributors: 00013 * 00014 * Description: Class used by client applications to convert location 00015 * information 00016 * 00017 */ 00018 00025 #ifndef LBS_LOCATION_INFO_CONVERTER_H 00026 #define LBS_LOCATION_INFO_CONVERTER_H 00027 00028 00029 // OS wide 00030 #include <e32base.h> 00031 00032 // LBS wide 00033 #include <lbs/lbslocationcommon.h> 00034 #include <lbs/lbslocationinfo.h> 00035 #include <lbs/lbslocationinfoconvertercommon.h> 00036 00037 class CLbsLocationInfoConverterImpl; 00038 00039 00054 class MLbsLocationInfoConverterObserver 00055 { 00056 00057 public: 00058 00065 IMPORT_C virtual TVersion Version() const; 00066 00088 virtual void OnConversionComplete(TInt aStatusCode) = 0; 00089 00090 }; 00091 00092 00093 00094 00105 class CLbsLocationInfoConverter : public CBase 00106 { 00107 00108 public: 00109 00115 IMPORT_C static CLbsLocationInfoConverter* NewL( 00116 MLbsLocationInfoConverterObserver& aObserver, 00117 const TUid aConverterModuleId); 00118 00125 IMPORT_C static CLbsLocationInfoConverter* NewL( 00126 MLbsLocationInfoConverterObserver& aObserver); 00127 00131 IMPORT_C ~CLbsLocationInfoConverter(); 00132 00151 IMPORT_C void ConvertLocationInfoL( CLbsLocationInfoBase& aLocationInfo, 00152 const TLbsConversionPrefs aConversionPrefs, 00153 const TLbsConversionOutputInfoMask aRequestedInfo ); 00154 00155 00180 IMPORT_C void ConvertLocationInfoL( RLbsLocationInfoBaseArray& aLocationInfoArray, 00181 const TLbsConversionPrefs aConversionPrefs, 00182 const TLbsConversionOutputInfoMask aRequestedInfo ); 00183 00190 IMPORT_C void CancelConvertLocationInfo(); 00191 00192 private: 00193 00197 CLbsLocationInfoConverter(); 00198 00202 void ConstructL(MLbsLocationInfoConverterObserver& aObserver, 00203 const TUid aConverterModuleId); 00204 00208 CLbsLocationInfoConverter( CLbsLocationInfoConverter& ); 00209 00213 CLbsLocationInfoConverter& operator=( CLbsLocationInfoConverter& ); 00214 00215 private: 00216 00220 CLbsLocationInfoConverterImpl* iLocationInfoConverterImpl; 00221 00222 }; 00223 00224 00225 00226 #endif // LBS_LOCATION_INFO_CONVERTER_H