# HG changeset patch # User Pat Downey # Date 1277375314 -3600 # Node ID a85dbb892d7522d369d976718967297c337170d0 # Parent 18280709ae436d4f894272bc7d16266fe283f9e0# Parent 8e58c1bec439e23ccba5224f5cc01ef63d206902 Re-merge workaround for bug 2680. diff -r 8e58c1bec439 -r a85dbb892d75 cenrep/1028224B.cre Binary file cenrep/1028224B.cre has changed diff -r 8e58c1bec439 -r a85dbb892d75 cenrep/1028224B.txt Binary file cenrep/1028224B.txt has changed diff -r 8e58c1bec439 -r a85dbb892d75 cenrep/10282266.cre Binary file cenrep/10282266.cre has changed diff -r 8e58c1bec439 -r a85dbb892d75 cenrep/10282266.txt Binary file cenrep/10282266.txt has changed diff -r 8e58c1bec439 -r a85dbb892d75 datasourceadaptation/gpsdatasourceadaptation/psytester/psytester/src/epos_cpospsymemorytest.cpp --- a/datasourceadaptation/gpsdatasourceadaptation/psytester/psytester/src/epos_cpospsymemorytest.cpp Thu Jun 24 11:27:31 2010 +0100 +++ b/datasourceadaptation/gpsdatasourceadaptation/psytester/psytester/src/epos_cpospsymemorytest.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -223,7 +223,7 @@ TInt& aStackSize) { TInt tmp; - RHeap heap = User::Heap(); + RHeap& heap = User::Heap(); RThread thread; TThreadStackInfo info; thread.StackInfo(info); diff -r 8e58c1bec439 -r a85dbb892d75 datasourcemodules/bluetoothgpspositioningmodule/btgpsconfig/group/102869C1.cre Binary file datasourcemodules/bluetoothgpspositioningmodule/btgpsconfig/group/102869C1.cre has changed diff -r 8e58c1bec439 -r a85dbb892d75 datasourcemodules/bluetoothgpspositioningmodule/btgpsconfig/group/102869C1.txt Binary file datasourcemodules/bluetoothgpspositioningmodule/btgpsconfig/group/102869C1.txt has changed diff -r 8e58c1bec439 -r a85dbb892d75 datasourcemodules/bluetoothgpspositioningmodule/btgpsconfig/group/BLD.INF --- a/datasourcemodules/bluetoothgpspositioningmodule/btgpsconfig/group/BLD.INF Thu Jun 24 11:27:31 2010 +0100 +++ b/datasourcemodules/bluetoothgpspositioningmodule/btgpsconfig/group/BLD.INF Thu Jun 24 11:28:34 2010 +0100 @@ -13,7 +13,7 @@ // Description: // -#include "../btgpsconfigapi/group/BLD.INF" +#include "../btgpsconfigapi/group/bld.inf" // Main projects, in build order PRJ_EXPORTS diff -r 8e58c1bec439 -r a85dbb892d75 datasourcemodules/bluetoothgpspositioningmodule/btgpspsy/data/101FE99A.rss --- a/datasourcemodules/bluetoothgpspositioningmodule/btgpspsy/data/101FE99A.rss Thu Jun 24 11:27:31 2010 +0100 +++ b/datasourcemodules/bluetoothgpspositioningmodule/btgpspsy/data/101FE99A.rss Thu Jun 24 11:28:34 2010 +0100 @@ -22,7 +22,7 @@ // INCLUDES #include #include "btgpspsy.hrh" -#include "Nla_btgpspsy.loc" +#include "nla_btgpspsy.loc" // RESOURCE DEFINITIONS RESOURCE REGISTRY_INFO r_btpsy_reginfo diff -r 8e58c1bec439 -r a85dbb892d75 datasourcemodules/bluetoothgpspositioningmodule/btgpspsy/data/nlabtgpspsy_name.rss --- a/datasourcemodules/bluetoothgpspositioningmodule/btgpspsy/data/nlabtgpspsy_name.rss Thu Jun 24 11:27:31 2010 +0100 +++ b/datasourcemodules/bluetoothgpspositioningmodule/btgpspsy/data/nlabtgpspsy_name.rss Thu Jun 24 11:28:34 2010 +0100 @@ -21,7 +21,7 @@ // INCLUDES #include -#include +#include // RESOURCE DEFINITIONS diff -r 8e58c1bec439 -r a85dbb892d75 datasourcemodules/bluetoothgpspositioningmodule/btgpspsy/data/nlabtgpspsyconstants.rss --- a/datasourcemodules/bluetoothgpspositioningmodule/btgpspsy/data/nlabtgpspsyconstants.rss Thu Jun 24 11:27:31 2010 +0100 +++ b/datasourcemodules/bluetoothgpspositioningmodule/btgpspsy/data/nlabtgpspsyconstants.rss Thu Jun 24 11:28:34 2010 +0100 @@ -22,7 +22,7 @@ // INCLUDES #include #include -#include "Nla_btgpspsy.loc" +#include "nla_btgpspsy.loc" // RESOURCE SIGNATURE diff -r 8e58c1bec439 -r a85dbb892d75 datasourcemodules/bluetoothgpspositioningmodule/btgpspsy/group/bld.inf --- a/datasourcemodules/bluetoothgpspositioningmodule/btgpspsy/group/bld.inf Thu Jun 24 11:27:31 2010 +0100 +++ b/datasourcemodules/bluetoothgpspositioningmodule/btgpspsy/group/bld.inf Thu Jun 24 11:28:34 2010 +0100 @@ -23,7 +23,7 @@ PRJ_EXPORTS ./101fe999.cre z:/private/10202be9/101fe999.cre -../data/Nla_btgpspsy.loc OS_LAYER_LOC_EXPORT_PATH(Nla_btgpspsy.loc) +../data/nla_btgpspsy.loc OS_LAYER_LOC_EXPORT_PATH(nla_btgpspsy.loc) ../inc/Settings/BtGpsPsyPrivateCRKeys.h SYMBIAN_OS_LAYER_PLATFORM_EXPORT_PATH(lbs/btgpspsyprivatecrkeys.h) ../inc/Settings/BtGpsPsyPrivatePSKeys.h SYMBIAN_OS_LAYER_PLATFORM_EXPORT_PATH(lbs/btgpspsyprivatepskeys.h) diff -r 8e58c1bec439 -r a85dbb892d75 datasourcemodules/bluetoothgpspositioningmodule/conf/bluetoothgpspsy_102869c1.crml Binary file datasourcemodules/bluetoothgpspositioningmodule/conf/bluetoothgpspsy_102869c1.crml has changed diff -r 8e58c1bec439 -r a85dbb892d75 datasourcemodules/bluetoothgpspositioningmodule/group/bld.inf --- a/datasourcemodules/bluetoothgpspositioningmodule/group/bld.inf Thu Jun 24 11:27:31 2010 +0100 +++ b/datasourcemodules/bluetoothgpspositioningmodule/group/bld.inf Thu Jun 24 11:28:34 2010 +0100 @@ -14,7 +14,7 @@ // // Main projects, in build order -#include "../btgpsconfig/group/BLD.INF" +#include "../btgpsconfig/group/bld.inf" #include "../btgpspsy/group/bld.inf" PRJ_EXPORTS diff -r 8e58c1bec439 -r a85dbb892d75 datasourcemodules/locationapesuplpsy/group/bld.inf --- a/datasourcemodules/locationapesuplpsy/group/bld.inf Thu Jun 24 11:27:31 2010 +0100 +++ b/datasourcemodules/locationapesuplpsy/group/bld.inf Thu Jun 24 11:28:34 2010 +0100 @@ -30,10 +30,15 @@ // Conf Files... ../conf/ape_suplpsy.confml OS_LAYER_CONFML(ape_suplpsy.confml) -../conf/ape_suplpsy_20026FB7.crml OS_LAYER_CRML(ape_suplpsy_20026FB7.crml) +../conf/ape_suplpsy_20026fb7.crml OS_LAYER_CRML(ape_suplpsy_20026fb7.crml) + +../inc/lbssuplpsyadaptation.h /epoc32/include/lbssuplpsyadaptation.h -../inc/lbssuplpsyadaptation.h /epoc32/include/lbsSuplPsyAdaptation.h +// Techview rom +nla_ape_suplpsy.iby /epoc32/rom/include/nla_ape_suplpsy.iby +// Test only +../cenrep/20026fb7.txt z:/private/10202be9/20026fb7.txt PRJ_MMPFILES nla_ape_suplpsy.mmp diff -r 8e58c1bec439 -r a85dbb892d75 datasourcemodules/locationapesuplpsy/group/lbs_ape_supl_positioning_module.mrp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/datasourcemodules/locationapesuplpsy/group/lbs_ape_supl_positioning_module.mrp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,27 @@ +# +# Copyright (c) 2010 Nokia Corporation and/or its subsidiary(-ies). +# All rights reserved. +# This component and the accompanying materials are made available +# under the terms of "Eclipse Public License v1.0" +# which accompanies this distribution, and is available +# at the URL "http://www.eclipse.org/legal/epl-v10.html". +# +# Initial Contributors: +# Nokia Corporation - initial contribution. +# +# Contributors: +# +# Description: +# + +component lbs_ape_supl_positioning_module + +source \sf\os\lbs\datasourcemodules\locationapesuplpsy + +binary \sf\os\lbs\datasourcemodules\locationapesuplpsy\group all + +exports \sf\os\lbs\datasourcemodules\locationapesuplpsy\group + +notes_source \component_defs\release.src + +ipr E diff -r 8e58c1bec439 -r a85dbb892d75 datasourcemodules/locationapesuplpsy/group/nla_ape_suplpsy.iby --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/datasourcemodules/locationapesuplpsy/group/nla_ape_suplpsy.iby Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,30 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ +#ifndef __LBS_APE_SUPLPSY_IBY__ +#define __LBS_APE_SUPLPSY_IBY__ + +#if !defined(SYMBIAN_EXCLUDE_LOCATION) + +#ifdef _DEBUG +ECOM_PLUGIN_UDEB(nlaapesuplpsy.dll, nlaapesuplpsy.rsc) +#else +ECOM_PLUGIN(nlaapesuplpsy.dll, nlaapesuplpsy.rsc) +#endif //_DEBUG + +#endif + +#endif // __LBS_APE_SUPLPSY_IBY__ diff -r 8e58c1bec439 -r a85dbb892d75 datasourcemodules/locationapesuplpsy/group/nla_ape_suplpsy.mmp --- a/datasourcemodules/locationapesuplpsy/group/nla_ape_suplpsy.mmp Thu Jun 24 11:27:31 2010 +0100 +++ b/datasourcemodules/locationapesuplpsy/group/nla_ape_suplpsy.mmp Thu Jun 24 11:28:34 2010 +0100 @@ -64,5 +64,6 @@ LIBRARY flogger.lib +SMPSAFE // End of File diff -r 8e58c1bec439 -r a85dbb892d75 datasourcemodules/locationapesuplpsy/inc/suplpsyrequestor.h --- a/datasourcemodules/locationapesuplpsy/inc/suplpsyrequestor.h Thu Jun 24 11:27:31 2010 +0100 +++ b/datasourcemodules/locationapesuplpsy/inc/suplpsyrequestor.h Thu Jun 24 11:28:34 2010 +0100 @@ -23,7 +23,7 @@ // INCLUDES #include #include -#include +#include /** * Network Positioning Configuration API CenRep UID. @@ -39,6 +39,14 @@ */ const TUint32 KPSYTimeToNextFix = 0x00000005; +/* +* PM UID +* +* Name of key which holds the protocol module UID +*/ +const TUint32 KPSYPmUid = 0x00000013; + + // FORWARD DECLARATIONS class MLbsSuplPsyAdaptationObserver; class CLbsSuplPsyAdaptation; @@ -154,6 +162,8 @@ TUint iRequestId; TUint iRequestIdCount; + + TInt iPmUid; }; #endif // SUPLPSYREQUESTOR_H diff -r 8e58c1bec439 -r a85dbb892d75 datasourcemodules/locationapesuplpsy/src/lbssuplpsyadaptation.cpp --- a/datasourcemodules/locationapesuplpsy/src/lbssuplpsyadaptation.cpp Thu Jun 24 11:27:31 2010 +0100 +++ b/datasourcemodules/locationapesuplpsy/src/lbssuplpsyadaptation.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -25,7 +25,7 @@ #include "LbsPsyNgMsgs.h" #include "lbscommoninternaldatatypes.h" -#include +#include const TUid KSuplPsyUid = {KSuplPsyImplUid}; //KSuplPsyImplUid defined in "suplpsy.hrh" // ----------------------------------------------------------------------------- diff -r 8e58c1bec439 -r a85dbb892d75 datasourcemodules/locationapesuplpsy/src/suplpsyrequestor.cpp --- a/datasourcemodules/locationapesuplpsy/src/suplpsyrequestor.cpp Thu Jun 24 11:27:31 2010 +0100 +++ b/datasourcemodules/locationapesuplpsy/src/suplpsyrequestor.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -20,7 +20,7 @@ // INCLUDE FILES #include #include -#include +#include #include "suplpsyrequestor.h" #include "suplpsygenericinfouser.h" #include "suplpsylogging.h" @@ -67,6 +67,12 @@ //TInt keyValue; TInt ret = repository->Get(KPSYTimeToNextFix, iTtnf); + + if (KErrNone != repository->Get(KPSYPmUid, iPmUid)) + { + // Use default UID (SUPL Proxy PM) + iPmUid = 0x102871EC; + } delete repository; repository = NULL; @@ -146,30 +152,25 @@ { //Get position info TRACESTRING( "Extracting position... " ) - HPositionGenericInfo* posInfo = static_cast < HPositionGenericInfo*> ( &aPosition ); + HPositionGenericInfo* posInfo = static_cast < HPositionGenericInfo*> ( &aPosition ); - if ( aReason >= KErrNone ) - { //Set module Id iPositionInfo->SetModuleId( TUid::Uid( KSuplPsyImplUid ) ); - + //Set time - TPosition pos; - posInfo->GetPosition( pos ); - TTime now; - now.UniversalTime(); - pos.SetTime( now ); - iPositionInfo->SetPosition( pos ); - iPrevFixSuccess = ETrue; - //posInfo = NULL; - } - else - { - //delete posInfo; - //posInfo = NULL; - iPrevFixSuccess = EFalse; - } + TPosition pos; + posInfo->GetPosition( pos ); + TTime now; + now.UniversalTime(); + pos.SetTime( now ); + iPositionInfo->SetPosition( pos ); + iPrevFixSuccess = ETrue; + } + else + { + iPrevFixSuccess = EFalse; + } iObserver.CallBack(); TRACESTRING( "CSuplPsyRequestor::OnLocationUpdate end" ) } @@ -199,7 +200,7 @@ //Make location request iRequestId = GetRequestId(); - const TUint KProtocolModuleUidValue = 0x102871EC; + const TUint KProtocolModuleUidValue = iPmUid; const TUid KProtocolModuleUid = { KProtocolModuleUidValue }; iPsyAdaptation->RequestLocationUpdate(iRequestId, ETrue, KProtocolModuleUid); if (iFirstReq) diff -r 8e58c1bec439 -r a85dbb892d75 group/bld.inf --- a/group/bld.inf Thu Jun 24 11:27:31 2010 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,35 +0,0 @@ -/* -* Copyright (c) 2005 Nokia Corporation and/or its subsidiary(-ies). -* All rights reserved. -* This component and the accompanying materials are made available -* under the terms of "Eclipse Public License v1.0" -* which accompanies this distribution, and is available -* at the URL "http://www.eclipse.org/legal/epl-v10.html". -* -* Initial Contributors: -* Nokia Corporation - initial contribution. -* -* Contributors: -* -* Description: The common build file. -* -*/ - - -#include - -PRJ_PLATFORMS -DEFAULT - -#include "../datasourcemodules/locationapesuplpsy/group/bld.inf" //Component - APE SUPL PSY - -PRJ_EXPORTS -../inc/lbsipc.hrh /epoc32/include/lbs/lbsipc.hrh - -../cenrep/10282266.txt /epoc32/data/Z/private/10202be9/10282266.txt -../cenrep/1028224B.txt /epoc32/data/Z/private/10202be9/1028224B.txt - -../cenrep/10282266.cre /epoc32/winscw/c/private/10202be9/persists/10282266.cre -../cenrep/1028224B.cre /epoc32/winscw/c/private/10202be9/persists/1028224B.cre - -// End of File \ No newline at end of file diff -r 8e58c1bec439 -r a85dbb892d75 inc/lbsipc.hrh --- a/inc/lbsipc.hrh Thu Jun 24 11:27:31 2010 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,65 +0,0 @@ -/* -* Copyright (c) 2002-2005 Nokia Corporation and/or its subsidiary(-ies). -* All rights reserved. -* This component and the accompanying materials are made available -* under the terms of "Eclipse Public License v1.0" -* which accompanies this distribution, and is available -* at the URL "http://www.eclipse.org/legal/epl-v10.html". -* -* Initial Contributors: -* Nokia Corporation - initial contribution. -* -* Contributors: -* -* Description: Client-Server Request codes -* -*/ - - -#ifndef __LBSIPC_HRH__ -#define __LBSIPC_HRH__ - -// 0x00000000 to 0x00000FFF not used -#define EPositioningIpcOffset 0x1000 - -// 0x00001000 to 0x00001FFF reserved for RPositionServer requests -#define EPositionServerIpcOffset (EPositioningIpcOffset) - -// 0x00002000 to 0x00002FFF reserved for RPositioner requests -#define EPositionerIpcOffset (EPositionServerIpcOffset + 0x1000) - -// 0x40000000 to 0x7FFFFFFF reserved for 3rd party extensions to the LBS API. -// All extensions implemented by 3rd parties should be implemented in this range. -#define EPositionerCustomIpcOffset 0x40000000 - - -enum TPositionIpcId - { - // - // Request IDs - - EPositionServerCancelAsyncRequest = EPositionServerIpcOffset, - EPositionServerConnect, - EPositionServerGetDefaultModuleId, - EPositionServerGetNumModules, - EPositionServerGetModuleInfoByIndex, - EPositionServerGetModuleInfoById, - EPositionServerGetModuleStatus, - EPositionServerNotifyModuleStatusEvent, - - EPositionerCancelAsyncRequest = EPositionerIpcOffset, - EPositionerOpen, - EPositionerOpenModuleId, - EPositionerOpenCriteria, - EPositionerClose, - EPositionerSetSingleRequestor, - EPositionerSetMultipleRequestors, - EPositionerSetUpdateOptions, - EPositionerGetUpdateOptions, - EPositionerGetLastKnownPosition, - EPositionerNotifyPositionUpdate, - - EPositionerCustomCodesBegin = EPositionerCustomIpcOffset, - }; - -#endif // __LBSIPC_HRH__ diff -r 8e58c1bec439 -r a85dbb892d75 layers.sysdef.xml --- a/layers.sysdef.xml Thu Jun 24 11:27:31 2010 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,14 +0,0 @@ - - -]> - - - - - - - - - - \ No newline at end of file diff -r 8e58c1bec439 -r a85dbb892d75 lbstest/lbstestproduct/group/lbs_testproduct.mrp --- a/lbstest/lbstestproduct/group/lbs_testproduct.mrp Thu Jun 24 11:27:31 2010 +0100 +++ b/lbstest/lbstestproduct/group/lbs_testproduct.mrp Thu Jun 24 11:28:34 2010 +0100 @@ -16,14 +16,10 @@ component lbs_testproduct -source \sf\os\lbs\lbstest\lbstestproduct\test_group -source \sf\os\lbs\lbstest\lbstestproduct\internal -source \sf\os\lbs\lbstest\lbstestproduct\tdxml source \sf\os\lbs\lbstest\lbstestproduct -source \sf\os\lbs\lbstest\lbstestproduct\cit -source \sf\os\lbs\lbstest\lbstestproduct\ut + -exports \sf\os\lbs\lbstest\lbstestproduct\group +exports \sf\os\lbs\lbstest\lbstestproduct\test_group notes_source \component_defs\release.src diff -r 8e58c1bec439 -r a85dbb892d75 lbstest/lbstestproduct/lbsbackuprestore/inc/te_lbsbackuprestoresuitedefs.h --- a/lbstest/lbstestproduct/lbsbackuprestore/inc/te_lbsbackuprestoresuitedefs.h Thu Jun 24 11:27:31 2010 +0100 +++ b/lbstest/lbstestproduct/lbsbackuprestore/inc/te_lbsbackuprestoresuitedefs.h Thu Jun 24 11:28:34 2010 +0100 @@ -27,7 +27,7 @@ #define __TE_LBSBACKUPRESTORE_SUITEDEFS_H__ const TUint32 KBackupKey = 0x01234567; -const TUint32 KMetatagBackupAndRestoreValidValue = 0x01000000; +const TUint32 KMetatagBackupAndRestoreValidValue = 0x10000000; const TInt KValidValue = 0x01221122; const TInt KCorruptedValue = 0x01001001; diff -r 8e58c1bec439 -r a85dbb892d75 lbstest/lbstestproduct/lbsbackuprestore/src/checkpsyexiststep.cpp --- a/lbstest/lbstestproduct/lbsbackuprestore/src/checkpsyexiststep.cpp Thu Jun 24 11:27:31 2010 +0100 +++ b/lbstest/lbstestproduct/lbsbackuprestore/src/checkpsyexiststep.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -100,28 +100,36 @@ err = GetIntFromConfig(KPSYList, lineBuf, psyUid); err = idList->Find(TUid::Uid(psyUid)); if(KErrNotFound==err) - { + { INFO_PRINTF2(_L("CCheckPSYExistStep:can't find (%d) in idList "), psyUid); - SetTestStepResult(EFail); - } + SetTestStepResult(EFail); + } CRepository* centrepentry = CRepository::NewL(TUid::Uid(psyUid)); err = centrepentry->Get(brandKey, scarkey); if(KErrNotFound!=err) - { - centrepentry->GetMeta(brandKey, metadataTag); - if(metadataTag == KMetatagBackupAndRestoreValidValue) - { - if(scarkey!=KValidValue) - { - INFO_PRINTF3(_L("scarkey(%d)!=KValidValue(%d)"), scarkey,KValidValue); - SetTestStepResult(EFail); - } - } - } + { + centrepentry->GetMeta(brandKey, metadataTag); + if(metadataTag >= KMetatagBackupAndRestoreValidValue) + { + if(scarkey!=KValidValue) + { + INFO_PRINTF3(_L("scarkey(%d)!=KValidValue(%d)"), scarkey,KValidValue); + SetTestStepResult(EFail); + } + } + } else { - INFO_PRINTF1(_L("CCheckPSYExistStep:centrepentry->Get(brandKey, scarkey) NOT found")); - } + err = centrepentry->Set(brandKey, scarkey); + if(KErrPermissionDenied == err) + { + INFO_PRINTF2(_L("%d is read only"), psyUid); + } + else + { + INFO_PRINTF1(_L("CCheckPSYExistStep:centrepentry->Get(brandKey, scarkey) NOT found")); + } + } } CleanupStack::PopAndDestroy(3, modules); diff -r 8e58c1bec439 -r a85dbb892d75 lbstest/lbstestproduct/lbsclient/group/ctlbsclientportedsuite.mmp --- a/lbstest/lbstestproduct/lbsclient/group/ctlbsclientportedsuite.mmp Thu Jun 24 11:27:31 2010 +0100 +++ b/lbstest/lbstestproduct/lbsclient/group/ctlbsclientportedsuite.mmp Thu Jun 24 11:28:34 2010 +0100 @@ -101,7 +101,6 @@ LIBRARY lbsnetsim.lib LIBRARY cone.lib LIBRARY eikcore.lib -LIBRARY cntmodel.lib LIBRARY estor.lib LIBRARY ecom.lib LIBRARY apgrfx.lib diff -r 8e58c1bec439 -r a85dbb892d75 lbstest/lbstestproduct/tdxml/LbsSuite/LbsPrivacySuite/LbsUnitSuite/te_lbsnetworkprivacySuite/testexecuteservers/te_networkprivacySuite.xml --- a/lbstest/lbstestproduct/tdxml/LbsSuite/LbsPrivacySuite/LbsUnitSuite/te_lbsnetworkprivacySuite/testexecuteservers/te_networkprivacySuite.xml Thu Jun 24 11:27:31 2010 +0100 +++ b/lbstest/lbstestproduct/tdxml/LbsSuite/LbsPrivacySuite/LbsUnitSuite/te_lbsnetworkprivacySuite/testexecuteservers/te_networkprivacySuite.xml Thu Jun 24 11:28:34 2010 +0100 @@ -9,7 +9,7 @@ te_dummynetgateway.exe c:\sys\bin\te_dummynetgateway.exe te_dummynetgateway.mmp - networkprotocolmodules\privacyprotocolmodule\test\te_dummynetgateway\group\BLD.INF + networkprotocolmodules\privacyprotocolmodule\test\te_dummynetgateway\group\bld.inf diff -r 8e58c1bec439 -r a85dbb892d75 lbstest/lbstestproduct/tdxml/LbsSuite/LbsUnitSuite.xml --- a/lbstest/lbstestproduct/tdxml/LbsSuite/LbsUnitSuite.xml Thu Jun 24 11:27:31 2010 +0100 +++ b/lbstest/lbstestproduct/tdxml/LbsSuite/LbsUnitSuite.xml Thu Jun 24 11:28:34 2010 +0100 @@ -31,7 +31,8 @@ te_lbslocationmonitordbsuite te_lbslocationmonitordbsuite2 te_locmonitorsuite - te_lbsnetgatewaySuite + te_geolocmonitorsuite + te_lbsnetgatewaySuite te_testprotocolmodulesuite te_lbsnetsimtestSuite te_lbssupltestmoduleSuite @@ -45,6 +46,7 @@ tsuplasn1suite te_suplproxypmsuite te_npeintegrationmodulesuite + te_lbslocationinfoconvertersuite te_lbspositioningstatussuite @@ -133,8 +135,6 @@ networkpsy2.mmp locationrequestmgmt\locationserver\lbstestpsys\networkpsy2\group\bld.inf - - diff -r 8e58c1bec439 -r a85dbb892d75 lbstest/lbstestproduct/tdxml/LbsSuite/LbsUnitSuite/te_geolocmonitorsuite.xml --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/lbstest/lbstestproduct/tdxml/LbsSuite/LbsUnitSuite/te_geolocmonitorsuite.xml Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,14 @@ + + + + te_geolocmonitorsuite + + + te_geolocmonitortest + + + + te_geolocmonitorsuite + + + \ No newline at end of file diff -r 8e58c1bec439 -r a85dbb892d75 lbstest/lbstestproduct/tdxml/LbsSuite/LbsUnitSuite/te_geolocmonitorsuite/te_geolocmonitortest.xml --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/lbstest/lbstestproduct/tdxml/LbsSuite/LbsUnitSuite/te_geolocmonitorsuite/te_geolocmonitortest.xml Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,26 @@ + + + + + te_geolocmonitortest + 60 + + + + + te_geolocmonitorsuite + + + + locationmgmt\locmonitor\test\te_geolocmonitorsuite\testdata\te_geolocmonitorsuite.ini + c:\testdata\configs\te_geolocmonitorsuite.ini + + + locationmgmt\locmonitor\test\te_geolocmonitorsuite\testdata\lbsgeolocmonunitconfig.txt + c:\testdata\configs\lbsgeolocmonunitconfig.txt + + + diff -r 8e58c1bec439 -r a85dbb892d75 lbstest/lbstestproduct/tdxml/LbsSuite/LbsUnitSuite/te_geolocmonitorsuite/testexecuteservers/te_geolocmonitorsuite.xml --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/lbstest/lbstestproduct/tdxml/LbsSuite/LbsUnitSuite/te_geolocmonitorsuite/testexecuteservers/te_geolocmonitorsuite.xml Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,21 @@ + + + + te_geolocmonitorsuite + + te_geolocmonitorsuite.mmp + locationmgmt\locmonitor\test\te_geolocmonitorsuite\group\bld.inf + + + + examplelocationconverter.dll + c:\system\libs\examplelocationconverter.dll + ExampleLocationConverter.mmp + locationmgmt\locmonitor\test\examplelocationconverter\group\bld.inf + + + \epoc32\data\Z\resource\plugins\ExampleLocationConverter.rsc + c:\resource\plugins\ExampleLocationConverter.rsc + + + diff -r 8e58c1bec439 -r a85dbb892d75 lbstest/lbstestproduct/tdxml/LbsSuite/LbsUnitSuite/te_lbslocationinfoconvertersuite.xml --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/lbstest/lbstestproduct/tdxml/LbsSuite/LbsUnitSuite/te_lbslocationinfoconvertersuite.xml Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,11 @@ + + + te_lbslocationinfoconvertersuite + + te_lbslocationinfoconvertertest + + + te_lbslocationinfoconvertersuite + + + diff -r 8e58c1bec439 -r a85dbb892d75 lbstest/lbstestproduct/tdxml/LbsSuite/LbsUnitSuite/te_lbslocationinfoconvertersuite/te_lbslocationinfoconvertertest.xml --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/lbstest/lbstestproduct/tdxml/LbsSuite/LbsUnitSuite/te_lbslocationinfoconvertersuite/te_lbslocationinfoconvertertest.xml Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,23 @@ + + + + + te_lbslocationinfoconvertertest + 240 + + + + + te_lbslocationinfoconvertersuite + + + + locationmgmt\locmonitor\test\te_lbslocationinforconvertertef\scripts\LbsLocationInfoConverter.ini + c:\testdata\configs\lbslocationinfoconverter.ini + + + + diff -r 8e58c1bec439 -r a85dbb892d75 lbstest/lbstestproduct/tdxml/LbsSuite/LbsUnitSuite/te_lbslocationinfoconvertersuite/testexecuteservers/te_lbslocationinfoconvertersuite.xml --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/lbstest/lbstestproduct/tdxml/LbsSuite/LbsUnitSuite/te_lbslocationinfoconvertersuite/testexecuteservers/te_lbslocationinfoconvertersuite.xml Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,57 @@ + + + te_lbslocationinfoconvertersuite + te_lbslocationinfoconverter.mmp + locationmgmt\locmonitor\test\te_lbslocationinforconvertertef\group\bld.inf + + + + examplelocationconverter.dll + c:\system\libs\examplelocationconverter.dll + ExampleLocationConverter.mmp + locationmgmt\locmonitor\test\examplelocationconverter\group\bld.inf + + + TestLocationConverter.dll + c:\system\libs\TestLocationConverter.dll + TestLocationConverter.dll + locationmgmt\locmonitor\test\TestLocationConverter\group\bld.inf + + + TestLocationConverter2.dll + c:\system\libs\TestLocationConverter2.dll + TestLocationConverter2.dll + locationmgmt\locmonitor\test\TestLocationConverter2\group\bld.inf + + + TestLocationConverter3.dll + c:\system\libs\TestLocationConverter3.dll + TestLocationConverter3.dll + locationmgmt\locmonitor\test\TestLocationConverter3\group\bld.inf + + + \epoc32\data\Z\resource\plugins\ExampleLocationConverter.rsc + c:\resource\plugins\ExampleLocationConverter.rsc + + + \epoc32\data\Z\resource\plugins\TestLocationConverter.rsc + c:\resource\plugins\TestLocationConverter.rsc + + + + \epoc32\data\Z\resource\plugins\TestLocationConverter2.rsc + c:\resource\plugins\TestLocationConverter2.rsc + + + + \epoc32\data\Z\resource\plugins\TestLocationConverter3.rsc + c:\resource\plugins\TestLocationConverter3.rsc + + + locationmgmt\locmonitor\test\te_geolocmonitorsuite\testdata\lbsgeolocmonunitconfig.txt + c:\testdata\configs\lbsgeolocmonunitconfig.txt + + + + + diff -r 8e58c1bec439 -r a85dbb892d75 lbstest/lbstestproduct/ut/lbsgpsdatasourcemodules/lbslocbtgpspsy/te_lbsbtgpspsy/group/te_lbsbtgpspsy.mmp --- a/lbstest/lbstestproduct/ut/lbsgpsdatasourcemodules/lbslocbtgpspsy/te_lbsbtgpspsy/group/te_lbsbtgpspsy.mmp Thu Jun 24 11:27:31 2010 +0100 +++ b/lbstest/lbstestproduct/ut/lbsgpsdatasourcemodules/lbslocbtgpspsy/te_lbsbtgpspsy/group/te_lbsbtgpspsy.mmp Thu Jun 24 11:28:34 2010 +0100 @@ -67,7 +67,6 @@ LIBRARY efsrv.lib // File server LIBRARY lbs.lib // Location acquisition API -LIBRARY cntmodel.lib // contact db LIBRARY btextnotifiers.lib LIBRARY btdevice.lib diff -r 8e58c1bec439 -r a85dbb892d75 lbstest/lbstestproduct/ut/lbsgpsdatasourcemodules/lbslocbtgpspsy/te_lbsbtgpspsy/src/LcfCommonProcedures.cpp --- a/lbstest/lbstestproduct/ut/lbsgpsdatasourcemodules/lbslocbtgpspsy/te_lbsbtgpspsy/src/LcfCommonProcedures.cpp Thu Jun 24 11:27:31 2010 +0100 +++ b/lbstest/lbstestproduct/ut/lbsgpsdatasourcemodules/lbslocbtgpspsy/te_lbsbtgpspsy/src/LcfCommonProcedures.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -139,7 +139,7 @@ TInt tmp; - RHeap heap = User::Heap(); + RHeap& heap = User::Heap(); if (!heap.Base()) { diff -r 8e58c1bec439 -r a85dbb892d75 lbstest/locationprotocoltest/group/BLD.INF --- a/lbstest/locationprotocoltest/group/BLD.INF Thu Jun 24 11:27:31 2010 +0100 +++ b/lbstest/locationprotocoltest/group/BLD.INF Thu Jun 24 11:28:34 2010 +0100 @@ -15,7 +15,7 @@ // Main projects, in build order #include "../../../networkprotocolmodules/networkprotocolmodule/LbsAssistanceDataSourceInterface/group/bld.inf" -#include "../../../networkprotocolmodules/networkprotocolmodule/LbsNetSim/group/BLD.INF" +#include "../../../networkprotocolmodules/networkprotocolmodule/LbsNetSim/group/bld.inf" #include "../../../networkprotocolmodules/networkprotocolmodule/LbsProtocolModule/group/bld.inf" #include "../../../networkprotocolmodules/networkprotocolmodule/suplasn1/group/bld.inf" #include "../../../networkprotocolmodules/networkprotocolmodule/LbsSuplTestProtocol/group/bld.inf" diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locationcore/GPSClock/group/BLD.INF --- a/locationmgmt/locationcore/GPSClock/group/BLD.INF Thu Jun 24 11:27:31 2010 +0100 +++ b/locationmgmt/locationcore/GPSClock/group/BLD.INF Thu Jun 24 11:28:34 2010 +0100 @@ -13,4 +13,4 @@ // Description: // -#include "../GpsSetClock/group/BLD.INF" +#include "../GpsSetClock/group/bld.inf" diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locationcore/LbsADataCache/group/BLD.INF --- a/locationmgmt/locationcore/LbsADataCache/group/BLD.INF Thu Jun 24 11:27:31 2010 +0100 +++ b/locationmgmt/locationcore/LbsADataCache/group/BLD.INF Thu Jun 24 11:28:34 2010 +0100 @@ -24,4 +24,4 @@ lbsadatacache.mmp PRJ_TESTMMPFILES -#include "../test/group/BLD.INF" +#include "../test/group/bld.inf" diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locationcore/LbsClient/LbsApi/group/BLD.INF --- a/locationmgmt/locationcore/LbsClient/LbsApi/group/BLD.INF Thu Jun 24 11:27:31 2010 +0100 +++ b/locationmgmt/locationcore/LbsClient/LbsApi/group/BLD.INF Thu Jun 24 11:28:34 2010 +0100 @@ -38,7 +38,6 @@ ../inc/lbs.inl SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(lbs.inl) ../inc/LbsPositionCalc.h SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(lbspositioncalc.h) ../inc/LbsGpsMeasurement.h SYMBIAN_OS_LAYER_PLATFORM_EXPORT_PATH(lbs/lbsgpsmeasurement.h) -../inc/lbsvariant.h SYMBIAN_OS_LAYER_PLATFORM_EXPORT_PATH(lbsvariant.h) ../inc/LbsAreaInfo.h SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(lbsareainfo.h) PRJ_MMPFILES diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locationcore/LbsClient/LbsApi/inc/LbsCommon.h --- a/locationmgmt/locationcore/LbsClient/LbsApi/inc/LbsCommon.h Thu Jun 24 11:27:31 2010 +0100 +++ b/locationmgmt/locationcore/LbsClient/LbsApi/inc/LbsCommon.h Thu Jun 24 11:28:34 2010 +0100 @@ -21,7 +21,6 @@ #include #include #include -#include /** @publishedAll @@ -40,9 +39,8 @@ @released Maximum characters in module name. -If __S60_ is defined in lbsvariant.h the constant is 64 otherwise it is 20 */ -const TInt KPositionMaxModuleName = __LBS_MAX_MODULE_NAME; +const TInt KPositionMaxModuleName = 64; /** @publishedAll diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locationcore/LbsClient/LbsApi/inc/LbsErrors.h --- a/locationmgmt/locationcore/LbsClient/LbsApi/inc/LbsErrors.h Thu Jun 24 11:27:31 2010 +0100 +++ b/locationmgmt/locationcore/LbsClient/LbsApi/inc/LbsErrors.h Thu Jun 24 11:28:34 2010 +0100 @@ -17,7 +17,6 @@ #define __LBSERRORS_H__ #include -#include /** LBS Panic string @@ -133,7 +132,7 @@ If __S60_ is defined in lbsvariant.h the constant is -30371 otherwise it is -17350 */ -const TInt KPositionErrBase = __LBS_TDEFAULT_ERROR_BASE; +const TInt KPositionErrBase = -30371; /** BufferOverflow error diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locationcore/LbsClient/LbsApi/inc/LbsPosition.h --- a/locationmgmt/locationcore/LbsClient/LbsApi/inc/LbsPosition.h Thu Jun 24 11:27:31 2010 +0100 +++ b/locationmgmt/locationcore/LbsClient/LbsApi/inc/LbsPosition.h Thu Jun 24 11:28:34 2010 +0100 @@ -17,7 +17,6 @@ #define __LBSPOSITION_H__ #include -#include /** @publishedAll diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locationcore/LbsClient/LbsApi/inc/lbsvariant.h --- a/locationmgmt/locationcore/LbsClient/LbsApi/inc/lbsvariant.h Thu Jun 24 11:27:31 2010 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,28 +0,0 @@ -// Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies). -// All rights reserved. -// This component and the accompanying materials are made available -// under the terms of "Eclipse Public License v1.0" -// which accompanies this distribution, and is available -// at the URL "http://www.eclipse.org/legal/epl-v10.html". -// -// Initial Contributors: -// Nokia Corporation - initial contribution. -// -// Contributors: -// -// Description: -// - -#ifndef __LBSVARIANT_H__ -#define __LBSVARIANT_H__ - -/** -@file -@internalTechnology -@prototype -*/ -#define __LBS_TDEFAULT_ERROR_BASE (-30371) -#define __LBS_TCOURSE_RESERVED_SIZE 16 -#define __LBS_MAX_MODULE_NAME 64 - -#endif //__LBSVARIANT_H__ diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locationcore/LbsClient/LbsApi/src/LbsPositionInfo.cpp --- a/locationmgmt/locationcore/LbsClient/LbsApi/src/LbsPositionInfo.cpp Thu Jun 24 11:27:31 2010 +0100 +++ b/locationmgmt/locationcore/LbsClient/LbsApi/src/LbsPositionInfo.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -19,6 +19,12 @@ #include "LbsInternal.h" #include "lbsfieldindex.h" +// Fix for GCCE 4.x : bug #1708 - GCC-E compilation error in lbs +#if defined(_FOFF) +#undef _FOFF +#endif // defined(_FOFF) +#define _FOFF(c,f) (((TInt)&(((c *)0x1000)->f))-0x1000) +// End of fix for GCCE 4.x //------------------------------------------------------------------------------ // TPositionInfoBase diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locationcore/LbsClient/LbsApi/src/lbsfields.cpp --- a/locationmgmt/locationcore/LbsClient/LbsApi/src/lbsfields.cpp Thu Jun 24 11:27:31 2010 +0100 +++ b/locationmgmt/locationcore/LbsClient/LbsApi/src/lbsfields.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -23,6 +23,14 @@ #define __ASSERT_ALIGNED_2BYTE(aPtr) __ASSERT_DEBUG(!(TUint(aPtr)&1),User::Panic(KPositionInternalFault, EBadAlignment)) #define __ASSERT_ALIGNED_4BYTE(aPtr) __ASSERT_DEBUG(!(TUint(aPtr)&3),User::Panic(KPositionInternalFault, EBadAlignment)) + +// Fix for GCCE 4.x : bug #1708 - GCC-E compilation error in lbs +#if defined(_FOFF) +#undef _FOFF +#endif // defined(_FOFF) +#define _FOFF(c,f) (((TInt)&(((c *)0x1000)->f))-0x1000) +// End of fix for GCCE 4.x + #define __DATA_OFFSET_INTO_HPOS(aOffset) \ (_FOFF(HPositionGenericInfo, iBuffer[(aOffset+iInfo.iDataStartPoint)])) @@ -75,13 +83,13 @@ case PositionFieldManager::ETDesC16: { const TUint8* address = &(iInfo.iBuffer[fieldIndex.FieldStartPos()]); - TUint lengthOfString = reinterpret_cast(address)->iLength; + const TUint lengthOfString = reinterpret_cast(address)->iLength; return _FOFF(SPackedTDesC16, iBuf[lengthOfString]); } case PositionFieldManager::ETDesC8: { const TUint8* address = &(iInfo.iBuffer[fieldIndex.FieldStartPos()]); - TUint lengthOfString = reinterpret_cast(address)->iLength; + const TUint lengthOfString = reinterpret_cast(address)->iLength; return _FOFF(SPackedTDesC8, iBuf[lengthOfString]); } default: @@ -861,7 +869,7 @@ const TDesC16& aValue, HPositionGenericInfo& aInfo) { - const TDataWrapperC wrapper(ETDesC16, _FOFF(SPackedTDesC16, iBuf[aValue.Length()]), &aValue, CopyFromTDesC16); + const TDataWrapperC wrapper(ETDesC16, (_FOFF(SPackedTDesC16, iBuf[aValue.Length()])), &aValue, CopyFromTDesC16); TPositionFieldSetter fieldSetter(aInfo); return fieldSetter.DoSetValue(aFieldId, wrapper); } diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locationcore/LbsClient/group/BLD.INF --- a/locationmgmt/locationcore/LbsClient/group/BLD.INF Thu Jun 24 11:27:31 2010 +0100 +++ b/locationmgmt/locationcore/LbsClient/group/BLD.INF Thu Jun 24 11:28:34 2010 +0100 @@ -14,5 +14,5 @@ // // Main projects, in build order -#include "../LbsApi/group/BLD.INF" +#include "../LbsApi/group/bld.inf" diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locationcore/LbsNetInternalApi/group/BLD.INF --- a/locationmgmt/locationcore/LbsNetInternalApi/group/BLD.INF Thu Jun 24 11:27:31 2010 +0100 +++ b/locationmgmt/locationcore/LbsNetInternalApi/group/BLD.INF Thu Jun 24 11:28:34 2010 +0100 @@ -24,5 +24,5 @@ PRJ_TESTMMPFILES -#include "../test/group/BLD.INF" +#include "../test/group/bld.inf" diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locationcore/LbsNetRegStatusInt/group/BLD.INF --- a/locationmgmt/locationcore/LbsNetRegStatusInt/group/BLD.INF Thu Jun 24 11:27:31 2010 +0100 +++ b/locationmgmt/locationcore/LbsNetRegStatusInt/group/BLD.INF Thu Jun 24 11:28:34 2010 +0100 @@ -24,4 +24,4 @@ lbsnetregstatusint.mmp PRJ_TESTMMPFILES -#include "../test/group/BLD.INF" +#include "../test/group/bld.inf" diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locationcore/LbsRefFnpInt/group/BLD.INF --- a/locationmgmt/locationcore/LbsRefFnpInt/group/BLD.INF Thu Jun 24 11:27:31 2010 +0100 +++ b/locationmgmt/locationcore/LbsRefFnpInt/group/BLD.INF Thu Jun 24 11:28:34 2010 +0100 @@ -25,5 +25,5 @@ PRJ_TESTMMPFILES -#include "../test/group/BLD.INF" +#include "../test/group/bld.inf" diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locationcore/group/bld.inf --- a/locationmgmt/locationcore/group/bld.inf Thu Jun 24 11:27:31 2010 +0100 +++ b/locationmgmt/locationcore/group/bld.inf Thu Jun 24 11:28:34 2010 +0100 @@ -14,36 +14,35 @@ // // Common admin projects -#include "../LbsCommonInternalDataTypes/group/BLD.INF" -#include "../LbsLocCommon/group/BLD.INF" -#include "../LbsInternalApi/group/BLD.INF" -#include "../LbsClient/group/BLD.INF" +#include "../LbsCommonInternalDataTypes/group/bld.inf" +#include "../LbsLocCommon/group/bld.inf" +#include "../LbsInternalApi/group/bld.inf" +#include "../LbsClient/group/bld.inf" #include "../LbsLogging/group/bld.inf" -#include "../LbsAssistanceData/group/BLD.INF" +#include "../LbsAssistanceData/group/bld.inf" #include "../LbsPartnerCommon/group/bld.inf" #include "../LbsLocDataSource/group/bld.inf" -#include "../GPSClock/group/BLD.INF" -#include "../LbsNetProtocol/group/BLD.INF" -#include "../LbsNetRegStatusInt/group/BLD.INF" -#include "../LbsNgNlmInt/group/BLD.INF" -#include "../LbsNrhNgMsgs/group/BLD.INF" -#include "../LbsRefFnpInt/group/BLD.INF" -#include "../LbsNetInternalApi/group/BLD.INF" -#include "../LbsADataCache/group/BLD.INF" -#include "../LbsAgpsNgMsgs/group/BLD.INF" -#include "../LbsPsyNgMsgs/group/BLD.INF" +#include "../GPSClock/group/bld.inf" +#include "../LbsNetProtocol/group/bld.inf" +#include "../LbsNetRegStatusInt/group/bld.inf" +#include "../LbsNgNlmInt/group/bld.inf" +#include "../LbsNrhNgMsgs/group/bld.inf" +#include "../LbsRefFnpInt/group/bld.inf" +#include "../LbsNetInternalApi/group/bld.inf" +#include "../LbsADataCache/group/bld.inf" +#include "../LbsAgpsNgMsgs/group/bld.inf" +#include "../LbsPsyNgMsgs/group/bld.inf" -#include "../lbsrootapi/group/BLD.INF" -#include "../lbsroot/group/BLD.INF" +#include "../lbsrootapi/group/bld.inf" +#include "../lbsroot/group/bld.inf" #include "../LbsDebug/group/bld.inf" #include "../LbsClient/lastknownlocapi/group/bld.inf" #include "../lbslocsettings/group/bld.inf" #include "../lbsmlfwutilities/group/bld.inf" #include "../lbslocindicatorlib/group/bld.inf" -#include "../../locmonitor/lbslocmonitorclient/group/bld.inf" +#include "../../locmonitor/lbslocmonitorapis/group/bld.inf" #include "../LbsRefLocDataSource/group/bld.inf" - #include "../lbspositioningstatus/group/bld.inf" @@ -53,7 +52,7 @@ PRJ_EXPORTS //HEADERS ../inc/LbsLocErrors.h SYMBIAN_OS_LAYER_PLATFORM_EXPORT_PATH(lbs/lbslocerrors.h) -../inc/lbsmessageenums.h SYMBIAN_OS_LAYER_PLATFORM_EXPORT_PATH(lbsmessageenums.h) +../inc/lbsmessageenums.h SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(lbsmessageenums.h) ../inc/lbsadmin.h SYMBIAN_OS_LAYER_PLATFORM_EXPORT_PATH(lbs/lbsadmin.h) ../inc/lbsadmin.inl SYMBIAN_OS_LAYER_PLATFORM_EXPORT_PATH(lbs/lbsadmin.inl) ../inc/lbsadminclasstypes.h SYMBIAN_OS_LAYER_PLATFORM_EXPORT_PATH(lbsadminclasstypes.h) diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locationcore/group/lbs_admin.mrp --- a/locationmgmt/locationcore/group/lbs_admin.mrp Thu Jun 24 11:27:31 2010 +0100 +++ b/locationmgmt/locationcore/group/lbs_admin.mrp Thu Jun 24 11:28:34 2010 +0100 @@ -30,7 +30,7 @@ source \sf\os\lbs\locationmgmt\locationcore\lbsrootapi source \sf\os\lbs\locationmgmt\locationcore\lbsroot source \sf\os\lbs\locationmgmt\locationcore\LbsDebug -source \sf\os\lbs\locationmgmt\locmonitor\lbslocmonitorclient +source \sf\os\lbs\locationmgmt\locmonitor\lbslocmonitorapis source \sf\os\lbs\locationmgmt\locationcore source \sf\os\lbs\locationmgmt\locationcore\lbslocsettings diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locationcore/group/lbsadmin.iby --- a/locationmgmt/locationcore/group/lbsadmin.iby Thu Jun 24 11:27:31 2010 +0100 +++ b/locationmgmt/locationcore/group/lbsadmin.iby Thu Jun 24 11:28:34 2010 +0100 @@ -22,7 +22,10 @@ file=ABI_DIR\DEBUG_DIR\lbsadmin.dll System\libs\lbsadmin.dll #include "lbsassistancedata.iby" +#include "lbslocationinfodatatypes.iby" #include "lbslocmonclient.iby" +#include "lbslocationinfoconverter.iby" +#include "lbslocationinfoconverterplugin.iby" #include "lbsloccommon.iby" #include "LbsLocDataSource.iby" #include "lbsinternalapi.iby" diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locationcore/inc/LbsLocErrors.h --- a/locationmgmt/locationcore/inc/LbsLocErrors.h Thu Jun 24 11:27:31 2010 +0100 +++ b/locationmgmt/locationcore/inc/LbsLocErrors.h Thu Jun 24 11:28:34 2010 +0100 @@ -208,5 +208,27 @@ longer supported by an extended version of the interface.*/ ENetProtocolApiExtendedInterfaceMisuse = 0, }; + +//------------------------------------------------------------------------------- +// Location monitor server +//------------------------------------------------------------------------------- +/** +Panic string for the Location monitor client API +@publishedPartner +@released +*/ +_LIT(KLocationMonitorFault,"LocationMonitorClient"); +/** +Panic codes for the Location monitor client API +@publishedPartner +@released +*/ +enum TLocationMonitorClientPanic + { + /** + * A client has called an asynchronous request while it is still outstanding. + */ + ELocMonitorDuplicateRequest = 0, + }; #endif // LBSLOCERRORS_H diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locationcore/inc/lbsmessageenums.h --- a/locationmgmt/locationcore/inc/lbsmessageenums.h Thu Jun 24 11:27:31 2010 +0100 +++ b/locationmgmt/locationcore/inc/lbsmessageenums.h Thu Jun 24 11:28:34 2010 +0100 @@ -12,14 +12,13 @@ // // Description: // the message enums/opcodes shared between the client and the server sides -// Extend the enum list as required for each server - see restrictions -// butDO NOT rename the file -// +// +// NOTE: This file should not be modified or used by any new applications // /** @file - @publishedPartner + @publishedAll @released */ diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locationcore/lbspositioningstatus/test/te_lbspositioningstatus/group/bld.inf --- a/locationmgmt/locationcore/lbspositioningstatus/test/te_lbspositioningstatus/group/bld.inf Thu Jun 24 11:27:31 2010 +0100 +++ b/locationmgmt/locationcore/lbspositioningstatus/test/te_lbspositioningstatus/group/bld.inf Thu Jun 24 11:28:34 2010 +0100 @@ -1,4 +1,4 @@ -// Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +// Copyright (c) 2010 Nokia Corporation and/or its subsidiary(-ies). // All rights reserved. // This component and the accompanying materials are made available // under the terms of "Eclipse Public License v1.0" diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locationcore/lbspositioningstatus/test/te_lbspositioningstatus/inc/te_lbspositioningstatusserver.h --- a/locationmgmt/locationcore/lbspositioningstatus/test/te_lbspositioningstatus/inc/te_lbspositioningstatusserver.h Thu Jun 24 11:27:31 2010 +0100 +++ b/locationmgmt/locationcore/lbspositioningstatus/test/te_lbspositioningstatus/inc/te_lbspositioningstatusserver.h Thu Jun 24 11:28:34 2010 +0100 @@ -24,7 +24,7 @@ #ifndef TE_LBSPOSITIONINGSTATUSSERVER_H #define TE_LBSPOSITIONINGSTATUSSERVER_H -#include +#include class CTe_LbsPositioningStatusServer : public CTestServer diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locationcore/lbspositioningstatus/test/te_lbspositioningstatus/inc/te_lbspositioningstatusstep.h --- a/locationmgmt/locationcore/lbspositioningstatus/test/te_lbspositioningstatus/inc/te_lbspositioningstatusstep.h Thu Jun 24 11:27:31 2010 +0100 +++ b/locationmgmt/locationcore/lbspositioningstatus/test/te_lbspositioningstatus/inc/te_lbspositioningstatusstep.h Thu Jun 24 11:28:34 2010 +0100 @@ -22,7 +22,7 @@ #ifndef TE_LBSPOSITIONINGSTATUSSTEPBASE_H #define TE_LBSPOSITIONINGSTATUSSTEPBASE_H -#include +#include _LIT(KStatusStep,"StatusStep"); diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locationcore/lbspositioningstatus/test/te_lbspositioningstatus/scripts/te_lbspositioningstatus.script --- a/locationmgmt/locationcore/lbspositioningstatus/test/te_lbspositioningstatus/scripts/te_lbspositioningstatus.script Thu Jun 24 11:27:31 2010 +0100 +++ b/locationmgmt/locationcore/lbspositioningstatus/test/te_lbspositioningstatus/scripts/te_lbspositioningstatus.script Thu Jun 24 11:28:34 2010 +0100 @@ -1,5 +1,5 @@ // -// Copyright (c) 2010 Nokia Corporation and/or its subsidiary(-ies). +// Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). // All rights reserved. // This component and the accompanying materials are made available // under the terms of "Eclipse Public License v1.0" diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locationcore/lbspositioningstatus/test/te_lbspositioningstatus/src/te_lbspositioningstatusserver.cpp --- a/locationmgmt/locationcore/lbspositioningstatus/test/te_lbspositioningstatus/src/te_lbspositioningstatusserver.cpp Thu Jun 24 11:27:31 2010 +0100 +++ b/locationmgmt/locationcore/lbspositioningstatus/test/te_lbspositioningstatus/src/te_lbspositioningstatusserver.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -1,4 +1,4 @@ -// Copyright (c) 2010 Nokia Corporation and/or its subsidiary(-ies). +// Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). // All rights reserved. // This component and the accompanying materials are made available // under the terms of "Eclipse Public License v1.0" @@ -11,7 +11,7 @@ // Contributors: // // Description: -// +// // /** diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locationcore/lbspositioningstatus/test/te_lbspositioningstatus/src/te_lbsstatustestmanager.cpp --- a/locationmgmt/locationcore/lbspositioningstatus/test/te_lbspositioningstatus/src/te_lbsstatustestmanager.cpp Thu Jun 24 11:27:31 2010 +0100 +++ b/locationmgmt/locationcore/lbspositioningstatus/test/te_lbspositioningstatus/src/te_lbsstatustestmanager.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -1,4 +1,4 @@ -// Copyright (c) 2010 Nokia Corporation and/or its subsidiary(-ies). +// Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). // All rights reserved. // This component and the accompanying materials are made available // under the terms of "Eclipse Public License v1.0" diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/CommonClientServerApi/bwins/lbslocmonclient.def --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/CommonClientServerApi/bwins/lbslocmonclient.def Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,31 @@ +EXPORTS + ?OpenL@RLbsLocMonitorAreaPositioner@@QAEXAAVRLbsLocMonitorSession@@@Z @ 1 NONAME ; void RLbsLocMonitorAreaPositioner::OpenL(class RLbsLocMonitorSession &) + ?ConstructL@RLbsLocMonitorAreaPositioner@@MAEXXZ @ 2 NONAME ; void RLbsLocMonitorAreaPositioner::ConstructL(void) + ?ConvertLocationInfoL@RLbsLocInfoConverter@@QAEXAAV?$RPointerArray@VCLbsLocationInfoBase@@@@KKVTUid@@AAVTRequestStatus@@@Z @ 3 NONAME ; void RLbsLocInfoConverter::ConvertLocationInfoL(class RPointerArray &, unsigned long, unsigned long, class TUid, class TRequestStatus &) + ?ConstructL@CLbsLocMonitorPtrHolder@@IAEXHH@Z @ 4 NONAME ; void CLbsLocMonitorPtrHolder::ConstructL(int, int) + ?PtrC@CLbsLocMonitorPtrHolder@@QAEAAVTPtrC8@@H@Z @ 5 NONAME ; class TPtrC8 & CLbsLocMonitorPtrHolder::PtrC(int) + ?CancelDatabaseWipeOut@RLbsLocMonitorSession@@QBEHXZ @ 6 NONAME ; int RLbsLocMonitorSession::CancelDatabaseWipeOut(void) const + ?Ptr@CLbsLocMonitorPtrHolder@@QAEAAVTPtr8@@H@Z @ 7 NONAME ; class TPtr8 & CLbsLocMonitorPtrHolder::Ptr(int) + ?GetLastKnownPosition@RLbsLocMonitorAreaPositioner@@QBEXAAVTPositionInfoBase@@AAVTRequestStatus@@@Z @ 8 NONAME ; void RLbsLocMonitorAreaPositioner::GetLastKnownPosition(class TPositionInfoBase &, class TRequestStatus &) const + ?Close@RLbsLocMonitorSession@@UAEXXZ @ 9 NONAME ; void RLbsLocMonitorSession::Close(void) + ?Destruct@RLbsLocMonitorAreaPositioner@@MAEXXZ @ 10 NONAME ; void RLbsLocMonitorAreaPositioner::Destruct(void) + ?OpenL@RLbsLocInfoConverter@@QAEXAAVRLbsLocMonitorSession@@@Z @ 11 NONAME ; void RLbsLocInfoConverter::OpenL(class RLbsLocMonitorSession &) + ?GetLastKnownPositionArea@RLbsLocMonitorAreaPositioner@@QBEXAAVTPositionInfoBase@@AAVTPositionAreaInfoBase@@AAVTPosAreaReqParams@@AAVTRequestStatus@@@Z @ 12 NONAME ; void RLbsLocMonitorAreaPositioner::GetLastKnownPositionArea(class TPositionInfoBase &, class TPositionAreaInfoBase &, class TPosAreaReqParams &, class TRequestStatus &) const + ?CancelGetLastKnownPositionArea@RLbsLocMonitorAreaPositioner@@QBEHXZ @ 13 NONAME ; int RLbsLocMonitorAreaPositioner::CancelGetLastKnownPositionArea(void) const + ?CancelConvertLocationInfo@RLbsLocInfoConverter@@QAEXXZ @ 14 NONAME ; void RLbsLocInfoConverter::CancelConvertLocationInfo(void) + ?Close@RLbsLocInfoConverter@@UAEXXZ @ 15 NONAME ; void RLbsLocInfoConverter::Close(void) + ?NewL@CLbsLocMonitorPtrHolder@@SAPAV1@HH@Z @ 16 NONAME ; class CLbsLocMonitorPtrHolder * CLbsLocMonitorPtrHolder::NewL(int, int) + ??0RLbsLocMonitorAreaPositioner@@QAE@XZ @ 17 NONAME ; RLbsLocMonitorAreaPositioner::RLbsLocMonitorAreaPositioner(void) + ?CancelGetLastKnownPosition@RLbsLocMonitorAreaPositioner@@QBEHXZ @ 18 NONAME ; int RLbsLocMonitorAreaPositioner::CancelGetLastKnownPosition(void) const + ??0RLbsLocMonitorSession@@QAE@XZ @ 19 NONAME ; RLbsLocMonitorSession::RLbsLocMonitorSession(void) + ?WipeOutDatabase@RLbsLocMonitorSession@@QBEXAAVTRequestStatus@@@Z @ 20 NONAME ; void RLbsLocMonitorSession::WipeOutDatabase(class TRequestStatus &) const + ?ConstructL@RLbsLocInfoConverter@@AAEXXZ @ 21 NONAME ; void RLbsLocInfoConverter::ConstructL(void) + ?ConvertLocationInfoL@RLbsLocInfoConverter@@QAEXAAVCLbsLocationInfoBase@@KABKVTUid@@AAVTRequestStatus@@@Z @ 22 NONAME ; void RLbsLocInfoConverter::ConvertLocationInfoL(class CLbsLocationInfoBase &, unsigned long, unsigned long const &, class TUid, class TRequestStatus &) + ?Close@RLbsLocMonitorAreaPositioner@@UAEXXZ @ 23 NONAME ; void RLbsLocMonitorAreaPositioner::Close(void) + ??1CLbsLocMonitorPtrHolder@@UAE@XZ @ 24 NONAME ; CLbsLocMonitorPtrHolder::~CLbsLocMonitorPtrHolder(void) + ?Version@RLbsLocMonitorSession@@UAE?AVTVersion@@XZ @ 25 NONAME ; class TVersion RLbsLocMonitorSession::Version(void) + ?Connect@RLbsLocMonitorSession@@QAEHXZ @ 26 NONAME ; int RLbsLocMonitorSession::Connect(void) + ?SetLastKnownPosition@RLbsLocMonitorAreaPositioner@@QBEHABVTPositionInfoBase@@@Z @ 27 NONAME ; int RLbsLocMonitorAreaPositioner::SetLastKnownPosition(class TPositionInfoBase const &) const + ??1RLbsLocInfoConverter@@QAE@XZ @ 28 NONAME ; RLbsLocInfoConverter::~RLbsLocInfoConverter(void) + ??0RLbsLocInfoConverter@@QAE@XZ @ 29 NONAME ; RLbsLocInfoConverter::RLbsLocInfoConverter(void) + diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/CommonClientServerApi/eabi/lbslocmonclient.def --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/CommonClientServerApi/eabi/lbslocmonclient.def Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,47 @@ +EXPORTS + _ZN20RLbsLocInfoConverter10ConstructLEv @ 1 NONAME + _ZN20RLbsLocInfoConverter20ConvertLocationInfoLER13RPointerArrayI20CLbsLocationInfoBaseEmm4TUidR14TRequestStatus @ 2 NONAME + _ZN20RLbsLocInfoConverter20ConvertLocationInfoLER20CLbsLocationInfoBasemRKm4TUidR14TRequestStatus @ 3 NONAME + _ZN20RLbsLocInfoConverter25CancelConvertLocationInfoEv @ 4 NONAME + _ZN20RLbsLocInfoConverter5CloseEv @ 5 NONAME + _ZN20RLbsLocInfoConverter5OpenLER21RLbsLocMonitorSession @ 6 NONAME + _ZN20RLbsLocInfoConverterC1Ev @ 7 NONAME + _ZN20RLbsLocInfoConverterC2Ev @ 8 NONAME + _ZN20RLbsLocInfoConverterD1Ev @ 9 NONAME + _ZN20RLbsLocInfoConverterD2Ev @ 10 NONAME + _ZN21RLbsLocMonitorSession5CloseEv @ 11 NONAME + _ZN21RLbsLocMonitorSession7ConnectEv @ 12 NONAME + _ZN21RLbsLocMonitorSession7VersionEv @ 13 NONAME + _ZN21RLbsLocMonitorSessionC1Ev @ 14 NONAME + _ZN21RLbsLocMonitorSessionC2Ev @ 15 NONAME + _ZN23CLbsLocMonitorPtrHolder10ConstructLEii @ 16 NONAME + _ZN23CLbsLocMonitorPtrHolder3PtrEi @ 17 NONAME + _ZN23CLbsLocMonitorPtrHolder4NewLEii @ 18 NONAME + _ZN23CLbsLocMonitorPtrHolder4PtrCEi @ 19 NONAME + _ZN23CLbsLocMonitorPtrHolderD0Ev @ 20 NONAME + _ZN23CLbsLocMonitorPtrHolderD1Ev @ 21 NONAME + _ZN23CLbsLocMonitorPtrHolderD2Ev @ 22 NONAME + _ZN28RLbsLocMonitorAreaPositioner10ConstructLEv @ 23 NONAME + _ZN28RLbsLocMonitorAreaPositioner5CloseEv @ 24 NONAME + _ZN28RLbsLocMonitorAreaPositioner5OpenLER21RLbsLocMonitorSession @ 25 NONAME + _ZN28RLbsLocMonitorAreaPositioner8DestructEv @ 26 NONAME + _ZN28RLbsLocMonitorAreaPositionerC1Ev @ 27 NONAME + _ZN28RLbsLocMonitorAreaPositionerC2Ev @ 28 NONAME + _ZNK21RLbsLocMonitorSession15WipeOutDatabaseER14TRequestStatus @ 29 NONAME + _ZNK21RLbsLocMonitorSession21CancelDatabaseWipeOutEv @ 30 NONAME + _ZNK28RLbsLocMonitorAreaPositioner20GetLastKnownPositionER17TPositionInfoBaseR14TRequestStatus @ 31 NONAME + _ZNK28RLbsLocMonitorAreaPositioner20SetLastKnownPositionERK17TPositionInfoBase @ 32 NONAME + _ZNK28RLbsLocMonitorAreaPositioner24GetLastKnownPositionAreaER17TPositionInfoBaseR21TPositionAreaInfoBaseR17TPosAreaReqParamsR14TRequestStatus @ 33 NONAME + _ZNK28RLbsLocMonitorAreaPositioner26CancelGetLastKnownPositionEv @ 34 NONAME + _ZNK28RLbsLocMonitorAreaPositioner30CancelGetLastKnownPositionAreaEv @ 35 NONAME + _ZTI20RLbsLocInfoConverter @ 36 NONAME + _ZTI21RLbsLocMonitorSession @ 37 NONAME + _ZTI23CLbsLocMonitorPtrHolder @ 38 NONAME + _ZTI28CLbsLocInfoConversionHandler @ 39 NONAME + _ZTI28RLbsLocMonitorAreaPositioner @ 40 NONAME + _ZTV20RLbsLocInfoConverter @ 41 NONAME + _ZTV21RLbsLocMonitorSession @ 42 NONAME + _ZTV23CLbsLocMonitorPtrHolder @ 43 NONAME + _ZTV28CLbsLocInfoConversionHandler @ 44 NONAME + _ZTV28RLbsLocMonitorAreaPositioner @ 45 NONAME + diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/CommonClientServerApi/group/bld.inf --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/CommonClientServerApi/group/bld.inf Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,23 @@ +// Copyright (c) 2002-2009 Nokia Corporation and/or its subsidiary(-ies). +// All rights reserved. +// This component and the accompanying materials are made available +// under the terms of "Eclipse Public License v1.0" +// which accompanies this distribution, and is available +// at the URL "http://www.eclipse.org/legal/epl-v10.html". +// +// Initial Contributors: +// Nokia Corporation - initial contribution. +// +// Contributors: +// +// Description: +// + +PRJ_EXPORTS +lbslocmonclient.iby /epoc32/rom/include/lbslocmonclient.iby + +../../cenrep/20026814.txt c:/private/10202be9/20026814.txt + + +PRJ_MMPFILES +lbslocmonclient.mmp diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/CommonClientServerApi/group/lbslocmonclient.iby --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/CommonClientServerApi/group/lbslocmonclient.iby Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,26 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ +#ifndef __LBS_LOCMONCLIENT_IBY__ +#define __LBS_LOCMONCLIENT_IBY__ + +//#if !defined(SYMBIAN_EXCLUDE_LOCATION) + +file=ABI_DIR\DEBUG_DIR\lbslocmonclient.dll sys\bin\lbslocmonclient.dll + +//#endif // SYMBIAN_EXCLUDE_LOCATION + +#endif \ No newline at end of file diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/CommonClientServerApi/group/lbslocmonclient.mmp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/CommonClientServerApi/group/lbslocmonclient.mmp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,63 @@ +/* +* Copyright (c) 2005 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ + + +TARGET lbslocmonclient.dll +TARGETTYPE dll +UID 0x1000008d 0x102869DE + +CAPABILITY ALL -TCB + +MACRO ENABLE_LBS_DEV_LOGGER + +NOSTRICTDEF + +SOURCEPATH ../src +SOURCE rlbslocmonitorareapositioner.cpp +SOURCE rlbslocmonitorsession.cpp +SOURCE clbslocmonitorptrholder.cpp +SOURCE rlbslocinfoconverter.cpp +SOURCE clbslocinfoconversionhandler.cpp +// +// Server framework stuff +// +SOURCEPATH ../../../../locationcore/LbsLocCommon/ServerFramework/src +SOURCE tserverstartparams.cpp +SOURCE rsecuresessionbase.cpp +SOURCE cserverlaunch.cpp +SOURCE tstartparamsbase.cpp + +USERINCLUDE ../inc +USERINCLUDE ../../../../locationcore/LbsLocCommon/ServerFramework/inc +USERINCLUDE ../../../lbslocmonitorserver/inc +USERINCLUDE ../../../../locationcore/LbsInternalApi/inc +USERINCLUDE ../../../../locationcore/lbsrootapi/inc +USERINCLUDE ../../../../locationcore/LbsPartnerCommon/inc + +OS_LAYER_SYSTEMINCLUDE_SYMBIAN + +LIBRARY euser.lib +LIBRARY estor.lib +LIBRARY lbs.lib +LIBRARY lbsloccommon.lib +LIBRARY lbspartnercommon.lib +LIBRARY lbsrootapi.lib +LIBRARY lbslocationinfodatatypes.lib + +SMPSAFE + + diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/CommonClientServerApi/inc/clbslocinfoconversionhandler.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/CommonClientServerApi/inc/clbslocinfoconversionhandler.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,156 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Declaration of CLbsLocInfoConversionHandler class. +* +*/ +#ifndef C_LBSLOCINFOCONVERSIONHANDLER_H_ +#define C_LBSLOCINFOCONVERSIONHANDLER_H_ + +#include + +// Forward declaration +class RLbsLocInfoConverter; +class CLbsLocationInfo; + +/** + * Class waits for location information completion event and + * notifies the observer on completion. + */ +class CLbsLocInfoConversionHandler : public CActive + { +public: + enum TAyncRequestType + { + EGetBuffersizeForSingleArea, + + EGetSingleConvertedArea, + + EGetBuffersizeForMultipleArea, + + EGetMultipleConvertedArea + }; +public: + /** + * Allocates and construct a new CLbsLocInfoConversionHandler object + */ + static CLbsLocInfoConversionHandler* NewL( RLbsLocInfoConverter& aLocInfoConverter ); + + /** + * Destructor. + */ + ~CLbsLocInfoConversionHandler(); + + /** + * Starts the asyncronous operation by setting the iStatus to active. + */ + void Start( TAyncRequestType aType); + + /** + * Adds the buffer into the object. + */ + void SetBuffer( CBufFlat* aBuffer ); + + /** + * Stores the client's status. + */ + void SetStatus( TRequestStatus& aStatus ); + + /** + * Adds client specified requested info. + */ + void SetClientRequestedInfo( TLbsConversionOutputInfoMask aRequestedInfo ); + + /** + * Sets client's location info array. + */ + void SetClientLocationInfoArray( RLbsLocationInfoBaseArray* + aLocationInfoArray ); + + /** + * Sets client's location info object. + */ + void SetClientLocationInfo( CLbsLocationInfoBase& aLocationInfo ); + + /** + * Releases all the resources used by earlier request. + */ + void ReleaseAllResources(); + + +protected: // from CActive + void RunL(); + void DoCancel(); + +private: + CLbsLocInfoConversionHandler( RLbsLocInfoConverter& aLocInfoConverter ); + + void ConstructL(); + + void HandleSingleConversionL(); + + + void HandleMultipleConversionL(); + + void GetPositionInfoArrayL( RBufReadStream& readStream, + CLbsLocationInfo& aDesLocationInfo ); + + void GetGsmCellInfoArrayL( RBufReadStream& readStream, + CLbsLocationInfo& aDesLocationInfo); + + void GetWcdmaCellInfoArrayL( RBufReadStream& readStream, + CLbsLocationInfo& aDesLocationInfo ); + + void GetWlanInfoArrayL( RBufReadStream& readStream, + CLbsLocationInfo& aDesLocationInfo ); + + +private: // Member variables + /** + * Handle to loc info converter subsession. + */ + RLbsLocInfoConverter& iLocInfoConverter; + + /** + * Pointer to buffer + */ + CBufFlat* iBuffer; + + /** + * Pointer to client's TRequestStatus + */ + TRequestStatus* iClientStatus; + + /** + * Pointer to client's location info list + * Not Own. + */ + RLbsLocationInfoBaseArray* iClientLocationInfoList; + + /** + * Pointer to client's location info + */ + CLbsLocationInfoBase* iClientLocationInfo; + + /** + * Client specified request info + */ + TLbsConversionOutputInfoMask iRequestedInfo; + + /** + * Type of async operation requested + */ + TAyncRequestType iRequestType; + }; + +#endif /*C_LBSLOCINFOCONVERSIONHANDLER_H_*/ diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/CommonClientServerApi/inc/clbslocmonitorptrholder.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/CommonClientServerApi/inc/clbslocmonitorptrholder.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,56 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ + + +#ifndef CLBSLOCMONITORPTRHOLDER_H +#define CLBSLOCMONITORPTRHOLDER_H + +#include + +class CLbsLocMonitorPtrHolder : public CBase +/** +Holds the TPtr8 and TPtrC8 arrays for all RPositionServer requests. +@internalComponent + */ + { +public: + + enum TParameter + { + EPosForGetLastKnownPosition = 0, + EPosForGetLastKnownPositionArea, + EAreaForGetLastKnownPositionArea, + EParamsForGetLastKnownPositionArea, + ELastParam, // Keep this the last + }; + +public: + IMPORT_C static CLbsLocMonitorPtrHolder* NewL(TInt aNumberOfPtrs, + TInt aNumberOfPtrCs); + IMPORT_C ~CLbsLocMonitorPtrHolder(); + IMPORT_C TPtr8& Ptr(TInt aIndex); + IMPORT_C TPtrC8& PtrC(TInt aIndex); +protected: + IMPORT_C void ConstructL(TInt aNumberOfPtrs, TInt aNumberOfPtrCs); +private: + /** modifiable pointer array */ + RArray iPtrArray; + /** non-modifiable pointer array */ + RArray iPtrCArray; + }; + +#endif // CLBSLOCMONITORPTRHOLDER_H diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/CommonClientServerApi/inc/lbslocmonitorclientconsts.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/CommonClientServerApi/inc/lbslocmonitorclientconsts.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,58 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ + + +#ifndef LBSLOCMONITORCLIENTCONSTS_H_ +#define LBSLOCMONITORCLIENTCONSTS_H_ + +#include +#include + +/** + * Message parameters index in a message of RMessage2. The server has to use + * the parameter index defined below to write and read data into the IPC message. + */ + +// This position in the IPC is used by the client library to receive +// buffer size. +const TInt KParamBufferSize = 0; + + +// This position in the IPC is used by the client library to send location +// information. +const TInt KParamLocationInfo = 1; + +// This position in the IPC is used by the client library to send client preferences. +const TInt KParamClientPrefs = 2; + +// This position in the IPC is used by the server to send converted info +const TInt KParamConvertedInfo = 0; + +/** + * This structure holds conversion prefs,location info mask and + * the conversion module id. + */ +struct TLbsClientPrefs + { + TLbsConversionPrefs iConversionPrefs; + + TLbsConversionOutputInfoMask iRequestedInfo; + + TUid iConverterModuleId; + }; + +#endif /*LBSLOCMONITORCLIENTCONSTS_H_*/ diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/CommonClientServerApi/inc/rlbslocinfoconverter.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/CommonClientServerApi/inc/rlbslocinfoconverter.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,174 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ + + +#ifndef R_LBSLOCINFOCONVERTER_H_ +#define R_LBSLOCINFOCONVERTER_H_ + + +#include +#include +#include "rlbslocmonitorsession.h" +#include "rsecuresessionbase.h" + + +// Forward declaration +class CLbsLocInfoConversionHandler; +class CLbsLocMonitorPtrHolder; +struct TLbsClientPrefs; + + +/** + * + * This class provides services pertaining to conversion of geographical + * area information represented as a collection of GSM/WCDMA or WLAN + * information to corresponding geographical coordinates. This class is + * used to create sub-session with the location monitor server. + * + * Before using the class, a primary connection must have already been + * established with the server with RLbsLocMonitorSession::Connect(). + * + */ +class RLbsLocInfoConverter : public RSecureSubSessionBase + { +public: + + /** + * C++ constructor + */ + IMPORT_C RLbsLocInfoConverter(); + + /** + * Destructor + */ + IMPORT_C ~RLbsLocInfoConverter(); + + /** + * Opens a subsession with Location Monitor Server. + * + * A subsession must be opened before any other service can be used. + * + * @param[in] aServer Reference to the Location Monitor Server + * session. + * + * @return KErrNone if successful. Otherwise, Symbian standard + * error code is returned, such as KErrNoMemory, KErrServerBusy, etc. + */ + IMPORT_C void OpenL( RLbsLocMonitorSession& aLocMonSession ); + + /** + * Closes the subsession with Location Monitor Server. + */ + IMPORT_C void Close(); + + /** + * Converts one area info to position info + * @param[in] aLocationInfo location information corresponding to + * a geographical location is passed and on successful completion of this + * method,position information corresponding to the location information + * is returned in the observer callback. + * @param[in] aConversionPrefs Conversion preferences suggested by client + * @param[in] aRequestedInfo Location information that is requested. + * @param[in] aConverterModuleId Module ID of the converter plugin to be + * used + * @param[out] aStatus Contains the error code when the request is completed. + * + * @leave KErrArgument If the location info pointer is NULL or one of system + * wide error codes. + */ + IMPORT_C void ConvertLocationInfoL( CLbsLocationInfoBase& aLocationInfo, + TLbsConversionPrefs aConversionPrefs, + const TLbsConversionOutputInfoMask& aRequestedInfo, + const TUid aConverterModuleId, + TRequestStatus& aStatus ); + + /** + * Converts the area informations of a group of geographical locations + * to its corresponding position information. + * + * @param[in] aLocationInfoArray Array of Location information to be + * converted. + * @param[in] aConversionPrefs Conversion preferences suggested by client. + * @param[in] aRequestedInfo Location information that is requested. + * @param[in] aConversionModuleId Module ID of the converter plugin to be + * used + * @param[out] aStatus Contains the error code when the request is completed. + * + * @leave KErrArgument If the location info array is empty or if array count + * exceeds KPositionMaxBatchSize or one of system wide error codes. + */ + IMPORT_C void ConvertLocationInfoL( RLbsLocationInfoBaseArray& aLocationInfoArray, + TLbsConversionPrefs aConversionPrefs, + TLbsConversionOutputInfoMask aRequestedInfo, + const TUid aConverterModuleId, + TRequestStatus& aStatus ); + + /** + * Cancel outstanding request to convert location information. + */ + IMPORT_C void CancelConvertLocationInfo(); + + /** + * Handles buffer size passed from the server to store single converted + * location info. + */ + void HandleSingleConversionBufferSizeL(); + + /** + * Handles buffer size passed from the server to store multiple converted + * location info. + */ + void HandleMultipleConversionBufferSizeL(); + + /** + * Validates location information. + */ + void ValidateLocationInfoL( CLbsLocationInfoBase* aLocationInfo ); + + +private: + /** + * Symbian 2 phase constructor + */ + void ConstructL(); + + +private: // Member variables + /** + * Pointer to location info conversion handler + */ + CLbsLocInfoConversionHandler* iConversionHandler; + + /** + * A pointer to a container that holds pointer descriptors, needed to point + * to the clients request data during asynchronous requests + */ + CLbsLocMonitorPtrHolder* iPtrHolder; + + /** + * Size of the buffer required to receive information + * from server. + */ + TInt iBufferSize; + + /** + * Client preferences + */ + TLbsClientPrefs* iClientPrefs; + }; + +#endif /*R_LBSLOCINFOCONVERTER_H_*/ diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/CommonClientServerApi/inc/rlbslocmonitorareapositioner.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/CommonClientServerApi/inc/rlbslocmonitorareapositioner.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,99 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ + +/** +@file +@InternalTechnology +*/ + +#ifndef RLBSLOCMONITORAREAPOSITIONER_H +#define RLBSLOCMONITORAREAPOSITIONER_H + +#include +#include +#include "rlbslocmonitorsession.h" +#include "lbslocmonitorserverdata.h" +#include "clbslocmonitorptrholder.h" + +/** +This class is used by clients of the Location Monitor server to +create a sub-session with the server. + +Before using the class, a primary connection must have already been +established with the server with RLbsLocMonitorSession::Connect(). + +@see RLbsLocMonitorSession +*/ +class RLbsLocMonitorAreaPositioner : public RSecureSubSessionBase + { + +public: + + IMPORT_C RLbsLocMonitorAreaPositioner(); + IMPORT_C void OpenL(RLbsLocMonitorSession& aLocMonSession); + IMPORT_C void Close(); + + /* Called by the Location Server to report the last + Position obtained from any of its PSYs that are not otherwise + available to the Location Monitor. The position + will be stored in a database. + */ + IMPORT_C TInt SetLastKnownPosition(const TPositionInfoBase& aPosInfo) const; + + /* Retrieve the position last stored in the database */ + IMPORT_C void GetLastKnownPosition(TPositionInfoBase& aPosInfo, + TRequestStatus& aStatus) const; + + /* Cancel a previous call to GetLastKnownPosition*/ + IMPORT_C TInt CancelGetLastKnownPosition() const; + + /* Returns in aPosInfo a position which had been previously stored + in association with "context information" that is bound to a + geographical area (e.g. Global Cell Id). + + Current context information will be sensed by the server and used + to search for a position in the database. If found, the position + will be an approximation of the current position of the handset. + If no position is found in the database for the current context + information, the position last stored in the database is returned. + + The method returns in aAreaInfo a rough indication of how accurate the + returned position is based on an estimation of the size of the + geographical area covered by the sensed context information. + */ + IMPORT_C void GetLastKnownPositionArea(TPositionInfoBase& aPosInfo, + TPositionAreaInfoBase& aAreaInfo, + TPosAreaReqParams& aParameters, + TRequestStatus& aStatus) const; + + /* Cancel a call to GetLastKnownPositionArea */ + IMPORT_C TInt CancelGetLastKnownPositionArea() const; + + +protected: + + IMPORT_C virtual void ConstructL(); + IMPORT_C virtual void Destruct(); + +private: + + /** A pointer to a container that holds pointer descriptors, needed to point + to the clients request data during asynchronous requests */ + CLbsLocMonitorPtrHolder* iPtrHolder; + }; + +#endif // RLBSLOCMONITORAREAPOSITIONER_H diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/CommonClientServerApi/inc/rlbslocmonitorsession.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/CommonClientServerApi/inc/rlbslocmonitorsession.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,60 @@ +/* +* Copyright (c) 2008 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ + + +/** +@InternalTechnology +@prototype +*/ + +#ifndef RLBSLOCMONITORSESSION_H +#define RLBSLOCMONITORSESSION_H + +#include "rsecuresessionbase.h" + +/** +Client-side session with the Location Monitor server. + */ +class RLbsLocMonitorSession : public RSecureSessionBase + { + +public: + + IMPORT_C RLbsLocMonitorSession(); + + IMPORT_C TInt Connect(); + + IMPORT_C void Close(); + + /* Close the database and wipe out the DB file. + */ + IMPORT_C void WipeOutDatabase(TRequestStatus& aStatus) const; + + /* Cancel previous request to delete the Database + of positions. + */ + IMPORT_C TInt CancelDatabaseWipeOut() const; + + IMPORT_C TVersion Version(); + +protected: + + // From RSecureSessionBase + TInt StartServer(TServerStartParams& aParams); + }; + +#endif // RLBSLOCMONITORSESSION_H diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/CommonClientServerApi/src/clbslocinfoconversionhandler.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/CommonClientServerApi/src/clbslocinfoconversionhandler.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,378 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* Contributors: +* +* Description: Implementation of CLbsLocInfoConversionHandler class. +* +*/ + +#include +#include +#include +#include "rlbslocinfoconverter.h" +#include "clbslocinfoconversionhandler.h" + + +//---------------------------------------------------------------- +// CLbsLocInfoConversionHandler::NewL +// (other items were commented in a header). +//---------------------------------------------------------------- +CLbsLocInfoConversionHandler* CLbsLocInfoConversionHandler::NewL( + RLbsLocInfoConverter& aLocInfoConverter ) + { + CLbsLocInfoConversionHandler* self = new ( ELeave ) + CLbsLocInfoConversionHandler( aLocInfoConverter ); + CleanupStack::PushL( self ); + self->ConstructL(); + CleanupStack::Pop( self ); + return self; + } + +//---------------------------------------------------------------- +// CLbsLocInfoConversionHandler::CLbsLocInfoConversionHandler +// (other items were commented in a header). +//---------------------------------------------------------------- +CLbsLocInfoConversionHandler::CLbsLocInfoConversionHandler( + RLbsLocInfoConverter& aLocInfoConverter ): + CActive( EPriorityStandard ), + iLocInfoConverter( aLocInfoConverter ) + { + CActiveScheduler::Add( this ); + } + +//---------------------------------------------------------------- +// CLbsLocInfoConversionHandler::SetBuffer +// (other items were commented in a header). +//---------------------------------------------------------------- +void CLbsLocInfoConversionHandler::SetBuffer( CBufFlat* aBuffer ) + { + if( iBuffer ) + { + delete iBuffer; + iBuffer = NULL; + } + iBuffer = aBuffer; + } + +//---------------------------------------------------------------- +// CLbsLocInfoConversionHandler::SetStatus +// (other items were commented in a header). +//---------------------------------------------------------------- +void CLbsLocInfoConversionHandler:: SetStatus( TRequestStatus& aStatus ) + { + iClientStatus = &aStatus; + } + +//---------------------------------------------------------------- +// CLbsLocInfoConversionHandler::SetClientLocationInfoArray +// (other items were commented in a header). +//---------------------------------------------------------------- +void CLbsLocInfoConversionHandler::SetClientLocationInfoArray( + RLbsLocationInfoBaseArray* + aLocationInfoArray ) + { + iClientLocationInfoList = aLocationInfoArray; + } + +//---------------------------------------------------------------- +// CLbsLocInfoConversionHandler::SetClientLocationInfo +// (other items were commented in a header). +//---------------------------------------------------------------- +void CLbsLocInfoConversionHandler::SetClientLocationInfo( + CLbsLocationInfoBase& aLocationInfo ) + { + iClientLocationInfo = &aLocationInfo; + } + +//---------------------------------------------------------------- +// CLbsLocInfoConversionHandler::SetClientLocationInfo +// (other items were commented in a header). +//---------------------------------------------------------------- +void CLbsLocInfoConversionHandler::SetClientRequestedInfo( + TLbsConversionOutputInfoMask aRequestedInfo ) + { + iRequestedInfo = aRequestedInfo; + } + +//---------------------------------------------------------------- +// CLbsLocInfoConversionHandler::ReleaseAllResources +// (other items were commented in a header). +//---------------------------------------------------------------- +void CLbsLocInfoConversionHandler::ReleaseAllResources() + { + if( iBuffer ) + { + delete iBuffer; + iBuffer = NULL; + } + iClientLocationInfoList = NULL; + iClientLocationInfo = NULL; + iClientStatus = NULL; + } + +//---------------------------------------------------------------- +// CLbsLocInfoConversionHandler::~CLbsLocInfoConversionHandler +// (other items were commented in a header). +//---------------------------------------------------------------- +CLbsLocInfoConversionHandler::~CLbsLocInfoConversionHandler() + { + if( IsActive() ) + { + Cancel(); + } + delete iBuffer; + iBuffer = NULL; + } + +//---------------------------------------------------------------- +// CLbsLocInfoConversionHandler::RunL +// (other items were commented in a header). +//---------------------------------------------------------------- +void CLbsLocInfoConversionHandler::RunL() + { + TInt error = iStatus.Int(); + if( error == KErrNone ) + { + switch( iRequestType ) + { + case EGetBuffersizeForSingleArea: + { + iLocInfoConverter.HandleSingleConversionBufferSizeL(); + break; + } + case EGetSingleConvertedArea: + { + HandleSingleConversionL(); + break; + } + case EGetBuffersizeForMultipleArea: + { + iLocInfoConverter.HandleMultipleConversionBufferSizeL(); + break; + } + case EGetMultipleConvertedArea: + { + HandleMultipleConversionL(); + break; + } + } + } + // Incase of error, report it to the client through observer. + else + { + User::RequestComplete( iClientStatus,error ); + } + } + + +//---------------------------------------------------------------- +// CLbsLocInfoConversionHandler::HandleSingleConversionL +// (other items were commented in a header). +//---------------------------------------------------------------- +void CLbsLocInfoConversionHandler::HandleSingleConversionL() + { + RBufReadStream readStream( *iBuffer ); + CleanupClosePushL( readStream ); + + CLbsLocationInfo* clientLocInfo = static_cast + ( iClientLocationInfo ); + + // Get the client requested area info from location info object. + switch( iRequestedInfo ) + { + case ELbsConversionOutputPosition: + GetPositionInfoArrayL( readStream,*clientLocInfo ); + break; + + case ELbsConversionOutputGsm: + GetGsmCellInfoArrayL( readStream,*clientLocInfo ); + break; + + case ELbsConversionOutputWcdma: + GetWcdmaCellInfoArrayL( readStream,*clientLocInfo ); + break; + + case ELbsConversionOutputWlan: + GetWlanInfoArrayL( readStream,*clientLocInfo ); + break; + + } + + // Complete client status + CleanupStack::PopAndDestroy( &readStream ); + User::RequestComplete( iClientStatus,KErrNone ); + } + +//---------------------------------------------------------------- +// CLbsLocInfoConversionHandler::HandleMultipleConversionL +// (other items were commented in a header). +//---------------------------------------------------------------- +void CLbsLocInfoConversionHandler::HandleMultipleConversionL() + { + RBufReadStream readStream( *iBuffer ); + CleanupClosePushL( readStream ); + + // Extract the converted info array from the stream. + TInt locInfoArrayCount = readStream.ReadInt8L(); + + // Get the client requested area info from the each object of location + // info in the array + for( TInt i=0;i + ( (*iClientLocationInfoList)[i] ); + + switch( iRequestedInfo ) + { + case ELbsConversionOutputPosition: + GetPositionInfoArrayL( readStream,*clientLocInfo ); + break; + + case ELbsConversionOutputGsm: + GetGsmCellInfoArrayL( readStream,*clientLocInfo ); + break; + + case ELbsConversionOutputWcdma: + GetWcdmaCellInfoArrayL( readStream,*clientLocInfo ); + break; + + case ELbsConversionOutputWlan: + GetWlanInfoArrayL( readStream,*clientLocInfo ); + break; + } + } + + // Complete client status + CleanupStack::PopAndDestroy( &readStream ); + User::RequestComplete( iClientStatus,KErrNone ); + } + +//---------------------------------------------------------------- +// CLbsLocInfoConversionHandler::DoCancel +// (other items were commented in a header). +//---------------------------------------------------------------- +void CLbsLocInfoConversionHandler::DoCancel() + { + User::RequestComplete(iClientStatus, iStatus.Int()); + } + +//---------------------------------------------------------------- +// CLbsLocInfoConversionHandler::ConstructL +// (other items were commented in a header). +//---------------------------------------------------------------- +void CLbsLocInfoConversionHandler::ConstructL() + { + // Nothing to be done here. + } + +// --------------------------------------------------------- +// CLbsLocInfoConversionHandler::Start +// (other items were commented in a header). +// --------------------------------------------------------- +// +void CLbsLocInfoConversionHandler::Start( TAyncRequestType aType ) + { + iRequestType = aType; + SetActive(); + } + +// --------------------------------------------------------- +// CLbsLocInfoConversionHandler::GetPositionInfoArrayL +// (other items were commented in a header). +// --------------------------------------------------------- +// +void CLbsLocInfoConversionHandler::GetPositionInfoArrayL( + RBufReadStream& readStream, + CLbsLocationInfo& aDesLocationInfo ) + { + // Read the count of converted info. + TInt convertedInfoCount = readStream.ReadInt8L(); + + for( TInt i=0;iInternaliseL( readStream ); + aDesLocationInfo.AddAreaInfoL( positionInfo ); + CleanupStack::Pop( positionInfo ); + } + } + + +// --------------------------------------------------------- +// CLbsLocInfoConversionHandler::GetGsmCellInfoArrayL +// (other items were commented in a header). +// --------------------------------------------------------- +// +void CLbsLocInfoConversionHandler::GetGsmCellInfoArrayL( + RBufReadStream& readStream, + CLbsLocationInfo& aDesLocationInfo ) + { + // Read the count of converted info. + TInt convertedInfoCount = readStream.ReadInt8L(); + + for( TInt i=0;iInternaliseL( readStream ); + aDesLocationInfo.AddAreaInfoL( gsmCellInfo ); + CleanupStack::Pop( gsmCellInfo ); + } + } + +// --------------------------------------------------------- +// CLbsLocInfoConversionHandler::GetWcdmaCellInfoArrayL +// (other items were commented in a header). +// --------------------------------------------------------- +// +void CLbsLocInfoConversionHandler::GetWcdmaCellInfoArrayL( + RBufReadStream& readStream, + CLbsLocationInfo& aDesLocationInfo ) + { + // Read the count of converted info. + TInt convertedInfoCount = readStream.ReadInt8L(); + + for( TInt i=0;iInternaliseL( readStream ); + aDesLocationInfo.AddAreaInfoL( wcdmaCellInfo ); + CleanupStack::Pop( wcdmaCellInfo ); + } + } + +// --------------------------------------------------------- +// CLbsLocInfoConversionHandler::GetWlanInfoArrayL +// (other items were commented in a header). +// --------------------------------------------------------- +// +void CLbsLocInfoConversionHandler::GetWlanInfoArrayL( + RBufReadStream& readStream, + CLbsLocationInfo& aDesLocationInfo ) + { + // Read the count of converted info. + TInt convertedInfoCount = readStream.ReadInt8L(); + + for( TInt i=0;iInternaliseL( readStream ); + aDesLocationInfo.AddAreaInfoL( wlanInfo ); + CleanupStack::Pop( wlanInfo ); + } + } + +// End of file. diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/CommonClientServerApi/src/clbslocmonitorptrholder.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/CommonClientServerApi/src/clbslocmonitorptrholder.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,101 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ + + +#include "clbslocmonitorptrholder.h" + + +//----------------------------------------------------------------------------- +// CLbsLocMonitorPtrHolder +//----------------------------------------------------------------------------- + +/** + Allocates and constructs a CLbsLocMonitorPtrHolder object. + + The function leaves if there is insufficient memory. + +@internalComponent +@param aNumberOfPtrs is the number of modifiable pointer descriptors to + create. These are used for asynchronous 'get' requests. +@param aNumberOfPtrCs is the number of read-only pointer descriptors to + create. These are used for asynchronous 'set' requests. +@return a newly created CLbsLocMonitorPtrHolder object. + */ +EXPORT_C CLbsLocMonitorPtrHolder* CLbsLocMonitorPtrHolder::NewL(TInt aNumberOfPtrs, + TInt aNumberOfPtrCs) + { + CLbsLocMonitorPtrHolder* self = new (ELeave) CLbsLocMonitorPtrHolder; + CleanupStack::PushL(self); + self->ConstructL(aNumberOfPtrs, aNumberOfPtrCs); + CleanupStack::Pop(self); + return self; + } + +EXPORT_C void CLbsLocMonitorPtrHolder::ConstructL(TInt aNumberOfPtrs, + TInt aNumberOfPtrCs) + + { + TPtr8 ptr(NULL, 0); + TInt i; + for (i = 0; i < aNumberOfPtrs; i++) + { + User::LeaveIfError(iPtrArray.Append(ptr)); + } + + TPtrC8 ptrC(NULL, 0); + for (i = 0; i < aNumberOfPtrCs; i++) + { + User::LeaveIfError(iPtrCArray.Append(ptrC)); + } + } + +/** +Destructor for CLbsLocMonitorPtrHolder. + +@internalComponent +*/ +EXPORT_C CLbsLocMonitorPtrHolder::~CLbsLocMonitorPtrHolder() + { + iPtrCArray.Close(); + iPtrArray.Close(); + } + +/** +An accessor for the modifiable pointer descriptors. + +@internalComponent +@param aIndex specifies the descriptor to return. +@return a reference to one of our contained pointer descriptors. + */ +EXPORT_C TPtr8& CLbsLocMonitorPtrHolder::Ptr(TInt aIndex) + { + return iPtrArray[aIndex]; + } + +/** +An accessor for the read-only pointer descriptors. + +@internalComponent +@param aIndex specifies the descriptor to return. +@return a reference to one of our contained pointer descriptors. +*/ +EXPORT_C TPtrC8& CLbsLocMonitorPtrHolder::PtrC(TInt aIndex) + { + return iPtrCArray[aIndex]; + } + + diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/CommonClientServerApi/src/rlbslocinfoconverter.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/CommonClientServerApi/src/rlbslocinfoconverter.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,357 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Implementation of RLbsLocInfoConverter class. +* +*/ + +#include +#include +#include "rlbslocinfoconverter.h" +#include "clbslocinfoconversionhandler.h" +#include "lbslocmonitorclientconsts.h" +#include "clbslocmonitorptrholder.h" +#include "lbslocmonitorserverdata.h" +#include +#include +#include +#include +#include + +void CleanUpAreaInfoArray(TAny* aArray) + { + static_cast(aArray)->ResetAndDestroy(); + } + + +//---------------------------------------------------------------- +// RLbsLocInfoConverter::RLbsLocInfoConverter +// (other items were commented in a header). +//---------------------------------------------------------------- +EXPORT_C RLbsLocInfoConverter::RLbsLocInfoConverter(): + iConversionHandler( NULL ), + iPtrHolder( NULL ) + { + //iConversionHandler = NULL; + //iPtrHolder = NULL; + } + +//---------------------------------------------------------------- +// RLbsLocInfoConverter::~RLbsLocInfoConverter +// (other items were commented in a header). +//---------------------------------------------------------------- +EXPORT_C RLbsLocInfoConverter::~RLbsLocInfoConverter() + { + delete iConversionHandler; + iConversionHandler = NULL; + + delete iPtrHolder; + iPtrHolder = NULL; + + delete iClientPrefs; + iClientPrefs = NULL; + } + + +//---------------------------------------------------------------- +// RLbsLocInfoConverter::OpenL +// (other items were commented in a header). +//---------------------------------------------------------------- +EXPORT_C void RLbsLocInfoConverter::OpenL( RLbsLocMonitorSession& + aLocMonSession ) + { + __ASSERT_ALWAYS(aLocMonSession.Handle() != 0, User::Invariant()); // trying to open twice + TInt err(KErrNone); + ConstructL(); + + // Call Server Framework 'Open' + TLbsLocMonitorConversionPositionerData emptyData; + TLbsLocMonitorSubSessionType type(ELocMonitorSubSessionTypeConversionPositiner); + err = RSecureSubSessionBase::Open + (aLocMonSession, type, emptyData); + User::LeaveIfError(err); + } + +//---------------------------------------------------------------- +// RLbsLocInfoConverter::Close +// (other items were commented in a header). +//---------------------------------------------------------------- +EXPORT_C void RLbsLocInfoConverter::Close() + { + // Call Server Framework 'Close' + RSecureSubSessionBase::Close(); + } + +//---------------------------------------------------------------- +// RLbsLocInfoConverter::ConvertLocationInfoL +// (other items were commented in a header). +//---------------------------------------------------------------- +EXPORT_C void RLbsLocInfoConverter::ConvertLocationInfoL( + CLbsLocationInfoBase& aLocationInfo, + TLbsConversionPrefs aConversionPrefs, + const TLbsConversionOutputInfoMask& aRequestedInfo, + const TUid aConverterModuleId, + TRequestStatus& aStatus ) + { + __ASSERT_ALWAYS(SubSessionHandle(), User::Invariant()); + + // If there is any outstanding request,panic the client with error code + // ELocMonitorDuplicateRequest + if( iConversionHandler->IsActive() ) + { + User::Panic( KLocationMonitorFault,ELocMonitorDuplicateRequest ); + } + + aStatus = KRequestPending; + + // Validate area information + ValidateLocationInfoL( &aLocationInfo ); + + // Release the resources used by the earlier request. + iConversionHandler->ReleaseAllResources(); + + // Store the handle to client's location info. This is required to + // update it with the converted info. + iConversionHandler->SetClientLocationInfo( aLocationInfo ); + iConversionHandler->SetClientRequestedInfo( aRequestedInfo ); + + iPtrHolder->Ptr(0).Set( reinterpret_cast(&iBufferSize), + sizeof(iBufferSize),sizeof(iBufferSize) ); + + CBufFlat* buffer = CBufFlat::NewL( 512 ); + CleanupStack::PushL( buffer ); + RBufWriteStream writeStream; + writeStream.Open( *buffer ); + CleanupClosePushL( writeStream ); + + // Write location info content to the stream. + aLocationInfo.ExternaliseL( writeStream ); + writeStream.CommitL(); + CleanupStack::PopAndDestroy( &writeStream ); + CleanupStack::Pop( buffer ); + + // Store the buffer handle in the handler object. + iConversionHandler->SetBuffer( buffer ); + + // Store handle to client's status in handler object.Handler + // object will complete client's status on conversion completion. + iConversionHandler->SetStatus( aStatus ); + + TPtr8 ptr = buffer->Ptr(0); + iPtrHolder->Ptr(1).Set( ptr ); + + // Client preferences are packed into a structure in order to send it in + // a single IPC slot. + iClientPrefs->iConversionPrefs = aConversionPrefs; + iClientPrefs->iRequestedInfo = aRequestedInfo; + iClientPrefs->iConverterModuleId = aConverterModuleId; + TPckg clientPrefsPckg( *iClientPrefs ); + + TIpcArgs ipcArgs; + ipcArgs.Set( KParamBufferSize,&iPtrHolder->Ptr(0) ); + ipcArgs.Set( KParamLocationInfo,&iPtrHolder->Ptr(1) ); + ipcArgs.Set( KParamClientPrefs,&clientPrefsPckg ); + + SendReceive( EConvertSingleLocationInfoBufferSize,ipcArgs,iConversionHandler->iStatus ); + iConversionHandler->Start( CLbsLocInfoConversionHandler::EGetBuffersizeForSingleArea ); + } + +//---------------------------------------------------------------- +// RLbsLocInfoConverter::ConvertLocationInfoL +// (other items were commented in a header). +//---------------------------------------------------------------- +EXPORT_C void RLbsLocInfoConverter::ConvertLocationInfoL( + RLbsLocationInfoBaseArray& aLocationInfoArray, + TLbsConversionPrefs aConversionPrefs, + TLbsConversionOutputInfoMask aRequestedInfo, + const TUid aConverterModuleId, + TRequestStatus& aStatus ) + { + __ASSERT_ALWAYS(SubSessionHandle(), User::Invariant()); + + // If there is any outstanding request,panic the client with error code + // ELocMonitorDuplicateRequest + if( iConversionHandler->IsActive() ) + { + User::Panic( KLocationMonitorFault,ELocMonitorDuplicateRequest ); + } + + aStatus = KRequestPending; + + TInt count = aLocationInfoArray.Count(); + // Leave with error code if array count is zero or count exceeds KPositionMaxBatchSize + if( !count || count > KPositionMaxBatchSize ) + { + User::Leave( KErrArgument ); + } + + // Validate each location info object in the array. + for( TInt i=0;iReleaseAllResources(); + + // Store the handle to client's location info array. This is required to + // update it with the converted info. + iConversionHandler->SetClientLocationInfoArray( &aLocationInfoArray ); + iConversionHandler->SetClientRequestedInfo( aRequestedInfo ); + + iPtrHolder->Ptr(0).Set( reinterpret_cast(&iBufferSize), + sizeof(iBufferSize),sizeof(iBufferSize) ); + + CBufFlat* buffer = CBufFlat::NewL( 512 ); + CleanupStack::PushL( buffer ); + RBufWriteStream writeStream; + writeStream.Open( *buffer ); + CleanupClosePushL( writeStream ); + + TInt arrayCount = aLocationInfoArray.Count(); + // Write the array count to the stream. + writeStream.WriteInt8L( arrayCount ); + + // Write location info array contents to the stream. + for( TInt i=0;iExternaliseL( writeStream ); + } + writeStream.CommitL(); + CleanupStack::PopAndDestroy( &writeStream ); + CleanupStack::Pop( buffer ); + + // Store the buffer handle in the handler object. + iConversionHandler->SetBuffer( buffer ); + + // Store handle to client's status in handler object.Handler + // object will complete client's status on conversion completion. + iConversionHandler->SetStatus( aStatus ); + + TPtr8 ptr = buffer->Ptr(0); + iPtrHolder->Ptr(1).Set( ptr ); + + // Client preferences are packed into a structure in order to send it in + // a single IPC slot. + iClientPrefs->iConversionPrefs = aConversionPrefs; + iClientPrefs->iRequestedInfo = aRequestedInfo; + iClientPrefs->iConverterModuleId = aConverterModuleId; + TPckg clientPrefsPckg( *iClientPrefs ); + + TIpcArgs ipcArgs; + ipcArgs.Set( KParamBufferSize,&iPtrHolder->Ptr(0) ); + ipcArgs.Set( KParamLocationInfo,&iPtrHolder->Ptr(1) ); + ipcArgs.Set( KParamClientPrefs,&clientPrefsPckg ); + + SendReceive( EConvertMultipleLocationInfoBufferSize,ipcArgs,iConversionHandler->iStatus ); + iConversionHandler->Start( CLbsLocInfoConversionHandler::EGetBuffersizeForMultipleArea ); + } + +//---------------------------------------------------------------- +// RLbsLocInfoConverter::CancelConvertLocationInfo +// (other items were commented in a header). +//---------------------------------------------------------------- +EXPORT_C void RLbsLocInfoConverter::CancelConvertLocationInfo() + { + __ASSERT_ALWAYS(SubSessionHandle(), User::Invariant()); + SendReceive( ECancelConvertLocationInfo ); + if( iConversionHandler->iStatus.Int() != KRequestPending ) + iConversionHandler->Cancel(); + } + +//---------------------------------------------------------------- +// RLbsLocInfoConverter::HandleSingleConversionBufferSizeL +// (other items were commented in a header). +//---------------------------------------------------------------- +void RLbsLocInfoConverter::HandleSingleConversionBufferSizeL() + { + CBufFlat* buffer = CBufFlat::NewL(256); + CleanupStack::PushL( buffer ); + buffer->ResizeL( iBufferSize ); + CleanupStack::Pop( buffer ); + iConversionHandler->SetBuffer( buffer ); + + TPtr8 bufPtr = buffer->Ptr(0); + iPtrHolder->Ptr(0).Set( bufPtr ); + TIpcArgs ipcArgs; + ipcArgs.Set( KParamConvertedInfo,&iPtrHolder->Ptr(0) ); + + SendReceive( EGetSingleLocationInfo,ipcArgs,iConversionHandler->iStatus ); + iConversionHandler->Start( CLbsLocInfoConversionHandler::EGetSingleConvertedArea ); + } + +//---------------------------------------------------------------- +// RLbsLocInfoConverter::HandleMultipleConversionBufferSizeL +// (other items were commented in a header). +//---------------------------------------------------------------- +void RLbsLocInfoConverter::HandleMultipleConversionBufferSizeL() + { + CBufFlat* buffer = CBufFlat::NewL(256); + CleanupStack::PushL( buffer ); + buffer->ResizeL( iBufferSize ); + CleanupStack::Pop( buffer ); + iConversionHandler->SetBuffer( buffer ); + + TPtr8 bufPtr = buffer->Ptr(0); + iPtrHolder->Ptr(0).Set( bufPtr ); + TIpcArgs ipcArgs; + ipcArgs.Set( KParamConvertedInfo,&iPtrHolder->Ptr(0) ); + + SendReceive( EGetMultipleLocationInfo,ipcArgs,iConversionHandler->iStatus ); + iConversionHandler->Start( CLbsLocInfoConversionHandler::EGetMultipleConvertedArea ); + } + +//---------------------------------------------------------------- +// RLbsLocInfoConverter::ConstructL +// (other items were commented in a header). +//---------------------------------------------------------------- +EXPORT_C void RLbsLocInfoConverter::ConstructL() + { + iConversionHandler = CLbsLocInfoConversionHandler::NewL( *this ); + iPtrHolder = CLbsLocMonitorPtrHolder::NewL(CLbsLocMonitorPtrHolder::ELastParam, 0); + iClientPrefs = new( ELeave ) TLbsClientPrefs; + } + +//---------------------------------------------------------------- +// RLbsLocInfoConverter::ValidateLocationInfoL +// (other items were commented in a header). +//---------------------------------------------------------------- +void RLbsLocInfoConverter::ValidateLocationInfoL( CLbsLocationInfoBase* + aLocationInfo ) + { + CLbsLocationInfo* locationInfo = static_cast + ( aLocationInfo ); + + RLbsAreaInfoBaseArray areaInfoArray; + + CleanupStack::PushL(TCleanupItem(*CleanUpAreaInfoArray, &areaInfoArray )); + + locationInfo->GetAreaInfoL( areaInfoArray ); + + // Leave with error if array count is zero. + TInt count = areaInfoArray.Count(); + if( !count ) + { + User::Leave( KErrArgument ); + } + + // Validate each and every area info object. + for( TInt i=0;iValidateDataL(); + } + CleanupStack::PopAndDestroy( &areaInfoArray ); + } + +// End of file diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/CommonClientServerApi/src/rlbslocmonitorareapositioner.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/CommonClientServerApi/src/rlbslocmonitorareapositioner.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,194 @@ +/* +* Copyright (c) 2008 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ + + +#include +#include +#include +#include +#include "rlbslocmonitorareapositioner.h" + + +EXPORT_C RLbsLocMonitorAreaPositioner::RLbsLocMonitorAreaPositioner() + : RSecureSubSessionBase(), + iPtrHolder(NULL) + { + } + +EXPORT_C void RLbsLocMonitorAreaPositioner::ConstructL() + { + iPtrHolder = CLbsLocMonitorPtrHolder::NewL(CLbsLocMonitorPtrHolder::ELastParam, 0); + } + +EXPORT_C void RLbsLocMonitorAreaPositioner::Destruct() + { + delete iPtrHolder; + iPtrHolder = NULL; + } + +EXPORT_C void RLbsLocMonitorAreaPositioner::OpenL(RLbsLocMonitorSession& aLocMonSession) + { + __ASSERT_ALWAYS(aLocMonSession.Handle() != 0, User::Invariant()); // trying to open twice + TInt err(KErrNone); + ConstructL(); + + // Call Server Framework 'Open' + TLbsLocMonitorAreaPositionerData emptyData; + TLbsLocMonitorSubSessionType type(ELocMonitorSubSessionTypeAreaPositioner); + err = RSecureSubSessionBase::Open(aLocMonSession, type, emptyData); + if (err != KErrNone) + { + Destruct(); + } + User::LeaveIfError(err); + } + +EXPORT_C void RLbsLocMonitorAreaPositioner::Close() + { + // Call Server Framework 'Close' + RSecureSubSessionBase::Close(); + Destruct(); + } + +/** +Method called by the Location Server to send the Last Known Position to the Location Monitor +for storing together with Local Area information if possible. + +@param aPosInfo the position object to be sent to the server (only the TPositionInfo portion + will be sent) +@return KErrNone if position is succesfully sent to server + KErrArgument if aPosInfo is not a TPositionInfo class or derived class. + Any of the error codes returned by RSessionBase::SendReceive +*/ +EXPORT_C TInt RLbsLocMonitorAreaPositioner::SetLastKnownPosition(const TPositionInfoBase& aPosInfo) const + { + __ASSERT_ALWAYS(SubSessionHandle(), User::Invariant()); + __ASSERT_ALWAYS(iPtrHolder != NULL, User::Invariant()); + // Verify aPosInfo is of a type that contains a position + const TPositionInfoBase& infoBase = static_cast(aPosInfo); + TUint32 classType = infoBase.PositionClassType(); + if (!(classType & EPositionInfoClass)) + { + return KErrArgument; + } + + // Get the TPosition in aPosInfo and send to the Location Monitor + const TPositionInfo& posInfo = static_cast(aPosInfo); + TPosition position; + posInfo.GetPosition(position); + + TPckgC posPckg(position); + return SendReceive(ESetLastKnownPosition, TIpcArgs(&posPckg)); + } + + +/* Retrieve the position last stored in the database */ +EXPORT_C void RLbsLocMonitorAreaPositioner::GetLastKnownPosition(TPositionInfoBase& aPosInfo, + TRequestStatus& aStatus) const + { + __ASSERT_ALWAYS(SubSessionHandle(), User::Invariant()); + __ASSERT_ALWAYS(iPtrHolder != NULL, User::Invariant()); + + // Ensure aPosInfo output parameter is at TPositionInfo or derived class + const TPositionInfoBase& infoBase = static_cast(aPosInfo); + TUint32 classType = infoBase.PositionClassType(); + if (!(classType & EPositionInfoClass)) + { + TRequestStatus* status = &aStatus; + User::RequestComplete(status, KErrArgument); + return; + } + + iPtrHolder->Ptr(CLbsLocMonitorPtrHolder::EPosForGetLastKnownPosition).Set( + reinterpret_cast(&aPosInfo), + aPosInfo.PositionClassSize(), + aPosInfo.PositionClassSize()); + + SendReceive(EGetLastKnownPosition, + TIpcArgs(&iPtrHolder->Ptr(CLbsLocMonitorPtrHolder::EPosForGetLastKnownPosition)), + aStatus); + } + +EXPORT_C TInt RLbsLocMonitorAreaPositioner::CancelGetLastKnownPosition() const + { + __ASSERT_ALWAYS(SubSessionHandle(), User::Invariant()); + + return SendReceive(ECancelGetLastKnownPosition); + } + + +/** +Returns in aPosInfo a position which had been previously stored +in association with "context information" that is bound to a +geographical area (e.g. Global Cell Id). + +Current context information will be sensed by the server and used +to search for a position in the database. If found, the position +will be an approximation of the current position of the handset. +If no position is found in the database for the current context +information, the position last stored in the database is returned. + +The method returns in aAreaInfo a rough indication of how accurate the +returned position is based on an estimation of the size of the +geographical area covered by the sensed context information. +*/ +EXPORT_C void RLbsLocMonitorAreaPositioner::GetLastKnownPositionArea(TPositionInfoBase& aPosInfo, + TPositionAreaInfoBase& aAreaInfo, + TPosAreaReqParams& aParameters, + TRequestStatus& aStatus) const + { + __ASSERT_ALWAYS(SubSessionHandle(), User::Invariant()); + __ASSERT_ALWAYS(iPtrHolder != NULL, User::Invariant()); + + // Ensure aPosInfo output parameter is at TPositionInfo or derived class + const TPositionInfoBase& infoBase = static_cast(aPosInfo); + TUint32 classType = infoBase.PositionClassType(); + if (!(classType & EPositionInfoClass)) + { + TRequestStatus* status = &aStatus; + User::RequestComplete(status, KErrArgument); + return; + } + + iPtrHolder->Ptr(CLbsLocMonitorPtrHolder::EPosForGetLastKnownPositionArea).Set( + reinterpret_cast(&aPosInfo), + aPosInfo.PositionClassSize(), + aPosInfo.PositionClassSize()); + + iPtrHolder->Ptr(CLbsLocMonitorPtrHolder::EAreaForGetLastKnownPositionArea).Set( + reinterpret_cast(&aAreaInfo), + aAreaInfo.PositionClassSize(), + aAreaInfo.PositionClassSize()); + + iPtrHolder->Ptr(CLbsLocMonitorPtrHolder::EParamsForGetLastKnownPositionArea).Set( + reinterpret_cast(&aParameters), + sizeof(TPosAreaReqParams), + sizeof(TPosAreaReqParams)); + + SendReceive(EGetLastKnownPositionArea, + TIpcArgs(&iPtrHolder->Ptr(CLbsLocMonitorPtrHolder::EPosForGetLastKnownPositionArea), + &iPtrHolder->Ptr(CLbsLocMonitorPtrHolder::EAreaForGetLastKnownPositionArea), + &iPtrHolder->Ptr(CLbsLocMonitorPtrHolder::EParamsForGetLastKnownPositionArea)), + aStatus); + } + +EXPORT_C TInt RLbsLocMonitorAreaPositioner::CancelGetLastKnownPositionArea() const + { + __ASSERT_ALWAYS(SubSessionHandle(), User::Invariant()); + return SendReceive(ECancelGetLastKnownPositionArea); + } + diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/CommonClientServerApi/src/rlbslocmonitorsession.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/CommonClientServerApi/src/rlbslocmonitorsession.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,109 @@ +/* +* Copyright (c) 2008 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ + + +#include "rlbslocmonitorsession.h" +#include "lbsdevloggermacros.h" +#include "tserverstartparams.h" +#include "cserverlaunch.h" +#include "lbslocmonitorserverdata.h" +#include "lbsprocessuiddefs.h" +#include "lbsipc.h" + + +//----------------------------------------------------------------------------- +// RLbsLocMonitorSession +//----------------------------------------------------------------------------- +EXPORT_C RLbsLocMonitorSession::RLbsLocMonitorSession() + { + LBSLOG(ELogP9, "->S RLbsLocMonitorSession::RLbsLocMonitorSession() lbslocmonitor.exe\n"); + } + +/** +Creates a session with the location monitor server. +This method starts the server if not yet started. + +@return Standard Symbian OS error code. +*/ +EXPORT_C TInt RLbsLocMonitorSession::Connect() + { + LBSLOG(ELogP9, "->S RLbsLocMonitorSession::Connect()\n"); + TInt ret(KErrNone); + TServerStartParams params; + params.SetServerFileName(KLocMonitorExeName); + params.SetServerName(KLocMonitorServerName); + params.SetNumberOfServerSlots(KLbsDefaultMessageSlots); + params.SetServerUids(KNullUid, KNullUid, KLbsLocMonitorUid); + + // Base class creates the session (and the server if required) + ret = RSecureSessionBase::Connect(params); + + LBSLOG2(ELogP9, " Return = %d\n", ret); + return ret; + } + +EXPORT_C void RLbsLocMonitorSession::Close() + { + LBSLOG(ELogP9, "->S RLbsLocMonitorSession::Close() lbslocationmonitor.exe\n"); + RSecureSessionBase::Close(); + } + +/** +Attempts to Cancel a previously issued asynchronous request to delete the +database of area-locations. + +The TRequestStatus of the original request will be set to KErrCancel if +the cancellation request was successful, or any other Symbian OS error code +if CancelRequest was called too late. + +@return Standard Symbian OS error code. + */ +EXPORT_C TInt RLbsLocMonitorSession::CancelDatabaseWipeOut() const + { + LBSLOG(ELogP9, "->S RLbsLocMonitorSession::CancelDatabaseWipeOut() lbslocationmonitor.exe\n"); + __ASSERT_ALWAYS(Handle(), User::Invariant()); + return SendReceive(ECancelDbWipeOut); + } + +EXPORT_C void RLbsLocMonitorSession::WipeOutDatabase(TRequestStatus& aStatus) const + { + LBSLOG(ELogP9, "->S RLbsLocMonitorSession::WipeOutDatabase() lbslocationmonitor.exe\n"); + __ASSERT_ALWAYS(Handle(), User::Invariant()); + return SendReceive(EWipeOutDb, aStatus); + } + +EXPORT_C TVersion RLbsLocMonitorSession::Version() +/** +Obtains the current version number of the location monitor. + +@return the version of the client API. + */ + { + LBSLOG(ELogP9, "->S RLbsLocMonitorSession::Version() lbslocationmonitor.exe\n"); + LBSLOG4(ELogP9, " Return TVersion = (%d, %d, %d)\n", KLbsLocMonitorMajorVersionNumber, + KLbsLocMonitorMinorVersionNumber, + KLbsLocMonitorBuildVersionNumber); + return TVersion( + KLbsLocMonitorMajorVersionNumber, + KLbsLocMonitorMinorVersionNumber, + KLbsLocMonitorBuildVersionNumber); + } + +TInt RLbsLocMonitorSession::StartServer(TServerStartParams& aParams) + { + return RSecureSessionBase::StartServer(aParams); + } diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/ConversionApi/ConversionClientApi/BWINS/lbslocationinfoconverteru.def --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/ConversionApi/ConversionClientApi/BWINS/lbslocationinfoconverteru.def Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,17 @@ +EXPORTS + ?NewL@CLbsLocationResolver@@SAPAV1@AAVMLbsLocationResolverObserver@@@Z @ 1 NONAME ; class CLbsLocationResolver * CLbsLocationResolver::NewL(class MLbsLocationResolverObserver &) + ?NewL@CLbsLocationInfoConverter@@SAPAV1@AAVMLbsLocationInfoConverterObserver@@VTUid@@@Z @ 2 NONAME ; class CLbsLocationInfoConverter * CLbsLocationInfoConverter::NewL(class MLbsLocationInfoConverterObserver &, class TUid) + ?NewL@CLbsLocationInfoConverter@@SAPAV1@AAVMLbsLocationInfoConverterObserver@@@Z @ 3 NONAME ; class CLbsLocationInfoConverter * CLbsLocationInfoConverter::NewL(class MLbsLocationInfoConverterObserver &) + ?CancelResolveLocation@CLbsLocationResolver@@QAEXXZ @ 4 NONAME ; void CLbsLocationResolver::CancelResolveLocation(void) + ?NewL@CLbsLocationResolver@@SAPAV1@AAVMLbsLocationResolverObserver@@VTUid@@@Z @ 5 NONAME ; class CLbsLocationResolver * CLbsLocationResolver::NewL(class MLbsLocationResolverObserver &, class TUid) + ?ConvertLocationInfoL@CLbsLocationInfoConverter@@QAEXAAV?$RPointerArray@VCLbsLocationInfoBase@@@@KK@Z @ 6 NONAME ; void CLbsLocationInfoConverter::ConvertLocationInfoL(class RPointerArray &, unsigned long, unsigned long) + ??1CLbsLocationResolver@@UAE@XZ @ 7 NONAME ; CLbsLocationResolver::~CLbsLocationResolver(void) + ?ResolveLocationL@CLbsLocationResolver@@QAEXABVCLbsLocationInfo@@@Z @ 8 NONAME ; void CLbsLocationResolver::ResolveLocationL(class CLbsLocationInfo const &) + ?Version@MLbsLocationInfoConverterObserver@@UBE?AVTVersion@@XZ @ 9 NONAME ; class TVersion MLbsLocationInfoConverterObserver::Version(void) const + ??1CLbsLocationInfoConverter@@UAE@XZ @ 10 NONAME ; CLbsLocationInfoConverter::~CLbsLocationInfoConverter(void) + ?Version@MLbsLocationResolverObserver@@UBE?AVTVersion@@XZ @ 11 NONAME ; class TVersion MLbsLocationResolverObserver::Version(void) const + ?ConvertLocationInfoL@CLbsLocationInfoConverter@@QAEXAAVCLbsLocationInfoBase@@KK@Z @ 12 NONAME ; void CLbsLocationInfoConverter::ConvertLocationInfoL(class CLbsLocationInfoBase &, unsigned long, unsigned long) + ?CancelConvertLocationInfo@CLbsLocationInfoConverter@@QAEXXZ @ 13 NONAME ; void CLbsLocationInfoConverter::CancelConvertLocationInfo(void) + ?SetConversionPreferences@CLbsLocationResolver@@QAEHK@Z @ 14 NONAME ; int CLbsLocationResolver::SetConversionPreferences(unsigned long) + ?ConversionPreferences@CLbsLocationResolver@@QAEKXZ @ 15 NONAME ; unsigned long CLbsLocationResolver::ConversionPreferences(void) + diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/ConversionApi/ConversionClientApi/EABI/lbslocationinfoconverteru.def --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/ConversionApi/ConversionClientApi/EABI/lbslocationinfoconverteru.def Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,29 @@ +EXPORTS + _ZN20CLbsLocationResolver16ResolveLocationLERK16CLbsLocationInfo @ 1 NONAME + _ZN20CLbsLocationResolver21CancelResolveLocationEv @ 2 NONAME + _ZN20CLbsLocationResolver4NewLER28MLbsLocationResolverObserver @ 3 NONAME + _ZN20CLbsLocationResolver4NewLER28MLbsLocationResolverObserver4TUid @ 4 NONAME + _ZN20CLbsLocationResolverD0Ev @ 5 NONAME + _ZN20CLbsLocationResolverD1Ev @ 6 NONAME + _ZN20CLbsLocationResolverD2Ev @ 7 NONAME + _ZN25CLbsLocationInfoConverter20ConvertLocationInfoLER13RPointerArrayI20CLbsLocationInfoBaseEmm @ 8 NONAME + _ZN25CLbsLocationInfoConverter20ConvertLocationInfoLER20CLbsLocationInfoBasemm @ 9 NONAME + _ZN25CLbsLocationInfoConverter25CancelConvertLocationInfoEv @ 10 NONAME + _ZN25CLbsLocationInfoConverter4NewLER33MLbsLocationInfoConverterObserver @ 11 NONAME + _ZN25CLbsLocationInfoConverter4NewLER33MLbsLocationInfoConverterObserver4TUid @ 12 NONAME + _ZN25CLbsLocationInfoConverterD0Ev @ 13 NONAME + _ZN25CLbsLocationInfoConverterD1Ev @ 14 NONAME + _ZN25CLbsLocationInfoConverterD2Ev @ 15 NONAME + _ZNK28MLbsLocationResolverObserver7VersionEv @ 16 NONAME + _ZNK33MLbsLocationInfoConverterObserver7VersionEv @ 17 NONAME + _ZTI24CLbsLocationResolverImpl @ 18 NONAME + _ZTI28MLbsLocationResolverObserver @ 19 NONAME + _ZTI29CLbsLocationInfoConverterImpl @ 20 NONAME + _ZTI33MLbsLocationInfoConverterObserver @ 21 NONAME + _ZTV24CLbsLocationResolverImpl @ 22 NONAME + _ZTV28MLbsLocationResolverObserver @ 23 NONAME + _ZTV29CLbsLocationInfoConverterImpl @ 24 NONAME + _ZTV33MLbsLocationInfoConverterObserver @ 25 NONAME + _ZN20CLbsLocationResolver21ConversionPreferencesEv @ 26 NONAME + _ZN20CLbsLocationResolver24SetConversionPreferencesEm @ 27 NONAME + diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/ConversionApi/ConversionClientApi/group/bld.inf --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/ConversionApi/ConversionClientApi/group/bld.inf Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,26 @@ +// Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +// All rights reserved. +// This component and the accompanying materials are made available +// under the terms of "Eclipse Public License v1.0" +// which accompanies this distribution, and is available +// at the URL "http://www.eclipse.org/legal/epl-v10.html". +// +// Initial Contributors: +// Nokia Corporation - initial contribution. +// +// Contributors: +// +// Description: +// + + +PRJ_EXPORTS +../inc/lbslocationinfoconverter.h SYMBIAN_OS_LAYER_PLATFORM_EXPORT_PATH(lbs/lbslocationinfoconverter.h) +../inc/lbslocationresolver.h SYMBIAN_OS_LAYER_PLATFORM_EXPORT_PATH(lbs/lbslocationresolver.h) + + +lbslocationinfoconverter.iby /epoc32/rom/include/lbslocationinfoconverter.iby + + +PRJ_MMPFILES +lbslocationinfoconverter.mmp diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/ConversionApi/ConversionClientApi/group/lbslocationinfoconverter.iby --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/ConversionApi/ConversionClientApi/group/lbslocationinfoconverter.iby Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,25 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ +#ifndef __LBS_LOCATIONINFOCONVERTER_IBY__ +#define __LBS_LOCATIONINFOCONVERTER_IBY__ +//#if !defined(SYMBIAN_EXCLUDE_LOCATION) + +file=ABI_DIR\DEBUG_DIR\lbslocationinfoconverter.dll sys\bin\lbslocationinfoconverter.dll + +//#endif // SYMBIAN_EXCLUDE_LOCATION + +#endif //__LBS_LOCATIONINFOCONVERTER_IBY__ diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/ConversionApi/ConversionClientApi/group/lbslocationinfoconverter.mmp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/ConversionApi/ConversionClientApi/group/lbslocationinfoconverter.mmp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,44 @@ +// Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +// All rights reserved. +// This component and the accompanying materials are made available +// under the terms of "Eclipse Public License v1.0" +// which accompanies this distribution, and is available +// at the URL "http://www.eclipse.org/legal/epl-v10.html". +// +// Initial Contributors: +// Nokia Corporation - initial contribution. +// +// Contributors: +// +// Description: +// + + +TARGET lbslocationinfoconverter.dll +TARGETTYPE dll +UID 0x1000008d 0x102871F9 + +VENDORID 0x70000001 +CAPABILITY ALL -TCB + +SOURCEPATH ../src +SOURCE lbslocationinfoconverter.cpp +SOURCE lbslocationinfoconverterimpl.cpp +SOURCE lbslocationresolver.cpp +SOURCE lbslocationresolverimpl.cpp + + +USERINCLUDE ../inc +USERINCLUDE ../../../CommonClientServerApi/inc +USERINCLUDE ../../../../../locationcore/LbsLocCommon/ServerFramework/inc + +OS_LAYER_SYSTEMINCLUDE_SYMBIAN + +LIBRARY euser.lib +LIBRARY lbslocationinfodatatypes.lib +LIBRARY lbslocmonclient.lib +LIBRARY lbs.lib +LIBRARY estor.lib + +SMPSAFE + diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/ConversionApi/ConversionClientApi/inc/lbslocationinfoconverter.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/ConversionApi/ConversionClientApi/inc/lbslocationinfoconverter.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,226 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Class used by client applications to convert location +* information +* +*/ + +/** +@file +@publishedPartner +@prototype +*/ + +#ifndef LBS_LOCATION_INFO_CONVERTER_H +#define LBS_LOCATION_INFO_CONVERTER_H + + +// OS wide +#include + +// LBS wide +#include +#include +#include + +class CLbsLocationInfoConverterImpl; + + +/** +* The MLbsLocationInfoConverterObserver class is used in partnership with +* CLbsLocationInfoConverter. The observer interface is used by the LBS +* subsystem to inform a client application when a Locality conversion +* process initiated through the CLbsLocationInfoConverter class has been +* finished. In OnResolveLocationComplete the results will be returned +* as an argument of the function, while OnConversionComplete indicates that the results +* have been written in to the data that was passed in using ConvertLocationInfoL. +* +* Although all the interface methods in the MLbsLocationInfoConverterObserver +* class are synchronous, the client application should ensure they return quickly +* (e.g. any extensive processing of the received data is scheduled in another +* active object). +*/ +class MLbsLocationInfoConverterObserver + { + +public: + + /** + * Gets the current version of the observer interface. + * Derived classes should not change the implementation. + * + * @return Version number (currently 1.0.0) + */ + IMPORT_C virtual TVersion Version() const; + + /** + * The callback is used by the LBS subsystem to inform a client application + * that a general purpose Locality conversion process initiated through the + * CLbsLocationInfoConverter::ConvertLocationInfoL method has been finished. + * + * Receiving the callback indicates that, unless the conversion was not successful, + * the location data structures passed through the + * CLbsLocationInfoConverter::ConvertLocationInfoL method have been updated with the + * requested information. + * + * @param aStatusCode Result of the conversion operation; + * KErrNone if at least one conversion have been successful and + * the related location data structure(s) passed through the + * CLbsLocationInfoConverter::ConvertLocationInfoL method + * have been updated with the requested information; + * KErrNotSupported if the conversion type specified by + * aRequestedInfo is not supported by converter plugin + * KErrNotFound if none of conversions have been successful; + * Or other system wide error code othervise. +In here I think we should say that when the caller uses ConvertLocationInfoL( RLbsLocationInfoBaseArray& aLocationInfoArray, ..) then on OnConversionComplete the caller should iterate around all 'n' of the entries of the aLocationInfoArray and call GetAreaInfoL to see if there is any conversion results. OH I see below that you say something near the ConvertLocationInfoL method. Maybe should say it here as well to ti e together + */ + virtual void OnConversionComplete(TInt aStatusCode) = 0; + + }; + + + + +/** +* The CLbsLocationInfoConverter interface is used in partnership with MLbsLocationInfoConverterObserver +* and provides the services to convert location information between different formats. +* +* Completion of conversions is indicated by the LBS subsystem by invoking callbacks defined +* by the MLbsLocationInfoConverterObserver class. +* +* Currently the only supported conversion is from WLAN and/or GSM and/or WCDMA info into a geographic +* Locality. +*/ +NONSHARABLE_CLASS(CLbsLocationInfoConverter) : public CBase + { + +public: + + /** + * Allocates and construct a new CLbsLocationInfoConverter + * @param[in] aObserver An observer for location conversion event. + * @param[in] aConverterModuleId UID of the conversion plugin to be used. + */ + IMPORT_C static CLbsLocationInfoConverter* NewL( + MLbsLocationInfoConverterObserver& aObserver, + const TUid aConverterModuleId); + + /** + * Allocates and construct a new CLbsLocationInfoConverter + * Note here to say that impementations for both OnResolveLocationComplete and OnConversionComplete MUST be provided even though only interested in say, ConvertLocationFingerPrintToLocalityL + * Opens the default module. + * @param[in] aObserver An observer for location conversion event. + */ + IMPORT_C static CLbsLocationInfoConverter* NewL( + MLbsLocationInfoConverterObserver& aObserver); + + /** + * Destructor. + */ + IMPORT_C ~CLbsLocationInfoConverter(); + + /** + * A general purpose function that converts a single locationinfo. + * Completion of the conversion is indicated by the LBS subsystem by invoking the + * MLbsLocationInfoConverterObserver::OnConversionComplete + * and the caller can then iterate through the results returned in aLocationInfo + * + * @capability Location + * + * @param[in] aLocationInfo location information to be converted. + * @param[in] aConversionPrefs Conversion preferences suggested by client + * @param[in] aRequestedInfo Location information that is requested. Currently + * the only supported conversion is from WLAN and/or GSM and/or WCDMA info into + * a geographic position, hence the parameter should be set to ELbsConversionOutputPosition) + * Need to say that can only do one of either ConvertLocationFingerPrintToLocalityL or ConvertLocationInfoL at a time or else user is panicked + + * @leave KErrNoMemory if there is not enough memory available to perform the conversion. + * KErrArgument If the location info pointer is NULL. + */ + IMPORT_C void ConvertLocationInfoL( CLbsLocationInfoBase& aLocationInfo, + const TLbsConversionPrefs aConversionPrefs, + const TLbsConversionOutputInfoMask aRequestedInfo ); + + + /** + * A general purpose function that converts multiple locationinfos. + * The maximum allowable batch size is defined by KPositionMaxBatchSize which is 500. + * Exceeding KPositionMaxBatchSize will result in KErrNotSupported being reported. + * + * Completion of the conversion is indicated by the LBS subsystem by invoking the + * MLbsLocationInfoConverterObserver::OnConversionComplete + * and the caller can then iterate through the results returned in aLocationInfoArray + * + * @capability Location + * + * @param[in] aLocationInfo An array of location information to be converted. + * @param[in] aConversionPrefs Conversion preferences suggested by client + * @param[in] aRequestedInfo Location information that is requested. Currently + * the only supported conversion is from WLAN and/or GSM and/or WCDMA info into + * a geographic position, hence the parameter should be set to ELbsConversionOutputPosition) + * + * @leave KErrNoMemory if there is not enough memory available to perform the conversion. + * KErrArgument If the location info pointer is NULL. + * KErrNotSupported if the conversion type specified by + * aRequestedInfo is not supported or if the bitmask specified by the + * client has all options set. This error is also returned if the + * batch size exceeds KPositionMaxBatchSize. + */ + IMPORT_C void ConvertLocationInfoL( RLbsLocationInfoBaseArray& aLocationInfoArray, + const TLbsConversionPrefs aConversionPrefs, + const TLbsConversionOutputInfoMask aRequestedInfo ); + + /** + * Cancels an ongoing conversion operation. + * If there is no ongoing conversion the cancellation request is ignored. + * + * Neither of the The MLbsLocationInfoConverterObserver callbacks will not be invoked if cancellation is successful. + */ + IMPORT_C void CancelConvertLocationInfo(); + +private: + + /** + * Default constructor + */ + CLbsLocationInfoConverter(); + + /** + * Symbian 2nd phase constructor. + */ + void ConstructL(MLbsLocationInfoConverterObserver& aObserver, + const TUid aConverterModuleId); + + /** + * Copy constructor. Restricted by default. + */ + CLbsLocationInfoConverter( CLbsLocationInfoConverter& ); + + /** + * Overloaded assignment operator. Restricted by default. + */ + CLbsLocationInfoConverter& operator=( CLbsLocationInfoConverter& ); + +private: + + /** + * Pointer to implementation class + */ + CLbsLocationInfoConverterImpl* iLocationInfoConverterImpl; + + }; + + + +#endif // LBS_LOCATION_INFO_CONVERTER_H diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/ConversionApi/ConversionClientApi/inc/lbslocationinfoconverterimpl.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/ConversionApi/ConversionClientApi/inc/lbslocationinfoconverterimpl.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,142 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Class that implements location information converter +* information +* +*/ + + +#ifndef LBSLOCATIONINFOCONVERTERIMPL_H_ +#define LBSLOCATIONINFOCONVERTERIMPL_H_ + + +#include +#include +#include "rlbslocmonitorsession.h" +#include "rlbslocinfoconverter.h" +#include + + +// forward declaration +class MLbsLocationInfoConverterObserver; + + +/** + * Class implements the services exposed by CLbsLocationInfoConverter + */ +class CLbsLocationInfoConverterImpl : public CActive + { +public: + /** + * Allocates and construct a new CLbsLocationInfoConverterImpl + * + * @param[in] aObserver Handle to the observer implementation + * @param[in] aConversionModuleId ID of the conversion plugin to be used. + * @return Pointer to the implementation class of Location Info converter. + */ + static CLbsLocationInfoConverterImpl* NewL( MLbsLocationInfoConverterObserver& aObserver, + const TUid aConversionModuleId ); + + /** + * Destructor + */ + ~CLbsLocationInfoConverterImpl(); + + /** + * Converts one area info to position info + * @param[in] aLocationInfo location information corresponding to + * a geographical location is passed and on successful completion of this + * method,position information corresponding to the location information + * is returned in the observer callback. + * @param[in] aConversionPrefs Conversion preferences suggested by client + * @param[in] aRequestedInfo Location information that is requested. + * + * @leave KErrArgument If the location info array is empty or one of system + * wide error codes. + */ + void ConvertLocationInfoL( CLbsLocationInfoBase& aLocationInfo, + TLbsConversionPrefs aConversionPrefs, + const TLbsConversionOutputInfoMask aRequestedInfo ); + + /** + * Converts the area informations of a group of geographical locations + * to its corresponding position information. + * @param[in][out] aLocationInfoArray Array of location informations + * corresponding to geographical locations are passed and on successful + * completion of this method,position information corresponding to the + * location informations are returned in the observer callback. + * @param[in] aConversionPrefs Conversion preferences suggested by client + * + * @leave KErrArgument If the location info array is empty or one of + * system wide error codes. + */ + void ConvertLocationInfoL( RLbsLocationInfoBaseArray& aLocationInfoArray, + TLbsConversionPrefs aConversionPrefs, + const TLbsConversionOutputInfoMask aRequestedInfo ); + + /** + * Cancels get location info operation. + */ + void CancelConvertLocationInfo(); + +protected: // From CActive + void RunL(); + + void DoCancel(); + +private: + /** + * Default constructor + */ + CLbsLocationInfoConverterImpl( MLbsLocationInfoConverterObserver& aObserver ); + + /** + * Copy constructor. Restricted by default. + */ + CLbsLocationInfoConverterImpl( CLbsLocationInfoConverterImpl& ); + + /** + * Overloaded assignment operator. Restricted by default. + */ + CLbsLocationInfoConverterImpl& operator=( CLbsLocationInfoConverterImpl& ); + + /** + * Symbian 2 phase constructor. + */ + void ConstructL( const TUid aConversionModuleId ); + +private: // data + + /** + * Reference to the observer. + */ + MLbsLocationInfoConverterObserver& iObserver; + + /** + * Handle to session + */ + RLbsLocMonitorSession iLocMoniterSession; + + /** + * Handle to subsession + */ + RLbsLocInfoConverter iLocInfoConverter; + + /** + * Client specified conversion module id. + */ + TUid iConversionModuleId; + }; + +#endif // LBSLOCATIONINFOCONVERTERIMPL_H_ diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/ConversionApi/ConversionClientApi/inc/lbslocationresolver.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/ConversionApi/ConversionClientApi/inc/lbslocationresolver.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,159 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Class used by client applications to convert data +* such as such as WlanInfo or CellIds into TLocality position information +* +*/ + +/** +@file +@publishedPartner +@prototype +*/ + +#ifndef LBS_LOCATIONRESOLVER_H +#define LBS_LOCATIONRESOLVER_H + + +#include +#include +#include +#include + +class CLbsLocationResolverImpl; + + +class MLbsLocationResolverObserver + { + +public: + + /** + * Gets the current version of the observer interface. + * Derived classes should not change the implementation. + * + * @return Version number (currently 1.0.0) + */ + IMPORT_C virtual TVersion Version() const; + + /** + * The callback is used by the LBS subsystem to inform a client application + * that a simple CLbsLocationResolver conversion process initiated through the + * CLbsLocationResolver::ResolveLocationL method has been finished. + * + * @param aStatus status of conversion, KErrNone for success, standard system error code + * in other cases. Note that in the event of a cancellation this method will not execute. + * @param aBasicLocationInfo the location conversion that was requested. + * If the conversion has failed the values will be uninitialised + */ + virtual void OnResolveLocationComplete(TInt aStatus, const TLocality& aLocality) = 0; + + }; + + +NONSHARABLE_CLASS(CLbsLocationResolver) : public CBase + { + +public: + + /** + * Allocates and construct a new CLbsLocationResolver + * @param[in] aObserver An observer for location conversion event. + * @param[in] aConverterModuleId UID of the conversion plugin to be used. + */ + IMPORT_C static CLbsLocationResolver* NewL(MLbsLocationResolverObserver& aObserver, + const TUid aConverterModuleId); + + /** + * Allocates and construct a new CLbsLocationResolver + * @param[in] aObserver An observer for location conversion event. + */ + IMPORT_C static CLbsLocationResolver* NewL(MLbsLocationResolverObserver& aObserver); + + /** + * Destructor. + */ + IMPORT_C ~CLbsLocationResolver(); + + /** + * A simple function that converts a single Location Info into a TLocality + * No preferences or masks may be set. + * The result is returned in the MLbsLocationResolverObserver + * callback via OnResolveLocationComplete + * + * Only one outstanding conversion can be open at a time for each client. + * Attempting to perform more than one will result in a leave with KErrInUse + * + * @param[in] aLocationInfo the information to be converted into a location. + */ + IMPORT_C void ResolveLocationL(const CLbsLocationInfo& aLocationInfo); + + /** + * Sets the option for the conversion module's connection preferences [ eg. "online without prompt"] + * @param[in] aConversionPref - Enum specifying the connection preferences + * @return KErrArgument if the value is invalid, KErrNone otherwise + */ + IMPORT_C TInt SetConversionPreferences(TLbsConversionPrefs aConversionPrefs); + + /** + * Returns the option currently set for the conversion module's + * connection preference [ eg. "local cache"] + * @return The enum corresponding to the currently set connection preferences (ELbsConversionNotDefined will be + * returned if the conversion preferences have not been set yet) + */ + IMPORT_C TLbsConversionPrefs ConversionPreferences(); + + /** + * Cancels an ongoing conversion operation. + * If there is no ongoing conversion the cancellation request is ignored. + * + * The MLbsLocationResolverObserver callback will not be invoked + * if cancellation is successful. + */ + IMPORT_C void CancelResolveLocation(); + +protected: + /** + * Default constructor + */ + CLbsLocationResolver(); + + /** + * Symbian 2nd phase constructor. + */ + void ConstructL(MLbsLocationResolverObserver& aObserver, const TUid aConverterModuleId); + + +private: + /** + * Copy constructor. Restricted by default. + */ + CLbsLocationResolver(CLbsLocationResolver&); + + /** + * Overloaded assignment operator. Restricted by default. + */ + CLbsLocationResolver& operator=(CLbsLocationResolver&); + +private: + + /** + * Pointer to implementation class + */ + CLbsLocationResolverImpl* iLocationResolverImpl; + + }; + + +#endif // LBS_LOCATIONRESOLVER_H diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/ConversionApi/ConversionClientApi/inc/lbslocationresolverimpl.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/ConversionApi/ConversionClientApi/inc/lbslocationresolverimpl.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,149 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Class that implements location information converter +* information +* +*/ + + +#ifndef LBSLOCATIONINFOCONVERTERIMPL_H_ +#define LBSLOCATIONINFOCONVERTERIMPL_H_ + + +#include +#include +#include "rlbslocmonitorsession.h" +#include "rlbslocinfoconverter.h" +#include + + +// forward declaration +class MLbsLocationResolverObserver; + + +/** + * Class implements the services exposed by CLbsLocationInfoConverter + */ +class CLbsLocationResolverImpl : public CActive + { +public: + /** + * Allocates and construct a new CLbsLocationResolverImpl + * + * @param[in] aObserver Handle to the observer implementation + * @param[in] aConversionModuleId ID of the conversion plugin to be used. + * @return Pointer to the implementation class of Location Info converter. + */ + static CLbsLocationResolverImpl* NewL( MLbsLocationResolverObserver& aObserver, + const TUid aConversionModuleId ); + + /** + * Destructor + */ + ~CLbsLocationResolverImpl(); + + /** + * Converts one area info to position info + * @param[in] aLocationInfo location information corresponding to + * a geographical location is passed and on successful completion of this + * method,position information corresponding to the location information + * is returned in the observer callback. + * @param[in] aConversionPrefs Conversion preferences suggested by client + * @param[in] aRequestedInfo Location information that is requested. + * + * @leave KErrArgument If the location info array is empty or one of system + * wide error codes. + */ + void ResolveLocationL(const CLbsLocationInfoBase& aLocationInfo); + + /** + * Cancels get location info operation. + */ + void CancelResolveLocation(); + + /** + * Sets the option for the conversion module's connection preferences [ eg. "online without prompt"] + * @param[in] aConversionPrefs - Enum specifying the connection preference + * @return KErrArgument if the value is invalid, KErrNone otherwise + */ + TInt SetConversionPreferences(TLbsConversionPrefs aConversionPrefs); + + /** + * Returns the option currently set for the conversion module's + * connection preference [ eg. "local cache"] + * @return The enum corresponding to the currently set connection preferences (ELbsConversionNotDefined will be + * returned if the conversion preferences have not been set yet) + */ + TLbsConversionPrefs ConversionPreferences(); + +protected: // From CActive + void RunL(); + + void DoCancel(); + +private: + /** + * Default constructor + */ + CLbsLocationResolverImpl( MLbsLocationResolverObserver& aObserver ); + + /** + * Copy constructor. Restricted by default. + */ + CLbsLocationResolverImpl( CLbsLocationResolverImpl& ); + + /** + * Overloaded assignment operator. Restricted by default. + */ + CLbsLocationResolverImpl& operator=( CLbsLocationResolverImpl& ); + + /** + * Symbian 2 phase constructor. + */ + void ConstructL( const TUid aConversionModuleId ); + +private: // data + + /** + * Copy of locationinfo passed in by client + */ + CLbsLocationInfo* iLocationInfo; + + /** + * Reference to the observer. + */ + MLbsLocationResolverObserver& iObserver; + + /** + * Handle to session + */ + RLbsLocMonitorSession iLocMoniterSession; + + /** + * Handle to subsession + */ + RLbsLocInfoConverter iLocInfoConverter; + + /** + * Client specified conversion module id. + */ + TUid iConversionModuleId; + + /** + * Conversion module's specific connection preferences + */ + TLbsConversionPrefs iConversionPrefs; + }; + +#endif // LBSLOCATIONINFOCONVERTERIMPL_H_ diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/ConversionApi/ConversionClientApi/src/lbslocationinfoconverter.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/ConversionApi/ConversionClientApi/src/lbslocationinfoconverter.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,125 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Class used by client applications to convert location +* information +* +*/ + +#include +#include +#include +#include "lbslocationinfoconverterimpl.h" + + +EXPORT_C TVersion MLbsLocationInfoConverterObserver::Version() const + { + return TVersion(1, 0, 0); + } + + + +//---------------------------------------------------------------- +// CLbsLocationInfoConverter::NewL +// (other items were commented in a header). +//---------------------------------------------------------------- +EXPORT_C CLbsLocationInfoConverter* CLbsLocationInfoConverter::NewL( + MLbsLocationInfoConverterObserver& aObserver, + const TUid aConverterModuleId ) + { + CLbsLocationInfoConverter* self = new( ELeave ) CLbsLocationInfoConverter; + CleanupStack::PushL( self ); + self->ConstructL( aObserver,aConverterModuleId ); + CleanupStack::Pop( self ); + return self; + } + +//---------------------------------------------------------------- +// CLbsLocationInfoConverter::NewL +// (other items were commented in a header). +//---------------------------------------------------------------- +EXPORT_C CLbsLocationInfoConverter* CLbsLocationInfoConverter::NewL( + MLbsLocationInfoConverterObserver& aObserver ) + { + CLbsLocationInfoConverter* self = new( ELeave ) CLbsLocationInfoConverter; + CleanupStack::PushL( self ); + self->ConstructL( aObserver,TUid::Uid( KNullUidValue ) ); + CleanupStack::Pop( self ); + return self; + } + +//---------------------------------------------------------------- +// CLbsLocationInfoConverter::~CLbsLocationInfoConverter +// (other items were commented in a header). +//---------------------------------------------------------------- +EXPORT_C CLbsLocationInfoConverter::~CLbsLocationInfoConverter() + { + delete iLocationInfoConverterImpl; + iLocationInfoConverterImpl = NULL; + } + +//---------------------------------------------------------------- +// CLbsLocationInfoConverter::ConvertLocationInfoL +// (other items were commented in a header). +//---------------------------------------------------------------- +EXPORT_C void CLbsLocationInfoConverter::ConvertLocationInfoL( + CLbsLocationInfoBase& aLocationInfo, + const TLbsConversionPrefs aConversionPrefs, + const TLbsConversionOutputInfoMask aRequestedInfo ) + { + iLocationInfoConverterImpl->ConvertLocationInfoL( aLocationInfo,aConversionPrefs, + aRequestedInfo ); + } + +//---------------------------------------------------------------- +// CLbsLocationInfoConverter::ConvertLocationInfoL +// (other items were commented in a header). +//---------------------------------------------------------------- +EXPORT_C void CLbsLocationInfoConverter::ConvertLocationInfoL( + RLbsLocationInfoBaseArray& aLocationInfoArray, + const TLbsConversionPrefs aConversionPrefs, + const TLbsConversionOutputInfoMask aRequestedInfo ) + { + iLocationInfoConverterImpl->ConvertLocationInfoL( aLocationInfoArray, + aConversionPrefs,aRequestedInfo ); + } + +//---------------------------------------------------------------- +// CLbsLocationInfoConverter::CancelConvertLocationInfo +// (other items were commented in a header). +//---------------------------------------------------------------- +EXPORT_C void CLbsLocationInfoConverter::CancelConvertLocationInfo() + { + iLocationInfoConverterImpl->CancelConvertLocationInfo(); + } + +//---------------------------------------------------------------- +// CLbsLocationInfoConverter::ConstructL +// (other items were commented in a header). +//---------------------------------------------------------------- +void CLbsLocationInfoConverter::ConstructL( + MLbsLocationInfoConverterObserver& aObserver, + const TUid aConverterModuleId ) + { + iLocationInfoConverterImpl = CLbsLocationInfoConverterImpl::NewL( + aObserver,aConverterModuleId ); + } + +//---------------------------------------------------------------- +// CLbsLocationInfoConverter::CLbsLocationInfoConverter +// (other items were commented in a header). +//---------------------------------------------------------------- +CLbsLocationInfoConverter::CLbsLocationInfoConverter() + { + + } diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/ConversionApi/ConversionClientApi/src/lbslocationinfoconverterimpl.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/ConversionApi/ConversionClientApi/src/lbslocationinfoconverterimpl.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,132 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Implementation of CLbsLocationInfoConverterImpl class. +* +*/ + +#include "lbslocationinfoconverterimpl.h" +#include + + +//---------------------------------------------------------------- +// CLbsLocationInfoConverterImpl::NewL +// (other items were commented in a header). +//---------------------------------------------------------------- +CLbsLocationInfoConverterImpl* CLbsLocationInfoConverterImpl::NewL( + MLbsLocationInfoConverterObserver& aObserver, + const TUid aConverterModuleId ) + { + CLbsLocationInfoConverterImpl* self = new( ELeave ) CLbsLocationInfoConverterImpl( + aObserver ); + CleanupStack::PushL( self ); + self->ConstructL( aConverterModuleId ); + CleanupStack::Pop( self ); + return self; + } + + +//---------------------------------------------------------------- +// CLbsLocationInfoConverterImpl::~CLbsLocationInfoConverterImpl +// (other items were commented in a header). +//---------------------------------------------------------------- +CLbsLocationInfoConverterImpl::~CLbsLocationInfoConverterImpl() + { + iLocInfoConverter.Close(); + iLocMoniterSession.Close(); + } + +//---------------------------------------------------------------- +// CLbsLocationInfoConverterImpl::CLbsLocationInfoConverterImpl +// (other items were commented in a header). +//---------------------------------------------------------------- +CLbsLocationInfoConverterImpl::CLbsLocationInfoConverterImpl( + MLbsLocationInfoConverterObserver& aObserver ): + CActive( EPriorityStandard ), + iObserver( aObserver ) + + { + CActiveScheduler::Add( this ); + } + +//---------------------------------------------------------------- +// CLbsLocationInfoConverterImpl::ConstructL +// (other items were commented in a header). +//---------------------------------------------------------------- +void CLbsLocationInfoConverterImpl::ConstructL( const TUid aConverterModuleId ) + { + iConversionModuleId = aConverterModuleId; + User::LeaveIfError( iLocMoniterSession.Connect() ); + iLocInfoConverter.OpenL( iLocMoniterSession ); + } + +//---------------------------------------------------------------- +// CLbsLocationInfoConverterImpl::ConvertLocationInfoL +// (other items were commented in a header). +//---------------------------------------------------------------- +void CLbsLocationInfoConverterImpl::ConvertLocationInfoL( + CLbsLocationInfoBase& aLocationInfo, + const TLbsConversionPrefs aConversionPrefs, + const TLbsConversionOutputInfoMask aRequestedInfo ) + { + iLocInfoConverter.ConvertLocationInfoL( aLocationInfo,aConversionPrefs,aRequestedInfo, + iConversionModuleId,iStatus ); + SetActive(); + } + +//---------------------------------------------------------------- +// CLbsLocationInfoConverterImpl::ConvertLocationInfoL +// (other items were commented in a header). +//---------------------------------------------------------------- +void CLbsLocationInfoConverterImpl::ConvertLocationInfoL( + RLbsLocationInfoBaseArray& aLocationInfoArray, + TLbsConversionPrefs aConversionPrefs, + const TLbsConversionOutputInfoMask aRequestedInfo ) + { + iLocInfoConverter.ConvertLocationInfoL( aLocationInfoArray,aConversionPrefs,aRequestedInfo, + iConversionModuleId,iStatus ); + SetActive(); + } + +//---------------------------------------------------------------- +// CLbsLocationInfoConverterImpl::CancelConvertLocationInfoL +// (other items were commented in a header). +//-------;--------------------------------------------------------- +void CLbsLocationInfoConverterImpl::CancelConvertLocationInfo() + { + Cancel(); + } + +//---------------------------------------------------------------- +// CLbsLocationInfoConverterImpl::RunL +// (other items were commented in a header). +//---------------------------------------------------------------- +void CLbsLocationInfoConverterImpl::RunL() + { + if( iStatus.Int() != KErrCancel ) + { + iObserver.OnConversionComplete( iStatus.Int() ); + } + } + +//---------------------------------------------------------------- +// CLbsLocationInfoConverterImpl::DoCancel +// (other items were commented in a header). +//---------------------------------------------------------------- +void CLbsLocationInfoConverterImpl::DoCancel() + { + iLocInfoConverter.CancelConvertLocationInfo(); + } + +// End of file + diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/ConversionApi/ConversionClientApi/src/lbslocationresolver.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/ConversionApi/ConversionClientApi/src/lbslocationresolver.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,127 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Class used by client applications to convert location +* information +* +*/ + +#include +#include +#include +#include "lbslocationresolverimpl.h" + + +EXPORT_C TVersion MLbsLocationResolverObserver::Version() const + { + return TVersion(1, 0, 0); + } + + + +//---------------------------------------------------------------- +// CLbsLocationResolver::NewL +// (other items were commented in a header). +//---------------------------------------------------------------- +EXPORT_C CLbsLocationResolver* CLbsLocationResolver::NewL( + MLbsLocationResolverObserver& aObserver, + const TUid aConverterModuleId ) + { + CLbsLocationResolver* self = new( ELeave ) CLbsLocationResolver; + CleanupStack::PushL( self ); + self->ConstructL( aObserver,aConverterModuleId ); + CleanupStack::Pop( self ); + return self; + } + +//---------------------------------------------------------------- +// CLbsLocationResolver::NewL +// (other items were commented in a header). +//---------------------------------------------------------------- +EXPORT_C CLbsLocationResolver* CLbsLocationResolver::NewL( + MLbsLocationResolverObserver& aObserver ) + { + CLbsLocationResolver* self = new( ELeave ) CLbsLocationResolver; + CleanupStack::PushL( self ); + self->ConstructL( aObserver,TUid::Uid( KNullUidValue ) ); + CleanupStack::Pop( self ); + return self; + } + +//---------------------------------------------------------------- +// CLbsLocationResolver::~CLbsLocationResolver +// (other items were commented in a header). +//---------------------------------------------------------------- +EXPORT_C CLbsLocationResolver::~CLbsLocationResolver() + { + delete iLocationResolverImpl; + iLocationResolverImpl = NULL; + } + +//---------------------------------------------------------------- +// CLbsLocationResolver::ResolveLocationL +// (other items were commented in a header). +//---------------------------------------------------------------- +EXPORT_C void CLbsLocationResolver::ResolveLocationL(const CLbsLocationInfo& aLocationInfo) + { + iLocationResolverImpl->ResolveLocationL(aLocationInfo); + } + + +//---------------------------------------------------------------- +// CLbsLocationResolverImpl::SetConversionPreferences +// (other items were commented in a header). +//---------------------------------------------------------------- +EXPORT_C TInt CLbsLocationResolver::SetConversionPreferences(TLbsConversionPrefs aConversionPrefs) + { + return iLocationResolverImpl->SetConversionPreferences(aConversionPrefs); + } + +//---------------------------------------------------------------- +// CLbsLocationResolverImpl::GetConversionPref +// (other items were commented in a header). +//---------------------------------------------------------------- +EXPORT_C TLbsConversionPrefs CLbsLocationResolver::ConversionPreferences() + { + return iLocationResolverImpl->ConversionPreferences(); + } + +//---------------------------------------------------------------- +// CLbsLocationResolver::CancelResolveLocation +// (other items were commented in a header). +//---------------------------------------------------------------- +EXPORT_C void CLbsLocationResolver::CancelResolveLocation() + { + iLocationResolverImpl->CancelResolveLocation(); + } + +//---------------------------------------------------------------- +// CLbsLocationResolver::ConstructL +// (other items were commented in a header). +//---------------------------------------------------------------- +void CLbsLocationResolver::ConstructL( + MLbsLocationResolverObserver& aObserver, + const TUid aConverterModuleId ) + { + iLocationResolverImpl = CLbsLocationResolverImpl::NewL( + aObserver,aConverterModuleId ); + } + +//---------------------------------------------------------------- +// CLbsLocationResolver::CLbsLocationResolver +// (other items were commented in a header). +//---------------------------------------------------------------- +CLbsLocationResolver::CLbsLocationResolver() + { + + } diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/ConversionApi/ConversionClientApi/src/lbslocationresolverimpl.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/ConversionApi/ConversionClientApi/src/lbslocationresolverimpl.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,235 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Implementation of CLbsLocationResolverImpl class. +* +*/ + +#include +#include "lbslocationresolverimpl.h" +#include + + +void CleanUpAreaInfoArray(TAny* aArray) + { + static_cast(aArray)->ResetAndDestroy(); + } + +//---------------------------------------------------------------- +// CLbsLocationResolverImpl::NewL +// (other items were commented in a header). +//---------------------------------------------------------------- +CLbsLocationResolverImpl* CLbsLocationResolverImpl::NewL( + MLbsLocationResolverObserver& aObserver, + const TUid aConverterModuleId ) + { + CLbsLocationResolverImpl* self = new( ELeave ) CLbsLocationResolverImpl( + aObserver ); + CleanupStack::PushL( self ); + self->ConstructL( aConverterModuleId ); + CleanupStack::Pop( self ); + return self; + } + + +//---------------------------------------------------------------- +// CLbsLocationResolverImpl::~CLbsLocationResolverImpl +// (other items were commented in a header). +//---------------------------------------------------------------- +CLbsLocationResolverImpl::~CLbsLocationResolverImpl() + { + if(iLocationInfo) + { + delete iLocationInfo; + iLocationInfo = NULL; + } + iLocInfoConverter.Close(); + iLocMoniterSession.Close(); + } + +//---------------------------------------------------------------- +// CLbsLocationResolverImpl::CLbsLocationResolverImpl +// (other items were commented in a header). +//---------------------------------------------------------------- +CLbsLocationResolverImpl::CLbsLocationResolverImpl( + MLbsLocationResolverObserver& aObserver): + CActive(EPriorityStandard), + iObserver(aObserver) + { + CActiveScheduler::Add( this ); + } + +//---------------------------------------------------------------- +// CLbsLocationResolverImpl::ConstructL +// (other items were commented in a header). +//---------------------------------------------------------------- +void CLbsLocationResolverImpl::ConstructL( const TUid aConverterModuleId ) + { + iConversionModuleId = aConverterModuleId; + User::LeaveIfError( iLocMoniterSession.Connect() ); + iLocInfoConverter.OpenL( iLocMoniterSession ); + } + +//---------------------------------------------------------------- +// CLbsLocationResolverImpl::ConvertLocationInfoL +// (other items were commented in a header). +//---------------------------------------------------------------- +void CLbsLocationResolverImpl::ResolveLocationL(const CLbsLocationInfoBase& aLocationInfo) + { + if(IsActive()) + { + User::Leave(KErrInUse); + } + + CBufFlat* buffer = CBufFlat::NewL(512); + CleanupStack::PushL(buffer); + RBufWriteStream writeStream; + writeStream.Open(*buffer); + CleanupClosePushL(writeStream); + + + aLocationInfo.ExternaliseL(writeStream); + writeStream.CommitL(); + + RBufReadStream readStream(*buffer); + CleanupClosePushL(readStream); + iLocationInfo = CLbsLocationInfo::NewL(); + iLocationInfo->InternaliseL(readStream); + + iLocInfoConverter.ConvertLocationInfoL(*iLocationInfo, iConversionPrefs, + ELbsConversionOutputPosition, + iConversionModuleId, iStatus); + CleanupStack::PopAndDestroy(&readStream); + CleanupStack::PopAndDestroy(&writeStream); + CleanupStack::PopAndDestroy(buffer); + + SetActive(); + } + + + +//---------------------------------------------------------------- +// CLbsLocationResolverImpl::CancelConvertLocationInfoL +// (other items were commented in a header). +//-------;--------------------------------------------------------- +void CLbsLocationResolverImpl::CancelResolveLocation() + { + Cancel(); + } + +//---------------------------------------------------------------- +// CLbsLocationResolverImpl::RunL +// (other items were commented in a header). +//---------------------------------------------------------------- +void CLbsLocationResolverImpl::RunL() + { + TLocality result; + + if(iStatus.Int() == KErrNone) + { + if(iLocationInfo) + { + RLbsAreaInfoBaseArray areaInfoArray; + CleanupStack::PushL(TCleanupItem(*CleanUpAreaInfoArray, &areaInfoArray )); + iLocationInfo->GetAreaInfoL(areaInfoArray, CLbsLocationInfo::ELbsPosInfo); + TInt count = areaInfoArray.Count(); + if(count >0) + { + CLbsPositionInfo* posInfo = static_cast(areaInfoArray[0]); + posInfo->GetLocality(result); + } + else + { + iObserver.OnResolveLocationComplete(KErrGeneral, result); + } + CleanupStack::PopAndDestroy( &areaInfoArray ); + delete iLocationInfo; + iLocationInfo = NULL; + } + } + if(iStatus.Int() != KErrCancel) + { + iObserver.OnResolveLocationComplete(iStatus.Int(), result); + } + } + +//---------------------------------------------------------------- +// CLbsLocationResolverImpl::DoCancel +// (other items were commented in a header). +//---------------------------------------------------------------- +void CLbsLocationResolverImpl::DoCancel() + { + iLocInfoConverter.CancelConvertLocationInfo(); + if(iLocationInfo) + { + delete iLocationInfo; + iLocationInfo = NULL; + } + } + + +//---------------------------------------------------------------- +// CLbsLocationResolverImpl::SetConversionPreferences +// (other items were commented in a header). +//---------------------------------------------------------------- +TInt CLbsLocationResolverImpl::SetConversionPreferences(TLbsConversionPrefs aConversionPrefs) + { + TInt retVal = KErrNone; + //The acceptable values for the TLbsConversionPrefs Enums are such that only one of the 32 bits is set + //and bit combinations are not permitted. + TLbsConversionPrefs copyConvPrefs = aConversionPrefs; + TUint bitCount = 0; + for (TUint count = 1; count <= 32; count++) + { + //Check if the LeastSignificantBit is set to 1 + if ( (copyConvPrefs) & (1) ) + { + bitCount++; + if (bitCount > 1) + { + break; + } + } + copyConvPrefs = (copyConvPrefs >> 1); + if (copyConvPrefs == 0) + { + break; + } + } + + //Check if only one of the 32 bits is set in aConversionPref + if (bitCount == 1) + { + iConversionPrefs = aConversionPrefs; + } + else + { + retVal = KErrArgument; + } + + return retVal; + } + +//---------------------------------------------------------------- +// CLbsLocationResolverImpl::ConversionPreferences +// (other items were commented in a header). +//---------------------------------------------------------------- + TLbsConversionPrefs CLbsLocationResolverImpl::ConversionPreferences() + { + return iConversionPrefs; + } + + + +// End of file + diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/ConversionApi/ConversionCommon/group/bld.inf --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/ConversionApi/ConversionCommon/group/bld.inf Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,18 @@ +// Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +// All rights reserved. +// This component and the accompanying materials are made available +// under the terms of "Eclipse Public License v1.0" +// which accompanies this distribution, and is available +// at the URL "http://www.eclipse.org/legal/epl-v10.html". +// +// Initial Contributors: +// Nokia Corporation - initial contribution. +// +// Contributors: +// +// Description: +// + + +PRJ_EXPORTS +../inc/lbslocationinfoconvertercommon.h SYMBIAN_OS_LAYER_PLATFORM_EXPORT_PATH(lbs/lbslocationinfoconvertercommon.h) diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/ConversionApi/ConversionCommon/inc/lbslocationinfoconvertercommon.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/ConversionApi/ConversionCommon/inc/lbslocationinfoconvertercommon.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,122 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Common enumerations used by client applications and plugins +* for conversion of location information. +* +*/ + +/** +@file +@publishedPartner +@prototype +*/ + +#ifndef LBS_LOCATION_INFO_CONVERTER_COMMON_H +#define LBS_LOCATION_INFO_CONVERTER_COMMON_H + +#include + +/** + * Conversion preferences + */ +typedef TUint32 TLbsConversionPrefs; + + +/** + * Enumeration to define the preferences a client can specify while requesting + * location information. The conversion preferences enumeration shall not be + * used as a bitmask. + * The preferences are used by conversion module in order to decide if/how + * a connection to an external server should be established. + */ +enum _TLbsConversionPrefs + { + + /** + * Indicates that no preferences are specified. + */ + ELbsConversionNotDefined = 0x0000, + + /** + * Use only local cache to retrieve information. + */ + ELbsConversionCacheOnly = 0x0001, + + /** + * Disable prompt while making a connection to an external service for + * conversion. + * Ignored if a conversion module does not require external connection. + */ + ELbsConversionSilent = 0x0002, + + /** + * Allow prompt while making a connection to an external service for + * conversion. + * * Ignored if a conversion module does not require external connection. + */ + ELbsConversionPrompt = 0x0004, + + /** + * + * Allow Wlan Only to make a connection only using W-Lan. + * + */ + ELbsWlanOnly = 0x0008 + + }; + + +/** + * Output Location Information + */ +typedef TUint32 TLbsConversionOutputInfoMask; + + +/** + * Enumeration to define the type(s) of location information being communicated + */ +enum _TLbsConversionOutputInfoMask + { + + /** + * Used to initialise data only. Should not be used when requesting conversions. + */ + ELbsConversionOutputNotDefined = 0x0000, + + /** + * Indicates that the input data should be converted to a geographical coordinate + * @see CLbsPositionInfo + */ + ELbsConversionOutputPosition = 0x0001, + + /** + * Indicates that the input data should be converted to a GSM Cell information + * @see CLbsGsmCellInfo + */ + ELbsConversionOutputGsm = 0x0002, + + /** + * Indicates that the input data should be converted to a WCDMA Cell information + * @see CLbsWcdmaCellInfo + */ + ELbsConversionOutputWcdma = 0x0004, + + /** + * Indicates that the input data should be converted to a WLAN information + * @see CLbsWlanInfo + */ + ELbsConversionOutputWlan = 0x0008 + }; + +#endif // LBS_LOCATION_INFO_CONVERTER_COMMON_H diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/ConversionApi/ConversionPluginApi/BWINS/lbslocationinfoconverterpluginu.def --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/ConversionApi/ConversionPluginApi/BWINS/lbslocationinfoconverterpluginu.def Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,18 @@ +EXPORTS + ?ExtendedInterface@MLbsLocInfoConverterPluginObserver@@EAEPAXHPAX0@Z @ 1 NONAME ; void * MLbsLocInfoConverterPluginObserver::ExtendedInterface(int, void *, void *) + ?NewL@CLbsLocInfoConverterPluginBase@@SAPAV1@VTUid@@AAVTLbsLocInfoConverterPluginParams@@@Z @ 2 NONAME ; class CLbsLocInfoConverterPluginBase * CLbsLocInfoConverterPluginBase::NewL(class TUid, class TLbsLocInfoConverterPluginParams &) + ?ClassType@TLbsLocInfoConverterPluginClassTypeBase@@QBEKXZ @ 3 NONAME ; unsigned long TLbsLocInfoConverterPluginClassTypeBase::ClassType(void) const + ??0TLbsLocInfoConverterPluginClassTypeBase@@IAE@XZ @ 4 NONAME ; TLbsLocInfoConverterPluginClassTypeBase::TLbsLocInfoConverterPluginClassTypeBase(void) + ?Observer@TLbsLocInfoConverterPluginParams@@QBEAAVMLbsLocInfoConverterPluginObserver@@XZ @ 5 NONAME ; class MLbsLocInfoConverterPluginObserver & TLbsLocInfoConverterPluginParams::Observer(void) const + ?Version@CLbsLocInfoConverterPluginBase@@UBE?AVTVersion@@XZ @ 6 NONAME ; class TVersion CLbsLocInfoConverterPluginBase::Version(void) const + ??1CLbsLocInfoConverterPluginBase@@UAE@XZ @ 7 NONAME ; CLbsLocInfoConverterPluginBase::~CLbsLocInfoConverterPluginBase(void) + ??0TLbsLocInfoConverterPluginParams@@QAE@AAVMLbsLocInfoConverterPluginObserver@@@Z @ 8 NONAME ; TLbsLocInfoConverterPluginParams::TLbsLocInfoConverterPluginParams(class MLbsLocInfoConverterPluginObserver &) + ?ClassSize@TLbsLocInfoConverterPluginClassTypeBase@@QBEIXZ @ 9 NONAME ; unsigned int TLbsLocInfoConverterPluginClassTypeBase::ClassSize(void) const + ?ExtendedInterface@CLbsLocInfoConverterPluginBase@@UAEPAXHPAX0@Z @ 10 NONAME ; void * CLbsLocInfoConverterPluginBase::ExtendedInterface(int, void *, void *) + ?Version@MLbsLocInfoConverterPluginObserver@@UBE?AVTVersion@@XZ @ 11 NONAME ; class TVersion MLbsLocInfoConverterPluginObserver::Version(void) const + ?IsPluginPositionToBeCached@TLbsConversionPluginInfo@@QBEHXZ @ 12 NONAME ; int TLbsConversionPluginInfo::IsPluginPositionToBeCached(void) const + ??0TLbsConversionPluginInfo@@QAE@XZ @ 13 NONAME ; TLbsConversionPluginInfo::TLbsConversionPluginInfo(void) + ?SetPluginCapabilitiesMask@TLbsConversionPluginInfo@@QAEXK@Z @ 14 NONAME ; void TLbsConversionPluginInfo::SetPluginCapabilitiesMask(unsigned long) + ?SetIsPluginPositionToBeCached@TLbsConversionPluginInfo@@QAEXH@Z @ 15 NONAME ; void TLbsConversionPluginInfo::SetIsPluginPositionToBeCached(int) + ?PluginCapabilitiesMask@TLbsConversionPluginInfo@@QBEKXZ @ 16 NONAME ; unsigned long TLbsConversionPluginInfo::PluginCapabilitiesMask(void) const + diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/ConversionApi/ConversionPluginApi/EABI/lbslocationinfoconverterpluginu.def --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/ConversionApi/ConversionPluginApi/EABI/lbslocationinfoconverterpluginu.def Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,27 @@ +EXPORTS + _ZN30CLbsLocInfoConverterPluginBase17ExtendedInterfaceEiPvS0_ @ 1 NONAME + _ZN30CLbsLocInfoConverterPluginBase4NewLE4TUidR32TLbsLocInfoConverterPluginParams @ 2 NONAME + _ZN30CLbsLocInfoConverterPluginBaseD0Ev @ 3 NONAME + _ZN30CLbsLocInfoConverterPluginBaseD1Ev @ 4 NONAME + _ZN30CLbsLocInfoConverterPluginBaseD2Ev @ 5 NONAME + _ZN32TLbsLocInfoConverterPluginParamsC1ER34MLbsLocInfoConverterPluginObserver @ 6 NONAME + _ZN32TLbsLocInfoConverterPluginParamsC2ER34MLbsLocInfoConverterPluginObserver @ 7 NONAME + _ZN34MLbsLocInfoConverterPluginObserver17ExtendedInterfaceEiPvS0_ @ 8 NONAME + _ZN39TLbsLocInfoConverterPluginClassTypeBaseC1Ev @ 9 NONAME + _ZN39TLbsLocInfoConverterPluginClassTypeBaseC2Ev @ 10 NONAME + _ZNK30CLbsLocInfoConverterPluginBase7VersionEv @ 11 NONAME + _ZNK32TLbsLocInfoConverterPluginParams8ObserverEv @ 12 NONAME + _ZNK34MLbsLocInfoConverterPluginObserver7VersionEv @ 13 NONAME + _ZNK39TLbsLocInfoConverterPluginClassTypeBase9ClassSizeEv @ 14 NONAME + _ZNK39TLbsLocInfoConverterPluginClassTypeBase9ClassTypeEv @ 15 NONAME + _ZTI30CLbsLocInfoConverterPluginBase @ 16 NONAME + _ZTI34MLbsLocInfoConverterPluginObserver @ 17 NONAME + _ZTV30CLbsLocInfoConverterPluginBase @ 18 NONAME + _ZTV34MLbsLocInfoConverterPluginObserver @ 19 NONAME + _ZN24TLbsConversionPluginInfo25SetPluginCapabilitiesMaskEm @ 20 NONAME + _ZN24TLbsConversionPluginInfo29SetIsPluginPositionToBeCachedEi @ 21 NONAME + _ZN24TLbsConversionPluginInfoC1Ev @ 22 NONAME + _ZN24TLbsConversionPluginInfoC2Ev @ 23 NONAME + _ZNK24TLbsConversionPluginInfo22PluginCapabilitiesMaskEv @ 24 NONAME + _ZNK24TLbsConversionPluginInfo26IsPluginPositionToBeCachedEv @ 25 NONAME + diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/ConversionApi/ConversionPluginApi/group/bld.inf --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/ConversionApi/ConversionPluginApi/group/bld.inf Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,27 @@ +// Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +// All rights reserved. +// This component and the accompanying materials are made available +// under the terms of "Eclipse Public License v1.0" +// which accompanies this distribution, and is available +// at the URL "http://www.eclipse.org/legal/epl-v10.html". +// +// Initial Contributors: +// Nokia Corporation - initial contribution. +// +// Contributors: +// +// Description: +// + + +PRJ_EXPORTS +../inc/lbslocinfoconverterpluginbase.h SYMBIAN_OS_LAYER_PLATFORM_EXPORT_PATH(lbs/lbslocinfoconverterpluginbase.h) +../inc/lbslocinfoconverterpluginclasstypes.h SYMBIAN_OS_LAYER_PLATFORM_EXPORT_PATH(lbs/lbslocinfoconverterpluginclasstypes.h) +../inc/lbslocinfoconverterplugincommon.h SYMBIAN_OS_LAYER_PLATFORM_EXPORT_PATH(lbs/lbslocinfoconverterplugincommon.h) +../inc/lbslocinfoconverterpluginbase.hrh SYMBIAN_OS_LAYER_PLATFORM_EXPORT_PATH(lbs/lbslocinfoconverterpluginbase.hrh) + +lbslocationinfoconverterplugin.iby /epoc32/rom/include/lbslocationinfoconverterplugin.iby + + +PRJ_MMPFILES +lbslocationinfoconverterplugin.mmp diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/ConversionApi/ConversionPluginApi/group/lbslocationinfoconverterplugin.iby --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/ConversionApi/ConversionPluginApi/group/lbslocationinfoconverterplugin.iby Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,26 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ +//#ifndef __LBS_LOCATIONINFOCONVERTERPLUGIN_IBY__ +#define __LBS_LOCATIONINFOCONVERTERPLUGIN_IBY__ +//#if !defined(SYMBIAN_EXCLUDE_LOCATION) + +file=ABI_DIR\DEBUG_DIR\lbslocationinfoconverterplugin.dll sys\bin\lbslocationinfoconverterplugin.dll + + +//#endif // SYMBIAN_EXCLUDE_LOCATION + +//#endif //__LBS_LOCATIONINFOCONVERTERPLUGIN_IBY__ diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/ConversionApi/ConversionPluginApi/group/lbslocationinfoconverterplugin.mmp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/ConversionApi/ConversionPluginApi/group/lbslocationinfoconverterplugin.mmp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,36 @@ +// Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +// All rights reserved. +// This component and the accompanying materials are made available +// under the terms of "Eclipse Public License v1.0" +// which accompanies this distribution, and is available +// at the URL "http://www.eclipse.org/legal/epl-v10.html". +// +// Initial Contributors: +// Nokia Corporation - initial contribution. +// +// Contributors: +// +// Description: +// + + +TARGET lbslocationinfoconverterplugin.dll +TARGETTYPE dll +UID 0x1000008d 0x102871FA + +VENDORID 0x70000001 +CAPABILITY ALL -TCB + +SOURCEPATH ../src +SOURCE lbslocinfoconverterpluginbase.cpp +SOURCE lbslocinfoconverterplugincommon.cpp + +USERINCLUDE ../inc +OS_LAYER_SYSTEMINCLUDE_SYMBIAN + +LIBRARY euser.lib +LIBRARY ecom.lib +LIBRARY lbslocationinfodatatypes.lib + +SMPSAFE + diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/ConversionApi/ConversionPluginApi/inc/lbslocinfoconverterpluginbase.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/ConversionApi/ConversionPluginApi/inc/lbslocinfoconverterpluginbase.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,303 @@ +/* +* Copyright (c) 2008 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Location information converter plug in API +* +*/ + + +/** +* @file +* @publishedPartner +* @prototype +*/ + + +#ifndef LBS_LOC_INFO_CONVERSION_PLUGIN_BASE_H +#define LBS_LOC_INFO_CONVERSION_PLUGIN_BASE_H + + +// System wide +#include + +// Common LBS data types +#include +#include + +// Component specific +#include +#include + + +class TLbsLocInfoConverterPluginParams; + + +/** +* The MLbsLocInfoConverterPluginObserver class is used in partnership with +* CLbsLocInfoConverterPluginBase. The observer interface is used by a +* conversion plugin to inform LBS when a coordinate conversion process +* initiated through the CLbsLocInfoConverterPluginBase class is completed. +* +* Although all the interface methods in the MLbsLocInfoConverterPluginObserver +* class are synchronous, the LBS subsystem ensures they return quickly. +*/ +class MLbsLocInfoConverterPluginObserver + { + +public: + + /** + * Gets the current version of the observer interface. + * Derived classes should not change the implementation. + * + * @return Version number (currently 1.0.0) + */ + IMPORT_C virtual TVersion Version() const; + + /** + * The callback is used by the conversion plugin to inform the LBS + * subsystem that a validation request initiated through the + * CLbsLocInfoConverterPluginBase::ValidateClient method is completed. + * + * @param aStatusCode Result of the validation operation. + * KErrNone if the access is granted. + * KErrPermissionDenied due to a potential security violation. + * Other system wide error codes. + */ + IMPORT_C virtual void OnValidationComplete( TInt aStatusCode ) = 0; + + /** + * The callback is used by the conversion plugin to inform the LBS + * subsystem that a coordinate conversion process initiated through the + * CLbsLocInfoConverterPluginBase::ConvertLocationInfoL method is + * completed. + * + * Receiving the callback indicates that, unless the conversion was not + * successful, the location data structures passed through the + * CLbsLocInfoConverterPluginBase::ConvertLocationInfoL method have been + * updated with the requested information. + * + * @param aStatusCode Result of the conversion operation. + * KErrNone if at least one conversion have been successful and + * the related location data structure(s) passed through the + * CLbsLocInfoConverterPluginBase::ConvertLocationInfoL method + * have been updated with the requested information; + * KErrKErrNotFound if none of conversions have been successful + * Or other system wide error code otherwise. + */ + IMPORT_C virtual void OnConversionComplete( TInt aStatusCode ) = 0; + +private: + + /** + * This methods is reserved for future expansion and should not be used or + * implemented by derived classes. + */ + IMPORT_C virtual TAny* ExtendedInterface( TInt aFunctionNumber, + TAny* aPtr1, + TAny* aPtr2 ); + + }; + + +/** +* The CLbsLocInfoConverterPluginBase is the abstract Ecom interface to a +* coordinate conversion Plugin. All coordinate conversion Plugins must derive +* from and implement this interface. +* +* The interface is used in partnership with MLbsLocInfoConverterPluginObserver +* and is used by the LBS subsystem to request conversion of location +* information between different formats. +* +* Completion of conversions must be indicated by a plugin by invoking +* callback(s) defined by the MLbsLocInfoConverterPluginObserver class. +* +* Although all the interface methods in the class are synchronous they must +* return immediately. When the LBS subsystem makes a request via +* CLbsLocInfoConverterPluginBase the Plugin must queue the request internally +* and return control to the caller immediately. Later on, when plugin provides +* a response, it uses the corresponding notification method in the +* MLbsLocInfoConverterPluginObserver class. +*/ +class CLbsLocInfoConverterPluginBase : public CBase + { + +public: + + /** + * Loads a coordinate conversion Plugin and initalises it. + * + * @param[in] aImplementationUid An implementation Uid of the module to be + * loaded. + * @param[in] aParams Arguments sent to conversion plugin. + * + * @return Pointer to the new coordinate conversion plugin. + */ + IMPORT_C static CLbsLocInfoConverterPluginBase* NewL( + TUid aImplementationUid, + TLbsLocInfoConverterPluginParams& aParams ); + + /** + * Destructor + */ + IMPORT_C virtual ~CLbsLocInfoConverterPluginBase(); + + /** + * Gets the current version of the interface implemented by a Plugin. + * Derived classes should not change the implementation. + * + * @return Version number (currently 1.0.0) + */ + IMPORT_C virtual TVersion Version() const; + + /** + * Validates a client before a request is processed. This method is called + * by the Location Monitor Server, everytime, before a conversion request is + * sent. + * The result of validation is indicated by the plugin by invoking the + * MLbsLocInfoConverterPluginObserver::OnValidationComplete callback. + * + * @param[in] aSecureId The secure ID of the client application/process + * @param[in] aVendorId The vendor ID of the client application/process + * @param{in] aRequestedInfo The requested converted information. This + * bit field would be checked by the plugin to determine if the specified + * conversion can be supported for the requesting client. + */ + IMPORT_C virtual void ValidateClient( const TSecureId& aSecureId, + const TVendorId& aVendorId, + const TLbsConversionOutputInfoMask aRequestedInfo) = 0; + + /** + * Cancels an ongoing validation operation. + * If there is no ongoing validation operation, the cancellation request + * is ignored. + * + * The MLbsLocInfoConverterPluginObserver::OnValidationComplete callback is + * not invoked. + */ + IMPORT_C virtual void CancelValidateClient() = 0; + + /** + * Converts multiple location information. + * + * Completion of the conversion is indicated by a Plugin by invoking the + * MLbsLocInfoConverterPluginObserver::OnConversionComplete callback + * + * @param[in] aLocationInfo An array of location information for which + * corresponding position information is expected. + * @param[in] aConversionPrefs Conversion preferences suggested by client + * @param[in] aRequestedInfo Location information that is requested. + + * @leave KErrNoMemory if there is not enough memory available to perform + * the conversion. + * KErrArgument If the location info pointer is NULL. + * KErrNotSupported if the conversion type specified by aRequestedInfo is + * not supported. + * Or any other system wide error code. + */ + IMPORT_C virtual void ConvertLocationInfoL( + RLbsLocationInfoArray& aLocationInfoArray, + const TLbsConversionPrefs aConversionPrefs, + const TLbsConversionOutputInfoMask aRequestedInfo ) = 0; + + /** + * Cancels an ongoing conversion operation. + * If there is no ongoing conversion the cancellation request is ignored. + * + * The MLbsLocInfoConverterPluginObserver::OnConversionComplete callback is + * not invoked. + */ + IMPORT_C virtual void CancelConvertLocationInfo() = 0; + + + /** + * This method is used to read the conversion plugin's preferences such as + * its capability to use wlan/gsm/wcdma/pos information to perform the requested conversion + * or whether position that it returns after conversion should be retained in the cache. + */ + IMPORT_C virtual void ConversionPluginPreferences( + TLbsConversionPluginInfo& aPluginInfo ) = 0; + + /** + * This method is reserved for future expansion and should not be used + * or implemented by derived classes. + */ + IMPORT_C virtual TAny* ExtendedInterface( TInt aFunctionNumber, + TAny* aPtr1, + TAny* aPtr2 ); + +private: // data + + /** + * Instance identifier key. When instance of an implementation is + * created by ECOM framework, the framework will assign UID + * for it. The UID is used in destructor to notify framework that + * this instance is being destroyed and resources can be released. + */ + TUid iDtor_ID_Key; + + }; + + +/** +* This class encapsulates the construction parameters for a Coordinate +* Conversion plugin. +* +* These parameters are passed by the LBS subsystem to the implementation +* of the Plugin module via ECom. The ECom constructor +* should take a single TAny* parameter. That parameter should be cast to +* a variable of type TLbsLocInfoConverterPluginParams. +* +* @see CLbsLocInfoConverterPluginBase::NewL +*/ +class TLbsLocInfoConverterPluginParams : public TLbsLocInfoConverterPluginClassTypeBase + { + +public: + + /** + * This class encapsulates the construction parameters for a Coordinate + * Conversion plugin implementation. + * + * When created, the LBS subsystem must provide a reference to the + * plugin's observer. + * + * @see MLbsLocInfoConverterPluginObserver + * @see CLbsLocInfoConverterPluginBase::NewL + */ + IMPORT_C TLbsLocInfoConverterPluginParams( + MLbsLocInfoConverterPluginObserver& aObserver ); + + /** + * Returns a reference to the observer. + * + * @see MLbsLocInfoConverterPluginObserver + * @see CLbsLocInfoConverterPluginBase::NewL + */ + IMPORT_C MLbsLocInfoConverterPluginObserver& Observer() const; + +protected: + + /** + * Handle to the plugin observer + */ + MLbsLocInfoConverterPluginObserver& iObserver; + + /** + * Reserved for future use + */ + TUint8 iReserved[20]; + + }; + +#endif // LBS_LOC_INFO_CONVERSION_PLUGIN_BASE_H diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/ConversionApi/ConversionPluginApi/inc/lbslocinfoconverterpluginbase.hrh --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/ConversionApi/ConversionPluginApi/inc/lbslocinfoconverterpluginbase.hrh Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,33 @@ +/* +* Copyright (c) 2008 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Resource headers for project +* +*/ + + +/** +* @file +* @publishedPartner +* @prototype +*/ + + +#ifndef LBSLOCINFOCONVERTERPLUGINBASE_HRH +#define LBSLOCINFOCONVERTERPLUGINBASE_HRH + +// ECom interface ID for Location information converter Plugin API +#define KLbsLocInfoConverterPlugInInterfaceId (0x10287201) + + +#endif // LBSLOCINFOCONVERTERPLUGINBASE_HRH diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/ConversionApi/ConversionPluginApi/inc/lbslocinfoconverterpluginclasstypes.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/ConversionApi/ConversionPluginApi/inc/lbslocinfoconverterpluginclasstypes.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,51 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Common enumerations used by client applications and plugins +* for conversion of location information. +* +*/ + +/** +@file +@publishedPartner +@prototype +*/ + + +#ifndef LBS_LOC_INFO_CONV_PLUGIN_CLASS_TYPES_H +#define LBS_LOC_INFO_CONV_PLUGIN_CLASS_TYPES_H + + +/** Type used for identifying class types */ +typedef TUint32 TLbsLocInfoConverterPluginParamsClassType; + + +/** + * Class types for TLbsLocInfoConverterPluginParams and its derived classes + */ +enum _TLbsLocInfoConverterPluginParamsClassType + { + /** Should be used for data initialisation only */ + ELbsLocInfoConverterPluginParamsUnknownClass = 0x00, + + /** Identifier for TLbsLocInfoConverterPluginParams class */ + ELbsLocInfoConverterPluginParamsClass = 0x01, + + /** Not used. */ + ELbsLocInfoConverterPluginParamsLastClass = 0xFFFFFFFF + }; + + +#endif // LBS_LOC_INFO_CONV_PLUGIN_CLASS_TYPES_H + diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/ConversionApi/ConversionPluginApi/inc/lbslocinfoconverterplugincommon.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/ConversionApi/ConversionPluginApi/inc/lbslocinfoconverterplugincommon.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,136 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Base class for all the class representing +* location informations. +* +*/ + +/** +@file +@publishedPartner +@prototype +*/ + +#ifndef LBS_LOCATION_CONVERTER_PLUGIN_COMMON_H +#define LBS_LOCATION_CONVERTER_PLUGIN_COMMON_H + +#include + + +/** +The generic base for classes that store conversion Plugin Interface +related information +*/ +class TLbsLocInfoConverterPluginClassTypeBase + { +public: + IMPORT_C TUint32 ClassType() const; + IMPORT_C TUint ClassSize() const; + +protected: + IMPORT_C TLbsLocInfoConverterPluginClassTypeBase(); + +protected: + /** The type of the derived class */ + TUint32 iClassType; + /** The size of the derived class */ + TUint iClassSize; + }; + +/** + * Conversion plugin's capabilities + */ +typedef TUint32 TLbsConversionPluginCapabilityMask; + +/** + * Enums that are used as bitmasks to define the capabilities of the conversion plugin. + */ +enum _TLbsConversionPluginCapabilityMask + { + /** + * Bitmask indicating the conversion plugin's capability has not been defined. + */ + ELbsPluginCapabilityNotDefined = 0x00, + + /** + * Bitmask indicating the conversion plugin's capability to use position information + * for the conversion. + */ + ELbsPluginCapabilityPosInfo = 0x01, + + /** + * Bitmask indicating the conversion plugin's capability to use GSM cell information + * for the conversion. + */ + ELbsPluginCapabilityGsmInfo = 0x02, + + /** + * Bitmask indicating the conversion plugin's capability to use WCDMA cell information + * for the conversion. + */ + ELbsPluginCapabilityWcdmaInfo = 0x04, + + /** + * Bitmask indicating the conversion plugin's capability to use WLAN AP information + * for the conversion. + */ + ELbsPluginCapabilityWlanInfo = 0x08, + + /** + * Bitmask indicating the conversion plugin's capability to use all area information + * for the conversion. + */ + ELbsPluginCapabilityAreaInfoAll = 0xFFFFFFFF + }; + + +/** + * Class used to read the preferences of the conversion plugin such as its capability to use + * gsm/wlan/wcdma information during conversion and whether the position that it returns is to be + * stored in the cache. + */ +class TLbsConversionPluginInfo + { +public: + IMPORT_C TLbsConversionPluginInfo(); + +public: + /** + * Read the flag indicating if the conversion result is to be cached + */ + IMPORT_C TBool IsPluginPositionToBeCached() const; + + /** + * Read the currently set capabilities + */ + IMPORT_C TLbsConversionPluginCapabilityMask PluginCapabilitiesMask() const; + + /** + * Sets the flag indicating if the conversion result returned from the plugin is + * to be cached. + */ + IMPORT_C void SetIsPluginPositionToBeCached(TBool aCachePluginPosition); + + /** + * Sets the bitmask representing the capabilities of the conversion plugin. + */ + IMPORT_C void SetPluginCapabilitiesMask(TLbsConversionPluginCapabilityMask aCapabilitiesMask); + +private: + TBool iIsPluginPositionToBeCached; + TLbsConversionPluginCapabilityMask iCapabilitiesMask; + TUint32 iReserved[8]; + }; + +#endif // LBS_LOCATION_CONVERTER_PLUGIN_COMMON_H diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/ConversionApi/ConversionPluginApi/src/lbslocinfoconverterpluginbase.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/ConversionApi/ConversionPluginApi/src/lbslocinfoconverterpluginbase.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,120 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Implentation of functions shared between all +* implementations of the LBS Network Protocol Module +* interface/ECom plugin. +* +*/ + + +#include +#include + +#include +#include + + +// --------------------------------------------------------------------------- +// MLbsLocInfoConverterPluginObserver::ExtendedInterface() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C TVersion MLbsLocInfoConverterPluginObserver::Version() const + { + return TVersion( 1, 0, 0 ); + } + +// --------------------------------------------------------------------------- +// MLbsLocInfoConverterPluginObserver::ExtendedInterface() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C TAny* MLbsLocInfoConverterPluginObserver::ExtendedInterface( + TInt /*aFunctionNumber*/, + TAny* /*aPtr1*/, + TAny* /*aPtr2*/ ) + { + return NULL; + } + +// --------------------------------------------------------------------------- +// CLbsLocInfoConverterPluginBase::NewL() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C CLbsLocInfoConverterPluginBase* CLbsLocInfoConverterPluginBase::NewL( + TUid aImplementationUid, + TLbsLocInfoConverterPluginParams& aParams ) + { + TAny* ptr = REComSession::CreateImplementationL( aImplementationUid, + _FOFF( CLbsLocInfoConverterPluginBase, iDtor_ID_Key ), + reinterpret_cast( &aParams ) ); + + return reinterpret_cast(ptr); + } + +// --------------------------------------------------------------------------- +// CLbsLocInfoConverterPluginBase::~CLbsLocInfoConverterPluginBase() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C CLbsLocInfoConverterPluginBase::~CLbsLocInfoConverterPluginBase() + { + REComSession::DestroyedImplementation( iDtor_ID_Key ); + } + +// --------------------------------------------------------------------------- +// CLbsLocInfoConverterPluginBase::Version() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C TVersion CLbsLocInfoConverterPluginBase::Version() const + { + return TVersion( 1, 0, 0 ); + } + +// --------------------------------------------------------------------------- +// CLbsLocInfoConverterPluginBase::ExtendedInterface() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C TAny* CLbsLocInfoConverterPluginBase::ExtendedInterface( + TInt /*aFunctionNumber*/, + TAny* /*aPtr1*/, + TAny* /*aPtr2*/ ) + { + return NULL; + } + +// --------------------------------------------------------------------------- +// TLbsLocInfoConverterPluginParams::TLbsLocInfoConverterPluginParams() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C TLbsLocInfoConverterPluginParams::TLbsLocInfoConverterPluginParams( + MLbsLocInfoConverterPluginObserver& aObserver ):iObserver(aObserver) + { + iClassType = ELbsLocInfoConverterPluginParamsClass; + iClassSize = sizeof(TLbsLocInfoConverterPluginParams); + } + +// --------------------------------------------------------------------------- +// TLbsLocInfoConverterPluginParams::Observer() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C MLbsLocInfoConverterPluginObserver& TLbsLocInfoConverterPluginParams::Observer() const + { + return iObserver; + } diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/ConversionApi/ConversionPluginApi/src/lbslocinfoconverterplugincommon.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/ConversionApi/ConversionPluginApi/src/lbslocinfoconverterplugincommon.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,103 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Implentation of functions shared between all +* implementations of the LBS Network Protocol Module +* interface/ECom plugin. +* +*/ + +#include +#include + + +// --------------------------------------------------------------------------- +// TLbsLocInfoConverterPluginClassTypeBase::TLbsLocInfoConverterPluginClassTypeBase() +// Default constructor for TLbsLocInfoConverterPluginClassTypeBase +// --------------------------------------------------------------------------- +// +EXPORT_C TLbsLocInfoConverterPluginClassTypeBase::TLbsLocInfoConverterPluginClassTypeBase() +: iClassType(0), + iClassSize(0) + { + } + +// --------------------------------------------------------------------------- +// TLbsLocInfoConverterPluginClassTypeBase::ClassSize() +// Returns the size of the TLbsLocInfoConverterPluginClassTypeBase-derived class +// --------------------------------------------------------------------------- +// +EXPORT_C TUint TLbsLocInfoConverterPluginClassTypeBase::ClassSize() const + { + return iClassSize; + } + +// --------------------------------------------------------------------------- +// TLbsLocInfoConverterPluginClassTypeBase::ClassType() +// Returns the type of the TLbsLocInfoConverterPluginClassTypeBase-derived class +// --------------------------------------------------------------------------- +// +EXPORT_C TUint32 TLbsLocInfoConverterPluginClassTypeBase::ClassType() const + { + return iClassType; + } + +//---------------------------------------------------------------- +// TLbsConversionPluginInfo::TLbsConversionPluginInfo +// (other items were commented in a header). +//---------------------------------------------------------------- +EXPORT_C TLbsConversionPluginInfo::TLbsConversionPluginInfo() : + iIsPluginPositionToBeCached(EFalse), + iCapabilitiesMask(ELbsPluginCapabilityNotDefined) + { + + } + +//---------------------------------------------------------------- +// TLbsConversionPluginInfo::TLbsConversionPluginInfo +// (other items were commented in a header). +//---------------------------------------------------------------- +EXPORT_C TBool TLbsConversionPluginInfo::IsPluginPositionToBeCached() const + { + return iIsPluginPositionToBeCached; + } + +//---------------------------------------------------------------- +// TLbsConversionPluginInfo::PluginCapabilitiesMask +// (other items were commented in a header). +//---------------------------------------------------------------- +EXPORT_C TLbsConversionPluginCapabilityMask TLbsConversionPluginInfo::PluginCapabilitiesMask() const + { + return iCapabilitiesMask; + } + +//---------------------------------------------------------------- +// TLbsConversionPluginInfo::SetPluginPositionToBeCached +// (other items were commented in a header). +//---------------------------------------------------------------- +EXPORT_C void TLbsConversionPluginInfo::SetIsPluginPositionToBeCached( + TBool aCachePluginPosition) + { + iIsPluginPositionToBeCached = aCachePluginPosition; + } + +//---------------------------------------------------------------- +// TLbsConversionPluginInfo::SetPluginCapabilitiesMask +// (other items were commented in a header). +//---------------------------------------------------------------- +EXPORT_C void TLbsConversionPluginInfo::SetPluginCapabilitiesMask( + TLbsConversionPluginCapabilityMask aCapabilitiesMask) + { + iCapabilitiesMask = aCapabilitiesMask; + } + diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/ConversionDataTypes/BWINS/lbslocationinfodatatypesu.def --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/ConversionDataTypes/BWINS/lbslocationinfodatatypesu.def Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,85 @@ +EXPORTS + ??1CLbsLocationInfo@@UAE@XZ @ 1 NONAME ; CLbsLocationInfo::~CLbsLocationInfo(void) + ?SetMobileNetworkCode@CLbsWcdmaCellInfo@@QAEXH@Z @ 2 NONAME ; void CLbsWcdmaCellInfo::SetMobileNetworkCode(int) + ?SetMobileCountryCode@CLbsWcdmaCellInfo@@QAEXH@Z @ 3 NONAME ; void CLbsWcdmaCellInfo::SetMobileCountryCode(int) + ??1CLbsWlanInfo@@UAE@XZ @ 4 NONAME ; CLbsWlanInfo::~CLbsWlanInfo(void) + ??1CLbsAreaInfoBase@@UAE@XZ @ 5 NONAME ; CLbsAreaInfoBase::~CLbsAreaInfoBase(void) + ?MobileCountryCode@CLbsGsmCellInfo@@QBEHXZ @ 6 NONAME ; int CLbsGsmCellInfo::MobileCountryCode(void) const + ?ScramblingCode@CLbsWcdmaCellInfo@@QBEHXZ @ 7 NONAME ; int CLbsWcdmaCellInfo::ScramblingCode(void) const + ?Bsic@TLbsGsmNeighbourCellInfo@@QBEHXZ @ 8 NONAME ; int TLbsGsmNeighbourCellInfo::Bsic(void) const + ?AddNeighbouringCellInfoL@CLbsGsmCellInfo@@QAEXPAVTLbsGsmNeighbourCellInfo@@@Z @ 9 NONAME ; void CLbsGsmCellInfo::AddNeighbouringCellInfoL(class TLbsGsmNeighbourCellInfo *) + ?SetCellId@CLbsGsmCellInfo@@QAEXH@Z @ 10 NONAME ; void CLbsGsmCellInfo::SetCellId(int) + ?ScramblingCode@TLbsWcdmaNeighbourCellInfo@@QBEHXZ @ 11 NONAME ; int TLbsWcdmaNeighbourCellInfo::ScramblingCode(void) const + ?Pathloss@TLbsWcdmaNeighbourCellInfo@@QBEHXZ @ 12 NONAME ; int TLbsWcdmaNeighbourCellInfo::Pathloss(void) const + ?GetMacAddress@CLbsWlanInfo@@QBEXAAVTDes8@@@Z @ 13 NONAME ; void CLbsWlanInfo::GetMacAddress(class TDes8 &) const + ?NewL@CLbsWcdmaCellInfo@@SAPAV1@XZ @ 14 NONAME ; class CLbsWcdmaCellInfo * CLbsWcdmaCellInfo::NewL(void) + ?SetUniqueCellId@CLbsWcdmaCellInfo@@QAEXH@Z @ 15 NONAME ; void CLbsWcdmaCellInfo::SetUniqueCellId(int) + ?SetSignalStrength@CLbsWlanInfo@@QAEXH@Z @ 16 NONAME ; void CLbsWlanInfo::SetSignalStrength(int) + ?AddNeighbouringCellInfoL@CLbsWcdmaCellInfo@@QAEXPAVTLbsWcdmaNeighbourCellInfo@@@Z @ 17 NONAME ; void CLbsWcdmaCellInfo::AddNeighbouringCellInfoL(class TLbsWcdmaNeighbourCellInfo *) + ?NewL@CLbsLocationInfo@@SAPAV1@XZ @ 18 NONAME ; class CLbsLocationInfo * CLbsLocationInfo::NewL(void) + ?GetNeighbouringCellInfoL@CLbsWcdmaCellInfo@@QBEXAAV?$RArray@VTLbsWcdmaNeighbourCellInfo@@@@@Z @ 19 NONAME ; void CLbsWcdmaCellInfo::GetNeighbouringCellInfoL(class RArray &) const + ?GetAreaInfoL@CLbsLocationInfo@@QAEXAAV?$RPointerArray@VCLbsAreaInfoBase@@@@K@Z @ 20 NONAME ; void CLbsLocationInfo::GetAreaInfoL(class RPointerArray &, unsigned long) + ??0TLbsWcdmaNeighbourCellInfo@@QAE@HHHH@Z @ 21 NONAME ; TLbsWcdmaNeighbourCellInfo::TLbsWcdmaNeighbourCellInfo(int, int, int, int) + ?AddAreaInfoL@CLbsLocationInfo@@QAEXPAVCLbsAreaInfoBase@@@Z @ 22 NONAME ; void CLbsLocationInfo::AddAreaInfoL(class CLbsAreaInfoBase *) + ??0TLbsWcdmaNeighbourCellInfo@@QAE@XZ @ 23 NONAME ; TLbsWcdmaNeighbourCellInfo::TLbsWcdmaNeighbourCellInfo(void) + ?NewL@CLbsGsmCellInfo@@SAPAV1@HHHH@Z @ 24 NONAME ; class CLbsGsmCellInfo * CLbsGsmCellInfo::NewL(int, int, int, int) + ?Type@CLbsLocationInfoBase@@UAEKXZ @ 25 NONAME ; unsigned long CLbsLocationInfoBase::Type(void) + ?SetMacAddress@CLbsWlanInfo@@QAEXABVTDesC8@@@Z @ 26 NONAME ; void CLbsWlanInfo::SetMacAddress(class TDesC8 const &) + ?NewLC@CLbsLocationInfo@@SAPAV1@XZ @ 27 NONAME ; class CLbsLocationInfo * CLbsLocationInfo::NewLC(void) + ?SetRxLevel@TLbsGsmNeighbourCellInfo@@QAEXH@Z @ 28 NONAME ; void TLbsGsmNeighbourCellInfo::SetRxLevel(int) + ?ExternaliseL@CLbsLocationInfoBase@@QBEXAAVRWriteStream@@@Z @ 29 NONAME ; void CLbsLocationInfoBase::ExternaliseL(class RWriteStream &) const + ??1CLbsWcdmaCellInfo@@UAE@XZ @ 30 NONAME ; CLbsWcdmaCellInfo::~CLbsWcdmaCellInfo(void) + ?RxLevel@CLbsGsmCellInfo@@QBEHXZ @ 31 NONAME ; int CLbsGsmCellInfo::RxLevel(void) const + ?Arfcn@TLbsGsmNeighbourCellInfo@@QBEHXZ @ 32 NONAME ; int TLbsGsmNeighbourCellInfo::Arfcn(void) const + ?CellId@CLbsGsmCellInfo@@QBEHXZ @ 33 NONAME ; int CLbsGsmCellInfo::CellId(void) const + ?Type@CLbsLocationInfo@@MAEKXZ @ 34 NONAME ; unsigned long CLbsLocationInfo::Type(void) + ??1CLbsGsmCellInfo@@UAE@XZ @ 35 NONAME ; CLbsGsmCellInfo::~CLbsGsmCellInfo(void) + ?SetArfcn@TLbsGsmNeighbourCellInfo@@QAEXH@Z @ 36 NONAME ; void TLbsGsmNeighbourCellInfo::SetArfcn(int) + ?TimingAdvance@CLbsGsmCellInfo@@QBEHXZ @ 37 NONAME ; int CLbsGsmCellInfo::TimingAdvance(void) const + ?ResetNeighbouringCellInfo@CLbsGsmCellInfo@@QAEXXZ @ 38 NONAME ; void CLbsGsmCellInfo::ResetNeighbouringCellInfo(void) + ?NewL@CLbsWcdmaCellInfo@@SAPAV1@HHH@Z @ 39 NONAME ; class CLbsWcdmaCellInfo * CLbsWcdmaCellInfo::NewL(int, int, int) + ?InternaliseL@CLbsLocationInfoBase@@QAEXAAVRReadStream@@@Z @ 40 NONAME ; void CLbsLocationInfoBase::InternaliseL(class RReadStream &) + ??0TLbsGsmNeighbourCellInfo@@QAE@HHH@Z @ 41 NONAME ; TLbsGsmNeighbourCellInfo::TLbsGsmNeighbourCellInfo(int, int, int) + ?SignalStrength@TLbsWcdmaNeighbourCellInfo@@QBEHXZ @ 42 NONAME ; int TLbsWcdmaNeighbourCellInfo::SignalStrength(void) const + ?MobileNetworkCode@CLbsGsmCellInfo@@QBEHXZ @ 43 NONAME ; int CLbsGsmCellInfo::MobileNetworkCode(void) const + ?SetRxLevel@CLbsGsmCellInfo@@QAEXH@Z @ 44 NONAME ; void CLbsGsmCellInfo::SetRxLevel(int) + ?GetLocality@CLbsPositionInfo@@QBEXAAVTLocality@@@Z @ 45 NONAME ; void CLbsPositionInfo::GetLocality(class TLocality &) const + ?ExternaliseL@CLbsAreaInfoBase@@QAEXAAVRWriteStream@@@Z @ 46 NONAME ; void CLbsAreaInfoBase::ExternaliseL(class RWriteStream &) + ?SetScramblingCode@CLbsWcdmaCellInfo@@QAEXH@Z @ 47 NONAME ; void CLbsWcdmaCellInfo::SetScramblingCode(int) + ?MobileCountryCode@CLbsWcdmaCellInfo@@QBEHXZ @ 48 NONAME ; int CLbsWcdmaCellInfo::MobileCountryCode(void) const + ?RxLevel@TLbsGsmNeighbourCellInfo@@QBEHXZ @ 49 NONAME ; int TLbsGsmNeighbourCellInfo::RxLevel(void) const + ?SetScramblingCode@TLbsWcdmaNeighbourCellInfo@@QAEXH@Z @ 50 NONAME ; void TLbsWcdmaNeighbourCellInfo::SetScramblingCode(int) + ?SetLocationAreaCode@CLbsGsmCellInfo@@QAEXH@Z @ 51 NONAME ; void CLbsGsmCellInfo::SetLocationAreaCode(int) + ?SignalStrength@CLbsWlanInfo@@QBEHXZ @ 52 NONAME ; int CLbsWlanInfo::SignalStrength(void) const + ?SetTimingAdvance@CLbsGsmCellInfo@@QAEXH@Z @ 53 NONAME ; void CLbsGsmCellInfo::SetTimingAdvance(int) + ?GetNeighbouringCellInfoL@CLbsGsmCellInfo@@QBEXAAV?$RArray@VTLbsGsmNeighbourCellInfo@@@@@Z @ 54 NONAME ; void CLbsGsmCellInfo::GetNeighbouringCellInfoL(class RArray &) const + ?SetSignalStrength@TLbsWcdmaNeighbourCellInfo@@QAEXH@Z @ 55 NONAME ; void TLbsWcdmaNeighbourCellInfo::SetSignalStrength(int) + ?NewL@CLbsWlanInfo@@SAPAV1@XZ @ 56 NONAME ; class CLbsWlanInfo * CLbsWlanInfo::NewL(void) + ?SetPathloss@TLbsWcdmaNeighbourCellInfo@@QAEXH@Z @ 57 NONAME ; void TLbsWcdmaNeighbourCellInfo::SetPathloss(int) + ??0TLbsGsmNeighbourCellInfo@@QAE@XZ @ 58 NONAME ; TLbsGsmNeighbourCellInfo::TLbsGsmNeighbourCellInfo(void) + ?NewL@CLbsGsmCellInfo@@SAPAV1@XZ @ 59 NONAME ; class CLbsGsmCellInfo * CLbsGsmCellInfo::NewL(void) + ?ResetAreaInfo@CLbsLocationInfo@@QAEXK@Z @ 60 NONAME ; void CLbsLocationInfo::ResetAreaInfo(unsigned long) + ?SetBsic@TLbsGsmNeighbourCellInfo@@QAEXH@Z @ 61 NONAME ; void TLbsGsmNeighbourCellInfo::SetBsic(int) + ?SetMobileCountryCode@CLbsGsmCellInfo@@QAEXH@Z @ 62 NONAME ; void CLbsGsmCellInfo::SetMobileCountryCode(int) + ?UniqueCellId@CLbsWcdmaCellInfo@@QBEHXZ @ 63 NONAME ; int CLbsWcdmaCellInfo::UniqueCellId(void) const + ?SetLocality@CLbsPositionInfo@@QAEXABVTLocality@@@Z @ 64 NONAME ; void CLbsPositionInfo::SetLocality(class TLocality const &) + ?UniqueCellId@TLbsWcdmaNeighbourCellInfo@@QBEHXZ @ 65 NONAME ; int TLbsWcdmaNeighbourCellInfo::UniqueCellId(void) const + ?LocationAreaCode@CLbsGsmCellInfo@@QBEHXZ @ 66 NONAME ; int CLbsGsmCellInfo::LocationAreaCode(void) const + ?NewL@CLbsWlanInfo@@SAPAV1@ABV?$TBuf8@$0BC@@@H@Z @ 67 NONAME ; class CLbsWlanInfo * CLbsWlanInfo::NewL(class TBuf8<18> const &, int) + ?NewL@CLbsPositionInfo@@SAPAV1@XZ @ 68 NONAME ; class CLbsPositionInfo * CLbsPositionInfo::NewL(void) + ?NewL@CLbsPositionInfo@@SAPAV1@ABVTLocality@@@Z @ 69 NONAME ; class CLbsPositionInfo * CLbsPositionInfo::NewL(class TLocality const &) + ?InternaliseL@CLbsAreaInfoBase@@QAEXAAVRReadStream@@@Z @ 70 NONAME ; void CLbsAreaInfoBase::InternaliseL(class RReadStream &) + ?SetMobileNetworkCode@CLbsGsmCellInfo@@QAEXH@Z @ 71 NONAME ; void CLbsGsmCellInfo::SetMobileNetworkCode(int) + ??1CLbsPositionInfo@@UAE@XZ @ 72 NONAME ; CLbsPositionInfo::~CLbsPositionInfo(void) + ?Type@CLbsAreaInfoBase@@UAEKXZ @ 73 NONAME ; unsigned long CLbsAreaInfoBase::Type(void) + ??1CLbsLocationInfoBase@@UAE@XZ @ 74 NONAME ; CLbsLocationInfoBase::~CLbsLocationInfoBase(void) + ?SetUniqueCellId@TLbsWcdmaNeighbourCellInfo@@QAEXH@Z @ 75 NONAME ; void TLbsWcdmaNeighbourCellInfo::SetUniqueCellId(int) + ?MobileNetworkCode@CLbsWcdmaCellInfo@@QBEHXZ @ 76 NONAME ; int CLbsWcdmaCellInfo::MobileNetworkCode(void) const + ?ResetNeighbouringCellInfo@CLbsWcdmaCellInfo@@QAEXXZ @ 77 NONAME ; void CLbsWcdmaCellInfo::ResetNeighbouringCellInfo(void) + ?NewL@CLbsPositionInfo@@SAPAV1@ABV1@@Z @ 78 NONAME ; class CLbsPositionInfo * CLbsPositionInfo::NewL(class CLbsPositionInfo const &) + ?NewL@CLbsGsmCellInfo@@SAPAV1@ABV1@@Z @ 79 NONAME ; class CLbsGsmCellInfo * CLbsGsmCellInfo::NewL(class CLbsGsmCellInfo const &) + ?NewL@CLbsWcdmaCellInfo@@SAPAV1@ABV1@@Z @ 80 NONAME ; class CLbsWcdmaCellInfo * CLbsWcdmaCellInfo::NewL(class CLbsWcdmaCellInfo const &) + ?NewL@CLbsWlanInfo@@SAPAV1@ABV1@@Z @ 81 NONAME ; class CLbsWlanInfo * CLbsWlanInfo::NewL(class CLbsWlanInfo const &) + ?SetSignalStrength@CLbsWcdmaCellInfo@@QAEXH@Z @ 82 NONAME ; void CLbsWcdmaCellInfo::SetSignalStrength(int) + ?SignalStrength@CLbsWcdmaCellInfo@@QBEHXZ @ 83 NONAME ; int CLbsWcdmaCellInfo::SignalStrength(void) const + diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/ConversionDataTypes/EABI/lbslocationinfodatatypesu.def --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/ConversionDataTypes/EABI/lbslocationinfodatatypesu.def Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,103 @@ +EXPORTS + _ZN12CLbsWlanInfo13SetMacAddressERK6TDesC8 @ 1 NONAME + _ZN12CLbsWlanInfo17SetSignalStrengthEi @ 2 NONAME + _ZN12CLbsWlanInfo4NewLERK5TBuf8ILi18EEi @ 3 NONAME + _ZN12CLbsWlanInfo4NewLEv @ 4 NONAME + _ZN12CLbsWlanInfoD0Ev @ 5 NONAME + _ZN12CLbsWlanInfoD1Ev @ 6 NONAME + _ZN12CLbsWlanInfoD2Ev @ 7 NONAME + _ZN15CLbsGsmCellInfo10SetRxLevelEi @ 8 NONAME + _ZN15CLbsGsmCellInfo16SetTimingAdvanceEi @ 9 NONAME + _ZN15CLbsGsmCellInfo19SetLocationAreaCodeEi @ 10 NONAME + _ZN15CLbsGsmCellInfo20SetMobileCountryCodeEi @ 11 NONAME + _ZN15CLbsGsmCellInfo20SetMobileNetworkCodeEi @ 12 NONAME + _ZN15CLbsGsmCellInfo24AddNeighbouringCellInfoLEP24TLbsGsmNeighbourCellInfo @ 13 NONAME + _ZN15CLbsGsmCellInfo25ResetNeighbouringCellInfoEv @ 14 NONAME + _ZN15CLbsGsmCellInfo4NewLEiiii @ 15 NONAME + _ZN15CLbsGsmCellInfo4NewLEv @ 16 NONAME + _ZN15CLbsGsmCellInfo9SetCellIdEi @ 17 NONAME + _ZN15CLbsGsmCellInfoD0Ev @ 18 NONAME + _ZN15CLbsGsmCellInfoD1Ev @ 19 NONAME + _ZN15CLbsGsmCellInfoD2Ev @ 20 NONAME + _ZN16CLbsAreaInfoBase12ExternaliseLER12RWriteStream @ 21 NONAME + _ZN16CLbsAreaInfoBase12InternaliseLER11RReadStream @ 22 NONAME + _ZN16CLbsAreaInfoBase4TypeEv @ 23 NONAME + _ZN16CLbsAreaInfoBaseD0Ev @ 24 NONAME + _ZN16CLbsAreaInfoBaseD1Ev @ 25 NONAME + _ZN16CLbsAreaInfoBaseD2Ev @ 26 NONAME + _ZN16CLbsLocationInfo12AddAreaInfoLEP16CLbsAreaInfoBase @ 27 NONAME + _ZN16CLbsLocationInfo12GetAreaInfoLER13RPointerArrayI16CLbsAreaInfoBaseEm @ 28 NONAME + _ZN16CLbsLocationInfo13ResetAreaInfoEm @ 29 NONAME + _ZN16CLbsLocationInfo4NewLEv @ 30 NONAME + _ZN16CLbsLocationInfo4TypeEv @ 31 NONAME + _ZN16CLbsLocationInfo5NewLCEv @ 32 NONAME + _ZN16CLbsLocationInfoD0Ev @ 33 NONAME + _ZN16CLbsLocationInfoD1Ev @ 34 NONAME + _ZN16CLbsLocationInfoD2Ev @ 35 NONAME + _ZN16CLbsPositionInfo11SetLocalityERK9TLocality @ 36 NONAME + _ZN16CLbsPositionInfo4NewLERK9TLocality @ 37 NONAME + _ZN16CLbsPositionInfo4NewLEv @ 38 NONAME + _ZN16CLbsPositionInfoD0Ev @ 39 NONAME + _ZN16CLbsPositionInfoD1Ev @ 40 NONAME + _ZN16CLbsPositionInfoD2Ev @ 41 NONAME + _ZN17CLbsWcdmaCellInfo15SetUniqueCellIdEi @ 42 NONAME + _ZN17CLbsWcdmaCellInfo17SetScramblingCodeEi @ 43 NONAME + _ZN17CLbsWcdmaCellInfo20SetMobileCountryCodeEi @ 44 NONAME + _ZN17CLbsWcdmaCellInfo20SetMobileNetworkCodeEi @ 45 NONAME + _ZN17CLbsWcdmaCellInfo24AddNeighbouringCellInfoLEP26TLbsWcdmaNeighbourCellInfo @ 46 NONAME + _ZN17CLbsWcdmaCellInfo25ResetNeighbouringCellInfoEv @ 47 NONAME + _ZN17CLbsWcdmaCellInfo4NewLEiii @ 48 NONAME + _ZN17CLbsWcdmaCellInfo4NewLEv @ 49 NONAME + _ZN17CLbsWcdmaCellInfoD0Ev @ 50 NONAME + _ZN17CLbsWcdmaCellInfoD1Ev @ 51 NONAME + _ZN17CLbsWcdmaCellInfoD2Ev @ 52 NONAME + _ZN20CLbsLocationInfoBase12InternaliseLER11RReadStream @ 53 NONAME + _ZN20CLbsLocationInfoBase4TypeEv @ 54 NONAME + _ZN20CLbsLocationInfoBaseD0Ev @ 55 NONAME + _ZN20CLbsLocationInfoBaseD1Ev @ 56 NONAME + _ZN20CLbsLocationInfoBaseD2Ev @ 57 NONAME + _ZN24TLbsGsmNeighbourCellInfo10SetRxLevelEi @ 58 NONAME + _ZN24TLbsGsmNeighbourCellInfo7SetBsicEi @ 59 NONAME + _ZN24TLbsGsmNeighbourCellInfo8SetArfcnEi @ 60 NONAME + _ZN24TLbsGsmNeighbourCellInfoC1Eiii @ 61 NONAME + _ZN24TLbsGsmNeighbourCellInfoC1Ev @ 62 NONAME + _ZN24TLbsGsmNeighbourCellInfoC2Eiii @ 63 NONAME + _ZN24TLbsGsmNeighbourCellInfoC2Ev @ 64 NONAME + _ZN26TLbsWcdmaNeighbourCellInfo11SetPathlossEi @ 65 NONAME + _ZN26TLbsWcdmaNeighbourCellInfo15SetUniqueCellIdEi @ 66 NONAME + _ZN26TLbsWcdmaNeighbourCellInfo17SetScramblingCodeEi @ 67 NONAME + _ZN26TLbsWcdmaNeighbourCellInfo17SetSignalStrengthEi @ 68 NONAME + _ZN26TLbsWcdmaNeighbourCellInfoC1Eiiii @ 69 NONAME + _ZN26TLbsWcdmaNeighbourCellInfoC1Ev @ 70 NONAME + _ZN26TLbsWcdmaNeighbourCellInfoC2Eiiii @ 71 NONAME + _ZN26TLbsWcdmaNeighbourCellInfoC2Ev @ 72 NONAME + _ZNK12CLbsWlanInfo13GetMacAddressER5TDes8 @ 73 NONAME + _ZNK12CLbsWlanInfo14SignalStrengthEv @ 74 NONAME + _ZNK15CLbsGsmCellInfo13TimingAdvanceEv @ 75 NONAME + _ZNK15CLbsGsmCellInfo16LocationAreaCodeEv @ 76 NONAME + _ZNK15CLbsGsmCellInfo17MobileCountryCodeEv @ 77 NONAME + _ZNK15CLbsGsmCellInfo17MobileNetworkCodeEv @ 78 NONAME + _ZNK15CLbsGsmCellInfo24GetNeighbouringCellInfoLER6RArrayI24TLbsGsmNeighbourCellInfoE @ 79 NONAME + _ZNK15CLbsGsmCellInfo6CellIdEv @ 80 NONAME + _ZNK15CLbsGsmCellInfo7RxLevelEv @ 81 NONAME + _ZNK16CLbsPositionInfo11GetLocalityER9TLocality @ 82 NONAME + _ZNK17CLbsWcdmaCellInfo12UniqueCellIdEv @ 83 NONAME + _ZNK17CLbsWcdmaCellInfo14ScramblingCodeEv @ 84 NONAME + _ZNK17CLbsWcdmaCellInfo17MobileCountryCodeEv @ 85 NONAME + _ZNK17CLbsWcdmaCellInfo17MobileNetworkCodeEv @ 86 NONAME + _ZNK17CLbsWcdmaCellInfo24GetNeighbouringCellInfoLER6RArrayI26TLbsWcdmaNeighbourCellInfoE @ 87 NONAME + _ZNK20CLbsLocationInfoBase12ExternaliseLER12RWriteStream @ 88 NONAME + _ZNK24TLbsGsmNeighbourCellInfo4BsicEv @ 89 NONAME + _ZNK24TLbsGsmNeighbourCellInfo5ArfcnEv @ 90 NONAME + _ZNK24TLbsGsmNeighbourCellInfo7RxLevelEv @ 91 NONAME + _ZNK26TLbsWcdmaNeighbourCellInfo12UniqueCellIdEv @ 92 NONAME + _ZNK26TLbsWcdmaNeighbourCellInfo14ScramblingCodeEv @ 93 NONAME + _ZNK26TLbsWcdmaNeighbourCellInfo14SignalStrengthEv @ 94 NONAME + _ZNK26TLbsWcdmaNeighbourCellInfo8PathlossEv @ 95 NONAME + _ZN12CLbsWlanInfo4NewLERKS_ @ 96 NONAME + _ZN15CLbsGsmCellInfo4NewLERKS_ @ 97 NONAME + _ZN16CLbsPositionInfo4NewLERKS_ @ 98 NONAME + _ZN17CLbsWcdmaCellInfo4NewLERKS_ @ 99 NONAME + _ZN17CLbsWcdmaCellInfo17SetSignalStrengthEi @ 100 NONAME + _ZNK17CLbsWcdmaCellInfo14SignalStrengthEv @ 101 NONAME + diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/ConversionDataTypes/group/bld.inf --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/ConversionDataTypes/group/bld.inf Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,32 @@ +// Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +// All rights reserved. +// This component and the accompanying materials are made available +// under the terms of "Eclipse Public License v1.0" +// which accompanies this distribution, and is available +// at the URL "http://www.eclipse.org/legal/epl-v10.html". +// +// Initial Contributors: +// Nokia Corporation - initial contribution. +// +// Contributors: +// +// Description: +// + + +PRJ_EXPORTS +../inc/lbslocationclasstypes.h SYMBIAN_OS_LAYER_PLATFORM_EXPORT_PATH(lbs/lbslocationclasstypes.h) +../inc/lbslocationcommon.h SYMBIAN_OS_LAYER_PLATFORM_EXPORT_PATH(lbs/lbslocationcommon.h) +../inc/lbslocationposinfo.h SYMBIAN_OS_LAYER_PLATFORM_EXPORT_PATH(lbs/lbslocationposinfo.h) +../inc/lbslocationgsminfo.h SYMBIAN_OS_LAYER_PLATFORM_EXPORT_PATH(lbs/lbslocationgsminfo.h) +../inc/lbslocationgsmneighbourinfo.h SYMBIAN_OS_LAYER_PLATFORM_EXPORT_PATH(lbs/lbslocationgsmneighbourinfo.h) +../inc/lbslocationinfo.h SYMBIAN_OS_LAYER_PLATFORM_EXPORT_PATH(lbs/lbslocationinfo.h) +../inc/lbslocationwcdmainfo.h SYMBIAN_OS_LAYER_PLATFORM_EXPORT_PATH(lbs/lbslocationwcdmainfo.h) +../inc/lbslocationwcdmaneighbourinfo.h SYMBIAN_OS_LAYER_PLATFORM_EXPORT_PATH(lbs/lbslocationwcdmaneighbourinfo.h) +../inc/lbslocationwlaninfo.h SYMBIAN_OS_LAYER_PLATFORM_EXPORT_PATH(lbs/lbslocationwlaninfo.h) + +lbslocationinfodatatypes.iby /epoc32/rom/include/lbslocationinfodatatypes.iby + +PRJ_MMPFILES +lbslocationinfodatatypes.mmp + diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/ConversionDataTypes/group/lbslocationinfodatatypes.iby --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/ConversionDataTypes/group/lbslocationinfodatatypes.iby Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,25 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ +#ifndef __LBS_LOCATIONINFODATATYPES_IBY__ +#define __LBS_LOCATIONINFODATATYPES_IBY__ + +//#if !defined(SYMBIAN_EXCLUDE_LOCATION) + +file=ABI_DIR\DEBUG_DIR\lbslocationinfodatatypes.dll sys\bin\lbslocationinfodatatypes.dll + +//#endif // SYMBIAN_EXCLUDE_LOCATION +#endif //__LBS_LOCATIONINFODATATYPES_IBY__ diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/ConversionDataTypes/group/lbslocationinfodatatypes.mmp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/ConversionDataTypes/group/lbslocationinfodatatypes.mmp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,42 @@ +// Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +// All rights reserved. +// This component and the accompanying materials are made available +// under the terms of "Eclipse Public License v1.0" +// which accompanies this distribution, and is available +// at the URL "http://www.eclipse.org/legal/epl-v10.html". +// +// Initial Contributors: +// Nokia Corporation - initial contribution. +// +// Contributors: +// +// Description: +// + + +TARGET lbslocationinfodatatypes.dll +TARGETTYPE dll +UID 0x1000008d 0x102871FB + +VENDORID 0x70000001 +CAPABILITY ALL -TCB + +SOURCEPATH ../src +SOURCE lbslocationcommon.cpp +SOURCE lbslocationinfo.cpp +SOURCE lbslocationposinfo.cpp +SOURCE lbslocationgsminfo.cpp +SOURCE lbslocationwcdmainfo.cpp +SOURCE lbslocationwlaninfo.cpp +SOURCE lbslocationwcdmaneighbourinfo.cpp +SOURCE lbslocationgsmneighbourinfo.cpp + +USERINCLUDE ../inc +OS_LAYER_SYSTEMINCLUDE_SYMBIAN + +LIBRARY euser.lib +LIBRARY estor.lib +LIBRARY lbs.lib + +SMPSAFE + diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/ConversionDataTypes/inc/lbslocationclasstypes.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/ConversionDataTypes/inc/lbslocationclasstypes.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,111 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ + +/** +* @file +* @publishedPartner +* @prototype +*/ + + +#ifndef LBS_LOCATION_CLASS_TYPES_H +#define LBS_LOCATION_CLASS_TYPES_H + + +/** + * Type used for identifying location info class types + */ +typedef TUint32 TLbsAreaInfoClassType; + +/** + * Enumeration to indicate the type of area information. + * This information is included when a client application creates + * a class derived from CLbsAreaInfoBase + */ +enum _TLbsAreaInfoClassType + { + /** + * Should be used for data initialisation only + */ + ELbsAreaInfoUnknownClass = 0x00, + + /** + * Identifier for CLbsPositionInfo class + */ + ELbsAreaPositionInfoClass = 0x01, + + /** + * Identifier for CLbsGsmCellInfo class + */ + ELbsAreaGsmCellInfoClass = 0x02, + + /** + * Identifier for CLbsGsmNeighbourCellInfo class + */ + ELbsAreaGsmNeighbourCellInfoClass = 0x04, + + /** + * Identifier for CLbsWcdmaCellInfo class + */ + ELbsAreaWcmdaCellInfoClass = 0x08, + + /** + * Identifier for CLbsWcdmaNeighbourCellInfo class + */ + ELbsAreaWcmdaNeighbourCellInfoClass = 0x10, + + /** + * Identifier for CLbsWlanInfo class + */ + ELbsAreaWlanInfoClass = 0x20, + + /** + * Not used + */ + ELbsAreaInfoLastClass = 0xFFFFFFFF + }; + + +/** + * Type used for identifying location info class types + */ +typedef TUint32 TLbsLocationInfoClassType; + +/** + * Enumeration to indicate the type of area information. + * This information is included when a client application creates + * a class derived from CLbsLocationInfoBase + */ +enum _TLbsLocationInfoClassType + { + /** + * Should be used for data initialisation only + */ + ELbsLocationInfoUnknownClass = 0x00, + + /** + * Identifier for CLbsLocationInfo class + */ + ELbsLocationInfoClass = 0x01, + + /** + * Not used + */ + ELbsLocationInfoLastClass = 0xFFFFFFFF + }; + +#endif //LBS_LOCATION_CLASS_TYPES_H diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/ConversionDataTypes/inc/lbslocationcommon.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/ConversionDataTypes/inc/lbslocationcommon.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,211 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Base class for all the class representing +* location informations. +* +*/ + + +/** +@file +@publishedPartner +@prototype +*/ + + +#ifndef LBS_LOCATION_COMMON_H +#define LBS_LOCATION_COMMON_H + + +#include +#include +#include + + +// Constants + +/** + * Defines the maximum allowable batch size supported by the system + */ +const TUint KPositionMaxBatchSize = 500; + + +/** + * Abstract base class for data class representing location area + * information. + */ +NONSHARABLE_CLASS(CLbsLocationInfoBase) : public CBase + { + +public: + + /** + * This method is implemented by each of the derived classes that + * extend this class. + */ + IMPORT_C virtual TLbsLocationInfoClassType Type(); + + /** + * Destructor + */ + IMPORT_C virtual ~CLbsLocationInfoBase(); + + /** + * Internalizes the geographical area information from a stream. + * + * @param[in] aStream Stream from which the object is internalized. + */ + IMPORT_C void InternaliseL( RReadStream& aStream ); + + /** + * Externalizes the geographical area information to a stream. + * + * @param[in] aStream Stream to which the object is to be + * externalized. + */ + IMPORT_C void ExternaliseL( RWriteStream& aStream ) const; + +protected: + + /** + * C++ default constructor + */ + CLbsLocationInfoBase(); + + /** + * Internalize method that subclass must implement. + * + * @param[in] aStream Stream from which the object is internalized. + */ + virtual void DoInternaliseL( RReadStream& aStream ) = 0; + + /** + * Externalize method that subclass must implement. + * + * @param[in] aStream Stream to which the object is to be + * externalized. + */ + virtual void DoExternaliseL( RWriteStream& aStream ) const = 0; + +private: + + /** + * Copy constructor. Prohibited by default. + */ + CLbsLocationInfoBase( CLbsLocationInfoBase& ); + + /** + * Overloaded assignment operator. Prohibited by default. + */ + CLbsLocationInfoBase& operator=( CLbsLocationInfoBase& ); + +private: + + /* + * Reserved for future use. + */ + TAny* iReserved; + + }; + +typedef RPointerArray RLbsLocationInfoBaseArray; + +/** + * Abstract base class for data types representing geogrphical area + * information. + * + * Geographical information may be a collection of GSM or WCDMA cells + * or WLAN information. + */ +NONSHARABLE_CLASS(CLbsAreaInfoBase) : public CBase + { + +public: + + /** + * This method is implemented by each of the geographical area type classes + * that extend this class. The method returns the type of geographical area + * being represented. + */ + IMPORT_C virtual TLbsAreaInfoClassType Type(); + + /** + * Destructor + */ + IMPORT_C virtual ~CLbsAreaInfoBase(); + + /** + * Internalizes the geographical area information from a stream. + * + * @param[in] aStream Stream from which the object is internalized. + */ + IMPORT_C void InternaliseL( RReadStream& aStream ); + + /** + * Externalizes the geographical area information to a stream. + * + * @param[in] aStream Stream to which the object is to be + * externalized. + */ + IMPORT_C void ExternaliseL( RWriteStream& aStream ); + + /** + * Validates area information. + */ + virtual void ValidateDataL() const = 0; + +protected: + + /** + * C++ default constructor + */ + CLbsAreaInfoBase(); + + /** + * Internalize method that subclass must implement. + * + * @param[in] aStream Stream from which the object is internalized. + */ + virtual void DoInternaliseL( RReadStream& aStream ) = 0; + + /** + * Externalize method that subclass must implement. + * + * @param[in] aStream Stream to which the object is to be + * externalized. + */ + virtual void DoExternaliseL( RWriteStream& aStream ) const = 0; + +private: + + /** + * Copy constructor. Prohibited by default. + */ + CLbsAreaInfoBase( CLbsAreaInfoBase& ); + + /** + * Overloaded assignment operator. Prohibited by default. + */ + CLbsAreaInfoBase& operator=( CLbsAreaInfoBase& ); + +private: + + /** + * Reserved for future use. + */ + TAny* iReserved; + + }; + +#endif // LBS_LOCATION_COMMON_H diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/ConversionDataTypes/inc/lbslocationgsminfo.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/ConversionDataTypes/inc/lbslocationgsminfo.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,326 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Data class representing a geographical area in terms of +* cell information in a GSM PLMN. This class may also optionally contain +* neighbouring cell information +* +*/ + + +/** +* @file +* @publishedPartner +* @prototype +*/ + + +#ifndef LBS_GSM_CELL_INFO_H +#define LBS_GSM_CELL_INFO_H + + +#include +#include +#include + + +/** + * This class contains information related to a cell in GSM PLMN. An instance + * of this class may also contain information of one or more neighbouring + * GSM cells + */ +NONSHARABLE_CLASS(CLbsGsmCellInfo) : public CLbsAreaInfoBase + { + +public: + + /** + * Allocates and constructs a new GSM cell info object. In the returned + * instance, the country code, network code, location area code and cell ID + * are marked as undefined. + * + * @return Pointer to the new GSM cell info object. + * @leave Standard symbian error codes, such as KErrNoMemory + */ + IMPORT_C static CLbsGsmCellInfo* NewL(); + + /** + * Allocates and constructs a new GSM cell info object. + * + * @param[in] aCountryCode Network country code. + * @param[in] aNetworkCode Network code. + * @param[in] aLocationAreaCode Location area code. + * @param[in] aCellId Cell ID of a cell in GSM PLMN. + * @return Pointer to the new GSM cell info object. + * @leave standard symbian error codes, such as KErrNoMemory. + */ + IMPORT_C static CLbsGsmCellInfo* NewL( const TInt aCountryCode, + const TInt aNetworkCode, + const TInt aLocationAreaCode, + const TInt aCellId ); + + + /** + * Allocates and constructs new GSM cell info objec, a copy of another one. + * + * @param[in] aLocality Instance of CLbsGsmCellInfo. + */ + IMPORT_C static CLbsGsmCellInfo* NewL( const CLbsGsmCellInfo& aPositionInfo ); + + + /** + * Destructor + */ + IMPORT_C ~CLbsGsmCellInfo(); + + /** + * Sets the Mobile Country Code information. + * + * @param[in] aCountryCode Mobile Country Code, range 0..999. + */ + IMPORT_C void SetMobileCountryCode(const TInt aCountryCode); + + /** + * Retrieves the Mobile Country Code information. + * + * @return Mobile Country Code, range 0..999; + * KErrNotFound if the value is undefined. + */ + IMPORT_C TInt MobileCountryCode() const; + + /** + * Sets the Mobile Network Code information. + * + * @param[in] aNetworkCode Mobilre Network Code, range 0..999. + */ + IMPORT_C void SetMobileNetworkCode( const TInt aNetworkCode ); + + /** + * Retrieves the Mobile Network Code information. + * + * @return Mobile Network Code, range 0..999. + * KErrNotFound if the value is undefined. + */ + IMPORT_C TInt MobileNetworkCode() const; + + /** + * Sets the Location Area Code information. + * + * @param[in] aLocationAreaCode Location Area Code, range 0..65535. + */ + IMPORT_C void SetLocationAreaCode( const TInt aLocationAreaCode ); + + /** + * Retrieves the Location Area Code information. + * + * @return Location Area Code, range 0..65535. + * KErrNotFound if the value is undefined. + */ + IMPORT_C TInt LocationAreaCode() const; + + /** + * Sets the Cell Identity information. + * + * @param[in] aCellId Cell Identity, range 0..65535. + */ + IMPORT_C void SetCellId( const TInt aCellId ); + + /** + * Retrieves the Cell Identity information. + * + * @return Cell Identity, range 0..65535. + * KErrNotFound if the value is undefined. + */ + IMPORT_C TInt CellId() const; + + /** + * Initializes the signal strength parameter. + * + * @param[in] aRxLev Rx Level, range 0..63. + */ + IMPORT_C void SetRxLevel( const TInt aRxLev ); + + /** + * Retrieves the Rx level. + * + * @return Rx Level, range 0..63. + * KErrNotFound if the value is undefined. + */ + IMPORT_C TInt RxLevel() const; + + /** + * Sets the Timing Advance information. + * + * @param[in] aTimingAdvance Timing Advance, range 0..255. + */ + IMPORT_C void SetTimingAdvance( const TInt aTimingAdvance ); + + /** + * Retrieves the Timing Advance information. + * + * @return Timing Advance, range 0..255. + * KErrNotFound if the value is undefined. + */ + IMPORT_C TInt TimingAdvance() const; + + /** + * Adds a neighbouring cell information. + * + * @param[in] An instance of TLbsGsmNeighbourCellInfo class + * (memory ovnership is being transferred) + * @leave KErrArgument if the argument is NULL or one of standard symbian + * error codes + */ + IMPORT_C void AddNeighbouringCellInfoL( + TLbsGsmNeighbourCellInfo* aNeighbourCellInfo ); + + /** + * Retrieves a copy of neighbouring cell information information as an + * array. + * + * @param[in] aNeighbourCellInfo GSM neighbouring cell information + * (memory ownership is not being transferred to this function therefore + * it is the responsibility of the caller to ensure Close() is called to + * free resources) + */ + IMPORT_C void GetNeighbouringCellInfoL( + RLbsGsmNeighbourCellInfoArray& aNeighbourCellInfo ) const; + + /** + * Removes all neighbouring cell information. + */ + IMPORT_C void ResetNeighbouringCellInfo(); + +public: // from CLbsAreaInfoBase + + /** + * Returns the type of area information instance. + * + * @return Area type information + */ + virtual TLbsAreaInfoClassType Type(); + + /** + * Validates GSM cell information. + * This method checks for boundary conditions as well as the mandatory + * attributes. The attributes of this class become mandatory in a + * hierarchical manner. For instance, if location area code is + * specified then the mobile network code attribute is mandatory. If cell + * id is specified then, both LAC and MNC become mandatory attributes and + * so on. However, the mobile country code attribute is always mandatory + * which means client applications must at least specify the MCC attribute + * when specifying GSM cell information. + * This method is used internally to determine the correctness of + * information provided. Optionally, this method, may also be used by + * client applications to validate their input. + * + * @leave KErrArgument If the specified attributes dont meet the boundary + * conditions or the mandatory arguments are not specified. + */ + virtual void ValidateDataL() const; + +protected: // from CLbsAreaInfoBase + + /** + * Internalize method to write GSM cell information to a stream. + */ + virtual void DoInternaliseL( RReadStream& aStream ); + + /** + * Externalize method to read GSM cell information from a stream. + */ + virtual void DoExternaliseL( RWriteStream& aStream ) const; + +private: + + /** + * C++ default constructor + */ + CLbsGsmCellInfo(); + + /** + * Copy constructor. Prohibited by default. + */ + CLbsGsmCellInfo( CLbsGsmCellInfo& ); + + /** + * Overloaded assignment operator. Prohibited by default. + */ + CLbsGsmCellInfo& operator=( CLbsGsmCellInfo& ); + + /** + * Symbian 2 phase constructor + */ + void ConstructL(); + + /** + * Symbian 2 phase constructor + */ + void ConstructL( const TInt aCountryCode, const TInt aNetworkCode, + const TInt aLocationAreaCode, const TInt aCellId ); + +private: // attributes + + enum _TGsmDataValidationMask + { + EGsmDataNull = 0x00, + EGsmMCC = 0x01, + EGsmMNC = 0x02, + EGsmLAC = 0x04, + EGsmCI = 0x08, + EGsmRx = 0x10, + EGsmTA = 0x20 + }; + + /** + * Mobile country code + */ + TInt16 iMCC; + + /** + * Mobile network code + */ + TInt16 iMNC; + + /** + * Location area code + */ + TInt32 iLAC; + + /** + * Cell id + */ + TInt32 iCid; + + /** + * Signal strength + */ + TInt32 iRxLev; + + /** + * Timing advance + */ + TInt16 iTA; + + /** + * Data mask to determine initialized data. Used internally. + */ + TInt8 iDataValidationMask; + + /** + * Neighbouring cell info + */ + RLbsGsmNeighbourCellInfoArray iNeighbourCellInfo; + }; + +#endif //LBS_GSM_CELL_INFO_H diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/ConversionDataTypes/inc/lbslocationgsmneighbourinfo.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/ConversionDataTypes/inc/lbslocationgsmneighbourinfo.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,136 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Data class representing a geographical area in terms of +* cell information in a GSM PLMN. This class may also optionally contain +* neighbouring cell information +* +*/ + +/** +@file +@publishedPartner +@prototype +*/ + + +#ifndef LBS_GSM_NEIGHB_CELL_INFO_H +#define LBS_GSM_NEIGHB_CELL_INFO_H + +#include +#include + + +/** + * This class contains information related to a GSM neighbouring cell + * information. + */ +NONSHARABLE_CLASS(TLbsGsmNeighbourCellInfo) + { + +public: + + /** + * Allocates and constructs a new neighbour GSM cell info object. In the + * returned instance all data is marked as undefined + * + * @return Pointer to the new neighbour GSM cell info object. + */ + IMPORT_C TLbsGsmNeighbourCellInfo(); + + /** + * Allocates and constructs a new neighbour GSM cell info object. + + * @param[in] aARFCN Absolute Radio Frequency Channel Number + * @param[in] aBSIC Base station identity (colour) code. + * @param[in] aRxLev Rx level. + * + * @return Pointer to the new neighbour GSM cell info object. + */ + IMPORT_C TLbsGsmNeighbourCellInfo( const TInt aARFCN, + const TInt aBSIC, + const TInt aRxLev ); + + /** + *Sets the Absolute Radio Frequency Channel Number. + * + * @param[in] aARFCN Absolute Radio Frequency Channel Number, range 0..1023. + */ + IMPORT_C void SetArfcn(const TInt aARFCN); + + /** + * Retrieves the Absolute Radio Frequency Channel Number. + * + * @return Absolute Radio Frequency Channel Number, range 0..1023. + * KErrNotFound if the value is undefined. + */ + IMPORT_C TInt Arfcn() const; + + /** + * Sets the Base station identity (colour) code. + * + * @param[in] iBSIC Base station identity code, range 0..63. + */ + IMPORT_C void SetBsic( const TInt aBSIC ); + + /** + * Retrieves the Base station identity code. + * + * @return Base station identity code, range 0..63. + * KErrNotFound if the value is undefined. + */ + IMPORT_C TInt Bsic() const; + + /** + * Sets the Rx level. + * + * @param[in] aRxLev Rx Level, range 0..63. + */ + IMPORT_C void SetRxLevel( const TInt aRxLev ); + + /** + * Retrieves the Rx level. + * + * @return Rx Level, range 0..63. + * KErrNotFound if the value is undefined. + */ + IMPORT_C TInt RxLevel() const; + +protected: // attributes + + /** + * Absolute Radio Frequency Channel Number + */ + TInt16 iARFCN; + + /** + * Base station identity code + */ + TInt8 iBSIC; + + /** + * Rx level + */ + TInt8 iRxLev; + + /** + * Reserved + */ + TUint8 iReserved[4]; + + }; + +typedef RArray RLbsGsmNeighbourCellInfoArray; + + +#endif //LBS_GSM_NEIGHB_CELL_INFO_H diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/ConversionDataTypes/inc/lbslocationinfo.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/ConversionDataTypes/inc/lbslocationinfo.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,204 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Container class representing geographical area information as a +* collection of GSM/WCDMA cell information and WLAN MAC IDs. +* +*/ + + +/** +* @file +* @publishedPartner +* @prototype +*/ + + +#ifndef C_LBSLOCATIONINFO_H +#define C_LBSLOCATIONINFO_H + + +#include +#include +#include +#include +#include +#include + + +/** + * Type definitions + */ + +/** + * Structure used to carry location information to be converted + */ +typedef RPointerArray RLbsAreaInfoBaseArray; + +/** + * This class contains information related to a collection of geographical area + * information. Client applications create an instance of this class to + * represent a geographical area for which a conversion is required. The + * corresponding coordinate values determined by the conversion plugins would + * be updated in the same instance of CLbsLocationInfo. Client applications + * may retrieve the position estimate(s) using GetPositionInfo method. + * + */ +NONSHARABLE_CLASS(CLbsLocationInfo) : public CLbsLocationInfoBase + { + +public: + + typedef TUint32 TAreaInfoMask; + + enum _TAreaInfoMask + { + /** + * Bit mask used to retrieve position information. + */ + ELbsPosInfo = 0x01, + + /** + * Bit mask used to retrieve GSM cell information. + */ + ELbsGsmInfo = 0x02, + + /** + * Bit mask used to retrieve WCDMA cell information. + */ + ELbsWcdmaInfo = 0x04, + + /** + * Bit mask used to retrieve WLAN AP information. + */ + ELbsWlanInfo = 0x08, + + /** + * Bit mask used to retrieve all area information. + */ + ELbsAreaInfoAll = 0xFFFFFFFF + }; + + /** + * Allocates and constructs a new location info object. + * + * @return Pointer to the new area info object. + * @leave Standard symbian error codes, such as KErrNoMemory + */ + IMPORT_C static CLbsLocationInfo* NewL(); + + /** + * Allocates and constructs a new location info object. This method will + * push the resultant object onto the cleanup stack. + * + * @return Pointer to the new area info object. + * @leave Standard symbian error codes, such as KErrNoMemory + */ + IMPORT_C static CLbsLocationInfo* NewLC(); + + /** + * Destructor + */ + IMPORT_C ~CLbsLocationInfo(); + + /** + * Appends the specified area info entry to the data structure. This + * method takes a pointer to CLbsAreaInfoBase type instances. + * + * @param[in] aAreaInfo Pointer to a CLbsAreaInfoBase type instance. + * @leave KErrArgument if the pointer to CLbsAreaInfoBase type is NULL + */ + IMPORT_C void AddAreaInfoL( CLbsAreaInfoBase* aAreaInfo ); + + /** + * Retrieves the area information that is stored in the internal + * data structure. Client applications can specify the type of information + * to be retrieved using the TAreaInfoMask. The result is updated in + * the instance of RLbsAreaInfoBaseArray. If there is no information stored + * for the requested type the instance of RLbsAreaInfoBaseArray will not be + * updated. Client applications would need to check the contents of the + * array to determine the information retrieved. + * + * @param[out] aAreaInfoArray Array that is filled with pointers to the + * area information retrieved. Note it is the callers responsibility to call + * Close() to free the pointers. However ownership of the objects pointed to + * is not transferred to the caller. + * @param[in] aLocInfoMask Specifies the type of information to be + * retrieved. + */ + IMPORT_C void GetAreaInfoL( RLbsAreaInfoBaseArray& aAreaInfoArray, + TAreaInfoMask aAreaInfoMask = ELbsAreaInfoAll ); + + /** + * Removes all entries of the specified type from the data structure. If + * the mask is not specified all entries would be removed. If there are no + * entries found for a specific type, no changes will be done. + * + * @param[in] aLocInfoMask Specifies the type of information to be + * removed. + */ + IMPORT_C void ResetAreaInfo( TAreaInfoMask aAreaInfoMask + = ELbsAreaInfoAll ); + +protected: // from CLbsLocationInfoBase + + /** + * Type of location info class + */ + virtual TLbsLocationInfoClassType Type(); + + /** + * Internalize method to write location information to a stream. + */ + virtual void DoInternaliseL( RReadStream& aStream ); + + /** + * Externalize method to read location information from a stream. + */ + virtual void DoExternaliseL( RWriteStream& aStream ) const; + +private: + + /** + * C++ default constructor + */ + CLbsLocationInfo(); + + /** + * Copy constructor. Prohibited by default. + */ + CLbsLocationInfo( CLbsLocationInfo& ); + + /** + * Overloaded assignment operator. Prohibited by default. + */ + CLbsLocationInfo& operator = ( CLbsLocationInfo& ); + + /** + * Symbian 2 phase constructor + */ + void ConstructL(); + +private: + + /** + * A collection of geographical area information. + */ + RPointerArray iAreaInfoArray; + + }; + +typedef RPointerArray RLbsLocationInfoArray; + + +#endif //C_LBSLOCATIONINFO_H diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/ConversionDataTypes/inc/lbslocationposinfo.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/ConversionDataTypes/inc/lbslocationposinfo.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,172 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Data class representing a geographical area in terms of +* latitude,longitude,altitude,horizontal accuracy and vertical accuracy. +* +*/ + +/** +* @file +* @publishedPartner +* @prototype +*/ + + +#ifndef LBS_COORDINATE_INFO_H +#define LBS_COORDINATE_INFO_H + + +#include +#include +#include + + +/** + * This class contains the basic coordinates of a location (latitude, longitude + * and altitude) along with vertical and horizontal accuracies. This class + * is different from TPositionInfo class defined in LBS and cannot be used + * interchangeably. @see TPositionInfo class for more details. + */ +NONSHARABLE_CLASS(CLbsPositionInfo) : public CLbsAreaInfoBase + { + +public: + + /** + * Allocates and constructs a new position info object. In the returned + * instance, the longitude, latitude, altitude, horizontal accuracy and + * vertical accuracy are set to NaN. + * + * @return Pointer to the new coordinate info object. + * @leave Standard symbian error codes, such as KErrNoMemory + */ + IMPORT_C static CLbsPositionInfo* NewL(); + + /** + * Allocates and constructs a new position info object, a copy of another one. + * + * @param[in] aLocality Instance of CLbsPositionInfo. + */ + IMPORT_C static CLbsPositionInfo* NewL( const CLbsPositionInfo& aPositionInfo ); + + /** + * Allocates and constructs a new position info object + * + * @param[in] aLocality Instance of TLocality class that contains + * coordinates along with the error estimates for the horizontal and + * vertical accuracy of the point. + */ + IMPORT_C static CLbsPositionInfo* NewL( const TLocality& aLocality ); + + /** + * Destructor + */ + IMPORT_C virtual ~CLbsPositionInfo(); + + /** + * Initializes the locality information. This includes + * latitude - should be between and including -90 and 90 degrees. + * longitude - should be between and including -180 and 180 degrees. + * altitude - Altitude information in meters. + * datum - datum information. Defaults to the constant for the + * coordinate system for a specific positioning system. + * horizontal accuracy - horizontal accuracy in meters. + * vertical accuracy - vertical accuracy in meters. + * + * @param[in] aLatitude Latitude information. + */ + IMPORT_C void SetLocality( const TLocality& aLocality ); + + /** + * Retrieves the Locality information. + * + * @return NaN if nothing specified or latitude information. + * network. + */ + IMPORT_C void GetLocality( TLocality& aLocality ) const; + +public: // from CLbsAreaInfoBase + + /** + * Returns the type of area information instance. + * + * @return Area type information + */ + virtual TLbsAreaInfoClassType Type(); + + /** + * Validates position information. + * This method checks for boundary conditions as well as the mandatory + * attributes. The latitude, longitude and horizontal accuracy attributes + * are mandatory and must be specified in the TLocality instance being + * passed as an argument to instantiate/initialize an instance of this + * class. + * This method is used internally to determine the correctness of + * information provided. Optionally, this method, may also be used by + * client applications to validate their input. + * + * @leave KErrArgument If the specified attributes dont meet the boundary + * conditions or the mandatory arguments are not specified. + */ + virtual void ValidateDataL() const; + +protected: // from CLbsAreaInfoBase + + /** + * Internalize method to write GSM cell information to a stream. + */ + virtual void DoInternaliseL( RReadStream& aStream ); + + /** + * Externalize method to read GSM cell information from a stream. + */ + virtual void DoExternaliseL( RWriteStream& aStream ) const; + +private: + + /** + * C++ default constructor + */ + CLbsPositionInfo(); + + /** + * Copy constructor. Prohibited by default. + */ + CLbsPositionInfo( CLbsPositionInfo& ); + + /** + * Overloaded assignment operator. Prohibited by default. + */ + CLbsPositionInfo& operator=( CLbsPositionInfo& ); + + /** + * Symbian 2 phase constructor + */ + void ConstructL(); + + /** + * Symbian 2 phase constuctor + */ + void ConstructL( const TLocality& aLocality ); + +private: // attributes + + /** + * Locality information + */ + TLocality iLocality; + + }; + +#endif //LBS_COORDINATE_INFO_H diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/ConversionDataTypes/inc/lbslocationwcdmainfo.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/ConversionDataTypes/inc/lbslocationwcdmainfo.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,300 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Data class representing a geographical area in terms of +* cell information in a WCDMA PLMN. This class may also optionally contain +* neighbouring cell information +* +*/ + +/** +* @file +* @publishedPartner +* @prototype +*/ + + +#ifndef C_LBSWCDMACELLINFO_H +#define C_LBSWCDMACELLINFO_H + + +#include +#include +#include + + +/** + * This class contains information related to a cell in WCDMA PLMN. An instance + * of this class may also contain information of one or more neighbouring + * WCDMA cells + */ +NONSHARABLE_CLASS(CLbsWcdmaCellInfo) : public CLbsAreaInfoBase + { + +public: + + /** + * Allocates and constructs a new WCDMA cell info object. In the returned + * instance, the country code, network code and cell ID are set to zero. + * + * @return Pointer to the new WCDMA cell info object. + * @leave Standard symbian error codes, such as KErrNoMemory + */ + IMPORT_C static CLbsWcdmaCellInfo* NewL(); + + /** + * Allocates and constructs a new WCDMA cell info object. + * + * @param[in] aCountryCode Network country code. + * @param[in] aNetworkCode Network code. + * @param[in] aUniqueCellId Cell ID of a cell in WCDMA PLMN. + * @return Pointer to the new WCDMA cell info object. + * @leave KErrArgument in case of invalid input or other standard symbian + * error codes, such as KErrNoMemory. + */ + IMPORT_C static CLbsWcdmaCellInfo* NewL( const TInt aCountryCode, + const TInt aNetworkCode, + const TInt aUniqueCellId ); + /** + * Allocates and constructs a WCDMA cell info object, a copy of another one. + * + * @param[in] aLocality Instance of CLbsWcdmaCellInfo. + */ + IMPORT_C static CLbsWcdmaCellInfo* NewL( const CLbsWcdmaCellInfo& aPositionInfo); + + /** + * Destructor + */ + IMPORT_C ~CLbsWcdmaCellInfo(); + + /** + * Initializes the country code attribute. + * + * @param[in] aCountryCode Network country code, range 0..999 + */ + IMPORT_C void SetMobileCountryCode( const TInt aCountryCode); + + /** + * Retrieves the country code information. + + * @return Network country code, range 0..999 + KErrNotFound if the value is undefined. + */ + IMPORT_C TInt MobileCountryCode() const; + + /** + * Initializes the network code attribute. + * + * @param[in] aNetworkCode Network code, range 0..999 + */ + IMPORT_C void SetMobileNetworkCode( const TInt aNetworkCode ); + + /** + * Retrieves the network code information. + * + * @return Network code, range 0..999 + * KErrNotFound if the value is undefined. + */ + IMPORT_C TInt MobileNetworkCode() const; + + /** + * Sets the Cell Identity. + * + * @param[in] aUniqueCellId Cell Identity, range 0..268435455. + */ + IMPORT_C void SetUniqueCellId( const TInt aUniqueCellId ); + + /** + * Retrieves the Cell Identity. + * + * @return Cell Identity, range 0..268435455. + * KErrNotFound if the value is undefined. + */ + IMPORT_C TInt UniqueCellId() const; + + /** + * Sets the scrambling code + * + * @param[in] aScramblingCode scrambling code , range 0..511. + */ + IMPORT_C void SetScramblingCode( const TInt aScramblingCode ); + + /** + * Retrieves the scrambling code . + * + * @return Base scrambling code, range 0..511. + * KErrNotFound if the value is undefined. + */ + IMPORT_C TInt ScramblingCode() const; + + /** + * Sets the RSSI parameter + * + * @param[in] aRssi Received Signal Strength Indicator, range 0..127. + */ + IMPORT_C void SetSignalStrength( const TInt aRssi ); + + /** + * Retrieves the RSSI information. + * + * @return RSSI, range 0..127. + * KErrNotFound if the value is undefined. + */ + IMPORT_C TInt SignalStrength() const; + + /** + * Adds a neighbouring cell information. + * + * @param[in] An instance of TLbsWcdmaNeighbourCellInfo class + * (memory ovnership is being transferred) + * @leave KErrArgument if the argument is NULL or one of standard symbian + * error codes + */ + IMPORT_C void AddNeighbouringCellInfoL( + TLbsWcdmaNeighbourCellInfo* aNeighbourCellInfo ); + + /** + * Retrieves a copy of neighbouring cell information information as an + * array. + * + * @param[in] aNeighbourCellInfo WCDMA neighbouring cell information + * (memory ownership is not being transferred to this function therefore + * it is the responsibility of the caller to ensure Close() is called to + * free resources) + */ + IMPORT_C void GetNeighbouringCellInfoL( + RLbsWcdmaNeighbourCellInfoArray& aNeighbourCellInfo ) const; + + /** + * Removes all neighbouring cell information. + */ + IMPORT_C void ResetNeighbouringCellInfo(); + +public: // from CLbsAreaInfoBase + + /** + * Returns the type of area information instance. + * + * @return Area type information + */ + virtual TLbsAreaInfoClassType Type(); + + /** + * Validates WCDMA information. + * This method checks for boundary conditions as well as the mandatory + * attributes. The attributes of this class become mandatory in a + * hierarchical manner. For instance, if scrambling code is specified then, + * all other attributes except the neighbouring cell information become + * mandatory. However, the mobile country code attribute is always + * mandatory which means client applications must at least specify the MCC + * attribute when specifying WCDMA cell information. + * This method is used internally to determine the correctness of + * information provided. Optionally, this method, may also be used by + * client applications to validate their input. + * + * @leave KErrArgument If the specified attributes dont meet the boundary + * conditions or the mandatory arguments are not specified. + */ + virtual void ValidateDataL() const; + +protected: // from CLbsAreaInfoBase + + /** + * Internalize method to write WCDMA cell information to a stream. + */ + virtual void DoInternaliseL( RReadStream& aStream ); + + /** + * Externalize method to read WCDMA cell information from a stream. + */ + virtual void DoExternaliseL( RWriteStream& aStream ) const; + +private: + + /** + * C++ default constructor + */ + CLbsWcdmaCellInfo(); + + /** + * Copy constructor. Prohibited by default. + */ + CLbsWcdmaCellInfo( CLbsWcdmaCellInfo& ); + + /** + * Overloaded assignment operator. Prohibited by default. + */ + CLbsWcdmaCellInfo& operator=( CLbsWcdmaCellInfo& ); + + /** + * Symbian 2 phase constructor + */ + void ConstructL(); + + /** + * Symbian 2 phase constructor + */ + void ConstructL( const TInt aCountryCode, + const TInt aNetworkCode, + const TInt aUniqueCellId ); + +private: // data + + enum _TWcdmaDataValidationMask + { + EWcdmaDataNull = 0x00, + EWcdmaMCC = 0x01, + EWcdmaMNC = 0x02, + EWcdmaUCid = 0x04, + EWcdmaSC = 0x08, + EWcdmaRSSI = 0x10, + }; + + /** + * Mobile country code + */ + TInt16 iMCC; + + /** + * Mobile network code + */ + TInt16 iMNC; + + /** + * Unique cell identifier + */ + TInt32 iUCid; + + /** + * Scrambling code + */ + TInt16 iSCode; + + /** + * RSSI + */ + TInt16 iRssi; + + /** + * Data mask to determine initialized data. Used internally. + */ + TInt8 iDataValidationMask; + + /** + * Neighbouring cell info + */ + RLbsWcdmaNeighbourCellInfoArray iNeighbourCellInfo; + + }; + +#endif // C_POSWCDMACELLINFO_H diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/ConversionDataTypes/inc/lbslocationwcdmaneighbourinfo.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/ConversionDataTypes/inc/lbslocationwcdmaneighbourinfo.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,158 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Data class representing a geographical area in terms of +* cell information in a Wcdma PLMN. This class may also optionally contain +* neighbouring cell information +* +*/ + +/** +* @file +* @publishedPartner +* @prototype +*/ + + +#ifndef LBS_WCDMA_NEIGHB_CELL_INFO_H +#define LBS_WCDMA_NEIGHB_CELL_INFO_H + + +#include +#include + + +/** + * This class contains information related to a Wcdma neighbouring cell information + */ +NONSHARABLE_CLASS(TLbsWcdmaNeighbourCellInfo) + { + +public: + + /** + * Allocates and constructs a new neighbour Wcdma cell info object. In the returned + * instance all data is marked as undefined + * + * @return Pointer to the new neighbour Wcdma cell info object. + */ + IMPORT_C TLbsWcdmaNeighbourCellInfo(); + + /** + * Allocates and constructs a new neighbour Wcdma cell info object. + * + * @param[in] aUCid Cell Identity + * @param[in] aSCode Scrambling Code + * @param[in] aPathloss Pathloss + * @param[in] Received Signal Strength Indicator + * + * @return Pointer to the new neighbour Wcdma cell info object. + */ + IMPORT_C TLbsWcdmaNeighbourCellInfo(const TInt aUCid, + const TInt aSCode, + const TInt aPathloss, + const TInt aRssi ); + + /** + * Sets the Cell Identity. + * + * @param[in] aUniqueCellId Cell Identity, range 0..268435455. + */ + IMPORT_C void SetUniqueCellId( const TInt aUniqueCellId ); + + /** + * Retrieves the Cell Identity. + * + * @return Cell Identity, range 0..268435455. + * KErrNotFound if the value is undefined. + */ + IMPORT_C TInt UniqueCellId() const; + + /** + * Sets the scrambling code + * + * @param[in] aScramblingCode scrambling code , range 0..511. + */ + IMPORT_C void SetScramblingCode( const TInt aScramblingCode ); + + /** + * Retrieves the scrambling code . + * + * @return Base scrambling code, range 0..511. + * KErrNotFound if the value is undefined. + */ + IMPORT_C TInt ScramblingCode() const; + + /** + * Sets the Pathloss parameter + * + * @param[in] aPathloss Pathloss, range 46..173. + */ + IMPORT_C void SetPathloss( const TInt aPathloss ); + + /** + * Retrieves the pathloss information. + * + * @return pathloss, range 46..173. + * KErrNotFound if the value is undefined. + */ + IMPORT_C TInt Pathloss() const; + + /** + * Sets the RSSI parameter + * + * @param[in] aRssi Received Signal Strength Indicator, range 0..127. + */ + IMPORT_C void SetSignalStrength( const TInt aRssi ); + + /** + * Retrieves the RSSI information. + * + * @return RSSI, range 0..127. + * KErrNotFound if the value is undefined. + */ + IMPORT_C TInt SignalStrength() const; + +protected: // attributes + + /** + * Cell Identity + */ + TInt32 iUniqueCellId; + + /** + * Scrambling Code + */ + TInt16 iScramblingCode; + + /** + * Path loss + */ + TInt16 iPathloss; + + /** + * RSSI + */ + TInt16 iRssi; + + /** + * Reserved + */ + TUint8 iReserved[8]; + + }; + +typedef RArray RLbsWcdmaNeighbourCellInfoArray; + + +#endif //LBS_WCDMA_NEIGHB_CELL_INFO_H diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/ConversionDataTypes/inc/lbslocationwlaninfo.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/ConversionDataTypes/inc/lbslocationwlaninfo.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,203 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Data class representing a geographical area in terms of +* WLAN MAC ID. +* +*/ + +/** +* @file +* @publishedPartner +* @prototype +*/ + + +#ifndef LBSWLANINFO_H +#define LBSWLANINFO_H + + +#include +#include + + +/** + * Length of a WLAN MAC address. + */ +const TInt KLbsWlanMacAddressLength = 18; + + +/** + * WLAN MAC address consists of six hex numbers and is typically represented as + * a string with 6, colon separated hexadecimal numbers. (e.g. 11:22:33:44:55:66) + * + * In order so save memory the LBS subsystem does not use a string. A 6 byte long + * buffer is used instead. + * + * The leftmost number of the MAC address ("11" in the example) is stored in the first + * byte of the buffer. The rightmost number of the MAC address ("66" in the example) + * is stored in the last byte of the buffer. + */ +typedef TBuf8 TLbsWlanMacAddress; + + +/** + * This class contains information related to a WLAN radio map object. + */ +NONSHARABLE_CLASS(CLbsWlanInfo) : public CLbsAreaInfoBase + { + +public: + + /** + * Allocates and constructs a new WLAN info object. In the returned + * instance, the MAC ID and signal strength values are set to zero. + * + * @return Pointer to the new WLAN info object. + * @leave Standard symbian error codes, such as KErrNoMemory + */ + IMPORT_C static CLbsWlanInfo* NewL(); + + /** + * Allocates and constructs a new WLAN info object. + * + * The validation for the arguments is hierarchical. For instance, if + * signal strength is given, then specifying MAC ID is mandatory. + * + * @param[in] aMacAddress MAC address of the WLAN AP. + * @param[in] aRxStrength AP signal strength received at the SET. + + * @return Pointer to the new WLAN info object. + * @leave KErrArgument in case of invalid input or other standard symbian + * error codes, such as KErrNoMemory. + */ + IMPORT_C static CLbsWlanInfo* NewL( const TLbsWlanMacAddress& MacAddress, + const TInt aRxStrength ); + + /** + * Allocates and constructs a Wlan info object, a copy of another one. + * + * @param[in] aLocality Instance of CLbsWlanInfo. + */ + + IMPORT_C static CLbsWlanInfo* NewL( const CLbsWlanInfo& aPositionInfo); + + /** + * Destructor + */ + IMPORT_C ~CLbsWlanInfo(); + + /** + * Initializes the MAC ID attribute. + * + * @param[in] aMacAddress MAC address of the WLAN AP + */ + IMPORT_C void SetMacAddress( const TDesC8& aMacAddress ); + + /** + * Retrieves the MAC ID information. + */ + IMPORT_C void GetMacAddress(TDes8& aMacAddress ) const; + + /** + * Initializes the AP signal strength received at the SET. + * + * @param[in] aRxStrength AP signal strength received at the SET, range 0..255 + */ + IMPORT_C void SetSignalStrength( const TInt aRxStrength ); + + /** + * Retrieves the AP signal strength received at the SET. + * + * @return AP signal strength received at the SET, range 0..255 + * KErrNotFound if the value is undefined. + */ + IMPORT_C TInt SignalStrength() const; + +public: // from CLbsAreaInfoBase + + /** + * Returns the type of area information instance. + * + * @return Area type information + */ + virtual TLbsAreaInfoClassType Type(); + + /** + * Validates WLAN information. + * This method checks for boundary conditions as well as the mandatory + * attributes. All attributes of this class are mandatory. + * This method is used internally to determine the correctness of + * information provided. Optionally, this method, may also be used by + * client applications to validate their input. + * + * @leave KErrArgument If the specified attributes dont meet the boundary + * conditions or the mandatory arguments are not specified. + */ + virtual void ValidateDataL() const; + +protected: // from CLbsAreaInfoBase + + /** + * Internalize method to write WLAN information to a stream. + */ + virtual void DoInternaliseL( RReadStream& aStream ); + + /** + * Externalize method to read WLAN information from a stream. + */ + virtual void DoExternaliseL( RWriteStream& aStream ) const; + +private: + + /** + * C++ default constructor + */ + CLbsWlanInfo(); + + /** + * Copy constructor. Prohibited by default. + */ + CLbsWlanInfo( CLbsWlanInfo& ); + + /** + * Overloaded assignment operator. Prohibited by default. + */ + CLbsWlanInfo& operator=( CLbsWlanInfo& ); + + /** + * Symbian 2 phase constructor + */ + void ConstructL(); + + /** + * Symbian 2 phase constructor + */ + void ConstructL( const TLbsWlanMacAddress& MacAddress, + const TInt aPowRx ); + +private: // data + + /** + * MAC code + */ + TLbsWlanMacAddress iMacAddress; + + /** + * Received signal strength + */ + TInt16 iPowRx; + + }; + +#endif // LBSWLANINFO_H diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/ConversionDataTypes/src/lbslocationcommon.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/ConversionDataTypes/src/lbslocationcommon.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,119 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Base class for all the class representing +* location informations. +* +*/ + + +#include +#include +#include + + +// --------------------------------------------------------------------------- +// CLbsLocationInfoBase::Type() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C TLbsLocationInfoClassType CLbsLocationInfoBase::Type() + { + return ELbsAreaInfoUnknownClass; + } + +// --------------------------------------------------------------------------- +// CLbsLocationInfoBase::~CLbsLocationInfoBase() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C CLbsLocationInfoBase::~CLbsLocationInfoBase() + { + } + +// --------------------------------------------------------------------------- +// CLbsLocationInfoBase::InternaliseL() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C void CLbsLocationInfoBase::InternaliseL( RReadStream& aStream ) + { + DoInternaliseL( aStream ); + } + +// --------------------------------------------------------------------------- +// CLbsLocationInfoBase::ExternaliseL() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C void CLbsLocationInfoBase::ExternaliseL( RWriteStream& aStream ) const + { + DoExternaliseL( aStream ); + } + +// --------------------------------------------------------------------------- +// CLbsLocationInfoBase::CLbsLocationInfoBase() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +CLbsLocationInfoBase::CLbsLocationInfoBase() + { + } + +// --------------------------------------------------------------------------- +// CLbsAreaInfoBase::Type() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C TLbsAreaInfoClassType CLbsAreaInfoBase::Type() + { + return ELbsAreaInfoUnknownClass; + } + +// --------------------------------------------------------------------------- +// CLbsAreaInfoBase::~CLbsAreaInfoBase() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C CLbsAreaInfoBase::~CLbsAreaInfoBase() + { + } + +// --------------------------------------------------------------------------- +// CLbsAreaInfoBase::~CLbsAreaInfoBase() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +CLbsAreaInfoBase::CLbsAreaInfoBase() + { + } + +// --------------------------------------------------------------------------- +// CLbsAreaInfoBase::InternaliseL() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C void CLbsAreaInfoBase::InternaliseL( RReadStream& aStream ) + { + DoInternaliseL( aStream ); + } + +// --------------------------------------------------------------------------- +// CLbsAreaInfoBase::ExternaliseL() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C void CLbsAreaInfoBase::ExternaliseL( RWriteStream& aStream ) + { + DoExternaliseL( aStream ); + } diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/ConversionDataTypes/src/lbslocationgsminfo.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/ConversionDataTypes/src/lbslocationgsminfo.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,412 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Data class representing a geographical area in terms of +* cell information in a GSM PLMN. This class may also optionally contain +* neighbouring cell information +* +*/ + + +#include +#include + + +// --------------------------------------------------------------------------- +// CPosGsmCellInfo::NewL() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C CLbsGsmCellInfo* CLbsGsmCellInfo::NewL() + { + CLbsGsmCellInfo* self = new( ELeave ) CLbsGsmCellInfo; + CleanupStack::PushL( self ); + self->ConstructL(); + CleanupStack::Pop(); + return self; + } + +// --------------------------------------------------------------------------- +// CLbsGsmCellInfo::NewL() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C CLbsGsmCellInfo* CLbsGsmCellInfo::NewL( const TInt aCountryCode, + const TInt aNetworkCode, + const TInt aLocationAreaCode, + const TInt aCellId ) + { + CLbsGsmCellInfo* self = new( ELeave ) CLbsGsmCellInfo; + CleanupStack::PushL( self ); + self->ConstructL( aCountryCode, aNetworkCode, aLocationAreaCode, aCellId ); + CleanupStack::Pop(); + return self; + } + +EXPORT_C CLbsGsmCellInfo* CLbsGsmCellInfo::NewL( const CLbsGsmCellInfo& aPositionInfo ) + { + CLbsGsmCellInfo* self = CLbsGsmCellInfo::NewL(aPositionInfo.iMCC,aPositionInfo.iMNC,aPositionInfo.iLAC,aPositionInfo.iCid); + + self->iRxLev = aPositionInfo.iRxLev; + self->iTA = aPositionInfo.iTA; + self->iDataValidationMask = aPositionInfo.iDataValidationMask; + + RLbsGsmNeighbourCellInfoArray neighbourCellInfoArray; + aPositionInfo.GetNeighbouringCellInfoL(neighbourCellInfoArray); + + for (TInt i=0; i < neighbourCellInfoArray.Count(); i++) + { + TLbsGsmNeighbourCellInfo neighbourCellInfo = neighbourCellInfoArray[i]; + self->AddNeighbouringCellInfoL(&neighbourCellInfo); + } + neighbourCellInfoArray.Close(); + + return self; + + } + + +// --------------------------------------------------------------------------- +// CLbsGsmCellInfo::~CLbsGsmCellInfo() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C CLbsGsmCellInfo::~CLbsGsmCellInfo() + { + ResetNeighbouringCellInfo(); + } + +// --------------------------------------------------------------------------- +// CLbsGsmCellInfo::SetMobileCountryCodeL() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C void CLbsGsmCellInfo::SetMobileCountryCode( const TInt aCountryCode ) + { + iMCC = aCountryCode; + iDataValidationMask |= EGsmMCC; + } + +// --------------------------------------------------------------------------- +// CLbsGsmCellInfo::MobileCountryCode() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C TInt CLbsGsmCellInfo::MobileCountryCode() const + { + return iMCC; + } + +// --------------------------------------------------------------------------- +// CLbsGsmCellInfo::SetMobileNetworkCodeL() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C void CLbsGsmCellInfo::SetMobileNetworkCode( const TInt aNetworkCode ) + { + iMNC = aNetworkCode; + iDataValidationMask |= EGsmMNC; + } + +// --------------------------------------------------------------------------- +// CLbsGsmCellInfo::MobileNetworkCodeL() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C TInt CLbsGsmCellInfo::MobileNetworkCode() const + { + return iMNC; + } + +// --------------------------------------------------------------------------- +// CLbsGsmCellInfo::SetLocationAreaCode() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C void CLbsGsmCellInfo::SetLocationAreaCode( const TInt aLocationAreaCode ) + { + iLAC = aLocationAreaCode; + iDataValidationMask |= EGsmLAC; + } + +// --------------------------------------------------------------------------- +// CLbsGsmCellInfo::LocationAreaCode() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C TInt CLbsGsmCellInfo::LocationAreaCode() const + { + return iLAC; + } + +// --------------------------------------------------------------------------- +// CLbsGsmCellInfo::SetCellId() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C void CLbsGsmCellInfo::SetCellId( const TInt aCellId ) + { + iCid = aCellId; + iDataValidationMask |= EGsmCI; + } + +// --------------------------------------------------------------------------- +// CLbsGsmCellInfo::CellId() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C TInt CLbsGsmCellInfo::CellId() const + { + return iCid; + } + +// --------------------------------------------------------------------------- +// CLbsGsmCellInfo::SetSetRxLevel() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C void CLbsGsmCellInfo::SetRxLevel( const TInt aRxLev ) + { + iRxLev = aRxLev; + iDataValidationMask |= EGsmRx; + } + +// --------------------------------------------------------------------------- +// CLbsGsmCellInfo::RxLevel() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C TInt CLbsGsmCellInfo::RxLevel() const + { + return iRxLev; + } + +// --------------------------------------------------------------------------- +// CLbsGsmCellInfo::SetTimingAdvance() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C void CLbsGsmCellInfo::SetTimingAdvance( const TInt aTimingAdvance ) + { + iTA = aTimingAdvance; + iDataValidationMask |= EGsmTA; + } + +// --------------------------------------------------------------------------- +// CLbsGsmCellInfo::TimingAdvance() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C TInt CLbsGsmCellInfo::TimingAdvance() const + { + return iTA; + } + +// --------------------------------------------------------------------------- +// CLbsGsmCellInfo::SetNeighbouringCellInfoList() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C void CLbsGsmCellInfo::AddNeighbouringCellInfoL( + TLbsGsmNeighbourCellInfo* + aNeighbourCellInfo ) + { + if( !aNeighbourCellInfo ) + { + User::Leave( KErrArgument ); + } + + TLbsGsmNeighbourCellInfo neighbourCellInfo; + neighbourCellInfo.SetArfcn( aNeighbourCellInfo->Arfcn() ); + neighbourCellInfo.SetBsic( aNeighbourCellInfo->Bsic() ); + neighbourCellInfo.SetRxLevel( aNeighbourCellInfo->RxLevel() ); + + iNeighbourCellInfo.Append( neighbourCellInfo ); + } + +// --------------------------------------------------------------------------- +// CLbsGsmCellInfo::GetNeighbouringCellInfoL() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C void CLbsGsmCellInfo::GetNeighbouringCellInfoL( + RLbsGsmNeighbourCellInfoArray& + aNeighbourCellInfo ) const + { + for( TInt i = 0; i < iNeighbourCellInfo.Count(); i++ ) + { + aNeighbourCellInfo.AppendL( iNeighbourCellInfo[i] ); + } + } + + +// --------------------------------------------------------------------------- +// CLbsGsmCellInfo::ResetNeighbouringCellInfo() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C void CLbsGsmCellInfo::ResetNeighbouringCellInfo() + { + iNeighbourCellInfo.Reset(); + } + +// --------------------------------------------------------------------------- +// CLbsGsmCellInfo::Type() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +TLbsAreaInfoClassType CLbsGsmCellInfo::Type() + { + return ELbsAreaGsmCellInfoClass; + } + +// --------------------------------------------------------------------------- +// CLbsGsmCellInfo::DoInternaliseL() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +void CLbsGsmCellInfo::DoInternaliseL( RReadStream& aStream ) + { + iMCC = aStream.ReadInt16L(); + iMNC = aStream.ReadInt16L(); + iLAC = aStream.ReadInt32L(); + iCid = aStream.ReadInt32L(); + iRxLev = aStream.ReadInt8L(); + iTA = aStream.ReadInt16L(); + TInt count = aStream.ReadInt8L(); + for( TInt i = 0;i < count;i++ ) + { + TLbsGsmNeighbourCellInfo cellInfo; + cellInfo.SetArfcn( aStream.ReadInt16L() ); + cellInfo.SetBsic( aStream.ReadInt8L() ); + cellInfo.SetRxLevel( aStream.ReadInt8L() ); + iNeighbourCellInfo.AppendL( cellInfo ); + } + } + +// --------------------------------------------------------------------------- +// CLbsGsmCellInfo::DoExternaliseL() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +void CLbsGsmCellInfo::DoExternaliseL( RWriteStream& aStream ) const + { + aStream.WriteInt16L( iMCC ); + aStream.WriteInt16L( iMNC ); + aStream.WriteInt32L( iLAC ); + aStream.WriteInt32L( iCid ); + aStream.WriteInt8L( iRxLev ); + aStream.WriteInt16L( iTA ); + TInt count = iNeighbourCellInfo.Count(); + aStream.WriteInt8L( count ); + for( TInt i = 0;i < count;i++ ) + { + aStream.WriteInt16L( iNeighbourCellInfo[i].Arfcn() ); + aStream.WriteInt8L( iNeighbourCellInfo[i].Bsic() ); + aStream.WriteInt8L( iNeighbourCellInfo[i].RxLevel() ); + } + } + +// --------------------------------------------------------------------------- +// CLbsGsmCellInfo::ValidateAreaInfoL() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +void CLbsGsmCellInfo::ValidateDataL() const + { + // The following condition is to check the hierarchy of data values specified + if( ( iMCC < 0 || iMCC > 999 ) || ( iMNC < 0 && iLAC > -1 ) || + ( iLAC < 0 && iCid > -1 ) || ( iCid < 0 && iTA > -1 ) || + ( iCid < 0 && iRxLev > -1 ) || + ( iCid < 0 && iNeighbourCellInfo.Count() ) ) + User::Leave( KErrArgument ); + + // Check for range values if they are set specifically by clients + if( iDataValidationMask & EGsmMNC ) + { + if( iMNC < 0 || iMNC > 999 ) + User::Leave( KErrArgument ); + } + if( iDataValidationMask & EGsmLAC ) + { + if( iLAC < 0 || iLAC > 65535 ) + User::Leave( KErrArgument ); + } + if( iDataValidationMask & EGsmCI ) + { + if( iCid < 0 || iCid > 65535 ) + User::Leave( KErrArgument ); + } + if( iDataValidationMask & EGsmRx ) + { + if( iRxLev < 0 || iRxLev > 63 ) + User::Leave( KErrArgument ); + } + if( iDataValidationMask & EGsmTA ) + { + if( iTA < 0 || iTA > 255 ) + User::Leave( KErrArgument ); + } + + // Check neighbouring cell information + for( TInt i = 0; i < iNeighbourCellInfo.Count(); i++ ) + { + if( iNeighbourCellInfo[i].Arfcn() < 0 || iNeighbourCellInfo[i].Arfcn() > 1023 || + iNeighbourCellInfo[i].Bsic() < 0 || iNeighbourCellInfo[i].Bsic() > 63 || + iNeighbourCellInfo[i].RxLevel() < 0 || iNeighbourCellInfo[i].RxLevel() > 63 ) + { + User::Leave( KErrArgument ); + } + } + } + +// --------------------------------------------------------------------------- +// CLbsGsmCellInfo::CLbsGsmCellInfo() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +CLbsGsmCellInfo::CLbsGsmCellInfo() + { + } + +// --------------------------------------------------------------------------- +// CLbsGsmCellInfo::CLbsGsmCellInfo() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +void CLbsGsmCellInfo::ConstructL() + { + iMCC = -1; + iMNC = -1; + iLAC = -1; + iCid = -1; + iRxLev = -1; + iTA = -1; + iDataValidationMask = EGsmDataNull; + } + +// --------------------------------------------------------------------------- +// CLbsGsmCellInfo::CLbsGsmCellInfo() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +void CLbsGsmCellInfo::ConstructL( const TInt aCountryCode, const TInt aNetworkCode, + const TInt aLocationAreaCode, const TInt aCellId ) + { + SetMobileCountryCode( aCountryCode ); + SetMobileNetworkCode( aNetworkCode ); + SetLocationAreaCode( aLocationAreaCode ); + SetCellId( aCellId ); + iRxLev = -1; + iTA = -1; + } diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/ConversionDataTypes/src/lbslocationgsmneighbourinfo.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/ConversionDataTypes/src/lbslocationgsmneighbourinfo.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,107 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Data class representing a neighbouring cell +* information in a GSM PLMN. +* +*/ + + +#include + + +// --------------------------------------------------------------------------- +// TLbsGsmNeighbourCellInfo::TLbsGsmNeighbourCellInfo() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C TLbsGsmNeighbourCellInfo::TLbsGsmNeighbourCellInfo() + { + iARFCN = -1; + iBSIC = -1; + iRxLev = -1; + } + +// --------------------------------------------------------------------------- +// TLbsGsmNeighbourCellInfo::TLbsGsmNeighbourCellInfo() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C TLbsGsmNeighbourCellInfo::TLbsGsmNeighbourCellInfo( const TInt aARFCN, + const TInt aBSIC, + const TInt aRxLev ) + { + iARFCN = aARFCN; + iBSIC = aBSIC; + iRxLev = aRxLev; + } + +// --------------------------------------------------------------------------- +// TLbsGsmNeighbourCellInfo::SetArfcn() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C void TLbsGsmNeighbourCellInfo::SetArfcn( const TInt aARFCN ) + { + iARFCN = aARFCN; + } + +// --------------------------------------------------------------------------- +// TLbsGsmNeighbourCellInfo::TLbsGsmNeighbourCellInfo() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C TInt TLbsGsmNeighbourCellInfo::Arfcn() const + { + return iARFCN; + } + +// --------------------------------------------------------------------------- +// TLbsGsmNeighbourCellInfo::SetBsic() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C void TLbsGsmNeighbourCellInfo::SetBsic( const TInt aBSIC ) + { + iBSIC = aBSIC; + } + +// --------------------------------------------------------------------------- +// TLbsGsmNeighbourCellInfo::Bsic() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C TInt TLbsGsmNeighbourCellInfo::Bsic() const + { + return iBSIC; + } + +// --------------------------------------------------------------------------- +// TLbsGsmNeighbourCellInfo::SetRxLevel() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C void TLbsGsmNeighbourCellInfo::SetRxLevel( const TInt aRxLev ) + { + iRxLev = aRxLev; + } + +// --------------------------------------------------------------------------- +// TLbsGsmNeighbourCellInfo::RxLevel() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C TInt TLbsGsmNeighbourCellInfo::RxLevel() const + { + return iRxLev; + } diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/ConversionDataTypes/src/lbslocationinfo.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/ConversionDataTypes/src/lbslocationinfo.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,290 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Container class representing geographical area information as a +* collection of GSM/WCDMA cell information and WLAN MAC IDs. +* +*/ + + +#include +#include +#include + + +// --------------------------------------------------------------------------- +// CLbsLocationInfo::NewL() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C CLbsLocationInfo* CLbsLocationInfo::NewL() + { + CLbsLocationInfo* self = new( ELeave ) CLbsLocationInfo; + CleanupStack::PushL( self ); + self->ConstructL(); + CleanupStack::Pop(); + return self; + } + +// --------------------------------------------------------------------------- +// CLbsLocationInfo::NewLC() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C CLbsLocationInfo* CLbsLocationInfo::NewLC() + { + CLbsLocationInfo* self = new( ELeave ) CLbsLocationInfo; + CleanupStack::PushL( self ); + self->ConstructL(); + return self; + } + +// --------------------------------------------------------------------------- +// CLbsLocationInfo::~CLbsLocationInfo() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C CLbsLocationInfo::~CLbsLocationInfo() + { + iAreaInfoArray.ResetAndDestroy(); + } + +// --------------------------------------------------------------------------- +// CLbsLocationInfo::AddAreaInfoL() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C void CLbsLocationInfo::AddAreaInfoL( CLbsAreaInfoBase* + aAreaInfo ) + { + if( !aAreaInfo ) + { + User::Leave( KErrArgument ); + } + iAreaInfoArray.AppendL( aAreaInfo ); + } + +// --------------------------------------------------------------------------- +// CLbsLocationInfo::GetAreaInfoL() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C void CLbsLocationInfo::GetAreaInfoL( RLbsAreaInfoBaseArray& aAreaInfoArray, + TAreaInfoMask aAreaInfoMask ) + { + + for( TInt i = 0; i < iAreaInfoArray.Count(); i++ ) + { + switch( iAreaInfoArray[i]->Type() ) + { + case ELbsAreaPositionInfoClass: + if( aAreaInfoMask & ELbsPosInfo ) + { + // an object that is a copy of the CLbsPositionInfo + // object that is owned by the CLbsAreaInfoBase object + // is created. Note, ownership of this is passed to + // the caller of GetAreaInfo so the caller needs to do + // a ResetAndDestroy on the array to clean up. + + CLbsPositionInfo* posInfo = static_cast( iAreaInfoArray[i] ); + + CLbsPositionInfo* copyOfPosInfo = CLbsPositionInfo::NewL(*posInfo); + CleanupStack::PushL(copyOfPosInfo ); + aAreaInfoArray.AppendL(copyOfPosInfo); + CleanupStack::Pop(copyOfPosInfo); // ownership transferred to instance of CLbsLocationInfo + + } + break; + + case ELbsAreaGsmCellInfoClass: + if( aAreaInfoMask & ELbsGsmInfo ) + { + CLbsGsmCellInfo* cellInfo = static_cast( iAreaInfoArray[i]); + CLbsGsmCellInfo* copyOfGsmCellInfo = CLbsGsmCellInfo::NewL(*cellInfo); + CleanupStack::PushL(copyOfGsmCellInfo ); + aAreaInfoArray.AppendL( copyOfGsmCellInfo ); + CleanupStack::Pop(copyOfGsmCellInfo); // ownership transferred to instance of CLbsLocationInfo + + } + break; + + case ELbsAreaWcmdaCellInfoClass: + if( aAreaInfoMask & ELbsWcdmaInfo ) + { + CLbsWcdmaCellInfo* wcdaCellInfo = static_cast( iAreaInfoArray[i]); + CLbsWcdmaCellInfo* copyOfWcdaCellInfo = CLbsWcdmaCellInfo::NewL(*wcdaCellInfo); + CleanupStack::PushL(copyOfWcdaCellInfo ); + aAreaInfoArray.AppendL(copyOfWcdaCellInfo); + CleanupStack::Pop(copyOfWcdaCellInfo ); // ownership transferred to instance of CLbsLocationInfo + } + break; + + case ELbsAreaWlanInfoClass: + if( aAreaInfoMask & ELbsWlanInfo ) + { + CLbsWlanInfo* wlanInfo = static_cast( iAreaInfoArray[i]); + CLbsWlanInfo* copyOfWlanInfo = CLbsWlanInfo::NewL(*wlanInfo); + CleanupStack::PushL(copyOfWlanInfo ); + aAreaInfoArray.AppendL(copyOfWlanInfo); + CleanupStack::Pop(copyOfWlanInfo ); // ownership transferred to instance of CLbsLocationInfo + } + break; + + default: + break; + } + } + } + +// --------------------------------------------------------------------------- +// CLbsLocationInfo::ResetAreaInfo() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C void CLbsLocationInfo::ResetAreaInfo( TAreaInfoMask aAreaInfoMask ) + { + // If the mask reflects reset all,then reset and destroy is called on + // areaInfoArray directly + if( aAreaInfoMask == ELbsAreaInfoAll ) + { + iAreaInfoArray.ResetAndDestroy(); + return; + } + + for( TInt i = 0; i < iAreaInfoArray.Count(); i++ ) + { + switch( iAreaInfoArray[i]->Type() ) + { + case ELbsAreaPositionInfoClass: + if( aAreaInfoMask & ELbsPosInfo ) + { + CLbsAreaInfoBase* areaInfo = iAreaInfoArray[i]; + iAreaInfoArray.Remove( i ); + delete areaInfo; + } + break; + + case ELbsAreaGsmCellInfoClass: + if( aAreaInfoMask & ELbsGsmInfo ) + { + CLbsAreaInfoBase* areaInfo = iAreaInfoArray[i]; + iAreaInfoArray.Remove( i ); + delete areaInfo; + } + break; + + case ELbsAreaWcmdaCellInfoClass: + if( aAreaInfoMask & ELbsWcdmaInfo ) + { + CLbsAreaInfoBase* areaInfo = iAreaInfoArray[i]; + iAreaInfoArray.Remove( i ); + delete areaInfo; + } + break; + + case ELbsAreaWlanInfoClass: + if( aAreaInfoMask & ELbsWlanInfo ) + { + CLbsAreaInfoBase* areaInfo = iAreaInfoArray[i]; + iAreaInfoArray.Remove( i ); + delete areaInfo; + } + break; + + default: + break; + } + } + } + + +// --------------------------------------------------------------------------- +// CLbsLocationInfo::Type() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C TLbsLocationInfoClassType CLbsLocationInfo::Type() + { + return ELbsLocationInfoClass; + } + +// --------------------------------------------------------------------------- +// CLbsLocationInfo::DoInternaliseL() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +void CLbsLocationInfo::DoInternaliseL( RReadStream& aStream ) + { + TInt count = aStream.ReadInt8L(); + for( TInt i = 0; i < count; i++ ) + { + TLbsAreaInfoClassType type = aStream.ReadUint16L(); + CLbsAreaInfoBase* area = NULL; + if( ELbsAreaPositionInfoClass == type ) + { + area = CLbsPositionInfo::NewL(); + } + if( ELbsAreaGsmCellInfoClass == type ) + { + area = CLbsGsmCellInfo::NewL(); + } + if( ELbsAreaWcmdaCellInfoClass == type ) + { + area = CLbsWcdmaCellInfo::NewL(); + } + if( ELbsAreaWlanInfoClass == type ) + { + area = CLbsWlanInfo::NewL(); + } + if( area ) + { + area->InternaliseL( aStream ); + iAreaInfoArray.AppendL( area ); + } + } + } + +// --------------------------------------------------------------------------- +// CLbsLocationInfo::DoExternaliseL() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +void CLbsLocationInfo::DoExternaliseL( RWriteStream& aStream ) const + { + TInt count = iAreaInfoArray.Count(); + aStream.WriteInt8L( count ); + for( TInt i = 0; i < count; i++ ) + { + TLbsAreaInfoClassType type = iAreaInfoArray[i]->Type(); + aStream.WriteUint16L( type ); + iAreaInfoArray[i]->ExternaliseL( aStream ); + } + } + +// --------------------------------------------------------------------------- +// CLbsLocationInfo::CLbsLocationInfo() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +CLbsLocationInfo::CLbsLocationInfo() + { + } + +// --------------------------------------------------------------------------- +// CLbsLocationInfo::ConstructL() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +void CLbsLocationInfo::ConstructL() + { + } diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/ConversionDataTypes/src/lbslocationposinfo.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/ConversionDataTypes/src/lbslocationposinfo.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,177 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Data class representing a geographical area in terms of +* latitude,longitude,altitude,horizontal accuracy and vertical accuracy. +* +*/ + + +#include +#include +#include + + +// --------------------------------------------------------------------------- +// CLbsPositionInfo::NewL() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C CLbsPositionInfo* CLbsPositionInfo::NewL() + { + CLbsPositionInfo* self = new( ELeave ) CLbsPositionInfo; + CleanupStack::PushL( self ); + self->ConstructL(); + CleanupStack::Pop(); + return self; + } + +EXPORT_C CLbsPositionInfo* CLbsPositionInfo::NewL( const CLbsPositionInfo& aPositionInfo ) + { + TLocality locality; + + aPositionInfo.GetLocality(locality); + CLbsPositionInfo* self = CLbsPositionInfo::NewL( locality ); + return self; + + } + +// --------------------------------------------------------------------------- +// CLbsPositionInfo::NewL() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C CLbsPositionInfo* CLbsPositionInfo::NewL( const TLocality& aLocality ) + { + CLbsPositionInfo* self = new( ELeave ) CLbsPositionInfo; + CleanupStack::PushL( self ); + self->ConstructL( aLocality ); + CleanupStack::Pop(); + return self; + } + +// --------------------------------------------------------------------------- +// CLbsPositionInfo::~CLbsPositionInfo() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C CLbsPositionInfo::~CLbsPositionInfo() + { + } + +// --------------------------------------------------------------------------- +// CLbsPositionInfo::SetLocality() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C void CLbsPositionInfo::SetLocality( + const TLocality& aLocality ) + { + iLocality = aLocality; + } + +// --------------------------------------------------------------------------- +// CLbsPositionInfo::Locality() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C void CLbsPositionInfo::GetLocality( TLocality& aLocality ) const + { + aLocality = iLocality; + } + +// --------------------------------------------------------------------------- +// CLbsPositionInfo::Type() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +TLbsAreaInfoClassType CLbsPositionInfo::Type() + { + return ELbsAreaPositionInfoClass; + } + +// --------------------------------------------------------------------------- +// CLbsPositionInfo::ValidateAreaInfoL() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +void CLbsPositionInfo::ValidateDataL() const + { + if( Math::IsNaN( iLocality.Latitude() ) || + Math::IsNaN( iLocality.Longitude() ) || + iLocality.HorizontalAccuracy() < 0.0 ) + { + User::Leave( KErrArgument ); + } + } + +// --------------------------------------------------------------------------- +// CLbsPositionInfo::DoInternaliseL() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +void CLbsPositionInfo::DoInternaliseL( RReadStream& aStream ) + { + TReal64 latitude = aStream.ReadReal64L(); + TReal64 longitude = aStream.ReadReal64L(); + TReal32 altitude = aStream.ReadReal32L(); + iLocality.SetCoordinate( latitude, longitude, altitude ); + TInt datum = aStream.ReadInt32L(); + iLocality.SetDatum( TUid::Uid( datum ) ); + TReal32 hAccuracy = aStream.ReadReal32L(); + TReal32 vAccuracy = aStream.ReadReal32L(); + iLocality.SetAccuracy( hAccuracy, vAccuracy ); + } + +// --------------------------------------------------------------------------- +// CLbsPositionInfo::DoExternaliseL() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +void CLbsPositionInfo::DoExternaliseL( RWriteStream& aStream ) const + { + aStream.WriteReal64L( iLocality.Latitude() ); + aStream.WriteReal64L( iLocality.Longitude() ); + aStream.WriteReal32L( iLocality.Altitude() ); + aStream.WriteInt32L( iLocality.Datum().iUid ); + aStream.WriteReal32L( iLocality.HorizontalAccuracy() ); + aStream.WriteReal32L( iLocality.VerticalAccuracy() ); + } + +// --------------------------------------------------------------------------- +// CLbsPositionInfo::CLbsPositionInfo() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +CLbsPositionInfo::CLbsPositionInfo() + { + } + +// --------------------------------------------------------------------------- +// CLbsPositionInfo::ConstructL() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +void CLbsPositionInfo::ConstructL() + { + } + +// --------------------------------------------------------------------------- +// CLbsPositionInfo::ConstructL() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +void CLbsPositionInfo::ConstructL( const TLocality& aLocality ) + { + SetLocality( aLocality ); + } diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/ConversionDataTypes/src/lbslocationwcdmainfo.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/ConversionDataTypes/src/lbslocationwcdmainfo.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,386 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Data class representing a geographical area in terms of +* cell information in a WCDMA PLMN. This class may also optionally contain +* neighbouring cell information +* +*/ + + +#include +#include + + +// --------------------------------------------------------------------------- +// CLbsWcdmaCellInfo::NewL() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C CLbsWcdmaCellInfo* CLbsWcdmaCellInfo::NewL() + { + CLbsWcdmaCellInfo* self = new( ELeave ) CLbsWcdmaCellInfo; + CleanupStack::PushL( self ); + self->ConstructL(); + CleanupStack::Pop(); + return self; + } + +// --------------------------------------------------------------------------- +// CLbsWcdmaCellInfo::NewL() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C CLbsWcdmaCellInfo* CLbsWcdmaCellInfo::NewL( const TInt aCountryCode, + const TInt aNetworkCode, + const TInt aUniqueCellId ) + { + CLbsWcdmaCellInfo* self = new( ELeave ) CLbsWcdmaCellInfo; + CleanupStack::PushL( self ); + self->ConstructL( aCountryCode, aNetworkCode, aUniqueCellId ); + CleanupStack::Pop(); + return self; + } + +EXPORT_C CLbsWcdmaCellInfo* CLbsWcdmaCellInfo::NewL( const CLbsWcdmaCellInfo& aPositionInfo ) + { + + CLbsWcdmaCellInfo* self = CLbsWcdmaCellInfo::NewL( aPositionInfo.iMCC,aPositionInfo.iMNC,aPositionInfo.iUCid); + self->iSCode = aPositionInfo.iSCode; + + RLbsWcdmaNeighbourCellInfoArray neighbourCellInfoArray; + aPositionInfo.GetNeighbouringCellInfoL(neighbourCellInfoArray); + + for (TInt i=0; i < neighbourCellInfoArray.Count(); i++) + { + TLbsWcdmaNeighbourCellInfo neighbourCellInfo = neighbourCellInfoArray[i]; + self->AddNeighbouringCellInfoL(&neighbourCellInfo); + } + + self->iDataValidationMask = aPositionInfo.iDataValidationMask; + + neighbourCellInfoArray.Close(); + + return self; + } +// --------------------------------------------------------------------------- +// CLbsWcdmaCellInfo::~CLbsWcdmaCellInfo() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C CLbsWcdmaCellInfo::~CLbsWcdmaCellInfo() + { + ResetNeighbouringCellInfo(); + } + +// --------------------------------------------------------------------------- +// CLbsWcdmaCellInfo::SetMobileCountryCode() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C void CLbsWcdmaCellInfo::SetMobileCountryCode( const TInt aCountryCode ) + { + iMCC = aCountryCode; + iDataValidationMask |= EWcdmaMCC; + } + +// --------------------------------------------------------------------------- +// CLbsWcdmaCellInfo::MobileCountryCode() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C TInt CLbsWcdmaCellInfo::MobileCountryCode() const + { + return iMCC; + } + +// --------------------------------------------------------------------------- +// CLbsWcdmaCellInfo::SetMobileNetworkCode() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C void CLbsWcdmaCellInfo::SetMobileNetworkCode( const TInt aNetworkCode ) + { + iMNC = aNetworkCode; + iDataValidationMask |= EWcdmaMNC; + } + +// --------------------------------------------------------------------------- +// CLbsWcdmaCellInfo::MobileNetworkCode() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C TInt CLbsWcdmaCellInfo::MobileNetworkCode() const + { + return iMNC; + } + +// --------------------------------------------------------------------------- +// CLbsWcdmaCellInfo::SetUniqueCellId() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C void CLbsWcdmaCellInfo::SetUniqueCellId( const TInt aUniqueCellId ) + { + iUCid = aUniqueCellId; + iDataValidationMask |= EWcdmaUCid; + } + +// --------------------------------------------------------------------------- +// CLbsWcdmaCellInfo::UniqueCellId() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C TInt CLbsWcdmaCellInfo::UniqueCellId() const + { + return iUCid; + } + +// --------------------------------------------------------------------------- +// CLbsWcdmaCellInfo::SetScramblingCode() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C void CLbsWcdmaCellInfo::SetScramblingCode( const TInt aScramblingCode ) + { + iSCode = aScramblingCode; + iDataValidationMask |= EWcdmaSC; + } + +// --------------------------------------------------------------------------- +// CLbsWcdmaCellInfo::ScramblingCode() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C TInt CLbsWcdmaCellInfo::ScramblingCode() const + { + return iSCode; + } + +// --------------------------------------------------------------------------- +// CLbsWcdmaCellInfo::SetSignalStrength() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C void CLbsWcdmaCellInfo::SetSignalStrength( const TInt aRssi ) + { + iRssi = aRssi; + } + +// --------------------------------------------------------------------------- +// CLbsWcdmaCellInfo::SignalStrength() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C TInt CLbsWcdmaCellInfo::SignalStrength() const + { + return iRssi; + } + +// --------------------------------------------------------------------------- +// CLbsWcdmaCellInfo::AddNeighbouringCellInfoL() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C void CLbsWcdmaCellInfo::AddNeighbouringCellInfoL( + TLbsWcdmaNeighbourCellInfo* + aNeighbourCellInfo ) + { + if( !aNeighbourCellInfo ) + { + User::Leave( KErrArgument ); + } + TLbsWcdmaNeighbourCellInfo wcdmaNeighbourCellInfo; + wcdmaNeighbourCellInfo.SetUniqueCellId( aNeighbourCellInfo->UniqueCellId()); + wcdmaNeighbourCellInfo.SetScramblingCode( aNeighbourCellInfo->ScramblingCode() ); + wcdmaNeighbourCellInfo.SetSignalStrength( aNeighbourCellInfo->SignalStrength() ); + wcdmaNeighbourCellInfo.SetPathloss( aNeighbourCellInfo->Pathloss() ); + iNeighbourCellInfo.AppendL( wcdmaNeighbourCellInfo ); + } + +// --------------------------------------------------------------------------- +// CLbsWcdmaCellInfo::SetNeighbouringCellInfoList() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C void CLbsWcdmaCellInfo::GetNeighbouringCellInfoL( + RLbsWcdmaNeighbourCellInfoArray& + aNeighbourCellInfoList ) const + { + for( TInt i = 0; i < iNeighbourCellInfo.Count(); i++ ) + { + aNeighbourCellInfoList.AppendL( iNeighbourCellInfo[i] ); + } + } + +// --------------------------------------------------------------------------- +// CLbsWcdmaCellInfo::ResetNeighbouringCellInfo() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C void CLbsWcdmaCellInfo::ResetNeighbouringCellInfo() + { + iNeighbourCellInfo.Reset(); + } + +// --------------------------------------------------------------------------- +// CLbsWcdmaCellInfo::Type() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +TLbsAreaInfoClassType CLbsWcdmaCellInfo::Type() + { + return ELbsAreaWcmdaCellInfoClass; + } + +// --------------------------------------------------------------------------- +// CLbsWcdmaCellInfo::DoInternaliseL() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +void CLbsWcdmaCellInfo::DoInternaliseL( RReadStream& aStream ) + { + iMCC = aStream.ReadInt16L(); + iMNC = aStream.ReadInt16L(); + iUCid = aStream.ReadInt32L(); + iSCode = aStream.ReadInt16L(); + iRssi = aStream.ReadInt16L(); + + TInt count = aStream.ReadInt16L(); + for( TInt i = 0; i < count; i++ ) + { + TLbsWcdmaNeighbourCellInfo cellInfo; + cellInfo.SetUniqueCellId( aStream.ReadInt32L() ); + cellInfo.SetScramblingCode( aStream.ReadInt16L() ); + cellInfo.SetPathloss( aStream.ReadInt16L() ); + cellInfo.SetSignalStrength( aStream.ReadInt16L() ); + iNeighbourCellInfo.Append( cellInfo ); + } + } + +// --------------------------------------------------------------------------- +// CLbsWcdmaCellInfo::DoExternaliseL() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +void CLbsWcdmaCellInfo::DoExternaliseL( RWriteStream& aStream )const + { + aStream.WriteInt16L( iMCC ); + aStream.WriteInt16L( iMNC ); + aStream.WriteInt32L( iUCid ); + aStream.WriteInt16L( iSCode ); + aStream.WriteInt16L( iRssi ); + + TInt count = iNeighbourCellInfo.Count(); + aStream.WriteInt16L( count ); + for( TInt i = 0; i < count; i++ ) + { + aStream.WriteInt32L( iNeighbourCellInfo[i].UniqueCellId() ); + aStream.WriteInt16L( iNeighbourCellInfo[i].ScramblingCode() ); + aStream.WriteInt16L( iNeighbourCellInfo[i].Pathloss() ); + aStream.WriteInt16L( iNeighbourCellInfo[i].SignalStrength() ); + } + } + +// --------------------------------------------------------------------------- +// CLbsWcdmaCellInfo::ValidateAreaInfoL() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +void CLbsWcdmaCellInfo::ValidateDataL() const + { + // The following condition is to check the hierarchy of data values specified + if( ( iMCC < 0 || iMCC > 999 ) || + ( iMNC < 0 && iUCid > -1 ) || + ( iUCid < 0 && iSCode > -1 ) || + ( iUCid < 0 && iRssi > -1 ) || + ( iUCid < 0 && iNeighbourCellInfo.Count() ) ) + User::Leave( KErrArgument ); + + // Check for range values if they are set specifically by clients + if( iDataValidationMask & EWcdmaMNC ) + { + if( iMNC < 0 || iMNC > 999 ) + User::Leave( KErrArgument ); + } + if( iDataValidationMask & EWcdmaUCid ) + { + if( iUCid < 0 || iUCid > 268435455 ) + User::Leave( KErrArgument ); + } + if( iDataValidationMask & EWcdmaSC ) + { + if( iSCode < 0 || iSCode > 511 ) + User::Leave( KErrArgument ); + } + if ( iDataValidationMask & EWcdmaRSSI ) + { + if( iRssi < 0 || iRssi > 127 ) + User::Leave( KErrArgument ); + } + + for( TInt i = 0; i < iNeighbourCellInfo.Count(); i++ ) + { + if( iNeighbourCellInfo[i].UniqueCellId() < 0 || + iNeighbourCellInfo[i].UniqueCellId() > 268435455 || + iNeighbourCellInfo[i].ScramblingCode() < 0 || + iNeighbourCellInfo[i].ScramblingCode() > 511 || + iNeighbourCellInfo[i].Pathloss() < 46 || + iNeighbourCellInfo[i].Pathloss() > 173 || + iNeighbourCellInfo[i].SignalStrength() < 0 || + iNeighbourCellInfo[i].SignalStrength() > 127 ) + { + User::Leave( KErrArgument ); + } + } + } + +// --------------------------------------------------------------------------- +// CLbsWcdmaCellInfo::CLbsWcdmaCellInfo() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +CLbsWcdmaCellInfo::CLbsWcdmaCellInfo() + { + } + +// --------------------------------------------------------------------------- +// CLbsWcdmaCellInfo::ConstructL() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +void CLbsWcdmaCellInfo::ConstructL() + { + iMCC = -1; + iMNC = -1; + iUCid = -1; + iSCode = -1; + iRssi = -1; + iDataValidationMask = EWcdmaDataNull; + } + +// --------------------------------------------------------------------------- +// CLbsWcdmaCellInfo::ConstructL() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +void CLbsWcdmaCellInfo::ConstructL( const TInt aCountryCode, + const TInt aNetworkCode, + const TInt aUniqueCellId ) + { + SetMobileCountryCode( aCountryCode ); + SetMobileNetworkCode( aNetworkCode ); + SetUniqueCellId( aUniqueCellId ); + iSCode = -1; + iRssi = -1; + } diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/ConversionDataTypes/src/lbslocationwcdmaneighbourinfo.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/ConversionDataTypes/src/lbslocationwcdmaneighbourinfo.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,131 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Data class representing a neighbouring cell +* information in a WCDMA PLMN. +* +*/ + + +#include + + +// --------------------------------------------------------------------------- +// TLbsWcdmaNeighbourCellInfo::TLbsWcdmaNeighbourCellInfo() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C TLbsWcdmaNeighbourCellInfo::TLbsWcdmaNeighbourCellInfo() + { + iUniqueCellId = -1; + iScramblingCode = -1; + iPathloss = -1; + iRssi = -1; + } + +// --------------------------------------------------------------------------- +// TLbsWcdmaNeighbourCellInfo::TLbsWcdmaNeighbourCellInfo() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C TLbsWcdmaNeighbourCellInfo::TLbsWcdmaNeighbourCellInfo( const TInt aUCid, + const TInt aSCode, + const TInt aPathloss, + const TInt aRssi ) + { + iUniqueCellId = aUCid; + iScramblingCode = aSCode; + iPathloss = aPathloss; + iRssi = aRssi; + } + +// --------------------------------------------------------------------------- +// TLbsWcdmaNeighbourCellInfo::SetUniqueCellId() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C void TLbsWcdmaNeighbourCellInfo::SetUniqueCellId( const TInt aUniqueCellId ) + { + iUniqueCellId = aUniqueCellId; + } + +// --------------------------------------------------------------------------- +// TLbsWcdmaNeighbourCellInfo::UniqueCellId() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C TInt TLbsWcdmaNeighbourCellInfo::UniqueCellId() const + { + return iUniqueCellId; + } + +// --------------------------------------------------------------------------- +// TLbsWcdmaNeighbourCellInfo::SetScramblingCode() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C void TLbsWcdmaNeighbourCellInfo::SetScramblingCode( + const TInt aScramblingCode ) + { + iScramblingCode = aScramblingCode; + } + +// --------------------------------------------------------------------------- +// TLbsWcdmaNeighbourCellInfo::ScramblingCode() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C TInt TLbsWcdmaNeighbourCellInfo::ScramblingCode() const + { + return iScramblingCode; + } + +// --------------------------------------------------------------------------- +// TLbsWcdmaNeighbourCellInfo::SetPathloss() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C void TLbsWcdmaNeighbourCellInfo::SetPathloss( const TInt aPathloss ) + { + iPathloss = aPathloss; + } + +// --------------------------------------------------------------------------- +// TLbsWcdmaNeighbourCellInfo::Pathloss() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C TInt TLbsWcdmaNeighbourCellInfo::Pathloss() const + { + return iPathloss; + } + +// --------------------------------------------------------------------------- +// TLbsWcdmaNeighbourCellInfo::SetSignalStrength() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C void TLbsWcdmaNeighbourCellInfo::SetSignalStrength( const TInt aRssi ) + { + iRssi = aRssi; + } + +// --------------------------------------------------------------------------- +// TLbsWcdmaNeighbourCellInfo::SignalStrength() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C TInt TLbsWcdmaNeighbourCellInfo::SignalStrength() const + { + return iRssi; + } diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/ConversionDataTypes/src/lbslocationwlaninfo.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/ConversionDataTypes/src/lbslocationwlaninfo.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,198 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Data class representing a geographical area in terms of +* WLAN MAC ID. +* +*/ + + +#include +#include + + +// --------------------------------------------------------------------------- +// CLbsWlanInfo::NewL() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C CLbsWlanInfo* CLbsWlanInfo::NewL() + { + CLbsWlanInfo* self = new( ELeave ) CLbsWlanInfo; + CleanupStack::PushL( self ); + self->ConstructL(); + CleanupStack::Pop(); + return self; + } + +// --------------------------------------------------------------------------- +// CLbsWlanInfo::~CLbsWlanInfo() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C CLbsWlanInfo* CLbsWlanInfo::NewL( const CLbsWlanInfo& aPositionInfo) + { + + TLbsWlanMacAddress macAddress; + aPositionInfo.GetMacAddress(macAddress); + TInt16 powRx = aPositionInfo.SignalStrength(); + + CLbsWlanInfo* self = CLbsWlanInfo::NewL( macAddress, powRx); + + return self; + } +// --------------------------------------------------------------------------- +// CLbsWlanInfo::NewL() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C CLbsWlanInfo* CLbsWlanInfo::NewL( const TLbsWlanMacAddress& MacAddress, + const TInt aPowRx ) + { + CLbsWlanInfo* self = new( ELeave ) CLbsWlanInfo; + CleanupStack::PushL( self ); + self->ConstructL( MacAddress, aPowRx ); + CleanupStack::Pop(); + return self; + } + + +// --------------------------------------------------------------------------- +// CLbsWlanInfo::~CLbsWlanInfo() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C CLbsWlanInfo::~CLbsWlanInfo() + { + } + +// --------------------------------------------------------------------------- +// CLbsWlanInfo::SetMacId() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C void CLbsWlanInfo::SetMacAddress( const TDesC8& aMacAddress ) + { + iMacAddress = aMacAddress; + } + +// --------------------------------------------------------------------------- +// CLbsWlanInfo::MacId() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C void CLbsWlanInfo::GetMacAddress(TDes8& aMacAddress ) const + { + aMacAddress = iMacAddress; + } + +// --------------------------------------------------------------------------- +// CLbsWlanInfo::SetSignalStrength() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C void CLbsWlanInfo::SetSignalStrength( const TInt aPowRx ) + { + iPowRx = aPowRx; + } + +// --------------------------------------------------------------------------- +// CLbsWlanInfo::SignalStrength() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +EXPORT_C TInt CLbsWlanInfo::SignalStrength() const + { + return iPowRx; + } + +// --------------------------------------------------------------------------- +// CLbsWlanInfo::Type() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +TLbsAreaInfoClassType CLbsWlanInfo::Type() + { + return ELbsAreaWlanInfoClass; + } + +// --------------------------------------------------------------------------- +// CLbsWlanInfo::DoInternaliseL() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +void CLbsWlanInfo::DoInternaliseL( RReadStream& aStream ) + { + TInt len = aStream.ReadInt32L(); + aStream.ReadL( iMacAddress, len ); + iPowRx = aStream.ReadInt16L(); + } + +// --------------------------------------------------------------------------- +// CLbsWlanInfo::DoExternaliseL() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +void CLbsWlanInfo::DoExternaliseL( RWriteStream& aStream )const + { + TInt len = iMacAddress.Length(); + aStream.WriteInt32L( len ); + aStream.WriteL( iMacAddress,len ); + aStream.WriteInt16L( iPowRx ); + } + +// --------------------------------------------------------------------------- +// CLbsWlanInfo::ValidateAreaInfoL() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +void CLbsWlanInfo::ValidateDataL() const + { + if( !iMacAddress.Length() ) + User::Leave( KErrArgument ); + + if( iPowRx < 0 || iPowRx > 255 ) + User::Leave( KErrArgument ); + } + +// --------------------------------------------------------------------------- +// CLbsWlanInfo::CLbsWlanInfo() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +CLbsWlanInfo::CLbsWlanInfo() + { + } + +// --------------------------------------------------------------------------- +// CLbsWlanInfo::ConstructL() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +void CLbsWlanInfo::ConstructL() + { + iMacAddress.FillZ(); + iPowRx = -1; + } + +// --------------------------------------------------------------------------- +// CLbsWlanInfo::ConstructL() +// other items were commented in the header +// --------------------------------------------------------------------------- +// +void CLbsWlanInfo::ConstructL( const TLbsWlanMacAddress& MacAddress, + const TInt aPowRx ) + { + SetMacAddress( MacAddress ); + SetSignalStrength( aPowRx ); + } diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/cenrep/20026814.txt Binary file locationmgmt/locmonitor/lbslocmonitorapis/cenrep/20026814.txt has changed diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/conf/locationinfoconverter.confml Binary file locationmgmt/locmonitor/lbslocmonitorapis/conf/locationinfoconverter.confml has changed diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/conf/locationinfoconverter_20026814.crml Binary file locationmgmt/locmonitor/lbslocmonitorapis/conf/locationinfoconverter_20026814.crml has changed diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorapis/group/bld.inf --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorapis/group/bld.inf Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,40 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: This file provides the information required for building the +* location monitor API component. +* +*/ + +#include + +PRJ_PLATFORMS +DEFAULT + +PRJ_EXPORTS + +#ifdef OS_LAYER_CONFML +../conf/locationinfoconverter.confml OS_LAYER_CONFML(locationinfoconverter.confml) +#endif + +#ifdef OS_LAYER_CRML +../conf/locationinfoconverter_20026814.crml OS_LAYER_CRML(locationinfoconverter_20026814.crml) +#endif + +#include "../ConversionApi/ConversionCommon/group/bld.inf" +#include "../ConversionDataTypes/group/bld.inf" +#include "../CommonClientServerApi/group/bld.inf" +#include "../ConversionApi/ConversionClientApi/group/bld.inf" +#include "../ConversionApi/ConversionPluginApi/group/bld.inf" + +// End of file diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorclient/bwins/lbslocmonclient.def --- a/locationmgmt/locmonitor/lbslocmonitorclient/bwins/lbslocmonclient.def Thu Jun 24 11:27:31 2010 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,23 +0,0 @@ -EXPORTS - ?OpenL@RLbsLocMonitorAreaPositioner@@QAEXAAVRLbsLocMonitorSession@@@Z @ 1 NONAME ; void RLbsLocMonitorAreaPositioner::OpenL(class RLbsLocMonitorSession &) - ?ConstructL@RLbsLocMonitorAreaPositioner@@MAEXXZ @ 2 NONAME ; void RLbsLocMonitorAreaPositioner::ConstructL(void) - ?ConstructL@CLbsLocMonitorPtrHolder@@IAEXHH@Z @ 3 NONAME ; void CLbsLocMonitorPtrHolder::ConstructL(int, int) - ?PtrC@CLbsLocMonitorPtrHolder@@QAEAAVTPtrC8@@H@Z @ 4 NONAME ; class TPtrC8 & CLbsLocMonitorPtrHolder::PtrC(int) - ?CancelDatabaseWipeOut@RLbsLocMonitorSession@@QBEHXZ @ 5 NONAME ; int RLbsLocMonitorSession::CancelDatabaseWipeOut(void) const - ?Ptr@CLbsLocMonitorPtrHolder@@QAEAAVTPtr8@@H@Z @ 6 NONAME ; class TPtr8 & CLbsLocMonitorPtrHolder::Ptr(int) - ?GetLastKnownPosition@RLbsLocMonitorAreaPositioner@@QBEXAAVTPositionInfoBase@@AAVTRequestStatus@@@Z @ 7 NONAME ; void RLbsLocMonitorAreaPositioner::GetLastKnownPosition(class TPositionInfoBase &, class TRequestStatus &) const - ?Close@RLbsLocMonitorSession@@UAEXXZ @ 8 NONAME ; void RLbsLocMonitorSession::Close(void) - ?Destruct@RLbsLocMonitorAreaPositioner@@MAEXXZ @ 9 NONAME ; void RLbsLocMonitorAreaPositioner::Destruct(void) - ?GetLastKnownPositionArea@RLbsLocMonitorAreaPositioner@@QBEXAAVTPositionInfoBase@@AAVTPositionAreaInfoBase@@AAVTPosAreaReqParams@@AAVTRequestStatus@@@Z @ 10 NONAME ; void RLbsLocMonitorAreaPositioner::GetLastKnownPositionArea(class TPositionInfoBase &, class TPositionAreaInfoBase &, class TPosAreaReqParams &, class TRequestStatus &) const - ?CancelGetLastKnownPositionArea@RLbsLocMonitorAreaPositioner@@QBEHXZ @ 11 NONAME ; int RLbsLocMonitorAreaPositioner::CancelGetLastKnownPositionArea(void) const - ?NewL@CLbsLocMonitorPtrHolder@@SAPAV1@HH@Z @ 12 NONAME ; class CLbsLocMonitorPtrHolder * CLbsLocMonitorPtrHolder::NewL(int, int) - ??0RLbsLocMonitorAreaPositioner@@QAE@XZ @ 13 NONAME ; RLbsLocMonitorAreaPositioner::RLbsLocMonitorAreaPositioner(void) - ?CancelGetLastKnownPosition@RLbsLocMonitorAreaPositioner@@QBEHXZ @ 14 NONAME ; int RLbsLocMonitorAreaPositioner::CancelGetLastKnownPosition(void) const - ??0RLbsLocMonitorSession@@QAE@XZ @ 15 NONAME ; RLbsLocMonitorSession::RLbsLocMonitorSession(void) - ?WipeOutDatabase@RLbsLocMonitorSession@@QBEXAAVTRequestStatus@@@Z @ 16 NONAME ; void RLbsLocMonitorSession::WipeOutDatabase(class TRequestStatus &) const - ?Close@RLbsLocMonitorAreaPositioner@@UAEXXZ @ 17 NONAME ; void RLbsLocMonitorAreaPositioner::Close(void) - ??1CLbsLocMonitorPtrHolder@@UAE@XZ @ 18 NONAME ; CLbsLocMonitorPtrHolder::~CLbsLocMonitorPtrHolder(void) - ?Connect@RLbsLocMonitorSession@@QAEHXZ @ 19 NONAME ; int RLbsLocMonitorSession::Connect(void) - ?Version@RLbsLocMonitorSession@@UAE?AVTVersion@@XZ @ 20 NONAME ; class TVersion RLbsLocMonitorSession::Version(void) - ?SetLastKnownPosition@RLbsLocMonitorAreaPositioner@@QBEHABVTPositionInfoBase@@@Z @ 21 NONAME ; int RLbsLocMonitorAreaPositioner::SetLastKnownPosition(class TPositionInfoBase const &) const - diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorclient/eabi/lbslocmonclient.def --- a/locationmgmt/locmonitor/lbslocmonitorclient/eabi/lbslocmonclient.def Thu Jun 24 11:27:31 2010 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,33 +0,0 @@ -EXPORTS - _ZN21RLbsLocMonitorSession5CloseEv @ 1 NONAME - _ZN21RLbsLocMonitorSession7ConnectEv @ 2 NONAME - _ZN21RLbsLocMonitorSession7VersionEv @ 3 NONAME - _ZN21RLbsLocMonitorSessionC1Ev @ 4 NONAME - _ZN21RLbsLocMonitorSessionC2Ev @ 5 NONAME - _ZN23CLbsLocMonitorPtrHolder10ConstructLEii @ 6 NONAME - _ZN23CLbsLocMonitorPtrHolder3PtrEi @ 7 NONAME - _ZN23CLbsLocMonitorPtrHolder4NewLEii @ 8 NONAME - _ZN23CLbsLocMonitorPtrHolder4PtrCEi @ 9 NONAME - _ZN23CLbsLocMonitorPtrHolderD0Ev @ 10 NONAME - _ZN23CLbsLocMonitorPtrHolderD1Ev @ 11 NONAME - _ZN23CLbsLocMonitorPtrHolderD2Ev @ 12 NONAME - _ZN28RLbsLocMonitorAreaPositioner5CloseEv @ 13 NONAME - _ZN28RLbsLocMonitorAreaPositioner5OpenLER21RLbsLocMonitorSession @ 14 NONAME - _ZN28RLbsLocMonitorAreaPositionerC1Ev @ 15 NONAME - _ZN28RLbsLocMonitorAreaPositionerC2Ev @ 16 NONAME - _ZNK21RLbsLocMonitorSession15WipeOutDatabaseER14TRequestStatus @ 17 NONAME - _ZNK21RLbsLocMonitorSession21CancelDatabaseWipeOutEv @ 18 NONAME - _ZNK28RLbsLocMonitorAreaPositioner20GetLastKnownPositionER17TPositionInfoBaseR14TRequestStatus @ 19 NONAME - _ZNK28RLbsLocMonitorAreaPositioner20SetLastKnownPositionERK17TPositionInfoBase @ 20 NONAME - _ZNK28RLbsLocMonitorAreaPositioner24GetLastKnownPositionAreaER17TPositionInfoBaseR21TPositionAreaInfoBaseR17TPosAreaReqParamsR14TRequestStatus @ 21 NONAME - _ZNK28RLbsLocMonitorAreaPositioner26CancelGetLastKnownPositionEv @ 22 NONAME - _ZNK28RLbsLocMonitorAreaPositioner30CancelGetLastKnownPositionAreaEv @ 23 NONAME - _ZTI21RLbsLocMonitorSession @ 24 NONAME - _ZTI23CLbsLocMonitorPtrHolder @ 25 NONAME - _ZTI28RLbsLocMonitorAreaPositioner @ 26 NONAME - _ZTV21RLbsLocMonitorSession @ 27 NONAME - _ZTV23CLbsLocMonitorPtrHolder @ 28 NONAME - _ZTV28RLbsLocMonitorAreaPositioner @ 29 NONAME - _ZN28RLbsLocMonitorAreaPositioner10ConstructLEv @ 30 NONAME - _ZN28RLbsLocMonitorAreaPositioner8DestructEv @ 31 NONAME - diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorclient/group/bld.inf --- a/locationmgmt/locmonitor/lbslocmonitorclient/group/bld.inf Thu Jun 24 11:27:31 2010 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,21 +0,0 @@ -// Copyright (c) 2002-2009 Nokia Corporation and/or its subsidiary(-ies). -// All rights reserved. -// This component and the accompanying materials are made available -// under the terms of "Eclipse Public License v1.0" -// which accompanies this distribution, and is available -// at the URL "http://www.eclipse.org/legal/epl-v10.html". -// -// Initial Contributors: -// Nokia Corporation - initial contribution. -// -// Contributors: -// -// Description: -// - -PRJ_EXPORTS -lbslocmonclient.iby /epoc32/rom/include/lbslocmonclient.iby - - -PRJ_MMPFILES -lbslocmonclient.mmp diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorclient/group/lbslocmonclient.iby --- a/locationmgmt/locmonitor/lbslocmonitorclient/group/lbslocmonclient.iby Thu Jun 24 11:27:31 2010 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,26 +0,0 @@ -/* -* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). -* All rights reserved. -* This component and the accompanying materials are made available -* under the terms of "Eclipse Public License v1.0" -* which accompanies this distribution, and is available -* at the URL "http://www.eclipse.org/legal/epl-v10.html". -* -* Initial Contributors: -* Nokia Corporation - initial contribution. -* -* Contributors: -* -* Description: -* -*/ -#ifndef __LBS_LOCMONCLIENT_IBY__ -#define __LBS_LOCMONCLIENT_IBY__ - -//#if !defined(SYMBIAN_EXCLUDE_LOCATION) - -file=ABI_DIR\DEBUG_DIR\lbslocmonclient.dll System\libs\lbslocmonclient.dll - -//#endif // SYMBIAN_EXCLUDE_LOCATION - -#endif \ No newline at end of file diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorclient/group/lbslocmonclient.mmp --- a/locationmgmt/locmonitor/lbslocmonitorclient/group/lbslocmonclient.mmp Thu Jun 24 11:27:31 2010 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,59 +0,0 @@ -/* -* Copyright (c) 2005 Nokia Corporation and/or its subsidiary(-ies). -* All rights reserved. -* This component and the accompanying materials are made available -* under the terms of "Eclipse Public License v1.0" -* which accompanies this distribution, and is available -* at the URL "http://www.eclipse.org/legal/epl-v10.html". -* -* Initial Contributors: -* Nokia Corporation - initial contribution. -* -* Contributors: -* -* Description: -* -*/ - - -TARGET lbslocmonclient.dll -TARGETTYPE dll -UID 0x1000008d 0x102869DE - -CAPABILITY ALL -TCB - -MACRO ENABLE_LBS_DEV_LOGGER - -NOSTRICTDEF - -SOURCEPATH ../src -SOURCE rlbslocmonitorareapositioner.cpp -SOURCE rlbslocmonitorsession.cpp -SOURCE clbslocmonitorptrholder.cpp - -// -// Server framework stuff -// -SOURCEPATH ../../../locationcore/LbsLocCommon/ServerFramework/src -SOURCE tserverstartparams.cpp -SOURCE rsecuresessionbase.cpp -SOURCE cserverlaunch.cpp -SOURCE tstartparamsbase.cpp - -USERINCLUDE ../inc -USERINCLUDE ../../../locationcore/LbsLocCommon/ServerFramework/inc -USERINCLUDE ../../lbslocmonitorserver/inc -USERINCLUDE ../../../locationcore/LbsInternalApi/inc -USERINCLUDE ../../../locationcore/lbsrootapi/inc -USERINCLUDE ../../../locationcore/LbsPartnerCommon/inc - -OS_LAYER_SYSTEMINCLUDE_SYMBIAN - -LIBRARY euser.lib -LIBRARY estor.lib -LIBRARY lbs.lib -LIBRARY lbsloccommon.lib -LIBRARY lbspartnercommon.lib -LIBRARY lbsrootapi.lib - -SMPSAFE diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorclient/inc/clbslocmonitorptrholder.h --- a/locationmgmt/locmonitor/lbslocmonitorclient/inc/clbslocmonitorptrholder.h Thu Jun 24 11:27:31 2010 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,56 +0,0 @@ -/* -* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). -* All rights reserved. -* This component and the accompanying materials are made available -* under the terms of "Eclipse Public License v1.0" -* which accompanies this distribution, and is available -* at the URL "http://www.eclipse.org/legal/epl-v10.html". -* -* Initial Contributors: -* Nokia Corporation - initial contribution. -* -* Contributors: -* -* Description: -* -*/ - - -#ifndef CLBSLOCMONITORPTRHOLDER_H -#define CLBSLOCMONITORPTRHOLDER_H - -#include - -class CLbsLocMonitorPtrHolder : public CBase -/** -Holds the TPtr8 and TPtrC8 arrays for all RPositionServer requests. -@internalComponent - */ - { -public: - - enum TParameter - { - EPosForGetLastKnownPosition = 0, - EPosForGetLastKnownPositionArea, - EAreaForGetLastKnownPositionArea, - EParamsForGetLastKnownPositionArea, - ELastParam, // Keep this the last - }; - -public: - IMPORT_C static CLbsLocMonitorPtrHolder* NewL(TInt aNumberOfPtrs, - TInt aNumberOfPtrCs); - IMPORT_C ~CLbsLocMonitorPtrHolder(); - IMPORT_C TPtr8& Ptr(TInt aIndex); - IMPORT_C TPtrC8& PtrC(TInt aIndex); -protected: - IMPORT_C void ConstructL(TInt aNumberOfPtrs, TInt aNumberOfPtrCs); -private: - /** modifiable pointer array */ - RArray iPtrArray; - /** non-modifiable pointer array */ - RArray iPtrCArray; - }; - -#endif // CLBSLOCMONITORPTRHOLDER_H diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorclient/inc/rlbslocmonitorareapositioner.h --- a/locationmgmt/locmonitor/lbslocmonitorclient/inc/rlbslocmonitorareapositioner.h Thu Jun 24 11:27:31 2010 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,99 +0,0 @@ -/* -* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). -* All rights reserved. -* This component and the accompanying materials are made available -* under the terms of "Eclipse Public License v1.0" -* which accompanies this distribution, and is available -* at the URL "http://www.eclipse.org/legal/epl-v10.html". -* -* Initial Contributors: -* Nokia Corporation - initial contribution. -* -* Contributors: -* -* Description: -* -*/ - -/** -@file -@internalTechnology -*/ - -#ifndef RLBSLOCMONITORAREAPOSITIONER_H -#define RLBSLOCMONITORAREAPOSITIONER_H - -#include -#include -#include "rlbslocmonitorsession.h" -#include "lbslocmonitorserverdata.h" -#include "clbslocmonitorptrholder.h" - -/** -This class is used by clients of the Location Monitor server to -create a sub-session with the server. - -Before using the class, a primary connection must have already been -established with the server with RLbsLocMonitorSession::Connect(). - -@see RLbsLocMonitorSession -*/ -class RLbsLocMonitorAreaPositioner : public RSecureSubSessionBase - { - -public: - - IMPORT_C RLbsLocMonitorAreaPositioner(); - IMPORT_C void OpenL(RLbsLocMonitorSession& aLocMonSession); - IMPORT_C void Close(); - - /* Called by the Location Server to report the last - Position obtained from any of its PSYs that are not otherwise - available to the Location Monitor. The position - will be stored in a database. - */ - IMPORT_C TInt SetLastKnownPosition(const TPositionInfoBase& aPosInfo) const; - - /* Retrieve the position last stored in the database */ - IMPORT_C void GetLastKnownPosition(TPositionInfoBase& aPosInfo, - TRequestStatus& aStatus) const; - - /* Cancel a previous call to GetLastKnownPosition*/ - IMPORT_C TInt CancelGetLastKnownPosition() const; - - /* Returns in aPosInfo a position which had been previously stored - in association with "context information" that is bound to a - geographical area (e.g. Global Cell Id). - - Current context information will be sensed by the server and used - to search for a position in the database. If found, the position - will be an approximation of the current position of the handset. - If no position is found in the database for the current context - information, the position last stored in the database is returned. - - The method returns in aAreaInfo a rough indication of how accurate the - returned position is based on an estimation of the size of the - geographical area covered by the sensed context information. - */ - IMPORT_C void GetLastKnownPositionArea(TPositionInfoBase& aPosInfo, - TPositionAreaInfoBase& aAreaInfo, - TPosAreaReqParams& aParameters, - TRequestStatus& aStatus) const; - - /* Cancel a call to GetLastKnownPositionArea */ - IMPORT_C TInt CancelGetLastKnownPositionArea() const; - - -protected: - - IMPORT_C virtual void ConstructL(); - IMPORT_C virtual void Destruct(); - -private: - - /** A pointer to a container that holds pointer descriptors, needed to point - to the clients request data during asynchronous requests */ - CLbsLocMonitorPtrHolder* iPtrHolder; - }; - -#endif // RLBSLOCMONITORAREAPOSITIONER_H diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorclient/inc/rlbslocmonitorsession.h --- a/locationmgmt/locmonitor/lbslocmonitorclient/inc/rlbslocmonitorsession.h Thu Jun 24 11:27:31 2010 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,61 +0,0 @@ -/* -* Copyright (c) 2008 Nokia Corporation and/or its subsidiary(-ies). -* All rights reserved. -* This component and the accompanying materials are made available -* under the terms of "Eclipse Public License v1.0" -* which accompanies this distribution, and is available -* at the URL "http://www.eclipse.org/legal/epl-v10.html". -* -* Initial Contributors: -* Nokia Corporation - initial contribution. -* -* Contributors: -* -* Description: -* -*/ - - -/** -@internalTechnology -@prototype -*/ - -#ifndef RLBSLOCMONITORSESSION_H -#define RLBSLOCMONITORSESSION_H - -#include "rlbslocmonitorsession.h" -#include "rsecuresessionbase.h" - -/** -Client-side session with the Location Monitor server. - */ -class RLbsLocMonitorSession : public RSecureSessionBase - { - -public: - - IMPORT_C RLbsLocMonitorSession(); - - IMPORT_C TInt Connect(); - - IMPORT_C void Close(); - - /* Close the database and wipe out the DB file. - */ - IMPORT_C void WipeOutDatabase(TRequestStatus& aStatus) const; - - /* Cancel previous request to delete the Database - of positions. - */ - IMPORT_C TInt CancelDatabaseWipeOut() const; - - IMPORT_C TVersion Version(); - -protected: - - // From RSecureSessionBase - TInt StartServer(TServerStartParams& aParams); - }; - -#endif // RLBSLOCMONITORSESSION_H diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorclient/src/clbslocmonitorptrholder.cpp --- a/locationmgmt/locmonitor/lbslocmonitorclient/src/clbslocmonitorptrholder.cpp Thu Jun 24 11:27:31 2010 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,101 +0,0 @@ -/* -* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). -* All rights reserved. -* This component and the accompanying materials are made available -* under the terms of "Eclipse Public License v1.0" -* which accompanies this distribution, and is available -* at the URL "http://www.eclipse.org/legal/epl-v10.html". -* -* Initial Contributors: -* Nokia Corporation - initial contribution. -* -* Contributors: -* -* Description: -* -*/ - - -#include "clbslocmonitorptrholder.h" - - -//----------------------------------------------------------------------------- -// CLbsLocMonitorPtrHolder -//----------------------------------------------------------------------------- - -/** - Allocates and constructs a CLbsLocMonitorPtrHolder object. - - The function leaves if there is insufficient memory. - -@internalComponent -@param aNumberOfPtrs is the number of modifiable pointer descriptors to - create. These are used for asynchronous 'get' requests. -@param aNumberOfPtrCs is the number of read-only pointer descriptors to - create. These are used for asynchronous 'set' requests. -@return a newly created CLbsLocMonitorPtrHolder object. - */ -EXPORT_C CLbsLocMonitorPtrHolder* CLbsLocMonitorPtrHolder::NewL(TInt aNumberOfPtrs, - TInt aNumberOfPtrCs) - { - CLbsLocMonitorPtrHolder* self = new (ELeave) CLbsLocMonitorPtrHolder; - CleanupStack::PushL(self); - self->ConstructL(aNumberOfPtrs, aNumberOfPtrCs); - CleanupStack::Pop(self); - return self; - } - -EXPORT_C void CLbsLocMonitorPtrHolder::ConstructL(TInt aNumberOfPtrs, - TInt aNumberOfPtrCs) - - { - TPtr8 ptr(NULL, 0); - TInt i; - for (i = 0; i < aNumberOfPtrs; i++) - { - User::LeaveIfError(iPtrArray.Append(ptr)); - } - - TPtrC8 ptrC(NULL, 0); - for (i = 0; i < aNumberOfPtrCs; i++) - { - User::LeaveIfError(iPtrCArray.Append(ptrC)); - } - } - -/** -Destructor for CLbsLocMonitorPtrHolder. - -@internalComponent -*/ -EXPORT_C CLbsLocMonitorPtrHolder::~CLbsLocMonitorPtrHolder() - { - iPtrCArray.Close(); - iPtrArray.Close(); - } - -/** -An accessor for the modifiable pointer descriptors. - -@internalComponent -@param aIndex specifies the descriptor to return. -@return a reference to one of our contained pointer descriptors. - */ -EXPORT_C TPtr8& CLbsLocMonitorPtrHolder::Ptr(TInt aIndex) - { - return iPtrArray[aIndex]; - } - -/** -An accessor for the read-only pointer descriptors. - -@internalComponent -@param aIndex specifies the descriptor to return. -@return a reference to one of our contained pointer descriptors. -*/ -EXPORT_C TPtrC8& CLbsLocMonitorPtrHolder::PtrC(TInt aIndex) - { - return iPtrCArray[aIndex]; - } - - diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorclient/src/rlbslocmonitorareapositioner.cpp --- a/locationmgmt/locmonitor/lbslocmonitorclient/src/rlbslocmonitorareapositioner.cpp Thu Jun 24 11:27:31 2010 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,194 +0,0 @@ -/* -* Copyright (c) 2008 Nokia Corporation and/or its subsidiary(-ies). -* All rights reserved. -* This component and the accompanying materials are made available -* under the terms of "Eclipse Public License v1.0" -* which accompanies this distribution, and is available -* at the URL "http://www.eclipse.org/legal/epl-v10.html". -* -* Initial Contributors: -* Nokia Corporation - initial contribution. -* -* Contributors: -* -* Description: -* -*/ - - -#include -#include -#include -#include -#include "rlbslocmonitorareapositioner.h" - - -EXPORT_C RLbsLocMonitorAreaPositioner::RLbsLocMonitorAreaPositioner() - : RSecureSubSessionBase(), - iPtrHolder(NULL) - { - } - -EXPORT_C void RLbsLocMonitorAreaPositioner::ConstructL() - { - iPtrHolder = CLbsLocMonitorPtrHolder::NewL(CLbsLocMonitorPtrHolder::ELastParam, 0); - } - -EXPORT_C void RLbsLocMonitorAreaPositioner::Destruct() - { - delete iPtrHolder; - iPtrHolder = NULL; - } - -EXPORT_C void RLbsLocMonitorAreaPositioner::OpenL(RLbsLocMonitorSession& aLocMonSession) - { - __ASSERT_ALWAYS(aLocMonSession.Handle() != 0, User::Invariant()); // trying to open twice - TInt err(KErrNone); - ConstructL(); - - // Call Server Framework 'Open' - TLbsLocMonitorAreaPositionerData emptyData; - TLbsLocMonitorSubSessionType type(ELocMonitorSubSessionTypeAreaPositioner); - err = RSecureSubSessionBase::Open(aLocMonSession, type, emptyData); - if (err != KErrNone) - { - Destruct(); - } - User::LeaveIfError(err); - } - -EXPORT_C void RLbsLocMonitorAreaPositioner::Close() - { - // Call Server Framework 'Close' - RSecureSubSessionBase::Close(); - Destruct(); - } - -/** -Method called by the Location Server to send the Last Known Position to the Location Monitor -for storing together with Local Area information if possible. - -@param aPosInfo the position object to be sent to the server (only the TPositionInfo portion - will be sent) -@return KErrNone if position is succesfully sent to server - KErrArgument if aPosInfo is not a TPositionInfo class or derived class. - Any of the error codes returned by RSessionBase::SendReceive -*/ -EXPORT_C TInt RLbsLocMonitorAreaPositioner::SetLastKnownPosition(const TPositionInfoBase& aPosInfo) const - { - __ASSERT_ALWAYS(SubSessionHandle(), User::Invariant()); - __ASSERT_ALWAYS(iPtrHolder != NULL, User::Invariant()); - // Verify aPosInfo is of a type that contains a position - const TPositionInfoBase& infoBase = static_cast(aPosInfo); - TUint32 classType = infoBase.PositionClassType(); - if (!(classType & EPositionInfoClass)) - { - return KErrArgument; - } - - // Get the TPosition in aPosInfo and send to the Location Monitor - const TPositionInfo& posInfo = static_cast(aPosInfo); - TPosition position; - posInfo.GetPosition(position); - - TPckgC posPckg(position); - return SendReceive(ESetLastKnownPosition, TIpcArgs(&posPckg)); - } - - -/* Retrieve the position last stored in the database */ -EXPORT_C void RLbsLocMonitorAreaPositioner::GetLastKnownPosition(TPositionInfoBase& aPosInfo, - TRequestStatus& aStatus) const - { - __ASSERT_ALWAYS(SubSessionHandle(), User::Invariant()); - __ASSERT_ALWAYS(iPtrHolder != NULL, User::Invariant()); - - // Ensure aPosInfo output parameter is at TPositionInfo or derived class - const TPositionInfoBase& infoBase = static_cast(aPosInfo); - TUint32 classType = infoBase.PositionClassType(); - if (!(classType & EPositionInfoClass)) - { - TRequestStatus* status = &aStatus; - User::RequestComplete(status, KErrArgument); - return; - } - - iPtrHolder->Ptr(CLbsLocMonitorPtrHolder::EPosForGetLastKnownPosition).Set( - reinterpret_cast(&aPosInfo), - aPosInfo.PositionClassSize(), - aPosInfo.PositionClassSize()); - - SendReceive(EGetLastKnownPosition, - TIpcArgs(&iPtrHolder->Ptr(CLbsLocMonitorPtrHolder::EPosForGetLastKnownPosition)), - aStatus); - } - -EXPORT_C TInt RLbsLocMonitorAreaPositioner::CancelGetLastKnownPosition() const - { - __ASSERT_ALWAYS(SubSessionHandle(), User::Invariant()); - - return SendReceive(ECancelGetLastKnownPosition); - } - - -/** -Returns in aPosInfo a position which had been previously stored -in association with "context information" that is bound to a -geographical area (e.g. Global Cell Id). - -Current context information will be sensed by the server and used -to search for a position in the database. If found, the position -will be an approximation of the current position of the handset. -If no position is found in the database for the current context -information, the position last stored in the database is returned. - -The method returns in aAreaInfo a rough indication of how accurate the -returned position is based on an estimation of the size of the -geographical area covered by the sensed context information. -*/ -EXPORT_C void RLbsLocMonitorAreaPositioner::GetLastKnownPositionArea(TPositionInfoBase& aPosInfo, - TPositionAreaInfoBase& aAreaInfo, - TPosAreaReqParams& aParameters, - TRequestStatus& aStatus) const - { - __ASSERT_ALWAYS(SubSessionHandle(), User::Invariant()); - __ASSERT_ALWAYS(iPtrHolder != NULL, User::Invariant()); - - // Ensure aPosInfo output parameter is at TPositionInfo or derived class - const TPositionInfoBase& infoBase = static_cast(aPosInfo); - TUint32 classType = infoBase.PositionClassType(); - if (!(classType & EPositionInfoClass)) - { - TRequestStatus* status = &aStatus; - User::RequestComplete(status, KErrArgument); - return; - } - - iPtrHolder->Ptr(CLbsLocMonitorPtrHolder::EPosForGetLastKnownPositionArea).Set( - reinterpret_cast(&aPosInfo), - aPosInfo.PositionClassSize(), - aPosInfo.PositionClassSize()); - - iPtrHolder->Ptr(CLbsLocMonitorPtrHolder::EAreaForGetLastKnownPositionArea).Set( - reinterpret_cast(&aAreaInfo), - aAreaInfo.PositionClassSize(), - aAreaInfo.PositionClassSize()); - - iPtrHolder->Ptr(CLbsLocMonitorPtrHolder::EParamsForGetLastKnownPositionArea).Set( - reinterpret_cast(&aParameters), - sizeof(TPosAreaReqParams), - sizeof(TPosAreaReqParams)); - - SendReceive(EGetLastKnownPositionArea, - TIpcArgs(&iPtrHolder->Ptr(CLbsLocMonitorPtrHolder::EPosForGetLastKnownPositionArea), - &iPtrHolder->Ptr(CLbsLocMonitorPtrHolder::EAreaForGetLastKnownPositionArea), - &iPtrHolder->Ptr(CLbsLocMonitorPtrHolder::EParamsForGetLastKnownPositionArea)), - aStatus); - } - -EXPORT_C TInt RLbsLocMonitorAreaPositioner::CancelGetLastKnownPositionArea() const - { - __ASSERT_ALWAYS(SubSessionHandle(), User::Invariant()); - return SendReceive(ECancelGetLastKnownPositionArea); - } - diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorclient/src/rlbslocmonitorsession.cpp --- a/locationmgmt/locmonitor/lbslocmonitorclient/src/rlbslocmonitorsession.cpp Thu Jun 24 11:27:31 2010 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,109 +0,0 @@ -/* -* Copyright (c) 2008 Nokia Corporation and/or its subsidiary(-ies). -* All rights reserved. -* This component and the accompanying materials are made available -* under the terms of "Eclipse Public License v1.0" -* which accompanies this distribution, and is available -* at the URL "http://www.eclipse.org/legal/epl-v10.html". -* -* Initial Contributors: -* Nokia Corporation - initial contribution. -* -* Contributors: -* -* Description: -* -*/ - - -#include "rlbslocmonitorsession.h" -#include "lbsdevloggermacros.h" -#include "tserverstartparams.h" -#include "cserverlaunch.h" -#include "lbslocmonitorserverdata.h" -#include "lbsprocessuiddefs.h" -#include "lbsipc.h" - - -//----------------------------------------------------------------------------- -// RLbsLocMonitorSession -//----------------------------------------------------------------------------- -EXPORT_C RLbsLocMonitorSession::RLbsLocMonitorSession() - { - LBSLOG(ELogP9, "->S RLbsLocMonitorSession::RLbsLocMonitorSession() lbslocmonitor.exe\n"); - } - -/** -Creates a session with the location monitor server. -This method starts the server if not yet started. - -@return Standard Symbian OS error code. -*/ -EXPORT_C TInt RLbsLocMonitorSession::Connect() - { - LBSLOG(ELogP9, "->S RLbsLocMonitorSession::Connect()\n"); - TInt ret(KErrNone); - TServerStartParams params; - params.SetServerFileName(KLocMonitorExeName); - params.SetServerName(KLocMonitorServerName); - params.SetNumberOfServerSlots(KLbsDefaultMessageSlots); - params.SetServerUids(KNullUid, KNullUid, KLbsLocMonitorUid); - - // Base class creates the session (and the server if required) - ret = RSecureSessionBase::Connect(params); - - LBSLOG2(ELogP9, " Return = %d\n", ret); - return ret; - } - -EXPORT_C void RLbsLocMonitorSession::Close() - { - LBSLOG(ELogP9, "->S RLbsLocMonitorSession::Close() lbslocationmonitor.exe\n"); - RSecureSessionBase::Close(); - } - -/** -Attempts to Cancel a previously issued asynchronous request to delete the -database of area-locations. - -The TRequestStatus of the original request will be set to KErrCancel if -the cancellation request was successful, or any other Symbian OS error code -if CancelRequest was called too late. - -@return Standard Symbian OS error code. - */ -EXPORT_C TInt RLbsLocMonitorSession::CancelDatabaseWipeOut() const - { - LBSLOG(ELogP9, "->S RLbsLocMonitorSession::CancelDatabaseWipeOut() lbslocationmonitor.exe\n"); - __ASSERT_ALWAYS(Handle(), User::Invariant()); - return SendReceive(ECancelDbWipeOut); - } - -EXPORT_C void RLbsLocMonitorSession::WipeOutDatabase(TRequestStatus& aStatus) const - { - LBSLOG(ELogP9, "->S RLbsLocMonitorSession::WipeOutDatabase() lbslocationmonitor.exe\n"); - __ASSERT_ALWAYS(Handle(), User::Invariant()); - return SendReceive(EWipeOutDb, aStatus); - } - -EXPORT_C TVersion RLbsLocMonitorSession::Version() -/** -Obtains the current version number of the location monitor. - -@return the version of the client API. - */ - { - LBSLOG(ELogP9, "->S RLbsLocMonitorSession::Version() lbslocationmonitor.exe\n"); - LBSLOG4(ELogP9, " Return TVersion = (%d, %d, %d)\n", KLbsLocMonitorMajorVersionNumber, - KLbsLocMonitorMinorVersionNumber, - KLbsLocMonitorBuildVersionNumber); - return TVersion( - KLbsLocMonitorMajorVersionNumber, - KLbsLocMonitorMinorVersionNumber, - KLbsLocMonitorBuildVersionNumber); - } - -TInt RLbsLocMonitorSession::StartServer(TServerStartParams& aParams) - { - return RSecureSessionBase::StartServer(aParams); - } diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorserver/group/lbslocationmonitor.mmp --- a/locationmgmt/locmonitor/lbslocmonitorserver/group/lbslocationmonitor.mmp Thu Jun 24 11:27:31 2010 +0100 +++ b/locationmgmt/locmonitor/lbslocmonitorserver/group/lbslocationmonitor.mmp Thu Jun 24 11:28:34 2010 +0100 @@ -22,7 +22,8 @@ UID 0x1000007A 0x102869DF VENDORID 0x70000001 -CAPABILITY ReadDeviceData ProtServ Location +CAPABILITY ReadDeviceData ProtServ Location NetworkServices WriteDeviceData ReadUserData + MACRO ENABLE_LBS_DEV_LOGGER @@ -39,11 +40,13 @@ SOURCE clbslocmonitorutils.cpp SOURCE lbslocmonitorareainfodefs.cpp SOURCE clbslocmonitorrequesthandler.cpp -SOURCE rlbslocmonitordb.cpp -SOURCE clbslocmonitordbengine.cpp +SOURCE rlbslocmonitordb.cpp +SOURCE clbslocmonitordbengine.cpp +SOURCE clbsconversionpositionersubsession.cpp +SOURCE clbslocmonitorconversionhandler.cpp +SOURCE clbslocmonitorpluginresolver.cpp SOURCE clbslocmonitordbtimer.cpp - - + SOURCEPATH ../../../locationcore/LbsLocCommon/ServerFramework/src // @@ -61,6 +64,7 @@ USERINCLUDE ../inc +USERINCLUDE ../../lbslocmonitorapis/CommonClientServerApi/inc USERINCLUDE ../../../locationcore/inc USERINCLUDE ../../../locationcore/lbsroot/inc USERINCLUDE ../../../locationcore/LbsCommonInternalDataTypes/inc @@ -73,7 +77,6 @@ USERINCLUDE ../../../locationcore/LbsDebug/inc USERINCLUDE ../../../locationcore/LbsLogging/inc - OS_LAYER_SYSTEMINCLUDE_SYMBIAN LIBRARY euser.lib @@ -87,11 +90,14 @@ LIBRARY etelmm.lib LIBRARY sqldb.lib LIBRARY commsdat.lib +LIBRARY ecom.lib +LIBRARY centralrepository.lib + LIBRARY lbsinternalapi.lib -LIBRARY lbsnetinternalapi.lib - +LIBRARY lbslocationinfoconverterplugin.lib +LIBRARY lbslocationinfodatatypes.lib // // For interface with LBS Root process // diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorserver/inc/clbsconversionpositionersubsession.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorserver/inc/clbsconversionpositionersubsession.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,76 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ + + +#ifndef CLBSCONVERSIONPOSITIONERSUBSESSION_H_ +#define CLBSCONVERSIONPOSITIONERSUBSESSION_H_ + + +#include +#include "tserverstartparams.h" +#include "csecureasbase.h" +#include "csecureserverbase.h" +#include "csecuresessionbase.h" +#include "csecuresessionsubsessionbase.h" +#include "csubsessionbase.h" +#include "messageutils.h" +#include "clbslocmonitorutils.h" + +class CLbsLocMonitorServer; + +/* + Server side subsession of the Location Monitor server. + This subsession handles client's requests for the + location info conversion. +*/ +class CLbsConversionPositionerSubsession : public CBase, + public MSubSessionImpl + { +public: + static CLbsConversionPositionerSubsession* NewL(); + + ~CLbsConversionPositionerSubsession(); + + // From MSubSessionImpl + virtual void DispatchL(const RMessage2& aMessage); + virtual void DispatchError(const RMessage2& aMessage, TInt aError); + virtual void CreateSubSessionL(const RMessage2& aMessage, const CSecureServerBase* aServer); + virtual void CloseSubSession(); + + // via MSubSessionImpl::MRelease + void VirtualRelease(); + +protected: + CLbsConversionPositionerSubsession(); + void ConstructL(); + + // + // action methods. + // + void GetPositionL(const RMessage2& aMessage); + void CancelGetPositionL(const RMessage2& aMessage); + void SetLastKnownPositionL(const RMessage2& aMessage); + +private: + + CLbsLocMonitorServer* iLocMonitorServer; + + // Unique ID of this subsession + CLbsLocMonitorUtils::sessionAndSubSessionId iSubsessionId; + }; + +#endif /*CLBSCONVERSIONPOSITIONERSUBSESSION_H_*/ diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorserver/inc/clbslocmonitorconversionhandler.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorserver/inc/clbslocmonitorconversionhandler.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,256 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Declaration of CLbsLocMonitorConversionHandler class. +* +*/ + +#ifndef CLBSLOCMONITORCONVERSIONHANDLER_H_ +#define CLBSLOCMONITORCONVERSIONHANDLER_H_ + +#include +#include +#include +#include "mlbsconversioncompleteobserver.h" +#include "rlbslocmonitordb.h" + +/** + * This class is responsible for requesting location conversion from + * the plug in and later to handle the converted information. + */ +class CLbsLocMonitorConversionHandler : public CActive, + public MLbsLocInfoConverterPluginObserver + { +public: + /** + * Validation info assosciated with each client + */ + struct TValidationInfo + { + TSecureId iClientSecureId; + }; /** + * This represent different state of conversion handler. + */ + enum TState + { + EStateIdle, + EStateValidation, + EStateConversion, + EStateCacheSave, + EStateCacheSaveComplete + }; + +public: + /** + * Creates new instance of CLbsLocMonitorConversionHandler object. + */ + static CLbsLocMonitorConversionHandler* NewL( + MLbsConversionCompleteObserver& + aConversionCompleteObserver, + TUid aConversionPluginUid ); + + /** + * Destructor + */ + ~CLbsLocMonitorConversionHandler(); + + /** + * Returns the size of converted location information to the client. + */ + void GetConvertLocationInfoSizeL(const RMessage2& aMessage); + + /** + * Returns the converted location information to the client. + */ + void GetConvertedLocationInfoL(const RMessage2& aMessage); + + /** + * Cancel location info conversion. + */ + void CancelLocationInfoConversionL(const RMessage2& aMessage); + + /** + * Returns Uid of conversion plugin that is loaded. + */ + TUid ConversionPluginUid(); + + /** + * Returns ETrue is any message corresponding to subsession id + * is present in the handler. + */ + TBool IsMessagePresent(const RMessage2& aMessage); + + /** + * Returns ETrue if secure id and subsession id matches else EFalse. + */ + TBool CompareMessage(const RMessage2& aSrc,const RMessage2& aDes); + + /** + * Returns accuracy level from a cache match, or nan if undefined. + */ + TReal32 AccuracyFromMatchLevel(TPositionAreaExtendedInfo::TArea aMatchlevel); + + + +public: // from MLbsLocInfoConverterPluginObserver + virtual void OnConversionComplete(TInt aStatusCode); + + virtual void OnValidationComplete(TInt aStatusCode); + +protected: // from CActive + void RunL(); + void DoCancel(); + +private: + /** + * Constructor. + */ + CLbsLocMonitorConversionHandler(MLbsConversionCompleteObserver& + aConversionCompleteObserver); + + /** + * Symbian 2 phase constructor. + */ + void ConstructL(TUid aConversionPluginUid); + + /** + * Processes the request which is recently validated. + */ + TInt ProcessRequestL(); + + /** + * Loads the conversion module specified by client. + */ + void LoadConversionPluginL(TUid aConversionModuleId); + + /** + * Writes converted position information to the stream. + */ + void WriteAreaInfoL(RBufWriteStream& aWriteStream, + CLbsLocationInfo::TAreaInfoMask aAreaInfoMask); + + /** + * Completes client's message. + */ + void CompleteRequest(const RMessage2& aMessage,TInt aReason); + + /** + * This is called after each conversion request complete + */ + void RequestCompleteL(); + + + void WriteResultToBufferL(); + + + /** + * Fills in partial results from cache where they are better than those returned from the plugin + */ + void FillInPartialL(); + + /** + * Sends requests from iRequestedInfo to the cacne and uses the result to + * fill in iCacheLookupResults, the RunL will decide which responses to + * write back into iRequestedInfo and send back to the client + */ + TBool CacheLookupL(); + + /* + * Writes any cellid + location pairs received as part of a query back into + * the cache + */ + TBool CacheSaveL(); + +private: // Member variables + /** + * Handle to conversion complete observer + */ + MLbsConversionCompleteObserver& iConversionCompleteObserver; + + /** + * Conversion request. + */ + RMessage2 iConversionRequest; + + /** + * Validation request array. + */ + RArray iValidationRequestQueue; + + /** + * Pointer to conversion plugin + */ + CLbsLocInfoConverterPluginBase* iLocInfoConverterPlugIn; + + /** + * Handle to buffer that contains converted information. + */ + CBufFlat* iBuffer; + + /** + * Client specified request info + */ + TLbsConversionOutputInfoMask iRequestedInfo; + + /** + * Location information array passed from client. + */ + RLbsLocationInfoArray iLocationInfoArray; + + + /** + * A subset of location information array passed from client. + * requests that have been solved by the cache are ommitted + * this array DOES NOT OWN its contents and should not destroy them. + * as the ownership remains with iLocationInfoArray + */ + RLbsLocationInfoArray iSubsetLocationInfoArray; + + /** + * Uid of currently loaded conversion plug in + */ + TUid iConversionPluginId; + + /** + * State of conversion handler. + */ + TState iState; + + /** + * Secure id of client that has outstanding request + */ + TSecureId iCurrentRequestSecureId; + + /** + * Subsession id of client that has outstanding request + */ + TInt iCurrentRequestSubsessionId; + + + /* + * Cache lookup results + */ + RArray iCachePartialResults; + + + /** + * Cache for lookups + */ + RLbsLocMonitorDb iCache; + + + TInt iSavedToCacheCount; + + }; + +#endif /*CLBSLOCMONITORCONVERSIONHANDLER_H_*/ diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorserver/inc/clbslocmonitorgpsbus.h --- a/locationmgmt/locmonitor/lbslocmonitorserver/inc/clbslocmonitorgpsbus.h Thu Jun 24 11:27:31 2010 +0100 +++ b/locationmgmt/locmonitor/lbslocmonitorserver/inc/clbslocmonitorgpsbus.h Thu Jun 24 11:28:34 2010 +0100 @@ -71,7 +71,7 @@ class MLbsLocMonitorGpsBusObserver { public: - virtual void GpsPositionAvailable(const TPosition& aPosition) = 0; + virtual void GpsPositionAvailableL(const TPosition& aPosition) = 0; }; #endif // CLBSLOCMONITORGPSBUS_H \ No newline at end of file diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorserver/inc/clbslocmonitorpluginresolver.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorserver/inc/clbslocmonitorpluginresolver.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,86 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Declaration of CLbsLocMonitorPluginResolver class +* +*/ + +#ifndef CLBSLOCMONITORPLUGINRESOLVER_H_ +#define CLBSLOCMONITORPLUGINRESOLVER_H_ + +#include +#include + +/** + * This class is responsible for choosing the default converter plugin based + * on vendorid and plugin priority. + * + */ +class CLbsLocMonitorPluginResolver : public CActive + { +public: + /** + * Constructs new object of CLbsLocMonitorPluginResolver. + */ + static CLbsLocMonitorPluginResolver* NewL(); + + /** + * Destructor. + */ + ~CLbsLocMonitorPluginResolver(); + + /** + * Returns uid of default converter. + * @param[out] aConverterPluginUid Default converter plugin id. + * @return KErrNotFound If none of converter plugin available. + */ + TInt DefaultConverterUid( TUid& aConverterPluginUid ); + +protected: // From CActive + void RunL(); + void DoCancel(); + + +private: + /** + * Default constructor. + */ + CLbsLocMonitorPluginResolver(); + + /** + * Symbian 2nd phase constructor. + */ + void ConstructL(); + + /** + * Finds default converter plugin + */ + void FindDefaultConverterPluginL(); + + /** + * + */ + TInt PriorityInfo( const TDesC8& aOpaqueData ); +private: // Member variables + + /** + * Pointer to ecom session + */ + REComSession* iEcomSession; + + /** + * Default converter plugin uid. + */ + TUid iDefaultConverterPluginId; + }; +#endif /* CLBSLOCMONITORPLUGINRESOLVER_H_ */ diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorserver/inc/clbslocmonitorposlistener.h --- a/locationmgmt/locmonitor/lbslocmonitorserver/inc/clbslocmonitorposlistener.h Thu Jun 24 11:27:31 2010 +0100 +++ b/locationmgmt/locmonitor/lbslocmonitorserver/inc/clbslocmonitorposlistener.h Thu Jun 24 11:28:34 2010 +0100 @@ -26,7 +26,7 @@ class MLbsLocMonitorPosListenerObserver { public: - virtual void PositionAvailable(const TPosition& aPosition) = 0; + virtual void PositionAvailableL(const TPosition& aPosition) = 0; }; /** @@ -47,7 +47,7 @@ ~CLbsLocMonitorPosListener(); // From MLbsLocMonitorGpsBusObserver - void GpsPositionAvailable(const TPosition& aPosition); + void GpsPositionAvailableL(const TPosition& aPosition); private: diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorserver/inc/clbslocmonitorrequesthandler.h --- a/locationmgmt/locmonitor/lbslocmonitorserver/inc/clbslocmonitorrequesthandler.h Thu Jun 24 11:27:31 2010 +0100 +++ b/locationmgmt/locmonitor/lbslocmonitorserver/inc/clbslocmonitorrequesthandler.h Thu Jun 24 11:28:34 2010 +0100 @@ -126,7 +126,7 @@ as a consequence of a new position being observed on an internal position bus. */ - void PositionAvailable(const TPosition& aPosition); + void PositionAvailableL(const TPosition& aPosition); private: diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorserver/inc/clbslocmonitorserver.h --- a/locationmgmt/locmonitor/lbslocmonitorserver/inc/clbslocmonitorserver.h Thu Jun 24 11:27:31 2010 +0100 +++ b/locationmgmt/locmonitor/lbslocmonitorserver/inc/clbslocmonitorserver.h Thu Jun 24 11:28:34 2010 +0100 @@ -33,6 +33,9 @@ #include "clbslocmonitorposlistener.h" #include "lbsrootapi.h" #include "lbsprocesssupervisor.h" +#include "mlbsconversioncompleteobserver.h" +#include "clbslocmonitorconversionhandler.h" +#include "clbslocmonitorpluginresolver.h" @@ -89,7 +92,8 @@ @released */ class CLbsLocMonitorServer : public CSecureServerBase, - public MLbsProcessCloseDown + public MLbsProcessCloseDown, + public MLbsConversionCompleteObserver { enum TAreaInfoFinder @@ -111,11 +115,21 @@ // to database for writting and reading positions and area info. CLbsLocMonitorRequestHandler& ReadRequestHandler() const; + CLbsLocMonitorConversionHandler* ConversionHandlerL( TUid aConversionPluginId ); + + CLbsLocMonitorConversionHandler* ConversionHandler( const RMessage2& aMessage ); + + CLbsLocMonitorPluginResolver* PluginResolver(); + void SetLocMonServerDestructObserverL(const MLocMonServerDestructObserver& aDestructObserver); void UnsetLocMonServerDestructObserver(const MLocMonServerDestructObserver& aDestructObserver); public: // From MLbsProcessCloseDown void OnProcessCloseDown(); + +public: // From MLbsConversionCompleteObserver + void HandleConversionComplete( CLbsLocMonitorConversionHandler* + aConversionHandler ); protected: @@ -137,6 +151,9 @@ CLbsCloseDownRequestDetector* iCloseDownRequestDetector; + RPointerArray iConversionHandlerArray; + + CLbsLocMonitorPluginResolver* iPluginResolver; RPointerArray iDestructionObservers; }; diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorserver/inc/lbslocmonitorserverdata.h --- a/locationmgmt/locmonitor/lbslocmonitorserver/inc/lbslocmonitorserverdata.h Thu Jun 24 11:27:31 2010 +0100 +++ b/locationmgmt/locmonitor/lbslocmonitorserver/inc/lbslocmonitorserverdata.h Thu Jun 24 11:28:34 2010 +0100 @@ -72,7 +72,13 @@ EGetLastKnownPositionArea = EAreaPositionerFirstMsgId + 2, ECancelGetLastKnownPosition = EAreaPositionerFirstMsgId + 3, ECancelGetLastKnownPositionArea = EAreaPositionerFirstMsgId + 4, - + + EConvertSingleLocationInfoBufferSize = EAreaPositionerFirstMsgId + 5, + EGetSingleLocationInfo = EAreaPositionerFirstMsgId + 6, + EConvertMultipleLocationInfoBufferSize = EAreaPositionerFirstMsgId + 7, + EGetMultipleLocationInfo = EAreaPositionerFirstMsgId + 8, + ECancelConvertLocationInfo = EAreaPositionerFirstMsgId + 9, + // Add here any new message IDs for subsession type AreaPositioner EAreaPositionerLastMessageId, @@ -89,6 +95,8 @@ { ELocMonitorSubSessionTypeUnknown = 0, ELocMonitorSubSessionTypeAreaPositioner, + ELocMonitorSubSessionTypeConversionPositiner, + ELocMonitorSubSessionTypeLocInfoConverter, }; /* Initialisation data sent to the Location Monitor server @@ -100,6 +108,15 @@ TInt iUnused; /* Reserved for future use */ }; +/* Initialisation data sent to the Location Monitor server + when creating a new conversion Positioner subsession. +*/ +class TLbsLocMonitorConversionPositionerData + { +public: + TInt iUnused; /* Reserved for future use */ + }; + /* Parameters sent from client to server in a GetLastKnownPositionArea request diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorserver/inc/locmonitorsettingskeys.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorserver/inc/locmonitorsettingskeys.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,34 @@ +/* +* Copyright (c) 2006 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Defines the cenrep keys of location monitor +* +*/ + + +#ifndef LOCMONITORSETTINGSKEYS_H +#define LOCMONITORSETTINGSKEYS_H + +// CONSTANTS + +// ENUMERATION FOR CENTRAL REPOSITORY KEYS +enum TCenRepKeys + { + EPhoneVendorId = 0x00000001, + }; + +// CENTRAL REPOSITORY UID +const TUid KCRUidLocMonitorSettings = {0x20026814}; + + +#endif // LOCMONITORSETTINGSKEYS_H diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorserver/inc/mlbsconversioncompleteobserver.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorserver/inc/mlbsconversioncompleteobserver.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,37 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ + +#ifndef MLBSCONVERSIONCOMPLETEOBSERVER_H_ +#define MLBSCONVERSIONCOMPLETEOBSERVER_H_ + +// Forward declarations +class CLbsLocMonitorConversionHandler; + +/** + * Class that needs to implement this interface to listen + * to conversion complete event from the handler. + * + */ +class MLbsConversionCompleteObserver + { +public: + virtual void HandleConversionComplete(CLbsLocMonitorConversionHandler* + aConversionHandler) = 0; + }; + + +#endif /*MLBSCONVERSIONCOMPLETEOBSERVER_H_*/ diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorserver/src/clbsconversionpositionersubsession.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorserver/src/clbsconversionpositionersubsession.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,201 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ + +#include "clbsconversionpositionersubsession.h" +#include "lbslocmonitorserverdata.h" +#include "clbslocmonitorutils.h" +#include "clbslocmonitorserver.h" +#include "lbsdevloggermacros.h" +#include "clbslocmonitorconversionhandler.h" +#include "lbslocmonitorclientconsts.h" + +//---------------------------------------------------------------------------- +// CLbsConversionPositionerSubsession::NewL +// +//----------------------------------------------------------------------------- +CLbsConversionPositionerSubsession* CLbsConversionPositionerSubsession::NewL() + { + LBSLOG(ELogP1,"CLbsConversionPositionerSubsession::NewL()"); + CLbsConversionPositionerSubsession* self = new (ELeave) CLbsConversionPositionerSubsession; + CleanupStack::PushL(self); + self->ConstructL(); + CleanupStack::Pop(self); + return self; + } + + +// ----------------------------------------------------------------------------- +// CLbsConversionPositionerSubsession::~CLbsConversionPositionerSubsession +//------------------------------------------------------------------------------ +CLbsConversionPositionerSubsession::CLbsConversionPositionerSubsession() + { + LBSLOG(ELogP1,"CLbsConversionPositionerSubsession::CLbsConversionPositionerSubsession()"); + } + +// ----------------------------------------------------------------------------- +// CLbsConversionPositionerSubsession::ConstructL +//------------------------------------------------------------------------------ +void CLbsConversionPositionerSubsession::ConstructL() + { + LBSLOG(ELogP1,"CLbsConversionPositionerSubsession::ConstructL()"); + // Nothing to do + } +//---------------------------------------------------------------------------- +// CLbsConversionPositionerSubsession::~CLbsConversionPositionerSubsession +// +//----------------------------------------------------------------------------- +CLbsConversionPositionerSubsession::~CLbsConversionPositionerSubsession() + { + LBSLOG(ELogP1,"->CLbsConversionPositionerSubsession::~CLbsConversionPositionerSubsession"); + + // Tell the DB reader that this subsession is being deleted + // so that if there are any outanding requests from this session + // they are terminated with KErrServerTerminated. + iLocMonitorServer->ReadRequestHandler().ClientTerminated(iSubsessionId); + + LBSLOG(ELogP1,"<-CLbsConversionPositionerSubsession::~CLbsConversionPositionerSubsession"); + } + +//---------------------------------------------------------------------------- +// CLbsConversionPositionerSubsession::DispatchL +// +//----------------------------------------------------------------------------- +void CLbsConversionPositionerSubsession::DispatchL(const RMessage2& aMessage) + { + LBSLOG(ELogP1,"CLbsConversionPositionerSubsession::DispatchL()"); + switch(aMessage.Function()) + { + case EConvertSingleLocationInfoBufferSize: + case EConvertMultipleLocationInfoBufferSize: + { + // Extract client preferences + TLbsClientPrefs clientPrefs; + TPckg clientPrefsPckg(clientPrefs); + aMessage.ReadL(KParamClientPrefs,clientPrefsPckg); + + // If client has not specified any conversion plugin id, read the default + // plugin from cenrep and load it. + TUid conversionPluginId; + if(clientPrefs.iConverterModuleId.iUid == KNullUidValue) + { + TInt error = iLocMonitorServer->PluginResolver()->DefaultConverterUid( + conversionPluginId); + if(error != KErrNone) + { + aMessage.Complete(error); + return; + } + } + else + { + conversionPluginId = clientPrefs.iConverterModuleId; + } + + CLbsLocMonitorConversionHandler* conversionHandler = + iLocMonitorServer->ConversionHandlerL(conversionPluginId); + conversionHandler->GetConvertLocationInfoSizeL(aMessage); + break; + } + + case EGetSingleLocationInfo: + case EGetMultipleLocationInfo: + { + CLbsLocMonitorConversionHandler* conversionHandler = + iLocMonitorServer->ConversionHandler(aMessage); + + conversionHandler->GetConvertedLocationInfoL(aMessage); + break; + } + + + + case ECancelConvertLocationInfo: + { + CLbsLocMonitorConversionHandler* conversionHandler = + iLocMonitorServer->ConversionHandler(aMessage); + + // If there is no outstanding request from the subsession which requested cancel operation, + // complete the request. + if(conversionHandler) + { + conversionHandler->CancelLocationInfoConversionL(aMessage); + } + else + { + aMessage.Complete(KErrNone); + } + break; + } + default: + __ASSERT_DEBUG(EFalse, User::Invariant()); + break; + } + } + + +//---------------------------------------------------------------------------- +// CLbsConversionPositionerSubsession::DispatchError +// +//----------------------------------------------------------------------------- +void CLbsConversionPositionerSubsession::DispatchError(const RMessage2& aMessage, + TInt aError) + { + LBSLOG(ELogP1,"CLbsConversionPositionerSubsession::DispatchError()"); + // errors from DispatchL end up in here + aMessage.Complete(aError); + } + + +//---------------------------------------------------------------------------- +// CLbsConversionPositionerSubsession::DispatchError +// +//----------------------------------------------------------------------------- +void CLbsConversionPositionerSubsession::CreateSubSessionL(const RMessage2& aMessage, + const CSecureServerBase* aServer) + { + LBSLOG(ELogP1,"CLbsAreaPositionerSubsession::CreateSubSessionL()"); + CSecureServerBase* server = const_cast (aServer); + iLocMonitorServer = reinterpret_cast(server); + iSubsessionId.iSessionPtr = static_cast(aMessage.Session()); + + TInt subsessionId; + TPckg subsessionIdBuf(subsessionId); + User::LeaveIfError(aMessage.Read(3, subsessionIdBuf)); + + iSubsessionId.iSubsessionId = subsessionId; + } + +//---------------------------------------------------------------------------- +// CLbsConversionPositionerSubsession::CloseSubSession +// +//----------------------------------------------------------------------------- +void CLbsConversionPositionerSubsession::CloseSubSession() + { + LBSLOG(ELogP1,"CLbsConversionPositionerSubsession::CloseSubSession()"); + // Release anything allocated in CreateSubSessionL. + // In this case there is nothing to do. + } + +//---------------------------------------------------------------------------- +// CLbsConversionPositionerSubsession::VirtualRelease +// +//----------------------------------------------------------------------------- +void CLbsConversionPositionerSubsession::VirtualRelease() + { + LBSLOG(ELogP1,"CLbsConversionPositionerSubsession::VirtualRelease()"); + delete this; + } diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorserver/src/clbslocmonitorconversionhandler.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorserver/src/clbslocmonitorconversionhandler.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,910 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Implementation of CLbsLocMonitorConversionHandler class. +* +*/ + +#include +#include +#include +#include +#include "clbslocmonitorconversionhandler.h" +#include "lbslocmonitorclientconsts.h" +#include "lbslocmonitorserverdata.h" +#include "lbsdevloggermacros.h" + + + +// constants +const TInt KCurrentRequestIndex = 0; +const TInt KMaxBufferSize = 512; + +//TODO need to agree which core lbs header to put them in and names +const TReal32 KWlanAccuracy = 100.0; +const TReal32 KCellFullAccuracy = 3000.0; +const TReal32 KCellLocationAccuracy = 30000.0; +const TReal32 KCellCountryAccuracy = 1000000.0; + + + +void CleanUpResetAndDestroy(TAny* aArray) + { + static_cast(aArray)->ResetAndDestroy(); + } + +//---------------------------------------------------------------- +// CLbsLocMonitorConversionHandler::NewL +// (other items were commented in a header). +//---------------------------------------------------------------- +CLbsLocMonitorConversionHandler* CLbsLocMonitorConversionHandler::NewL( + MLbsConversionCompleteObserver& + aConversionCompleteObserver, + TUid aConversionPluginUid) + { + LBSLOG(ELogP1,"CLbsLocMonitorConversionHandler::NewL()"); + CLbsLocMonitorConversionHandler* self = new(ELeave) + CLbsLocMonitorConversionHandler( + aConversionCompleteObserver); + CleanupStack::PushL(self); + self->ConstructL(aConversionPluginUid); + CleanupStack::Pop(self); + return self; + } + +//---------------------------------------------------------------- +// CLbsLocMonitorConversionHandler::CLbsLocMonitorConversionHandler +// (other items were commented in a header). +//---------------------------------------------------------------- +CLbsLocMonitorConversionHandler::CLbsLocMonitorConversionHandler( + MLbsConversionCompleteObserver& + aConversionCompleteObserver): + CActive(EPriorityStandard), + iConversionCompleteObserver( + aConversionCompleteObserver) + + { + LBSLOG(ELogP1,"CLbsLocMonitorConversionHandler::CLbsLocMonitorConversionHandler()"); + CActiveScheduler::Add(this); + iBuffer = NULL; + iLocInfoConverterPlugIn = NULL; + iConversionPluginId = TUid::Uid(KNullUidValue); + iState = EStateIdle; + } + +//---------------------------------------------------------------- +// CLbsLocMonitorConversionHandler::~CLbsLocMonitorConversionHandler +// (other items were commented in a header). +//---------------------------------------------------------------- +CLbsLocMonitorConversionHandler::~CLbsLocMonitorConversionHandler() + { + LBSLOG(ELogP1,"CLbsLocMonitorConversionHandler::~CLbsLocMonitorConversionHandler()"); + + iCachePartialResults.Reset(); + iSubsetLocationInfoArray.Reset(); // NOT OWNED! + iLocationInfoArray.ResetAndDestroy(); + + iValidationRequestQueue.Close(); + + delete iLocInfoConverterPlugIn; + delete iBuffer; + iCache.Close(); + // NewL of plugin internally uses REComSession to find implementations. + // Hence it needs to be closed to avoid memory leak. + REComSession::FinalClose(); + } + +//---------------------------------------------------------------- +// CLbsLocMonitorConversionHandler::ConstructL +// (other items were commented in a header). +//---------------------------------------------------------------- +void CLbsLocMonitorConversionHandler::ConstructL(TUid aConversionPluginUid) + { + LBSLOG(ELogP1,"CLbsLocMonitorConversionHandler::ConstructL()"); + LoadConversionPluginL(aConversionPluginUid); + iCache.OpenL(); + } + +//---------------------------------------------------------------- +// CLbsLocMonitorConversionHandler::GetConvertLocationInfoSizeL +// (other items were commented in a header). +//---------------------------------------------------------------- +void CLbsLocMonitorConversionHandler::GetConvertLocationInfoSizeL( + const RMessage2& aMessage) + { + LBSLOG(ELogP1,"CLbsLocMonitorConversionHandler::GetConvertLocationInfoSizeL()"); + iValidationRequestQueue.AppendL(aMessage); + + // If the message which is appended is the only message in the queue, + // send the necessary information of the message to the plug in for + // validation. + if(iValidationRequestQueue.Count() == 1) + { + iState = EStateValidation; + // Extract client preferences to get the requested info. + TLbsClientPrefs clientPrefs; + TPckg clientPrefsPckg(clientPrefs); + aMessage.ReadL(KParamClientPrefs,clientPrefsPckg); + + iLocInfoConverterPlugIn->ValidateClient(aMessage.SecureId(), + aMessage.VendorId(), + clientPrefs.iRequestedInfo); + } + } + +//---------------------------------------------------------------- +// CLbsLocMonitorConversionHandler::ProcessRequestL +// (other items were commented in a header). +//---------------------------------------------------------------- +TInt CLbsLocMonitorConversionHandler::ProcessRequestL() + { + LBSLOG(ELogP1,"CLbsLocMonitorConversionHandler::ProcessRequestL()"); + // Reset the member variables. + iLocationInfoArray.ResetAndDestroy(); + delete iBuffer; + iBuffer = NULL; + iState = EStateIdle; + + // Store secure id and subsession id of the request. This is required + // to identify the next IPC that requests for actual data. + iCurrentRequestSecureId = iConversionRequest.SecureId(); + iCurrentRequestSubsessionId = iConversionRequest.Int3(); + + // Extract client preferences + TLbsClientPrefs clientPrefs; + TPckg clientPrefsPckg(clientPrefs); + iConversionRequest.ReadL(KParamClientPrefs,clientPrefsPckg); + + // Store the client requested info.This is required to extract the + // required information on conversion complete. + iRequestedInfo = clientPrefs.iRequestedInfo; + + // Extract the client specified location information + TInt dataSize = iConversionRequest.GetDesLength(KParamLocationInfo); + if (dataSize < 0) + { + CompleteRequest(iConversionRequest,KErrBadDescriptor); + return KErrBadDescriptor; + } + HBufC8* buffer = HBufC8::NewLC(dataSize); + TPtr8 ptrToBuf = buffer->Des(); + iConversionRequest.ReadL(KParamLocationInfo, ptrToBuf); + + RDesReadStream stream(*buffer); + CleanupClosePushL(stream); + + TInt count; + // Read the number of location info object only incase of multiple conversion + if(iConversionRequest.Function() == EConvertMultipleLocationInfoBufferSize) + { + count = stream.ReadInt8L(); + } + else + { + // Incase of single location info conversion, count value is always one. + count = 1; + } + + for(TInt i = 0; iInternaliseL(stream); + CleanupStack::Pop(locationInfo); + iLocationInfoArray.AppendL(locationInfo); + } + + CleanupStack::PopAndDestroy(2); // stream,buffer + + iState = EStateConversion; + // Ask Cache, + // take different action depending on whether it has results for all our requests + if(CacheLookupL()) + { + // Cache has supplied all positions. We can self complete now to pass result back to client + iState = EStateCacheSaveComplete; + } + else + { + // Cache did not have all the positions we wanted, must go to plugin + iLocInfoConverterPlugIn->ConvertLocationInfoL(iSubsetLocationInfoArray, + clientPrefs.iConversionPrefs, + clientPrefs.iRequestedInfo); + } + return KErrNone; + } + +//---------------------------------------------------------------- +// CLbsLocMonitorConversionHandler::LoadConversionPluginL +// (other items were commented in a header). +//---------------------------------------------------------------- +void CLbsLocMonitorConversionHandler::LoadConversionPluginL( + TUid aConversionModuleId) + { + LBSLOG(ELogP1,"CLbsLocMonitorConversionHandler::LoadConversionPluginL()"); + TLbsLocInfoConverterPluginParams conversionPluginParam(*this); + + iLocInfoConverterPlugIn = CLbsLocInfoConverterPluginBase::NewL( + aConversionModuleId,conversionPluginParam); + iConversionPluginId = aConversionModuleId; + } + +//---------------------------------------------------------------- +// CLbsLocMonitorConversionHandler::GetConvertLocationInfoL +// (other items were commented in a header). +//---------------------------------------------------------------- +void CLbsLocMonitorConversionHandler::GetConvertedLocationInfoL( + const RMessage2& aMessage) + { + LBSLOG(ELogP1,"CLbsLocMonitorConversionHandler::GetConvertedLocationInfoL()"); + TPtr8 ptr = iBuffer->Ptr(0); + aMessage.WriteL(KParamConvertedInfo,ptr); + aMessage.Complete(KErrNone); + + // This is the last step of a any location conversion. Hence request + // complete call needs to be called to process next request if any. + RequestCompleteL(); + } + +//---------------------------------------------------------------- +// CLbsLocMonitorConversionHandler::IsMessagePresent +// (other items were commented in a header). +//---------------------------------------------------------------- +TBool CLbsLocMonitorConversionHandler::IsMessagePresent( + const RMessage2& aMessage) + { + LBSLOG(ELogP1,"CLbsLocMonitorConversionHandler::IsMessagePresent()"); + // Iterate through the validation request array to find the message. + // First element in the validation queue will the current request + // under conversion. + for(TInt i=0;iCancelValidateClient(); + break; + + case EStateConversion: + iLocInfoConverterPlugIn->CancelConvertLocationInfo(); + break; + + default: + break; + } + CompleteRequest(iValidationRequestQueue[i],KErrCancel); + Cancel(); + RequestCompleteL(); + } + else + { + RMessage2 message = iValidationRequestQueue[i]; + iValidationRequestQueue.Remove(i); + message.Complete(KErrCancel); + } + aMessage.Complete(KErrNone); + return; + } + } + } + +//---------------------------------------------------------------- +// CLbsLocMonitorConversionHandler::ConversionPluginUid +// (other items were commented in a header). +//---------------------------------------------------------------- +TUid CLbsLocMonitorConversionHandler::ConversionPluginUid() + { + LBSLOG(ELogP1,"CLbsLocMonitorConversionHandler::ConversionPluginUid()"); + return iConversionPluginId; + } + +//---------------------------------------------------------------- +// CLbsLocMonitorConversionHandler::OnConversionComplete +// (other items were commented in a header). +//---------------------------------------------------------------- +void CLbsLocMonitorConversionHandler::OnConversionComplete(TInt aStatusCode) + { + LBSLOG(ELogP1,"CLbsLocMonitorConversionHandler::OnConversionComplete()"); + // This is done to release the Plug-in's method from which this method + // has been called. + TRequestStatus* statusPtr = &iStatus; + iStatus = KRequestPending; + SetActive(); + User::RequestComplete(statusPtr,aStatusCode); + } + +//---------------------------------------------------------------- +// CLbsLocMonitorConversionHandler::OnValidationComplete +// (other items were commented in a header). +//---------------------------------------------------------------- +void CLbsLocMonitorConversionHandler::OnValidationComplete(TInt aStatusCode) + { + LBSLOG(ELogP1,"CLbsLocMonitorConversionHandler::OnValidationComplete()"); + // This is done to release the Plug-in's method from which this method + // has been called. + TRequestStatus* statusPtr = &iStatus; + iStatus = KRequestPending; + SetActive(); + User::RequestComplete(statusPtr,aStatusCode); + } + + +void CLbsLocMonitorConversionHandler::WriteResultToBufferL() + { + iBuffer = CBufFlat::NewL(KMaxBufferSize); + RBufWriteStream writeStream; + writeStream.Open(*iBuffer); + CleanupClosePushL(writeStream); + + // Write the count only if multiple conversion was requested by client. + if(iConversionRequest.Function() == EConvertMultipleLocationInfoBufferSize) + { + writeStream.WriteInt8L(iLocationInfoArray.Count()); + } + + switch(iRequestedInfo) + { + case ELbsConversionOutputPosition: + WriteAreaInfoL(writeStream,CLbsLocationInfo::ELbsPosInfo); + break; + + case ELbsConversionOutputGsm: + WriteAreaInfoL(writeStream,CLbsLocationInfo::ELbsGsmInfo); + break; + + case ELbsConversionOutputWcdma: + WriteAreaInfoL(writeStream,CLbsLocationInfo::ELbsWcdmaInfo); + break; + + case ELbsConversionOutputWlan: + WriteAreaInfoL(writeStream,CLbsLocationInfo::ELbsWlanInfo); + break; + + default: + break; + } + + writeStream.CommitL(); + CleanupStack::PopAndDestroy(&writeStream); + } + +//---------------------------------------------------------------- +// CLbsLocMonitorConversionHandler::RunL +// (other items were commented in a header). +//---------------------------------------------------------------- +void CLbsLocMonitorConversionHandler::RunL() + { + LBSLOG(ELogP1,"CLbsLocMonitorConversionHandler::RunL()"); + TBool cacheSaveComplete = EFalse; + switch(iState) + { + case EStateValidation: + { + // This validation result corresponds to the first request in the validation + // queue. + iConversionRequest = iValidationRequestQueue[KCurrentRequestIndex]; + if(iStatus.Int() == KErrNone) + { + // On successful validation, process the request + ProcessRequestL(); + } + else + { + iConversionRequest.Complete(iStatus.Int()); + RequestCompleteL(); + } + break; + } + case EStateConversion: + { + if(iStatus.Int() == KErrNone) + { + //First we loop through comparing accuracies to any partial results we may have had + FillInPartialL(); + + TLbsConversionPluginInfo pluginPreferences; + iLocInfoConverterPlugIn->ConversionPluginPreferences(pluginPreferences); + + // Then save all things we are allowed to, to the cache + if(pluginPreferences.IsPluginPositionToBeCached()) + { + iSavedToCacheCount = 0; + cacheSaveComplete = CacheSaveL(); + if(cacheSaveComplete) + { + iState = EStateCacheSaveComplete; + } + } + else + { + WriteResultToBufferL(); + + // Send the required buffer size to the client. + TInt size = iBuffer->Size(); + TPckg sizePckg(size); + iConversionRequest.WriteL(KParamBufferSize,sizePckg); + CompleteRequest(iConversionRequest,KErrNone); + } + } + else + { + // Since there is error in conversion, server dont receive + // any call to retrieve converted info.Hence we need to + // remove the current request. + CompleteRequest(iConversionRequest,iStatus.Int()); + RequestCompleteL(); + } + break; + } + case EStateCacheSave: + { + cacheSaveComplete = CacheSaveL(); + if(cacheSaveComplete) + { + iState = EStateCacheSaveComplete; + } + break; + } + case EStateCacheSaveComplete: + { + // fall through + break; + } + default: + { + User::Invariant(); + } + } + if(iState == EStateCacheSaveComplete) + { + WriteResultToBufferL(); + + // Send the required buffer size to the client. + TInt size = iBuffer->Size(); + TPckg sizePckg(size); + iConversionRequest.WriteL(KParamBufferSize,sizePckg); + CompleteRequest(iConversionRequest,KErrNone); + } + } + + +//---------------------------------------------------------------- +// CLbsLocMonitorConversionHandler::RequestCompleteL +// (other items were commented in a header). +//---------------------------------------------------------------- +void CLbsLocMonitorConversionHandler::RequestCompleteL() + { + LBSLOG(ELogP1,"CLbsLocMonitorConversionHandler::RequestCompleteL()"); + // Remove the completed conversion request. + iValidationRequestQueue.Remove(KCurrentRequestIndex); + + // Process the next the request in the queue incase any. + if(iValidationRequestQueue.Count()) + { + iState = EStateValidation; + // Extract client preferences to get the requested info. + TLbsClientPrefs clientPrefs; + TPckg clientPrefsPckg(clientPrefs); + iValidationRequestQueue[KCurrentRequestIndex].ReadL(KParamClientPrefs,clientPrefsPckg); + + iLocInfoConverterPlugIn->ValidateClient( + iValidationRequestQueue[KCurrentRequestIndex].SecureId(), + iValidationRequestQueue[KCurrentRequestIndex].VendorId(), + clientPrefs.iRequestedInfo); + } + else + { + iConversionCompleteObserver.HandleConversionComplete(this); + } + } + + +//---------------------------------------------------------------- +// CLbsLocMonitorConversionHandler::DoCancel +// (other items were commented in a header). +//---------------------------------------------------------------- +void CLbsLocMonitorConversionHandler::DoCancel() + { + LBSLOG(ELogP1,"CLbsLocMonitorConversionHandler::DoCancel()"); + // Nothing to do here. + } + +//---------------------------------------------------------------- +// CLbsLocMonitorConversionHandler::WriteAreaInfoL +// (other items were commented in a header). +//---------------------------------------------------------------- +void CLbsLocMonitorConversionHandler::WriteAreaInfoL(RBufWriteStream& + aWriteStream, + CLbsLocationInfo::TAreaInfoMask aAreaInfoMask) + { + LBSLOG(ELogP1,"CLbsLocMonitorConversionHandler::WriteAreaInfoL()"); + for(TInt i=0;iGetAreaInfoL(areaInfoArray,aAreaInfoMask); + + // Write the count of converted information for each location info object. + TInt count = areaInfoArray.Count(); + aWriteStream.WriteInt8L(count); + + for(TInt j=0;jExternaliseL(aWriteStream); + } + CleanupStack::PopAndDestroy(&areaInfoArray); + } + } + +//---------------------------------------------------------------- +// CLbsLocMonitorConversionHandler::CompleteRequest +// (other items were commented in a header). +//---------------------------------------------------------------- +void CLbsLocMonitorConversionHandler::CompleteRequest(const RMessage2& aMessage, + TInt aReason) + { + LBSLOG(ELogP1,"CLbsLocMonitorConversionHandler::CompleteRequest()"); + TInt pos = iValidationRequestQueue.Find(aMessage); + if(!aMessage.IsNull()) + { + aMessage.Complete(aReason); + iValidationRequestQueue[pos] = aMessage; + } + } + + +//---------------------------------------------------------------- +// CLbsLocMonitorConversionHandler::CompareMessage +// (other items were commented in a header). +//---------------------------------------------------------------- +TBool CLbsLocMonitorConversionHandler::CompareMessage(const RMessage2& aSrc, + const RMessage2& aDes) + { + LBSLOG(ELogP1,"CLbsLocMonitorConversionHandler::CompareMessage()"); + // If the src message is NULL,this is the message corresponding to the + // first request for which it is completed with size of converted info. + // Hence it needs to checked aganist current request's secure id and the + // subsession id. + if(aSrc.IsNull()) + { + if(aDes.SecureId() == iCurrentRequestSecureId && + aDes.Int3() == iCurrentRequestSubsessionId) + { + return ETrue; + } + return EFalse; + } + + // Subsession id is stored in the 4th IPC slot. + if(aSrc.SecureId() == aDes.SecureId() && + aSrc.Int3() == aDes.Int3()) + { + return ETrue; + } + return EFalse; + } + + +//---------------------------------------------------------------- +// CLbsLocMonitorConversionHandler::AccuracyFromMatchLevel +// (other items were commented in a header). +//---------------------------------------------------------------- +TReal32 CLbsLocMonitorConversionHandler::AccuracyFromMatchLevel(TPositionAreaExtendedInfo::TArea aMatchlevel) + { + TRealX outputAccuracy; + outputAccuracy.SetNaN(); + switch(aMatchlevel) + { + case TPositionAreaExtendedInfo::EAreaUnknown: + { + break; + } + case TPositionAreaExtendedInfo::EAreaCountry: + { + outputAccuracy.Set(KCellCountryAccuracy); + break; + } + case TPositionAreaExtendedInfo::EAreaRegion: + { + outputAccuracy.Set(KCellLocationAccuracy); + break; + } + case TPositionAreaExtendedInfo::EAreaCity: + { + outputAccuracy.Set(KCellFullAccuracy); + break; + } + case TPositionAreaExtendedInfo::EAreaDistrict: + { + outputAccuracy.Set(KWlanAccuracy); + break; + } + case TPositionAreaExtendedInfo::EAreaStreet: + { + outputAccuracy.Set(KWlanAccuracy); + break; + } + default: + { + break; + } + } + return outputAccuracy; + } + + + +void CLbsLocMonitorConversionHandler::FillInPartialL() + { + TInt infoCount = iSubsetLocationInfoArray.Count(); + TInt partialCount = iCachePartialResults.Count(); + if((infoCount != partialCount) || infoCount == 0) + return; + + for(TInt i = 0; i < infoCount; i++) + { + CLbsLocationInfo* locationInfo = static_cast(iSubsetLocationInfoArray[i]); + + RLbsAreaInfoBaseArray locationArray; + CleanupStack::PushL(TCleanupItem(*CleanUpResetAndDestroy, &locationArray)); + locationInfo->GetAreaInfoL(locationArray, CLbsLocationInfo::ELbsPosInfo); + + if(locationArray.Count() > 0) + { + CLbsPositionInfo* location = static_cast(locationArray[0]); + TLocality pluginLocality; + location->GetLocality(pluginLocality); + if(!Math::IsNaN(iCachePartialResults[i].HorizontalAccuracy()) && + (iCachePartialResults[i].HorizontalAccuracy() < pluginLocality.HorizontalAccuracy())) + { + locationInfo->ResetAreaInfo(CLbsLocationInfo::ELbsPosInfo); + CLbsPositionInfo* newLocation = CLbsPositionInfo::NewL(iCachePartialResults[i]); + locationInfo->AddAreaInfoL(newLocation); + } + } + CleanupStack::PopAndDestroy(&locationArray); + } + } + + + +//---------------------------------------------------------------- +// CLbsLocMonitorConversionHandler::CacheLookupL +// (other items were commented in a header). +//---------------------------------------------------------------- +TBool CLbsLocMonitorConversionHandler::CacheLookupL() + { + iCachePartialResults.Reset(); + // Does NOT own contents + iSubsetLocationInfoArray.Reset(); + TInt infoCount = iLocationInfoArray.Count(); + // We only do lookups if the client wants a position + if(iRequestedInfo != ELbsConversionOutputPosition) + { + // copy all into subset array, the cache has solved nothing + for(TInt i = 0; i < infoCount; i++) + { + iSubsetLocationInfoArray.AppendL(iLocationInfoArray[i]); + } + return EFalse; + } + + TInt cacheLoads = 0; + TBool resolved = EFalse; + + + for(TInt i=0; i < infoCount; i++) + { + CLbsLocationInfo* locationInfo = static_cast(iLocationInfoArray[i]); + RLbsAreaInfoBaseArray areaArray; + CleanupStack::PushL(TCleanupItem(*CleanUpResetAndDestroy, &areaArray)); + // NOTE! When locmonitor is expanded to cache 3g / wlan this call must be changed! + locationInfo->GetAreaInfoL(areaArray, ELbsAreaGsmCellInfoClass); + + TInt areaCount = areaArray.Count(); + TBool saved = EFalse; + + TRealX nan; + nan.SetNaN(); + TLocality partialLocality; + partialLocality.SetCoordinate(nan, nan, nan); + partialLocality.SetAccuracy(nan, nan); + + for (TInt j = 0; j < areaCount; j++) + { + resolved = EFalse; + TLbsAreaInfoClassType type = areaArray[j]->Type(); + TLbsLocMonitorAreaInfoGci areaInfoGci; + switch(type) + { + case ELbsAreaGsmCellInfoClass: + { + CLbsGsmCellInfo* area = static_cast(areaArray[j]); + areaInfoGci.iMcc = area->MobileCountryCode(); + areaInfoGci.iMnc = area->MobileNetworkCode(); + areaInfoGci.iLac = area->LocationAreaCode(); + areaInfoGci.iCid = area->CellId(); + resolved = ETrue; + break; + } + default: + { + resolved = EFalse; + break; + } + } + + if(resolved && !saved) + { + TPosition position; + RPointerArray outArray; + outArray.Append(&areaInfoGci); + TPositionAreaExtendedInfo matchLevel; + matchLevel.SetArea(TPositionAreaInfo::EAreaUnknown); + TRequestStatus status; + // Cache gets are fast and not really asynch, so no harm in blocking here + TInt ret = iCache.GetPosition(position,outArray,matchLevel,status); + if((ret == KErrNone) || (ret == KErrNotFound)) + { + User::WaitForRequest(status); + } + outArray.Reset(); + + if((ret == KErrNone) && (matchLevel.Area() >= TPositionAreaExtendedInfo::EAreaCity)) + { + TLocality locality; + locality.SetCoordinate(position.Latitude(), position.Longitude(), + position.Altitude()); + TRealX nan; + nan.SetNaN(); + locality.SetAccuracy(AccuracyFromMatchLevel(matchLevel.Area()), nan); + + CLbsPositionInfo* positionInfo = CLbsPositionInfo::NewL(locality); + CleanupStack::PushL(positionInfo); + iLocationInfoArray[i]->AddAreaInfoL(positionInfo); + CleanupStack::Pop(positionInfo); + saved = ETrue; + cacheLoads++; + } + else if ((ret == KErrNone) && (matchLevel.Area() > TPositionAreaExtendedInfo::EAreaUnknown)) + { + // we also store partial matches in case they are better than the plugin response + partialLocality.SetCoordinate(position.Latitude(), position.Longitude(), + position.Altitude()); + TRealX nan; + nan.SetNaN(); + partialLocality.SetAccuracy(AccuracyFromMatchLevel(matchLevel.Area()), nan); + } + + } + } + if(!saved) + { + //copy into subset array, we couldn't solve this from cache + iSubsetLocationInfoArray.AppendL(iLocationInfoArray[i]); + + iCachePartialResults.AppendL(partialLocality); + } + CleanupStack::PopAndDestroy(&areaArray); + } + // If we've loaded as many results from the cache as there are requests + // then we have fully satisfied the query + return cacheLoads == infoCount; + } + + +//---------------------------------------------------------------- +// CLbsLocMonitorConversionHandler::CacheSaveL +// (other items were commented in a header). +//---------------------------------------------------------------- +TBool CLbsLocMonitorConversionHandler::CacheSaveL() + { + iState = EStateCacheSave; + TBool saveRequested = EFalse; + TInt infoCount = iSubsetLocationInfoArray.Count(); + while((iSavedToCacheCount < infoCount) && !saveRequested) + { + CLbsLocationInfo* locationInfo = static_cast(iSubsetLocationInfoArray[iSavedToCacheCount]); + + RLbsAreaInfoBaseArray cellArray; + CleanupStack::PushL(TCleanupItem(*CleanUpResetAndDestroy, &cellArray)); + locationInfo->GetAreaInfoL(cellArray, CLbsLocationInfo::ELbsGsmInfo); + + RLbsAreaInfoBaseArray locationArray; + CleanupStack::PushL(TCleanupItem(*CleanUpResetAndDestroy, &locationArray)); + locationInfo->GetAreaInfoL(locationArray, CLbsLocationInfo::ELbsPosInfo); + + + // We should get only 1 pos back but may have passed in multiple cells + // We want to save that pos against all cells + if((locationArray.Count() > 0) && (cellArray.Count() > 0)) + { + CLbsPositionInfo* location = static_cast(locationArray[0]); + TLocality locality; + location->GetLocality(locality); + // Only locations that have an accuracy that is better than a cell + // location code will be saved in the cache + if(locality.HorizontalAccuracy() < KCellLocationAccuracy) + { + for(TInt i = 0; i < cellArray.Count(); i++) + { + CLbsGsmCellInfo* cell = static_cast(cellArray[i]); + TLbsLocMonitorAreaInfoGci areaInfoGci; + areaInfoGci.iMcc = cell->MobileCountryCode(); + areaInfoGci.iMnc = cell->MobileNetworkCode(); + areaInfoGci.iLac = cell->LocationAreaCode(); + areaInfoGci.iCid = cell->CellId(); + RPointerArray areaArray; + areaArray.Append(&areaInfoGci); + TTime now; + now.HomeTime(); + TPosition pos(locality, now); + TInt ret = iCache.SavePosition(pos, areaArray, iStatus); + if(ret != KErrNone) + { + saveRequested = EFalse; + } + else + { + saveRequested = ETrue; + SetActive(); + } + areaArray.Reset(); + } + } + } + CleanupStack::PopAndDestroy(&locationArray); + CleanupStack::PopAndDestroy(&cellArray); + iSavedToCacheCount++; + } + if((iSavedToCacheCount >= infoCount) && !saveRequested) + { + return ETrue; + } + return EFalse; + } + + +// End of file. diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorserver/src/clbslocmonitorgpsbus.cpp --- a/locationmgmt/locmonitor/lbslocmonitorserver/src/clbslocmonitorgpsbus.cpp Thu Jun 24 11:27:31 2010 +0100 +++ b/locationmgmt/locmonitor/lbslocmonitorserver/src/clbslocmonitorgpsbus.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -93,7 +93,7 @@ { TPosition position; positionInfo.GetPosition(position); - iObserver.GpsPositionAvailable(position); + iObserver.GpsPositionAvailableL(position); } else { diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorserver/src/clbslocmonitorpluginresolver.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/lbslocmonitorserver/src/clbslocmonitorpluginresolver.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,302 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Implementation of CLbsLocMonitorPluginResolver class +* +*/ + +#include +#include +#include "clbslocmonitorpluginresolver.h" +#include "locmonitorsettingskeys.h" +#include "lbsdevloggermacros.h" + +// Constants +static const TInt KLeastPluginPriority = 0; + +//---------------------------------------------------------------------------- +// CLbsLocMonitorPluginResolver::NewL +// +//----------------------------------------------------------------------------- +CLbsLocMonitorPluginResolver* CLbsLocMonitorPluginResolver::NewL() + { + LBSLOG(ELogP1,"CLbsLocMonitorPluginResolver::NewL()"); + CLbsLocMonitorPluginResolver* self = new (ELeave) CLbsLocMonitorPluginResolver; + CleanupStack::PushL(self); + self->ConstructL(); + CleanupStack::Pop(self); + return self; + } + +//---------------------------------------------------------------------------- +// CLbsLocMonitorPluginResolver::CLbsLocMonitorPluginResolver +// +//----------------------------------------------------------------------------- +CLbsLocMonitorPluginResolver::CLbsLocMonitorPluginResolver(): +CActive(EPriorityStandard), iDefaultConverterPluginId(KNullUid) + { + LBSLOG(ELogP1,"CLbsLocMonitorPluginResolver::CLbsLocMonitorPluginResolver()"); + CActiveScheduler::Add(this); + } + +//---------------------------------------------------------------------------- +// CLbsLocMonitorPluginResolver::ConstructL +// +//----------------------------------------------------------------------------- +void CLbsLocMonitorPluginResolver::ConstructL() + { + LBSLOG(ELogP1,"CLbsLocMonitorPluginResolver::ConstructL()"); + iEcomSession = &(REComSession::OpenL()); + // Find the default plugin. + FindDefaultConverterPluginL(); + // Register for ecom data change. + iEcomSession->NotifyOnChange(iStatus); + SetActive(); + } + +//---------------------------------------------------------------------------- +// CLbsLocMonitorPluginResolver::~CLbsLocMonitorPluginResolver +// +//----------------------------------------------------------------------------- +CLbsLocMonitorPluginResolver::~CLbsLocMonitorPluginResolver() + { + LBSLOG(ELogP1,"CLbsLocMonitorPluginResolver::~CLbsLocMonitorPluginResolver()"); + // Cancel outstanding notify request. + Cancel(); + iEcomSession->Close(); + REComSession::FinalClose(); + } + +//---------------------------------------------------------------------------- +// CLbsLocMonitorPluginResolver::DefaultConverterUid +// +//----------------------------------------------------------------------------- +TInt CLbsLocMonitorPluginResolver::DefaultConverterUid(TUid& aConverterPluginUid) + { + LBSLOG(ELogP1,"CLbsLocMonitorPluginResolver::DefaultConverterUid()"); + if(iDefaultConverterPluginId == KNullUid) + { + return KErrNotFound; + } + aConverterPluginUid = iDefaultConverterPluginId; + return KErrNone; + } + +//---------------------------------------------------------------------------- +// CLbsLocMonitorPluginResolver::FindDefaultConverterPluginL +// +//----------------------------------------------------------------------------- +void CLbsLocMonitorPluginResolver::FindDefaultConverterPluginL() + { + LBSLOG(ELogP1,"CLbsLocMonitorPluginResolver::FindDefaultConverterPluginL()"); + RImplInfoPtrArray implementationArray; + CleanupClosePushL(implementationArray); + + iEcomSession->ListImplementationsL(TUid::Uid(KLbsLocInfoConverterPlugInInterfaceId), + implementationArray); + + TInt count = implementationArray.Count(); + // Leave if there are no plugin available. + if(!count) + { + CleanupStack::Pop(&implementationArray); + implementationArray.ResetAndDestroy(); + // Reset the default id. + iDefaultConverterPluginId = KNullUid; + return; + } + + // Initialise both phoneVendorImpl and otherVendorImpl to NULL. + CImplementationInformation* phoneVendorImpl = NULL; + CImplementationInformation* otherVendorImpl = NULL; + + // Get the phone's vendor id from the cenrep. + CRepository* repository = NULL; + TVendorId phoneVendorId(0); + + TRAPD(error,repository = CRepository::NewL(KCRUidLocMonitorSettings)); + if(error == KErrNone) + { + TInt vendorId; + error = repository->Get(EPhoneVendorId,vendorId); + if(error == KErrNone) + { + phoneVendorId.iId = vendorId; + } + delete repository; + } + + if(error == KErrNone) + { + // The default plugin to be used is the highest priority plugin provided by the + // phone vendor if any else the highest priority plugin from other vendor. + for(TInt i=0;iVendorId()) + { + if(!phoneVendorImpl) + { + phoneVendorImpl = implementationArray[i]; + } + else + { + TInt currentHighestPriority,currentImplPriority; + currentHighestPriority = PriorityInfo(phoneVendorImpl->OpaqueData()); + currentImplPriority = PriorityInfo(implementationArray[i]->OpaqueData()); + + // Store the handle to current implementation if its priority + // is higher than currently stored implementation. + if(currentImplPriority > currentHighestPriority) + { + phoneVendorImpl = implementationArray[i]; + } + } + } + else + { + // Other vendor implementation is required only if current vendor implementation + // is not available. Hence the search for the high priority other vendor implementation + // should continue till the phone vendor plug in is found. + if(!phoneVendorImpl) + { + if(!otherVendorImpl) + { + otherVendorImpl = implementationArray[i]; + } + else + { + TInt currentHighestPriority,currentImplPriority; + currentHighestPriority = PriorityInfo(otherVendorImpl->OpaqueData()); + currentImplPriority = PriorityInfo(implementationArray[i]->OpaqueData()); + + // Store the handle to current implementation if its priority + // is higher than currently stored implementation. + if(currentImplPriority > currentHighestPriority) + { + otherVendorImpl = implementationArray[i]; + } + } + } + } + } + } + else + { + for(TInt i=0;iOpaqueData()); + currentImplPriority = PriorityInfo(implementationArray[i]->OpaqueData()); + + // Store the handle to current implementation if its priority + // is higher than currently stored implementation. + if(currentImplPriority > currentHighestPriority) + { + otherVendorImpl = implementationArray[i]; + } + } + + } + } + + if(phoneVendorImpl) + { + iDefaultConverterPluginId = phoneVendorImpl->ImplementationUid(); + } + else if(otherVendorImpl) + { + iDefaultConverterPluginId = otherVendorImpl->ImplementationUid(); + } + + CleanupStack::Pop(&implementationArray); + implementationArray.ResetAndDestroy(); + } + + +//---------------------------------------------------------------------------- +// CLbsLocMonitorPluginResolver::RunL +// +//----------------------------------------------------------------------------- +void CLbsLocMonitorPluginResolver::RunL() + { + LBSLOG(ELogP1,"CLbsLocMonitorPluginResolver::RunL()"); + if(KErrNone == iStatus.Int()) + { + FindDefaultConverterPluginL(); + } + // Register for ecom data change. + iEcomSession->NotifyOnChange(iStatus); + SetActive(); + } + + +//---------------------------------------------------------------------------- +// CLbsLocMonitorPluginResolver::DoCancel +// +//----------------------------------------------------------------------------- +void CLbsLocMonitorPluginResolver::DoCancel() + { + LBSLOG(ELogP1,"CLbsLocMonitorPluginResolver::DoCancel()"); + iEcomSession->CancelNotifyOnChange(iStatus); + } + +//---------------------------------------------------------------------------- +// CLbsLocMonitorPluginResolver::PriorityInfo +// +//----------------------------------------------------------------------------- +TInt CLbsLocMonitorPluginResolver::PriorityInfo(const TDesC8& aOpaqueData) + { + LBSLOG(ELogP1,"CLbsLocMonitorPluginResolver::PriorityInfo()"); + TInt opaqueDataLength = aOpaqueData.Length(); + if(!opaqueDataLength) + { + return KLeastPluginPriority; + } + + TLex8 lex(aOpaqueData); + + TInt iterator = 0; + // Iterate through the descriptor till we get colon. + while(lex.Get() != ':') + { + iterator++; + if(iterator == opaqueDataLength) + { + return KLeastPluginPriority; + } + } + // Neglect space if any + while(lex.Peek() == ' ') + { + lex.Inc(); + if(iterator == opaqueDataLength) + { + return KLeastPluginPriority; + } + } + + TInt priority; + lex.Val(priority); + return priority; + } + +//End of file diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorserver/src/clbslocmonitorposlistener.cpp --- a/locationmgmt/locmonitor/lbslocmonitorserver/src/clbslocmonitorposlistener.cpp Thu Jun 24 11:27:31 2010 +0100 +++ b/locationmgmt/locmonitor/lbslocmonitorserver/src/clbslocmonitorposlistener.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -46,9 +46,9 @@ delete iGpsBus; } -void CLbsLocMonitorPosListener::GpsPositionAvailable(const TPosition& aPosition) +void CLbsLocMonitorPosListener::GpsPositionAvailableL(const TPosition& aPosition) { - LBSLOG(ELogP1,"->CLbsLocMonitorPosListener::GpsPositionAvailable"); + LBSLOG(ELogP1,"->CLbsLocMonitorPosListener::GpsPositionAvailableL"); if (Math::IsNaN(aPosition.Latitude()) || Math::IsNaN(aPosition.Longitude())) { @@ -59,7 +59,7 @@ if ((aPosition.Latitude() != iLastGpsPosition.Latitude()) || (aPosition.Longitude() != iLastGpsPosition.Longitude())) { - iObserver.PositionAvailable(aPosition); + iObserver.PositionAvailableL(aPosition); iLastGpsPosition = aPosition; } } diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorserver/src/clbslocmonitorrequesthandler.cpp --- a/locationmgmt/locmonitor/lbslocmonitorserver/src/clbslocmonitorrequesthandler.cpp Thu Jun 24 11:27:31 2010 +0100 +++ b/locationmgmt/locmonitor/lbslocmonitorserver/src/clbslocmonitorrequesthandler.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -52,9 +52,7 @@ // Allocate space for 1 pointer to area info source object (Global Cell Id) iCurrentAreaInfo.ReserveL(ELastAreaInfoType); TLbsLocMonitorAreaInfoGci* locMonitorAreaInfoGci = new(ELeave) TLbsLocMonitorAreaInfoGci; - CleanupStack::PushL(locMonitorAreaInfoGci); iCurrentAreaInfo.Insert(static_cast(locMonitorAreaInfoGci), EGlobalCellIdType); - CleanupStack::Pop(locMonitorAreaInfoGci); iDb.OpenL(); } @@ -128,12 +126,12 @@ as a consequence of a new position being observed on an internal position bus. */ -void CLbsLocMonitorRequestHandler::PositionAvailable(const TPosition& aPosition) +void CLbsLocMonitorRequestHandler::PositionAvailableL(const TPosition& aPosition) { - LBSLOG(ELogP1,"->CLbsLocMonitorRequestHandler::PositionAvailable"); + LBSLOG(ELogP1,"->CLbsLocMonitorRequestHandler::PositionAvailableL"); if(iPositionsQueue.Count() < KLbsLocMonitorMaxWriteArraySize) { - iPositionsQueue.Append(aPosition); + iPositionsQueue.AppendL(aPosition); } else { diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorserver/src/clbslocmonitorserver.cpp --- a/locationmgmt/locmonitor/lbslocmonitorserver/src/clbslocmonitorserver.cpp Thu Jun 24 11:27:31 2010 +0100 +++ b/locationmgmt/locmonitor/lbslocmonitorserver/src/clbslocmonitorserver.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -24,13 +24,6 @@ // -------------------- Server's security policy ------------------------------- // ------------------------------------------------------------------------------- -// SID of the EPOS Location Server (needed for security check) -#ifdef UNIT_TEST_LOCMONITOR -const TInt KLocationServerSID=0x102869E3; -#else -const TInt KLocationServerSID=0x101f97b2; -#endif -const TInt KNetworkGatewaySID=0x10281D46; const TInt KShutDownDelay = 10000000; // 10 seconds @@ -72,40 +65,20 @@ //Package all the above together into a policy const CPolicyServer::TPolicy locMonitorServerPolicy = { - CPolicyServer::ECustomCheck, // onConnect...only certain processes are allowed to connect + CPolicyServer::ECustomCheck, locMonitorServerPolicyRangeCount, // number of ranges locMonitorServerPolicyRanges, // ranges array locMonitorServerPolicyElementsIndex, // elements<->ranges index locMonitorServerPolicyElements, // array of elements }; -/** - * From CPolicyServer - * This method checks the SID of the message sender. - * The check of SID has been done this way (instead of using a TPolicyElement) - * to allow more SIDs (e.g, from NRH, NG, etc) to be checked - * in the future. - * The check fails if the message hasn't been sent from a client with an authorized SID. - * Default action (FailClient) will take place if the check fails. - */ -CPolicyServer::TCustomResult CLbsLocMonitorServer::CustomSecurityCheckL(const RMessage2& aMsg, TInt& /*aAction*/,TSecurityInfo& /*aMissing*/) + +CPolicyServer::TCustomResult CLbsLocMonitorServer::CustomSecurityCheckL(const RMessage2& /*aMsg*/, TInt& /*aAction*/,TSecurityInfo& /*aMissing*/) { LBSLOG(ELogP1,"CLbsLocMonitorServer::CustomSecurityCheckL"); CPolicyServer::TCustomResult result = CPolicyServer::EPass; - // Check if the message source is one on the allowed processes - static _LIT_SECURITY_POLICY_S0(allowEposLocServerPolicy, KLocationServerSID); - TBool isEposLocServer = allowEposLocServerPolicy().CheckPolicy(aMsg); - - static _LIT_SECURITY_POLICY_S0(allowNetworkGatewayPolicy, KNetworkGatewaySID); - TBool isNetworkGateway = allowNetworkGatewayPolicy().CheckPolicy(aMsg); - - // Fail the check if none of the allowed processes has sent the message - if (!isEposLocServer && !isNetworkGateway) - { - result = CPolicyServer::EFail; - } return result; } @@ -185,6 +158,9 @@ // Initiate monitoring of network information static_cast(iAreaInfoFinders[ENetworkInfoFinder])->StartGettingNetworkInfoL(); + + // Initiate plugin resolver. + iPluginResolver = CLbsLocMonitorPluginResolver::NewL(); } CLbsLocMonitorServer::~CLbsLocMonitorServer() @@ -202,6 +178,8 @@ delete iPosListener; iAreaInfoFinders.ResetAndDestroy(); delete iCloseDownRequestDetector; + iConversionHandlerArray.ResetAndDestroy(); + delete iPluginResolver; } CSession2* CLbsLocMonitorServer::DoNewSessionL(const TVersion& /*aVersion*/, const RMessage2& /*aMessage*/) const @@ -222,6 +200,56 @@ return (*iRequestHandler); } +CLbsLocMonitorConversionHandler* CLbsLocMonitorServer::ConversionHandlerL( + TUid aConversionPluginId ) + { + LBSLOG(ELogP1,"CLbsLocMonitorServer::ConversionHandlerL()"); + + // Iterate through the conversion handler array and check whether + // there is already a handler that has loaded user specified + // plugin + for( TInt i=0;iConversionPluginUid() == + aConversionPluginId ) + { + return iConversionHandlerArray[i]; + } + } + + CLbsLocMonitorServer* monitorServer = const_cast + ( this ); + CLbsLocMonitorConversionHandler* conversionHandler = + CLbsLocMonitorConversionHandler::NewL( *monitorServer, + aConversionPluginId ); + + iConversionHandlerArray.AppendL( conversionHandler ); + return conversionHandler; + } + +CLbsLocMonitorConversionHandler* CLbsLocMonitorServer::ConversionHandler( + const RMessage2& aMessage ) + { + LBSLOG(ELogP1,"CLbsLocMonitorServer::ConversionHandler()"); + + // Iterate through the conversion handler array and check whether + // there is already a handler that has loaded user specified + // plugin + for( TInt i=0;iIsMessagePresent( aMessage ) ) + { + return iConversionHandlerArray[i]; + } + } + return NULL; + } + +CLbsLocMonitorPluginResolver* CLbsLocMonitorServer::PluginResolver() + { + LBSLOG(ELogP1,"CLbsLocMonitorServer::PluginResolver()"); + return iPluginResolver; + } /* Intended for use by subsessions Called to register as an observer @@ -255,7 +283,23 @@ LBSLOG(ELogP1,"CLbsLocMonitorServer::OnProcessCloseDown()"); CActiveScheduler::Stop(); } - + +/** + * This method is called by CLbsLocMonitorConversionHandler after it completes + * all the requests + */ +void CLbsLocMonitorServer::HandleConversionComplete( CLbsLocMonitorConversionHandler* + aConversionHandler ) + { + LBSLOG(ELogP1,"CLbsLocMonitorServer::HandleConversionComplete()"); + // Remove the conversion handler object from the array and delete it. + TInt index = iConversionHandlerArray.Find( aConversionHandler ); + if( index != KErrNotFound ) + { + iConversionHandlerArray.Remove(index); + } + delete aConversionHandler; + } TBool CLbsLocMonitorServer::FindRootProcess() { diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/lbslocmonitorserver/src/clbslocmonitorsession.cpp --- a/locationmgmt/locmonitor/lbslocmonitorserver/src/clbslocmonitorsession.cpp Thu Jun 24 11:27:31 2010 +0100 +++ b/locationmgmt/locmonitor/lbslocmonitorserver/src/clbslocmonitorsession.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -20,6 +20,7 @@ #include "lbsdevloggermacros.h" #include "lbslocmonitorserverdata.h" #include "clbsareapositionersubsession.h" +#include "clbsconversionpositionersubsession.h" // Called by the CServer2 code to complete construction of the session void CLbsLocMonitorSession::CreateL() @@ -90,11 +91,21 @@ subSession = CLbsAreaPositionerSubsession::NewL(); break; } + case ELocMonitorSubSessionTypeConversionPositiner: + { + subSession = CLbsConversionPositionerSubsession::NewL(); + break; + } case ELocMonitorSubSessionTypeUnknown: + { + _LIT(KPanicUnknownSubSession, "Unknown SubSession Type"); + __ASSERT_DEBUG(0, MessageUtils::PanicClient(aMessage, KPanicUnknownSubSession, 0)); + break; + } default: { - _LIT(KPanicLocMonitorServer, "Unknown SubSession Type"); - MessageUtils::PanicClient(aMessage, KPanicLocMonitorServer, 0); + _LIT(KPanicSubSessionType, "Unrecognised SubSession Type"); + __ASSERT_DEBUG(0, MessageUtils::PanicClient(aMessage, KPanicSubSessionType, 0)); break; } } diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/ExampleLocationConverter/.cproject --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/ExampleLocationConverter/.cproject Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,671 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/ExampleLocationConverter/.project --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/ExampleLocationConverter/.project Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,19 @@ + + + ExampleLocationConverter + + + + + + com.nokia.carbide.cdt.builder.carbideCPPBuilder + + + + + + org.eclipse.cdt.core.cnature + org.eclipse.cdt.core.ccnature + com.nokia.carbide.cdt.builder.carbideCPPBuilderNature + + diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/ExampleLocationConverter/data/10287201.rss --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/ExampleLocationConverter/data/10287201.rss Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,45 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Resource file for movement detector plugin +* +*/ +// mydetector.rss +// +#include + +#include "ExampleLocationConverter.hrh" +#include + +RESOURCE REGISTRY_INFO theInfo +{ +dll_uid = KExampleLocationConverterUid; +interfaces = + { + INTERFACE_INFO + { + interface_uid = KLbsLocInfoConverterPlugInInterfaceId; + implementations = + { + IMPLEMENTATION_INFO + { + implementation_uid = KExampleLocationConverterImplementationUid; + version_no = 1; + display_name = "Example location info converter"; + default_data = "text/ascii"; + opaque_data = "priority:5"; + } + }; + } + }; +} diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/ExampleLocationConverter/data/ExampleLocationConverter.hrh --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/ExampleLocationConverter/data/ExampleLocationConverter.hrh Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,26 @@ +/* +* Copyright (c) 2007 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Resource headers for project +* +*/ + + +#ifndef EXAMPLELOCATIONCONVERTER_HRH +#define EXAMPLELOCATIONCONVERTER_HRH + +#define KExampleLocationConverterUid 0x2002140C +#define KExampleLocationConverterImplementationUid 0x2002140D + + +#endif // EXAMPLELOCATIONCONVERTER_HRH diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/ExampleLocationConverter/group/ExampleLocationConverter.mmp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/ExampleLocationConverter/group/ExampleLocationConverter.mmp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,49 @@ +/* +* Copyright (c) 2006-2007 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Project definition file for project Cell Id movement detector +* +*/ + + +#include "../data/ExampleLocationConverter.hrh" + +TARGET ExampleLocationConverter.dll +TARGETTYPE PLUGIN +UID 0x10009D8D KExampleLocationConverterUid +VENDORID 0x2002140e + +CAPABILITY ALL -TCB + +OS_LAYER_SYSTEMINCLUDE + +USERINCLUDE ../inc +USERINCLUDE ../data + +SOURCEPATH ../src +SOURCE ExampleLocationConverter.cpp + +START RESOURCE ../data/10287201.rss +TARGET ExampleLocationConverter.rsc +END + +LIBRARY euser.lib +LIBRARY ecom.lib +LIBRARY flogger.lib +LIBRARY lbslocationinfoconverterplugin.lib +LIBRARY lbslocationinfodatatypes.lib +LIBRARY lbs.lib + +PAGED + +SMPSAFE diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/ExampleLocationConverter/group/bld.inf --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/ExampleLocationConverter/group/bld.inf Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,25 @@ +/* +* Copyright (c) 2006 - 2007 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Build information file for project ?myapp +* +*/ + + +PRJ_PLATFORMS +DEFAULT + +PRJ_TESTMMPFILES +ExampleLocationConverter.mmp + +// END OF FILE diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/ExampleLocationConverter/inc/ExampleLocationConverter.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/ExampleLocationConverter/inc/ExampleLocationConverter.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,122 @@ +/* +* Copyright (c) 2008 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Definition of Movement Detection API +* +*/ + + +#ifndef C_EXAMPLELOCATIONCONVERTER_H +#define C_EXAMPLELOCATIONCONVERTER_H + +#include + +#include +#include +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +/** + * CExampleLocationConverter is an ECom plugin that implements CLbsLocInfoConversionPluginBase. + * + * This class is responsible for monitering movement of mobile based on + * GSM information available to mobile at any instant. + * + * @lib movementdetector.lib + * @since S60 v4.0 + */ +class CExampleLocationConverter : public CLbsLocInfoConverterPluginBase + + { + +public: + + /** + * Loads a location info conveter and initalises it. + * + * @param[in] aObserver An observer for location conversion event. + * @param[in] aPluginArgs Agruements sent to conversion plugin. + * return Pointer to the new loation info converter.If module id is not specified + * default plug in will be loaded. + */ + static CExampleLocationConverter* NewL( TLbsLocInfoConverterPluginParams& aPluginParams ); + + /** + * Unloads this movement detector. + * + * @since S60 TACO + */ + virtual ~CExampleLocationConverter(); + + // From CLbsLocInfoConversionPluginBase + + /** + * Converts the area informations of a group of geographical locations + * to its corresponding position information. + * + * @param[in] aLocationInfoArray Array of location informations corresponding + * to geographical locations are passed and on successful completion of this + * method,position information corresponding to the loation informations are + * updated in each area info object. + * @param[in] aConversionPrefs Conversion preferences suggested by client. + * + * @leave KErrArgument If the location info array is empty. + */ + virtual void ConvertLocationInfoL( + RLbsLocationInfoArray& aLocationInfoArray, + const TLbsConversionPrefs aConversionPrefs, + const TLbsConversionOutputInfoMask aRequestedInfo ); + + /** + * Cancels get location info operation. + */ + virtual void CancelConvertLocationInfo(); + + virtual void ValidateClient( const TSecureId& aSecureId, + const TVendorId& aVendorId, + const TLbsConversionOutputInfoMask aRequestedInfo ); + + virtual void CancelValidateClient(); + + virtual void ConversionPluginPreferences( + TLbsConversionPluginInfo& aPluginInfo ); + +private: + + + void ConstructL(TLbsLocInfoConverterPluginParams& aPluginParams); + + /** + * Default C++ Constructor + */ + CExampleLocationConverter(TLbsLocInfoConverterPluginParams& aParams); + +private: // data + + MLbsLocInfoConverterPluginObserver &iObserver; + TBool iRetainLocalityInCache; + }; + + +#endif // C_LBTCELLIDMVMTDET_H diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/ExampleLocationConverter/src/ExampleLocationConverter.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/ExampleLocationConverter/src/ExampleLocationConverter.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,331 @@ +/* +* Copyright (c) 2008 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Definition of CdummyMvmtDet class. +* +*/ + + + +#include +#include +#include +#include "ExampleLocationConverter.h" + +// the test code sets the timing advance in the GSM vell info to this value +// which instructs the test converter to constuct TLocalitys with +// latitude ser to country code, longitude set to +// network code and altitiude set to local area code +const TInt KTimingAdvanceSpecialValue= 254; + +const TInt KTimingAdvanceSaveToCacheTrue= 253; + +const TInt KTimingAdvanceSaveToCacheFalse= 252; + +// ECOM implementation specifics +static const TImplementationProxy implTable[] = + { + IMPLEMENTATION_PROXY_ENTRY(0x2002140D, CExampleLocationConverter::NewL) + }; + + +EXPORT_C const TImplementationProxy* ImplementationGroupProxy(TInt& aTableCount) + { + aTableCount = sizeof(implTable) / sizeof(TImplementationProxy); + + return implTable; + } + + +// Class methods + +//------------------------------------------------------------ +// CLbsLocInfoConversionPluginBase::NewL +// Symbian Two - phase constructor +//------------------------------------------------------------ +// +CExampleLocationConverter* CExampleLocationConverter::NewL( TLbsLocInfoConverterPluginParams& aParams) + { + CExampleLocationConverter* self = new (ELeave) CExampleLocationConverter(aParams); + CleanupStack::PushL(self); + self->ConstructL(aParams); + CleanupStack::Pop(); + return self; + } + + +//------------------------------------------------------------ +// CLbsLocInfoConversionPluginBase::ConstructL +//------------------------------------------------------------ +// +void CExampleLocationConverter::ConstructL( TLbsLocInfoConverterPluginParams& /*aParams*/ ) + { + CLbsLocInfoConverterPluginBase::Version(); + TInt aFunctionNumber = 1982; + TAny* aPtr1 = &aFunctionNumber; + TAny* aPtr2 = &aFunctionNumber; + CLbsLocInfoConverterPluginBase::ExtendedInterface(aFunctionNumber, aPtr1, aPtr2); + + iObserver.Version(); + } + + +//----------------------------------------------------------------- +// CLbsLocInfoConversionPluginBase::CLbsLocInfoConversionPluginBase +// C++ Default constructor +//------------------------------------------------------------------ +// +CExampleLocationConverter::CExampleLocationConverter(TLbsLocInfoConverterPluginParams& aParams):iObserver(aParams.Observer()), + iRetainLocalityInCache(ETrue) + { + + } + + +//------------------------------------------------------------ +// CLbsLocInfoConversionPluginBase::~CLbsLocInfoConversionPluginBase +// Destructor +//------------------------------------------------------------ +// +CExampleLocationConverter::~CExampleLocationConverter() + { + + } + + +//------------------------------------------------------------ +// CLbsLocInfoConversionPluginBase::ConvertLocationInfoL +//------------------------------------------------------------ +// +void CExampleLocationConverter::ConvertLocationInfoL( RLbsLocationInfoArray& aLocationInfoArray, + const TLbsConversionPrefs /*aConversionPrefs*/, + const TLbsConversionOutputInfoMask aRequestedInfo) + { + if(aRequestedInfo == ELbsConversionOutputNotDefined) + { + iObserver.OnConversionComplete(KErrArgument); + return; + } + TInt count = aLocationInfoArray.Count(); + for(TInt i=0 ; iGetAreaInfoL( areaInfoArray,areaInfoMask ); + TInt count = areaInfoArray.Count(); + + + + if( count == 0 ) + { + iObserver.OnConversionComplete(KErrNotSupported); + return; + } + TLocality locality; + if (areaInfoArray[0]->Type() == ELbsAreaGsmCellInfoClass) + { + CLbsGsmCellInfo* posInfo = + static_cast (areaInfoArray[0]); + + TInt timingAdvance = posInfo->TimingAdvance(); + + if (timingAdvance == KTimingAdvanceSaveToCacheFalse) + { + iRetainLocalityInCache = EFalse; + } + else + { + // for all others values ensiure that we put + // localities in cache + iRetainLocalityInCache = ETrue; + } + + if ((timingAdvance == KTimingAdvanceSpecialValue) + || (timingAdvance + == KTimingAdvanceSaveToCacheTrue) + || (timingAdvance + == KTimingAdvanceSaveToCacheFalse)) + { + // For all the special tests + TReal64 lat = posInfo->MobileCountryCode(); + TReal64 lng = posInfo->MobileNetworkCode(); + TReal32 alt = posInfo->LocationAreaCode(); + + TReal32 horAcc = posInfo->CellId(); + + locality.SetCoordinate(lat, lng, alt); + locality.SetAccuracy(horAcc, 11.0); + } + else + { + // and for the original tests + locality.SetCoordinate(62.5285, 23.9385, 1.22f); + locality.SetAccuracy(10.0f, 0.0); + + } + } + else + { + // and for the original tests + locality.SetCoordinate(62.5285, 23.9385, 1.22f); + locality.SetAccuracy(10.0f, 0.0); + } + areaInfoArray.ResetAndDestroy(); + + CLbsPositionInfo* positionInfo = CLbsPositionInfo::NewL( locality ); + CleanupStack::PushL( positionInfo ); + aLocationInfoArray[i]->AddAreaInfoL( positionInfo ); + CleanupStack::Pop( positionInfo ); + break; + } + case ELbsConversionOutputGsm: + { + // Extract the area info provided by the client. + // If client has specified only gsm info, + // return KErrNotSupported. + RLbsAreaInfoBaseArray areaInfoArray; + CLbsLocationInfo::TAreaInfoMask areaInfoMask = 0; + areaInfoMask |= CLbsLocationInfo::ELbsPosInfo | + CLbsLocationInfo::ELbsWcdmaInfo | + CLbsLocationInfo::ELbsWlanInfo; + aLocationInfoArray[i]->GetAreaInfoL( areaInfoArray,areaInfoMask ); + TInt count = areaInfoArray.Count(); + areaInfoArray.ResetAndDestroy(); + + if( count == 0 ) + { + iObserver.OnConversionComplete(KErrNotSupported); + return; + } + + CLbsGsmCellInfo* gsmCellInfo = CLbsGsmCellInfo::NewL( 100,101,102,103); + CleanupStack::PushL( gsmCellInfo ); + aLocationInfoArray[i]->AddAreaInfoL( gsmCellInfo ); + CleanupStack::Pop( gsmCellInfo ); + break; + } + case ELbsConversionOutputWcdma: + { + // Extract the area info provided by the client. + // If client has specified only wcdma info, + // return KErrNotSupported. + RLbsAreaInfoBaseArray areaInfoArray; + CLbsLocationInfo::TAreaInfoMask areaInfoMask = 0; + areaInfoMask |= CLbsLocationInfo::ELbsPosInfo | + CLbsLocationInfo::ELbsGsmInfo | + CLbsLocationInfo::ELbsWlanInfo; + aLocationInfoArray[i]->GetAreaInfoL( areaInfoArray,areaInfoMask ); + TInt count = areaInfoArray.Count(); + areaInfoArray.ResetAndDestroy(); + + if( count == 0 ) + { + iObserver.OnConversionComplete(KErrNotSupported); + return; + } + + CLbsWcdmaCellInfo* wcdmaCellInfo = CLbsWcdmaCellInfo::NewL( 100,101,102 ); + CleanupStack::PushL( wcdmaCellInfo ); + aLocationInfoArray[i]->AddAreaInfoL( wcdmaCellInfo ); + CleanupStack::Pop( wcdmaCellInfo ); + break; + } + case ELbsConversionOutputWlan: + { + // Extract the area info provided by the client. + // If client has specified only wlan info, + // return KErrNotSupported. + RLbsAreaInfoBaseArray areaInfoArray; + CLbsLocationInfo::TAreaInfoMask areaInfoMask = 0; + areaInfoMask |= CLbsLocationInfo::ELbsPosInfo | + CLbsLocationInfo::ELbsGsmInfo | + CLbsLocationInfo::ELbsWcdmaInfo; + aLocationInfoArray[i]->GetAreaInfoL( areaInfoArray,areaInfoMask ); + TInt count = areaInfoArray.Count(); + areaInfoArray.ResetAndDestroy(); + + if( count == 0 ) + { + iObserver.OnConversionComplete(KErrNotSupported); + return; + } + + TLbsWlanMacAddress macAddress(_L8("10.0.1")); + CLbsWlanInfo* WlanInfo = CLbsWlanInfo::NewL( macAddress,10.1); + CleanupStack::PushL( WlanInfo ); + aLocationInfoArray[i]->AddAreaInfoL( WlanInfo ); + CleanupStack::Pop( WlanInfo ); + } + default: + break; + } + + } + iObserver.OnConversionComplete(KErrNone); + } + +//------------------------------------------------------------ +// CLbsLocInfoConversionPluginBase::ConvertLocationInfoL +//------------------------------------------------------------ +// +void CExampleLocationConverter::CancelConvertLocationInfo( ) + { + + } + +//------------------------------------------------------------ +// CLbsLocInfoConversionPluginBase::ValidateClient +//------------------------------------------------------------ +// +void CExampleLocationConverter::ValidateClient( const TSecureId& /*aSecureId*/, + const TVendorId& /*aVendorId*/, + const TLbsConversionOutputInfoMask /*aRequestedInfo*/ ) + { + iObserver.OnValidationComplete( KErrNone ); + } + +//------------------------------------------------------------ +// CLbsLocInfoConversionPluginBase::ValidateClient +//------------------------------------------------------------ +// +void CExampleLocationConverter::CancelValidateClient() + { + + } + +//------------------------------------------------------------ +// CExampleLocationConverter::ConversionPluginPreferences +//------------------------------------------------------------ +// +void CExampleLocationConverter::ConversionPluginPreferences( + TLbsConversionPluginInfo& aPluginInfo ) + { + aPluginInfo.SetIsPluginPositionToBeCached(iRetainLocalityInCache); + + //Note: The capability mask is currently not used anywhere in the location + //monitor. + TLbsConversionPluginCapabilityMask capabilityMask; + capabilityMask = aPluginInfo.PluginCapabilitiesMask(); + capabilityMask = ( ELbsPluginCapabilityGsmInfo|ELbsPluginCapabilityPosInfo|ELbsPluginCapabilityWlanInfo); + aPluginInfo.SetPluginCapabilitiesMask(capabilityMask); + } diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/LocInfoConversionUnitTest/Bmarm/LocInfoConversionUnitTestU.DEF --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/LocInfoConversionUnitTest/Bmarm/LocInfoConversionUnitTestU.DEF Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,3 @@ +EXPORTS + LibEntryL__FR13CTestModuleIf @ 1 NONAME R3UNUSED ; LibEntryL(CTestModuleIf &) + diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/LocInfoConversionUnitTest/Bwins/LocInfoConversionUnitTestU.DEF --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/LocInfoConversionUnitTest/Bwins/LocInfoConversionUnitTestU.DEF Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,3 @@ +EXPORTS + ?LibEntryL@@YAPAVCScriptBase@@AAVCTestModuleIf@@@Z @ 1 NONAME ; class CScriptBase * __cdecl LibEntryL(class CTestModuleIf &) + diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/LocInfoConversionUnitTest/EABI/LocInfoConversionUnitTestU.def --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/LocInfoConversionUnitTest/EABI/LocInfoConversionUnitTestU.def Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,3 @@ +EXPORTS + _Z9LibEntryLR13CTestModuleIf @ 1 NONAME + diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/LocInfoConversionUnitTest/conf/LocInfoConversionUnitTest.cfg --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/LocInfoConversionUnitTest/conf/LocInfoConversionUnitTest.cfg Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,113 @@ +[Test] +title UnitTest1 +create LocInfoConversionUnitTest foobar +foobar UnitTest1 +delete foobar +[Endtest] + +[Test] +title UnitTest2 +create LocInfoConversionUnitTest foobar +foobar UnitTest2 +delete foobar +[Endtest] + +[Test] +title UnitTest3 +create LocInfoConversionUnitTest foobar +foobar UnitTest3 +delete foobar +[Endtest] + +[Test] +title UnitTest4 +create LocInfoConversionUnitTest foobar +foobar UnitTest4 +delete foobar +[Endtest] + +[Test] +title UnitTest5 +create LocInfoConversionUnitTest foobar +foobar UnitTest5 +delete foobar +[Endtest] + +[Test] +title UnitTest6 +create LocInfoConversionUnitTest foobar +foobar UnitTest6 +delete foobar +[Endtest] + +[Test] +title UnitTest7 +create LocInfoConversionUnitTest foobar +foobar UnitTest7 +delete foobar +[Endtest] + + +[Test] +title UnitTest8 +create LocInfoConversionUnitTest foobar +foobar UnitTest8 +delete foobar +[Endtest] + +[Test] +title UnitTest9 +create LocInfoConversionUnitTest foobar +foobar UnitTest9 +delete foobar +[Endtest] + +[Test] +title UnitTest10 +create LocInfoConversionUnitTest foobar +foobar UnitTest10 +delete foobar +[Endtest] + +[Test] +title UnitTest11 +create LocInfoConversionUnitTest foobar +foobar UnitTest11 +delete foobar +[Endtest] + +[Test] +title UnitTest12 +create LocInfoConversionUnitTest foobar +foobar UnitTest12 +delete foobar +[Endtest] + +[Test] +title UnitTest13 +create LocInfoConversionUnitTest foobar +foobar UnitTest13 +delete foobar +[Endtest] + +[Test] +title UnitTest14 +create LocInfoConversionUnitTest foobar +foobar UnitTest14 +delete foobar +[Endtest] + +[Test] +title UnitTest15 +create LocInfoConversionUnitTest foobar +foobar UnitTest15 +delete foobar +[Endtest] + +[Test] +title UnitTest16 +create LocInfoConversionUnitTest foobar +foobar UnitTest16 +delete foobar +[Endtest] + diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/LocInfoConversionUnitTest/group/LocInfoConversionUnitTest.mmp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/LocInfoConversionUnitTest/group/LocInfoConversionUnitTest.mmp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,90 @@ +/*TYPE TESTCLASS*/ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: MMP file for STIF Test Framework's TestScripter +* testclass test module. +* +*/ + +#include + +TARGET LocInfoConversionUnitTest.dll +TARGETTYPE dll +UID 0x1000008D 0x101FB3E3 + +CAPABILITY ALL -TCB +/* Remove comments and replace 0x00000000 with correct vendor id */ +// VENDORID 0x00000000 +/* Remove comments and replace 0x00000000 with correct secure id */ +// SECUREID 0x00000000 + +//TARGETPATH ?target_path +DEFFILE LocInfoConversionUnitTest.def + +USERINCLUDE ../inc +USERINCLUDE ../../../lbslocmonitorapis/CommonClientServerApi/inc +USERINCLUDE ../../../lbslocmonitorserver/inc +USERINCLUDE ../../../../locationcore/lbsrootapi/inc +USERINCLUDE ../../../../locationcore/LbsInternalApi/inc +USERINCLUDE ../../../../locationcore/LbsNetInternalApi/inc +USERINCLUDE ../../../../locationcore/LbsLocDataSource/inc +USERINCLUDE ../../../../locationcore/LbsPartnerCommon/inc +USERINCLUDE ../../../../locationcore/LbsLocCommon/ServerFramework/inc +USERINCLUDE ../../../../locationcore/LbsDebug/inc +USERINCLUDE ../../../../locationcore/LbsLogging/inc + + +OS_LAYER_SYSTEMINCLUDE + +SOURCEPATH ../src +SOURCE LocInfoConversionUnitTest.cpp +SOURCE LocInfoConversionUnitTestBlocks.cpp +SOURCE LocInfoConversionHandler.cpp + +//RESOURCE resource_file +//RESOURCE resource_file2 + +LIBRARY euser.lib +LIBRARY stiftestinterface.lib +LIBRARY stiftestengine.lib +LIBRARY lbslocationinfodatatypes.lib +LIBRARY lbslocmonclient.lib +LIBRARY lbs.lib +LANG SC + +/* +START WINS +?wins_specific_information +END + +START MARM +?marm_specific_information +END +*/ +// Other possible keywords: + +// DOCUMENT ?file, that is not compiled, but added to MSVC project workspace (i.e. release notes) +/* +START BITMAP ?target +TARGETPATH ?emulated_path_on_target_machine +HEADER +SOURCE ?color_depth ?source_bitmap +END +*/ +// DEFFILE ?filename +// AIF ?filename + +SMPSAFE + +// End of File diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/LocInfoConversionUnitTest/group/LocInfoConversionUnitTest.pkg --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/LocInfoConversionUnitTest/group/LocInfoConversionUnitTest.pkg Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,60 @@ +; +; Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +; All rights reserved. +; This component and the accompanying materials are made available +; under the terms of "Eclipse Public License v1.0" +; which accompanies this distribution, and is available +; at the URL "http://www.eclipse.org/legal/epl-v10.html". +; +; Initial Contributors: +; Nokia Corporation - initial contribution. +; +; Contributors: +; +; Description: +; +; Installation file for STIF +; + +; Languages +&EN + +; Provide value for uid +#{"STIF"},(0x00000000),1,1,0,TYPE=SA + +; Series60 product id for S60 3.0 +[0x101F7961], 0, 0, 0, {"Series60ProductID"} + +; Localised Vendor name +%{"Nokia"} + +; Unique Vendor name +:"Nokia" + +; Logo +; None + +; Package signature - Optional +; None + +; Start of Package body + +; Condition blocks +; None + +; Options list +; None + +; Install files +"\epoc32\release\armv5\udeb\LocInfoConversionUnitTest.dll" - "!:\Sys\Bin\LocInfoConversionUnitTest.dll" + +; Embedded SIS +; None + +; End of Package body + +; PKG dependencies +; None + +; PKG capabilities +; None diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/LocInfoConversionUnitTest/group/bld.inf --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/LocInfoConversionUnitTest/group/bld.inf Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,60 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ + +PRJ_PLATFORMS +// specify the platforms your component needs to be built for here +// defaults to WINS MARM so you can ignore this if you just build these + + DEFAULT + +PRJ_TESTEXPORTS +// NOTE: If using ARS requirements all export operations should be done under this. +// 'abld test export' + +PRJ_EXPORTS +// Specify the source file followed by its destination here +// copy will be used to copy the source file to its destination +// If there's no destination then the source file will be copied +// to the same name in \epoc32\include +// Example: +/* +\agnmodel\inc\AGMCOMON.H +*/ + +//PRJ_TESTMMPFILES + +// LocInfoConversionUnitTest.mmp + +PRJ_MMPFILES +LocInfoConversionUnitTest.mmp +// LocInfoConversionUnitTest_nrm.mmp + +// Specify the .mmp files required for building the important component +// releasables. +// +// Specify "tidy" if the component you need to build doesn't need to be +// released. Specify "ignore" if the MMP file exists but should be +// ignored. +// Example: +/* +\agnmodel\group\agnmodel.mmp +#if defined(MARM) +\agnmodel\group\agsvexe.mmp +#endif +*/ + +// End of File diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/LocInfoConversionUnitTest/inc/LocInfoConversionHandler.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/LocInfoConversionUnitTest/inc/LocInfoConversionHandler.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,41 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: STIF testclass declaration +* +*/ + +#ifndef LOCINFOCONVERSIONHANDLER_H_ +#define LOCINFOCONVERSIONHANDLER_H_ + +#include + +class CLocInfoConversionHanlder : public CActive + { +public: + static CLocInfoConversionHanlder* NewL(); + + ~CLocInfoConversionHanlder(); + + void Start(); +protected: // from CActive + void RunL(); + void DoCancel(); + +private: + CLocInfoConversionHanlder(); + + void ConstructL(); + }; + +#endif /*LOCINFOCONVERSIONHANDLER_H_*/ diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/LocInfoConversionUnitTest/inc/LocInfoConversionUnitTest.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/LocInfoConversionUnitTest/inc/LocInfoConversionUnitTest.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,234 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: STIF testclass declaration +* +*/ + +#ifndef LOCINFOCONVERSIONUNITTEST_H +#define LOCINFOCONVERSIONUNITTEST_H + +// INCLUDES +#include +#include +#include +#include +#include +#include "LocInfoConversionHandler.h" +#include + +// CONSTANTS +//const ?type ?constant_var = ?constant; + +// MACROS +//#define ?macro ?macro_def +#define TEST_CLASS_VERSION_MAJOR 0 +#define TEST_CLASS_VERSION_MINOR 0 +#define TEST_CLASS_VERSION_BUILD 0 + +// Logging path +_LIT( KLocInfoConversionUnitTestLogPath, "\\logs\\testframework\\LocInfoConversionUnitTest\\" ); +// Log file +_LIT( KLocInfoConversionUnitTestLogFile, "LocInfoConversionUnitTest.txt" ); +_LIT( KLocInfoConversionUnitTestLogFileWithTitle, "LocInfoConversionUnitTest_[%S].txt" ); + +// FUNCTION PROTOTYPES +//?type ?function_name(?arg_list); + +// FORWARD DECLARATIONS +//class ?FORWARD_CLASSNAME; +class CLocInfoConversionUnitTest; +class CLbsPositionInfo; +class CLbsGsmCellInfo; +class CLbsWcdmaCellInfo; +class CLbsWlanInfo; +class CLbsLocationInfo; + +enum TTestType + { + EPositive, + + ENegative + }; + +// DATA TYPES +//enum ?declaration +//typedef ?declaration +//extern ?data_type; + +// CLASS DECLARATION + +/** +* CLocInfoConversionUnitTest test class for STIF Test Framework TestScripter. +* ?other_description_lines +* +* @lib ?library +* @since ?Series60_version +*/ +NONSHARABLE_CLASS(CLocInfoConversionUnitTest) : public CScriptBase + { + public: // Constructors and destructor + + /** + * Two-phased constructor. + */ + static CLocInfoConversionUnitTest* NewL( CTestModuleIf& aTestModuleIf ); + + /** + * Destructor. + */ + virtual ~CLocInfoConversionUnitTest(); + + public: // New functions + + /** + * ?member_description. + * @since ?Series60_version + * @param ?arg1 ?description + * @return ?description + */ + //?type ?member_function( ?type ?arg1 ); + + public: // Functions from base classes + + /** + * From CScriptBase Runs a script line. + * @since ?Series60_version + * @param aItem Script line containing method name and parameters + * @return Symbian OS error code + */ + virtual TInt RunMethodL( CStifItemParser& aItem ); + + protected: // New functions + + /** + * ?member_description. + * @since ?Series60_version + * @param ?arg1 ?description + * @return ?description + */ + //?type ?member_function( ?type ?arg1 ); + + protected: // Functions from base classes + + /** + * From ?base_class ?member_description + */ + //?type ?member_function(); + + private: + + /** + * C++ default constructor. + */ + CLocInfoConversionUnitTest( CTestModuleIf& aTestModuleIf ); + + /** + * By default Symbian 2nd phase constructor is private. + */ + void ConstructL(); + + // Prohibit copy constructor if not deriving from CBase. + // ?classname( const ?classname& ); + // Prohibit assigment operator if not deriving from CBase. + // ?classname& operator=( const ?classname& ); + + /** + * Frees all resources allocated from test methods. + * @since ?Series60_version + */ + void Delete(); + + /** + * Test methods are listed below. + */ + + /** + * Example test method. + * @since ?Series60_version + * @param aItem Script line containing parameters. + * @return Symbian OS error code. + */ + TInt RLbsLocInfoConverter_Connect1L(CStifItemParser& aItem ); + TInt RLbsLocInfoConverter_Connect2L(CStifItemParser& aItem ); + TInt RLbsLocInfoConverter_ConvertLocationInfo1L(CStifItemParser& aItem ); + TInt RLbsLocInfoConverter_ConvertLocationInfo2L(CStifItemParser& aItem ); + TInt RLbsLocInfoConverter_ConvertLocationInfo3L(CStifItemParser& aItem ); + TInt RLbsLocInfoConverter_ConvertLocationInfo4L(CStifItemParser& aItem ); + TInt RLbsLocInfoConverter_ConvertLocationInfo5L(CStifItemParser& aItem ); + TInt RLbsLocInfoConverter_ConvertLocationInfo6L(CStifItemParser& aItem ); + TInt RLbsLocInfoConverter_ConvertLocationInfo7L(CStifItemParser& aItem ); + TInt RLbsLocInfoConverter_ConvertLocationInfo8L(CStifItemParser& aItem ); + TInt RLbsLocInfoConverter_ConvertLocationInfo9L(CStifItemParser& aItem ); + TInt RLbsLocInfoConverter_ConvertLocationInfo10L(CStifItemParser& aItem ); + TInt RLbsLocInfoConverter_Cancel1L(CStifItemParser& aItem ); + TInt RLbsLocInfoConverter_Cancel2L(CStifItemParser& aItem ); + TInt RLbsLocInfoConverter_Cancel3L(CStifItemParser& aItem ); + TInt RLbsLocInfoConverter_Cancel4L(CStifItemParser& aItem ); + + /** + * Method used to log version of test class + */ + void SendTestClassVersion(); + + /** + * Helper methods. + */ + CLbsPositionInfo* CreatePositionInfoObjectLC(); + + CLbsGsmCellInfo* CreateGsmCellInfoObjectLC(); + + CLbsWcdmaCellInfo* CreateWcdmaCellInfoObjectLC(); + + CLbsWlanInfo* CreateWlanInfoObjectLC(); + + CLbsLocationInfo* CreateLocationInfoObjectLC( TLbsAreaInfoClassType aAreaType ); + + void AppendAreaInfoObjectToLocationInfoL( CLbsLocationInfo* aLocationInfo, + TLbsAreaInfoClassType aAreaType ); + + void CheckPositionConvertedInfoL( CLbsLocationInfo* aLocationInfo, + TTestType aTestType = EPositive ); + + void CheckGsmCellConvertedInfoL( CLbsLocationInfo* aLocationInfo, + TTestType aTestType = EPositive ); + + void CheckWcdmaCellConvertedInfoL( CLbsLocationInfo* aLocationInfo, + TTestType aTestType = EPositive ); + + void CheckWlanConvertedInfoL( CLbsLocationInfo* aLocationInfo, + TTestType aTestType = EPositive ); + public: // Data + // ?one_line_short_description_of_data + //?data_declaration; + + protected: // Data + // ?one_line_short_description_of_data + //?data_declaration; + + private: // Data + CLocInfoConversionHanlder* iConversionHandler; + + CLocInfoConversionHanlder* iConversionHandler1; + public: // Friend classes + //?friend_class_declaration; + protected: // Friend classes + //?friend_class_declaration; + private: // Friend classes + //?friend_class_declaration; + + }; + +#endif // LOCINFOCONVERSIONUNITTEST_H + +// End of File diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/LocInfoConversionUnitTest/inc/lbtlogger.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/LocInfoConversionUnitTest/inc/lbtlogger.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,374 @@ +/* +* Copyright (c) 2007 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Defines the macros for logging mechanism in LBT +* +*/ + + +#ifndef LBT_LOGGER_H +#define LBT_LOGGER_H + +/** + * To use this logger mechanism you also need to add flogger.lib to the mmp + * using, + * DEBUGLIBRARY flogger.lib + */ + + +/** + * The trace level is defined as follows, + * 0x[moduleid - 4digits][logginglevel-4digits], + * The currently define logginglevels are + * 0x0001 - Verbose + * things like entered method, leaving method etc, + * logs of the parameters to methods, files + * that are being used, creating a key, creating a file, + * opening a resource, + * + * 0x0002 - Warning + * things like events, error cases that were not processed + * but ignored. + * + * 0x0003 - Operations + * things like what operation started (create, delete), + * manipulations to the data structures, important events like + * MMC card , app uninstall events which we process, + * current location, triggers being monitored, psy conked off, + * any other such important event. + * + * 0x0004 - Errors + * log all _ASSERT_DEBUG kind of cases, basically things which + * you don't expect to happen but happened - Sounds like paradox ;-) + * Also log all error cases with this trace level. + * + * 0x0005 - Fatal + * Use this if the server cannot recover from this error and you + * have to crash !! ;-) + * + * So for a create trigger operation in server the log should be like + * LBT_TRACE(KLbtLogOperation|KLbtLogServerLogic,"Creating Trigger"); + */ +#define KLbtLogLevelMask 0x0000FFFF + +#define KLbtLogVerbose 0x00000001 +#define KLbtLogWarning 0x00000002 +#define KLbtLogOperation 0x00000003 +#define KLbtLogError 0x00000004 +#define KLbtLogFatal 0x00000005 + +/** + * + * Then for the module id lets use + * 0x0001 - Lbt Client Library + * 0x0002 - Lbt Server Core + * 0x0003 - Lbt Server Logic Base + * 0x0004 - Lbt Server Logic ( ecom plugin ) + * 0x0005 - Lbt Container + * 0x0006 - Lbt Strategy Plugin api + * 0x0007 - Lbt Strategy Implementation ( Ecom plugin ) + * 0x0008 - Lbt Movement detector plugin api + * 0x0009 - Lbt Cell id Movement Detector + * Did I miss any component ? + */ +#define KLbtLogComponentMask 0xFFFF0000 + +#define KLbtLogClientLib 0x00010000 +#define KLbtLogServerCore 0x00020000 +#define KLbtLogServerLogicBase 0x00030000 +#define KLbtLogServerLogic 0x00040000 +#define KLbtLogContainer 0x00050000 +#define KLbtLogStrategyPluginApi 0x00060000 +#define KLbtLogStrategyEngine 0x00070000 +#define KLbtLogMovementDetectorApi 0x00080000 +#define KLbtLogCellIdMovementDetector 0x00090000 + +#ifdef _DEBUG +#define _LBT_DEBUG +#endif // #ifdef _DEBUG + +// define _LBT_DEBUG to enable LBT logging +#define _LBT_DEBUG + +#ifdef _LBT_DEBUG + +#include +#include +#include "lbtloggerimpl.h" + +_LIT8( KEndOfLineChars, "\r\n"); + +// CLASS DECLARATION +class TLogFunc + { + public: + TLogFunc(const char aFunctionName[]) + { + const unsigned char* string = (unsigned char*)(aFunctionName); + iBuffer.Zero(); + iBuffer.Copy(string); + TBuf8<150> buf; + buf.Zero(); + buf.Append(_L("=>")); + buf.Append(iBuffer); + CLbtLoggerImpl* loggerImpl = CLbtLoggerImpl::CreateLogger(); + if( loggerImpl ) + { + RFileLogger& logger = loggerImpl->GetFileLogger(); + logger.Write( buf ); + } + } + + ~TLogFunc() + { + RThread thread; + TInt exitReason = thread.ExitReason(); + if(exitReason != KErrNone) + { + TExitCategoryName name = thread.ExitCategory(); + TBuf8<400> buf; + buf.Zero(); + buf.Append(_L("LBT PANICKED : ")); + buf.Append(name); + + CLbtLoggerImpl* loggerImpl = CLbtLoggerImpl::CreateLogger(); + if(loggerImpl) + { + RFileLogger& logger = loggerImpl->GetFileLogger(); + logger.Write( buf); + } + // The thread has panicked and hence dont print the exit placeholder + thread.Close(); + return; + } + iBuffer.Append(_L("=>")); + CLbtLoggerImpl* loggerImpl = CLbtLoggerImpl::CreateLogger(); + if(loggerImpl) + { + RFileLogger& logger = loggerImpl->GetFileLogger(); + logger.Write( iBuffer); + } + thread.Close(); + } + + static void FileName( TDes& aFileNameBuffer ) + { + TTime currTime; + currTime.HomeTime(); + TDateTime dt = currTime.DateTime(); + + _LIT16( filefmt, "%S_%d%d%d_%d%d%d.log" ); + + TBuf<150> logFileName; + logFileName.Append( _L("C:\\Logs\\Epos\\lbt_func") ); + aFileNameBuffer.AppendFormat( filefmt(), &logFileName, dt.Day(), + dt.Month(), dt.Year(), dt.Hour(), dt.Minute(), dt.Second() ); + } + + static void FormatTextToBuffer( TDes8& aTrg, const TDesC8& aText ) + { + TTime currTime; + currTime.HomeTime(); + TDateTime dt = currTime.DateTime(); + _LIT8( dtFmt, "%d/%d/%d %d:%d:%d "); + aTrg.AppendFormat( dtFmt(), dt.Day(), dt.Month(), dt.Year(), dt.Hour(), dt.Minute(), dt.Second() ); + aTrg.Append( aText ); + aTrg.Append( KEndOfLineChars ); + } + + static void RenameFileIfRequired() + { + RFs fs; + RFile file; + fs.Connect(); + + TInt err = file.Open( fs, _L("C:\\Logs\\Epos\\lbt_func.log"), EFileWrite|EFileShareAny ); + if( KErrNone == err ) + { + // Check Size of file + TInt size; + file.Size( size ); + + if( size > 1024 ) + { + file.Close(); + TBuf<200> fileName; + FileName( fileName ); + //BaflUtils::RenameFile( fs, _L("C:\\Logs\\Epos\\lbt.log"), fileName ); + fs.Rename(_L("C:\\Logs\\Epos\\lbt_func.log"), fileName ); + } + } + file.Close(); + fs.Close(); + } + + private: + TBuf8<150> iBuffer; + }; + +#define FUNC_ENTER(x) //TLogFunc lbtlog(x); + +#define STOPLOGGING CLbtLoggerImpl::Destroy(); + +#define ERROR(x,y) { TBuf8<150> buffer; \ + const unsigned char* string = (unsigned char*)(x); \ + buffer.Zero(); \ + buffer.Copy(string); \ + buffer.Append(_L(": LBT ERROR")); \ + CLbtLoggerImpl* loggerImpl = CLbtLoggerImpl::CreateLogger(); \ + if( loggerImpl ) \ + { \ + RFileLogger& logger = loggerImpl->GetFileLogger(); \ + logger.WriteFormat( buffer, y); \ + } \ + } + +#define LOG(x) { TBuf8<150> buffer; \ + const unsigned char* string = (unsigned char*)(x); \ + buffer.Zero(); \ + buffer.Copy(string); \ + CLbtLoggerImpl* loggerImpl = CLbtLoggerImpl::CreateLogger(); \ + if( loggerImpl ) \ + { \ + RFileLogger& logger = loggerImpl->GetFileLogger(); \ + logger.Write( buffer); \ + } \ + } + +#define LOG1(x,y) { TBuf8<150> buffer; \ + const unsigned char* string = (unsigned char*)(x); \ + buffer.Zero(); \ + buffer.Copy(string); \ + CLbtLoggerImpl* loggerImpl = CLbtLoggerImpl::CreateLogger(); \ + if( loggerImpl ) \ + { \ + RFileLogger& logger = loggerImpl->GetFileLogger(); \ + logger.WriteFormat( buffer, y); \ + } \ + } + +#define LOGSTRING(x, y) { \ + _LIT(KTmpStr, x); \ + CLbtLoggerImpl* loggerImpl = CLbtLoggerImpl::CreateLogger(); \ + if( loggerImpl ) \ + { \ + RFileLogger& logger = loggerImpl->GetFileLogger(); \ + logger.WriteFormat( TRefByValue(KTmpStr()), y); \ + } \ + } \ + + +#define LBT_FILE_LOGGER 1 // Always log to file + +const char* const LbtLogLevelStr[] = + { + "", + "Verbose", + "Warning", + "Operation", + "Error", + "Fatal" + }; + +const char* const LbtLogComponentStr[] = + { + "", + "client lib", + "server core", + "server logic api", + "server logic", + "container", + "strategy api", + "strategy engine", + "movement detector api", + "cell id movement detector" + }; + + +#define LENGTH(str,len) for(len = 0; str[len]; len++) {} + + +NONSHARABLE_CLASS( TLbtDesOverflow ) : public TDes8Overflow + { + void Overflow(TDes8 &/*aDes*/) + { + // Dummy Implementation to prevent User panic 23 + } + }; + +#define LBT_TRACE(level, file, lineno, desc...) + +/* +LOCAL_C void LBT_TRACE(TInt level, const char* file, TInt lineno, const char* desc,...) + { + _LIT8(fmt, "!%s %s %s:%d "); + TInt desclength, filelength, fmtlength; + fmtlength = fmt().Length(); + LENGTH(desc,desclength); + LENGTH(file,filelength); + + HBufC8* str = NULL; + TRAPD(error, str = HBufC8::NewL(desclength+fmtlength+filelength+10+25+200)); + if ( error != KErrNone ) + { + return; + } + + TPtr8 ptr(str->Des()); + ptr.Zero(); + + TLbtDesOverflow ovrflowHandler; + ptr.AppendFormat(fmt(), + &ovrflowHandler, + LbtLogLevelStr[(level&KLbtLogLevelMask)], + LbtLogComponentStr[(level&KLbtLogComponentMask) >> 16], + file, + lineno); + + HBufC8* descbuf = HBufC8::NewL(desclength); + if ( error == KErrNone ) + { + descbuf->Des().Append(reinterpret_cast(desc), desclength); + VA_LIST list; + VA_START(list, desc); + ptr.AppendFormat(*descbuf, + &ovrflowHandler, + list ); + delete descbuf; + } + +#ifdef LBT_FILE_LOGGER + _LIT(KLbtTraceDir,"epos"); + _LIT(KLbtTraceFile,"lbt.log"); + RFileLogger::Write(KLbtTraceDir(), KLbtTraceFile(), EFileLoggingModeAppend, *str); +#else + RDebug::RawPrint(*str); +#endif + delete str; + } +*/ + +#else // if _DEBUG flag is not defined + +#define LBT_TRACE(level, file, lineno, desc...) +#define FUNC_ENTER(x) +#define STOPLOGGING +#define LOG(x) +#define LOG1(x,y) +#define ERROR(x,y) +#define LOGSTRING(x, y) + +#endif // end of #ifdef _DEBUG + + +#endif // LBT_LOGGER_H diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/LocInfoConversionUnitTest/inc/lbtloggerimpl.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/LocInfoConversionUnitTest/inc/lbtloggerimpl.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,42 @@ +/* +* Copyright (c) 2006 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: This header file describes the triggering logger implementation +* +*/ + + +// INCLUDES +#include + +// FORWARD DECLARATION +class RFileLogger; + +NONSHARABLE_CLASS( CLbtLoggerImpl ) : public CBase + { + public: + IMPORT_C static CLbtLoggerImpl* CreateLogger(); + + IMPORT_C static void Destroy(); + + IMPORT_C RFileLogger& GetFileLogger(); + + private: + CLbtLoggerImpl(); + + ~CLbtLoggerImpl(); + + RFileLogger iLogger; + + static CLbtLoggerImpl* iSelf; + }; \ No newline at end of file diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/LocInfoConversionUnitTest/src/LocInfoConversionHandler.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/LocInfoConversionUnitTest/src/LocInfoConversionHandler.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,63 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: STIF testclass declaration +* +*/ + +#include "LocInfoConversionHandler.h" + +CLocInfoConversionHanlder* CLocInfoConversionHanlder::NewL() + { + CLocInfoConversionHanlder* self = new ( ELeave ) CLocInfoConversionHanlder; + CleanupStack::PushL( self ); + self->ConstructL(); + CleanupStack::Pop( self ); + return self; + } + +CLocInfoConversionHanlder::CLocInfoConversionHanlder():CActive( EPriorityStandard ) + { + CActiveScheduler::Add( this ); + } + +CLocInfoConversionHanlder::~CLocInfoConversionHanlder() + { + if( IsActive() ) + { + Cancel(); + } + } + +void CLocInfoConversionHanlder::Start() + { + iStatus = KRequestPending; + SetActive(); + } + +void CLocInfoConversionHanlder::RunL() + { + CActiveScheduler::Stop(); + } + + +void CLocInfoConversionHanlder::ConstructL() + { + // Nothign to do here + } + + +void CLocInfoConversionHanlder::DoCancel() + { + // Nothign to do here + } diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/LocInfoConversionUnitTest/src/LocInfoConversionUnitTest.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/LocInfoConversionUnitTest/src/LocInfoConversionUnitTest.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,202 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: This file contains testclass implementation. +* +*/ + +// INCLUDE FILES +#include +#include "LocInfoConversionUnitTest.h" +#include + +// EXTERNAL DATA STRUCTURES +//extern ?external_data; + +// EXTERNAL FUNCTION PROTOTYPES +//extern ?external_function( ?arg_type,?arg_type ); + +// CONSTANTS +//const ?type ?constant_var = ?constant; + +// MACROS +//#define ?macro ?macro_def + +// LOCAL CONSTANTS AND MACROS +//const ?type ?constant_var = ?constant; +//#define ?macro_name ?macro_def + +// MODULE DATA STRUCTURES +//enum ?declaration +//typedef ?declaration + +// LOCAL FUNCTION PROTOTYPES +//?type ?function_name( ?arg_type, ?arg_type ); + +// FORWARD DECLARATIONS +//class ?FORWARD_CLASSNAME; + +// ============================= LOCAL FUNCTIONS =============================== + +// ----------------------------------------------------------------------------- +// ?function_name ?description. +// ?description +// Returns: ?value_1: ?description +// ?value_n: ?description_line1 +// ?description_line2 +// ----------------------------------------------------------------------------- +// +/* +?type ?function_name( + ?arg_type arg, // ?description + ?arg_type arg) // ?description + { + + ?code // ?comment + + // ?comment + ?code + } +*/ + +// ============================ MEMBER FUNCTIONS =============================== + +// ----------------------------------------------------------------------------- +// CLocInfoConversionUnitTest::CLocInfoConversionUnitTest +// C++ default constructor can NOT contain any code, that +// might leave. +// ----------------------------------------------------------------------------- +// +CLocInfoConversionUnitTest::CLocInfoConversionUnitTest( + CTestModuleIf& aTestModuleIf ): + CScriptBase( aTestModuleIf ) + { + } + +// ----------------------------------------------------------------------------- +// CLocInfoConversionUnitTest::ConstructL +// Symbian 2nd phase constructor can leave. +// ----------------------------------------------------------------------------- +// +void CLocInfoConversionUnitTest::ConstructL() + { + //Read logger settings to check whether test case name is to be + //appended to log file name. + RSettingServer settingServer; + TInt ret = settingServer.Connect(); + if(ret != KErrNone) + { + User::Leave(ret); + } + // Struct to StifLogger settigs. + TLoggerSettings loggerSettings; + // Parse StifLogger defaults from STIF initialization file. + ret = settingServer.GetLoggerSettings(loggerSettings); + if(ret != KErrNone) + { + User::Leave(ret); + } + // Close Setting server session + settingServer.Close(); + + TFileName logFileName; + + if(loggerSettings.iAddTestCaseTitle) + { + TName title; + TestModuleIf().GetTestCaseTitleL(title); + logFileName.Format(KLocInfoConversionUnitTestLogFileWithTitle, &title); + } + else + { + logFileName.Copy(KLocInfoConversionUnitTestLogFile); + } + + iLog = CStifLogger::NewL( KLocInfoConversionUnitTestLogPath, + logFileName, + CStifLogger::ETxt, + CStifLogger::EFile, + EFalse ); + + SendTestClassVersion(); + iConversionHandler = CLocInfoConversionHanlder::NewL(); + iConversionHandler1 = CLocInfoConversionHanlder::NewL(); + } + +// ----------------------------------------------------------------------------- +// CLocInfoConversionUnitTest::NewL +// Two-phased constructor. +// ----------------------------------------------------------------------------- +// +CLocInfoConversionUnitTest* CLocInfoConversionUnitTest::NewL( + CTestModuleIf& aTestModuleIf ) + { + CLocInfoConversionUnitTest* self = new (ELeave) CLocInfoConversionUnitTest( aTestModuleIf ); + + CleanupStack::PushL( self ); + self->ConstructL(); + CleanupStack::Pop(); + + return self; + + } + +// Destructor +CLocInfoConversionUnitTest::~CLocInfoConversionUnitTest() + { + + // Delete resources allocated from test methods + Delete(); + + // Delete logger + delete iLog; + delete iConversionHandler; + delete iConversionHandler1; + } + +//----------------------------------------------------------------------------- +// CLocInfoConversionUnitTest::SendTestClassVersion +// Method used to send version of test class +//----------------------------------------------------------------------------- +// +void CLocInfoConversionUnitTest::SendTestClassVersion() + { + TVersion moduleVersion; + moduleVersion.iMajor = TEST_CLASS_VERSION_MAJOR; + moduleVersion.iMinor = TEST_CLASS_VERSION_MINOR; + moduleVersion.iBuild = TEST_CLASS_VERSION_BUILD; + + TFileName moduleName; + moduleName = _L("LocInfoConversionUnitTest.dll"); + + TBool newVersionOfMethod = ETrue; + TestModuleIf().SendTestModuleVersion(moduleVersion, moduleName, newVersionOfMethod); + } + +// ========================== OTHER EXPORTED FUNCTIONS ========================= + +// ----------------------------------------------------------------------------- +// LibEntryL is a polymorphic Dll entry point. +// Returns: CScriptBase: New CScriptBase derived object +// ----------------------------------------------------------------------------- +// +EXPORT_C CScriptBase* LibEntryL( + CTestModuleIf& aTestModuleIf ) // Backpointer to STIF Test Framework + { + + return ( CScriptBase* ) CLocInfoConversionUnitTest::NewL( aTestModuleIf ); + + } + + +// End of File diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/LocInfoConversionUnitTest/src/LocInfoConversionUnitTestBlocks.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/LocInfoConversionUnitTest/src/LocInfoConversionUnitTestBlocks.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,2017 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: This file contains testclass implementation. +* +*/ + +// [INCLUDE FILES] - do not remove +#include +#include +#include + +#include "LocInfoConversionUnitTest.h" +#include "rlbslocmonitorsession.h" +#include "rlbslocinfoconverter.h" +#include "rlbslocmonitorareapositioner.h" +#include +#include +#include "lbsposition.h" + + +// Plug in +const TInt KDummyPluginId = 537007117; +const TInt KSuplPluginId = 537028467; + +// ============================ MEMBER FUNCTIONS =============================== + +// ----------------------------------------------------------------------------- +// CLocInfoConversionUnitTest::Delete +// Delete here all resources allocated and opened from test methods. +// Called from destructor. +// ----------------------------------------------------------------------------- +// +void CLocInfoConversionUnitTest::Delete() + { + + } + +// ----------------------------------------------------------------------------- +// CLocInfoConversionUnitTest::RunMethodL +// Run specified method. Contains also table of test mothods and their names. +// ----------------------------------------------------------------------------- +// +TInt CLocInfoConversionUnitTest::RunMethodL( + CStifItemParser& aItem ) + { + + static TStifFunctionInfo const KFunctions[] = + { + ENTRY( "UnitTest1", CLocInfoConversionUnitTest::RLbsLocInfoConverter_Connect1L ), + ENTRY( "UnitTest2", CLocInfoConversionUnitTest::RLbsLocInfoConverter_Connect2L ), + ENTRY( "UnitTest3", CLocInfoConversionUnitTest::RLbsLocInfoConverter_ConvertLocationInfo1L ), + ENTRY( "UnitTest4", CLocInfoConversionUnitTest::RLbsLocInfoConverter_ConvertLocationInfo2L ), + ENTRY( "UnitTest5", CLocInfoConversionUnitTest::RLbsLocInfoConverter_ConvertLocationInfo3L ), + ENTRY( "UnitTest6", CLocInfoConversionUnitTest::RLbsLocInfoConverter_ConvertLocationInfo4L ), + ENTRY( "UnitTest7", CLocInfoConversionUnitTest::RLbsLocInfoConverter_ConvertLocationInfo5L ), + ENTRY( "UnitTest8", CLocInfoConversionUnitTest::RLbsLocInfoConverter_ConvertLocationInfo6L ), + ENTRY( "UnitTest9", CLocInfoConversionUnitTest::RLbsLocInfoConverter_ConvertLocationInfo7L ), + ENTRY( "UnitTest10", CLocInfoConversionUnitTest::RLbsLocInfoConverter_ConvertLocationInfo8L ), + ENTRY( "UnitTest11", CLocInfoConversionUnitTest::RLbsLocInfoConverter_ConvertLocationInfo9L ), + ENTRY( "UnitTest12", CLocInfoConversionUnitTest::RLbsLocInfoConverter_ConvertLocationInfo10L ), + ENTRY( "UnitTest13", CLocInfoConversionUnitTest::RLbsLocInfoConverter_Cancel1L ), + ENTRY( "UnitTest14", CLocInfoConversionUnitTest::RLbsLocInfoConverter_Cancel2L ), + ENTRY( "UnitTest15", CLocInfoConversionUnitTest::RLbsLocInfoConverter_Cancel3L ), + ENTRY( "UnitTest16", CLocInfoConversionUnitTest::RLbsLocInfoConverter_Cancel4L ), + }; + + const TInt count = sizeof( KFunctions ) / + sizeof( TStifFunctionInfo ); + + return RunInternalL( KFunctions, count, aItem ); + + } + +// ----------------------------------------------------------------------------- +// CLocInfoConversionUnitTest::RLbsLocInfoConverter_Connect1 +// simple session and subsession. +// ----------------------------------------------------------------------------- +// +TInt CLocInfoConversionUnitTest::RLbsLocInfoConverter_Connect1L(CStifItemParser& /*aItem*/ ) + { + TInt error; + RLbsLocMonitorSession locMonitorSession; + error = locMonitorSession.Connect(); + if( error != KErrNone ) + { + return error; + } + CleanupClosePushL( locMonitorSession ); + RLbsLocInfoConverter locInfoConverter; + CleanupClosePushL( locInfoConverter ); + locInfoConverter.OpenL( locMonitorSession ); + locInfoConverter.Close(); + CleanupStack::PopAndDestroy( 2 ); // locInfoConverter,locMonitorSession + return KErrNone; + } + +// ----------------------------------------------------------------------------- +// CLocInfoConversionUnitTest::RLbsLocInfoConverter_Connect2 +// Opening multiple subsession from single session +// ----------------------------------------------------------------------------- +// +TInt CLocInfoConversionUnitTest::RLbsLocInfoConverter_Connect2L(CStifItemParser& /*aItem*/ ) + { + RLbsLocMonitorSession locMonitorSession; + TInt error = locMonitorSession.Connect(); + if( error != KErrNone ) + { + return error; + } + CleanupClosePushL( locMonitorSession ); + RLbsLocInfoConverter locInfoConverter; + CleanupClosePushL( locInfoConverter ); + RLbsLocInfoConverter locInfoConverter1; + CleanupClosePushL( locInfoConverter1 ); + + locInfoConverter.OpenL( locMonitorSession ); + locInfoConverter1.OpenL( locMonitorSession ); + locInfoConverter.Close(); + locInfoConverter1.Close(); + + CleanupStack::PopAndDestroy( 3 ); //locInfoConverter1,locInfoConverter and + //locMonitorSession + return KErrNone; + } + + +// ----------------------------------------------------------------------------- +// CLocInfoConversionUnitTest::RLbsLocInfoConverter_ConvertLocationInfo1L +// This test case tests the simple and corner case related +// to RLbsLocInfoConverter::ConvertLocationInfoL +// ----------------------------------------------------------------------------- +// +TInt CLocInfoConversionUnitTest::RLbsLocInfoConverter_ConvertLocationInfo1L(CStifItemParser& /*aItem*/ ) + { + RLbsLocMonitorSession locMonitorSession; + TInt error = locMonitorSession.Connect(); + if( error != KErrNone ) + { + return error; + } + CleanupClosePushL( locMonitorSession ); + RLbsLocInfoConverter locInfoConverter; + CleanupClosePushL( locInfoConverter ); + locInfoConverter.OpenL( locMonitorSession ); + + + TUid conversionModuleId = TUid::Uid( KDummyPluginId ); + + /** + * Case 1: where NULL pointer is passed instead of location info + */ + error = KErrNone; + CLbsLocationInfo* locationInfo = CLbsLocationInfo::NewL(); + CleanupStack::PushL( locationInfo ); + TRAP( error,locInfoConverter.ConvertLocationInfoL( + *locationInfo,ELbsConversionNotDefined,ELbsConversionOutputPosition, + conversionModuleId,iConversionHandler->iStatus )); + if( error!= KErrArgument ) + { + User::Leave( KErrArgument ); + } + + /** + * Case 2: where we pass location info.This is + * just test where this method completes without leaving. + */ + + // Here we append gsmcell info object to the existing location info object. + AppendAreaInfoObjectToLocationInfoL( locationInfo,ELbsAreaGsmCellInfoClass ); + + locInfoConverter.ConvertLocationInfoL( + *locationInfo,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId,iConversionHandler->iStatus ); + iConversionHandler->Start(); + locInfoConverter.CancelConvertLocationInfo(); + iConversionHandler->Cancel(); + CleanupStack::PopAndDestroy( locationInfo ); + + /** + * Case 3. Empty location info array is passed. + */ + error = KErrNone; + RPointerArray locationInfoArray; + CleanupClosePushL( locationInfoArray ); + TRAP( error,locInfoConverter.ConvertLocationInfoL( + locationInfoArray,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId,iConversionHandler->iStatus )); + + if( error != KErrArgument ) + { + User::Leave( KErrArgument ); + } + + /** + * Case 4: where we pass location info array.This is + * just test where this method completes without leaving. + */ + + // Here we create locationInfo object with gsm cell info object contained in it. + CLbsLocationInfo* locationInfo1 = CreateLocationInfoObjectLC( ELbsAreaGsmCellInfoClass ); + locationInfoArray.Append( locationInfo1 ); + + locInfoConverter.ConvertLocationInfoL( + locationInfoArray,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId,iConversionHandler->iStatus ); + iConversionHandler->Start(); + locInfoConverter.CancelConvertLocationInfo(); + iConversionHandler->Cancel(); + + CleanupStack::Pop( 2 ); //locationInfo1,locationInfoArray + locationInfoArray.ResetAndDestroy(); + CleanupStack::PopAndDestroy( 2 ); // locInfoConverter,locMonitorSession + return KErrNone; + } + +// ----------------------------------------------------------------------------- +// CLocInfoConversionUnitTest::RLbsLocInfoConverter_ConvertLocationInfo2L +// This test case tests ConvertLocationInfo when expected information is +// of type ECoordinate +// ----------------------------------------------------------------------------- +// +TInt CLocInfoConversionUnitTest::RLbsLocInfoConverter_ConvertLocationInfo2L(CStifItemParser& /*aItem*/ ) + { + RLbsLocMonitorSession locMonitorSession; + TInt error = locMonitorSession.Connect(); + if( error != KErrNone ) + { + return error; + } + CleanupClosePushL( locMonitorSession ); + RLbsLocInfoConverter locInfoConverter; + CleanupClosePushL( locInfoConverter ); + locInfoConverter.OpenL( locMonitorSession ); + + + RPointerArray locationInfoArray; + CleanupClosePushL( locationInfoArray ); + + TUid conversionModuleId = TUid::Uid( KDummyPluginId ); + + /** + * case 1: Any information regarding the area is passed and + * coordinate corresponding to that area info is expected. + */ + + // Here GSM cell info is passed as input area. + CLbsLocationInfo* locationInfo = CreateLocationInfoObjectLC( ELbsAreaGsmCellInfoClass ); + + locInfoConverter.ConvertLocationInfoL( + *locationInfo,ELbsConversionNotDefined,ELbsConversionOutputPosition + ,conversionModuleId,iConversionHandler->iStatus ); + iConversionHandler->Start(); + CActiveScheduler::Start(); + + error = iConversionHandler->iStatus.Int(); + // If the conversion status is KErrNone, check for the corresponding + // converted info. + if( error == KErrNone ) + { + CheckPositionConvertedInfoL( locationInfo ); + } + // KErrNotSupported and KErrNotFound are allowed error codes. + else if( !( error == KErrNotSupported || error == KErrNotFound ) ) + { + User::Leave( KErrArgument ); + } + + /** + * case 2: Pass any information related to multiple area and we expect coordinate information + * corresponding to each area information. + */ + + // Create one more location info object which holds wlan info for which corresponding coordinate + // is expected. + CLbsLocationInfo* locationInfo2 = CreateLocationInfoObjectLC( ELbsAreaWlanInfoClass ); + + // Before pushing location info object, remove the converted info from it. + // We had requested for coordinate info, hence we need to clear it before + // we use it as input for next conversion. + locationInfo->ResetAreaInfo( CLbsLocationInfo::ELbsPosInfo ); + locationInfoArray.Append( locationInfo ); + + locationInfoArray.Append( locationInfo2 ); + + locInfoConverter.ConvertLocationInfoL( + locationInfoArray,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId,iConversionHandler->iStatus ); + iConversionHandler->Start(); + + // This is just to block the control till the call back method is called. + // Code after this statement will be resumed when Stop on CActiveScheduler + // is called in the HandleLocationConversion method. + CActiveScheduler::Start(); + + error = iConversionHandler->iStatus.Int(); + // Iterate through the array and check for converted info. + if( error == KErrNone ) + { + for( TInt i=0;i ( locationInfobase ); + CheckPositionConvertedInfoL( locationInfo ); + } + } + // KErrNotSupported and KErrNotFound are allowed error codes. + else if( !( error == KErrNotSupported || error == KErrNotFound ) ) + { + User::Leave( KErrArgument ); + } + + CleanupStack::Pop( 3 ); // locationInfo,locationInfo1,locationInfoArray + locationInfoArray.ResetAndDestroy(); + CleanupStack::PopAndDestroy( 2 ); // locInfoConverter,locMonitorSession + return KErrNone; + } + + +// ----------------------------------------------------------------------------- +// CLocInfoConversionUnitTest::RLbsLocInfoConverter_ConvertLocationInfo3L +// This test case tests ConvertLocationInfo when expected information is +// of type EGsm +// ----------------------------------------------------------------------------- +// +TInt CLocInfoConversionUnitTest::RLbsLocInfoConverter_ConvertLocationInfo3L(CStifItemParser& /*aItem*/ ) + { + RLbsLocMonitorSession locMonitorSession; + TInt error = locMonitorSession.Connect(); + if( error != KErrNone ) + { + return error; + } + CleanupClosePushL( locMonitorSession ); + RLbsLocInfoConverter locInfoConverter; + CleanupClosePushL( locInfoConverter ); + locInfoConverter.OpenL( locMonitorSession ); + + RPointerArray locationInfoArray; + CleanupClosePushL( locationInfoArray ); + + TUid conversionModuleId = TUid::Uid( KDummyPluginId );; + + /** + * case 1: Pass any area info and we expect GSM cell info + */ + + // Here WLAN info is passed as input area. + CLbsLocationInfo* locationInfo = CreateLocationInfoObjectLC( ELbsAreaWlanInfoClass ); + + locInfoConverter.ConvertLocationInfoL( + *locationInfo,ELbsConversionCacheOnly,ELbsConversionOutputGsm, + conversionModuleId,iConversionHandler->iStatus ); + iConversionHandler->Start(); + + // This is just to block the control till the call back method is called. + // Code after this statement will be resumed when Stop on CActiveScheduler + // is called in the HandleLocationConversion method. + CActiveScheduler::Start(); + + error = iConversionHandler->iStatus.Int(); + // If the conversion status is success, check for the corresponding + // converted info. + if( error == KErrNone ) + { + CheckGsmCellConvertedInfoL( locationInfo ); + } + // KErrNotSupported and KErrNotFound are allowed error codes. + else if( !( error == KErrNotSupported || error == KErrNotFound ) ) + { + User::Leave( KErrArgument ); + } + + /** + * case 2: Pass any information related to multiple area and we expect GSM cell info + * corresponding to each area information. + */ + + // Create one more location info object which holds coordinate info for which corresponding GSM + // cell info is expected. + CLbsLocationInfo* locationInfo1 = CreateLocationInfoObjectLC( ELbsAreaPositionInfoClass ); + + // Before pushing location info object, remove the converted info from it. + // We had requested for GSM cell info, hence we need to clear it before + // we use it for next conversion. + locationInfo->ResetAreaInfo( CLbsLocationInfo::ELbsGsmInfo ); + locationInfoArray.Append( locationInfo ); + locationInfoArray.Append( locationInfo1 ); + + locInfoConverter.ConvertLocationInfoL( + locationInfoArray,ELbsConversionCacheOnly,ELbsConversionOutputGsm, + conversionModuleId,iConversionHandler->iStatus ); + iConversionHandler->Start(); + + // This is just to block the control till the call back method is called. + // Code after this statement will be resumed when Stop on CActiveScheduler + // is called in the HandleLocationConversion method. + CActiveScheduler::Start(); + + error = iConversionHandler->iStatus.Int(); + // Iterate through the array and check for converted info. + if( error == KErrNone ) + { + for( TInt i=0;i ( locationInfobase ); + CheckGsmCellConvertedInfoL( locationInfo ); + } + } + // KErrNotSupported and KErrNotFound are allowed error codes. + else if( !( error == KErrNotSupported || error == KErrNotFound ) ) + { + User::Leave( KErrArgument ); + } + CleanupStack::Pop( 3 ); // locationInfo,locationInfo1,locationInfoArray + locationInfoArray.ResetAndDestroy(); + CleanupStack::PopAndDestroy( 2 ); // locInfoConverter,locMonitorSession + return KErrNone; + } + + +// ----------------------------------------------------------------------------- +// CLocInfoConversionUnitTest::RLbsLocInfoConverter_ConvertLocationInfo4L +//This test case tests ConvertLocationInfo when expected information is +// of type EWcdma +// ----------------------------------------------------------------------------- +// +TInt CLocInfoConversionUnitTest::RLbsLocInfoConverter_ConvertLocationInfo4L(CStifItemParser& /*aItem*/ ) + { + RLbsLocMonitorSession locMonitorSession; + TInt error = locMonitorSession.Connect(); + if( error != KErrNone ) + { + return error; + } + CleanupClosePushL( locMonitorSession ); + RLbsLocInfoConverter locInfoConverter; + CleanupClosePushL( locInfoConverter ); + locInfoConverter.OpenL( locMonitorSession ); + + RPointerArray locationInfoArray; + CleanupClosePushL( locationInfoArray ); + + TUid conversionModuleId = TUid::Uid( KDummyPluginId ); + + /** + * case 1: Pass any area info pointer and we expect EWcdma type + */ + CLbsLocationInfo* locationInfo = CreateLocationInfoObjectLC( ELbsAreaPositionInfoClass ); + + locInfoConverter.ConvertLocationInfoL( + *locationInfo,ELbsConversionSilent,ELbsConversionOutputWcdma, + conversionModuleId,iConversionHandler->iStatus ); + iConversionHandler->Start(); + + // This is just to block the control till the call back method is called. + // Code after this statement will be resumed when Stop on CActiveScheduler + // is called in the HandleLocationConversion method. + CActiveScheduler::Start(); + + error = iConversionHandler->iStatus.Int(); + // If the conversion status is success, check for the corresponding + // converted info. + if( error == KErrNone ) + { + CheckWcdmaCellConvertedInfoL( locationInfo ); + } + // KErrNotSupported and KErrNotFound are allowed error codes. + else if( !( error == KErrNotSupported || error == KErrNotFound ) ) + { + User::Leave( KErrArgument ); + } + + /** + * case 2: Pass any information related to multiple area and we expect wcdma information + * corresponding to each area information. + */ + + // Create one more location info object which holds wlan info for which corresponding WCDMA + // cell info is expected. + CLbsLocationInfo* locationInfo1 = CreateLocationInfoObjectLC( ELbsAreaWlanInfoClass ); + + // Before pushing location info object, remove the converted info from it. + // We had requested for WCDMA info, hence we need to clear it before + // we use it as input for next conversion. + locationInfo->ResetAreaInfo( CLbsLocationInfo::ELbsWcdmaInfo ); + locationInfoArray.Append( locationInfo ); + locationInfoArray.Append( locationInfo1 ); + + locInfoConverter.ConvertLocationInfoL( + locationInfoArray,ELbsConversionSilent,ELbsConversionOutputWcdma, + conversionModuleId,iConversionHandler->iStatus ); + + iConversionHandler->Start(); + + // This is just to block the control till the call back method is called. + // Code after this statement will be resumed when Stop on CActiveScheduler + // is called in the HandleLocationConversion method. + CActiveScheduler::Start(); + + error = iConversionHandler->iStatus.Int(); + // Iterate through the array and check for converted info. + if( error == KErrNone ) + { + for( TInt i=0;i ( locationInfobase ); + CheckWcdmaCellConvertedInfoL( locationInfo ); + } + } + // KErrNotSupported and KErrNotFound are allowed error codes. + else if( !( error == KErrNotSupported || error == KErrNotFound ) ) + { + User::Leave( KErrArgument ); + } + + CleanupStack::Pop( 3 ); // locationInfo,locationInfo1,locationInfoArray + locationInfoArray.ResetAndDestroy(); + CleanupStack::PopAndDestroy( 2 ); // locInfoConverter,locMonitorSession + return KErrNone; + } + + +// ----------------------------------------------------------------------------- +// CLocInfoConversionUnitTest::RLbsLocInfoConverter_ConvertLocationInfo5L +// This test case tests ConvertLocationInfo when expected information is +// of type EWlan +// ----------------------------------------------------------------------------- +// +TInt CLocInfoConversionUnitTest::RLbsLocInfoConverter_ConvertLocationInfo5L(CStifItemParser& /*aItem*/ ) + { + RLbsLocMonitorSession locMonitorSession; + TInt error = locMonitorSession.Connect(); + if( error != KErrNone ) + { + return error; + } + CleanupClosePushL( locMonitorSession ); + RLbsLocInfoConverter locInfoConverter; + CleanupClosePushL( locInfoConverter ); + locInfoConverter.OpenL( locMonitorSession ); + + RPointerArray locationInfoArray; + CleanupClosePushL( locationInfoArray ); + + TUid conversionModuleId = TUid::Uid( KDummyPluginId ); + + /** + * case 1: Pass any area info pointer and we expect EWlan type + */ + CLbsLocationInfo* locationInfo = CreateLocationInfoObjectLC( ELbsAreaWcmdaCellInfoClass ); + + locInfoConverter.ConvertLocationInfoL( + *locationInfo,ELbsConversionCacheOnly,ELbsConversionOutputWlan,conversionModuleId,iConversionHandler->iStatus ); + iConversionHandler->Start(); + + // This is just to block the control till the call back method is called. + // Code after this statement will be resumed when Stop on CActiveScheduler + // is called in the HandleLocationConversion method. + CActiveScheduler::Start(); + + // If the conversion status is success, check for the corresponding + // converted info. + if( iConversionHandler->iStatus == KErrNone ) + { + CheckWlanConvertedInfoL( locationInfo ); + } + // KErrNotSupported and KErrNotFound are allowed error codes. + else if( !( iConversionHandler->iStatus == KErrNotSupported || iConversionHandler->iStatus == KErrNotFound ) ) + { + User::Leave( KErrArgument ); + } + + /** + * Case 2: Pass any information related to multiple area and we expect Wlan info + * corresponding to each area information. + */ + + // Create one more location info object which holds coordinate info for which corresponding + // Wlan info is expected. + CLbsLocationInfo* locationInfo1 = CreateLocationInfoObjectLC( ELbsAreaPositionInfoClass ); + + // Before pushing location info object, remove the converted info from it. + // We had requested for wlan info, hence we need to clear it before + // we use it for next conversion. + locationInfo->ResetAreaInfo( CLbsLocationInfo::ELbsWlanInfo ); + locationInfoArray.Append( locationInfo ); + locationInfoArray.Append( locationInfo1 ); + + TRequestStatus status; + locInfoConverter.ConvertLocationInfoL( + locationInfoArray,ELbsConversionCacheOnly,ELbsConversionOutputWlan,conversionModuleId,iConversionHandler->iStatus); + iConversionHandler->Start(); + + // This is just to block the control till the call back method is called. + // Code after this statement will be resumed when Stop on CActiveScheduler + // is called in the HandleLocationConversion method. + CActiveScheduler::Start(); + + // Iterate through the array and check for converted info. + if( iConversionHandler->iStatus == KErrNone ) + { + for( TInt i=0;i ( locationInfobase ); + CheckWlanConvertedInfoL( locationInfo ); + } + } + // KErrNotSupported and KErrNotFound are allowed error codes. + else if( !( iConversionHandler->iStatus == KErrNotSupported || iConversionHandler->iStatus == KErrNotFound ) ) + { + User::Leave( KErrArgument ); + } + CleanupStack::Pop( 3 ); // locationInfo,locationInfo1,locationInfoArray + locationInfoArray.ResetAndDestroy(); + CleanupStack::PopAndDestroy( 2 ); // locInfoConverter,locMonitorSession + return KErrNone; + } + +// ----------------------------------------------------------------------------- +// CLocInfoConversionUnitTest::RLbsLocInfoConverter_ConvertLocationInfo6L +// This test case tests the scenario when user tries to request new single +// conversion without waiting for completion of previous one. +// ----------------------------------------------------------------------------- +// +TInt CLocInfoConversionUnitTest::RLbsLocInfoConverter_ConvertLocationInfo6L(CStifItemParser& /*aItem*/ ) + { + RLbsLocMonitorSession locMonitorSession; + TInt error = locMonitorSession.Connect(); + if( error != KErrNone ) + { + return error; + } + CleanupClosePushL( locMonitorSession ); + RLbsLocInfoConverter locInfoConverter; + CleanupClosePushL( locInfoConverter ); + locInfoConverter.OpenL( locMonitorSession ); + + TUid conversionModuleId = TUid::Uid( KDummyPluginId ); + + CLbsLocationInfo* locationInfo = CreateLocationInfoObjectLC( ELbsAreaGsmCellInfoClass ); + + // Here in this case input area doesnt matter + locInfoConverter.ConvertLocationInfoL( + *locationInfo,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId,iConversionHandler->iStatus ); + iConversionHandler->Start(); + + CLbsLocationInfo* locationInfo1 = CreateLocationInfoObjectLC( ELbsAreaWcmdaCellInfoClass ); + + error = KErrNone; + TRequestStatus status; + TestModuleIf().SetExitReason( CTestModuleIf::EPanic, 0); + locInfoConverter.ConvertLocationInfoL( + *locationInfo1,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId,status ); + + CleanupStack::PopAndDestroy( 2 ); // locationInfo1,locationInfo + return KErrNone; + } + +// ----------------------------------------------------------------------------- +// CLocInfoConversionUnitTest::RLbsLocInfoConverter_ConvertLocationInfo7L +// This test case tests the scenario when user tries to request new batch +// conversion without waiting for completion of previous one. +// ----------------------------------------------------------------------------- +// +TInt CLocInfoConversionUnitTest::RLbsLocInfoConverter_ConvertLocationInfo7L(CStifItemParser& /*aItem*/ ) + { + RLbsLocMonitorSession locMonitorSession; + TInt error = locMonitorSession.Connect(); + if( error != KErrNone ) + { + return error; + } + CleanupClosePushL( locMonitorSession ); + RLbsLocInfoConverter locInfoConverter; + CleanupClosePushL( locInfoConverter ); + locInfoConverter.OpenL( locMonitorSession ); + + TUid conversionModuleId = TUid::Uid( KNullUidValue );; + + // Here in this case input area doesnt matter + RPointerArray locationInfoArray; + CleanupClosePushL( locationInfoArray ); + + RPointerArray locationInfoArray1; + CleanupClosePushL( locationInfoArray1 ); + + CLbsLocationInfo* locationInfo = CreateLocationInfoObjectLC( ELbsAreaGsmCellInfoClass ); + + CLbsLocationInfo* locationInfo1 = CreateLocationInfoObjectLC( ELbsAreaWlanInfoClass ); + + locationInfoArray.Append( locationInfo ); + + locInfoConverter.ConvertLocationInfoL( + locationInfoArray,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId ,iConversionHandler->iStatus ); + iConversionHandler->Start(); + + locationInfoArray1.Append( locationInfo1 ); + + TRequestStatus status; + TestModuleIf().SetExitReason( CTestModuleIf::EPanic, 0); + locInfoConverter.ConvertLocationInfoL( + locationInfoArray1,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId,status ); + + CleanupStack::Pop(4); // locationInfo1,locationInfoArray1,locationInfo,locationInfoArray + locationInfoArray.ResetAndDestroy(); + locationInfoArray1.ResetAndDestroy(); + CleanupStack::PopAndDestroy( 2 ); // locInfoConverter,locMonitorSession + return KErrNone; + } + + +// ----------------------------------------------------------------------------- +// CLocInfoConversionUnitTest::RLbsLocInfoConverter_ConvertLocationInfo8L +// This test case tests the scenario when user tries to request two conversion +// using two subsessions simultaneously specifying same plugin. +// ----------------------------------------------------------------------------- +// +TInt CLocInfoConversionUnitTest::RLbsLocInfoConverter_ConvertLocationInfo8L(CStifItemParser& /*aItem*/ ) + { + RLbsLocMonitorSession locMonitorSession; + TInt error = locMonitorSession.Connect(); + if( error != KErrNone ) + { + return error; + } + CleanupClosePushL( locMonitorSession ); + + // Here we need to open two subsessions. + RLbsLocInfoConverter locInfoConverter,locInfoConverter1; + CleanupClosePushL( locInfoConverter ); + locInfoConverter.OpenL( locMonitorSession ); + + CleanupClosePushL( locInfoConverter1 ); + locInfoConverter1.OpenL( locMonitorSession ); + + RPointerArray locationInfoArray; + CleanupClosePushL( locationInfoArray ); + + RPointerArray locationInfoArray1; + CleanupClosePushL( locationInfoArray1 ); + + TUid conversionModuleId = TUid::Uid( KDummyPluginId ); + + /** + * Case 1: Users tries to request 2 simultaneous single conversion + * using 2 subsession specifying same conversion uid. + */ + + // Here type of area input doesnt matter. + CLbsLocationInfo* locationInfo = CreateLocationInfoObjectLC( ELbsAreaGsmCellInfoClass ); + + CLbsLocationInfo* locationInfo1 = CreateLocationInfoObjectLC( ELbsAreaGsmCellInfoClass ); + + locInfoConverter.ConvertLocationInfoL( + *locationInfo,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId,iConversionHandler->iStatus ); + iConversionHandler->Start(); + + locInfoConverter1.ConvertLocationInfoL( + *locationInfo1,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId,iConversionHandler1->iStatus ); + iConversionHandler1->Start(); + + // This is just to block the control till the call back method is called. + // Code after this statement will be resumed when Stop on CActiveScheduler + // is called in the HandleLocationConversion method. + CActiveScheduler::Start(); + + // Here we need to wait till both the request completes.Hence we need to block it once again + // till the 2nd request completes. + if( iConversionHandler->iStatus.Int() == KRequestPending || + iConversionHandler1->iStatus.Int() == KRequestPending ) + { + CActiveScheduler::Start(); + } + + // Check the converted values in both the conversions. + error = iConversionHandler->iStatus.Int(); + if( error == KErrNone ) + { + CheckPositionConvertedInfoL( locationInfo ); + } + else + { + User::Leave( KErrArgument ); + } + + error = iConversionHandler1->iStatus.Int(); + if( error == KErrNone ) + { + CheckPositionConvertedInfoL( locationInfo1 ); + } + else + { + User::Leave( KErrArgument ); + } + + /** + * Case 2: Users tries to request 2 simultaneous bulk conversion + * using 2 subsession specifying same conversion uid. + */ + + // Before we append the location info object to the info array, + // we need to clear the converted info in each object. + locationInfo->ResetAreaInfo( CLbsLocationInfo::ELbsPosInfo); + locationInfo1->ResetAreaInfo( CLbsLocationInfo::ELbsPosInfo ); + + locationInfoArray.Append( locationInfo ); + locationInfoArray1.Append( locationInfo1 ); + + locInfoConverter.ConvertLocationInfoL( + locationInfoArray,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId,iConversionHandler->iStatus ); + iConversionHandler->Start(); + + locInfoConverter1.ConvertLocationInfoL( + locationInfoArray1,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId,iConversionHandler1->iStatus ); + iConversionHandler1->Start(); + + // This is just to block the control till the call back method is called. + // Code after this statement will be resumed when Stop on CActiveScheduler + // is called in the HandleLocationConversion method. + CActiveScheduler::Start(); + + // Here we need to wait till both the request completes.Hence we need to block it once again + // till the 2nd request completes. + if( iConversionHandler->iStatus.Int() == KRequestPending || + iConversionHandler1->iStatus.Int() == KRequestPending ) + { + CActiveScheduler::Start(); + } + + // Check the converted values in both the conversions. + // Iterate through the array and check for converted info. + error = iConversionHandler->iStatus.Int(); + if( error == KErrNone ) + { + for( TInt i=0;i ( locationInfobase ); + CheckPositionConvertedInfoL( locationInfo ); + } + } + else + { + User::Leave( KErrArgument ); + } + + error = iConversionHandler1->iStatus.Int(); + if( error == KErrNone ) + { + for( TInt i=0;i ( locationInfobase ); + CheckPositionConvertedInfoL( locationInfo ); + } + } + else + { + User::Leave( KErrArgument ); + } + + CleanupStack::Pop(4); // locationInfo1,locationInfoArray1,locationInfo,locationInfoArray + locationInfoArray.ResetAndDestroy(); + locationInfoArray1.ResetAndDestroy(); + CleanupStack::PopAndDestroy( 3 ); // locInfoConverter,locInfoConverter1,locMonitorSession + return KErrNone; + } + + +// ----------------------------------------------------------------------------- +// CLocInfoConversionUnitTest::RLbsLocInfoConverter_ConvertLocationInfo9L +// This test case tests the scenario when user tries to request two conversion +// using two subsessions simultaneously specifying different plugin. +// ----------------------------------------------------------------------------- +// +TInt CLocInfoConversionUnitTest::RLbsLocInfoConverter_ConvertLocationInfo9L(CStifItemParser& /*aItem*/ ) + { + RLbsLocMonitorSession locMonitorSession; + TInt error = locMonitorSession.Connect(); + if( error != KErrNone ) + { + return error; + } + CleanupClosePushL( locMonitorSession ); + + // Here we need two subsessions + RLbsLocInfoConverter locInfoConverter,locInfoConverter1; + CleanupClosePushL( locInfoConverter ); + locInfoConverter.OpenL( locMonitorSession ); + + CleanupClosePushL( locInfoConverter1 ); + locInfoConverter1.OpenL( locMonitorSession ); + + RPointerArray locationInfoArray; + CleanupClosePushL( locationInfoArray ); + + RPointerArray locationInfoArray1; + CleanupClosePushL( locationInfoArray1 ); + + TUid conversionModuleId1 = TUid::Uid( KDummyPluginId ); + TUid conversionModuleId2 = TUid::Uid( KSuplPluginId ); + + /** + * Case 1: Users tries to request 2 simultaneous single conversion + * using 2 subsession specifying different conversion uid. + */ + + CLbsLocationInfo* locationInfo = CreateLocationInfoObjectLC( ELbsAreaWcmdaCellInfoClass ); + + CLbsLocationInfo* locationInfo1 = CreateLocationInfoObjectLC( ELbsAreaWlanInfoClass ); + + locInfoConverter.ConvertLocationInfoL( + *locationInfo,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId1,iConversionHandler->iStatus ); + iConversionHandler->Start(); + + locInfoConverter1.ConvertLocationInfoL( + *locationInfo1,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId2,iConversionHandler1->iStatus ); + iConversionHandler1->Start(); + + // This is just to block the control till the call back method is called. + // Code after this statement will be resumed when Stop on CActiveScheduler + // is called in the HandleLocationConversion method. + CActiveScheduler::Start(); + + // Here we need to wait till both the request completes.Hence we need to block it once again + // till the 2nd request completes. + if( iConversionHandler->iStatus.Int() == KRequestPending || + iConversionHandler1->iStatus.Int() == KRequestPending ) + { + CActiveScheduler::Start(); + } + + // Check the converted values in both the conversions. + error = iConversionHandler->iStatus.Int(); + if( error == KErrNone ) + { + CheckPositionConvertedInfoL( locationInfo ); + } + else if( !( error == KErrNotFound || error == KErrNotSupported ) ) + { + User::Leave( KErrArgument ); + } + + error = iConversionHandler1->iStatus.Int(); + if( error == KErrNone ) + { + CheckPositionConvertedInfoL( locationInfo1 ); + } + else if( !( error == KErrNotFound || error == KErrNotSupported ) ) + { + User::Leave( KErrArgument ); + } + + /** + * Case 2: Users tries to request 2 simultaneous bulk conversion + * using 2 subsession specifying same conversion uid. + */ + + // Before we append the location info object to the info array, + // we need to clear the converted info in each object. + locationInfo->ResetAreaInfo( CLbsLocationInfo::ELbsPosInfo ); + locationInfo1->ResetAreaInfo( CLbsLocationInfo::ELbsPosInfo ); + + locationInfoArray.Append( locationInfo ); + locationInfoArray1.Append( locationInfo1 ); + + locInfoConverter.ConvertLocationInfoL( + locationInfoArray,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId1,iConversionHandler->iStatus ); + iConversionHandler->Start(); + + locInfoConverter1.ConvertLocationInfoL( + locationInfoArray1,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId2,iConversionHandler1->iStatus ); + iConversionHandler1->Start(); + + // This is just to block the control till the call back method is called. + // Code after this statement will be resumed when Stop on CActiveScheduler + // is called in the HandleLocationConversion method. + CActiveScheduler::Start(); + + // Here we need to wait till both the request completes.Hence we need to block it once again + // till the 2nd request completes. + if( iConversionHandler->iStatus.Int() == KRequestPending || + iConversionHandler1->iStatus.Int() == KRequestPending ) + { + CActiveScheduler::Start(); + } + + // Check the converted values in both the conversions. + // Iterate through the array and check for converted info. + error = iConversionHandler->iStatus.Int(); + if( error == KErrNone ) + { + for( TInt i=0;i ( locationInfobase ); + CheckPositionConvertedInfoL( locationInfo ); + } + } + else if( !( error == KErrNotFound || error == KErrNotSupported ) ) + { + User::Leave( KErrArgument ); + } + + error = iConversionHandler1->iStatus.Int(); + if( error == KErrNone ) + { + for( TInt i=0;i ( locationInfobase ); + CheckPositionConvertedInfoL( locationInfo ); + } + } + else if( !( error == KErrNotFound || error == KErrNotSupported ) ) + { + User::Leave( KErrArgument ); + } + + + CleanupStack::Pop(4); // locationInfo1,locationInfoArray1,locationInfo,locationInfoArray + locationInfoArray.ResetAndDestroy(); + locationInfoArray1.ResetAndDestroy(); + CleanupStack::PopAndDestroy( 3 ); // locInfoConverter,locInfoConverter1,locMonitorSession + return KErrNone; + } + +// ----------------------------------------------------------------------------- +// CLocInfoConversionUnitTest::RLbsLocInfoConverter_ConvertLocationInfo10L +// This test case tests following unsuccessful conversion scenarios: +// 1. Conversion preference not supported by plugin. +// 2. Conversion request by specifying input area type same as requested type. +// ----------------------------------------------------------------------------- +// +TInt CLocInfoConversionUnitTest::RLbsLocInfoConverter_ConvertLocationInfo10L(CStifItemParser& /*aItem*/ ) + { + RLbsLocMonitorSession locMonitorSession; + TInt error = locMonitorSession.Connect(); + if( error != KErrNone ) + { + return error; + } + CleanupClosePushL( locMonitorSession ); + + // Here we need two subsessions + RLbsLocInfoConverter locInfoConverter; + CleanupClosePushL( locInfoConverter ); + locInfoConverter.OpenL( locMonitorSession ); + + TUid conversionModuleId = TUid::Uid( KDummyPluginId ); + /** + * Case 1: Users tries to request conversion by specifying conversion + * preference not supported by plugin. Example plugin doesnt + * support conversion using cache. + */ + CLbsLocationInfo* locationInfo = CreateLocationInfoObjectLC( ELbsAreaWcmdaCellInfoClass ); + + locInfoConverter.ConvertLocationInfoL( + *locationInfo,ELbsConversionCacheOnly, + ELbsConversionOutputPosition,conversionModuleId,iConversionHandler->iStatus ); + iConversionHandler->Start(); + + // This is just to block the control till the call back method is called. + // Code after this statement will be resumed when Stop on CActiveScheduler + // is called in the HandleLocationConversion method. + CActiveScheduler::Start(); + + // Check the converted values in both the conversions. + error = iConversionHandler->iStatus.Int(); + if( error != KErrNotSupported ) + { + User::Leave( KErrArgument ); + } + + /** + * Case 2: Users tries to request for coordinate info by specifying + * only coordinate info. + */ + locationInfo->ResetAreaInfo(); + AppendAreaInfoObjectToLocationInfoL( locationInfo,ELbsAreaPositionInfoClass ); + locInfoConverter.ConvertLocationInfoL( + *locationInfo,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId,iConversionHandler->iStatus ); + iConversionHandler->Start(); + // This is just to block the control till the call back method is called. + // Code after this statement will be resumed when Stop on CActiveScheduler + // is called in the HandleLocationConversion method. + CActiveScheduler::Start(); + + // Check the converted values in both the conversions. + error = iConversionHandler->iStatus.Int(); + if( error != KErrNotSupported ) + { + User::Leave( KErrArgument ); + } + + /** + * Case 3: Users tries to request for gsm cell info by specifying + * only gsm cell info. + */ + locationInfo->ResetAreaInfo(); + AppendAreaInfoObjectToLocationInfoL( locationInfo,ELbsAreaGsmCellInfoClass ); + locInfoConverter.ConvertLocationInfoL( + *locationInfo,ELbsConversionNotDefined, + ELbsConversionOutputGsm,conversionModuleId,iConversionHandler->iStatus ); + iConversionHandler->Start(); + // This is just to block the control till the call back method is called. + // Code after this statement will be resumed when Stop on CActiveScheduler + // is called in the HandleLocationConversion method. + CActiveScheduler::Start(); + + // Check the converted values in both the conversions. + error = iConversionHandler->iStatus.Int(); + if( error != KErrNotSupported ) + { + User::Leave( KErrArgument ); + } + + /** + * Case 4: Users tries to request for wcdma cell info by specifying + * only wcdma cell info. + */ + locationInfo->ResetAreaInfo(); + AppendAreaInfoObjectToLocationInfoL( locationInfo,ELbsAreaWcmdaCellInfoClass ); + locInfoConverter.ConvertLocationInfoL( + *locationInfo,ELbsConversionNotDefined, + ELbsConversionOutputWcdma,conversionModuleId,iConversionHandler->iStatus ); + iConversionHandler->Start(); + // This is just to block the control till the call back method is called. + // Code after this statement will be resumed when Stop on CActiveScheduler + // is called in the HandleLocationConversion method. + CActiveScheduler::Start(); + + // Check the converted values in both the conversions. + error = iConversionHandler->iStatus.Int(); + if( error != KErrNotSupported ) + { + User::Leave( KErrArgument ); + } + + /** + * Case 5: Users tries to request for wlan info by specifying + * only wlan info. + */ + locationInfo->ResetAreaInfo(); + AppendAreaInfoObjectToLocationInfoL( locationInfo,ELbsAreaWlanInfoClass ); + locInfoConverter.ConvertLocationInfoL( + *locationInfo,ELbsConversionNotDefined, + ELbsConversionOutputWlan,conversionModuleId,iConversionHandler->iStatus ); + iConversionHandler->Start(); + // This is just to block the control till the call back method is called. + // Code after this statement will be resumed when Stop on CActiveScheduler + // is called in the HandleLocationConversion method. + CActiveScheduler::Start(); + + // Check the converted values in both the conversions. + error = iConversionHandler->iStatus.Int(); + if( error != KErrNotSupported ) + { + User::Leave( KErrArgument ); + } + + CleanupStack::PopAndDestroy( 3 ); // locationInfo,locInfoConverter,locMonitorSession + return KErrNone; + } + + + +// ----------------------------------------------------------------------------- +// CLocInfoConversionUnitTest::RLbsLocInfoConverter_Cancel1L +// This test case tests the scenario when user tries to cancel the request before +// and after the conversion request complete for both single and batch conversion. +// ----------------------------------------------------------------------------- +// +TInt CLocInfoConversionUnitTest::RLbsLocInfoConverter_Cancel1L(CStifItemParser& /*aItem*/ ) + { + + RLbsLocMonitorSession locMonitorSession; + TInt error = locMonitorSession.Connect(); + if( error != KErrNone ) + { + return error; + } + CleanupClosePushL( locMonitorSession ); + RLbsLocInfoConverter locInfoConverter; + CleanupClosePushL( locInfoConverter ); + locInfoConverter.OpenL( locMonitorSession ); + + RPointerArray locationInfoArray; + CleanupClosePushL( locationInfoArray ); + + TUid conversionModuleId = TUid::Uid( KDummyPluginId ); + + // This can can be done for any area type here EGsm to ECoordinate conversion has + // been used. + + /** + * Case 1: Here single location information conversion is requested + * and cancel is called before the conversion completes. + */ + CLbsLocationInfo* locationInfo = CreateLocationInfoObjectLC( ELbsAreaGsmCellInfoClass ); + + locInfoConverter.ConvertLocationInfoL( + *locationInfo,ELbsConversionNotDefined,ELbsConversionOutputPosition + ,conversionModuleId,iConversionHandler->iStatus ); + iConversionHandler->Start(); + locInfoConverter.CancelConvertLocationInfo(); + iConversionHandler->Cancel(); + + error = iConversionHandler->iStatus.Int(); + // Request should be completed with the error code KErrCancel and + // location info should not have converted information. + if( error == KErrCancel ) + { + CheckPositionConvertedInfoL( locationInfo,ENegative ); + } + else + { + User::Leave( KErrArgument ); + } + + /** + * case 2: Here single location information conversion is requested + * and cancel is called after the conversion completes. + */ + locInfoConverter.ConvertLocationInfoL( + *locationInfo,ELbsConversionNotDefined,ELbsConversionOutputPosition + ,conversionModuleId,iConversionHandler->iStatus ); + iConversionHandler->Start(); + CActiveScheduler::Start(); + locInfoConverter.CancelConvertLocationInfo(); + iConversionHandler->Cancel(); + + error = iConversionHandler->iStatus.Int(); + // Request should be completed with the error code KErrNone and + // location info should have converted information. + if( error == KErrNone ) + { + CheckPositionConvertedInfoL( locationInfo ); + } + else + { + User::Leave( KErrArgument ); + } + + // case 3: Here mutiple location information conversion is + // requested and cancel is called before the conversion completes. + + CLbsLocationInfo* locationInfo1 = CreateLocationInfoObjectLC( ELbsAreaGsmCellInfoClass ); + + // We had requested for coordinate info, hence we need to clear it before + // we use it as input for next conversion. + locationInfo->ResetAreaInfo( CLbsLocationInfo::ELbsPosInfo ); + locationInfoArray.Append( locationInfo ); + + locationInfoArray.Append( locationInfo1 ); + + locInfoConverter.ConvertLocationInfoL( + locationInfoArray,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId,iConversionHandler->iStatus ); + iConversionHandler->Start(); + locInfoConverter.CancelConvertLocationInfo(); + iConversionHandler->Cancel(); + + // Request should be completed with the error code KErrCancel and + // location info should not have converted information. + error = iConversionHandler->iStatus.Int(); + + if( error == KErrCancel ) + { + for( TInt i=0;i ( locationInfobase ); + CheckPositionConvertedInfoL( locationInfo,ENegative ); + } + } + else + { + User::Leave( KErrArgument ); + } + + + /** + * case 4: Here mutiple location information conversion is + * requested and cancel is called after the conversion completes. + */ + + locInfoConverter.ConvertLocationInfoL( + locationInfoArray,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId,iConversionHandler->iStatus ); + iConversionHandler->Start(); + CActiveScheduler::Start(); + locInfoConverter.CancelConvertLocationInfo(); + iConversionHandler->Cancel(); + + // Request should be completed with the error code KErrNone and + // location info should have converted information. + error = iConversionHandler->iStatus.Int(); + + if( error == KErrNone ) + { + for( TInt i=0;i ( locationInfobase ); + CheckPositionConvertedInfoL( locationInfo ); + } + } + else + { + User::Leave( KErrArgument ); + } + + CleanupStack::Pop( 3 ); // locationInfo,locationInfo1,locationInfoArray + locationInfoArray.ResetAndDestroy(); + CleanupStack::PopAndDestroy( 2 ); // locInfoConverter,locMonitorSession + return KErrNone; + } + + + +// ----------------------------------------------------------------------------- +// CLocInfoConversionUnitTest::RLbsLocInfoConverter_Cancel2L +// This test case tests the scenario when user tries to cancel the conversion request +// from the different subsession for both single and multiple conversion. +// ----------------------------------------------------------------------------- +// +TInt CLocInfoConversionUnitTest::RLbsLocInfoConverter_Cancel2L(CStifItemParser& /*aItem*/ ) + { + + RLbsLocMonitorSession locMonitorSession; + TInt error = locMonitorSession.Connect(); + if( error != KErrNone ) + { + return error; + } + CleanupClosePushL( locMonitorSession ); + + // Here we need to subsessions. + RLbsLocInfoConverter locInfoConverter,locInfoConverter1; + CleanupClosePushL( locInfoConverter ); + locInfoConverter.OpenL( locMonitorSession ); + + CleanupClosePushL( locInfoConverter1 ); + locInfoConverter1.OpenL( locMonitorSession ); + + + RPointerArray locationInfoArray; + CleanupClosePushL( locationInfoArray ); + + TUid conversionModuleId = TUid::Uid( KDummyPluginId ); + + // This can can be done for any area type here EGsm to ECoordinate conversion has + // been used. + + /** + * Case 1: Here single location information conversion is + * requested and cancel is called the different subsession. + */ + + CLbsLocationInfo* locationInfo = CreateLocationInfoObjectLC( ELbsAreaGsmCellInfoClass ); + + locInfoConverter.ConvertLocationInfoL( + *locationInfo,ELbsConversionNotDefined,ELbsConversionOutputPosition + ,conversionModuleId,iConversionHandler->iStatus ); + iConversionHandler->Start(); + locInfoConverter1.CancelConvertLocationInfo(); + CActiveScheduler::Start(); + + error = iConversionHandler->iStatus.Int(); + // Request should be completed with the error code KErrNone and + // location info should have converted information. + if( error == KErrNone ) + { + CheckPositionConvertedInfoL( locationInfo ); + } + else + { + User::Leave( KErrArgument ); + } + + /** + * Case 2: Here mutiple location information conversion is requested + * and cancel is called from the different subsession. + */ + CLbsLocationInfo* locationInfo1 = CreateLocationInfoObjectLC( ELbsAreaGsmCellInfoClass ); + + // We had requested for coordinate info, hence we need to clear it before + // we use it as input for next conversion. + locationInfo->ResetAreaInfo( CLbsLocationInfo::ELbsPosInfo ); + locationInfoArray.Append( locationInfo ); + + locationInfoArray.Append( locationInfo1 ); + + locInfoConverter.ConvertLocationInfoL( + locationInfoArray,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId,iConversionHandler->iStatus ); + iConversionHandler->Start(); + locInfoConverter1.CancelConvertLocationInfo(); + CActiveScheduler::Start(); + + // Request should be completed with the error code KErrNone and + // location info should have converted information. + error = iConversionHandler->iStatus.Int(); + + if( error == KErrNone ) + { + for( TInt i=0;i ( locationInfobase ); + CheckPositionConvertedInfoL( locationInfo ); + } + } + else + { + User::Leave( KErrArgument ); + } + CleanupStack::Pop( 3 ); // locationInfo,locationInfo1,locationInfoArray + locationInfoArray.ResetAndDestroy(); + CleanupStack::PopAndDestroy( 3 ); // locInfoConverter,locInfoConverter1,locMonitorSession + return KErrNone; + } + +// ----------------------------------------------------------------------------- +// CLocInfoConversionUnitTest::RLbsLocInfoConverter_Cancel3L +// This test case tests the scenario when user tries to request two conversion +// using two subsessions simultaneously specifying same plugin and we cancel one request +// of two requests. +// ----------------------------------------------------------------------------- +// +TInt CLocInfoConversionUnitTest::RLbsLocInfoConverter_Cancel3L(CStifItemParser& /*aItem*/ ) + { + RLbsLocMonitorSession locMonitorSession; + TInt error = locMonitorSession.Connect(); + if( error != KErrNone ) + { + return error; + } + CleanupClosePushL( locMonitorSession ); + + // Here we need to open two subsessions. + RLbsLocInfoConverter locInfoConverter,locInfoConverter1; + CleanupClosePushL( locInfoConverter ); + locInfoConverter.OpenL( locMonitorSession ); + + CleanupClosePushL( locInfoConverter1 ); + locInfoConverter1.OpenL( locMonitorSession ); + + RPointerArray locationInfoArray; + CleanupClosePushL( locationInfoArray ); + + RPointerArray locationInfoArray1; + CleanupClosePushL( locationInfoArray1 ); + + TUid conversionModuleId = TUid::Uid( KDummyPluginId ); + + /** + * Case 1: Users tries to request 2 simultaneous single conversion + * using 2 subsession specifying same conversion uid and + * anyone conversion request is cancelled. + */ + + // Here type of area input doesnt matter. + CLbsLocationInfo* locationInfo = CreateLocationInfoObjectLC( ELbsAreaGsmCellInfoClass ); + + CLbsLocationInfo* locationInfo1 = CreateLocationInfoObjectLC( ELbsAreaGsmCellInfoClass ); + + locInfoConverter.ConvertLocationInfoL( + *locationInfo,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId,iConversionHandler->iStatus ); + iConversionHandler->Start(); + + locInfoConverter1.ConvertLocationInfoL( + *locationInfo1,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId,iConversionHandler1->iStatus ); + iConversionHandler1->Start(); + + // Here first request is called. + locInfoConverter.CancelConvertLocationInfo(); + + // This is just to block the control till the call back method is called. + // Code after this statement will be resumed when Stop on CActiveScheduler + // is called in the HandleLocationConversion method. + CActiveScheduler::Start(); + + // Here we need to wait till both the request completes.Hence we need to block it once again + // till the 2nd request completes. + if( iConversionHandler->iStatus.Int() == KRequestPending || + iConversionHandler1->iStatus.Int() == KRequestPending ) + { + CActiveScheduler::Start(); + } + + // Check the converted values in both the conversions. + error = iConversionHandler->iStatus.Int(); + if( error == KErrCancel ) + { + CheckPositionConvertedInfoL( locationInfo,ENegative ); + } + else + { + User::Leave( KErrArgument ); + } + + error = iConversionHandler1->iStatus.Int(); + if( error == KErrNone ) + { + CheckPositionConvertedInfoL( locationInfo1 ); + } + else + { + User::Leave( KErrArgument ); + } + + /** + * Case 2: Users tries to request 2 simultaneous bulk conversion + * using 2 subsession specifying same conversion uid and + * any one conversion request is cancelled. + */ + + // Before we append the location info object to the info array, + // we need to clear the converted info in each object. + locationInfo->ResetAreaInfo( CLbsLocationInfo::ELbsPosInfo ); + locationInfo1->ResetAreaInfo( CLbsLocationInfo::ELbsPosInfo ); + + locationInfoArray.Append( locationInfo ); + locationInfoArray1.Append( locationInfo1 ); + + locInfoConverter.ConvertLocationInfoL( + locationInfoArray,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId,iConversionHandler->iStatus ); + iConversionHandler->Start(); + + locInfoConverter1.ConvertLocationInfoL( + locationInfoArray1,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId,iConversionHandler1->iStatus ); + iConversionHandler1->Start(); + + // Here second request is called. + locInfoConverter1.CancelConvertLocationInfo(); + + // This is just to block the control till the call back method is called. + // Code after this statement will be resumed when Stop on CActiveScheduler + // is called in the HandleLocationConversion method. + CActiveScheduler::Start(); + + // Here we need to wait till both the request completes.Hence we need to block it once again + // till the 2nd request completes. + if( iConversionHandler->iStatus.Int() == KRequestPending || + iConversionHandler1->iStatus.Int() == KRequestPending ) + { + CActiveScheduler::Start(); + } + + // Check the converted values in both the conversions. + // Iterate through the array and check for converted info. + error = iConversionHandler->iStatus.Int(); + if( error == KErrNone ) + { + for( TInt i=0;i ( locationInfobase ); + CheckPositionConvertedInfoL( locationInfo ); + } + } + else + { + User::Leave( KErrArgument ); + } + + error = iConversionHandler1->iStatus.Int(); + if( error == KErrCancel ) + { + for( TInt i=0;i ( locationInfobase ); + CheckPositionConvertedInfoL( locationInfo,ENegative ); + } + } + else + { + User::Leave( KErrArgument ); + } + + CleanupStack::Pop(4); // locationInfo1,locationInfoArray1,locationInfo,locationInfoArray + locationInfoArray.ResetAndDestroy(); + locationInfoArray1.ResetAndDestroy(); + CleanupStack::PopAndDestroy( 3 ); // locInfoConverter,locInfoConverter1,locMonitorSession + return KErrNone; + } + +// ----------------------------------------------------------------------------- +// CLocInfoConversionUnitTest::RLbsLocInfoConverter_Cancel4L +// This test case tests the scenario when user tries to request two conversion +// using two subsessions simultaneously specifying different plugin. +// ----------------------------------------------------------------------------- +// +TInt CLocInfoConversionUnitTest::RLbsLocInfoConverter_Cancel4L(CStifItemParser& /*aItem*/ ) + { + RLbsLocMonitorSession locMonitorSession; + TInt error = locMonitorSession.Connect(); + if( error != KErrNone ) + { + return error; + } + CleanupClosePushL( locMonitorSession ); + + // Here we need two subsessions + RLbsLocInfoConverter locInfoConverter,locInfoConverter1; + CleanupClosePushL( locInfoConverter ); + locInfoConverter.OpenL( locMonitorSession ); + + CleanupClosePushL( locInfoConverter1 ); + locInfoConverter1.OpenL( locMonitorSession ); + + RPointerArray locationInfoArray; + CleanupClosePushL( locationInfoArray ); + + RPointerArray locationInfoArray1; + CleanupClosePushL( locationInfoArray1 ); + + TUid conversionModuleId1 = TUid::Uid( KDummyPluginId ); + TUid conversionModuleId2 = TUid::Uid( KSuplPluginId ); + + /** + * Case 1: Users tries to request 2 simultaneous single conversion + * using 2 subsession specifying different conversion uid + * any one request is cancelled. + */ + + CLbsLocationInfo* locationInfo = CreateLocationInfoObjectLC( ELbsAreaWcmdaCellInfoClass ); + + CLbsLocationInfo* locationInfo1 = CreateLocationInfoObjectLC( ELbsAreaWlanInfoClass ); + + locInfoConverter.ConvertLocationInfoL( + *locationInfo,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId1,iConversionHandler->iStatus ); + iConversionHandler->Start(); + + + locInfoConverter1.ConvertLocationInfoL( + *locationInfo1,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId2,iConversionHandler1->iStatus ); + iConversionHandler1->Start(); + + // Here first request is cancelled. + locInfoConverter.CancelConvertLocationInfo(); + + // This is just to block the control till the call back method is called. + // Code after this statement will be resumed when Stop on CActiveScheduler + // is called in the HandleLocationConversion method. + CActiveScheduler::Start(); + + // Here we need to wait till both the request completes.Hence we need to block it once again + // till the 2nd request completes. + if( iConversionHandler->iStatus.Int() == KRequestPending || + iConversionHandler1->iStatus.Int() == KRequestPending ) + { + CActiveScheduler::Start(); + } + + // Check the converted values in both the conversions. + error = iConversionHandler->iStatus.Int(); + if( error == KErrCancel ) + { + CheckPositionConvertedInfoL( locationInfo,ENegative ); + } + else if( !( error == KErrNotFound || error == KErrNotSupported ) ) + { + User::Leave( KErrArgument ); + } + + error = iConversionHandler1->iStatus.Int(); + if( error == KErrNone ) + { + CheckPositionConvertedInfoL( locationInfo1 ); + } + else if( !( error == KErrNotFound || error == KErrNotSupported ) ) + { + User::Leave( KErrArgument ); + } + + /** + * Case 2: Users tries to request 2 simultaneous bulk conversion + * using 2 subsession specifying same conversion uid and + * one conversion request is cancelled. + */ + + // Before we append the location info object to the info array, + // we need to clear the converted info in each object. + locationInfo->ResetAreaInfo( CLbsLocationInfo::ELbsPosInfo ); + locationInfo1->ResetAreaInfo( CLbsLocationInfo::ELbsPosInfo ); + + locationInfoArray.Append( locationInfo ); + locationInfoArray1.Append( locationInfo1 ); + + locInfoConverter.ConvertLocationInfoL( + locationInfoArray,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId1,iConversionHandler->iStatus ); + iConversionHandler->Start(); + + locInfoConverter1.ConvertLocationInfoL( + locationInfoArray1,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId2,iConversionHandler1->iStatus ); + iConversionHandler1->Start(); + + // Here we cancel 2nd request + locInfoConverter1.CancelConvertLocationInfo(); + + // This is just to block the control till the call back method is called. + // Code after this statement will be resumed when Stop on CActiveScheduler + // is called in the HandleLocationConversion method. + CActiveScheduler::Start(); + + // Here we need to wait till both the request completes.Hence we need to block it once again + // till the 2nd request completes. + if( iConversionHandler->iStatus.Int() == KRequestPending || + iConversionHandler1->iStatus.Int() == KRequestPending ) + { + CActiveScheduler::Start(); + } + + // Check the converted values in both the conversions. + // Iterate through the array and check for converted info. + error = iConversionHandler->iStatus.Int(); + if( error == KErrNone ) + { + for( TInt i=0;i ( locationInfobase ); + CheckPositionConvertedInfoL( locationInfo ); + } + } + else if( !( error == KErrNotFound || error == KErrNotSupported ) ) + { + User::Leave( KErrArgument ); + } + + error = iConversionHandler1->iStatus.Int(); + if( error == KErrCancel ) + { + for( TInt i=0;i ( locationInfobase ); + CheckPositionConvertedInfoL( locationInfo,ENegative ); + } + } + else if( !( error == KErrNotFound || error == KErrNotSupported ) ) + { + User::Leave( KErrArgument ); + } + + + CleanupStack::Pop(4); // locationInfo1,locationInfoArray1,locationInfo,locationInfoArray + locationInfoArray.ResetAndDestroy(); + locationInfoArray1.ResetAndDestroy(); + CleanupStack::PopAndDestroy( 3 ); // locInfoConverter,locInfoConverter1,locMonitorSession + return KErrNone; + } + + +// Helper methods + +// ----------------------------------------------------------------------------- +// CLocInfoConversionUnitTest::CreatePositionObjectLC +// ----------------------------------------------------------------------------- +// +CLbsPositionInfo* CLocInfoConversionUnitTest::CreatePositionInfoObjectLC() + { + TLocality locality; + locality.SetCoordinate( 62.5285,23.9385 ); + locality.SetAccuracy( 100,0.0 ); + CLbsPositionInfo* positionInfo = CLbsPositionInfo::NewL( locality ); + CleanupStack::PushL( positionInfo ); + return positionInfo; + } + +// ----------------------------------------------------------------------------- +// CLocInfoConversionUnitTest::CreateGsmCellInfoObjectLC +// ----------------------------------------------------------------------------- +// +CLbsGsmCellInfo* CLocInfoConversionUnitTest::CreateGsmCellInfoObjectLC() + { + CLbsGsmCellInfo* gsmCellInfo = CLbsGsmCellInfo::NewL( 100,101,102,103); + CleanupStack::PushL( gsmCellInfo ); + return gsmCellInfo; + } + +// ----------------------------------------------------------------------------- +// CLocInfoConversionUnitTest::CreateWcdmaCellInfoObjectLC +// ----------------------------------------------------------------------------- +// +CLbsWcdmaCellInfo* CLocInfoConversionUnitTest::CreateWcdmaCellInfoObjectLC() + { + CLbsWcdmaCellInfo* wcdmaCellInfo = CLbsWcdmaCellInfo::NewL( 100,101,102 ); + CleanupStack::PushL( wcdmaCellInfo ); + return wcdmaCellInfo; + } + +// ----------------------------------------------------------------------------- +// CLocInfoConversionUnitTest::CreateWlanInfoObjectLC +// ----------------------------------------------------------------------------- +// +CLbsWlanInfo* CLocInfoConversionUnitTest::CreateWlanInfoObjectLC() + { + TLbsWlanMacAddress macAddress(_L8("10.0.1")); + CLbsWlanInfo* wlanInfo = CLbsWlanInfo::NewL( macAddress,10.1 ); + CleanupStack::PushL( wlanInfo ); + return wlanInfo; + } + + +// ----------------------------------------------------------------------------- +// CLocInfoConversionUnitTest::CreateLocationInfoObjectLC +// ----------------------------------------------------------------------------- +// +CLbsLocationInfo* CLocInfoConversionUnitTest::CreateLocationInfoObjectLC( + TLbsAreaInfoClassType aAreaType ) + { + CLbsLocationInfo* locationInfo = CLbsLocationInfo::NewL(); + CleanupStack::PushL( locationInfo ); + AppendAreaInfoObjectToLocationInfoL( locationInfo,aAreaType ); + return locationInfo; + } + +// ----------------------------------------------------------------------------- +// CLocInfoConversionUnitTest::AppendAreaInfoObjectToLocationInfoL +// ----------------------------------------------------------------------------- +// +void CLocInfoConversionUnitTest::AppendAreaInfoObjectToLocationInfoL( + CLbsLocationInfo* aLocationInfo, + TLbsAreaInfoClassType aAreaType ) + { + switch( aAreaType ) + { + case ELbsAreaPositionInfoClass: + CLbsPositionInfo* positionInfo = NULL; + positionInfo = CreatePositionInfoObjectLC(); + aLocationInfo->AddAreaInfoL( positionInfo ); + CleanupStack::Pop( positionInfo ); + break; + + case ELbsAreaGsmCellInfoClass: + CLbsGsmCellInfo* gsmCellInfo = NULL; + gsmCellInfo = CreateGsmCellInfoObjectLC(); + aLocationInfo->AddAreaInfoL( gsmCellInfo ); + CleanupStack::Pop( gsmCellInfo ); + break; + + case ELbsAreaWcmdaCellInfoClass: + CLbsWcdmaCellInfo* wcdmaCellInfo = NULL; + wcdmaCellInfo = CreateWcdmaCellInfoObjectLC(); + aLocationInfo->AddAreaInfoL( wcdmaCellInfo ); + CleanupStack::Pop( wcdmaCellInfo ); + break; + + case ELbsAreaWlanInfoClass: + CLbsWlanInfo* wlanInfo = NULL; + wlanInfo = CreateWlanInfoObjectLC(); + aLocationInfo->AddAreaInfoL( wlanInfo ); + CleanupStack::Pop( wlanInfo ); + break; + + default: + break; + } + } + +// ----------------------------------------------------------------------------- +// CLocInfoConversionUnitTest::CheckPositionConvertedInfoL +// ----------------------------------------------------------------------------- +// +void CLocInfoConversionUnitTest::CheckPositionConvertedInfoL( CLbsLocationInfo* + aLocationInfo, + TTestType + aTestType ) + { + RLbsAreaInfoBaseArray areaInfoArray; + aLocationInfo->GetAreaInfo( areaInfoArray,CLbsLocationInfo::ELbsPosInfo ); + TInt count = areaInfoArray.Count(); + areaInfoArray.Reset(); + if( aTestType == EPositive ) + { + if( !count ) + { + User::Leave( KErrArgument ); + } + } + else + { + if( count ) + { + User::Leave( KErrArgument ); + } + } + } + + +// ----------------------------------------------------------------------------- +// CLocInfoConversionUnitTest::CheckGsmCellConvertedInfoL +// ----------------------------------------------------------------------------- +// +void CLocInfoConversionUnitTest::CheckGsmCellConvertedInfoL( CLbsLocationInfo* + aLocationInfo, + TTestType + aTestType ) + { + RLbsAreaInfoBaseArray areaInfoArray; + aLocationInfo->GetAreaInfo( areaInfoArray,CLbsLocationInfo::ELbsGsmInfo ); + TInt count = areaInfoArray.Count(); + areaInfoArray.Reset(); + if( aTestType == EPositive ) + { + if( !count ) + { + User::Leave( KErrArgument ); + } + } + else + { + if( count ) + { + User::Leave( KErrArgument ); + } + } + } + +// ----------------------------------------------------------------------------- +// CLocInfoConversionUnitTest::CheckWcdmaCellConvertedInfoL +// ----------------------------------------------------------------------------- +// +void CLocInfoConversionUnitTest::CheckWcdmaCellConvertedInfoL( CLbsLocationInfo* + aLocationInfo, + TTestType + aTestType ) + { + RLbsAreaInfoBaseArray areaInfoArray; + aLocationInfo->GetAreaInfo( areaInfoArray,CLbsLocationInfo::ELbsWcdmaInfo ); + TInt count = areaInfoArray.Count(); + areaInfoArray.Reset(); + if( aTestType == EPositive ) + { + if( !count ) + { + User::Leave( KErrArgument ); + } + } + else + { + if( count ) + { + User::Leave( KErrArgument ); + } + } + } + +// ----------------------------------------------------------------------------- +// CLocInfoConversionUnitTest::CheckWlanConvertedInfoL +// ----------------------------------------------------------------------------- +// +void CLocInfoConversionUnitTest::CheckWlanConvertedInfoL( CLbsLocationInfo* + aLocationInfo, + TTestType + aTestType ) + { + RLbsAreaInfoBaseArray areaInfoArray; + aLocationInfo->GetAreaInfo( areaInfoArray,CLbsLocationInfo::ELbsWlanInfo ); + TInt count = areaInfoArray.Count(); + areaInfoArray.ResetAndDestroy(); + if( aTestType == EPositive ) + { + if( !count ) + { + User::Leave( KErrArgument ); + } + } + else + { + if( count ) + { + User::Leave( KErrArgument ); + } + } + } +// [End of File] diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/Te_locationinfoconverter/bmarm/Te_locationinfoconverterU.DEF --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/Te_locationinfoconverter/bmarm/Te_locationinfoconverterU.DEF Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,3 @@ +EXPORTS + LibEntryL__FR13CTestModuleIf @ 1 NONAME R3UNUSED ; LibEntryL(CTestModuleIf &) + diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/Te_locationinfoconverter/bwins/Te_locationinfoconverterU.DEF --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/Te_locationinfoconverter/bwins/Te_locationinfoconverterU.DEF Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,3 @@ +EXPORTS + ?LibEntryL@@YAPAVCScriptBase@@AAVCTestModuleIf@@@Z @ 1 NONAME ; class CScriptBase * __cdecl LibEntryL(class CTestModuleIf &) + diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/Te_locationinfoconverter/conf/Te_locationinfoconverter.cfg --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/Te_locationinfoconverter/conf/Te_locationinfoconverter.cfg Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,2037 @@ +[Define] +PrefsUnspecified 0 +LocalCacheOnly 1 +ConnectionSilent 2 +ConnectionPrompt 4 +ConvertionNotDefined 0 +Coordinate 1 +Gsm 2 +Wcdma 4 +Wlan 8 +GsmAndWcdma 3 +GsmAndWlan 5 +WcdmaAndWlan 6 +KErrArgument -6 +KErrCancel -3 +[Enddefine] +[Test] +title GetAllLocationInfo +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetCoordinateInfo 1 LATITUDE= 100 LONGITUDE= 200 ALTITUDE= 300 HA= 20 VA= 30 +foobar SetGSMCellInfo 2 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 TIMINGADVANCE= 40 NEIGHBOURCELLS= 2 ARFCN= 3 CCODE= 10 NRXLEV=1 ARFCN= 3 CCODE= 10 NRXLEV=1 +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 SCODE= 15 NEIGHBOURCELLS= 2 NCELLID= 44 NSCODE= 15 NCELLID= 20 NSCODE= 44 +foobar SetWLanInfo 1 MACID= 100 SIGNAL= 200 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.1.1 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 1 COUNTRYCODE= 404 NETWORKCODE= 49 LOCATIONCODE= 16 CELLID= 7141 +foobar AddLocationInfo +foobar ConvertLocationInfo ConnectionPrompt Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.1.3 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 1 COUNTRYCODE= 0 NETWORKCODE= 0 LOCATIONCODE= 0 CELLID= 0 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.1.4 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 1 COUNTRYCODE= 999 NETWORKCODE= 999 LOCATIONCODE= 65535 CELLID= 65535 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.1.5 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 1 COUNTRYCODE= -1 NETWORKCODE= 0 LOCATIONCODE= 0 CELLID= 0 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.1.6 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= -1 LOCATIONCODE= 0 CELLID= 0 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.1.7 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= -1 CELLID= 0 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.1.8 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= -1 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.1.9 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 1 COUNTRYCODE= 1000 NETWORKCODE= 0 LOCATIONCODE= 0 CELLID= 0 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.1.10 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 1000 LOCATIONCODE= 0 CELLID= 0 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.1.11 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 65536 CELLID= 0 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.1.12 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 65536 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.1.13 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 2 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.2 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 2 COUNTRYCODE= 100 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.3 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 2 COUNTRYCODE= 999 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.4 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 2 COUNTRYCODE= 0 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.5 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 2 COUNTRYCODE= 1000 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.6 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 2 COUNTRYCODE= -1 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.7 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 2 COUNTRYCODE= 100 NETWORKCODE= 200 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.8 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 2 COUNTRYCODE= 100 NETWORKCODE= 999 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.9 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 2 COUNTRYCODE= 100 NETWORKCODE= 0 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.10 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 2 COUNTRYCODE= 100 NETWORKCODE= 1000 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.11 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 2 COUNTRYCODE= 100 NETWORKCODE= -1 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.12 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 2 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.13 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 2 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 65535 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.14 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 2 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 0 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.15 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 2 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 65536 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.16 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 2 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= -1 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.17 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 2 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 65535 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.18 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 2 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 0 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.19 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 2 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 65536 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.20 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 2 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= -1 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.21 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 2 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 TIMINGADVANCE= 255 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.22 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 2 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 TIMINGADVANCE= 0 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.23 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 2 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 TIMINGADVANCE= -1 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.24 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 2 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 TIMINGADVANCE= 256 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.25 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 +foobar AddLocationInfo +foobar ConvertLocationInfo LocalCacheOnly Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.26 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 +foobar AddLocationInfo +foobar ConvertLocationInfo ConnectionSilent Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.27 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 +foobar AddLocationInfo +foobar ConvertLocationInfo ConnectionPrompt Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.28.1 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.28.1.3 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 1 COUNTRYCODE= 0 NETWORKCODE= 0 CELLID= 0 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.28.1.4 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 1 COUNTRYCODE= 999 NETWORKCODE= 999 CELLID= 65535 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.28.1.5 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 1 COUNTRYCODE= -1 NETWORKCODE= 200 CELLID= 300 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.28.1.6 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= -1 CELLID= 300 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.28.1.7 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= -1 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.28.1.8 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 1 COUNTRYCODE= 1000 NETWORKCODE= 200 CELLID= 300 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.28.1.9 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 1000 CELLID= 300 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.28.1.10 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 268435456 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.28.2 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 2 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.29 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 2 COUNTRYCODE= 100 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.30 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 2 COUNTRYCODE= 999 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.31 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 2 COUNTRYCODE= 0 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.32 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 2 COUNTRYCODE= 1000 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.33 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 2 COUNTRYCODE= -1 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.34 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 2 COUNTRYCODE= 100 NETWORKCODE= 200 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.35 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 2 COUNTRYCODE= 100 NETWORKCODE= 999 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.36 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 2 COUNTRYCODE= 100 NETWORKCODE= 0 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.37 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 2 COUNTRYCODE= 100 NETWORKCODE= 1000 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.38 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 2 COUNTRYCODE= 100 NETWORKCODE= -1 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.39 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 2 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 65535 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.40 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 2 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 0 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.41 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 2 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 268435456 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.42 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 2 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= -1 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.43 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 2 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 SCODE= 511 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.44 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 2 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 SCODE= 0 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.45 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 2 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 SCODE= 512 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.46 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 2 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 SCODE= -1 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.47.1 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 2 NETWORKCODE= 200 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.47.2 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 2 COUNTRYCODE= 100 LOCATIONCODE= 300 CELLID= 30 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.47.3 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 2 COUNTRYCODE= 100 NETWORKCODE= 300 CELLID= 30 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.49.1 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 1 NETWORKCODE= 200 CELLID= 30 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.49.2 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 1 COUNTRYCODE= 200 CELLID= 30 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.51 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 2 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 +foobar AddLocationInfo +foobar ConvertLocationInfo LocalCacheOnly Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.52 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 2 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 +foobar AddLocationInfo +foobar ConvertLocationInfo ConnectionSilent Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.1.53 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 2 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 +foobar AddLocationInfo +foobar ConvertLocationInfo ConnectionPrompt Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.2.1 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 NEIGHBOURCELLS= 1 CCODE= 0 NRXLEV=1 ARFCN= 3 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.2.2 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 NEIGHBOURCELLS= 1 CCODE= 63 NRXLEV=1 ARFCN= 3 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.2.3 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 NEIGHBOURCELLS= 2 ARFCN= 3 CCODE= 10 NRXLEV=1 ARFCN= 3 CCODE= 10 NRXLEV=1 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.2.4 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 NEIGHBOURCELLS= 1 CCODE= -1 NRXLEV=1 ARFCN= 3 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.2.5 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 NEIGHBOURCELLS= 1 CCODE= 64 NRXLEV=1 ARFCN= 3 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.2.6 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 NEIGHBOURCELLS= 1 CCODE= 63 NRXLEV=1 ARFCN= 0 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.2.7 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 NEIGHBOURCELLS= 1 CCODE= 63 NRXLEV=1 ARFCN= 1023 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.2.8 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 NEIGHBOURCELLS= 1 CCODE= 63 NRXLEV=1 ARFCN= -1 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.2.9 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 NEIGHBOURCELLS= 1 CCODE= 63 NRXLEV=1 ARFCN= 1024 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.2.10 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 NEIGHBOURCELLS= 1 CCODE= 63 NRXLEV= 0 ARFCN= 1023 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.2.11 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 NEIGHBOURCELLS= 1 CCODE= 63 NRXLEV= 63 ARFCN= 1023 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.2.12 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 NEIGHBOURCELLS= 1 CCODE= 63 NRXLEV= -1 ARFCN= 1023 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.2.13 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 NEIGHBOURCELLS= 1 CCODE= 63 NRXLEV= 64 ARFCN= 1023 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.2.14 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 NEIGHBOURCELLS= 1 NCELLID= 0 NSCODE= 15 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.2.15 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 NEIGHBOURCELLS= 1 NCELLID= 268435455 NSCODE= 15 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.2.16 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 SCODE= 15 NEIGHBOURCELLS= 2 NCELLID= 44 NSCODE= 15 NCELLID= 20 NSCODE= 44 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.2.17 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 NEIGHBOURCELLS= 1 NCELLID= -1 NSCODE= 15 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.2.18 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 NEIGHBOURCELLS= 1 NCELLID= 268435456 NSCODE= 15 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.2.19 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 NEIGHBOURCELLS= 1 NCELLID= 0 NSCODE= 0 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.2.20 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 NEIGHBOURCELLS= 1 NCELLID= 268435455 NSCODE= 511 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.2.21 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 NEIGHBOURCELLS= 1 NCELLID= 0 NSCODE= -1 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.2.22 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 NEIGHBOURCELLS= 1 NCELLID= 268435455 NSCODE= 512 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.3.1.1 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWLanInfo 1 MACID= 100000 SIGNAL= 3 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.3.2.1 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWLanInfo 2 MACID= 100000 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.3.2.2 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWLanInfo 2 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.3.4 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWLanInfo 2 MACID= 100000 SIGNAL= 3 +foobar AddLocationInfo +foobar ConvertLocationInfo LocalCacheOnly Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.3.5 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWLanInfo 2 MACID= 100000 SIGNAL= 3 +foobar AddLocationInfo +foobar ConvertLocationInfo ConnectionSilent Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.3.6 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWLanInfo 2 MACID= 100000 SIGNAL= 3 +foobar AddLocationInfo +foobar ConvertLocationInfo ConnectionPrompt Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.3.7 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWLanInfo 2 MACID= 100000 SIGNAL= 0 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.3.8 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWLanInfo 2 MACID= 100000 SIGNAL= 255 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.3.9 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWLanInfo 2 MACID= 100000 SIGNAL= -1 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.3.10 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWLanInfo 2 MACID= 100000 SIGNAL= 256 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.4.1 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 +allownextresult KErrCancel +foobar Misc 1 +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.4.2 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWLanInfo 2 MACID= 100000 SIGNAL= 255 +allownextresult KErrCancel +foobar Misc 1 +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.4.3 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 +foobar Misc 2 +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.4.4 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 +foobar Misc 3 +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.5.1 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 +foobar Misc 4 +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.4.5.2 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.5.1.1 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 +foobar AddLocationInfo +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 NEIGHBOURCELLS= 1 CCODE= 63 NRXLEV= 63 ARFCN= 1023 +foobar AddLocationInfo +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 +foobar AddLocationInfo +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 TIMINGADVANCE= 40 NEIGHBOURCELLS= 1 CCODE= 63 NRXLEV= 63 ARFCN= 1023 +foobar AddLocationInfo +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate 2 +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.5.1.2 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 +foobar AddLocationInfo +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 NEIGHBOURCELLS= 1 NCELLID= 268435455 NSCODE= 511 +foobar AddLocationInfo +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 +foobar AddLocationInfo +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 SCODE= 511 NEIGHBOURCELLS= 1 NCELLID= 268435455 NSCODE= 511 +foobar AddLocationInfo +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate 2 +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.5.1.3 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 +foobar AddLocationInfo 10 +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 NEIGHBOURCELLS= 1 CCODE= 63 NRXLEV= 63 ARFCN= 1023 +foobar AddLocationInfo 10 +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 +foobar AddLocationInfo 10 +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 NEIGHBOURCELLS= 1 CCODE= 63 NRXLEV= 63 ARFCN= 1023 +foobar AddLocationInfo 10 +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 +foobar AddLocationInfo 10 +foobar ConvertLocationInfo PrefsUnspecified Coordinate 2 +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.5.1.4 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 +foobar AddLocationInfo 10 +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 NEIGHBOURCELLS= 1 NCELLID= 268435455 NSCODE= 511 +foobar AddLocationInfo 10 +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 +foobar AddLocationInfo 10 +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 NEIGHBOURCELLS= 1 NCELLID= 268435455 NSCODE= 511 +foobar AddLocationInfo 10 +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 +foobar AddLocationInfo 10 +foobar ConvertLocationInfo PrefsUnspecified Coordinate 2 +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.5.1.5 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate 2 +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.5.1.6 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate 2 +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.5.1.7 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate 2 +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.5.1.8 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate 2 +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.5.1.9 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 +foobar AddLocationInfo +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 NEIGHBOURCELLS= 1 CCODE= 63 NRXLEV= 63 ARFCN= 1023 +foobar AddLocationInfo +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 +foobar AddLocationInfo +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 NEIGHBOURCELLS= 1 CCODE= 63 NRXLEV= 63 ARFCN= 1023 +foobar AddLocationInfo +foobar SetGSMCellInfo 1 COUNTRYCODE= 1000 NETWORKCODE= -1 LOCATIONCODE= 300 CELLID= 30 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate 2 +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.5.1.10 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 +foobar AddLocationInfo +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 NEIGHBOURCELLS= 1 CCODE= 63 NRXLEV= 63 ARFCN= 1023 +foobar AddLocationInfo +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 +foobar AddLocationInfo +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 TIMINGADVANCE= 40 NEIGHBOURCELLS= 1 CCODE= 64 NRXLEV= 64 ARFCN= 1023 +foobar AddLocationInfo +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate 2 +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.5.1.11 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 +foobar AddLocationInfo +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 NEIGHBOURCELLS= 1 CCODE= 63 NRXLEV= 63 ARFCN= 1023 +foobar AddLocationInfo +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 +foobar AddLocationInfo +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 TIMINGADVANCE= -1 NEIGHBOURCELLS= 1 CCODE= 63 NRXLEV= 63 ARFCN= 1023 +foobar AddLocationInfo +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate 2 +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.5.1.12 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 +foobar AddLocationInfo +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 NEIGHBOURCELLS= 1 CCODE= 63 NRXLEV= 63 ARFCN= 1023 +foobar AddLocationInfo +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 +foobar AddLocationInfo +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 TIMINGADVANCE= 40 NEIGHBOURCELLS= 1 CCODE= 63 NRXLEV= 63 ARFCN= 1023 +foobar AddLocationInfo +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 LOCATIONCODE= 300 CELLID= 30 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate 2 +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.5.1.13 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 +foobar AddLocationInfo +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 NEIGHBOURCELLS= 1 NCELLID= 268435455 NSCODE= 511 +foobar AddLocationInfo +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 +foobar AddLocationInfo +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 SCODE= 511 NEIGHBOURCELLS= 1 NCELLID= 268435455 NSCODE= 511 +foobar AddLocationInfo +foobar SetWCDMACellInfo 1 COUNTRYCODE= 1000 NETWORKCODE= 200 CELLID= 30 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate 2 +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.5.1.14 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 +foobar AddLocationInfo +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 NEIGHBOURCELLS= 1 NCELLID= 268435456 NSCODE= 511 +foobar AddLocationInfo +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 +foobar AddLocationInfo +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 SCODE= 511 NEIGHBOURCELLS= 1 NCELLID= 268435455 NSCODE= 511 +foobar AddLocationInfo +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate 2 +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.5.1.15 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 +foobar AddLocationInfo +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 NEIGHBOURCELLS= 1 NCELLID= 268435455 NSCODE= 511 +foobar AddLocationInfo +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 +foobar AddLocationInfo +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 SCODE= 512 NEIGHBOURCELLS= 1 NCELLID= 268435455 NSCODE= 511 +foobar AddLocationInfo +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate 2 +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.5.1.16 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 +foobar AddLocationInfo +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 NEIGHBOURCELLS= 1 NCELLID= 268435455 NSCODE= 511 +foobar AddLocationInfo +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 +foobar AddLocationInfo +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 SCODE= 511 NEIGHBOURCELLS= 1 NCELLID= 268435455 NSCODE= 511 +foobar AddLocationInfo +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 CELLID= 30 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate 2 +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.5.1.17 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 +foobar AddLocationInfo +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 NEIGHBOURCELLS= 1 NCELLID= 268435455 NSCODE= 511 +foobar AddLocationInfo +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 +foobar AddLocationInfo +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 TIMINGADVANCE= 40 NEIGHBOURCELLS= 1 CCODE= 63 NRXLEV= 63 ARFCN= 1023 +foobar AddLocationInfo +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate 2 +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.5.1.18 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 +foobar AddLocationInfo +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 NEIGHBOURCELLS= 1 CCODE= 63 NRXLEV= 63 ARFCN= 1023 +foobar AddLocationInfo +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 +foobar AddLocationInfo +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 TIMINGADVANCE= 40 NEIGHBOURCELLS= 1 CCODE= 63 NRXLEV= 63 ARFCN= 1023 +foobar AddLocationInfo +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 +foobar AddLocationInfo +foobar ConvertLocationInfo LocalCacheOnly Coordinate 2 +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.5.1.19 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 +foobar AddLocationInfo +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 NEIGHBOURCELLS= 1 CCODE= 63 NRXLEV= 63 ARFCN= 1023 +foobar AddLocationInfo +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 +foobar AddLocationInfo +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 TIMINGADVANCE= 40 NEIGHBOURCELLS= 1 CCODE= 63 NRXLEV= 63 ARFCN= 1023 +foobar AddLocationInfo +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 +foobar AddLocationInfo +foobar ConvertLocationInfo ConnectionSilent Coordinate 2 +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.5.1.20 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 +foobar AddLocationInfo +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 NEIGHBOURCELLS= 1 CCODE= 63 NRXLEV= 63 ARFCN= 1023 +foobar AddLocationInfo +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 +foobar AddLocationInfo +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 TIMINGADVANCE= 40 NEIGHBOURCELLS= 1 CCODE= 63 NRXLEV= 63 ARFCN= 1023 +foobar AddLocationInfo +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 +foobar AddLocationInfo +foobar ConvertLocationInfo ConnectionPrompt Coordinate 2 +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.5.1.21 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 +foobar AddLocationInfo +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 NEIGHBOURCELLS= 1 NCELLID= 268435455 NSCODE= 511 +foobar AddLocationInfo +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 +foobar AddLocationInfo +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 SCODE= 511 NEIGHBOURCELLS= 1 NCELLID= 268435455 NSCODE= 511 +foobar AddLocationInfo +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 +foobar AddLocationInfo +foobar ConvertLocationInfo LocalCacheOnly Coordinate 2 +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.5.1.22 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 +foobar AddLocationInfo +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 NEIGHBOURCELLS= 1 NCELLID= 268435455 NSCODE= 511 +foobar AddLocationInfo +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 +foobar AddLocationInfo +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 SCODE= 511 NEIGHBOURCELLS= 1 NCELLID= 268435455 NSCODE= 511 +foobar AddLocationInfo +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 +foobar AddLocationInfo +foobar ConvertLocationInfo ConnectionSilent Coordinate 2 +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.5.1.23 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 +foobar AddLocationInfo +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 NEIGHBOURCELLS= 1 NCELLID= 268435455 NSCODE= 511 +foobar AddLocationInfo +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 +foobar AddLocationInfo +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 SCODE= 511 NEIGHBOURCELLS= 1 NCELLID= 268435455 NSCODE= 511 +foobar AddLocationInfo +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 +foobar AddLocationInfo +foobar ConvertLocationInfo ConnectionPrompt Coordinate 2 +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.5.1.24 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 +foobar AddLocationInfo +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 NEIGHBOURCELLS= 1 NCELLID= 268435455 NSCODE= 511 +foobar AddLocationInfo +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 +foobar AddLocationInfo +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 TIMINGADVANCE= 40 NEIGHBOURCELLS= 1 CCODE= 63 NRXLEV= 63 ARFCN= 1023 +foobar AddLocationInfo +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified ConvertionNotDefined 2 +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.5.1.25 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 +foobar AddLocationInfo +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 NEIGHBOURCELLS= 1 NCELLID= 268435455 NSCODE= 511 +foobar AddLocationInfo +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 +foobar AddLocationInfo +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 TIMINGADVANCE= 40 NEIGHBOURCELLS= 1 CCODE= 63 NRXLEV= 63 ARFCN= 1023 +foobar AddLocationInfo +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Gsm 2 +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.5.1.26 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 +foobar AddLocationInfo +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 NEIGHBOURCELLS= 1 NCELLID= 268435455 NSCODE= 511 +foobar AddLocationInfo +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 +foobar AddLocationInfo +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 TIMINGADVANCE= 40 NEIGHBOURCELLS= 1 CCODE= 63 NRXLEV= 63 ARFCN= 1023 +foobar AddLocationInfo +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Wcdma 2 +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.5.1.27 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 +foobar AddLocationInfo +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 NEIGHBOURCELLS= 1 NCELLID= 268435455 NSCODE= 511 +foobar AddLocationInfo +foobar SetWCDMACellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 CELLID= 30 +foobar AddLocationInfo +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 TIMINGADVANCE= 40 NEIGHBOURCELLS= 1 CCODE= 63 NRXLEV= 63 ARFCN= 1023 +foobar AddLocationInfo +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Wlan 2 +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.5.2.1 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWLanInfo 1 MACID= 100000 SIGNAL= 3 +foobar AddLocationInfo +foobar SetWLanInfo 1 MACID= 100000 SIGNAL= 3 +foobar AddLocationInfo +foobar SetWLanInfo 1 MACID= 100000 SIGNAL= 3 +foobar AddLocationInfo +foobar SetWLanInfo 1 MACID= 100000 SIGNAL= 3 +foobar AddLocationInfo +foobar SetWLanInfo 1 MACID= 100000 SIGNAL= 3 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.5.2.2 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWLanInfo 1 MACID= 100000 SIGNAL= 3 +foobar AddLocationInfo 10 +foobar SetWLanInfo 1 MACID= 200000 SIGNAL= 30 +foobar AddLocationInfo 10 +foobar SetWLanInfo 1 MACID= 100000 SIGNAL= 3 +foobar AddLocationInfo 10 +foobar SetWLanInfo 1 MACID= 100000 SIGNAL= 3 +foobar AddLocationInfo 10 +foobar SetWLanInfo 1 MACID= 200000 SIGNAL= 30 +foobar AddLocationInfo 10 +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.5.2.3 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWLanInfo 1 MACID= 100000 SIGNAL= 3 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.5.2.4 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate 2 +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.5.2.5 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWLanInfo 1 MACID= 100000 SIGNAL= 3 +foobar AddLocationInfo +foobar SetWLanInfo 1 MACID= 100000 SIGNAL= 3 +foobar AddLocationInfo +foobar SetWLanInfo 1 MACID= 100000 SIGNAL= 3 +foobar AddLocationInfo +foobar SetWLanInfo 1 MACID= 100000 SIGNAL= 256 +foobar AddLocationInfo +foobar SetWLanInfo 1 MACID= 100000 SIGNAL= 3 +foobar AddLocationInfo +allownextresult KErrArgument +foobar ConvertLocationInfo PrefsUnspecified Coordinate 2 +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.5.2.6 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWLanInfo 1 MACID= 100000 SIGNAL= 3 +foobar AddLocationInfo +foobar SetWLanInfo 1 MACID= 100000 SIGNAL= 3 +foobar AddLocationInfo +foobar SetWLanInfo 1 MACID= 100000 SIGNAL= 3 +foobar AddLocationInfo +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 +foobar AddLocationInfo +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 NEIGHBOURCELLS= 1 CCODE= 63 NRXLEV= 63 ARFCN= 1023 +foobar AddLocationInfo +foobar ConvertLocationInfo PrefsUnspecified Coordinate +foobar ValidateLocationInfo +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.5.3.1 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 +foobar AddLocationInfo +allownextresult KErrCancel +foobar Misc 5 +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.5.3.2 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetWLanInfo 2 MACID= 100000 SIGNAL= 255 +foobar AddLocationInfo +allownextresult KErrCancel +foobar Misc 5 +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.5.3.3 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 +foobar AddLocationInfo +foobar Misc 6 +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.5.3.4 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 +foobar AddLocationInfo +foobar Misc 7 +foobar Cleanup +delete foobar +[Endtest] + +[Test] +title 2698.5.4.1 +create Te_locationinfoconverter foobar +foobar CreateLocationInfoConverter +foobar SetGSMCellInfo 1 COUNTRYCODE= 100 NETWORKCODE= 200 LOCATIONCODE= 300 CELLID= 30 +foobar AddLocationInfo +foobar Misc 8 +foobar Cleanup +delete foobar +[Endtest] + + + + + + + diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/Te_locationinfoconverter/conf/te_LbsLocationInfoConverterSuite.script --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/Te_locationinfoconverter/conf/te_LbsLocationInfoConverterSuite.script Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,755 @@ +START_TESTCASE LBS-LocationInfoConverter-GetAllLocationInfo +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini GetAllLocationInfo +END_TESTCASE LBS-LocationInfoConverter-GetAllLocationInfo + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_1_1 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_1_1 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_1_1 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_1_3 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_1_3 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_1_3 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_1_4 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_1_4 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_1_4 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_1_5 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_1_5 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_1_5 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_1_6 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_1_6 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_1_6 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_1_7 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_1_7 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_1_7 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_1_8 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_1_8 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_1_8 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_1_9 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_1_9 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_1_9 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_1_10 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_1_10 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_1_10 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_1_11 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_1_11 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_1_11 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_1_12 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_1_12 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_1_12 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_1_13 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_1_13 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_1_13 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_2 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_2 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_2 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_3 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_3 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_3 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_4 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_4 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_4 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_5 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_5 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_5 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_6 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_6 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_6 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_7 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_7 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_7 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_8 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_8 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_8 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_9 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_9 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_9 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_10 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_10 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_10 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_11 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_11 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_11 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_12 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_12 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_12 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_13 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_13 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_13 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_14 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_14 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_14 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_15 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_15 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_15 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_16 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_16 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_16 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_17 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_17 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_17 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_18 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_18 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_18 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_19 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_19 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_19 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_20 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_20 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_20 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_21 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_21 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_21 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_22 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_22 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_22 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_23 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_23 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_23 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_24 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_24 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_24 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_25 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_25 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_25 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_26 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_26 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_26 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_27 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_27 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_27 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_28_1 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_28_1 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_28_1 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_28_1_3 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_28_1_3 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_28_1_3 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_28_1_4 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_28_1_4 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_28_1_4 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_28_1_5 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_28_1_5 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_28_1_5 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_28_1_6 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_28_1_6 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_28_1_6 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_28_1_7 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_28_1_7 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_28_1_7 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_28_1_8 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_28_1_8 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_28_1_8 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_28_1_9 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_28_1_9 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_28_1_9 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_28_1_10 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_28_1_10 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_28_1_10 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_28_2 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_28_2 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_28_2 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_29 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_29 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_29 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_30 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_30 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_30 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_31 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_31 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_31 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_32 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_32 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_32 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_33 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_33 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_33 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_34 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_34 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_34 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_35 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_35 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_35 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_36 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_36 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_36 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_37 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_37 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_37 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_38 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_38 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_38 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_39 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_39 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_39 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_40 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_40 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_40 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_41 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_41 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_41 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_42 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_42 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_42 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_43 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_43 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_43 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_44 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_44 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_44 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_45 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_45 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_45 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_46 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_46 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_46 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_47_1 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_47_1 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_47_1 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_47_2 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_47_2 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_47_2 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_47_3 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_47_3 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_47_3 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_49_1 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_49_1 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_49_1 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_49_2 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_49_2 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_49_2 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_51 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_51 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_51 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_52 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_52 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_52 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_1_53 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_1_53 +END_TESTCASE LBS-LocationInfoConverter-2698_4_1_53 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_2_1 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_2_1 +END_TESTCASE LBS-LocationInfoConverter-2698_4_2_1 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_2_2 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_2_2 +END_TESTCASE LBS-LocationInfoConverter-2698_4_2_2 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_2_3 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_2_3 +END_TESTCASE LBS-LocationInfoConverter-2698_4_2_3 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_2_4 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_2_4 +END_TESTCASE LBS-LocationInfoConverter-2698_4_2_4 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_2_5 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_2_5 +END_TESTCASE LBS-LocationInfoConverter-2698_4_2_5 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_2_6 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_2_6 +END_TESTCASE LBS-LocationInfoConverter-2698_4_2_6 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_2_7 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_2_7 +END_TESTCASE LBS-LocationInfoConverter-2698_4_2_7 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_2_8 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_2_8 +END_TESTCASE LBS-LocationInfoConverter-2698_4_2_8 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_2_9 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_2_9 +END_TESTCASE LBS-LocationInfoConverter-2698_4_2_9 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_2_10 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_2_10 +END_TESTCASE LBS-LocationInfoConverter-2698_4_2_10 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_2_11 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_2_11 +END_TESTCASE LBS-LocationInfoConverter-2698_4_2_11 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_2_12 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_2_12 +END_TESTCASE LBS-LocationInfoConverter-2698_4_2_12 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_2_13 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_2_13 +END_TESTCASE LBS-LocationInfoConverter-2698_4_2_13 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_2_14 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_2_14 +END_TESTCASE LBS-LocationInfoConverter-2698_4_2_14 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_2_15 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_2_15 +END_TESTCASE LBS-LocationInfoConverter-2698_4_2_15 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_2_16 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_2_16 +END_TESTCASE LBS-LocationInfoConverter-2698_4_2_16 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_2_17 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_2_17 +END_TESTCASE LBS-LocationInfoConverter-2698_4_2_17 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_2_18 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_2_18 +END_TESTCASE LBS-LocationInfoConverter-2698_4_2_18 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_2_19 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_2_19 +END_TESTCASE LBS-LocationInfoConverter-2698_4_2_19 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_2_20 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_2_20 +END_TESTCASE LBS-LocationInfoConverter-2698_4_2_20 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_2_21 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_2_21 +END_TESTCASE LBS-LocationInfoConverter-2698_4_2_21 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_2_22 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_2_22 +END_TESTCASE LBS-LocationInfoConverter-2698_4_2_22 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_3_1_1 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_3_1_1 +END_TESTCASE LBS-LocationInfoConverter-2698_4_3_1_1 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_3_2_1 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_3_2_1 +END_TESTCASE LBS-LocationInfoConverter-2698_4_3_2_1 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_3_2_2 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_3_2_2 +END_TESTCASE LBS-LocationInfoConverter-2698_4_3_2_2 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_3_4 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_3_4 +END_TESTCASE LBS-LocationInfoConverter-2698_4_3_4 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_3_5 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_3_5 +END_TESTCASE LBS-LocationInfoConverter-2698_4_3_5 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_3_6 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_3_6 +END_TESTCASE LBS-LocationInfoConverter-2698_4_3_6 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_3_7 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_3_7 +END_TESTCASE LBS-LocationInfoConverter-2698_4_3_7 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_3_8 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_3_8 +END_TESTCASE LBS-LocationInfoConverter-2698_4_3_8 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_3_9 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_3_9 +END_TESTCASE LBS-LocationInfoConverter-2698_4_3_9 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_3_10 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_3_10 +END_TESTCASE LBS-LocationInfoConverter-2698_4_3_10 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_4_1 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_4_1 +END_TESTCASE LBS-LocationInfoConverter-2698_4_4_1 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_4_2 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_4_2 +END_TESTCASE LBS-LocationInfoConverter-2698_4_4_2 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_4_3 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_4_3 +END_TESTCASE LBS-LocationInfoConverter-2698_4_4_3 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_4_4 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_4_4 +END_TESTCASE LBS-LocationInfoConverter-2698_4_4_4 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_5_1 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_5_1 +END_TESTCASE LBS-LocationInfoConverter-2698_4_5_1 + + +START_TESTCASE LBS-LocationInfoConverter-2698_4_5_2 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_4_5_2 +END_TESTCASE LBS-LocationInfoConverter-2698_4_5_2 + + +START_TESTCASE LBS-LocationInfoConverter-2698_5_1_1 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_5_1_1 +END_TESTCASE LBS-LocationInfoConverter-2698_5_1_1 + + +START_TESTCASE LBS-LocationInfoConverter-2698_5_1_2 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_5_1_2 +END_TESTCASE LBS-LocationInfoConverter-2698_5_1_2 + + +START_TESTCASE LBS-LocationInfoConverter-2698_5_1_3 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_5_1_3 +END_TESTCASE LBS-LocationInfoConverter-2698_5_1_3 + + +START_TESTCASE LBS-LocationInfoConverter-2698_5_1_4 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_5_1_4 +END_TESTCASE LBS-LocationInfoConverter-2698_5_1_4 + + +START_TESTCASE LBS-LocationInfoConverter-2698_5_1_5 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_5_1_5 +END_TESTCASE LBS-LocationInfoConverter-2698_5_1_5 + + +START_TESTCASE LBS-LocationInfoConverter-2698_5_1_6 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_5_1_6 +END_TESTCASE LBS-LocationInfoConverter-2698_5_1_6 + + +START_TESTCASE LBS-LocationInfoConverter-2698_5_1_7 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_5_1_7 +END_TESTCASE LBS-LocationInfoConverter-2698_5_1_7 + + +START_TESTCASE LBS-LocationInfoConverter-2698_5_1_8 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_5_1_8 +END_TESTCASE LBS-LocationInfoConverter-2698_5_1_8 + + +START_TESTCASE LBS-LocationInfoConverter-2698_5_1_9 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_5_1_9 +END_TESTCASE LBS-LocationInfoConverter-2698_5_1_9 + + +START_TESTCASE LBS-LocationInfoConverter-2698_5_1_10 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_5_1_10 +END_TESTCASE LBS-LocationInfoConverter-2698_5_1_10 + + +START_TESTCASE LBS-LocationInfoConverter-2698_5_1_11 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_5_1_11 +END_TESTCASE LBS-LocationInfoConverter-2698_5_1_11 + + +START_TESTCASE LBS-LocationInfoConverter-2698_5_1_12 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_5_1_12 +END_TESTCASE LBS-LocationInfoConverter-2698_5_1_12 + + +START_TESTCASE LBS-LocationInfoConverter-2698_5_1_13 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_5_1_13 +END_TESTCASE LBS-LocationInfoConverter-2698_5_1_13 + + +START_TESTCASE LBS-LocationInfoConverter-2698_5_1_14 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_5_1_14 +END_TESTCASE LBS-LocationInfoConverter-2698_5_1_14 + + +START_TESTCASE LBS-LocationInfoConverter-2698_5_1_15 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_5_1_15 +END_TESTCASE LBS-LocationInfoConverter-2698_5_1_15 + + +START_TESTCASE LBS-LocationInfoConverter-2698_5_1_16 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_5_1_16 +END_TESTCASE LBS-LocationInfoConverter-2698_5_1_16 + + +START_TESTCASE LBS-LocationInfoConverter-2698_5_1_17 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_5_1_17 +END_TESTCASE LBS-LocationInfoConverter-2698_5_1_17 + + +START_TESTCASE LBS-LocationInfoConverter-2698_5_1_18 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_5_1_18 +END_TESTCASE LBS-LocationInfoConverter-2698_5_1_18 + + +START_TESTCASE LBS-LocationInfoConverter-2698_5_1_19 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_5_1_19 +END_TESTCASE LBS-LocationInfoConverter-2698_5_1_19 + + +START_TESTCASE LBS-LocationInfoConverter-2698_5_1_20 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_5_1_20 +END_TESTCASE LBS-LocationInfoConverter-2698_5_1_20 + + +START_TESTCASE LBS-LocationInfoConverter-2698_5_1_21 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_5_1_21 +END_TESTCASE LBS-LocationInfoConverter-2698_5_1_21 + + +START_TESTCASE LBS-LocationInfoConverter-2698_5_1_22 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_5_1_22 +END_TESTCASE LBS-LocationInfoConverter-2698_5_1_22 + + +START_TESTCASE LBS-LocationInfoConverter-2698_5_1_23 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_5_1_23 +END_TESTCASE LBS-LocationInfoConverter-2698_5_1_23 + + +START_TESTCASE LBS-LocationInfoConverter-2698_5_1_24 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_5_1_24 +END_TESTCASE LBS-LocationInfoConverter-2698_5_1_24 + + +START_TESTCASE LBS-LocationInfoConverter-2698_5_1_25 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_5_1_25 +END_TESTCASE LBS-LocationInfoConverter-2698_5_1_25 + + +START_TESTCASE LBS-LocationInfoConverter-2698_5_1_26 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_5_1_26 +END_TESTCASE LBS-LocationInfoConverter-2698_5_1_26 + + +START_TESTCASE LBS-LocationInfoConverter-2698_5_1_27 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_5_1_27 +END_TESTCASE LBS-LocationInfoConverter-2698_5_1_27 + + +START_TESTCASE LBS-LocationInfoConverter-2698_5_2_1 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_5_2_1 +END_TESTCASE LBS-LocationInfoConverter-2698_5_2_1 + + +START_TESTCASE LBS-LocationInfoConverter-2698_5_2_2 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_5_2_2 +END_TESTCASE LBS-LocationInfoConverter-2698_5_2_2 + + +START_TESTCASE LBS-LocationInfoConverter-2698_5_2_3 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_5_2_3 +END_TESTCASE LBS-LocationInfoConverter-2698_5_2_3 + + +START_TESTCASE LBS-LocationInfoConverter-2698_5_2_4 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_5_2_4 +END_TESTCASE LBS-LocationInfoConverter-2698_5_2_4 + + +START_TESTCASE LBS-LocationInfoConverter-2698_5_2_5 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_5_2_5 +END_TESTCASE LBS-LocationInfoConverter-2698_5_2_5 + + +START_TESTCASE LBS-LocationInfoConverter-2698_5_2_6 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_5_2_6 +END_TESTCASE LBS-LocationInfoConverter-2698_5_2_6 + + +START_TESTCASE LBS-LocationInfoConverter-2698_5_3_1 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_5_3_1 +END_TESTCASE LBS-LocationInfoConverter-2698_5_3_1 + + +START_TESTCASE LBS-LocationInfoConverter-2698_5_3_2 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_5_3_2 +END_TESTCASE LBS-LocationInfoConverter-2698_5_3_2 + + +START_TESTCASE LBS-LocationInfoConverter-2698_5_3_3 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_5_3_3 +END_TESTCASE LBS-LocationInfoConverter-2698_5_3_3 + + +START_TESTCASE LBS-LocationInfoConverter-2698_5_3_4 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_5_3_4 +END_TESTCASE LBS-LocationInfoConverter-2698_5_3_4 + + +START_TESTCASE LBS-LocationInfoConverter-2698_5_4_1 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step LbsLocationInfoConverter.ini 2698_5_4_1 +END_TESTCASE LBS-LocationInfoConverter-2698_5_4_1 + + diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/Te_locationinfoconverter/eabi/Te_locationinfoconverterU.def --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/Te_locationinfoconverter/eabi/Te_locationinfoconverterU.def Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,5 @@ +EXPORTS + _Z9LibEntryLR13CTestModuleIf @ 1 NONAME + _ZTI33CTelocationinfoconversionobserver @ 2 NONAME + _ZTV33CTelocationinfoconversionobserver @ 3 NONAME + diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/Te_locationinfoconverter/group/Te_locationinfoconverter.mmp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/Te_locationinfoconverter/group/Te_locationinfoconverter.mmp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,51 @@ +/*TYPE TESTCLASS*/ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: MMP file for STIF Test Framework's TestScripter +* testclass test module. +* +*/ + +#include + +TARGET Te_locationinfoconverter.dll +TARGETTYPE dll +UID 0x1000008D 0x101FB3E3 + +CAPABILITY ALL -TCB + +//TARGETPATH ?target_path +DEFFILE Te_locationinfoconverter.def + +USERINCLUDE ../inc + +OS_LAYER_SYSTEMINCLUDE + +SOURCEPATH ../src +SOURCE Te_locationinfoconverter.cpp +SOURCE Te_locationinfoconverterBlocks.cpp Te_locationinfoconversionobserver.cpp + +LIBRARY euser.lib +LIBRARY ecom.lib +LIBRARY stiftestinterface.lib +LIBRARY stiftestengine.lib bafl.lib +LIBRARY lbslocationinfodatatypes.lib lbslocationinfoconverter.lib /*lbsselflocate.lib*/ +LIBRARY lbs.lib + +LANG SC + + +SMPSAFE + +// End of File diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/Te_locationinfoconverter/group/Te_locationinfoconverter.pkg --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/Te_locationinfoconverter/group/Te_locationinfoconverter.pkg Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,62 @@ +; +; Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +; All rights reserved. +; This component and the accompanying materials are made available +; under the terms of "Eclipse Public License v1.0" +; which accompanies this distribution, and is available +; at the URL "http://www.eclipse.org/legal/epl-v10.html". +; +; Initial Contributors: +; Nokia Corporation - initial contribution. +; +; Contributors: +; +; Description: +; +; Installation file for STIF +; + +; Languages +&EN + +; Provide value for uid +#{"STIF"},(0x00000000),1,1,0,TYPE=SA + +; Series60 product id for S60 3.0 +[0x101F7961], 0, 0, 0, {"Series60ProductID"} + +; Localised Vendor name +%{"Nokia"} + +; Unique Vendor name +:"Nokia" + +; Logo +; None + +; Package signature - Optional +; None + +; Start of Package body + +; Condition blocks +; None + +; Options list +; None + +; Install files +"\epoc32\release\armv5\urel\Te_locationinfoconverter.dll" - "!:\Sys\Bin\Te_locationinfoconverter.dll" +"..\conf\Te_locationinfoconverter.cfg"-"C:\TestFramework\Te_locationinfoconverter.cfg" + ;"Te_locationinfoconverter.bat" - "C:\Sys\Bin\Te_locationinfoconverter.bat" + +; Embedded SIS +; None + +; End of Package body + +; PKG dependencies +; None + +; PKG capabilities +; None diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/Te_locationinfoconverter/group/Te_locationinfoconverter_DoxyFile.txt --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/Te_locationinfoconverter/group/Te_locationinfoconverter_DoxyFile.txt Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,239 @@ +# +# Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +# All rights reserved. +# This component and the accompanying materials are made available +# under the terms of "Eclipse Public License v1.0" +# which accompanies this distribution, and is available +# at the URL "http://www.eclipse.org/legal/epl-v10.html". +# +# Initial Contributors: +# Nokia Corporation - initial contribution. +# +# Contributors: +# +# Description: +# +# + +# Doxyfile 1.4.1 + +#--------------------------------------------------------------------------- +# Project related configuration options +#--------------------------------------------------------------------------- +PROJECT_NAME = Te_locationinfoconverter +PROJECT_NUMBER = +OUTPUT_DIRECTORY = \Te_locationinfoconverter\ +CREATE_SUBDIRS = NO +OUTPUT_LANGUAGE = English +USE_WINDOWS_ENCODING = YES +BRIEF_MEMBER_DESC = YES +REPEAT_BRIEF = YES +ABBREVIATE_BRIEF = +ALWAYS_DETAILED_SEC = NO +INLINE_INHERITED_MEMB = NO +FULL_PATH_NAMES = NO +STRIP_FROM_PATH = +STRIP_FROM_INC_PATH = +SHORT_NAMES = NO +JAVADOC_AUTOBRIEF = NO +MULTILINE_CPP_IS_BRIEF = NO +DETAILS_AT_TOP = NO +INHERIT_DOCS = YES +DISTRIBUTE_GROUP_DOC = NO +TAB_SIZE = 8 +ALIASES = +OPTIMIZE_OUTPUT_FOR_C = YES +OPTIMIZE_OUTPUT_JAVA = NO +SUBGROUPING = YES +#--------------------------------------------------------------------------- +# Build related configuration options +#--------------------------------------------------------------------------- +EXTRACT_ALL = YES +EXTRACT_PRIVATE = NO +EXTRACT_STATIC = NO +EXTRACT_LOCAL_CLASSES = NO +EXTRACT_LOCAL_METHODS = NO +HIDE_UNDOC_MEMBERS = NO +HIDE_UNDOC_CLASSES = NO +HIDE_FRIEND_COMPOUNDS = NO +HIDE_IN_BODY_DOCS = NO +INTERNAL_DOCS = YES +CASE_SENSE_NAMES = YES +HIDE_SCOPE_NAMES = NO +SHOW_INCLUDE_FILES = YES +INLINE_INFO = YES +SORT_MEMBER_DOCS = YES +SORT_BRIEF_DOCS = NO +SORT_BY_SCOPE_NAME = NO +GENERATE_TODOLIST = NO +GENERATE_TESTLIST = NO +GENERATE_BUGLIST = NO +GENERATE_DEPRECATEDLIST= YES +ENABLED_SECTIONS = +MAX_INITIALIZER_LINES = 30 +SHOW_USED_FILES = YES +SHOW_DIRECTORIES = YES +FILE_VERSION_FILTER = +#--------------------------------------------------------------------------- +# configuration options related to warning and progress messages +#--------------------------------------------------------------------------- +QUIET = NO +WARNINGS = YES +WARN_IF_UNDOCUMENTED = YES +WARN_IF_DOC_ERROR = YES +WARN_NO_PARAMDOC = NO +WARN_FORMAT = "$file:$line: $text" +WARN_LOGFILE = +#--------------------------------------------------------------------------- +# configuration options related to the input files +#--------------------------------------------------------------------------- +INPUT = \Te_locationinfoconverter\ +FILE_PATTERNS = *.h \ + *.rh \ + *.hrh +RECURSIVE = YES +EXCLUDE = +EXCLUDE_SYMLINKS = NO +EXCLUDE_PATTERNS = +EXAMPLE_PATH = +EXAMPLE_PATTERNS = +EXAMPLE_RECURSIVE = NO +IMAGE_PATH = +INPUT_FILTER = +FILTER_PATTERNS = +FILTER_SOURCE_FILES = NO +#--------------------------------------------------------------------------- +# configuration options related to source browsing +#--------------------------------------------------------------------------- +SOURCE_BROWSER = NO +INLINE_SOURCES = NO +STRIP_CODE_COMMENTS = YES +REFERENCED_BY_RELATION = YES +REFERENCES_RELATION = YES +VERBATIM_HEADERS = YES +#--------------------------------------------------------------------------- +# configuration options related to the alphabetical class index +#--------------------------------------------------------------------------- +ALPHABETICAL_INDEX = NO +COLS_IN_ALPHA_INDEX = 5 +IGNORE_PREFIX = +#--------------------------------------------------------------------------- +# configuration options related to the HTML output +#--------------------------------------------------------------------------- +GENERATE_HTML = NO +HTML_OUTPUT = html +HTML_FILE_EXTENSION = .html +HTML_HEADER = +HTML_FOOTER = +HTML_STYLESHEET = +HTML_ALIGN_MEMBERS = YES +GENERATE_HTMLHELP = YES +CHM_FILE = +HHC_LOCATION = +GENERATE_CHI = NO +BINARY_TOC = YES +TOC_EXPAND = YES +DISABLE_INDEX = YES +ENUM_VALUES_PER_LINE = 4 +GENERATE_TREEVIEW = YES +TREEVIEW_WIDTH = 250 +#--------------------------------------------------------------------------- +# configuration options related to the LaTeX output +#--------------------------------------------------------------------------- +GENERATE_LATEX = NO +LATEX_OUTPUT = latex +LATEX_CMD_NAME = latex +MAKEINDEX_CMD_NAME = makeindex +COMPACT_LATEX = NO +PAPER_TYPE = a4wide +EXTRA_PACKAGES = +LATEX_HEADER = +PDF_HYPERLINKS = NO +USE_PDFLATEX = NO +LATEX_BATCHMODE = NO +LATEX_HIDE_INDICES = NO +#--------------------------------------------------------------------------- +# configuration options related to the RTF output +#--------------------------------------------------------------------------- +GENERATE_RTF = YES +RTF_OUTPUT = Doc +COMPACT_RTF = YES +RTF_HYPERLINKS = YES +RTF_STYLESHEET_FILE = +RTF_EXTENSIONS_FILE = +#--------------------------------------------------------------------------- +# configuration options related to the man page output +#--------------------------------------------------------------------------- +GENERATE_MAN = NO +MAN_OUTPUT = man +MAN_EXTENSION = .3 +MAN_LINKS = NO +#--------------------------------------------------------------------------- +# configuration options related to the XML output +#--------------------------------------------------------------------------- +GENERATE_XML = NO +XML_OUTPUT = xml +XML_SCHEMA = +XML_DTD = +XML_PROGRAMLISTING = YES +#--------------------------------------------------------------------------- +# configuration options for the AutoGen Definitions output +#--------------------------------------------------------------------------- +GENERATE_AUTOGEN_DEF = NO +#--------------------------------------------------------------------------- +# configuration options related to the Perl module output +#--------------------------------------------------------------------------- +GENERATE_PERLMOD = NO +PERLMOD_LATEX = NO +PERLMOD_PRETTY = YES +PERLMOD_MAKEVAR_PREFIX = +#--------------------------------------------------------------------------- +# Configuration options related to the preprocessor +#--------------------------------------------------------------------------- +ENABLE_PREPROCESSING = YES +MACRO_EXPANSION = YES +EXPAND_ONLY_PREDEF = NO +SEARCH_INCLUDES = YES +INCLUDE_PATH = +INCLUDE_FILE_PATTERNS = +PREDEFINED = NONSHARABLE_CLASS +EXPAND_AS_DEFINED = +SKIP_FUNCTION_MACROS = YES +#--------------------------------------------------------------------------- +# Configuration::additions related to external references +#--------------------------------------------------------------------------- +TAGFILES = +GENERATE_TAGFILE = +ALLEXTERNALS = NO +EXTERNAL_GROUPS = YES +PERL_PATH = /usr/bin/perl +#--------------------------------------------------------------------------- +# Configuration options related to the dot tool +#--------------------------------------------------------------------------- +CLASS_DIAGRAMS = YES +HIDE_UNDOC_RELATIONS = YES +HAVE_DOT = NO +CLASS_GRAPH = YES +COLLABORATION_GRAPH = YES +GROUP_GRAPHS = YES +UML_LOOK = NO +TEMPLATE_RELATIONS = YES +INCLUDE_GRAPH = YES +INCLUDED_BY_GRAPH = YES +CALL_GRAPH = NO +GRAPHICAL_HIERARCHY = YES +DIRECTORY_GRAPH = YES +DOT_IMAGE_FORMAT = png +DOT_PATH = +DOTFILE_DIRS = +MAX_DOT_GRAPH_WIDTH = 1024 +MAX_DOT_GRAPH_HEIGHT = 1024 +MAX_DOT_GRAPH_DEPTH = 0 +DOT_TRANSPARENT = NO +DOT_MULTI_TARGETS = NO +GENERATE_LEGEND = YES +DOT_CLEANUP = YES +#--------------------------------------------------------------------------- +# Configuration::additions related to the search engine +#--------------------------------------------------------------------------- +SEARCHENGINE = NO diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/Te_locationinfoconverter/group/Te_locationinfoconverter_c.bat --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/Te_locationinfoconverter/group/Te_locationinfoconverter_c.bat Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,23 @@ +rem +rem Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +rem All rights reserved. +rem This component and the accompanying materials are made available +rem under the terms of "Eclipse Public License v1.0" +rem which accompanies this distribution, and is available +rem at the URL "http://www.eclipse.org/legal/epl-v10.html". +rem +rem Initial Contributors: +rem Nokia Corporation - initial contribution. +rem +rem Contributors: +rem +rem Description: batch file +rem + +rem copy C:\TestFramework\TestFramework_locblid.ini C:\TestFramework\TestFramework.ini +rem md e:\BCTest +rem md e:\BCTest\Results + +ATSINTERFACE.EXE -testmodule testcombiner -config C:\TestFramework\Te_locationinfoconverter.cfg +copy c:\Logs\TestFramework\TestReport.txt e:\BCTest\results\Te_locationinfoconverter.txt + diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/Te_locationinfoconverter/group/Te_locationinfoconverter_nrm.mmp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/Te_locationinfoconverter/group/Te_locationinfoconverter_nrm.mmp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,78 @@ +/*TYPE TESTCLASS*/ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: MMP file for STIF Test Framework's TestScripter +* testclass test module. +* +*/ + +#include + +TARGET Te_locationinfoconverter.dll +TARGETTYPE dll +UID 0x1000008D 0x101FB3E3 + +CAPABILITY ALL -TCB +/* Remove comments and replace 0x00000000 with correct vendor id */ +// VENDORID 0x00000000 +/* Remove comments and replace 0x00000000 with correct secure id */ +// SECUREID 0x00000000 + +//TARGETPATH ?target_path +DEFFILE Te_locationinfoconverter.def + +USERINCLUDE ../inc + +OS_LAYER_SYSTEMINCLUDE + +SOURCEPATH ../src + +SOURCE Te_locationinfoconverter.cpp +SOURCE Te_locationinfoconverterBlocks.cpp + +//RESOURCE resource_file +//RESOURCE resource_file2 + +LIBRARY euser.lib +LIBRARY stiftestinterface.lib +LIBRARY stiftestengine.lib + +LANG SC + +/* +START WINS +?wins_specific_information +END + +START MARM +?marm_specific_information +END +*/ +// Other possible keywords: + +// DOCUMENT ?file, that is not compiled, but added to MSVC project workspace (i.e. release notes) +/* +START BITMAP ?target +TARGETPATH ?emulated_path_on_target_machine +HEADER +SOURCE ?color_depth ?source_bitmap +END +*/ +// DEFFILE ?filename +// AIF ?filename + + +SMPSAFE + +// End of File diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/Te_locationinfoconverter/group/Te_locationinfoconverter_z.bat --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/Te_locationinfoconverter/group/Te_locationinfoconverter_z.bat Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,23 @@ +rem +rem Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +rem All rights reserved. +rem This component and the accompanying materials are made available +rem under the terms of "Eclipse Public License v1.0" +rem which accompanies this distribution, and is available +rem at the URL "http://www.eclipse.org/legal/epl-v10.html". +rem +rem Initial Contributors: +rem Nokia Corporation - initial contribution. +rem +rem Contributors: +rem +rem Description: batch file +rem + +copy z:\TestFramework\TestFramework_locblid.ini C:\TestFramework\TestFramework.ini +md e:\BCTest +md e:\BCTest\Results + +ATSINTERFACE.EXE -testmodule testcombiner -config C:\TestFramework\tcLmkBlid.cfg +copy c:\Logs\TestFramework\TestReport.txt e:\BCTest\results\Location_LmkBlid.txt + diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/Te_locationinfoconverter/group/bld.inf --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/Te_locationinfoconverter/group/bld.inf Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,21 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ + +PRJ_TESTMMPFILES +Te_locationinfoconverter.mmp + +// End of File diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/Te_locationinfoconverter/inc/Te_locationinfoconversionobserver.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/Te_locationinfoconverter/inc/Te_locationinfoconversionobserver.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,73 @@ +/* +* Copyright (c) 2002 - 2007 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Test module to implement Advanced trigger supervision cases +* +*/ + + + +#ifndef TE_LOCATIONINFOCONVERSIONOBSERVER_H +#define TE_LOCATIONINFOCONVERSIONOBSERVER_H +#include + + + class CTelocationinfoconversionobserver: public CTimer, public MLbsLocationInfoConverterObserver + + { + + public: // Constructors and destructor + + /** + * Two-phased constructor. + */ + static CTelocationinfoconversionobserver* NewL( ); + + /** + * Destructor. + */ + ~CTelocationinfoconversionobserver(); + + + void OnConversionComplete( TInt aStatusCode ); + + void RunL( ); + + void DoCancel( ); + + TInt ConversionResult(); + + // RTimer iTimer; + TRequestStatus iWaitStatus; + + private: + + /** + * C++ default constructor. + */ + CTelocationinfoconversionobserver( ); + + /** + * By default Symbian 2nd phase constructor is private. + */ + void ConstructL(); + + private: + + TInt iStatusCode; + + }; + +#endif // TE_LOCATIONINFOCONVERSIONOBSERVER_H + +// End of File diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/Te_locationinfoconverter/inc/Te_locationinfoconverter.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/Te_locationinfoconverter/inc/Te_locationinfoconverter.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,190 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: STIF testclass declaration +* +*/ + +#ifndef TE_LOCATIONINFOCONVERTER_H +#define TE_LOCATIONINFOCONVERTER_H + +// INCLUDES + + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + + +#include "Te_locationinfoconversionobserver.h" + +// CONSTANTS +//const ?type ?constant_var = ?constant; + +// MACROS +//#define ?macro ?macro_def +#define TEST_CLASS_VERSION_MAJOR 0 +#define TEST_CLASS_VERSION_MINOR 0 +#define TEST_CLASS_VERSION_BUILD 0 + +// Logging path +_LIT( KTe_locationinfoconverterLogPath, "c:\\logs\\testframework\\" ); +// Log file +_LIT( KTe_locationinfoconverterLogFile, "Te_locationinfoconverter.txt" ); +_LIT( KTe_locationinfoconverterLogFileWithTitle, "Te_locationinfoconverter_[%S].txt" ); + +// FUNCTION PROTOTYPES +//?type ?function_name(?arg_list); + +// FORWARD DECLARATIONS +//class ?FORWARD_CLASSNAME; +class CTe_locationinfoconverter; + +// DATA TYPES +//enum ?declaration +//typedef ?declaration +//extern ?data_type; + +// CLASS DECLARATION + +/** +* CTe_locationinfoconverter test class for STIF Test Framework TestScripter. +* ?other_description_lines +* +* @lib ?library +* @since ?Series60_version +*/ +NONSHARABLE_CLASS(CTe_locationinfoconverter) : public CScriptBase + { + public: // Constructors and destructor + + /** + * Two-phased constructor. + */ + static CTe_locationinfoconverter* NewL( CTestModuleIf& aTestModuleIf ); + + /** + * Destructor. + */ + virtual ~CTe_locationinfoconverter(); + + public: // New functions + + /** + * ?member_description. + * @since ?Series60_version + * @param ?arg1 ?description + * @return ?description + */ + //?type ?member_function( ?type ?arg1 ); + + public: // Functions from base classes + + /** + * From CScriptBase Runs a script line. + * @since ?Series60_version + * @param aItem Script line containing method name and parameters + * @return Symbian OS error code + */ + virtual TInt RunMethodL( CStifItemParser& aItem ); + + protected: // New functions + + /** + * ?member_description. + * @since ?Series60_version + * @param ?arg1 ?description + * @return ?description + */ + //?type ?member_function( ?type ?arg1 ); + + protected: // Functions from base classes + + /** + * From ?base_class ?member_description + */ + //?type ?member_function(); + + private: + + /** + * C++ default constructor. + */ + CTe_locationinfoconverter( CTestModuleIf& aTestModuleIf ); + + /** + * By default Symbian 2nd phase constructor is private. + */ + void ConstructL(); + + // Prohibit copy constructor if not deriving from CBase. + // ?classname( const ?classname& ); + // Prohibit assigment operator if not deriving from CBase. + // ?classname& operator=( const ?classname& ); + + /** + * Frees all resources allocated from test methods. + * @since ?Series60_version + */ + void Delete(); + + /** + * Test methods are listed below. + */ + + /** + * Example test method. + * @since ?Series60_version + * @param aItem Script line containing parameters. + * @return Symbian OS error code. + */ + virtual TInt ConvertLocationInfoL( CStifItemParser& aItem ); + virtual TInt CreateLocationInfoConverterL( CStifItemParser& aItem ); + virtual TInt SetCoordinateInfoL( CStifItemParser& aItem ); + virtual TInt SetGSMCellInfoL( CStifItemParser& aItem ); + virtual TInt SetWCDMACellInfoL( CStifItemParser& aItem ); + virtual TInt SetWLanInfoL( CStifItemParser& aItem ); + virtual TInt AddLocationInfoL( CStifItemParser& aItem ); + virtual TInt ValidateLocationInfoL( CStifItemParser& aItem ); + virtual TInt MiscL( CStifItemParser& aItem ); + virtual TInt Cleanup( CStifItemParser& aItem ); + + + + + private: // Data + + // ?one_line_short_description_of_data + //?data_declaration; + CLbsLocationInfoConverter* ilbslocationinfoconverter; + CLbsLocationInfo* ilbslocationinfo; + CTelocationinfoconversionobserver* iObserver; + RLbsLocationInfoBaseArray ilbslocationinfoarray; + RLbsLocationInfoBaseArray ilbslocationinfoarrayTemp; + + + + }; + +#endif // TE_LOCATIONINFOCONVERTER_H + +// End of File diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/Te_locationinfoconverter/init/TestFramework.ini --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/Te_locationinfoconverter/init/TestFramework.ini Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,218 @@ +# +# This is STIF initialization file +# Comment lines start with '#'-character. +# See STIF TestFramework users guide.doc for instructions + +# -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- +# Set following test engine settings: +# - Set Test Reporting mode. TestReportMode's possible values are: +# + 'Summary': Summary of the tested test cases. +# + 'Environment': Hardware and software info. +# + 'TestCases': Test case report. +# + 'FullReport': Set of all above ones. +# + Example 'TestReportMode= Summary TestCases' +# +# - CreateTestReport setting controls report creation mode +# + YES, Test report will created. +# + NO, No Test report. +# +# - File path indicates the base path of the test report. +# - File name indicates the name of the test report. +# +# - File format indicates the type of the test report. +# + TXT, Test report file will be txt type, for example 'TestReport.txt'. +# + HTML, Test report will be html type, for example 'TestReport.html'. +# + XML, Test report will be xml type, for example 'TestReport.xml'. +# Note, that xml format is available only when output is set to FILE. +# +# - File output indicates output source of the test report. +# + FILE, Test report logging to file. +# + RDEBUG, Test report logging to using rdebug. +# +# - File Creation Mode indicates test report overwriting if file exist. +# + OVERWRITE, Overwrites if the Test report file exist. +# + APPEND, Continue logging after the old Test report information if +# report exist. +# - Sets a device reset module's dll name(Reboot). +# + If Nokia specific reset module is not available or it is not correct one +# StifHWResetStub module may use as a template for user specific reset +# module. +# - Sets STIF test measurement disable options. e.g. pluging1 and pluging2 disablation +# DisableMeasurement= stifmeasurementplugin01 stifmeasurementplugin02 +# + +[Engine_Defaults] + +TestReportMode= FullReport # Possible values are: 'Empty', 'Summary', 'Environment', + # 'TestCases' or 'FullReport' + +CreateTestReport= YES # Possible values: YES or NO + +TestReportFilePath= C:\LOGS\TestFramework\ +TestReportFileName= TestReport + +TestReportFormat= TXT # Possible values: TXT, HTML or XML +TestReportOutput= FILE # Possible values: FILE or RDEBUG +TestReportFileCreationMode= OVERWRITE # Possible values: OVERWRITE or APPEND + +DeviceResetDllName= StifResetForNokia.dll # e.g. 'StifHWResetStub.dll' for user specific reseting + +DisableMeasurement= stifmeasurementdisablenone # Possible values are: + # 'stifmeasurementdisablenone', 'stifmeasurementdisableall' + # 'stifmeasurementplugin01', 'stifmeasurementplugin02', + # 'stifmeasurementplugin03', 'stifmeasurementplugin04', + # 'stifmeasurementplugin05' or 'stifbappeaprofiler' + +Timeout= 0 # Default timeout value for each test case. In milliseconds +#UITestingSupport= YES # Possible values: YES or NO +#SeparateProcesses= YES # Possible values: YES or NO (default: NO) +[End_Defaults] +# -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- + + + +# -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- +# Module configurations start +# Modules are added between module tags +# tags. Module name is specified after ModuleName= tag, like +# ModuleName= XXXXXXXXX +# Modules might have initialisation file, specified as +# IniFile= c:\testframework\YYYYYY +# Modules might have several configuration files, like +# TestCaseFile= c:\testframework\NormalCases.txt +# TestCaseFile= c:\testframework\SmokeCases.txt +# TestCaseFile= c:\testframework\ManualCases.txt + +# (TestCaseFile is synonym for old term ConfigFile) + +# Following case specifies demo module settings. Demo module +# does not read any settings from file, so tags +# IniFile and TestCaseFile are not used. +# In the simplest case it is enough to specify only the +# name of the test module when adding new test module + +[New_Module] +ModuleName= testscripter +TestCaseFile= c:\testframework\Te_locationinfoconverter.cfg +[End_Module] + + +# Load testmoduleXXX, optionally with initialization file and/or test case files +#[New_Module] +#ModuleName= testmodulexxx + +#TestModuleXXX used initialization file +#IniFile= c:\testframework\init.txt + +#TestModuleXXX used configuration file(s) +#TestCaseFile= c:\testframework\testcases1.cfg +#TestCaseFile= c:\testframework\testcases2.cfg +#TestCaseFile= c:\testframework\manualtestcases.cfg + +#[End_Module] +# -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- + + + +# -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- +# Set STIF logging overwrite parameters for Logger. +# Hardware and emulator environment logging path and styles can +# be configured from here to overwrite the Logger's implemented values. +# +# Settings description: +# - Indicates option for creation log directory/directories. If log directory/directories +# is/are not created by user they will make by software. +# + YES, Create log directory/directories if not allready exist. +# + NO, Log directory/directories not created. Only created one is used. +# +# - Overwrite emulator path setting. +# + Example: If 'EmulatorBasePath= C:\LOGS\TestFramework\' and in code is defined +# Logger's path 'D:\\LOGS\\Module\\' with those definition the path +# will be 'C:\LOGS\TestFramework\LOGS\Module\' +# +# - Overwrite emulator's logging format. +# + TXT, Log file(s) will be txt type(s), for example 'Module.txt'. +# + HTML, Log file(s) will be html type(s), for example 'Module.html'. +# +# - Overwrited emulator logging output source. +# + FILE, Logging to file(s). +# + RDEBUG, Logging to using rdebug(s). +# +# - Overwrite hardware path setting (Same description as above in emulator path). +# - Overwrite hardware's logging format(Same description as above in emulator format). +# - Overwrite hardware's logging output source(Same description as above in emulator output). +# +# - File Creation Mode indicates file overwriting if file exist. +# + OVERWRITE, Overwrites if file(s) exist. +# + APPEND, Continue logging after the old logging information if file(s) exist. +# +# - Will thread id include to the log filename. +# + YES, Thread id to log file(s) name, Example filename 'Module_b9.txt'. +# + NO, No thread id to log file(s), Example filename 'Module.txt'. +# +# - Will time stamps include the to log file. +# + YES, Time stamp added to each line in log file(s). Time stamp is +# for example'12.Nov.2003 115958 LOGGING INFO' +# + NO, No time stamp(s). +# +# - Will line breaks include to the log file. +# + YES, Each logging event includes line break and next log event is in own line. +# + NO, No line break(s). +# +# - Will event ranking include to the log file. +# + YES, Event ranking number added to each line in log file(s). Ranking number +# depends on environment's tics, for example(includes time stamp also) +# '012 12.Nov.2003 115958 LOGGING INFO' +# + NO, No event ranking. +# +# - Will write log file in unicode format. +# + YES, Log file will be written in unicode format +# + NO, Log will be written as normal, not unicode, file. +# + +[Logger_Defaults] + +#NOTE: If you want to set Logger using next setting(s) remove comment(s)'#' +#NOTE: TestEngine and TestServer logging settings cannot change here + +#CreateLogDirectories= YES # Possible values: YES or NO + +#EmulatorBasePath= C:\LOGS\TestFramework\ +#EmulatorFormat= HTML # Possible values: TXT or HTML +#EmulatorOutput= FILE # Possible values: FILE or RDEBUG + +#HardwareBasePath= D:\LOGS\TestFramework\ +#HardwareFormat= HTML # Possible values: TXT or HTML +#HardwareOutput= FILE # Possible values: FILE or RDEBUG + +#FileCreationMode= OVERWRITE # Possible values: OVERWRITE or APPEND + +#ThreadIdToLogFile= YES # Possible values: YES or NO +#WithTimeStamp= YES # Possible values: YES or NO +#WithLineBreak= YES # Possible values: YES or NO +#WithEventRanking= YES # Possible values: YES or NO + +#FileUnicode= YES # Possible values: YES or NO +#AddTestCaseTitle= YES # Possible values: YES or NO +[End_Logger_Defaults] +# -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- + + + +# -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- +# Set filters to be used by ConsoleUI. +# If you want to use filter with ConsoleUI, simply remove comments +# from section below and provide valid filter entries. +# Each filter line has to start with "filter= " keyword. +# Filter can contain special wildcard characters: +# * which stands for none or any literal; +# ? which stands for single character. +# Filters are not case-sensitive. + +#[Filters] +#filter= *math* +#filter= *radio* +#[End_Filters] +# -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- + +# End of file diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/Te_locationinfoconverter/src/Te_locationinfoconversionobserver.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/Te_locationinfoconverter/src/Te_locationinfoconversionobserver.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,101 @@ +/* +* Copyright (c) 2002 - 2007 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Test module to implement Advanced trigger supervision cases +* +*/ + + + +// INCLUDE FILES +#include +#include "Te_locationinfoconversionobserver.h" + + + + +// ============================ MEMBER FUNCTIONS =============================== + +// ----------------------------------------------------------------------------- +// CTriggerFireObserver::CTriggerFireObserver +// C++ default constructor can NOT contain any code, that +// might leave. +// ----------------------------------------------------------------------------- +// +CTelocationinfoconversionobserver::CTelocationinfoconversionobserver( ):CTimer( CTimer::EPriorityStandard ) + { + + CActiveScheduler::Add(this); + } + +// ----------------------------------------------------------------------------- +// CTriggerFireObserver::ConstructL +// Symbian 2nd phase constructor can leave. +// ----------------------------------------------------------------------------- +// +void CTelocationinfoconversionobserver::ConstructL() + { + iStatusCode=KErrNone; + CTimer::ConstructL(); + + } + +// ----------------------------------------------------------------------------- +// CTriggerFireObserver::NewL +// Two-phased constructor. +// ----------------------------------------------------------------------------- +// +CTelocationinfoconversionobserver* CTelocationinfoconversionobserver::NewL( ) + { + + CTelocationinfoconversionobserver* self = new (ELeave) CTelocationinfoconversionobserver( ); + CleanupStack::PushL( self ); + self->ConstructL( ); + CleanupStack::Pop(); + return self; + + } + +// Destructor +CTelocationinfoconversionobserver::~CTelocationinfoconversionobserver() + { + Cancel(); + } + +void CTelocationinfoconversionobserver::OnConversionComplete( TInt aStatusCode ) + { + iStatusCode = aStatusCode; + CActiveScheduler::Stop(); + } + +TInt CTelocationinfoconversionobserver::ConversionResult() + { + return iStatusCode; + } + + + +void CTelocationinfoconversionobserver::RunL( ) + { + iStatusCode = KErrCancel; + CActiveScheduler::Stop(); + + } + +void CTelocationinfoconversionobserver::DoCancel( ) + { + + + } + +//End of file diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/Te_locationinfoconverter/src/Te_locationinfoconverter.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/Te_locationinfoconverter/src/Te_locationinfoconverter.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,199 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: This file contains testclass implementation. +* +*/ + +// INCLUDE FILES +#include +#include "Te_locationinfoconverter.h" +#include + +// EXTERNAL DATA STRUCTURES +//extern ?external_data; + +// EXTERNAL FUNCTION PROTOTYPES +//extern ?external_function( ?arg_type,?arg_type ); + +// CONSTANTS +//const ?type ?constant_var = ?constant; + +// MACROS +//#define ?macro ?macro_def + +// LOCAL CONSTANTS AND MACROS +//const ?type ?constant_var = ?constant; +//#define ?macro_name ?macro_def + +// MODULE DATA STRUCTURES +//enum ?declaration +//typedef ?declaration + +// LOCAL FUNCTION PROTOTYPES +//?type ?function_name( ?arg_type, ?arg_type ); + +// FORWARD DECLARATIONS +//class ?FORWARD_CLASSNAME; + +// ============================= LOCAL FUNCTIONS =============================== + +// ----------------------------------------------------------------------------- +// ?function_name ?description. +// ?description +// Returns: ?value_1: ?description +// ?value_n: ?description_line1 +// ?description_line2 +// ----------------------------------------------------------------------------- +// +/* +?type ?function_name( + ?arg_type arg, // ?description + ?arg_type arg) // ?description + { + + ?code // ?comment + + // ?comment + ?code + } +*/ + +// ============================ MEMBER FUNCTIONS =============================== + +// ----------------------------------------------------------------------------- +// CTe_locationinfoconverter::CTe_locationinfoconverter +// C++ default constructor can NOT contain any code, that +// might leave. +// ----------------------------------------------------------------------------- +// +CTe_locationinfoconverter::CTe_locationinfoconverter( + CTestModuleIf& aTestModuleIf ): + CScriptBase( aTestModuleIf ) + { + } + +// ----------------------------------------------------------------------------- +// CTe_locationinfoconverter::ConstructL +// Symbian 2nd phase constructor can leave. +// ----------------------------------------------------------------------------- +// +void CTe_locationinfoconverter::ConstructL() + { + //Read logger settings to check whether test case name is to be + //appended to log file name. + RSettingServer settingServer; + TInt ret = settingServer.Connect(); + if(ret != KErrNone) + { + User::Leave(ret); + } + // Struct to StifLogger settigs. + TLoggerSettings loggerSettings; + // Parse StifLogger defaults from STIF initialization file. + ret = settingServer.GetLoggerSettings(loggerSettings); + if(ret != KErrNone) + { + User::Leave(ret); + } + // Close Setting server session + settingServer.Close(); + + TFileName logFileName; + + if(loggerSettings.iAddTestCaseTitle) + { + TName title; + TestModuleIf().GetTestCaseTitleL(title); + logFileName.Format(KTe_locationinfoconverterLogFileWithTitle, &title); + } + else + { + logFileName.Copy(KTe_locationinfoconverterLogFile); + } + + iLog = CStifLogger::NewL( KTe_locationinfoconverterLogPath, + logFileName, + CStifLogger::ETxt, + CStifLogger::EFile, + EFalse ); + + SendTestClassVersion(); + } + +// ----------------------------------------------------------------------------- +// CTe_locationinfoconverter::NewL +// Two-phased constructor. +// ----------------------------------------------------------------------------- +// +CTe_locationinfoconverter* CTe_locationinfoconverter::NewL( + CTestModuleIf& aTestModuleIf ) + { + CTe_locationinfoconverter* self = new (ELeave) CTe_locationinfoconverter( aTestModuleIf ); + + CleanupStack::PushL( self ); + self->ConstructL(); + CleanupStack::Pop(); + + return self; + + } + +// Destructor +CTe_locationinfoconverter::~CTe_locationinfoconverter() + { + + // Delete resources allocated from test methods + Delete(); + + // Delete logger + delete iLog; + + } + +//----------------------------------------------------------------------------- +// CTe_locationinfoconverter::SendTestClassVersion +// Method used to send version of test class +//----------------------------------------------------------------------------- +// +void CTe_locationinfoconverter::SendTestClassVersion() + { + TVersion moduleVersion; + moduleVersion.iMajor = TEST_CLASS_VERSION_MAJOR; + moduleVersion.iMinor = TEST_CLASS_VERSION_MINOR; + moduleVersion.iBuild = TEST_CLASS_VERSION_BUILD; + + TFileName moduleName; + moduleName = _L("Te_locationinfoconverter.dll"); + + TBool newVersionOfMethod = ETrue; + TestModuleIf().SendTestModuleVersion(moduleVersion, moduleName, newVersionOfMethod); + } + +// ========================== OTHER EXPORTED FUNCTIONS ========================= + +// ----------------------------------------------------------------------------- +// LibEntryL is a polymorphic Dll entry point. +// Returns: CScriptBase: New CScriptBase derived object +// ----------------------------------------------------------------------------- +// +EXPORT_C CScriptBase* LibEntryL( + CTestModuleIf& aTestModuleIf ) // Backpointer to STIF Test Framework + { + + return ( CScriptBase* ) CTe_locationinfoconverter::NewL( aTestModuleIf ); + + } + + +// End of File diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/Te_locationinfoconverter/src/Te_locationinfoconverterBlocks.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/Te_locationinfoconverter/src/Te_locationinfoconverterBlocks.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,712 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: This file contains testclass implementation. +* +*/ + +// [INCLUDE FILES] - do not remove +#include +#include +#include +#include +#include "Te_locationinfoconverter.h" +#include +#include +#include +#include +#include + +// EXTERNAL DATA STRUCTURES +//extern ?external_data; + +// EXTERNAL FUNCTION PROTOTYPES +//extern ?external_function( ?arg_type,?arg_type ); + +// CONSTANTS +//const ?type ?constant_var = ?constant; + +// MACROS +//#define ?macro ?macro_def +#define KTestLatitude 10 +#define KTestLongitude 20 +#define KTestAltitude 30 +#define KTestHorizontalaccuracy 30 +#define KTestVerticalaccuracy 40 + +// LOCAL CONSTANTS AND MACROS +//const ?type ?constant_var = ?constant; +//#define ?macro_name ?macro_def +//Tags used in cfg file +_LIT(KLatitude, "LATITUDE= "); +_LIT(KLongitude, "LONGITUDE= "); +_LIT(KAltitude, "ALTITUDE= "); +_LIT(KHorizontalAccuracy, "HA= "); +_LIT(KVerticalAccuracy, "VA= "); +_LIT(KCountrycode, "COUNTRYCODE= "); +_LIT(KNetworkcode, "NETWORKCODE= "); +_LIT(KLocationcode, "LOCATIONCODE= "); +_LIT(KCellid, "CELLID= "); +_LIT(KRxlev, "RXLEV= "); +_LIT(KTimingAdvance, "TIMINGADVANCE= "); +_LIT(KNeighbouringcells, "NEIGHBOURCELLS= "); +_LIT(KArfcn, "ARFCN= "); +_LIT(KColourcode, "CCODE= "); +_LIT(KNeighbourRxlev, "NRXLEV= "); +_LIT(KScramblingcode, "SCODE= "); +_LIT(KNeighbourCellid, "NCELLID= "); +_LIT(KNeighbourScramblingcode, "NSCODE= "); +_LIT(KMacId, "MACID= "); +_LIT(KSignalstrength, "SIGNAL= "); +_LIT(KNeighbourPathloss, "NPATHLOSS= "); +_LIT(KNeighbourSignalstrength, "NSIGNAL= "); + +// MODULE DATA STRUCTURES +//enum ?declaration +//typedef ?declaration + +// LOCAL FUNCTION PROTOTYPES +//?type ?function_name( ?arg_type, ?arg_type ); + +// FORWARD DECLARATIONS +//class ?FORWARD_CLASSNAME; + +// ============================= LOCAL FUNCTIONS =============================== + +// ----------------------------------------------------------------------------- +// ?function_name ?description. +// ?description +// Returns: ?value_1: ?description +// ?value_n: ?description_line1 +// ?description_line2 +// ----------------------------------------------------------------------------- +// +/* +?type ?function_name( + ?arg_type arg, // ?description + ?arg_type arg) // ?description + { + + ?code // ?comment + + // ?comment + ?code + } +*/ + +// ============================ MEMBER FUNCTIONS =============================== + +// ----------------------------------------------------------------------------- +// CTe_locationinfoconverter::Delete +// Delete here all resources allocated and opened from test methods. +// Called from destructor. +// ----------------------------------------------------------------------------- +// +void CTe_locationinfoconverter::Delete() + { + + } + +// ----------------------------------------------------------------------------- +// CTe_locationinfoconverter::RunMethodL +// Run specified method. Contains also table of test mothods and their names. +// ----------------------------------------------------------------------------- +// +TInt CTe_locationinfoconverter::RunMethodL( + CStifItemParser& aItem ) + { + + static TStifFunctionInfo const KFunctions[] = + { + // Copy this line for every implemented function. + // First string is the function name used in TestScripter script file. + // Second is the actual implementation member function. + ENTRY( "ConvertLocationInfo", CTe_locationinfoconverter::ConvertLocationInfoL ), + ENTRY( "Misc", CTe_locationinfoconverter::MiscL ), + ENTRY( "CreateLocationInfoConverter", CTe_locationinfoconverter::CreateLocationInfoConverterL ), + ENTRY( "SetCoordinateInfo", CTe_locationinfoconverter::SetCoordinateInfoL ), + ENTRY( "SetGSMCellInfo", CTe_locationinfoconverter::SetGSMCellInfoL ), + ENTRY( "SetWCDMACellInfo", CTe_locationinfoconverter::SetWCDMACellInfoL ), + ENTRY( "SetWLanInfo", CTe_locationinfoconverter::SetWLanInfoL ), + ENTRY( "AddLocationInfo", CTe_locationinfoconverter::AddLocationInfoL ), + ENTRY( "ValidateLocationInfo", CTe_locationinfoconverter::ValidateLocationInfoL ), + ENTRY( "Cleanup", CTe_locationinfoconverter::Cleanup ), + //ADD NEW ENTRY HERE + // [test cases entries] - Do not remove + + }; + + const TInt count = sizeof( KFunctions ) / + sizeof( TStifFunctionInfo ); + + return RunInternalL( KFunctions, count, aItem ); + + } + +// ----------------------------------------------------------------------------- +// CTe_locationinfoconverter::CreateLocationInfoConverterL +// Creates and initializes Location info converter object +// (other items were commented in a header). +// ----------------------------------------------------------------------------- +// +TInt CTe_locationinfoconverter::CreateLocationInfoConverterL( CStifItemParser& aItem ) + { + iLog->Log(_L("CovertLocationInfoL Function")); +// TUint Uidinteger = 537028467; // SUPL + TUint Uidinteger = 537007117; // Example + TUid uid = TUid::Uid( Uidinteger ); + + aItem.GetNextInt(Uidinteger); + + iObserver = CTelocationinfoconversionobserver::NewL(); + ilbslocationinfo = CLbsLocationInfo::NewL(); + if(Uidinteger!=0) + { + ilbslocationinfoconverter = CLbsLocationInfoConverter::NewL(*iObserver,uid); + } + else + { + iLog->Log(_L("CovertLocationInfoL Function : Creating")); + ilbslocationinfoconverter = CLbsLocationInfoConverter::NewL(*iObserver); + } + iLog->Log(_L("CovertLocationInfoL Function end")); + return KErrNone; + + } + +// ----------------------------------------------------------------------------- +// CTe_locationinfoconverter::SetCoordinateInfoL +// Converts one location info to its corresponding position info. +// (other items were commented in a header). +// ----------------------------------------------------------------------------- +// +TInt CTe_locationinfoconverter::SetCoordinateInfoL( CStifItemParser& aItem ) + { + TInt fntype; + aItem.GetNextInt(fntype); + TPtrC Llatidude,Llongitude,Laltidude,Lhoracc,LVerAcc; + aItem.GetNextString( KLatitude, Llatidude); + aItem.GetNextString( KLongitude, Llongitude); + aItem.GetNextString( KAltitude, Laltidude); + aItem.GetNextString( KHorizontalAccuracy, Lhoracc); + aItem.GetNextString( KVerticalAccuracy, LVerAcc); + + TReal64 latitude =0 ; + TLex16 lat(Llatidude); + lat.Val(latitude); + + TReal64 longitude =0; + TLex16 longi(Llongitude); + longi.Val(longitude); + + TReal32 Altitude =0; + TLex16 Alt(Laltidude); + Alt.Val(Altitude); + + TReal32 HorizontalAccuracy =0; + TLex16 HA(Lhoracc); + HA.Val(HorizontalAccuracy); + + TReal32 VerticalAccuracy =0; + TLex16 VA(LVerAcc); + VA.Val(VerticalAccuracy); + TLocality Locality; + if(latitude!=0 && longitude!=0 && Altitude==0) + { + Locality.SetCoordinate(latitude,longitude); + } + else if (latitude!=0 && longitude!=0 && Altitude!=0) + { + Locality.SetCoordinate(latitude,longitude,Altitude); + } + + + if(HorizontalAccuracy!=0 ) + { + Locality.SetHorizontalAccuracy(HorizontalAccuracy); + } + if(VerticalAccuracy!=0 ) + { + Locality.SetVerticalAccuracy(VerticalAccuracy); + } + + CLbsPositionInfo* Posinfo; + if(fntype==1) + { + Posinfo=CLbsPositionInfo::NewL( Locality); + } + else if(fntype==2) + { + Posinfo=CLbsPositionInfo::NewL(); + Posinfo->SetLocality(Locality); + } + + ilbslocationinfo->AddAreaInfoL(Posinfo); + return KErrNone; + } + + +// ----------------------------------------------------------------------------- +// CTe_locationinfoconverter::SetGSMCellInfoL +// . +// (other items were commented in a header). +// ----------------------------------------------------------------------------- +// +TInt CTe_locationinfoconverter::SetGSMCellInfoL( CStifItemParser& aItem ) + { + TInt fntype; + aItem.GetNextInt(fntype); + TInt countrycode=-2,networkcode=-2,locationcode=-2,cellid=-2,timingadvance=-2,Rxlev=-2,nNeignbourcells=0,arfcn=-2,bsic=-2,NRxlev=-2; + aItem.GetNextInt( KCountrycode, countrycode); + aItem.GetNextInt( KNetworkcode, networkcode); + aItem.GetNextInt( KLocationcode, locationcode); + aItem.GetNextInt( KCellid, cellid); + aItem.GetNextInt( KTimingAdvance, timingadvance); + aItem.GetNextInt( KRxlev, Rxlev); + aItem.GetNextInt( KNeighbouringcells, nNeignbourcells); + + CLbsGsmCellInfo* gsmcellinfo; + if(fntype==1) + { + gsmcellinfo=CLbsGsmCellInfo::NewL( countrycode,networkcode,locationcode,cellid); + if(timingadvance!=-2) + { + gsmcellinfo->SetTimingAdvance(timingadvance); + } + if(Rxlev!=-2) + { + gsmcellinfo->SetRxLevel(Rxlev); + } + if(nNeignbourcells!=0) + { + TLbsGsmNeighbourCellInfo neighbourcell; + for(TInt i =0 ; iAddNeighbouringCellInfoL(&neighbourcell); + + } + } + } + else if(fntype==2) + { + gsmcellinfo=CLbsGsmCellInfo::NewL(); + if(countrycode!=-2) + { + gsmcellinfo->SetMobileCountryCode(countrycode); + } + if(networkcode!=-2) + { + gsmcellinfo->SetMobileNetworkCode(networkcode); + } + if(locationcode!=-2) + { + gsmcellinfo->SetLocationAreaCode(locationcode); + } + if(cellid!=-2) + { + gsmcellinfo->SetCellId(cellid); + } + if(timingadvance!=-2) + { + gsmcellinfo->SetTimingAdvance(timingadvance); + } + if(Rxlev!=-2) + { + gsmcellinfo->SetRxLevel(Rxlev); + } + if(nNeignbourcells!=0) + { + + + for(TInt i =0 ; iAddNeighbouringCellInfoL(&neighbourcell); + + } + } + } + + ilbslocationinfo->AddAreaInfoL(gsmcellinfo); + return KErrNone; + } + +// ----------------------------------------------------------------------------- +// CTe_locationinfoconverter::SetWCDMACellInfoL +// . +// (other items were commented in a header). +// ----------------------------------------------------------------------------- +// +TInt CTe_locationinfoconverter::SetWCDMACellInfoL( CStifItemParser& aItem ) + { + TInt fntype; + aItem.GetNextInt(fntype); + TInt countrycode=-2,networkcode=-2,cellid=-2,nNeignbourcells=0,scramblingcode=-2,neighbourucid=-2,neighbourscode=-2,neighbourpathloss=-2,neighboursignalstrength=-2; + aItem.GetNextInt( KCountrycode, countrycode); + aItem.GetNextInt( KNetworkcode, networkcode); + + aItem.GetNextInt( KCellid, cellid); + aItem.GetNextInt( KScramblingcode, scramblingcode); + + aItem.GetNextInt( KNeighbouringcells, nNeignbourcells); + + CLbsWcdmaCellInfo* wcdmacellinfo; + if(fntype==1) + { + wcdmacellinfo=CLbsWcdmaCellInfo::NewL( countrycode,networkcode,cellid); + if(scramblingcode!=-2) + { + wcdmacellinfo->SetScramblingCode(scramblingcode); + } + if(nNeignbourcells!=0) + { + TLbsWcdmaNeighbourCellInfo neighbourcell; + for(TInt i =0 ; iAddNeighbouringCellInfoL(&neighbourcell); + } + } + } + else if(fntype==2) + { + wcdmacellinfo=CLbsWcdmaCellInfo::NewL(); + if(countrycode!=-2) + { + wcdmacellinfo->SetMobileCountryCode(countrycode); + } + if(networkcode!=-2) + { + wcdmacellinfo->SetMobileNetworkCode(networkcode); + } + if(cellid!=-2) + { + wcdmacellinfo->SetUniqueCellId(cellid); + } + if(scramblingcode!=-2) + { + wcdmacellinfo->SetScramblingCode(scramblingcode); + } + if(nNeignbourcells!=0) + { + for(TInt i =0 ; iAddNeighbouringCellInfoL(&neighbourcell); + } + } + } + + ilbslocationinfo->AddAreaInfoL(wcdmacellinfo); + return KErrNone; + } + +// ----------------------------------------------------------------------------- +// CTe_locationinfoconverter::SetWLanInfoL +// . +// (other items were commented in a header). +// ----------------------------------------------------------------------------- +// +TInt CTe_locationinfoconverter::SetWLanInfoL( CStifItemParser& aItem ) + { + TInt fntype; + aItem.GetNextInt(fntype); + TPtrC macid; + TInt signalstrength=-2; + aItem.GetNextString( KMacId, macid); + aItem.GetNextInt( KSignalstrength, signalstrength); + TBuf8<6> macidbuf; + macidbuf.Copy(macid); + CLbsWlanInfo* wlaninfo; + if(fntype==1) + { + wlaninfo=CLbsWlanInfo::NewL( macidbuf,signalstrength); + } + else if(fntype==2) + { + wlaninfo=CLbsWlanInfo::NewL(); + if (macidbuf.Length()!=0) + { + wlaninfo->SetMacAddress(macidbuf); + } + if(signalstrength!=-2) + { + wlaninfo->SetSignalStrength(signalstrength); + } + } + ilbslocationinfo->AddAreaInfoL(wlaninfo); + return KErrNone; + } +// ----------------------------------------------------------------------------- +// CTe_locationinfoconverter::AddLocationInfoL +// Converts one location info to its corresponding position info. +// (other items were commented in a header). +// ----------------------------------------------------------------------------- +// +TInt CTe_locationinfoconverter::AddLocationInfoL( CStifItemParser& aItem ) + { + TInt nTimes =1; + aItem.GetNextInt(nTimes); + ilbslocationinfoarrayTemp.Append(ilbslocationinfo); + for (TInt i=0 ; iConvertLocationInfoL(*ilbslocationinfoarray[0],conversionprefs,requestedinfo); + } + else if (fntype==2) + { + ilbslocationinfoconverter->ConvertLocationInfoL(ilbslocationinfoarray,conversionprefs,requestedinfo); + } + ) + + if(err) + return err; + + CActiveScheduler::Start(); + + return KErrNone; + } + +// ----------------------------------------------------------------------------- +// CTe_locationinfoconverter::CancelConvertLocationInfo +// Converts one location info to its corresponding position info. +// (other items were commented in a header). +// ----------------------------------------------------------------------------- +// +TInt CTe_locationinfoconverter::MiscL( CStifItemParser& aItem) + { + TInt testcase ; + aItem.GetNextInt(testcase); + switch(testcase) + { + case 1: + ilbslocationinfoconverter->ConvertLocationInfoL(*ilbslocationinfo,0,1); + ilbslocationinfoconverter->CancelConvertLocationInfo(); + iObserver->After(1500000); + CActiveScheduler::Start(); + break; + case 2: + ilbslocationinfoconverter->ConvertLocationInfoL(*ilbslocationinfo,0,1); + CActiveScheduler::Start(); + ilbslocationinfoconverter->CancelConvertLocationInfo(); + + break; + case 3: + + ilbslocationinfoconverter->CancelConvertLocationInfo(); + + break; + case 4: + TestModuleIf().SetExitReason( CTestModuleIf::EPanic, 0); + ilbslocationinfoconverter->ConvertLocationInfoL(*ilbslocationinfo,0,1); + ilbslocationinfoconverter->ConvertLocationInfoL(*ilbslocationinfo,0,1); + + break; + case 5: + ilbslocationinfoconverter->ConvertLocationInfoL(ilbslocationinfoarray,0,1); + ilbslocationinfoconverter->CancelConvertLocationInfo(); + iObserver->After(1500000); + CActiveScheduler::Start(); + break; + case 6: + ilbslocationinfoconverter->ConvertLocationInfoL(ilbslocationinfoarray,0,1); + CActiveScheduler::Start(); + ilbslocationinfoconverter->CancelConvertLocationInfo(); + + break; + case 7: + + ilbslocationinfoconverter->CancelConvertLocationInfo(); + + break; + case 8: + TestModuleIf().SetExitReason( CTestModuleIf::EPanic, 0); + ilbslocationinfoconverter->ConvertLocationInfoL(ilbslocationinfoarray,0,1); + ilbslocationinfoconverter->ConvertLocationInfoL(ilbslocationinfoarray,0,1); + + break; + + } + + + return iObserver->ConversionResult();; + } + + + +TInt CTe_locationinfoconverter::ValidateLocationInfoL( CStifItemParser& aItem) + { + + if( iObserver->ConversionResult() == KErrNotSupported || + iObserver->ConversionResult() == KErrNotFound ) + return KErrNone; + + if( iObserver->ConversionResult() == KErrNone ) + { + TInt requestedinfo =1; + aItem.GetNextInt(requestedinfo); + if(requestedinfo ==1) + { + TInt count = ilbslocationinfoarray.Count(); + for(TInt i=0; i PosInfoList; + static_cast(ilbslocationinfoarray[i])->GetAreaInfoL(PosInfoList,CLbsLocationInfo::ELbsPosInfo); + TInt count2 = PosInfoList.Count(); + PosInfoList.Reset(); + PosInfoList.Close(); + if(count2>=1) + { + return KErrNone; + } + } + return KErrGeneral; + } + } + + return iObserver->ConversionResult(); + } + +TInt CTe_locationinfoconverter::Cleanup( CStifItemParser& aItem ) + { + if(iObserver) + { + delete iObserver; + } + if(ilbslocationinfo) + { + delete ilbslocationinfo; + } + if(ilbslocationinfoconverter) + { + delete ilbslocationinfoconverter; + } + ilbslocationinfoarrayTemp.ResetAndDestroy(); + ilbslocationinfoarray.Reset(); + + return KErrNone; + } + +// ----------------------------------------------------------------------------- +// CTe_locationinfoconverter::?member_function +// ?implementation_description +// (other items were commented in a header). +// ----------------------------------------------------------------------------- +// +/* +TInt CTe_locationinfoconverter::?member_function( + CItemParser& aItem ) + { + + ?code + + } +*/ + +// ========================== OTHER EXPORTED FUNCTIONS ========================= +// None + +// [End of File] - Do not remove diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/TestLocationConverter/data/10287201.rss --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/TestLocationConverter/data/10287201.rss Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,45 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Resource file for movement detector plugin +* +*/ +// mydetector.rss +// +#include + +#include "TestLocationConverter.hrh" +#include + +RESOURCE REGISTRY_INFO theInfo +{ +dll_uid = KTestLocationConverterUid; +interfaces = + { + INTERFACE_INFO + { + interface_uid = KLbsLocInfoConverterPlugInInterfaceId; + implementations = + { + IMPLEMENTATION_INFO + { + implementation_uid = KTestLocationConverterImplementationUid; + version_no = 1; + display_name = "Test location info converter"; + default_data = "text/ascii"; + opaque_data = "priority:2"; + } + }; + } + }; +} diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/TestLocationConverter/data/TestLocationConverter.hrh --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/TestLocationConverter/data/TestLocationConverter.hrh Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,26 @@ +/* +* Copyright (c) 2007 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Resource headers for project +* +*/ + + +#ifndef TESTLOCATIONCONVERTER_HRH +#define TESTLOCATIONCONVERTER_HRH + +#define KTestLocationConverterUid 0x2002150C +#define KTestLocationConverterImplementationUid 0x2002150D + + +#endif // TESTLOCATIONCONVERTER_HRH diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/TestLocationConverter/group/TestLocationConverter.mmp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/TestLocationConverter/group/TestLocationConverter.mmp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,50 @@ +/* +* Copyright (c) 2006-2007 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Project definition file for project Cell Id movement detector +* +*/ + + +#include "../data/TestLocationConverter.hrh" + +TARGET TestLocationConverter.dll +TARGETTYPE PLUGIN +UID 0x10009D8D KTestLocationConverterUid +VENDORID 0x2002140e + +CAPABILITY ALL -TCB + +OS_LAYER_SYSTEMINCLUDE + +USERINCLUDE ../inc +USERINCLUDE ../data + +SOURCEPATH ../src +SOURCE TestLocationConverter.cpp + +START RESOURCE ../data/10287201.rss +TARGET TestLocationConverter.rsc +END + +LIBRARY euser.lib +LIBRARY ecom.lib +LIBRARY commdb.lib +LIBRARY flogger.lib +LIBRARY lbslocationinfoconverterplugin.lib +LIBRARY lbslocationinfodatatypes.lib +LIBRARY lbs.lib + +PAGED + +SMPSAFE diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/TestLocationConverter/group/bld.inf --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/TestLocationConverter/group/bld.inf Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,25 @@ +/* +* Copyright (c) 2006 - 2007 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Build information file for project ?myapp +* +*/ + + +PRJ_PLATFORMS +DEFAULT + +PRJ_TESTMMPFILES +TestLocationConverter.mmp + +// END OF FILE diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/TestLocationConverter/inc/TestLocationConverter.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/TestLocationConverter/inc/TestLocationConverter.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,122 @@ +/* +* Copyright (c) 2008 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Definition of Movement Detection API +* +*/ + + +#ifndef C_TESTLOCATIONCONVERTER_H +#define C_TESTLOCATIONCONVERTER_H + +#include + +#include +#include +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +/** + * CTestLocationConverter is an ECom plugin that implements CLbsLocInfoConversionPluginBase. + * + * This class is responsible for monitering movement of mobile based on + * GSM information available to mobile at any instant. + * + * @lib movementdetector.lib + * @since S60 v4.0 + */ +class CTestLocationConverter : public CLbsLocInfoConverterPluginBase + + { + +public: + + /** + * Loads a location info conveter and initalises it. + * + * @param[in] aObserver An observer for location conversion event. + * @param[in] aPluginArgs Agruements sent to conversion plugin. + * return Pointer to the new loation info converter.If module id is not specified + * default plug in will be loaded. + */ + static CTestLocationConverter* NewL( TLbsLocInfoConverterPluginParams& aPluginParams ); + + /** + * Unloads this movement detector. + * + * @since S60 TACO + */ + virtual ~CTestLocationConverter(); + + // From CLbsLocInfoConversionPluginBase + + /** + * Converts the area informations of a group of geographical locations + * to its corresponding position information. + * + * @param[in] aLocationInfoArray Array of location informations corresponding + * to geographical locations are passed and on successful completion of this + * method,position information corresponding to the loation informations are + * updated in each area info object. + * @param[in] aConversionPrefs Conversion preferences suggested by client. + * + * @leave KErrArgument If the location info array is empty. + */ + virtual void ConvertLocationInfoL( + RLbsLocationInfoArray& aLocationInfoArray, + const TLbsConversionPrefs aConversionPrefs, + const TLbsConversionOutputInfoMask aRequestedInfo ); + + /** + * Cancels get location info operation. + */ + virtual void CancelConvertLocationInfo(); + + virtual void ValidateClient( const TSecureId& aSecureId, + const TVendorId& aVendorId, + const TLbsConversionOutputInfoMask aRequestedInfo ); + + virtual void CancelValidateClient(); + + virtual void ConversionPluginPreferences( + TLbsConversionPluginInfo& aPluginInfo ); + +private: + + + void ConstructL(TLbsLocInfoConverterPluginParams& aPluginParams); + + /** + * Default C++ Constructor + */ + CTestLocationConverter(TLbsLocInfoConverterPluginParams& aParams); + +private: // data + + MLbsLocInfoConverterPluginObserver &iObserver; + TBool iRetainLocalityInCache; + }; + + +#endif // C_TESTLOCATIONCONVERTER_H diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/TestLocationConverter/src/TestLocationConverter.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/TestLocationConverter/src/TestLocationConverter.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,321 @@ +/* +* Copyright (c) 2008 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Definition of CdummyMvmtDet class. +* +*/ + + + +#include +#include +#include +#include "TestLocationConverter.h" + +// the test code sets the timing advance in the GSM vell info to this value +// which instructs the test converter to constuct TLocalitys with +// latitude ser to country code, longitude set to +// network code and altitiude set to local area code +const TInt KTimingAdvanceSpecialValue= 254; + +const TInt KTimingAdvanceSaveToCacheTrue= 253; + +const TInt KTimingAdvanceSaveToCacheFalse= 252; + +// ECOM implementation specifics +static const TImplementationProxy implTable[] = + { + IMPLEMENTATION_PROXY_ENTRY(0x2002150D, CTestLocationConverter::NewL) + }; + + +EXPORT_C const TImplementationProxy* ImplementationGroupProxy(TInt& aTableCount) + { + aTableCount = sizeof(implTable) / sizeof(TImplementationProxy); + + return implTable; + } + + +// Class methods + +//------------------------------------------------------------ +// CLbsLocInfoConversionPluginBase::NewL +// Symbian Two - phase constructor +//------------------------------------------------------------ +// +CTestLocationConverter* CTestLocationConverter::NewL( TLbsLocInfoConverterPluginParams& aParams) + { + CTestLocationConverter* self = new (ELeave) CTestLocationConverter(aParams); + CleanupStack::PushL(self); + self->ConstructL(aParams); + CleanupStack::Pop(); + return self; + } + + +//------------------------------------------------------------ +// CLbsLocInfoConversionPluginBase::ConstructL +//------------------------------------------------------------ +// +void CTestLocationConverter::ConstructL( TLbsLocInfoConverterPluginParams& /*aParams*/ ) + { + + + } + + +//----------------------------------------------------------------- +// CLbsLocInfoConversionPluginBase::CLbsLocInfoConversionPluginBase +// C++ Default constructor +//------------------------------------------------------------------ +// +CTestLocationConverter::CTestLocationConverter(TLbsLocInfoConverterPluginParams& aParams):iObserver(aParams.Observer()), + iRetainLocalityInCache(ETrue) + { + + } + + +//------------------------------------------------------------ +// CLbsLocInfoConversionPluginBase::~CLbsLocInfoConversionPluginBase +// Destructor +//------------------------------------------------------------ +// +CTestLocationConverter::~CTestLocationConverter() + { + + } + + +//------------------------------------------------------------ +// CLbsLocInfoConversionPluginBase::ConvertLocationInfoL +//------------------------------------------------------------ +// +void CTestLocationConverter::ConvertLocationInfoL( RLbsLocationInfoArray& aLocationInfoArray, + const TLbsConversionPrefs /*aConversionPrefs*/, + const TLbsConversionOutputInfoMask aRequestedInfo) + { + if(aRequestedInfo == ELbsConversionOutputNotDefined) + { + iObserver.OnConversionComplete(KErrArgument); + return; + } + TInt count = aLocationInfoArray.Count(); + for(TInt i=0 ; iGetAreaInfoL( areaInfoArray,areaInfoMask ); + TInt count = areaInfoArray.Count(); + + + + if( count == 0 ) + { + iObserver.OnConversionComplete(KErrNotSupported); + return; + } + // + CLbsGsmCellInfo* posInfo = static_cast( areaInfoArray[0] ); + + TInt timingAdvance = posInfo->TimingAdvance(); + + TLocality locality; + if (timingAdvance == KTimingAdvanceSpecialValue) + { + TReal64 lat = posInfo->MobileCountryCode() ; + TReal64 lng = posInfo->MobileNetworkCode(); + TReal32 alt = posInfo->LocationAreaCode(); + locality.SetCoordinate( lat,lng, alt); + } + else + { + locality.SetCoordinate( 82.5285,35.9385, 2.22f); + } + +// if (timingAdvance == KTimingAdvanceSaveToCacheTrue) +// { +// TReal64 lat = posInfo->MobileCountryCode() ; +// TReal64 lng = posInfo->MobileNetworkCode(); +// TReal32 alt = posInfo->LocationAreaCode(); +// locality.SetCoordinate( lat,lng, alt); +// iRetainLocalityInCache = ETrue; +// } +// else if (timingAdvance == KTimingAdvanceSaveToCacheFalse) +// { +// TReal64 lat = posInfo->MobileCountryCode() ; +// TReal64 lng = posInfo->MobileNetworkCode(); +// TReal32 alt = posInfo->LocationAreaCode(); +// locality.SetCoordinate( lat,lng, alt); +// iRetainLocalityInCache = EFalse; +// } + + if (timingAdvance == KTimingAdvanceSaveToCacheFalse) + { + TReal64 lat = posInfo->MobileCountryCode(); + TReal64 lng = posInfo->MobileNetworkCode(); + TReal32 alt = posInfo->LocationAreaCode(); + locality.SetCoordinate(lat, lng, alt); + iRetainLocalityInCache = EFalse; + } + else + { + iRetainLocalityInCache = ETrue; + } + + + areaInfoArray.ResetAndDestroy(); + + locality.SetAccuracy( 100,0.0 ); + CLbsPositionInfo* positionInfo = CLbsPositionInfo::NewL( locality ); + CleanupStack::PushL( positionInfo ); + aLocationInfoArray[i]->AddAreaInfoL( positionInfo ); + CleanupStack::Pop( positionInfo ); + break; + } + case ELbsConversionOutputGsm: + { + // Extract the area info provided by the client. + // If client has specified only gsm info, + // return KErrNotSupported. + RLbsAreaInfoBaseArray areaInfoArray; + CLbsLocationInfo::TAreaInfoMask areaInfoMask = 0; + areaInfoMask |= CLbsLocationInfo::ELbsPosInfo | + CLbsLocationInfo::ELbsWcdmaInfo | + CLbsLocationInfo::ELbsWlanInfo; + aLocationInfoArray[i]->GetAreaInfoL( areaInfoArray,areaInfoMask ); + TInt count = areaInfoArray.Count(); + areaInfoArray.ResetAndDestroy(); + + if( count == 0 ) + { + iObserver.OnConversionComplete(KErrNotSupported); + return; + } + + CLbsGsmCellInfo* gsmCellInfo = CLbsGsmCellInfo::NewL( 200,201,202,203); + CleanupStack::PushL( gsmCellInfo ); + aLocationInfoArray[i]->AddAreaInfoL( gsmCellInfo ); + CleanupStack::Pop( gsmCellInfo ); + break; + } + case ELbsConversionOutputWcdma: + { + // Extract the area info provided by the client. + // If client has specified only wcdma info, + // return KErrNotSupported. + RLbsAreaInfoBaseArray areaInfoArray; + CLbsLocationInfo::TAreaInfoMask areaInfoMask = 0; + areaInfoMask |= CLbsLocationInfo::ELbsPosInfo | + CLbsLocationInfo::ELbsGsmInfo | + CLbsLocationInfo::ELbsWlanInfo; + aLocationInfoArray[i]->GetAreaInfoL( areaInfoArray,areaInfoMask ); + TInt count = areaInfoArray.Count(); + areaInfoArray.ResetAndDestroy(); + + if( count == 0 ) + { + iObserver.OnConversionComplete(KErrNotSupported); + return; + } + + CLbsWcdmaCellInfo* wcdmaCellInfo = CLbsWcdmaCellInfo::NewL( 200,201,202 ); + CleanupStack::PushL( wcdmaCellInfo ); + aLocationInfoArray[i]->AddAreaInfoL( wcdmaCellInfo ); + CleanupStack::Pop( wcdmaCellInfo ); + break; + } + case ELbsConversionOutputWlan: + { + // Extract the area info provided by the client. + // If client has specified only wlan info, + // return KErrNotSupported. + RLbsAreaInfoBaseArray areaInfoArray; + CLbsLocationInfo::TAreaInfoMask areaInfoMask = 0; + areaInfoMask |= CLbsLocationInfo::ELbsPosInfo | + CLbsLocationInfo::ELbsGsmInfo | + CLbsLocationInfo::ELbsWcdmaInfo; + aLocationInfoArray[i]->GetAreaInfoL( areaInfoArray,areaInfoMask ); + TInt count = areaInfoArray.Count(); + areaInfoArray.ResetAndDestroy(); + + if( count == 0 ) + { + iObserver.OnConversionComplete(KErrNotSupported); + return; + } + + TLbsWlanMacAddress macAddress(_L8("10.0.1")); + CLbsWlanInfo* WlanInfo = CLbsWlanInfo::NewL( macAddress,10.1); + CleanupStack::PushL( WlanInfo ); + aLocationInfoArray[i]->AddAreaInfoL( WlanInfo ); + CleanupStack::Pop( WlanInfo ); + } + default: + break; + } + + } + iObserver.OnConversionComplete(KErrNone); + } + +//------------------------------------------------------------ +// CLbsLocInfoConversionPluginBase::ConvertLocationInfoL +//------------------------------------------------------------ +// +void CTestLocationConverter::CancelConvertLocationInfo( ) + { + + } + +//------------------------------------------------------------ +// CLbsLocInfoConversionPluginBase::ValidateClient +//------------------------------------------------------------ +// +void CTestLocationConverter::ValidateClient( const TSecureId& /*aSecureId*/, + const TVendorId& /*aVendorId*/, + const TLbsConversionOutputInfoMask /*aRequestedInfo*/ ) + { + iObserver.OnValidationComplete( KErrNone ); + } + +//------------------------------------------------------------ +// CLbsLocInfoConversionPluginBase::ValidateClient +//------------------------------------------------------------ +// +void CTestLocationConverter::CancelValidateClient() + { + + } + +//------------------------------------------------------------ +// CExampleLocationConverter::ConversionPluginPreferences +//------------------------------------------------------------ +// +void CTestLocationConverter::ConversionPluginPreferences( + TLbsConversionPluginInfo& aPluginInfo ) + { + aPluginInfo.SetIsPluginPositionToBeCached(iRetainLocalityInCache); + //aPluginInfo.SetIsPluginPositionToBeCached(ETrue); + } diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/TestLocationConverter2/data/10287201.rss --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/TestLocationConverter2/data/10287201.rss Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,45 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Resource file for movement detector plugin +* +*/ +// mydetector.rss +// +#include + +#include "TestLocationConverter2.hrh" +#include + +RESOURCE REGISTRY_INFO theInfo +{ +dll_uid = KTestLocationConverter2Uid; +interfaces = + { + INTERFACE_INFO + { + interface_uid = KLbsLocInfoConverterPlugInInterfaceId; + implementations = + { + IMPLEMENTATION_INFO + { + implementation_uid = KTestLocationConverter2ImplementationUid; + version_no = 1; + display_name = "Test location info converter 2"; + default_data = "text/ascii"; + opaque_data = "priority:3"; + } + }; + } + }; +} diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/TestLocationConverter2/data/TestLocationConverter2.hrh --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/TestLocationConverter2/data/TestLocationConverter2.hrh Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,26 @@ +/* +* Copyright (c) 2007 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Resource headers for project +* +*/ + + +#ifndef TESTLOCATIONCONVERTER2_HRH +#define TESTLOCATIONCONVERTER2_HRH + +#define KTestLocationConverter2Uid 0x2002160C +#define KTestLocationConverter2ImplementationUid 0x2002160D + + +#endif // TESTLOCATIONCONVERTER2_HRH diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/TestLocationConverter2/group/TestLocationConverter2.mmp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/TestLocationConverter2/group/TestLocationConverter2.mmp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,50 @@ +/* +* Copyright (c) 2006-2007 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Project definition file for project Cell Id movement detector +* +*/ + + +#include "../data/TestLocationConverter2.hrh" + +TARGET TestLocationConverter2.dll +TARGETTYPE PLUGIN +UID 0x10009D8D KTestLocationConverter2Uid +VENDORID 0x70000001 + +CAPABILITY ALL -TCB + +OS_LAYER_SYSTEMINCLUDE + +USERINCLUDE ../inc +USERINCLUDE ../data + +SOURCEPATH ../src +SOURCE TestLocationConverter2.cpp + +START RESOURCE ../data/10287201.rss +TARGET TestLocationConverter2.rsc +END + +LIBRARY euser.lib +LIBRARY ecom.lib +LIBRARY commdb.lib +LIBRARY flogger.lib +LIBRARY lbslocationinfoconverterplugin.lib +LIBRARY lbslocationinfodatatypes.lib +LIBRARY lbs.lib + +PAGED + +SMPSAFE diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/TestLocationConverter2/group/bld.inf --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/TestLocationConverter2/group/bld.inf Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,25 @@ +/* +* Copyright (c) 2006 - 2007 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Build information file for project ?myapp +* +*/ + + +PRJ_PLATFORMS +DEFAULT + +PRJ_TESTMMPFILES +TestLocationConverter2.mmp + +// END OF FILE diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/TestLocationConverter2/inc/TestLocationConverter2.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/TestLocationConverter2/inc/TestLocationConverter2.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,122 @@ +/* +* Copyright (c) 2008 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Definition of Movement Detection API +* +*/ + + +#ifndef C_TESTLOCATIONCONVERTER2_H +#define C_TESTLOCATIONCONVERTER2_H + +#include + +#include +#include +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +/** + * CTestLocationConverter is an ECom plugin that implements CLbsLocInfoConversionPluginBase. + * + * This class is responsible for monitering movement of mobile based on + * GSM information available to mobile at any instant. + * + * @lib movementdetector.lib + * @since S60 v4.0 + */ +class CTestLocationConverter2 : public CLbsLocInfoConverterPluginBase + + { + +public: + + /** + * Loads a location info conveter and initalises it. + * + * @param[in] aObserver An observer for location conversion event. + * @param[in] aPluginArgs Agruements sent to conversion plugin. + * return Pointer to the new loation info converter.If module id is not specified + * default plug in will be loaded. + */ + static CTestLocationConverter2* NewL( TLbsLocInfoConverterPluginParams& aPluginParams ); + + /** + * Unloads this movement detector. + * + * @since S60 TACO + */ + virtual ~CTestLocationConverter2(); + + // From CLbsLocInfoConversionPluginBase + + /** + * Converts the area informations of a group of geographical locations + * to its corresponding position information. + * + * @param[in] aLocationInfoArray Array of location informations corresponding + * to geographical locations are passed and on successful completion of this + * method,position information corresponding to the loation informations are + * updated in each area info object. + * @param[in] aConversionPrefs Conversion preferences suggested by client. + * + * @leave KErrArgument If the location info array is empty. + */ + virtual void ConvertLocationInfoL( + RLbsLocationInfoArray& aLocationInfoArray, + const TLbsConversionPrefs aConversionPrefs, + const TLbsConversionOutputInfoMask aRequestedInfo ); + + /** + * Cancels get location info operation. + */ + virtual void CancelConvertLocationInfo(); + + virtual void ValidateClient( const TSecureId& aSecureId, + const TVendorId& aVendorId, + const TLbsConversionOutputInfoMask aRequestedInfo ); + + virtual void CancelValidateClient(); + + virtual void ConversionPluginPreferences( + TLbsConversionPluginInfo& aPluginInfo ); + +private: + + + void ConstructL(TLbsLocInfoConverterPluginParams& aPluginParams); + + /** + * Default C++ Constructor + */ + CTestLocationConverter2(TLbsLocInfoConverterPluginParams& aParams); + +private: // data + + MLbsLocInfoConverterPluginObserver &iObserver; + TBool iRetainLocalityInCache; + }; + + +#endif // C_TESTLOCATIONCONVERTER2_H diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/TestLocationConverter2/src/TestLocationConverter2.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/TestLocationConverter2/src/TestLocationConverter2.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,321 @@ +/* +* Copyright (c) 2008 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Definition of CdummyMvmtDet class. +* +*/ + + + +#include +#include +#include +#include "TestLocationConverter2.h" + +// the test code sets the timing advance in the GSM vell info to this value +// which instructs the test converter to constuct TLocalitys with +// latitude ser to country code, longitude set to +// network code and altitiude set to local area code +const TInt KTimingAdvanceSpecialValue= 254; + +const TInt KTimingAdvanceSaveToCacheTrue= 253; + +const TInt KTimingAdvanceSaveToCacheFalse= 252; + +// ECOM implementation specifics +static const TImplementationProxy implTable[] = + { + IMPLEMENTATION_PROXY_ENTRY(0x2002160D, CTestLocationConverter2::NewL) + }; + + +EXPORT_C const TImplementationProxy* ImplementationGroupProxy(TInt& aTableCount) + { + aTableCount = sizeof(implTable) / sizeof(TImplementationProxy); + + return implTable; + } + + +// Class methods + +//------------------------------------------------------------ +// CLbsLocInfoConversionPluginBase::NewL +// Symbian Two - phase constructor +//------------------------------------------------------------ +// +CTestLocationConverter2* CTestLocationConverter2::NewL( TLbsLocInfoConverterPluginParams& aParams) + { + CTestLocationConverter2* self = new (ELeave) CTestLocationConverter2(aParams); + CleanupStack::PushL(self); + self->ConstructL(aParams); + CleanupStack::Pop(); + return self; + } + + +//------------------------------------------------------------ +// CLbsLocInfoConversionPluginBase::ConstructL +//------------------------------------------------------------ +// +void CTestLocationConverter2::ConstructL( TLbsLocInfoConverterPluginParams& /*aParams*/ ) + { + + + } + + +//----------------------------------------------------------------- +// CLbsLocInfoConversionPluginBase::CLbsLocInfoConversionPluginBase +// C++ Default constructor +//------------------------------------------------------------------ +// +CTestLocationConverter2::CTestLocationConverter2(TLbsLocInfoConverterPluginParams& aParams):iObserver(aParams.Observer()), + iRetainLocalityInCache(ETrue) + { + + } + + +//------------------------------------------------------------ +// CLbsLocInfoConversionPluginBase::~CLbsLocInfoConversionPluginBase +// Destructor +//------------------------------------------------------------ +// +CTestLocationConverter2::~CTestLocationConverter2() + { + + } + + +//------------------------------------------------------------ +// CLbsLocInfoConversionPluginBase::ConvertLocationInfoL +//------------------------------------------------------------ +// +void CTestLocationConverter2::ConvertLocationInfoL( RLbsLocationInfoArray& aLocationInfoArray, + const TLbsConversionPrefs /*aConversionPrefs*/, + const TLbsConversionOutputInfoMask aRequestedInfo) + { + if(aRequestedInfo == ELbsConversionOutputNotDefined) + { + iObserver.OnConversionComplete(KErrArgument); + return; + } + TInt count = aLocationInfoArray.Count(); + for(TInt i=0 ; iGetAreaInfoL( areaInfoArray,areaInfoMask ); + TInt count = areaInfoArray.Count(); + + + + if( count == 0 ) + { + iObserver.OnConversionComplete(KErrNotSupported); + return; + } + // + CLbsGsmCellInfo* posInfo = static_cast( areaInfoArray[0] ); + + TInt timingAdvance = posInfo->TimingAdvance(); + + TLocality locality; + if (timingAdvance == KTimingAdvanceSpecialValue) + { + TReal64 lat = posInfo->MobileCountryCode() ; + TReal64 lng = posInfo->MobileNetworkCode(); + TReal32 alt = posInfo->LocationAreaCode(); + locality.SetCoordinate( lat,lng, alt); + } + else + { + locality.SetCoordinate( 62.5285,23.9385, 1.22f); + } + +// if (timingAdvance == KTimingAdvanceSaveToCacheTrue) +// { +// TReal64 lat = posInfo->MobileCountryCode() ; +// TReal64 lng = posInfo->MobileNetworkCode(); +// TReal32 alt = posInfo->LocationAreaCode(); +// locality.SetCoordinate( lat,lng, alt); +// iRetainLocalityInCache = ETrue; +// } +// else if (timingAdvance == KTimingAdvanceSaveToCacheFalse) +// { +// TReal64 lat = posInfo->MobileCountryCode() ; +// TReal64 lng = posInfo->MobileNetworkCode(); +// TReal32 alt = posInfo->LocationAreaCode(); +// locality.SetCoordinate( lat,lng, alt); +// iRetainLocalityInCache = EFalse; +// } + + if (timingAdvance == KTimingAdvanceSaveToCacheFalse) + { + TReal64 lat = posInfo->MobileCountryCode(); + TReal64 lng = posInfo->MobileNetworkCode(); + TReal32 alt = posInfo->LocationAreaCode(); + locality.SetCoordinate(lat, lng, alt); + iRetainLocalityInCache = EFalse; + } + else + { + iRetainLocalityInCache = ETrue; + } + + + areaInfoArray.ResetAndDestroy(); + + locality.SetAccuracy( 100,0.0 ); + CLbsPositionInfo* positionInfo = CLbsPositionInfo::NewL( locality ); + CleanupStack::PushL( positionInfo ); + aLocationInfoArray[i]->AddAreaInfoL( positionInfo ); + CleanupStack::Pop( positionInfo ); + break; + } + case ELbsConversionOutputGsm: + { + // Extract the area info provided by the client. + // If client has specified only gsm info, + // return KErrNotSupported. + RLbsAreaInfoBaseArray areaInfoArray; + CLbsLocationInfo::TAreaInfoMask areaInfoMask = 0; + areaInfoMask |= CLbsLocationInfo::ELbsPosInfo | + CLbsLocationInfo::ELbsWcdmaInfo | + CLbsLocationInfo::ELbsWlanInfo; + aLocationInfoArray[i]->GetAreaInfoL( areaInfoArray,areaInfoMask ); + TInt count = areaInfoArray.Count(); + areaInfoArray.ResetAndDestroy(); + + if( count == 0 ) + { + iObserver.OnConversionComplete(KErrNotSupported); + return; + } + + CLbsGsmCellInfo* gsmCellInfo = CLbsGsmCellInfo::NewL( 100,101,102,103); + CleanupStack::PushL( gsmCellInfo ); + aLocationInfoArray[i]->AddAreaInfoL( gsmCellInfo ); + CleanupStack::Pop( gsmCellInfo ); + break; + } + case ELbsConversionOutputWcdma: + { + // Extract the area info provided by the client. + // If client has specified only wcdma info, + // return KErrNotSupported. + RLbsAreaInfoBaseArray areaInfoArray; + CLbsLocationInfo::TAreaInfoMask areaInfoMask = 0; + areaInfoMask |= CLbsLocationInfo::ELbsPosInfo | + CLbsLocationInfo::ELbsGsmInfo | + CLbsLocationInfo::ELbsWlanInfo; + aLocationInfoArray[i]->GetAreaInfoL( areaInfoArray,areaInfoMask ); + TInt count = areaInfoArray.Count(); + areaInfoArray.ResetAndDestroy(); + + if( count == 0 ) + { + iObserver.OnConversionComplete(KErrNotSupported); + return; + } + + CLbsWcdmaCellInfo* wcdmaCellInfo = CLbsWcdmaCellInfo::NewL( 100,101,102 ); + CleanupStack::PushL( wcdmaCellInfo ); + aLocationInfoArray[i]->AddAreaInfoL( wcdmaCellInfo ); + CleanupStack::Pop( wcdmaCellInfo ); + break; + } + case ELbsConversionOutputWlan: + { + // Extract the area info provided by the client. + // If client has specified only wlan info, + // return KErrNotSupported. + RLbsAreaInfoBaseArray areaInfoArray; + CLbsLocationInfo::TAreaInfoMask areaInfoMask = 0; + areaInfoMask |= CLbsLocationInfo::ELbsPosInfo | + CLbsLocationInfo::ELbsGsmInfo | + CLbsLocationInfo::ELbsWcdmaInfo; + aLocationInfoArray[i]->GetAreaInfoL( areaInfoArray,areaInfoMask ); + TInt count = areaInfoArray.Count(); + areaInfoArray.ResetAndDestroy(); + + if( count == 0 ) + { + iObserver.OnConversionComplete(KErrNotSupported); + return; + } + + TLbsWlanMacAddress macAddress(_L8("10.0.1")); + CLbsWlanInfo* WlanInfo = CLbsWlanInfo::NewL( macAddress,10.1); + CleanupStack::PushL( WlanInfo ); + aLocationInfoArray[i]->AddAreaInfoL( WlanInfo ); + CleanupStack::Pop( WlanInfo ); + } + default: + break; + } + + } + iObserver.OnConversionComplete(KErrNone); + } + +//------------------------------------------------------------ +// CLbsLocInfoConversionPluginBase::ConvertLocationInfoL +//------------------------------------------------------------ +// +void CTestLocationConverter2::CancelConvertLocationInfo( ) + { + + } + +//------------------------------------------------------------ +// CLbsLocInfoConversionPluginBase::ValidateClient +//------------------------------------------------------------ +// +void CTestLocationConverter2::ValidateClient( const TSecureId& /*aSecureId*/, + const TVendorId& /*aVendorId*/, + const TLbsConversionOutputInfoMask /*aRequestedInfo*/ ) + { + iObserver.OnValidationComplete( KErrNone ); + } + +//------------------------------------------------------------ +// CLbsLocInfoConversionPluginBase::ValidateClient +//------------------------------------------------------------ +// +void CTestLocationConverter2::CancelValidateClient() + { + + } + +//------------------------------------------------------------ +// CExampleLocationConverter::ConversionPluginPreferences +//------------------------------------------------------------ +// +void CTestLocationConverter2::ConversionPluginPreferences( + TLbsConversionPluginInfo& aPluginInfo ) + { + aPluginInfo.SetIsPluginPositionToBeCached(iRetainLocalityInCache); + //aPluginInfo.SetIsPluginPositionToBeCached(ETrue); + } diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/TestLocationConverter3/data/10287201.rss --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/TestLocationConverter3/data/10287201.rss Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,45 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Resource file for movement detector plugin +* +*/ +// mydetector.rss +// +#include + +#include "TestLocationConverter3.hrh" +#include + +RESOURCE REGISTRY_INFO theInfo +{ +dll_uid = KTestLocationConverter3Uid; +interfaces = + { + INTERFACE_INFO + { + interface_uid = KLbsLocInfoConverterPlugInInterfaceId; + implementations = + { + IMPLEMENTATION_INFO + { + implementation_uid = KTestLocationConverter3ImplementationUid; + version_no = 1; + display_name = "Test location info converter 3"; + default_data = "text/ascii"; + opaque_data = "priority:1"; + } + }; + } + }; +} diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/TestLocationConverter3/data/TestLocationConverter3.hrh --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/TestLocationConverter3/data/TestLocationConverter3.hrh Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,26 @@ +/* +* Copyright (c) 2007 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Resource headers for project +* +*/ + + +#ifndef TESTLOCATIONCONVERTER3_HRH +#define TESTLOCATIONCONVERTER3_HRH + +#define KTestLocationConverter3Uid 0x2002170C +#define KTestLocationConverter3ImplementationUid 0x2002170D + + +#endif // TESTLOCATIONCONVERTER3_HRH diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/TestLocationConverter3/group/TestLocationConverter3.mmp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/TestLocationConverter3/group/TestLocationConverter3.mmp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,50 @@ +/* +* Copyright (c) 2006-2007 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Project definition file for project Cell Id movement detector +* +*/ + + +#include "../data/TestLocationConverter3.hrh" + +TARGET TestLocationConverter3.dll +TARGETTYPE PLUGIN +UID 0x10009D8D KTestLocationConverter3Uid +VENDORID 0x70000001 + +CAPABILITY ALL -TCB + +OS_LAYER_SYSTEMINCLUDE + +USERINCLUDE ../inc +USERINCLUDE ../data + +SOURCEPATH ../src +SOURCE TestLocationConverter3.cpp + +START RESOURCE ../data/10287201.rss +TARGET TestLocationConverter3.rsc +END + +LIBRARY euser.lib +LIBRARY ecom.lib +LIBRARY commdb.lib +LIBRARY flogger.lib +LIBRARY lbslocationinfoconverterplugin.lib +LIBRARY lbslocationinfodatatypes.lib +LIBRARY lbs.lib + +PAGED + +SMPSAFE diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/TestLocationConverter3/group/bld.inf --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/TestLocationConverter3/group/bld.inf Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,25 @@ +/* +* Copyright (c) 2006 - 2007 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Build information file for project ?myapp +* +*/ + + +PRJ_PLATFORMS +DEFAULT + +PRJ_TESTMMPFILES +TestLocationConverter3.mmp + +// END OF FILE diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/TestLocationConverter3/inc/TestLocationConverter3.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/TestLocationConverter3/inc/TestLocationConverter3.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,122 @@ +/* +* Copyright (c) 2008 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Definition of Movement Detection API +* +*/ + + +#ifndef C_TESTLOCATIONCONVERTER3_H +#define C_TESTLOCATIONCONVERTER3_H + +#include + +#include +#include +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +/** + * CTestLocationConverter is an ECom plugin that implements CLbsLocInfoConversionPluginBase. + * + * This class is responsible for monitering movement of mobile based on + * GSM information available to mobile at any instant. + * + * @lib movementdetector.lib + * @since S60 v4.0 + */ +class CTestLocationConverter3 : public CLbsLocInfoConverterPluginBase + + { + +public: + + /** + * Loads a location info conveter and initalises it. + * + * @param[in] aObserver An observer for location conversion event. + * @param[in] aPluginArgs Agruements sent to conversion plugin. + * return Pointer to the new loation info converter.If module id is not specified + * default plug in will be loaded. + */ + static CTestLocationConverter3* NewL( TLbsLocInfoConverterPluginParams& aPluginParams ); + + /** + * Unloads this movement detector. + * + * @since S60 TACO + */ + virtual ~CTestLocationConverter3(); + + // From CLbsLocInfoConversionPluginBase + + /** + * Converts the area informations of a group of geographical locations + * to its corresponding position information. + * + * @param[in] aLocationInfoArray Array of location informations corresponding + * to geographical locations are passed and on successful completion of this + * method,position information corresponding to the loation informations are + * updated in each area info object. + * @param[in] aConversionPrefs Conversion preferences suggested by client. + * + * @leave KErrArgument If the location info array is empty. + */ + virtual void ConvertLocationInfoL( + RLbsLocationInfoArray& aLocationInfoArray, + const TLbsConversionPrefs aConversionPrefs, + const TLbsConversionOutputInfoMask aRequestedInfo ); + + /** + * Cancels get location info operation. + */ + virtual void CancelConvertLocationInfo(); + + virtual void ValidateClient( const TSecureId& aSecureId, + const TVendorId& aVendorId, + const TLbsConversionOutputInfoMask aRequestedInfo ); + + virtual void CancelValidateClient(); + + virtual void ConversionPluginPreferences( + TLbsConversionPluginInfo& aPluginInfo ); + +private: + + + void ConstructL(TLbsLocInfoConverterPluginParams& aPluginParams); + + /** + * Default C++ Constructor + */ + CTestLocationConverter3(TLbsLocInfoConverterPluginParams& aParams); + +private: // data + + MLbsLocInfoConverterPluginObserver &iObserver; + TBool iRetainLocalityInCache; + }; + + +#endif // C_TESTLOCATIONCONVERTER3_H diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/TestLocationConverter3/src/TestLocationConverter3.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/TestLocationConverter3/src/TestLocationConverter3.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,321 @@ +/* +* Copyright (c) 2008 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Definition of CdummyMvmtDet class. +* +*/ + + + +#include +#include +#include +#include "TestLocationConverter3.h" + +// the test code sets the timing advance in the GSM vell info to this value +// which instructs the test converter to constuct TLocalitys with +// latitude ser to country code, longitude set to +// network code and altitiude set to local area code +const TInt KTimingAdvanceSpecialValue= 254; + +const TInt KTimingAdvanceSaveToCacheTrue= 253; + +const TInt KTimingAdvanceSaveToCacheFalse= 252; + +// ECOM implementation specifics +static const TImplementationProxy implTable[] = + { + IMPLEMENTATION_PROXY_ENTRY(0x2002170D, CTestLocationConverter3::NewL) + }; + + +EXPORT_C const TImplementationProxy* ImplementationGroupProxy(TInt& aTableCount) + { + aTableCount = sizeof(implTable) / sizeof(TImplementationProxy); + + return implTable; + } + + +// Class methods + +//------------------------------------------------------------ +// CLbsLocInfoConversionPluginBase::NewL +// Symbian Two - phase constructor +//------------------------------------------------------------ +// +CTestLocationConverter3* CTestLocationConverter3::NewL( TLbsLocInfoConverterPluginParams& aParams) + { + CTestLocationConverter3* self = new (ELeave) CTestLocationConverter3(aParams); + CleanupStack::PushL(self); + self->ConstructL(aParams); + CleanupStack::Pop(); + return self; + } + + +//------------------------------------------------------------ +// CLbsLocInfoConversionPluginBase::ConstructL +//------------------------------------------------------------ +// +void CTestLocationConverter3::ConstructL( TLbsLocInfoConverterPluginParams& /*aParams*/ ) + { + + + } + + +//----------------------------------------------------------------- +// CLbsLocInfoConversionPluginBase::CLbsLocInfoConversionPluginBase +// C++ Default constructor +//------------------------------------------------------------------ +// +CTestLocationConverter3::CTestLocationConverter3(TLbsLocInfoConverterPluginParams& aParams):iObserver(aParams.Observer()), + iRetainLocalityInCache(ETrue) + { + + } + + +//------------------------------------------------------------ +// CLbsLocInfoConversionPluginBase::~CLbsLocInfoConversionPluginBase +// Destructor +//------------------------------------------------------------ +// +CTestLocationConverter3::~CTestLocationConverter3() + { + + } + + +//------------------------------------------------------------ +// CLbsLocInfoConversionPluginBase::ConvertLocationInfoL +//------------------------------------------------------------ +// +void CTestLocationConverter3::ConvertLocationInfoL( RLbsLocationInfoArray& aLocationInfoArray, + const TLbsConversionPrefs /*aConversionPrefs*/, + const TLbsConversionOutputInfoMask aRequestedInfo) + { + if(aRequestedInfo == ELbsConversionOutputNotDefined) + { + iObserver.OnConversionComplete(KErrArgument); + return; + } + TInt count = aLocationInfoArray.Count(); + for(TInt i=0 ; iGetAreaInfoL( areaInfoArray,areaInfoMask ); + TInt count = areaInfoArray.Count(); + + + + if( count == 0 ) + { + iObserver.OnConversionComplete(KErrNotSupported); + return; + } + // + CLbsGsmCellInfo* posInfo = static_cast( areaInfoArray[0] ); + + TInt timingAdvance = posInfo->TimingAdvance(); + + TLocality locality; + if (timingAdvance == KTimingAdvanceSpecialValue) + { + TReal64 lat = posInfo->MobileCountryCode() ; + TReal64 lng = posInfo->MobileNetworkCode(); + TReal32 alt = posInfo->LocationAreaCode(); + locality.SetCoordinate( lat,lng, alt); + } + else + { + locality.SetCoordinate( 62.5285,23.9385, 1.22f); + } + +// if (timingAdvance == KTimingAdvanceSaveToCacheTrue) +// { +// TReal64 lat = posInfo->MobileCountryCode() ; +// TReal64 lng = posInfo->MobileNetworkCode(); +// TReal32 alt = posInfo->LocationAreaCode(); +// locality.SetCoordinate( lat,lng, alt); +// iRetainLocalityInCache = ETrue; +// } +// else if (timingAdvance == KTimingAdvanceSaveToCacheFalse) +// { +// TReal64 lat = posInfo->MobileCountryCode() ; +// TReal64 lng = posInfo->MobileNetworkCode(); +// TReal32 alt = posInfo->LocationAreaCode(); +// locality.SetCoordinate( lat,lng, alt); +// iRetainLocalityInCache = EFalse; +// } + + if (timingAdvance == KTimingAdvanceSaveToCacheFalse) + { + TReal64 lat = posInfo->MobileCountryCode(); + TReal64 lng = posInfo->MobileNetworkCode(); + TReal32 alt = posInfo->LocationAreaCode(); + locality.SetCoordinate(lat, lng, alt); + iRetainLocalityInCache = EFalse; + } + else + { + iRetainLocalityInCache = ETrue; + } + + + areaInfoArray.ResetAndDestroy(); + + locality.SetAccuracy( 100,0.0 ); + CLbsPositionInfo* positionInfo = CLbsPositionInfo::NewL( locality ); + CleanupStack::PushL( positionInfo ); + aLocationInfoArray[i]->AddAreaInfoL( positionInfo ); + CleanupStack::Pop( positionInfo ); + break; + } + case ELbsConversionOutputGsm: + { + // Extract the area info provided by the client. + // If client has specified only gsm info, + // return KErrNotSupported. + RLbsAreaInfoBaseArray areaInfoArray; + CLbsLocationInfo::TAreaInfoMask areaInfoMask = 0; + areaInfoMask |= CLbsLocationInfo::ELbsPosInfo | + CLbsLocationInfo::ELbsWcdmaInfo | + CLbsLocationInfo::ELbsWlanInfo; + aLocationInfoArray[i]->GetAreaInfoL( areaInfoArray,areaInfoMask ); + TInt count = areaInfoArray.Count(); + areaInfoArray.ResetAndDestroy(); + + if( count == 0 ) + { + iObserver.OnConversionComplete(KErrNotSupported); + return; + } + + CLbsGsmCellInfo* gsmCellInfo = CLbsGsmCellInfo::NewL( 100,101,102,103); + CleanupStack::PushL( gsmCellInfo ); + aLocationInfoArray[i]->AddAreaInfoL( gsmCellInfo ); + CleanupStack::Pop( gsmCellInfo ); + break; + } + case ELbsConversionOutputWcdma: + { + // Extract the area info provided by the client. + // If client has specified only wcdma info, + // return KErrNotSupported. + RLbsAreaInfoBaseArray areaInfoArray; + CLbsLocationInfo::TAreaInfoMask areaInfoMask = 0; + areaInfoMask |= CLbsLocationInfo::ELbsPosInfo | + CLbsLocationInfo::ELbsGsmInfo | + CLbsLocationInfo::ELbsWlanInfo; + aLocationInfoArray[i]->GetAreaInfoL( areaInfoArray,areaInfoMask ); + TInt count = areaInfoArray.Count(); + areaInfoArray.ResetAndDestroy(); + + if( count == 0 ) + { + iObserver.OnConversionComplete(KErrNotSupported); + return; + } + + CLbsWcdmaCellInfo* wcdmaCellInfo = CLbsWcdmaCellInfo::NewL( 100,101,102 ); + CleanupStack::PushL( wcdmaCellInfo ); + aLocationInfoArray[i]->AddAreaInfoL( wcdmaCellInfo ); + CleanupStack::Pop( wcdmaCellInfo ); + break; + } + case ELbsConversionOutputWlan: + { + // Extract the area info provided by the client. + // If client has specified only wlan info, + // return KErrNotSupported. + RLbsAreaInfoBaseArray areaInfoArray; + CLbsLocationInfo::TAreaInfoMask areaInfoMask = 0; + areaInfoMask |= CLbsLocationInfo::ELbsPosInfo | + CLbsLocationInfo::ELbsGsmInfo | + CLbsLocationInfo::ELbsWcdmaInfo; + aLocationInfoArray[i]->GetAreaInfoL( areaInfoArray,areaInfoMask ); + TInt count = areaInfoArray.Count(); + areaInfoArray.ResetAndDestroy(); + + if( count == 0 ) + { + iObserver.OnConversionComplete(KErrNotSupported); + return; + } + + TLbsWlanMacAddress macAddress(_L8("10.0.1")); + CLbsWlanInfo* WlanInfo = CLbsWlanInfo::NewL( macAddress,10.1); + CleanupStack::PushL( WlanInfo ); + aLocationInfoArray[i]->AddAreaInfoL( WlanInfo ); + CleanupStack::Pop( WlanInfo ); + } + default: + break; + } + + } + iObserver.OnConversionComplete(KErrNone); + } + +//------------------------------------------------------------ +// CLbsLocInfoConversionPluginBase::ConvertLocationInfoL +//------------------------------------------------------------ +// +void CTestLocationConverter3::CancelConvertLocationInfo( ) + { + + } + +//------------------------------------------------------------ +// CLbsLocInfoConversionPluginBase::ValidateClient +//------------------------------------------------------------ +// +void CTestLocationConverter3::ValidateClient( const TSecureId& /*aSecureId*/, + const TVendorId& /*aVendorId*/, + const TLbsConversionOutputInfoMask /*aRequestedInfo*/ ) + { + iObserver.OnValidationComplete( KErrNone ); + } + +//------------------------------------------------------------ +// CLbsLocInfoConversionPluginBase::ValidateClient +//------------------------------------------------------------ +// +void CTestLocationConverter3::CancelValidateClient() + { + + } + +//------------------------------------------------------------ +// CExampleLocationConverter::ConversionPluginPreferences +//------------------------------------------------------------ +// +void CTestLocationConverter3::ConversionPluginPreferences( + TLbsConversionPluginInfo& aPluginInfo ) + { + aPluginInfo.SetIsPluginPositionToBeCached(iRetainLocalityInCache); + //aPluginInfo.SetIsPluginPositionToBeCached(ETrue); + } diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/group/bld.inf --- a/locationmgmt/locmonitor/test/group/bld.inf Thu Jun 24 11:27:31 2010 +0100 +++ b/locationmgmt/locmonitor/test/group/bld.inf Thu Jun 24 11:28:34 2010 +0100 @@ -15,4 +15,10 @@ PRJ_TESTMMPFILES #include "../te_locmonitorsuite/group/bld.inf" +#include "../te_geolocmonitorsuite/group/bld.inf" #include "../te_lbslocmonitordbsuite/group/bld.inf" +#include "../ExampleLocationConverter/group/bld.inf" +#include "../TestLocationConverter/group/bld.inf" +#include "../TestLocationConverter2/group/bld.inf" +#include "../TestLocationConverter3/group/bld.inf" +#include "../te_lbslocationinforconvertertef/group/bld.inf" diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/te_geolocmonitorsuite/group/bld.inf --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/te_geolocmonitorsuite/group/bld.inf Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,32 @@ +// Copyright (c) 2002-2009 Nokia Corporation and/or its subsidiary(-ies). +// All rights reserved. +// This component and the accompanying materials are made available +// under the terms of "Eclipse Public License v1.0" +// which accompanies this distribution, and is available +// at the URL "http://www.eclipse.org/legal/epl-v10.html". +// +// Initial Contributors: +// Nokia Corporation - initial contribution. +// +// Contributors: +// +// Description: +// + +PRJ_EXPORTS + +PRJ_TESTEXPORTS +../scripts/te_geolocmonitorsuite.script c:/testdata/scripts/te_geolocmonitorsuite.script +../testdata/te_geolocmonitorsuite.ini c:/testdata/configs/te_geolocmonitorsuite.ini + +../testdata/lbsgeolocmonunitconfig.txt c:/testdata/configs/lbsgeolocmonunitconfig.txt +../testdata/lbsgeolocmonunitconfigbad.txt c:/testdata/configs/lbsgeolocmonunitconfigbad.txt + +./te_geolocmonitorsuite.iby /epoc32/rom/include/te_geolocmonitorsuite.iby + + +PRJ_MMPFILES + +PRJ_TESTMMPFILES +//#include "../../testlocationmonitor/group/bld.inf" +te_geolocmonitorsuite.mmp diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/te_geolocmonitorsuite/group/te_geolocmonitorsuite.iby --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/te_geolocmonitorsuite/group/te_geolocmonitorsuite.iby Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,28 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ + +#ifndef __TE_SUPLPROTOCOL_SUITE_IBY__ +#define __TE_SUPLPROTOCOL_SUITE_IBY__ + +#include + +file=ABI_DIR\DEBUG_DIR\te_geolocmonitorsuite.exe sys\bin\te_geolocmonitorsuite.exe +data=EPOCROOT##Epoc32\data\c\TestData\scripts\te_geolocmonitorsuite.script TestData\scripts\te_geolocmonitorsuite.script +data=EPOCROOT##Epoc32\data\c\TestData\configs\lbsgeolocmonunitconfig.txt TestData\configs\lbslocmonunitconfig.txt + + +#endif diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/te_geolocmonitorsuite/group/te_geolocmonitorsuite.mmp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/te_geolocmonitorsuite/group/te_geolocmonitorsuite.mmp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,77 @@ +/* +* Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ + + +TARGET te_geolocmonitorsuite.exe +TARGETTYPE exe +UID 0x1000007A 0x102869E3 + +CAPABILITY ALL -TCB +MACRO ENABLE_LBS_DEV_LOGGER +SOURCEPATH ../src + +//test steps +SOURCE te_geolocmonitorsuiteserver.cpp +SOURCE te_geolocmonitorstepbase.cpp +SOURCE te_geolocmonitorstep1.cpp +SOURCE te_geolocmonitorstep2.cpp +SOURCE te_geolocmonitorstep3.cpp +SOURCE te_geolocmonitorstep4.cpp +SOURCE te_geolocmonitorstep5.cpp +SOURCE te_geolocmonitorstep6.cpp +SOURCE te_geolocmonitorstep7.cpp +SOURCE LocInfoConversionHandler.cpp + + +// test step headers +USERINCLUDE ../inc + +// Test step headers +USERINCLUDE ../src + +// Required to start up the fake/test Location Monitor server + +// Various LBS subsystem headers +USERINCLUDE ../../../lbslocmonitorapis/CommonClientServerApi/inc +USERINCLUDE ../../../lbslocmonitorserver/inc +USERINCLUDE ../../../../locationcore/LbsInternalApi/inc +USERINCLUDE ../../../../locationcore/LbsNetInternalApi/inc +USERINCLUDE ../../../../locationcore/LbsLocDataSource +USERINCLUDE ../../../../locationcore/LbsLocCommon/ServerFramework/inc +USERINCLUDE ../../../../locationcore/LbsPartnerCommon/inc +USERINCLUDE ../../../../locationcore/LbsPartnerCommon/inc +USERINCLUDE ../../../../locationcore/LbsCommonInternalDataTypes/inc + +OS_LAYER_SYSTEMINCLUDE_SYMBIAN + +LIBRARY estor.lib +LIBRARY euser.lib +LIBRARY testexecuteutils.lib +LIBRARY testexecutelogclient.lib +LIBRARY efsrv.lib + +LIBRARY lbsinternalapi.lib +LIBRARY lbsnetinternalapi.lib +LIBRARY lbsnetprotocol.lib + +LIBRARY lbslocmonclient.lib +LIBRARY lbs.lib +LIBRARY lbspartnercommon.lib +LIBRARY lbslocationinfodatatypes.lib + + +SMPSAFE diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/te_geolocmonitorsuite/inc/LocInfoConversionHandler.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/te_geolocmonitorsuite/inc/LocInfoConversionHandler.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,41 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: STIF testclass declaration +* +*/ + +#ifndef LOCINFOCONVERSIONHANDLER_H_ +#define LOCINFOCONVERSIONHANDLER_H_ + +#include + +class CLocInfoConversionHandler : public CActive + { +public: + static CLocInfoConversionHandler* NewL(); + + ~CLocInfoConversionHandler(); + + void Start(); +protected: // from CActive + void RunL(); + void DoCancel(); + +private: + CLocInfoConversionHandler(); + + void ConstructL(); + }; + +#endif /*LOCINFOCONVERSIONHANDLER_H_*/ diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/te_geolocmonitorsuite/inc/te_geolocmonitorstep1.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/te_geolocmonitorsuite/inc/te_geolocmonitorstep1.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,50 @@ +/* +* Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ + + +/** + @file te_locmonitorstep1.h +*/ +#ifndef TE_LOCMONITORSTEP1_H +#define TE_LOCMONITORSTEP1_H + +#include +#include "te_geolocmonitorstepbase.h" + +class CTe_LocMonitorStep1 : public CTe_LocMonitorStepBase + { +public: + CTe_LocMonitorStep1(); + ~CTe_LocMonitorStep1(); + virtual TVerdict doTestStepPreambleL(); + virtual TVerdict doTestStepL(); + virtual TVerdict doTestStepPostambleL(); + TInt TestValidateGSMInfoL(TInt iMCC, TInt iMNC, TInt iLAC, TInt iCI, TInt iTA); + void CTe_LocMonitorStep1::ReadIniFileValues(); + + TInt iMCC; + TInt iMNC; + TInt iLAC; + TInt iCID; + TInt iTA; + TInt iExpectedError; +private: + }; + +_LIT(KLocMonitorStep1,"te_locmonitorstep1"); + +#endif diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/te_geolocmonitorsuite/inc/te_geolocmonitorstep2.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/te_geolocmonitorsuite/inc/te_geolocmonitorstep2.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,55 @@ +/* +* Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ + + +/** + @file te_locmonitorstep2.h +*/ +#ifndef TE_LOCMONITORSTEP2_H +#define TE_LOCMONITORSTEP2_H + +#include +#include "te_geolocmonitorstepbase.h" + +class CTe_LocMonitorStep2 : public CTe_LocMonitorStepBase + { +public: + CTe_LocMonitorStep2(); + ~CTe_LocMonitorStep2(); + virtual TVerdict doTestStepPreambleL(); + virtual TVerdict doTestStepL(); + virtual TVerdict doTestStepPostambleL(); + TInt TestValidateWCDMAInfoL(TInt iMCC, TInt iMNC, TInt iUCID, TInt iSC); + void ReadIniFileValues(); + + TInt iMCC; + TInt iMNC; + TInt iLAC; + TInt iUCID; + TInt iSC; + TInt iExpectedError; + +private: + + TPositionSatelliteInfo* iPosition; + TPositionAreaExtendedInfo* iAreaInfo; + TPosAreaReqParams* iAreaReqParams; + }; + +_LIT(KLocMonitorStep2,"te_locmonitorstep2"); + +#endif diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/te_geolocmonitorsuite/inc/te_geolocmonitorstep3.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/te_geolocmonitorsuite/inc/te_geolocmonitorstep3.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,49 @@ +/* +* Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ + + +/** + @file te_locmonitorstep3.h +*/ +#ifndef TE_LOCMONITORSTEP3_H +#define TE_LOCMONITORSTEP3_H + +#include +#include "te_geolocmonitorstepbase.h" + +class CTe_LocMonitorStep3 : public CTe_LocMonitorStepBase + { + +public: + + CTe_LocMonitorStep3(); + ~CTe_LocMonitorStep3(); + virtual TVerdict doTestStepPreambleL(); + virtual TVerdict doTestStepL(); + virtual TVerdict doTestStepPostambleL(); + TInt CTe_LocMonitorStep3::TestLocInfoAddCoordL(); +private: + + TPositionInfo* iPosition; + TPositionAreaInfo* iAreaInfo; + TPosAreaReqParams* iAreaReqParams; + + }; + +_LIT(KLocMonitorStep3,"te_locmonitorstep3"); + +#endif diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/te_geolocmonitorsuite/inc/te_geolocmonitorstep4.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/te_geolocmonitorsuite/inc/te_geolocmonitorstep4.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,71 @@ +/* +* Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ + + +/** + @file te_locmonitorstep4.h +*/ +#ifndef TE_LOCMONITORSTEP4_H +#define TE_LOCMONITORSTEP4_H + +#include +#include "te_geolocmonitorstepbase.h" + +class CTe_LocMonitorStep4 : public CTe_LocMonitorStepBase + { + +public: + + CTe_LocMonitorStep4(); + ~CTe_LocMonitorStep4(); + virtual TVerdict doTestStepPreambleL(); + virtual TVerdict doTestStepL(); + virtual TVerdict doTestStepPostambleL(); + + void CTe_LocMonitorStep4::ReadIniFileValues(); + + TInt CTe_LocMonitorStep4::TestLocInfoAddWlanL(); + TInt CTe_LocMonitorStep4::TestLocInfoAddWcdmaCellL(); + TInt CTe_LocMonitorStep4::TestLocInfoAddGsmCellL(); + TInt CTe_LocMonitorStep4::TestValidateWlanInfoL(); + TInt CTe_LocMonitorStep4::TestWlanNewL(); + TInt CTe_LocMonitorStep4::TestValidateCoordInfoL(); + TInt CTe_LocMonitorStep4::TestCoordNewL(); + TInt CTe_LocMonitorStep4::TestValidateWCDMAInfoHierarchyL(); + TInt CTe_LocMonitorStep4::TestWcdmaAddNCellL(); + TInt CTe_LocMonitorStep4::TestWcdmaSetSC(); + TInt CTe_LocMonitorStep4::TestWcdmaNewL(); + TInt CTe_LocMonitorStep4::TestValidateGSMInfoHierarchyL(); + TInt CTe_LocMonitorStep4::TestGSMAddNCellL(); + TInt CTe_LocMonitorStep4::TestGSMSetRxLev(); + TInt CTe_LocMonitorStep4::TestGSMSetTA(); + TInt CTe_LocMonitorStep4::TestGSMNewL(); + TInt CTe_LocMonitorStep4::TestLocInfoAddCoordL(); + + TInt iProcedure; + +private: + + TPositionInfo* iPosition; + TPositionAreaInfo* iAreaInfo; + TPosAreaReqParams* iAreaReqParams; + + }; + +_LIT(KLocMonitorStep4,"te_locmonitorstep4"); + +#endif diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/te_geolocmonitorsuite/inc/te_geolocmonitorstep5.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/te_geolocmonitorsuite/inc/te_geolocmonitorstep5.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,74 @@ +/* +* Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ + + +/** + @file te_locmonitorstep5.h +*/ +#ifndef TE_LOCMONITORSTEP5_H +#define TE_LOCMONITORSTEP5_H + +#include +#include "te_geolocmonitorstepbase.h" +#include +#include +#include +#include "LocInfoConversionHandler.h" + +class CTe_LocMonitorStep5 : public CTe_LocMonitorStepBase + { + +public: + CTe_LocMonitorStep5(); + ~CTe_LocMonitorStep5(); + virtual TVerdict doTestStepPreambleL(); + virtual TVerdict doTestStepL(); + virtual TVerdict doTestStepPostambleL(); + + TInt RLbsLocInfoConverter_Connect1L(); + TInt RLbsLocInfoConverter_Connect2L(); + TInt RLbsLocInfoConverter_ConvertLocationInfo1L(); + TInt RLbsLocInfoConverter_ConvertLocationInfo2L(); + TInt RLbsLocInfoConverter_ConvertLocationInfo3L(); + TInt RLbsLocInfoConverter_ConvertLocationInfo4L(); + TInt RLbsLocInfoConverter_ConvertLocationInfo5L(); + TInt RLbsLocInfoConverter_ConvertLocationInfo6L(); + TInt RLbsLocInfoConverter_ConvertLocationInfo7L(); + TInt RLbsLocInfoConverter_ConvertLocationInfo8L(); + TInt RLbsLocInfoConverter_ConvertLocationInfo9L(); + TInt RLbsLocInfoConverter_ConvertLocationInfo10L(); + TInt RLbsLocInfoConverter_Cancel1L(); + TInt RLbsLocInfoConverter_Cancel2L(); + TInt RLbsLocInfoConverter_Cancel3L(); + TInt RLbsLocInfoConverter_Cancel4L(); + + /** + * Method used to log version of test class + */ + void SendTestClassVersion(); + + + +private: // Data + CLocInfoConversionHandler* iConversionHandler; + + CLocInfoConversionHandler* iConversionHandler1; + }; + +_LIT(KLocMonitorStep5,"te_locmonitorstep5"); + +#endif diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/te_geolocmonitorsuite/inc/te_geolocmonitorstep6.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/te_geolocmonitorsuite/inc/te_geolocmonitorstep6.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,59 @@ +/* +* Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ + + +/** + @file te_locmonitorStep6.h +*/ +#ifndef TE_LOCMONITORSTEP6_H +#define TE_LOCMONITORSTEP6_H + +#include +#include "te_geolocmonitorstepbase.h" +#include +#include +#include +#include "LocInfoConversionHandler.h" + +class CTe_LocMonitorStep6 : public CTe_LocMonitorStepBase + { + +public: + CTe_LocMonitorStep6(); + ~CTe_LocMonitorStep6(); + virtual TVerdict doTestStepPreambleL(); + virtual TVerdict doTestStepL(); + virtual TVerdict doTestStepPostambleL(); + + TInt RLbsLocInfoConverter_ConvertLocationInfo6L(); + + /** + * Method used to log version of test class + */ + void SendTestClassVersion(); + + + +private: // Data + CLocInfoConversionHandler* iConversionHandler; + + CLocInfoConversionHandler* iConversionHandler1; + }; + +_LIT(KLocMonitorStep6,"te_locmonitorstep6"); + +#endif diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/te_geolocmonitorsuite/inc/te_geolocmonitorstep7.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/te_geolocmonitorsuite/inc/te_geolocmonitorstep7.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,58 @@ +/* +* Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ + + +/** + @file te_locmonitorstep7.h +*/ +#ifndef TE_LOCMONITORSTEP7_H +#define TE_LOCMONITORSTEP7_H + +#include +#include "te_geolocmonitorstepbase.h" +#include +#include +#include +#include "LocInfoConversionHandler.h" + +class CTe_LocMonitorStep7 : public CTe_LocMonitorStepBase + { + +public: + CTe_LocMonitorStep7(); + ~CTe_LocMonitorStep7(); + virtual TVerdict doTestStepPreambleL(); + virtual TVerdict doTestStepL(); + virtual TVerdict doTestStepPostambleL(); + + TInt RLbsLocInfoConverter_ConvertLocationInfo7L(); + + /** + * Method used to log version of test class + */ + void SendTestClassVersion(); + + +private: // Data + CLocInfoConversionHandler* iConversionHandler; + + CLocInfoConversionHandler* iConversionHandler1; + }; + +_LIT(KLocMonitorStep7,"te_locmonitorstep7"); + +#endif diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/te_geolocmonitorsuite/inc/te_geolocmonitorstepbase.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/te_geolocmonitorsuite/inc/te_geolocmonitorstepbase.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,112 @@ +/* +* Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ + + +/** + @file te_geolocmonitorstepbase.h +*/ + +#ifndef TE_LOCMONITORSTEPBASE_H +#define TE_LOCMONITORSTEPBASE_H +#include +#include +#include "lbstimer.h" +#include "rlbslocmonitorsession.h" +#include "rlbslocmonitorareapositioner.h" +#include "lbssatellite.h" +#include "lbsareainfo.h" +#include "lbslocmonitorserverdata.h" +#include "te_geolocmonitorsuitedefs.h" +#include "lbsinternalinterface.h" +#include "lbsnetinternalapi.h" + +#include +#include + + + +/**************************************************************************** +* Base Test Step class for te_geolocmonitorsuite test steps +* +****************************************************************************/ +class CTe_LocMonitorStepBase : public CTestStep + { + +public: + + enum TTestType + { + EPositive, + + ENegative + }; + + virtual ~CTe_LocMonitorStepBase(); + CTe_LocMonitorStepBase(); + virtual TVerdict doTestStepPreambleL(); + virtual TVerdict doTestStepPostambleL(); + + /** + * Helper methods. + */ + CLbsPositionInfo* CreatePositionInfoObjectLC(); + + CLbsGsmCellInfo* CreateGsmCellInfoObjectLC(); + + CLbsWcdmaCellInfo* CreateWcdmaCellInfoObjectLC(); + + CLbsWlanInfo* CreateWlanInfoObjectLC(); + + CLbsLocationInfo* CreateLocationInfoObjectLC( TLbsAreaInfoClassType aAreaType ); + + void AppendAreaInfoObjectToLocationInfoL( CLbsLocationInfo* aLocationInfo, + TLbsAreaInfoClassType aAreaType ); + + void CheckPositionConvertedInfoL( CLbsLocationInfo* aLocationInfo, + TTestType aTestType = EPositive ); + + void CheckGsmCellConvertedInfoL( CLbsLocationInfo* aLocationInfo, + TTestType aTestType = EPositive ); + + void CheckWcdmaCellConvertedInfoL( CLbsLocationInfo* aLocationInfo, + TTestType aTestType = EPositive ); + + void CheckWlanConvertedInfoL( CLbsLocationInfo* aLocationInfo, + TTestType aTestType = EPositive ); + + + +protected: + + +private: + + CActiveScheduler* iActiveScheduler; + }; + + +/************************************************************************** +* AO to wait for the Location Monitor database feedback (in a P&S property) +****************************************************************************/ + + + + + + + +#endif diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/te_geolocmonitorsuite/inc/te_geolocmonitorsuitedefs.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/te_geolocmonitorsuite/inc/te_geolocmonitorsuitedefs.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,29 @@ +/* +* Copyright (c) 2006-2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* This file define all the common values thoughout your test project +* +*/ + + +/** + @file te_geolocmonitorsuitedefs.h +*/ +#if (!defined TE_GEOLOCMONITORSUITEDEFS_H) +#define TE_GEOLOCMONITORSUITEDEFS_H + +// For test step panics +_LIT(KTe_geolocMonitorSuitePanic,"Te_geolocMonitorSuite"); + +#endif diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/te_geolocmonitorsuite/inc/te_geolocmonitorsuiteserver.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/te_geolocmonitorsuite/inc/te_geolocmonitorsuiteserver.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,34 @@ +/* +* Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ + + +#ifndef TE_GEOLOCMONITORSUITE_H +#define TE_GEOLOCMONITORSUITE_H + +#include +#include "lbsnetinternalapi.h" + +class CTe_GeoLocMonitorSuite : public CTestServer + { +public: + static CTe_GeoLocMonitorSuite* NewL(); + virtual CTestStep* CreateTestStep(const TDesC& aStepName); + virtual void ConstructL(const TDesC& aName); + ~CTe_GeoLocMonitorSuite(); + }; + +#endif // TE_GEOLOCMONITORSUITE_H diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/te_geolocmonitorsuite/scripts/te_geolocmonitorsuite.script --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/te_geolocmonitorsuite/scripts/te_geolocmonitorsuite.script Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,188 @@ +// +// Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +// All rights reserved. +// This component and the accompanying materials are made available +// under the terms of "Eclipse Public License v1.0" +// which accompanies this distribution, and is available +// at the URL "http://www.eclipse.org/legal/epl-v10.html". +// +// Initial Contributors: +// Nokia Corporation - initial contribution. +// +// Contributors: +// +// Description: +// +//! @File +//! @SYMTestSuiteName te_geolocmonitorsuite.script +//! @SYMScriptTestEnvironment TEF + + +PRINT Run te_geolocmonitorsuite +LOAD_SUITE te_geolocmonitorsuite + +RUN_UTILS DeleteFile c:\config.txt +RUN_UTILS CopyFile c:\testdata\configs\lbsgeolocmonunitconfig.txt c:\config.txt + +START_TESTCASE LBS-LocMonitorSuite-0001 +//! @SYMTestCaseID LBS-LocMonitorSuite-0001 +//! @SYMTestCaseDesc +//! This test ensures that, +//! +//! +//! +//! @SYMTestPriority High +//! @SYMTestType UT +//! @SYMCreationDate +//! @SYMAuthor juanmr +//! @SYMTestStatus 2. Functional +RUN_TEST_STEP 20 te_geolocmonitorsuite te_locmonitorstep1 c:\testdata\configs\te_geolocmonitorsuite.ini VALIDATEGSMCELLINFO1 +RUN_TEST_STEP 20 te_geolocmonitorsuite te_locmonitorstep1 c:\testdata\configs\te_geolocmonitorsuite.ini VALIDATEGSMCELLINFO2 +RUN_TEST_STEP 20 te_geolocmonitorsuite te_locmonitorstep1 c:\testdata\configs\te_geolocmonitorsuite.ini VALIDATEGSMCELLINFO3 +RUN_TEST_STEP 20 te_geolocmonitorsuite te_locmonitorstep1 c:\testdata\configs\te_geolocmonitorsuite.ini VALIDATEGSMCELLINFO4 +RUN_TEST_STEP 20 te_geolocmonitorsuite te_locmonitorstep1 c:\testdata\configs\te_geolocmonitorsuite.ini VALIDATEGSMCELLINFO5 +RUN_TEST_STEP 20 te_geolocmonitorsuite te_locmonitorstep1 c:\testdata\configs\te_geolocmonitorsuite.ini VALIDATEGSMCELLINFO6 +RUN_TEST_STEP 20 te_geolocmonitorsuite te_locmonitorstep1 c:\testdata\configs\te_geolocmonitorsuite.ini VALIDATEGSMCELLINFO7 +RUN_TEST_STEP 20 te_geolocmonitorsuite te_locmonitorstep1 c:\testdata\configs\te_geolocmonitorsuite.ini VALIDATEGSMCELLINFO8 +RUN_TEST_STEP 20 te_geolocmonitorsuite te_locmonitorstep1 c:\testdata\configs\te_geolocmonitorsuite.ini VALIDATEGSMCELLINFO9 +RUN_TEST_STEP 20 te_geolocmonitorsuite te_locmonitorstep1 c:\testdata\configs\te_geolocmonitorsuite.ini VALIDATEGSMCELLINFO10 +RUN_TEST_STEP 20 te_geolocmonitorsuite te_locmonitorstep1 c:\testdata\configs\te_geolocmonitorsuite.ini VALIDATEGSMCELLINFO11 +RUN_TEST_STEP 20 te_geolocmonitorsuite te_locmonitorstep1 c:\testdata\configs\te_geolocmonitorsuite.ini VALIDATEGSMCELLINFO12 +RUN_TEST_STEP 20 te_geolocmonitorsuite te_locmonitorstep1 c:\testdata\configs\te_geolocmonitorsuite.ini VALIDATEGSMCELLINFO13 +RUN_TEST_STEP 20 te_geolocmonitorsuite te_locmonitorstep1 c:\testdata\configs\te_geolocmonitorsuite.ini VALIDATEGSMCELLINFO14 +RUN_TEST_STEP 20 te_geolocmonitorsuite te_locmonitorstep1 c:\testdata\configs\te_geolocmonitorsuite.ini VALIDATEGSMCELLINFO15 +RUN_TEST_STEP 20 te_geolocmonitorsuite te_locmonitorstep1 c:\testdata\configs\te_geolocmonitorsuite.ini VALIDATEGSMCELLINFO16 + + + +END_TESTCASE LBS-LocMonitorSuite-0001 + +START_TESTCASE LBS-LocMonitorSuite-0002 +//! @SYMTestCaseID LBS-LocMonitorSuite-0002 +//! @SYMTestCaseDesc +//! This test ensures that, +//! +//! +//! +//! @SYMTestPriority High +//! @SYMTestType UT +//! @SYMCreationDate +//! @SYMAuthor bw +//! @SYMTestStatus 2. Functional +RUN_TEST_STEP 20 te_geolocmonitorsuite te_locmonitorstep2 c:\testdata\configs\te_geolocmonitorsuite.ini VALIDATEWCDMACELLINFO1 +RUN_TEST_STEP 20 te_geolocmonitorsuite te_locmonitorstep2 c:\testdata\configs\te_geolocmonitorsuite.ini VALIDATEWCDMACELLINFO2 +RUN_TEST_STEP 20 te_geolocmonitorsuite te_locmonitorstep2 c:\testdata\configs\te_geolocmonitorsuite.ini VALIDATEWCDMACELLINFO3 +RUN_TEST_STEP 20 te_geolocmonitorsuite te_locmonitorstep2 c:\testdata\configs\te_geolocmonitorsuite.ini VALIDATEWCDMACELLINFO4 +RUN_TEST_STEP 20 te_geolocmonitorsuite te_locmonitorstep2 c:\testdata\configs\te_geolocmonitorsuite.ini VALIDATEWCDMACELLINFO5 +RUN_TEST_STEP 20 te_geolocmonitorsuite te_locmonitorstep2 c:\testdata\configs\te_geolocmonitorsuite.ini VALIDATEWCDMACELLINFO6 +RUN_TEST_STEP 20 te_geolocmonitorsuite te_locmonitorstep2 c:\testdata\configs\te_geolocmonitorsuite.ini VALIDATEWCDMACELLINFO7 +RUN_TEST_STEP 20 te_geolocmonitorsuite te_locmonitorstep2 c:\testdata\configs\te_geolocmonitorsuite.ini VALIDATEWCDMACELLINFO8 +RUN_TEST_STEP 20 te_geolocmonitorsuite te_locmonitorstep2 c:\testdata\configs\te_geolocmonitorsuite.ini VALIDATEWCDMACELLINFO9 +RUN_TEST_STEP 20 te_geolocmonitorsuite te_locmonitorstep2 c:\testdata\configs\te_geolocmonitorsuite.ini VALIDATEWCDMACELLINFO10 +RUN_TEST_STEP 20 te_geolocmonitorsuite te_locmonitorstep2 c:\testdata\configs\te_geolocmonitorsuite.ini VALIDATEWCDMACELLINFO11 +RUN_TEST_STEP 20 te_geolocmonitorsuite te_locmonitorstep2 c:\testdata\configs\te_geolocmonitorsuite.ini VALIDATEWCDMACELLINFO12 + +END_TESTCASE LBS-LocMonitorSuite-0002 + + +START_TESTCASE LBS-LocMonitorSuite-0003 +//! @SYMTestCaseID LBS-LocMonitorSuite-0003 +//! @SYMTestCaseDesc +//! This test ensures that, +//! +//! +//! +//! @SYMTestPriority High +//! @SYMTestType UT +//! @SYMCreationDate +//! @SYMAuthor bw +//! @SYMTestStatus 2. Functional +RUN_TEST_STEP 20 te_geolocmonitorsuite te_locmonitorstep3 +END_TESTCASE LBS-LocMonitorSuite-0003 + + +START_TESTCASE LBS-LocMonitorSuite-0004 +//! @SYMTestCaseID LBS-LocMonitorSuite-0004 +//! @SYMTestCaseDesc +//! This test ensures that, +//! +//! +//! +//! @SYMTestPriority High +//! @SYMTestType UT +//! @SYMCreationDate +//! @SYMAuthor bw +//! @SYMTestStatus 2. Functional +RUN_TEST_STEP 20 te_geolocmonitorsuite te_locmonitorstep4 c:\testdata\configs\te_geolocmonitorsuite.ini CREATEGSMCELL +RUN_TEST_STEP 20 te_geolocmonitorsuite te_locmonitorstep4 c:\testdata\configs\te_geolocmonitorsuite.ini SETTATOGSMCELL +RUN_TEST_STEP 20 te_geolocmonitorsuite te_locmonitorstep4 c:\testdata\configs\te_geolocmonitorsuite.ini SETNCELLTOGSMCELL +RUN_TEST_STEP 20 te_geolocmonitorsuite te_locmonitorstep4 c:\testdata\configs\te_geolocmonitorsuite.ini VALIDATEGSMCELLHIERARCHY +RUN_TEST_STEP 20 te_geolocmonitorsuite te_locmonitorstep4 c:\testdata\configs\te_geolocmonitorsuite.ini CREATEWCDMACELL +RUN_TEST_STEP 20 te_geolocmonitorsuite te_locmonitorstep4 c:\testdata\configs\te_geolocmonitorsuite.ini SETSCTOWCDMACELL +RUN_TEST_STEP 20 te_geolocmonitorsuite te_locmonitorstep4 c:\testdata\configs\te_geolocmonitorsuite.ini SETNCELLTOWCDMACELL +RUN_TEST_STEP 20 te_geolocmonitorsuite te_locmonitorstep4 c:\testdata\configs\te_geolocmonitorsuite.ini VALIDATEWCDMACELLHIERARCHY +RUN_TEST_STEP 20 te_geolocmonitorsuite te_locmonitorstep4 c:\testdata\configs\te_geolocmonitorsuite.ini CREATECOORDINFO +RUN_TEST_STEP 20 te_geolocmonitorsuite te_locmonitorstep4 c:\testdata\configs\te_geolocmonitorsuite.ini VALIDATECOORDINFO +RUN_TEST_STEP 20 te_geolocmonitorsuite te_locmonitorstep4 c:\testdata\configs\te_geolocmonitorsuite.ini CREATEWLANINFO +RUN_TEST_STEP 20 te_geolocmonitorsuite te_locmonitorstep4 c:\testdata\configs\te_geolocmonitorsuite.ini VALIDATEWLANINFO +RUN_TEST_STEP 20 te_geolocmonitorsuite te_locmonitorstep4 c:\testdata\configs\te_geolocmonitorsuite.ini ADDCOORDINFOTOLOCINFO +RUN_TEST_STEP 20 te_geolocmonitorsuite te_locmonitorstep4 c:\testdata\configs\te_geolocmonitorsuite.ini ADDGSMINFOTOLOCINFO +RUN_TEST_STEP 20 te_geolocmonitorsuite te_locmonitorstep4 c:\testdata\configs\te_geolocmonitorsuite.ini ADDWCDMAINFOTOLOCINFO +RUN_TEST_STEP 20 te_geolocmonitorsuite te_locmonitorstep4 c:\testdata\configs\te_geolocmonitorsuite.ini ADDWLANINFOTOLOCINFO + +END_TESTCASE LBS-LocMonitorSuite-0004 + + + + +START_TESTCASE LBS-LocMonitorSuite-0005 +//! @SYMTestCaseID LBS-LocMonitorSuite-0005 +//! @SYMTestCaseDesc +//! This test ensures that, +//! +//! +//! +//! @SYMTestPriority High +//! @SYMTestType UT +//! @SYMCreationDate +//! @SYMAuthor bw +//! @SYMTestStatus 2. Functional + +RUN_TEST_STEP 20 te_geolocmonitorsuite te_locmonitorstep5 +END_TESTCASE LBS-LocMonitorSuite-0005 + +START_TESTCASE LBS-LocMonitorSuite-0006 +//! @SYMTestCaseID LBS-LocMonitorSuite-0006 +//! @SYMTestCaseDesc +//! This test ensures that, +//! +//! +//! +//! @SYMTestPriority High +//! @SYMTestType UT +//! @SYMCreationDate +//! @SYMAuthor bw +//! @SYMTestStatus 2. Functional + +RUN_TEST_STEP !PanicCode=0 20 te_geolocmonitorsuite te_locmonitorstep6 +END_TESTCASE LBS-LocMonitorSuite-0006 + + + +START_TESTCASE LBS-LocMonitorSuite-0007 +//! @SYMTestCaseID LBS-LocMonitorSuite-0007 +//! @SYMTestCaseDesc +//! This test ensures that, +//! +//! +//! +//! @SYMTestPriority High +//! @SYMTestType UT +//! @SYMCreationDate +//! @SYMAuthor bw +//! @SYMTestStatus 2. Functional + +RUN_TEST_STEP !PanicCode=0 20 te_geolocmonitorsuite te_locmonitorstep7 +END_TESTCASE LBS-LocMonitorSuite-0007 + + diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/te_geolocmonitorsuite/src/LocInfoConversionHandler.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/te_geolocmonitorsuite/src/LocInfoConversionHandler.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,63 @@ +/* +* Copyright (c) 2010 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: STIF testclass declaration +* +*/ + +#include "LocInfoConversionHandler.h" + +CLocInfoConversionHandler* CLocInfoConversionHandler::NewL() + { + CLocInfoConversionHandler* self = new ( ELeave ) CLocInfoConversionHandler; + CleanupStack::PushL( self ); + self->ConstructL(); + CleanupStack::Pop( self ); + return self; + } + +CLocInfoConversionHandler::CLocInfoConversionHandler():CActive( EPriorityStandard ) + { + CActiveScheduler::Add( this ); + } + +CLocInfoConversionHandler::~CLocInfoConversionHandler() + { + if( IsActive() ) + { + Cancel(); + } + } + +void CLocInfoConversionHandler::Start() + { + iStatus = KRequestPending; + SetActive(); + } + +void CLocInfoConversionHandler::RunL() + { + CActiveScheduler::Stop(); + } + + +void CLocInfoConversionHandler::ConstructL() + { + // Nothign to do here + } + + +void CLocInfoConversionHandler::DoCancel() + { + // Nothign to do here + } diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/te_geolocmonitorsuite/src/te_geolocmonitorstep1.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/te_geolocmonitorsuite/src/te_geolocmonitorstep1.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,134 @@ +/* +* Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ + + +/** + @file te_locmonitorstep1.cpp +*/ + +#include "te_geolocmonitorstep1.h" +#include "te_geolocmonitorsuitedefs.h" +#include +#include + +CTe_LocMonitorStep1::~CTe_LocMonitorStep1() + { + } + +CTe_LocMonitorStep1::CTe_LocMonitorStep1() + { + SetTestStepName(KLocMonitorStep1); + } + +TVerdict CTe_LocMonitorStep1::doTestStepPreambleL() + { + CTe_LocMonitorStepBase::doTestStepPreambleL(); + return TestStepResult(); + } + + +void CTe_LocMonitorStep1::ReadIniFileValues() + { + + _LIT(KMCC,"MCC"); + _LIT(KMNC,"MNC"); + _LIT(KLAC,"LAC"); + _LIT(KCID,"CID"); + _LIT(KTA,"TA"); + _LIT(KEXPECTEDERROR,"EXPECTEDERROR"); + + + iMCC = -1; + iMNC = -1; + iLAC = -1; + iCID = -1; + iTA = -1; + iExpectedError = KErrNone; + + GetIntFromConfig(ConfigSection(), KMCC, iMCC); + GetIntFromConfig(ConfigSection(), KMNC, iMNC); + GetIntFromConfig(ConfigSection(), KLAC, iLAC); + GetIntFromConfig(ConfigSection(), KCID, iCID); + GetIntFromConfig(ConfigSection(), KTA, iTA); + GetIntFromConfig(ConfigSection(), KEXPECTEDERROR, iExpectedError); + + } + + +TVerdict CTe_LocMonitorStep1::doTestStepL() + { + if (TestStepResult()==EPass) + { + // here, read from .ini file + ReadIniFileValues(); + + + INFO_PRINTF6(_L("TestValidateGSMInfoL(%d,%d,%d,%d,%d)"), iMCC, iMNC, iLAC, iCID, iTA); + + TInt result; + TRAP( result, TestValidateGSMInfoL(iMCC, iMNC, iLAC, iCID, iTA); ); + if (iExpectedError == result) + { + INFO_PRINTF2(_L("TestValidateGSMInfoL passed. Got %d as expected"),iExpectedError); + + } + else + { + INFO_PRINTF3(_L("TestValidateGSMInfoL failed, got error %d and was expecting %d "), result, iExpectedError); + TESTL(0); + } + + } + + return TestStepResult(); + } + +TVerdict CTe_LocMonitorStep1::doTestStepPostambleL() + { + CTe_LocMonitorStepBase::doTestStepPostambleL(); + return TestStepResult(); + } + +// ----------------------------------------------------------------------------- +// Clocationinfodatatypestest::TestValidateGSMInfoL +// ?implementation_description +// (other items were commented in a header). +// ----------------------------------------------------------------------------- +// + +TInt CTe_LocMonitorStep1::TestValidateGSMInfoL(TInt iMCC, TInt iMNC, TInt iLAC, TInt iCID, TInt iTA) + { + CLbsGsmCellInfo* gsmInfo = CLbsGsmCellInfo::NewL(); + CleanupDeletePushL( gsmInfo ); + + TLbsGsmNeighbourCellInfo nCell; + nCell.SetArfcn( 100 ); + nCell.SetBsic( 30 ); + nCell.SetRxLevel( 20 ); + gsmInfo->AddNeighbouringCellInfoL( &nCell ); + + gsmInfo->SetMobileCountryCode( iMCC ); + gsmInfo->SetMobileNetworkCode( iMNC ); + gsmInfo->SetLocationAreaCode( iLAC); + gsmInfo->SetCellId( iCID); + gsmInfo->SetTimingAdvance( iTA); + + gsmInfo->ValidateDataL(); + + CleanupStack::PopAndDestroy(); // gsmInfo + return KErrNone; + } diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/te_geolocmonitorsuite/src/te_geolocmonitorstep2.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/te_geolocmonitorsuite/src/te_geolocmonitorstep2.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,138 @@ +/* +* Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ + + +/** + @file te_locmonitorstep2.cpp +*/ + +#include "te_geolocmonitorstep2.h" +#include "te_geolocmonitorsuitedefs.h" +#include +#include + +CTe_LocMonitorStep2::~CTe_LocMonitorStep2() + { + } + +CTe_LocMonitorStep2::CTe_LocMonitorStep2() + { + SetTestStepName(KLocMonitorStep2); + } + +TVerdict CTe_LocMonitorStep2::doTestStepPreambleL() + { + CTe_LocMonitorStepBase::doTestStepPreambleL(); + return TestStepResult(); + } + + +void CTe_LocMonitorStep2::ReadIniFileValues() + { + + _LIT(KMCC,"MCC"); + _LIT(KMNC,"MNC"); + _LIT(KLAC,"LAC"); + _LIT(KUCID,"UCID"); + _LIT(KSC,"SC"); + _LIT(KEXPECTEDERROR,"EXPECTEDERROR"); + + iMCC = -1; + iMNC = -1; + iLAC =-1; + iUCID = -1; + iSC = -1; + iExpectedError = KErrNone; + + GetIntFromConfig(ConfigSection(), KMCC, iMCC); + GetIntFromConfig(ConfigSection(), KMNC, iMNC); + GetIntFromConfig(ConfigSection(), KLAC, iLAC); + GetIntFromConfig(ConfigSection(), KUCID, iUCID); + GetIntFromConfig(ConfigSection(), KSC, iSC); + GetIntFromConfig(ConfigSection(), KEXPECTEDERROR, iExpectedError); + + } + +// +// Repeatible call to GetLastKnownPositionArea using a TPositionSatelliteInfo +// and a TPositionAreaExtendedInfo object. +// +// This test checks that it is possible to request the last known +// position with area information from the Location Monitor using the above +// mentioned data types. +// +// The call to GetLastKnowPositionArea is conducted twice to check +// repeatibility. +// +TVerdict CTe_LocMonitorStep2::doTestStepL() + { + TPosition receivedPosition; + + if (TestStepResult()==EPass) + { + // here, read from .ini file + ReadIniFileValues(); + + + INFO_PRINTF5(_L("TestValidateWCDMAInfoL(%d,%d,%d,%d)"), iMCC, iMNC, iUCID, iSC); + + TInt result; + + TRAP( result, TestValidateWCDMAInfoL(iMCC,iMNC,iUCID,iSC);); + if (iExpectedError == result) + { + INFO_PRINTF2(_L("TestValidateWCDMAInfoL passed. Got %d as expected"),iExpectedError); + + } + else + { + INFO_PRINTF3(_L("TestValidateWCDMAInfoL failed, got error %d and was expecting %d"), result, iExpectedError); + TESTL(0); + } + } + + return TestStepResult(); + } + +TVerdict CTe_LocMonitorStep2::doTestStepPostambleL() + { + CTe_LocMonitorStepBase::doTestStepPostambleL(); + return TestStepResult(); + } + +TInt CTe_LocMonitorStep2::TestValidateWCDMAInfoL(TInt iMCC, TInt iMNC, TInt iUCID, TInt iSC ) + { + CLbsWcdmaCellInfo* wcdmaInfo = CLbsWcdmaCellInfo::NewL(); + CleanupDeletePushL( wcdmaInfo ); + + TLbsWcdmaNeighbourCellInfo nCell; + nCell.SetUniqueCellId( 100 ); + nCell.SetScramblingCode( 30 ); + nCell.SetPathloss( 100 ); + nCell.SetSignalStrength( 90 ); + wcdmaInfo->AddNeighbouringCellInfoL( &nCell ); + + wcdmaInfo->SetMobileCountryCode( iMCC); + wcdmaInfo->SetMobileNetworkCode( iMNC); + wcdmaInfo->SetUniqueCellId(iUCID); + wcdmaInfo->SetScramblingCode( iSC ); + + wcdmaInfo->ValidateDataL(); + + CleanupStack::PopAndDestroy(); // wcdmaInfo + return KErrNone; + } diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/te_geolocmonitorsuite/src/te_geolocmonitorstep3.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/te_geolocmonitorsuite/src/te_geolocmonitorstep3.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,147 @@ +/* +* Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ + + +/** + @file te_locmonitorstep3.cpp +*/ + +#include +#include + +#include "te_geolocmonitorstep3.h" +#include "te_geolocmonitorsuitedefs.h" +#include +#include + +extern void CleanUpAreaInfoArray(TAny* aArray); + +CTe_LocMonitorStep3::~CTe_LocMonitorStep3() + { + } + +CTe_LocMonitorStep3::CTe_LocMonitorStep3() + { + SetTestStepName(KLocMonitorStep3); + } + +TVerdict CTe_LocMonitorStep3::doTestStepPreambleL() + { + CTe_LocMonitorStepBase::doTestStepPreambleL(); + return TestStepResult(); + } + +// +// Call to GetLastKnownPositionArea using a TPositionInfo +// and a TPositionAreaInfo object. +// +// This test checks that it is possible to request the last known +// position with area information from the Location Monitor using +// the above mentioned data types. +// +TVerdict CTe_LocMonitorStep3::doTestStepL() + { + TPosition expectedPosition, receivedPosition; + TPositionAreaInfo expectedAreaInfo; + + if (TestStepResult()==EPass) + { + INFO_PRINTF1(_L("TestLocInfoAddCoordL()")); + + TInt result; + TRAP( result, TestLocInfoAddCoordL(); ); + if (KErrNone == result) + { + INFO_PRINTF2(_L("TestLocInfoAddCoordL passed. Got %d as expected"),KErrNone); + } + else + { + INFO_PRINTF3(_L("TestLocInfoAddCoordL failed, got error %d and was expecting %d "), result, KErrNone); + TESTL(0); + } + } + + return TestStepResult(); + } + +TVerdict CTe_LocMonitorStep3::doTestStepPostambleL() + { + CTe_LocMonitorStepBase::doTestStepPostambleL(); + return TestStepResult(); + } + +TInt CTe_LocMonitorStep3::TestLocInfoAddCoordL() + { + CBufFlat* buffer = CBufFlat::NewL( 512 ); + CleanupDeletePushL( buffer ); + CLbsLocationInfo* locInfo = CLbsLocationInfo::NewL(); + CleanupDeletePushL( locInfo ); + TCoordinate coord( 12.9765, 77.1423, 3000.0 ); + TLocality src( coord, 12.0 ); + src.SetVerticalAccuracy( 10.0 ); + CLbsPositionInfo* pos = CLbsPositionInfo::NewL( src ); + CleanupStack::PushL( pos ); + locInfo->AddAreaInfoL( pos ); + CleanupStack::Pop(); // pos; ownership transferred to instance of CLbsLocationInfo + + RBufWriteStream wStream; + wStream.Open( *buffer ); + CleanupClosePushL( wStream ); + ( (CLbsLocationInfoBase*)locInfo )->ExternaliseL( wStream ); + wStream.CommitL(); + + CleanupStack::PopAndDestroy(); // wStream + CleanupStack::PopAndDestroy(); // locInfo + locInfo = NULL; + + // Read from stream + RBufReadStream rStream; + rStream.Open( *buffer ); + + locInfo = CLbsLocationInfo::NewL(); + CleanupDeletePushL( locInfo ); + locInfo->InternaliseL( rStream ); + + RLbsAreaInfoBaseArray coords; + CleanupStack::PushL(TCleanupItem(*CleanUpAreaInfoArray, &coords )); + + locInfo->GetAreaInfoL( coords, CLbsLocationInfo::ELbsPosInfo ); + CLbsPositionInfo* posInfo = static_cast( coords[0] ); + TLocality res; + posInfo->GetLocality( res ); + + if( 12.9765 != res.Latitude() || + 77.1423 != res.Longitude() || + 3000.0 != res.Altitude() || + 12.0 != res.HorizontalAccuracy() || + 10.0 != res.VerticalAccuracy() ) + { + CleanupStack::PopAndDestroy(&coords); + //CleanupStack::PopAndDestroy( &coords ); + CleanupStack::PopAndDestroy( 2 ); + return -1; + } + + // Delete coordinate info + locInfo->ResetAreaInfo( CLbsLocationInfo::ELbsPosInfo ); + + CleanupStack::PopAndDestroy(&coords); + CleanupStack::PopAndDestroy(2); // locInfo and buffer + return KErrNone; + } + + diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/te_geolocmonitorsuite/src/te_geolocmonitorstep4.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/te_geolocmonitorsuite/src/te_geolocmonitorstep4.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,897 @@ +/* +* Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ + + +/** + @file te_locmonitorstep4.cpp +*/ + +#include +#include + +#include "te_geolocmonitorstep4.h" +#include "te_geolocmonitorsuitedefs.h" +#include +#include + +extern void CleanUpAreaInfoArray(TAny* aArray); + +CTe_LocMonitorStep4::~CTe_LocMonitorStep4() + { + } + +CTe_LocMonitorStep4::CTe_LocMonitorStep4() + { + SetTestStepName(KLocMonitorStep4); + } + +TVerdict CTe_LocMonitorStep4::doTestStepPreambleL() + { + CTe_LocMonitorStepBase::doTestStepPreambleL(); + return TestStepResult(); + } + + +void CTe_LocMonitorStep4::ReadIniFileValues() + { + _LIT(KPROCEDURE,"PROCEDURE"); + iProcedure = -1; + GetIntFromConfig(ConfigSection(), KPROCEDURE, iProcedure ); + } + + +TVerdict CTe_LocMonitorStep4::doTestStepL() + { + TPosition expectedPosition, receivedPosition; + TPositionAreaInfo expectedAreaInfo; + + if (TestStepResult()==EPass) + { + + // here, read from .ini file + ReadIniFileValues(); + INFO_PRINTF2(_L("Procedure %d"), iProcedure); + + TInt result=KErrNotFound; + + switch(iProcedure) + { + case 1: + result = TestGSMNewL(); + break; + case 2: + result = TestGSMSetTA(); + break; + case 3: + result = TestGSMAddNCellL(); + break; + case 4: + result = TestValidateGSMInfoHierarchyL(); + break; + case 5: + result = TestWcdmaNewL(); + break; + case 6: + result = TestWcdmaSetSC(); + break; + case 7: + result = TestWcdmaAddNCellL(); + break; + case 8: + result = TestValidateWCDMAInfoHierarchyL(); + break; + case 9: + result = TestCoordNewL(); + break; + case 10: + result = TestValidateCoordInfoL(); + break; + case 11: + result = TestWlanNewL(); + break; + case 12: + result = TestValidateWlanInfoL(); + break; + case 13: + result = TestLocInfoAddCoordL(); + break; + case 14: + result = TestLocInfoAddGsmCellL(); + break; + case 15: + result = TestLocInfoAddWcdmaCellL(); + break; + case 16: + result = TestLocInfoAddWlanL(); + break; + + default: + INFO_PRINTF2(_L("Bad Procedure number %d - Not supported"), iProcedure); + TESTL(0); + break; + + } + + if (KErrNone == result) + { + INFO_PRINTF3(_L("Procedure %d passed. Got %d as expected"),iProcedure, KErrNone); + + } + else + { + INFO_PRINTF4(_L("Procedure %d failed, got error %d and was expecting %d "), iProcedure, result, KErrNone); + TESTL(0); + } + } + + return TestStepResult(); + } + +TVerdict CTe_LocMonitorStep4::doTestStepPostambleL() + { + CTe_LocMonitorStepBase::doTestStepPostambleL(); + return TestStepResult(); + } + + + +TInt CTe_LocMonitorStep4::TestGSMNewL( ) + { + INFO_PRINTF1(_L("TestGSMNewL")); + + CLbsGsmCellInfo* gsmInfo = NULL; + TRAPD( err, gsmInfo = CLbsGsmCellInfo::NewL( 3, 4, 56, 78 ) ); + if( KErrNone != err ) + return err; + + if( ( 3 != gsmInfo->MobileCountryCode() ) || + ( 4 != gsmInfo->MobileNetworkCode() ) || + ( 56 != gsmInfo->LocationAreaCode() ) || + ( 78 != gsmInfo->CellId() ) ) + { + delete gsmInfo; + return -1; + } + + delete gsmInfo; + return KErrNone; + } + + + +TInt CTe_LocMonitorStep4::TestGSMSetTA( ) + { + INFO_PRINTF1(_L("TestGSMSetTA")); + CLbsGsmCellInfo* gsmInfo = NULL; + TRAPD( err, gsmInfo = CLbsGsmCellInfo::NewL() ); + if( KErrNone != err ) + return err; + + gsmInfo->SetTimingAdvance( 2 ); + if( 2 != gsmInfo->TimingAdvance() ) + { + delete gsmInfo; + return -1; + } + + delete gsmInfo; + return KErrNone; + } + + +TInt CTe_LocMonitorStep4::TestGSMSetRxLev( ) + { + INFO_PRINTF1(_L("TestGSMSetRxLev()")); + CLbsGsmCellInfo* gsmInfo = NULL; + TRAPD( err, gsmInfo = CLbsGsmCellInfo::NewL() ); + if( KErrNone != err ) + return err; + + + gsmInfo->SetRxLevel( 10 ); + if( 10 != gsmInfo->RxLevel() ) + { + delete gsmInfo; + return -1; + } + + delete gsmInfo; + return KErrNone; + } + + + +TInt CTe_LocMonitorStep4::TestGSMAddNCellL( ) + { + INFO_PRINTF1(_L("TestGSMAddNCellL()")); + + TLbsGsmNeighbourCellInfo gnCellInfo; + gnCellInfo.SetArfcn(12); + gnCellInfo.SetBsic(13); + gnCellInfo.SetRxLevel(14); + + CLbsGsmCellInfo* gsmInfo = NULL; + TRAPD( err, gsmInfo = CLbsGsmCellInfo::NewL() ); + if( KErrNone != err ) + return err; + CleanupDeletePushL( gsmInfo ); + + gsmInfo->AddNeighbouringCellInfoL( &gnCellInfo ); + + RLbsGsmNeighbourCellInfoArray nCellArray; + CleanupClosePushL( nCellArray ); + gsmInfo->GetNeighbouringCellInfoL( nCellArray ); + TLbsGsmNeighbourCellInfo res = nCellArray[0]; + + if( 12 != res.Arfcn() || 13 != res.Bsic() || 14 != res.RxLevel() ) + { + CleanupStack::PopAndDestroy(&nCellArray); + CleanupStack::PopAndDestroy(gsmInfo); + return -1; + } + RLbsGsmNeighbourCellInfoArray * ptr = &nCellArray; + + CleanupStack::PopAndDestroy(&nCellArray); + CleanupStack::PopAndDestroy(gsmInfo); + + return KErrNone; + } + + + +TInt CTe_LocMonitorStep4::TestValidateGSMInfoHierarchyL( ) + { + INFO_PRINTF1(_L("TestValidateGSMInfoHierarchyL()")); + + CLbsGsmCellInfo* gsmInfo = CLbsGsmCellInfo::NewL(); + CleanupDeletePushL( gsmInfo ); + + TLbsGsmNeighbourCellInfo nCell; + nCell.SetArfcn( 100 ); + nCell.SetBsic( 30 ); + nCell.SetRxLevel( 20 ); + gsmInfo->AddNeighbouringCellInfoL( &nCell ); + TRAPD( err, gsmInfo->ValidateDataL() ); + if( KErrArgument != err ) + { + CleanupStack::PopAndDestroy(gsmInfo); + return -1; + } + + gsmInfo->SetRxLevel( 10 ); + TRAP( err, gsmInfo->ValidateDataL() ); + if( KErrArgument != err ) + { + CleanupStack::PopAndDestroy(gsmInfo); + return -1; + } + + gsmInfo->SetTimingAdvance( 200 ); + TRAP( err, gsmInfo->ValidateDataL() ); + if( KErrArgument != err ) + { + CleanupStack::PopAndDestroy(gsmInfo); + return -1; + } + + gsmInfo->SetCellId( 455 ); + TRAP( err, gsmInfo->ValidateDataL() ); + if( KErrArgument != err ) + { + CleanupStack::PopAndDestroy(gsmInfo); + return -1; + } + + gsmInfo->SetLocationAreaCode( 350 ); + TRAP( err, gsmInfo->ValidateDataL() ); + if( KErrArgument != err ) + { + CleanupStack::PopAndDestroy(gsmInfo); + return -1; + } + + gsmInfo->SetMobileNetworkCode( 300 ); + TRAP( err, gsmInfo->ValidateDataL() ); + if( KErrArgument != err ) + { + CleanupStack::PopAndDestroy(gsmInfo); + return -1; + } + + gsmInfo->SetMobileCountryCode( 200 ); + TRAP( err, gsmInfo->ValidateDataL() ); + if( KErrNone != err ) + { + CleanupStack::PopAndDestroy(gsmInfo); + return -1; + } + + CleanupStack::PopAndDestroy(gsmInfo); + return KErrNone; + } + + + + +// ***************************************************************************************************************************************** + + + + + +TInt CTe_LocMonitorStep4::TestWcdmaNewL( ) + { + INFO_PRINTF1(_L("TestWcdmaNewL()")); + + CLbsWcdmaCellInfo* wcdmaCell = NULL; + TRAPD( err, wcdmaCell = CLbsWcdmaCellInfo::NewL( 4, 56, 78 ) ); + if( KErrNone != err ) + return err; + + TRAP( err, wcdmaCell->ValidateDataL() ); + if( KErrNone != err ) + return err; + + if( 4 != wcdmaCell->MobileCountryCode() ) + { + delete wcdmaCell; + return -1; + } + + if( 56 != wcdmaCell->MobileNetworkCode() ) + { + delete wcdmaCell; + return -1; + } + + if( 78 != wcdmaCell->UniqueCellId() ) + { + delete wcdmaCell; + return -1; + } + + delete wcdmaCell; + return KErrNone; + } + + +TInt CTe_LocMonitorStep4::TestWcdmaSetSC( ) + { + INFO_PRINTF1(_L("TestWcdmaSetSC()")); + + CLbsWcdmaCellInfo* wcdmaCell = NULL; + TRAPD( err, wcdmaCell = CLbsWcdmaCellInfo::NewL() ); + if( KErrNone != err ) + return err; + + wcdmaCell->SetScramblingCode( 90 ); + if( 90 != wcdmaCell->ScramblingCode() ) + { + delete wcdmaCell; + return -1; + } + + delete wcdmaCell; + return KErrNone; + } + + +TInt CTe_LocMonitorStep4::TestWcdmaAddNCellL( ) + { + INFO_PRINTF1(_L("TestWcdmaAddNCellL()")); + TLbsWcdmaNeighbourCellInfo nCell( 78, 90, 47, 100 ); + CLbsWcdmaCellInfo* wcdmaCell = NULL; + + TRAPD( err, wcdmaCell = CLbsWcdmaCellInfo::NewL() ); + if( KErrNone != err ) + return err; + + CleanupDeletePushL( wcdmaCell ); + wcdmaCell->AddNeighbouringCellInfoL( &nCell ); + + RLbsWcdmaNeighbourCellInfoArray nCellArr; + CleanupClosePushL( nCellArr ); + + wcdmaCell->GetNeighbouringCellInfoL( nCellArr ); + TLbsWcdmaNeighbourCellInfo res = nCellArr[0]; + if( 78 != res.UniqueCellId() ) + { + CleanupStack::PopAndDestroy(&nCellArr); + CleanupStack::PopAndDestroy(wcdmaCell); + return -1; + } + + if( 90 != res.ScramblingCode() ) + { + CleanupStack::PopAndDestroy(&nCellArr); + CleanupStack::PopAndDestroy(wcdmaCell); + return -1; + } + CleanupStack::PopAndDestroy(&nCellArr); + CleanupStack::PopAndDestroy(wcdmaCell); + + return KErrNone; + } + + + +TInt CTe_LocMonitorStep4::TestValidateWCDMAInfoHierarchyL( ) + { + INFO_PRINTF1(_L("TestValidateWCDMAInfoHierarchyL(()")); + CLbsWcdmaCellInfo* wcdmaInfo = CLbsWcdmaCellInfo::NewL(); + CleanupDeletePushL( wcdmaInfo ); + + TLbsWcdmaNeighbourCellInfo nCell; + nCell.SetUniqueCellId( 200 ); + nCell.SetScramblingCode( 400 ); + wcdmaInfo->AddNeighbouringCellInfoL( &nCell ); + TRAPD( err, wcdmaInfo->ValidateDataL() ); + if( KErrArgument != err ) + { + CleanupStack::PopAndDestroy(wcdmaInfo); + return -1; + } + + wcdmaInfo->SetScramblingCode( 300 ); + TRAP( err, wcdmaInfo->ValidateDataL() ); + if( KErrArgument != err ) + { + CleanupStack::PopAndDestroy(wcdmaInfo); + return -1; + } + + wcdmaInfo->SetUniqueCellId( 455 ); + TRAP( err, wcdmaInfo->ValidateDataL() ); + if( KErrArgument != err ) + { + CleanupStack::PopAndDestroy(wcdmaInfo); + return -1; + } + + wcdmaInfo->SetMobileNetworkCode( 300 ); + TRAP( err, wcdmaInfo->ValidateDataL() ); + if( KErrArgument != err ) + { + CleanupStack::PopAndDestroy(wcdmaInfo); + return -1; + } + + wcdmaInfo->SetMobileCountryCode( 2000 ); + TRAP( err, wcdmaInfo->ValidateDataL() ); + if( KErrArgument != err ) + { + CleanupStack::PopAndDestroy(wcdmaInfo); + return -1; + } + + CleanupStack::PopAndDestroy(wcdmaInfo); + return KErrNone; + } + + + +// ************************************************************************************************************************* + + + +TInt CTe_LocMonitorStep4::TestCoordNewL( ) + { + INFO_PRINTF1(_L("TestCoordNewL()")); + CLbsPositionInfo* pos = NULL; + TCoordinate coord( 12.9765, 77.1423, 3000.0 ); + TLocality src( coord, 12.0 ); + src.SetVerticalAccuracy( 10.0 ); + TRAPD( err, pos = CLbsPositionInfo::NewL( src ) ); + if ( KErrNone != err ) + return err; + + TRAP( err, pos->ValidateDataL() ); + if( KErrNone != err ) + return err; + + TLocality loc; + pos->GetLocality( loc ); + if( 12.9765 != loc.Latitude() ) + { + delete pos; + return -1; + } + + if( 77.1423 != loc.Longitude() ) + { + delete pos; + return -1; + } + + if( 3000.0 != loc.Altitude() ) + { + delete pos; + return -1; + } + + if( 12.0 != loc.HorizontalAccuracy() ) + { + delete pos; + return -1; + } + + if( 10.0 != loc.VerticalAccuracy() ) + { + delete pos; + return -1; + } + + delete pos; + return KErrNone; + } + + +TInt CTe_LocMonitorStep4::TestValidateCoordInfoL( ) + { + INFO_PRINTF1(_L("TestValidateCoordInfoL()")); + + CLbsPositionInfo* pos = CLbsPositionInfo::NewL(); + CleanupDeletePushL( pos ); + TLocality loc; + loc.SetVerticalAccuracy( 50.0 ); + pos->SetLocality( loc ); + TRAPD( err, pos->ValidateDataL() ); + if( KErrArgument != err ) + { + CleanupStack::PopAndDestroy(pos); + return -1; + } + + loc.SetHorizontalAccuracy( 40.0 ); + pos->SetLocality( loc ); + TRAP( err, pos->ValidateDataL() ); + if( KErrArgument != err ) + { + CleanupStack::PopAndDestroy(pos); + return -1; + } + + TCoordinate coord( 12.9423, 77.1423, 455.0 ); + TLocality loc1( coord, 40.0 ); + pos->SetLocality( loc1 ); + pos->ValidateDataL(); + CleanupStack::PopAndDestroy(pos); + return KErrNone; + } + +// ************************************************************************************************************************* + + +TInt CTe_LocMonitorStep4::TestWlanNewL( ) + { + INFO_PRINTF1(_L("TestWlanNewL()")); + TLbsWlanMacAddress macId; + macId.Append( _L8("FF:FF:FF:FF:FF:FF") ); + + CLbsWlanInfo* wlanInfo = NULL; + TRAPD( err, wlanInfo = CLbsWlanInfo::NewL( macId, 12 ) ); + if( KErrNone != err ) + return err; + + TRAP( err, wlanInfo->ValidateDataL() ); + if( KErrNone != err ) + return err; + + TLbsWlanMacAddress res; + wlanInfo->GetMacAddress( res ); + if( macId != res ) + { + delete wlanInfo; + return -1; + } + + if( 12 != wlanInfo->SignalStrength() ) + { + delete wlanInfo; + return -1; + } + + delete wlanInfo; + return KErrNone; + } + + +TInt CTe_LocMonitorStep4::TestValidateWlanInfoL( ) + { + INFO_PRINTF1(_L("TestValidateWlanInfoL()")); + CLbsWlanInfo* wlanInfo = CLbsWlanInfo::NewL(); + CleanupDeletePushL( wlanInfo ); + + wlanInfo->SetSignalStrength( 100 ); + TRAPD( err, wlanInfo->ValidateDataL() ); + if( KErrArgument != err ) + { + CleanupStack::PopAndDestroy(wlanInfo); + return -1; + } + + TLbsWlanMacAddress macId; + macId.Append( _L8("FF:FF:FF:FF:FF:FF") ); + wlanInfo->SetMacAddress( macId ); + TRAP( err, wlanInfo->ValidateDataL() ); + if( KErrNone != err ) + { + CleanupStack::PopAndDestroy(wlanInfo); + return -1; + } + + CleanupStack::PopAndDestroy(wlanInfo); // wlanInfo + return KErrNone; + } + +// ************************************************************************************************************************* + + +TInt CTe_LocMonitorStep4::TestLocInfoAddCoordL( ) + { + INFO_PRINTF1(_L("TestLocInfoAddCoordL()")); + CBufFlat* buffer = CBufFlat::NewL( 512 ); + CleanupDeletePushL( buffer ); + CLbsLocationInfo* locInfo = CLbsLocationInfo::NewL(); + CleanupDeletePushL( locInfo ); + TCoordinate coord( 12.9765, 77.1423, 3000.0 ); + TLocality src( coord, 12.0 ); + src.SetVerticalAccuracy( 10.0 ); + CLbsPositionInfo* pos = CLbsPositionInfo::NewL( src ); + CleanupStack::PushL( pos ); + locInfo->AddAreaInfoL( pos ); + CleanupStack::Pop(); // pos; ownership transferred to instance of CLbsLocationInfo + + RBufWriteStream wStream; + wStream.Open( *buffer ); + CleanupClosePushL( wStream ); + ( (CLbsLocationInfoBase*)locInfo )->ExternaliseL( wStream ); + wStream.CommitL(); + + CleanupStack::PopAndDestroy(&wStream); + CleanupStack::PopAndDestroy(locInfo); + + locInfo = NULL; + + // Read from stream + RBufReadStream rStream; + rStream.Open( *buffer ); + + locInfo = CLbsLocationInfo::NewL(); + CleanupDeletePushL( locInfo ); + ( (CLbsLocationInfoBase*)locInfo )->InternaliseL( rStream ); + + RLbsAreaInfoBaseArray coords; + CleanupStack::PushL(TCleanupItem(*CleanUpAreaInfoArray, &coords )); + + locInfo->GetAreaInfoL( coords, CLbsLocationInfo::ELbsPosInfo ); + CLbsPositionInfo* posInfo = static_cast( coords[0] ); + TLocality res; + posInfo->GetLocality( res ); + + if( 12.9765 != res.Latitude() || + 77.1423 != res.Longitude() || + 3000.0 != res.Altitude() || + 12.0 != res.HorizontalAccuracy() || + 10.0 != res.VerticalAccuracy() ) + { + CleanupStack::PopAndDestroy(&coords); + CleanupStack::PopAndDestroy(locInfo); + CleanupStack::PopAndDestroy(buffer); + return -1; + } + + // Delete coordinate info + locInfo->ResetAreaInfo( CLbsLocationInfo::ELbsPosInfo ); + CleanupStack::PopAndDestroy(&coords); + CleanupStack::PopAndDestroy(locInfo); + CleanupStack::PopAndDestroy(buffer); + return KErrNone; + } + + +TInt CTe_LocMonitorStep4::TestLocInfoAddGsmCellL( ) + { + INFO_PRINTF1(_L("TestLocInfoAddGsmCellL()")); + CBufFlat* buffer = CBufFlat::NewL( 512 ); + CleanupDeletePushL( buffer ); + CLbsLocationInfo* locInfo = CLbsLocationInfo::NewL(); + CleanupDeletePushL( locInfo ); + CLbsGsmCellInfo* gsmCell = CLbsGsmCellInfo::NewL( 23, 34, 45, 56 ); + CleanupStack::PushL( gsmCell ); + gsmCell->SetTimingAdvance( 10 ); + gsmCell->SetRxLevel( 100 ); + TLbsGsmNeighbourCellInfo nCell( 100, 60, 30 ); + gsmCell->AddNeighbouringCellInfoL( &nCell ); + locInfo->AddAreaInfoL( gsmCell ); + CleanupStack::Pop(); // gsmCell; ownership transferred to instance of CLbsLocationInfo + + RBufWriteStream wStream; + wStream.Open( *buffer ); + CleanupClosePushL( wStream ); + ( (CLbsLocationInfoBase*)locInfo )->ExternaliseL( wStream ); + wStream.CommitL(); + + CleanupStack::PopAndDestroy(&wStream); + CleanupStack::PopAndDestroy(locInfo); + locInfo = NULL; + + // Read from stream + RBufReadStream rStream; + rStream.Open( *buffer ); + + locInfo = CLbsLocationInfo::NewL(); + CleanupDeletePushL( locInfo ); + ( (CLbsLocationInfoBase*)locInfo )->InternaliseL( rStream ); + + RLbsAreaInfoBaseArray gsmInfo; + CleanupStack::PushL(TCleanupItem(*CleanUpAreaInfoArray, &gsmInfo )); + + locInfo->GetAreaInfoL( gsmInfo, CLbsLocationInfo::ELbsGsmInfo ); + CLbsGsmCellInfo* posInfo = static_cast( gsmInfo[0] ); + + RLbsGsmNeighbourCellInfoArray nCellArr; + CleanupClosePushL(nCellArr); + posInfo->GetNeighbouringCellInfoL( nCellArr ); + + if( 23 != posInfo->MobileCountryCode() || + 34 != posInfo->MobileNetworkCode() || + 45 != posInfo->LocationAreaCode() || + 56 != posInfo->CellId() || + 10 != posInfo->TimingAdvance() || + 100 != posInfo->RxLevel() || + 100 != nCellArr[0].Arfcn() || + 60 != nCellArr[0].Bsic() || + 30 != nCellArr[0].RxLevel() ) + { + CleanupStack::PopAndDestroy(&nCellArr); + CleanupStack::PopAndDestroy(&gsmInfo); + CleanupStack::PopAndDestroy(locInfo); + CleanupStack::PopAndDestroy(buffer); + return -1; + } + posInfo->ResetNeighbouringCellInfo(); + locInfo->ResetAreaInfo( CLbsLocationInfo::ELbsGsmInfo ); // Reset + CleanupStack::PopAndDestroy(&nCellArr); + CleanupStack::PopAndDestroy(&gsmInfo); + CleanupStack::PopAndDestroy(locInfo); + CleanupStack::PopAndDestroy(buffer); + return KErrNone; + } + + +TInt CTe_LocMonitorStep4::TestLocInfoAddWcdmaCellL( ) + { + INFO_PRINTF1(_L("TestLocInfoAddWcdmaCellL()")); + CBufFlat* buffer = CBufFlat::NewL( 512 ); + CleanupDeletePushL( buffer ); + CLbsLocationInfo* locInfo = CLbsLocationInfo::NewL(); + CleanupDeletePushL( locInfo ); + CLbsWcdmaCellInfo* wcdmaCell = CLbsWcdmaCellInfo::NewL( 23, 34, 45 ); + CleanupStack::PushL( wcdmaCell ); + wcdmaCell->SetScramblingCode( 10 ); + TLbsWcdmaNeighbourCellInfo nCell( 100, 60, 47, 100 ); + wcdmaCell->AddNeighbouringCellInfoL( &nCell ); + locInfo->AddAreaInfoL( wcdmaCell ); + CleanupStack::Pop(); // wcdmaCell; ownership transferred to instance of CLbsLocationInfo + + RBufWriteStream wStream; + wStream.Open( *buffer ); + CleanupClosePushL( wStream ); + ( (CLbsLocationInfoBase*)locInfo )->ExternaliseL( wStream ); + wStream.CommitL(); + + CleanupStack::PopAndDestroy(&wStream); + CleanupStack::PopAndDestroy(locInfo); + locInfo = NULL; + + // Read from stream + RBufReadStream rStream; + rStream.Open( *buffer ); + + locInfo = CLbsLocationInfo::NewL(); + CleanupDeletePushL(locInfo); + ( (CLbsLocationInfoBase*)locInfo )->InternaliseL( rStream ); + + RLbsAreaInfoBaseArray wcdmaInfo; + CleanupStack::PushL(TCleanupItem(*CleanUpAreaInfoArray, &wcdmaInfo )); + + locInfo->GetAreaInfoL( wcdmaInfo, CLbsLocationInfo::ELbsWcdmaInfo ); + CLbsWcdmaCellInfo* posInfo = static_cast( wcdmaInfo[0] ); + + RLbsWcdmaNeighbourCellInfoArray nCellArr; + CleanupClosePushL(nCellArr); + posInfo->GetNeighbouringCellInfoL( nCellArr ); + + if( 23 != posInfo->MobileCountryCode() || 34 != posInfo->MobileNetworkCode() + || 45 != posInfo->UniqueCellId() || 10 != posInfo->ScramblingCode() || + 100 != nCellArr[0].UniqueCellId() || 60 != nCellArr[0].ScramblingCode() || + 47 != nCellArr[0].Pathloss() || 100 != nCellArr[0].SignalStrength() ) + { + CleanupStack::PopAndDestroy(&nCellArr); + CleanupStack::PopAndDestroy(&wcdmaInfo); + CleanupStack::PopAndDestroy(locInfo); + CleanupStack::PopAndDestroy(buffer); + return -1; + } + + posInfo->ResetNeighbouringCellInfo(); + locInfo->ResetAreaInfo( CLbsLocationInfo::ELbsWcdmaInfo ); + CleanupStack::PopAndDestroy(&nCellArr); + CleanupStack::PopAndDestroy(&wcdmaInfo);// Reset + CleanupStack::PopAndDestroy(locInfo); + CleanupStack::PopAndDestroy(buffer); + return KErrNone; + } + + +TInt CTe_LocMonitorStep4::TestLocInfoAddWlanL( ) + { + INFO_PRINTF1(_L("TestLocInfoAddWlanL()")); + CBufFlat* buffer = CBufFlat::NewL( 512 ); + CleanupDeletePushL( buffer ); + CLbsLocationInfo* locInfo = CLbsLocationInfo::NewL(); + CleanupDeletePushL( locInfo ); + TLbsWlanMacAddress macId; + macId.Append( _L8("FF:FF:FF:FF:FF:FF") ); + CLbsWlanInfo* wlanInfo = CLbsWlanInfo::NewL( macId, 77 ); + CleanupStack::PushL( wlanInfo ); + locInfo->AddAreaInfoL( wlanInfo ); + CleanupStack::Pop(); // wlanInfo; ownership transferred to instance of CLbsLocationInfo + + RBufWriteStream wStream; + wStream.Open( *buffer ); + CleanupClosePushL( wStream ); + ( (CLbsLocationInfoBase*)locInfo )->ExternaliseL( wStream ); + wStream.CommitL(); + + CleanupStack::PopAndDestroy(&wStream); + CleanupStack::PopAndDestroy(locInfo); + locInfo = NULL; + + // Read from stream + RBufReadStream rStream; + rStream.Open( *buffer ); + + locInfo = CLbsLocationInfo::NewL(); + CleanupDeletePushL( locInfo ); + ( (CLbsLocationInfoBase*)locInfo )->InternaliseL( rStream ); + + RLbsAreaInfoBaseArray wlanInfoArr; + CleanupStack::PushL(TCleanupItem(*CleanUpAreaInfoArray, &wlanInfoArr )); + + locInfo->GetAreaInfoL( wlanInfoArr, CLbsLocationInfo::ELbsWlanInfo ); + + CLbsWlanInfo* posInfo = static_cast( wlanInfoArr[0] ); + TLbsWlanMacAddress macIdRes; + posInfo->GetMacAddress( macIdRes ); + + if( macId != macIdRes || 77 != posInfo->SignalStrength() ) + { + CleanupStack::PopAndDestroy(&wlanInfoArr); + CleanupStack::PopAndDestroy(locInfo); + CleanupStack::PopAndDestroy(buffer); + return -1; + } + // Delete coordinate info + locInfo->ResetAreaInfo( CLbsLocationInfo::ELbsWcdmaInfo ); + CleanupStack::PopAndDestroy(&wlanInfoArr); + CleanupStack::PopAndDestroy(locInfo); + CleanupStack::PopAndDestroy(buffer); + return KErrNone; + } + diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/te_geolocmonitorsuite/src/te_geolocmonitorstep5.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/te_geolocmonitorsuite/src/te_geolocmonitorstep5.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,1835 @@ +/* +* Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ + + +/** + @file te_locmonitorstep5.cpp +*/ + +#include "te_geolocmonitorstep5.h" +#include "te_geolocmonitorsuitedefs.h" +#include "rlbslocinfoconverter.h" +#include "LocInfoConversionHandler.h" +#include + +// Plug in +const TInt KDummyPluginId = 537007117; +const TInt KSuplPluginId = 537028467; + + +CTe_LocMonitorStep5::~CTe_LocMonitorStep5() + { + } + +CTe_LocMonitorStep5::CTe_LocMonitorStep5() + { + SetTestStepName(KLocMonitorStep5); + } + +TVerdict CTe_LocMonitorStep5::doTestStepPreambleL() + { + CTe_LocMonitorStepBase::doTestStepPreambleL(); + + iConversionHandler = CLocInfoConversionHandler::NewL(); + iConversionHandler1 = CLocInfoConversionHandler::NewL(); + + return TestStepResult(); + } + +// +// This test checks that it is possible to connect a session and +// subsession with the Location Monitor and then close both. +// +TVerdict CTe_LocMonitorStep5::doTestStepL() + { + INFO_PRINTF1(_L("CTe_LocMonitorStep5::doTestStepL() ")); + + if (TestStepResult()==EPass) + { + + // Run all tests sequentially first + RLbsLocInfoConverter_Connect1L(); + RLbsLocInfoConverter_Connect2L(); + RLbsLocInfoConverter_ConvertLocationInfo1L(); + RLbsLocInfoConverter_ConvertLocationInfo2L(); + RLbsLocInfoConverter_ConvertLocationInfo3L(); + RLbsLocInfoConverter_ConvertLocationInfo4L(); + RLbsLocInfoConverter_ConvertLocationInfo5L(); + + RLbsLocInfoConverter_ConvertLocationInfo8L(); + RLbsLocInfoConverter_ConvertLocationInfo9L(); + RLbsLocInfoConverter_ConvertLocationInfo10L(); + RLbsLocInfoConverter_Cancel1L(); + RLbsLocInfoConverter_Cancel2L(); + RLbsLocInfoConverter_Cancel3L(); + RLbsLocInfoConverter_Cancel4L(); + + } + + return TestStepResult(); + } + +TVerdict CTe_LocMonitorStep5::doTestStepPostambleL() + { + delete iConversionHandler; + delete iConversionHandler1; + CTe_LocMonitorStepBase::doTestStepPostambleL(); + return TestStepResult(); + } + + + +// ----------------------------------------------------------------------------- +// CLocInfoConversionUnitTest::RLbsLocInfoConverter_Connect1 +// simple session and subsession. +// ----------------------------------------------------------------------------- +// +TInt CTe_LocMonitorStep5::RLbsLocInfoConverter_Connect1L() + { + INFO_PRINTF1(_L("*** RLbsLocInfoConverter_Connect1L()")); + TInt error; + RLbsLocMonitorSession locMonitorSession; + error = locMonitorSession.Connect(); + if( error != KErrNone ) + { + return error; + } + CleanupClosePushL( locMonitorSession ); + RLbsLocInfoConverter locInfoConverter; + CleanupClosePushL( locInfoConverter ); + locInfoConverter.OpenL( locMonitorSession ); + locInfoConverter.Close(); + CleanupStack::PopAndDestroy( 2 ); // locInfoConverter,locMonitorSession + return KErrNone; + } + +// ----------------------------------------------------------------------------- +// CTe_LocMonitorStep5::RLbsLocInfoConverter_Connect2 +// Opening multiple subsession from single session +// ----------------------------------------------------------------------------- +// +TInt CTe_LocMonitorStep5::RLbsLocInfoConverter_Connect2L() + { + INFO_PRINTF1(_L("*** RLbsLocInfoConverter_Connect2L()")); + RLbsLocMonitorSession locMonitorSession; + TInt error = locMonitorSession.Connect(); + if( error != KErrNone ) + { + return error; + } + CleanupClosePushL( locMonitorSession ); + RLbsLocInfoConverter locInfoConverter; + CleanupClosePushL( locInfoConverter ); + RLbsLocInfoConverter locInfoConverter1; + CleanupClosePushL( locInfoConverter1 ); + + locInfoConverter.OpenL( locMonitorSession ); + locInfoConverter1.OpenL( locMonitorSession ); + locInfoConverter.Close(); + locInfoConverter1.Close(); + + CleanupStack::PopAndDestroy( 3 ); //locInfoConverter1,locInfoConverter and + //locMonitorSession + return KErrNone; + } + + +// ----------------------------------------------------------------------------- +// CTe_LocMonitorStep5::RLbsLocInfoConverter_ConvertLocationInfo1L +// This test case tests the simple and corner case related +// to RLbsLocInfoConverter::ConvertLocationInfoL +// ----------------------------------------------------------------------------- +// +TInt CTe_LocMonitorStep5::RLbsLocInfoConverter_ConvertLocationInfo1L() + { + INFO_PRINTF1(_L("*** RLbsLocInfoConverter_ConvertLocationInfo1L()")); + RLbsLocMonitorSession locMonitorSession; + TInt error = locMonitorSession.Connect(); + if( error != KErrNone ) + { + return error; + } + CleanupClosePushL( locMonitorSession ); + RLbsLocInfoConverter locInfoConverter; + CleanupClosePushL( locInfoConverter ); + locInfoConverter.OpenL( locMonitorSession ); + + + TUid conversionModuleId = TUid::Uid( KDummyPluginId ); + + /** + * Case 1: where NULL pointer is passed instead of location info + */ + error = KErrNone; + CLbsLocationInfo* locationInfo = CLbsLocationInfo::NewL(); + CleanupStack::PushL( locationInfo ); + TRAP( error,locInfoConverter.ConvertLocationInfoL( + *locationInfo,ELbsConversionNotDefined,ELbsConversionOutputPosition, + conversionModuleId,iConversionHandler->iStatus )); + if( error!= KErrArgument ) + { + INFO_PRINTF2(_L("Expected return value KErrArgument, got %d)"), error); + User::Leave( KErrArgument ); + } + + /** + * Case 2: where we pass location info.This is + * just test where this method completes without leaving. + */ + + // Here we append gsmcell info object to the existing location info object. + AppendAreaInfoObjectToLocationInfoL( locationInfo,ELbsAreaGsmCellInfoClass ); + + locInfoConverter.ConvertLocationInfoL( + *locationInfo,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId,iConversionHandler->iStatus ); + iConversionHandler->Start(); + locInfoConverter.CancelConvertLocationInfo(); + iConversionHandler->Cancel(); + CleanupStack::PopAndDestroy( locationInfo ); + + /** + * Case 3. Empty location info array is passed. + */ + error = KErrNone; + RPointerArray locationInfoArray; + CleanupClosePushL( locationInfoArray ); + TRAP( error,locInfoConverter.ConvertLocationInfoL( + locationInfoArray,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId,iConversionHandler->iStatus )); + + if( error != KErrArgument ) + { + INFO_PRINTF2(_L("Expected return value KErrArgument, got %d)"), error); + User::Leave( KErrArgument ); + } + + /** + * Case 4: where we pass location info array.This is + * just test where this method completes without leaving. + */ + + // Here we create locationInfo object with gsm cell info object contained in it. + CLbsLocationInfo* locationInfo1 = CreateLocationInfoObjectLC( ELbsAreaGsmCellInfoClass ); + locationInfoArray.Append( locationInfo1 ); + + locInfoConverter.ConvertLocationInfoL( + locationInfoArray,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId,iConversionHandler->iStatus ); + iConversionHandler->Start(); + locInfoConverter.CancelConvertLocationInfo(); + iConversionHandler->Cancel(); + + CleanupStack::Pop( 2 ); //locationInfo1,locationInfoArray + locationInfoArray.ResetAndDestroy(); + CleanupStack::PopAndDestroy( 2 ); // locInfoConverter,locMonitorSession + return KErrNone; + } + +// ----------------------------------------------------------------------------- +// CTe_LocMonitorStep5::RLbsLocInfoConverter_ConvertLocationInfo2L +// This test case tests ConvertLocationInfo when expected information is +// of type ECoordinate +// ----------------------------------------------------------------------------- +// +TInt CTe_LocMonitorStep5::RLbsLocInfoConverter_ConvertLocationInfo2L() + { + INFO_PRINTF1(_L("*** RLbsLocInfoConverter_ConvertLocationInfo2L()")); + RLbsLocMonitorSession locMonitorSession; + TInt error = locMonitorSession.Connect(); + if( error != KErrNone ) + { + return error; + } + CleanupClosePushL( locMonitorSession ); + RLbsLocInfoConverter locInfoConverter; + CleanupClosePushL( locInfoConverter ); + locInfoConverter.OpenL( locMonitorSession ); + + + RPointerArray locationInfoArray; + CleanupClosePushL( locationInfoArray ); + + TUid conversionModuleId = TUid::Uid( KDummyPluginId ); + + /** + * case 1: Any information regarding the area is passed and + * coordinate corresponding to that area info is expected. + */ + + // Here GSM cell info is passed as input area. + CLbsLocationInfo* locationInfo = CreateLocationInfoObjectLC( ELbsAreaGsmCellInfoClass ); + + locInfoConverter.ConvertLocationInfoL( + *locationInfo,ELbsConversionNotDefined,ELbsConversionOutputPosition + ,conversionModuleId,iConversionHandler->iStatus ); + iConversionHandler->Start(); + CActiveScheduler::Start(); + + error = iConversionHandler->iStatus.Int(); + // If the conversion status is KErrNone, check for the corresponding + // converted info. + if( error == KErrNone ) + { + CheckPositionConvertedInfoL( locationInfo ); + } + // KErrNotSupported and KErrNotFound are allowed error codes. + else if( !( error == KErrNotSupported || error == KErrNotFound ) ) + { + INFO_PRINTF2(_L("Expected return value KErrNotSupported or KErrNotFound, got %d)"), error); + User::Leave( KErrArgument ); + } + + /** + * case 2: Pass any information related to multiple area and we expect coordinate information + * corresponding to each area information. + */ + + // Create one more location info object which holds wlan info for which corresponding coordinate + // is expected. + CLbsLocationInfo* locationInfo2 = CreateLocationInfoObjectLC( ELbsAreaWlanInfoClass ); + + // Before pushing location info object, remove the converted info from it. + // We had requested for coordinate info, hence we need to clear it before + // we use it as input for next conversion. + locationInfo->ResetAreaInfo( CLbsLocationInfo::ELbsPosInfo ); + locationInfoArray.Append( locationInfo ); + + locationInfoArray.Append( locationInfo2 ); + + locInfoConverter.ConvertLocationInfoL( + locationInfoArray,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId,iConversionHandler->iStatus ); + iConversionHandler->Start(); + + // This is just to block the control till the call back method is called. + // Code after this statement will be resumed when Stop on CActiveScheduler + // is called in the HandleLocationConversion method. + CActiveScheduler::Start(); + + error = iConversionHandler->iStatus.Int(); + // Iterate through the array and check for converted info. + if( error == KErrNone ) + { + for( TInt i=0;i ( locationInfobase ); + CheckPositionConvertedInfoL( locationInfo ); + } + } + // KErrNotSupported and KErrNotFound are allowed error codes. + else if( !( error == KErrNotSupported || error == KErrNotFound ) ) + { + INFO_PRINTF2(_L("Expected return value KErrNotSupported or KErrNotFound, got %d)"), error); + User::Leave( KErrArgument ); + } + + CleanupStack::Pop( 3 ); // locationInfo,locationInfo1,locationInfoArray + locationInfoArray.ResetAndDestroy(); + CleanupStack::PopAndDestroy( 2 ); // locInfoConverter,locMonitorSession + return KErrNone; + } + + +// ----------------------------------------------------------------------------- +// CTe_LocMonitorStep5::RLbsLocInfoConverter_ConvertLocationInfo3L +// This test case tests ConvertLocationInfo when expected information is +// of type EGsm +// ----------------------------------------------------------------------------- +// +TInt CTe_LocMonitorStep5::RLbsLocInfoConverter_ConvertLocationInfo3L() + { + INFO_PRINTF1(_L("*** RLbsLocInfoConverter_ConvertLocationInfo3L()")); + RLbsLocMonitorSession locMonitorSession; + TInt error = locMonitorSession.Connect(); + if( error != KErrNone ) + { + return error; + } + CleanupClosePushL( locMonitorSession ); + RLbsLocInfoConverter locInfoConverter; + CleanupClosePushL( locInfoConverter ); + locInfoConverter.OpenL( locMonitorSession ); + + RPointerArray locationInfoArray; + CleanupClosePushL( locationInfoArray ); + + TUid conversionModuleId = TUid::Uid( KDummyPluginId );; + + /** + * case 1: Pass any area info and we expect GSM cell info + */ + + // Here WLAN info is passed as input area. + CLbsLocationInfo* locationInfo = CreateLocationInfoObjectLC( ELbsAreaWlanInfoClass ); + + locInfoConverter.ConvertLocationInfoL( + *locationInfo,ELbsConversionCacheOnly,ELbsConversionOutputGsm, + conversionModuleId,iConversionHandler->iStatus ); + iConversionHandler->Start(); + + // This is just to block the control till the call back method is called. + // Code after this statement will be resumed when Stop on CActiveScheduler + // is called in the HandleLocationConversion method. + CActiveScheduler::Start(); + + error = iConversionHandler->iStatus.Int(); + // If the conversion status is success, check for the corresponding + // converted info. + if( error == KErrNone ) + { + CheckGsmCellConvertedInfoL( locationInfo ); + } + // KErrNotSupported and KErrNotFound are allowed error codes. + else if( !( error == KErrNotSupported || error == KErrNotFound ) ) + { + INFO_PRINTF2(_L("Expected return value KErrNotSupported or KErrNotFound, got %d)"), error); + User::Leave( KErrArgument ); + } + + /** + * case 2: Pass any information related to multiple area and we expect GSM cell info + * corresponding to each area information. + */ + + // Create one more location info object which holds coordinate info for which corresponding GSM + // cell info is expected. + CLbsLocationInfo* locationInfo1 = CreateLocationInfoObjectLC( ELbsAreaPositionInfoClass ); + + // Before pushing location info object, remove the converted info from it. + // We had requested for GSM cell info, hence we need to clear it before + // we use it for next conversion. + locationInfo->ResetAreaInfo( CLbsLocationInfo::ELbsGsmInfo ); + locationInfoArray.Append( locationInfo ); + locationInfoArray.Append( locationInfo1 ); + + locInfoConverter.ConvertLocationInfoL( + locationInfoArray,ELbsConversionCacheOnly,ELbsConversionOutputGsm, + conversionModuleId,iConversionHandler->iStatus ); + iConversionHandler->Start(); + + // This is just to block the control till the call back method is called. + // Code after this statement will be resumed when Stop on CActiveScheduler + // is called in the HandleLocationConversion method. + CActiveScheduler::Start(); + + error = iConversionHandler->iStatus.Int(); + // Iterate through the array and check for converted info. + if( error == KErrNone ) + { + for( TInt i=0;i ( locationInfobase ); + CheckGsmCellConvertedInfoL( locationInfo ); + } + } + // KErrNotSupported and KErrNotFound are allowed error codes. + else if( !( error == KErrNotSupported || error == KErrNotFound ) ) + { + INFO_PRINTF2(_L("Expected return value KErrNotSupported or KErrNotFound, got %d)"), error); + User::Leave( KErrArgument ); + } + CleanupStack::Pop( 3 ); // locationInfo,locationInfo1,locationInfoArray + locationInfoArray.ResetAndDestroy(); + CleanupStack::PopAndDestroy( 2 ); // locInfoConverter,locMonitorSession + return KErrNone; + } + + +// ----------------------------------------------------------------------------- +// CTe_LocMonitorStep5::RLbsLocInfoConverter_ConvertLocationInfo4L +//This test case tests ConvertLocationInfo when expected information is +// of type EWcdma +// ----------------------------------------------------------------------------- +// +TInt CTe_LocMonitorStep5::RLbsLocInfoConverter_ConvertLocationInfo4L() + { + INFO_PRINTF1(_L("*** RLbsLocInfoConverter_ConvertLocationInfo4L()")); + RLbsLocMonitorSession locMonitorSession; + TInt error = locMonitorSession.Connect(); + if( error != KErrNone ) + { + return error; + } + CleanupClosePushL( locMonitorSession ); + RLbsLocInfoConverter locInfoConverter; + CleanupClosePushL( locInfoConverter ); + locInfoConverter.OpenL( locMonitorSession ); + + RPointerArray locationInfoArray; + CleanupClosePushL( locationInfoArray ); + + TUid conversionModuleId = TUid::Uid( KDummyPluginId ); + + /** + * case 1: Pass any area info pointer and we expect EWcdma type + */ + CLbsLocationInfo* locationInfo = CreateLocationInfoObjectLC( ELbsAreaPositionInfoClass ); + + locInfoConverter.ConvertLocationInfoL( + *locationInfo,ELbsConversionSilent,ELbsConversionOutputWcdma, + conversionModuleId,iConversionHandler->iStatus ); + iConversionHandler->Start(); + + // This is just to block the control till the call back method is called. + // Code after this statement will be resumed when Stop on CActiveScheduler + // is called in the HandleLocationConversion method. + CActiveScheduler::Start(); + + error = iConversionHandler->iStatus.Int(); + // If the conversion status is success, check for the corresponding + // converted info. + if( error == KErrNone ) + { + CheckWcdmaCellConvertedInfoL( locationInfo ); + } + // KErrNotSupported and KErrNotFound are allowed error codes. + else if( !( error == KErrNotSupported || error == KErrNotFound ) ) + { + INFO_PRINTF2(_L("Expected return value KErrNotSupported or KErrNotFound, got %d)"), error); + User::Leave( KErrArgument ); + } + + /** + * case 2: Pass any information related to multiple area and we expect wcdma information + * corresponding to each area information. + */ + + // Create one more location info object which holds wlan info for which corresponding WCDMA + // cell info is expected. + CLbsLocationInfo* locationInfo1 = CreateLocationInfoObjectLC( ELbsAreaWlanInfoClass ); + + // Before pushing location info object, remove the converted info from it. + // We had requested for WCDMA info, hence we need to clear it before + // we use it as input for next conversion. + locationInfo->ResetAreaInfo( CLbsLocationInfo::ELbsWcdmaInfo ); + locationInfoArray.Append( locationInfo ); + locationInfoArray.Append( locationInfo1 ); + + locInfoConverter.ConvertLocationInfoL( + locationInfoArray,ELbsConversionSilent,ELbsConversionOutputWcdma, + conversionModuleId,iConversionHandler->iStatus ); + + iConversionHandler->Start(); + + // This is just to block the control till the call back method is called. + // Code after this statement will be resumed when Stop on CActiveScheduler + // is called in the HandleLocationConversion method. + CActiveScheduler::Start(); + + error = iConversionHandler->iStatus.Int(); + // Iterate through the array and check for converted info. + if( error == KErrNone ) + { + for( TInt i=0;i ( locationInfobase ); + CheckWcdmaCellConvertedInfoL( locationInfo ); + } + } + // KErrNotSupported and KErrNotFound are allowed error codes. + else if( !( error == KErrNotSupported || error == KErrNotFound ) ) + { + INFO_PRINTF2(_L("Expected return value KErrNotSupported or KErrNotFound, got %d)"), error); + User::Leave( KErrArgument ); + } + + CleanupStack::Pop( 3 ); // locationInfo,locationInfo1,locationInfoArray + locationInfoArray.ResetAndDestroy(); + CleanupStack::PopAndDestroy( 2 ); // locInfoConverter,locMonitorSession + return KErrNone; + } + + +// ----------------------------------------------------------------------------- +// CTe_LocMonitorStep5::RLbsLocInfoConverter_ConvertLocationInfo5L +// This test case tests ConvertLocationInfo when expected information is +// of type EWlan +// ----------------------------------------------------------------------------- +// +TInt CTe_LocMonitorStep5::RLbsLocInfoConverter_ConvertLocationInfo5L() + { + INFO_PRINTF1(_L("*** RLbsLocInfoConverter_ConvertLocationInfo5L()")); + RLbsLocMonitorSession locMonitorSession; + TInt error = locMonitorSession.Connect(); + if( error != KErrNone ) + { + return error; + } + CleanupClosePushL( locMonitorSession ); + RLbsLocInfoConverter locInfoConverter; + CleanupClosePushL( locInfoConverter ); + locInfoConverter.OpenL( locMonitorSession ); + + RPointerArray locationInfoArray; + CleanupClosePushL( locationInfoArray ); + + TUid conversionModuleId = TUid::Uid( KDummyPluginId ); + + /** + * case 1: Pass any area info pointer and we expect EWlan type + */ + CLbsLocationInfo* locationInfo = CreateLocationInfoObjectLC( ELbsAreaWcmdaCellInfoClass ); + + locInfoConverter.ConvertLocationInfoL( + *locationInfo,ELbsConversionCacheOnly,ELbsConversionOutputWlan,conversionModuleId,iConversionHandler->iStatus ); + iConversionHandler->Start(); + + // This is just to block the control till the call back method is called. + // Code after this statement will be resumed when Stop on CActiveScheduler + // is called in the HandleLocationConversion method. + CActiveScheduler::Start(); + + // If the conversion status is success, check for the corresponding + // converted info. + if( iConversionHandler->iStatus == KErrNone ) + { + CheckWlanConvertedInfoL( locationInfo ); + } + // KErrNotSupported and KErrNotFound are allowed error codes. + else if( !( iConversionHandler->iStatus == KErrNotSupported || iConversionHandler->iStatus == KErrNotFound ) ) + { + INFO_PRINTF2(_L("Expected return value KErrNotSupported or KErrNotFound, got %d)"), iConversionHandler->iStatus); + User::Leave( KErrArgument ); + } + + /** + * Case 2: Pass any information related to multiple area and we expect Wlan info + * corresponding to each area information. + */ + + // Create one more location info object which holds coordinate info for which corresponding + // Wlan info is expected. + CLbsLocationInfo* locationInfo1 = CreateLocationInfoObjectLC( ELbsAreaPositionInfoClass ); + + // Before pushing location info object, remove the converted info from it. + // We had requested for wlan info, hence we need to clear it before + // we use it for next conversion. + locationInfo->ResetAreaInfo( CLbsLocationInfo::ELbsWlanInfo ); + locationInfoArray.Append( locationInfo ); + locationInfoArray.Append( locationInfo1 ); + + TRequestStatus status; + locInfoConverter.ConvertLocationInfoL( + locationInfoArray,ELbsConversionCacheOnly,ELbsConversionOutputWlan,conversionModuleId,iConversionHandler->iStatus); + iConversionHandler->Start(); + + // This is just to block the control till the call back method is called. + // Code after this statement will be resumed when Stop on CActiveScheduler + // is called in the HandleLocationConversion method. + CActiveScheduler::Start(); + + // Iterate through the array and check for converted info. + if( iConversionHandler->iStatus == KErrNone ) + { + for( TInt i=0;i ( locationInfobase ); + CheckWlanConvertedInfoL( locationInfo ); + } + } + // KErrNotSupported and KErrNotFound are allowed error codes. + else if( !( iConversionHandler->iStatus == KErrNotSupported || iConversionHandler->iStatus == KErrNotFound ) ) + { + INFO_PRINTF2(_L("Expected return value KErrNotSupported or KErrNotFound, got %d)"), iConversionHandler->iStatus); + User::Leave( KErrArgument ); + } + CleanupStack::Pop( 3 ); // locationInfo,locationInfo1,locationInfoArray + locationInfoArray.ResetAndDestroy(); + CleanupStack::PopAndDestroy( 2 ); // locInfoConverter,locMonitorSession + return KErrNone; + } + +// ----------------------------------------------------------------------------- +// CTe_LocMonitorStep5::RLbsLocInfoConverter_ConvertLocationInfo6L +// This test case tests the scenario when user tries to request new single +// conversion without waiting for completion of previous one. +// ----------------------------------------------------------------------------- +// +TInt CTe_LocMonitorStep5::RLbsLocInfoConverter_ConvertLocationInfo6L() + { + INFO_PRINTF1(_L("*** RLbsLocInfoConverter_ConvertLocationInfo6L()")); + RLbsLocMonitorSession locMonitorSession; + TInt error = locMonitorSession.Connect(); + if( error != KErrNone ) + { + return error; + } + CleanupClosePushL( locMonitorSession ); + RLbsLocInfoConverter locInfoConverter; + CleanupClosePushL( locInfoConverter ); + locInfoConverter.OpenL( locMonitorSession ); + + TUid conversionModuleId = TUid::Uid( KDummyPluginId ); + + CLbsLocationInfo* locationInfo = CreateLocationInfoObjectLC( ELbsAreaGsmCellInfoClass ); + + // Here in this case input area doesnt matter + locInfoConverter.ConvertLocationInfoL( + *locationInfo,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId,iConversionHandler->iStatus ); + iConversionHandler->Start(); + + CLbsLocationInfo* locationInfo1 = CreateLocationInfoObjectLC( ELbsAreaWcmdaCellInfoClass ); + + error = KErrNone; + TRequestStatus status; + + locInfoConverter.ConvertLocationInfoL( + *locationInfo1,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId,status ); + + CleanupStack::PopAndDestroy( 2 ); // locationInfo1,locationInfo + return KErrNone; + } + +// ----------------------------------------------------------------------------- +// CTe_LocMonitorStep5::RLbsLocInfoConverter_ConvertLocationInfo7L +// This test case tests the scenario when user tries to request new batch +// conversion without waiting for completion of previous one. +// ----------------------------------------------------------------------------- +// +TInt CTe_LocMonitorStep5::RLbsLocInfoConverter_ConvertLocationInfo7L() + { + INFO_PRINTF1(_L("*** RLbsLocInfoConverter_ConvertLocationInfo7L()")); + RLbsLocMonitorSession locMonitorSession; + TInt error = locMonitorSession.Connect(); + if( error != KErrNone ) + { + return error; + } + CleanupClosePushL( locMonitorSession ); + RLbsLocInfoConverter locInfoConverter; + CleanupClosePushL( locInfoConverter ); + locInfoConverter.OpenL( locMonitorSession ); + + TUid conversionModuleId = TUid::Uid( KNullUidValue );; + + // Here in this case input area doesnt matter + RPointerArray locationInfoArray; + CleanupClosePushL( locationInfoArray ); + + RPointerArray locationInfoArray1; + CleanupClosePushL( locationInfoArray1 ); + + CLbsLocationInfo* locationInfo = CreateLocationInfoObjectLC( ELbsAreaGsmCellInfoClass ); + + CLbsLocationInfo* locationInfo1 = CreateLocationInfoObjectLC( ELbsAreaWlanInfoClass ); + + locationInfoArray.Append( locationInfo ); + + locInfoConverter.ConvertLocationInfoL( + locationInfoArray,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId ,iConversionHandler->iStatus ); + iConversionHandler->Start(); + + locationInfoArray1.Append( locationInfo1 ); + + TRequestStatus status; + + locInfoConverter.ConvertLocationInfoL( + locationInfoArray1,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId,status ); + + CleanupStack::Pop(4); // locationInfo1,locationInfoArray1,locationInfo,locationInfoArray + locationInfoArray.ResetAndDestroy(); + locationInfoArray1.ResetAndDestroy(); + CleanupStack::PopAndDestroy( 2 ); // locInfoConverter,locMonitorSession + return KErrNone; + } + + +// ----------------------------------------------------------------------------- +// CTe_LocMonitorStep5::RLbsLocInfoConverter_ConvertLocationInfo8L +// This test case tests the scenario when user tries to request two conversion +// using two subsessions simultaneously specifying same plugin. +// ----------------------------------------------------------------------------- +// +TInt CTe_LocMonitorStep5::RLbsLocInfoConverter_ConvertLocationInfo8L() + { + INFO_PRINTF1(_L("*** RLbsLocInfoConverter_ConvertLocationInfo8L()")); + RLbsLocMonitorSession locMonitorSession; + TInt error = locMonitorSession.Connect(); + if( error != KErrNone ) + { + return error; + } + CleanupClosePushL( locMonitorSession ); + + // Here we need to open two subsessions. + RLbsLocInfoConverter locInfoConverter,locInfoConverter1; + CleanupClosePushL( locInfoConverter ); + locInfoConverter.OpenL( locMonitorSession ); + + CleanupClosePushL( locInfoConverter1 ); + locInfoConverter1.OpenL( locMonitorSession ); + + RPointerArray locationInfoArray; + CleanupClosePushL( locationInfoArray ); + + RPointerArray locationInfoArray1; + CleanupClosePushL( locationInfoArray1 ); + + TUid conversionModuleId = TUid::Uid( KDummyPluginId ); + + /** + * Case 1: Users tries to request 2 simultaneous single conversion + * using 2 subsession specifying same conversion uid. + */ + + // Here type of area input doesnt matter. + CLbsLocationInfo* locationInfo = CreateLocationInfoObjectLC( ELbsAreaGsmCellInfoClass ); + + CLbsLocationInfo* locationInfo1 = CreateLocationInfoObjectLC( ELbsAreaGsmCellInfoClass ); + + locInfoConverter.ConvertLocationInfoL( + *locationInfo,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId,iConversionHandler->iStatus ); + iConversionHandler->Start(); + + locInfoConverter1.ConvertLocationInfoL( + *locationInfo1,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId,iConversionHandler1->iStatus ); + iConversionHandler1->Start(); + + // This is just to block the control till the call back method is called. + // Code after this statement will be resumed when Stop on CActiveScheduler + // is called in the HandleLocationConversion method. + CActiveScheduler::Start(); + + // Here we need to wait till both the request completes.Hence we need to block it once again + // till the 2nd request completes. + if( iConversionHandler->iStatus.Int() == KRequestPending || + iConversionHandler1->iStatus.Int() == KRequestPending ) + { + CActiveScheduler::Start(); + } + + // Check the converted values in both the conversions. + error = iConversionHandler->iStatus.Int(); + if( error == KErrNone ) + { + CheckPositionConvertedInfoL( locationInfo ); + } + else + { + INFO_PRINTF2(_L("Expected return value KErrNone, got %d)"), error); + User::Leave( KErrArgument ); + } + + error = iConversionHandler1->iStatus.Int(); + if( error == KErrNone ) + { + CheckPositionConvertedInfoL( locationInfo1 ); + } + else + { + INFO_PRINTF2(_L("Expected return value KErrNone, got %d)"), error); + User::Leave( KErrArgument ); + } + + /** + * Case 2: Users tries to request 2 simultaneous bulk conversion + * using 2 subsession specifying same conversion uid. + */ + + // Before we append the location info object to the info array, + // we need to clear the converted info in each object. + locationInfo->ResetAreaInfo( CLbsLocationInfo::ELbsPosInfo); + locationInfo1->ResetAreaInfo( CLbsLocationInfo::ELbsPosInfo ); + + locationInfoArray.Append( locationInfo ); + locationInfoArray1.Append( locationInfo1 ); + + locInfoConverter.ConvertLocationInfoL( + locationInfoArray,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId,iConversionHandler->iStatus ); + iConversionHandler->Start(); + + locInfoConverter1.ConvertLocationInfoL( + locationInfoArray1,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId,iConversionHandler1->iStatus ); + iConversionHandler1->Start(); + + // This is just to block the control till the call back method is called. + // Code after this statement will be resumed when Stop on CActiveScheduler + // is called in the HandleLocationConversion method. + CActiveScheduler::Start(); + + // Here we need to wait till both the request completes.Hence we need to block it once again + // till the 2nd request completes. + if( iConversionHandler->iStatus.Int() == KRequestPending || + iConversionHandler1->iStatus.Int() == KRequestPending ) + { + CActiveScheduler::Start(); + } + + // Check the converted values in both the conversions. + // Iterate through the array and check for converted info. + error = iConversionHandler->iStatus.Int(); + if( error == KErrNone ) + { + for( TInt i=0;i ( locationInfobase ); + CheckPositionConvertedInfoL( locationInfo ); + } + } + else + { + INFO_PRINTF2(_L("Expected return value KErrNone, got %d)"), error); + User::Leave( KErrArgument ); + } + + error = iConversionHandler1->iStatus.Int(); + if( error == KErrNone ) + { + for( TInt i=0;i ( locationInfobase ); + CheckPositionConvertedInfoL( locationInfo ); + } + } + else + { + INFO_PRINTF2(_L("Expected return value KErrNone, got %d)"), error); + User::Leave( KErrArgument ); + } + + CleanupStack::Pop(4); // locationInfo1,locationInfoArray1,locationInfo,locationInfoArray + locationInfoArray.ResetAndDestroy(); + locationInfoArray1.ResetAndDestroy(); + CleanupStack::PopAndDestroy( 3 ); // locInfoConverter,locInfoConverter1,locMonitorSession + return KErrNone; + } + + +// ----------------------------------------------------------------------------- +// CTe_LocMonitorStep5::RLbsLocInfoConverter_ConvertLocationInfo9L +// This test case tests the scenario when user tries to request two conversion +// using two subsessions simultaneously specifying different plugin. +// ----------------------------------------------------------------------------- +// +TInt CTe_LocMonitorStep5::RLbsLocInfoConverter_ConvertLocationInfo9L() + { + INFO_PRINTF1(_L("*** RLbsLocInfoConverter_ConvertLocationInfo9L()")); + RLbsLocMonitorSession locMonitorSession; + TInt error = locMonitorSession.Connect(); + if( error != KErrNone ) + { + return error; + } + CleanupClosePushL( locMonitorSession ); + + // Here we need two subsessions + RLbsLocInfoConverter locInfoConverter,locInfoConverter1; + CleanupClosePushL( locInfoConverter ); + locInfoConverter.OpenL( locMonitorSession ); + + CleanupClosePushL( locInfoConverter1 ); + locInfoConverter1.OpenL( locMonitorSession ); + + RPointerArray locationInfoArray; + CleanupClosePushL( locationInfoArray ); + + RPointerArray locationInfoArray1; + CleanupClosePushL( locationInfoArray1 ); + + TUid conversionModuleId1 = TUid::Uid( KDummyPluginId ); + TUid conversionModuleId2 = TUid::Uid( KSuplPluginId ); + + /** + * Case 1: Users tries to request 2 simultaneous single conversion + * using 2 subsession specifying different conversion uid. + */ + + CLbsLocationInfo* locationInfo = CreateLocationInfoObjectLC( ELbsAreaWcmdaCellInfoClass ); + + CLbsLocationInfo* locationInfo1 = CreateLocationInfoObjectLC( ELbsAreaWlanInfoClass ); + + locInfoConverter.ConvertLocationInfoL( + *locationInfo,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId1,iConversionHandler->iStatus ); + iConversionHandler->Start(); + + locInfoConverter1.ConvertLocationInfoL( + *locationInfo1,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId2,iConversionHandler1->iStatus ); + iConversionHandler1->Start(); + + // This is just to block the control till the call back method is called. + // Code after this statement will be resumed when Stop on CActiveScheduler + // is called in the HandleLocationConversion method. + CActiveScheduler::Start(); + + // Here we need to wait till both the request completes.Hence we need to block it once again + // till the 2nd request completes. + if( iConversionHandler->iStatus.Int() == KRequestPending || + iConversionHandler1->iStatus.Int() == KRequestPending ) + { + CActiveScheduler::Start(); + } + + // Check the converted values in both the conversions. + error = iConversionHandler->iStatus.Int(); + if( error == KErrNone ) + { + CheckPositionConvertedInfoL( locationInfo ); + } + else if( !( error == KErrNotFound || error == KErrNotSupported ) ) + { + INFO_PRINTF2(_L("Expected return value KErrNone, got %d)"), error); + User::Leave( KErrArgument ); + } + + error = iConversionHandler1->iStatus.Int(); + if( error == KErrNone ) + { + CheckPositionConvertedInfoL( locationInfo1 ); + } + else if( !( error == KErrNotFound || error == KErrNotSupported ) ) + { + INFO_PRINTF2(_L("Expected return value KErrNone, got %d)"), error); + User::Leave( KErrArgument ); + } + + /** + * Case 2: Users tries to request 2 simultaneous bulk conversion + * using 2 subsession specifying same conversion uid. + */ + + // Before we append the location info object to the info array, + // we need to clear the converted info in each object. + locationInfo->ResetAreaInfo( CLbsLocationInfo::ELbsPosInfo ); + locationInfo1->ResetAreaInfo( CLbsLocationInfo::ELbsPosInfo ); + + locationInfoArray.Append( locationInfo ); + locationInfoArray1.Append( locationInfo1 ); + + locInfoConverter.ConvertLocationInfoL( + locationInfoArray,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId1,iConversionHandler->iStatus ); + iConversionHandler->Start(); + + locInfoConverter1.ConvertLocationInfoL( + locationInfoArray1,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId2,iConversionHandler1->iStatus ); + iConversionHandler1->Start(); + + // This is just to block the control till the call back method is called. + // Code after this statement will be resumed when Stop on CActiveScheduler + // is called in the HandleLocationConversion method. + CActiveScheduler::Start(); + + // Here we need to wait till both the request completes.Hence we need to block it once again + // till the 2nd request completes. + if( iConversionHandler->iStatus.Int() == KRequestPending || + iConversionHandler1->iStatus.Int() == KRequestPending ) + { + CActiveScheduler::Start(); + } + + // Check the converted values in both the conversions. + // Iterate through the array and check for converted info. + error = iConversionHandler->iStatus.Int(); + if( error == KErrNone ) + { + for( TInt i=0;i ( locationInfobase ); + CheckPositionConvertedInfoL( locationInfo ); + } + } + else if( !( error == KErrNotFound || error == KErrNotSupported ) ) + { + INFO_PRINTF2(_L("Expected return value KErrNotFound or KErrNotSupported, got %d)"), error); + User::Leave( KErrArgument ); + } + + error = iConversionHandler1->iStatus.Int(); + if( error == KErrNone ) + { + for( TInt i=0;i ( locationInfobase ); + CheckPositionConvertedInfoL( locationInfo ); + } + } + else if( !( error == KErrNotFound || error == KErrNotSupported ) ) + { + INFO_PRINTF2(_L("Expected return value KErrNotFound or KErrNotSupported, got %d)"), error); + User::Leave( KErrArgument ); + } + + + CleanupStack::Pop(4); // locationInfo1,locationInfoArray1,locationInfo,locationInfoArray + locationInfoArray.ResetAndDestroy(); + locationInfoArray1.ResetAndDestroy(); + CleanupStack::PopAndDestroy( 3 ); // locInfoConverter,locInfoConverter1,locMonitorSession + return KErrNone; + } + +// ----------------------------------------------------------------------------- +// CTe_LocMonitorStep5::RLbsLocInfoConverter_ConvertLocationInfo10L +// This test case tests following unsuccessful conversion scenarios: +// 1. Conversion preference not supported by plugin. +// 2. Conversion request by specifying input area type same as requested type. +// ----------------------------------------------------------------------------- +// +TInt CTe_LocMonitorStep5::RLbsLocInfoConverter_ConvertLocationInfo10L() + { + INFO_PRINTF1(_L("*** RLbsLocInfoConverter_ConvertLocationInfo10L()")); + RLbsLocMonitorSession locMonitorSession; + TInt error = locMonitorSession.Connect(); + if( error != KErrNone ) + { + return error; + } + CleanupClosePushL( locMonitorSession ); + + // Here we need two subsessions + RLbsLocInfoConverter locInfoConverter; + CleanupClosePushL( locInfoConverter ); + locInfoConverter.OpenL( locMonitorSession ); + + TUid conversionModuleId = TUid::Uid( KDummyPluginId ); + + CLbsLocationInfo* locationInfo = CreateLocationInfoObjectLC( ELbsAreaWcmdaCellInfoClass ); + + /** + * Case 2: Users tries to request for coordinate info by specifying + * only coordinate info. + */ + locationInfo->ResetAreaInfo(); + AppendAreaInfoObjectToLocationInfoL( locationInfo,ELbsAreaPositionInfoClass ); + locInfoConverter.ConvertLocationInfoL( + *locationInfo,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId,iConversionHandler->iStatus ); + iConversionHandler->Start(); + // This is just to block the control till the call back method is called. + // Code after this statement will be resumed when Stop on CActiveScheduler + // is called in the HandleLocationConversion method. + CActiveScheduler::Start(); + + // Check the converted values in both the conversions. + error = iConversionHandler->iStatus.Int(); + if( error != KErrNotSupported ) + { + INFO_PRINTF2(_L("Expected return value KErrNotSupported, got %d)"), error); + User::Leave( KErrArgument ); + } + + /** + * Case 3: Users tries to request for gsm cell info by specifying + * only gsm cell info. + */ + locationInfo->ResetAreaInfo(); + AppendAreaInfoObjectToLocationInfoL( locationInfo,ELbsAreaGsmCellInfoClass ); + locInfoConverter.ConvertLocationInfoL( + *locationInfo,ELbsConversionNotDefined, + ELbsConversionOutputGsm,conversionModuleId,iConversionHandler->iStatus ); + iConversionHandler->Start(); + // This is just to block the control till the call back method is called. + // Code after this statement will be resumed when Stop on CActiveScheduler + // is called in the HandleLocationConversion method. + CActiveScheduler::Start(); + + // Check the converted values in both the conversions. + error = iConversionHandler->iStatus.Int(); + if( error != KErrNotSupported ) + { + INFO_PRINTF2(_L("Expected return value KErrNotSupported, got %d)"), error); + User::Leave( KErrArgument ); + } + + /** + * Case 4: Users tries to request for wcdma cell info by specifying + * only wcdma cell info. + */ + locationInfo->ResetAreaInfo(); + AppendAreaInfoObjectToLocationInfoL( locationInfo,ELbsAreaWcmdaCellInfoClass ); + locInfoConverter.ConvertLocationInfoL( + *locationInfo,ELbsConversionNotDefined, + ELbsConversionOutputWcdma,conversionModuleId,iConversionHandler->iStatus ); + iConversionHandler->Start(); + // This is just to block the control till the call back method is called. + // Code after this statement will be resumed when Stop on CActiveScheduler + // is called in the HandleLocationConversion method. + CActiveScheduler::Start(); + + // Check the converted values in both the conversions. + error = iConversionHandler->iStatus.Int(); + if( error != KErrNotSupported ) + { + INFO_PRINTF2(_L("Expected return value KErrNotSupported, got %d)"), error); + User::Leave( KErrArgument ); + } + + /** + * Case 5: Users tries to request for wlan info by specifying + * only wlan info. + */ + locationInfo->ResetAreaInfo(); + AppendAreaInfoObjectToLocationInfoL( locationInfo,ELbsAreaWlanInfoClass ); + locInfoConverter.ConvertLocationInfoL( + *locationInfo,ELbsConversionNotDefined, + ELbsConversionOutputWlan,conversionModuleId,iConversionHandler->iStatus ); + iConversionHandler->Start(); + // This is just to block the control till the call back method is called. + // Code after this statement will be resumed when Stop on CActiveScheduler + // is called in the HandleLocationConversion method. + CActiveScheduler::Start(); + + // Check the converted values in both the conversions. + error = iConversionHandler->iStatus.Int(); + if( error != KErrNotSupported ) + { + INFO_PRINTF2(_L("Expected return value KErrNotSupported, got %d)"), error); + User::Leave( KErrArgument ); + } + + CleanupStack::PopAndDestroy( 3 ); // locationInfo,locInfoConverter,locMonitorSession + return KErrNone; + } + + + +// ----------------------------------------------------------------------------- +// CTe_LocMonitorStep5::RLbsLocInfoConverter_Cancel1L +// This test case tests the scenario when user tries to cancel the request before +// and after the conversion request complete for both single and batch conversion. +// ----------------------------------------------------------------------------- +// +TInt CTe_LocMonitorStep5::RLbsLocInfoConverter_Cancel1L() + { + INFO_PRINTF1(_L("*** RLbsLocInfoConverter_Cancel1L()")); + RLbsLocMonitorSession locMonitorSession; + TInt error = locMonitorSession.Connect(); + if( error != KErrNone ) + { + return error; + } + CleanupClosePushL( locMonitorSession ); + RLbsLocInfoConverter locInfoConverter; + CleanupClosePushL( locInfoConverter ); + locInfoConverter.OpenL( locMonitorSession ); + + RPointerArray locationInfoArray; + CleanupClosePushL( locationInfoArray ); + + TUid conversionModuleId = TUid::Uid( KDummyPluginId ); + + // This can can be done for any area type here EGsm to ECoordinate conversion has + // been used. + + /** + * Case 1: Here single location information conversion is requested + * and cancel is called before the conversion completes. + */ + CLbsLocationInfo* locationInfo = CreateLocationInfoObjectLC( ELbsAreaGsmCellInfoClass ); + + locInfoConverter.ConvertLocationInfoL( + *locationInfo,ELbsConversionNotDefined,ELbsConversionOutputPosition + ,conversionModuleId,iConversionHandler->iStatus ); + iConversionHandler->Start(); + locInfoConverter.CancelConvertLocationInfo(); + iConversionHandler->Cancel(); + + error = iConversionHandler->iStatus.Int(); + // Request should be completed with the error code KErrCancel and + // location info should not have converted information. + if( error == KErrCancel ) + { + CheckPositionConvertedInfoL( locationInfo,ENegative ); + } + else + { + INFO_PRINTF2(_L("Expected return value KErrCancel, got %d)"), error); + User::Leave( KErrArgument ); + } + + /** + * case 2: Here single location information conversion is requested + * and cancel is called after the conversion completes. + */ + locInfoConverter.ConvertLocationInfoL( + *locationInfo,ELbsConversionNotDefined,ELbsConversionOutputPosition + ,conversionModuleId,iConversionHandler->iStatus ); + iConversionHandler->Start(); + CActiveScheduler::Start(); + locInfoConverter.CancelConvertLocationInfo(); + iConversionHandler->Cancel(); + + error = iConversionHandler->iStatus.Int(); + // Request should be completed with the error code KErrNone and + // location info should have converted information. + if( error == KErrNone ) + { + CheckPositionConvertedInfoL( locationInfo ); + } + else + { + INFO_PRINTF2(_L("Expected return value KErrNone got %d)"), error); + User::Leave( KErrArgument ); + } + + // case 3: Here mutiple location information conversion is + // requested and cancel is called before the conversion completes. + + CLbsLocationInfo* locationInfo1 = CreateLocationInfoObjectLC( ELbsAreaGsmCellInfoClass ); + + // We had requested for coordinate info, hence we need to clear it before + // we use it as input for next conversion. + locationInfo->ResetAreaInfo( CLbsLocationInfo::ELbsPosInfo ); + locationInfoArray.Append( locationInfo ); + + locationInfoArray.Append( locationInfo1 ); + + locInfoConverter.ConvertLocationInfoL( + locationInfoArray,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId,iConversionHandler->iStatus ); + iConversionHandler->Start(); + locInfoConverter.CancelConvertLocationInfo(); + iConversionHandler->Cancel(); + + // Request should be completed with the error code KErrCancel and + // location info should not have converted information. + error = iConversionHandler->iStatus.Int(); + + if( error == KErrCancel ) + { + for( TInt i=0;i ( locationInfobase ); + CheckPositionConvertedInfoL( locationInfo,ENegative ); + } + } + else + { + INFO_PRINTF2(_L("Expected return value KErrCancel, got %d)"), error); + User::Leave( KErrArgument ); + } + + + /** + * case 4: Here mutiple location information conversion is + * requested and cancel is called after the conversion completes. + */ + + locInfoConverter.ConvertLocationInfoL( + locationInfoArray,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId,iConversionHandler->iStatus ); + iConversionHandler->Start(); + CActiveScheduler::Start(); + locInfoConverter.CancelConvertLocationInfo(); + iConversionHandler->Cancel(); + + // Request should be completed with the error code KErrNone and + // location info should have converted information. + error = iConversionHandler->iStatus.Int(); + + if( error == KErrNone ) + { + for( TInt i=0;i ( locationInfobase ); + CheckPositionConvertedInfoL( locationInfo ); + } + } + else + { + INFO_PRINTF2(_L("Expected return value KErrNone got %d)"), error); + User::Leave( KErrArgument ); + } + + CleanupStack::Pop( 3 ); // locationInfo,locationInfo1,locationInfoArray + locationInfoArray.ResetAndDestroy(); + CleanupStack::PopAndDestroy( 2 ); // locInfoConverter,locMonitorSession + return KErrNone; + } + + + +// ----------------------------------------------------------------------------- +// CTe_LocMonitorStep5::RLbsLocInfoConverter_Cancel2L +// This test case tests the scenario when user tries to cancel the conversion request +// from the different subsession for both single and multiple conversion. +// ----------------------------------------------------------------------------- +// +TInt CTe_LocMonitorStep5::RLbsLocInfoConverter_Cancel2L() + { + INFO_PRINTF1(_L("*** RLbsLocInfoConverter_Cancel2L()")); + RLbsLocMonitorSession locMonitorSession; + TInt error = locMonitorSession.Connect(); + if( error != KErrNone ) + { + return error; + } + CleanupClosePushL( locMonitorSession ); + + // Here we need to subsessions. + RLbsLocInfoConverter locInfoConverter,locInfoConverter1; + CleanupClosePushL( locInfoConverter ); + locInfoConverter.OpenL( locMonitorSession ); + + CleanupClosePushL( locInfoConverter1 ); + locInfoConverter1.OpenL( locMonitorSession ); + + + RPointerArray locationInfoArray; + CleanupClosePushL( locationInfoArray ); + + TUid conversionModuleId = TUid::Uid( KDummyPluginId ); + + // This can can be done for any area type here EGsm to ECoordinate conversion has + // been used. + + /** + * Case 1: Here single location information conversion is + * requested and cancel is called the different subsession. + */ + + CLbsLocationInfo* locationInfo = CreateLocationInfoObjectLC( ELbsAreaGsmCellInfoClass ); + + locInfoConverter.ConvertLocationInfoL( + *locationInfo,ELbsConversionNotDefined,ELbsConversionOutputPosition + ,conversionModuleId,iConversionHandler->iStatus ); + iConversionHandler->Start(); + locInfoConverter1.CancelConvertLocationInfo(); + CActiveScheduler::Start(); + + error = iConversionHandler->iStatus.Int(); + // Request should be completed with the error code KErrNone and + // location info should have converted information. + if( error == KErrNone ) + { + CheckPositionConvertedInfoL( locationInfo ); + } + else + { + INFO_PRINTF2(_L("Expected return value KErrNone, got %d)"), error); + User::Leave( KErrArgument ); + } + + /** + * Case 2: Here mutiple location information conversion is requested + * and cancel is called from the different subsession. + */ + CLbsLocationInfo* locationInfo1 = CreateLocationInfoObjectLC( ELbsAreaGsmCellInfoClass ); + + // We had requested for coordinate info, hence we need to clear it before + // we use it as input for next conversion. + locationInfo->ResetAreaInfo( CLbsLocationInfo::ELbsPosInfo ); + locationInfoArray.Append( locationInfo ); + + locationInfoArray.Append( locationInfo1 ); + + locInfoConverter.ConvertLocationInfoL( + locationInfoArray,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId,iConversionHandler->iStatus ); + iConversionHandler->Start(); + locInfoConverter1.CancelConvertLocationInfo(); + CActiveScheduler::Start(); + + // Request should be completed with the error code KErrNone and + // location info should have converted information. + error = iConversionHandler->iStatus.Int(); + + if( error == KErrNone ) + { + for( TInt i=0;i ( locationInfobase ); + CheckPositionConvertedInfoL( locationInfo ); + } + } + else + { + INFO_PRINTF2(_L("Expected return value KErrNone, got %d)"), error); + User::Leave( KErrArgument ); + } + CleanupStack::Pop( 3 ); // locationInfo,locationInfo1,locationInfoArray + locationInfoArray.ResetAndDestroy(); + CleanupStack::PopAndDestroy( 3 ); // locInfoConverter,locInfoConverter1,locMonitorSession + return KErrNone; + } + +// ----------------------------------------------------------------------------- +// CTe_LocMonitorStep5::RLbsLocInfoConverter_Cancel3L +// This test case tests the scenario when user tries to request two conversion +// using two subsessions simultaneously specifying same plugin and we cancel one request +// of two requests. +// ----------------------------------------------------------------------------- +// +TInt CTe_LocMonitorStep5::RLbsLocInfoConverter_Cancel3L() + { + INFO_PRINTF1(_L("*** RLbsLocInfoConverter_Cancel3L()")); + RLbsLocMonitorSession locMonitorSession; + TInt error = locMonitorSession.Connect(); + if( error != KErrNone ) + { + return error; + } + CleanupClosePushL( locMonitorSession ); + + // Here we need to open two subsessions. + RLbsLocInfoConverter locInfoConverter,locInfoConverter1; + CleanupClosePushL( locInfoConverter ); + locInfoConverter.OpenL( locMonitorSession ); + + CleanupClosePushL( locInfoConverter1 ); + locInfoConverter1.OpenL( locMonitorSession ); + + RPointerArray locationInfoArray; + CleanupClosePushL( locationInfoArray ); + + RPointerArray locationInfoArray1; + CleanupClosePushL( locationInfoArray1 ); + + TUid conversionModuleId = TUid::Uid( KDummyPluginId ); + + /** + * Case 1: Users tries to request 2 simultaneous single conversion + * using 2 subsession specifying same conversion uid and + * anyone conversion request is cancelled. + */ + + // Here type of area input doesnt matter. + CLbsLocationInfo* locationInfo = CreateLocationInfoObjectLC( ELbsAreaGsmCellInfoClass ); + + CLbsLocationInfo* locationInfo1 = CreateLocationInfoObjectLC( ELbsAreaGsmCellInfoClass ); + + locInfoConverter.ConvertLocationInfoL( + *locationInfo,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId,iConversionHandler->iStatus ); + iConversionHandler->Start(); + + locInfoConverter1.ConvertLocationInfoL( + *locationInfo1,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId,iConversionHandler1->iStatus ); + iConversionHandler1->Start(); + + // Here first request is called. + locInfoConverter.CancelConvertLocationInfo(); + + // This is just to block the control till the call back method is called. + // Code after this statement will be resumed when Stop on CActiveScheduler + // is called in the HandleLocationConversion method. + CActiveScheduler::Start(); + + // Here we need to wait till both the request completes.Hence we need to block it once again + // till the 2nd request completes. + if( iConversionHandler->iStatus.Int() == KRequestPending || + iConversionHandler1->iStatus.Int() == KRequestPending ) + { + CActiveScheduler::Start(); + } + + // Check the converted values in both the conversions. + error = iConversionHandler->iStatus.Int(); + if( error == KErrCancel ) + { + CheckPositionConvertedInfoL( locationInfo,ENegative ); + } + else + { + INFO_PRINTF2(_L("Expected return value KErrCancel, got %d)"), error); + User::Leave( KErrArgument ); + } + + error = iConversionHandler1->iStatus.Int(); + if( error == KErrNone ) + { + CheckPositionConvertedInfoL( locationInfo1 ); + } + else + { + INFO_PRINTF2(_L("Expected return value KErrNone, got %d)"), error); + User::Leave( KErrArgument ); + } + + /** + * Case 2: Users tries to request 2 simultaneous bulk conversion + * using 2 subsession specifying same conversion uid and + * any one conversion request is cancelled. + */ + + // Before we append the location info object to the info array, + // we need to clear the converted info in each object. + locationInfo->ResetAreaInfo( CLbsLocationInfo::ELbsPosInfo ); + locationInfo1->ResetAreaInfo( CLbsLocationInfo::ELbsPosInfo ); + + locationInfoArray.Append( locationInfo ); + locationInfoArray1.Append( locationInfo1 ); + + locInfoConverter.ConvertLocationInfoL( + locationInfoArray,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId,iConversionHandler->iStatus ); + iConversionHandler->Start(); + + locInfoConverter1.ConvertLocationInfoL( + locationInfoArray1,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId,iConversionHandler1->iStatus ); + iConversionHandler1->Start(); + + // Here second request is called. + locInfoConverter1.CancelConvertLocationInfo(); + + // This is just to block the control till the call back method is called. + // Code after this statement will be resumed when Stop on CActiveScheduler + // is called in the HandleLocationConversion method. + CActiveScheduler::Start(); + + // Here we need to wait till both the request completes.Hence we need to block it once again + // till the 2nd request completes. + if( iConversionHandler->iStatus.Int() == KRequestPending || + iConversionHandler1->iStatus.Int() == KRequestPending ) + { + CActiveScheduler::Start(); + } + + // Check the converted values in both the conversions. + // Iterate through the array and check for converted info. + error = iConversionHandler->iStatus.Int(); + if( error == KErrNone ) + { + for( TInt i=0;i ( locationInfobase ); + CheckPositionConvertedInfoL( locationInfo ); + } + } + else + { + INFO_PRINTF2(_L("Expected return value KErrNone, got %d)"), error); + User::Leave( KErrArgument ); + } + + error = iConversionHandler1->iStatus.Int(); + if( error == KErrCancel ) + { + for( TInt i=0;i ( locationInfobase ); + CheckPositionConvertedInfoL( locationInfo,ENegative ); + } + } + else + { + INFO_PRINTF2(_L("Expected return value KErrCancel, got %d)"), error); + User::Leave( KErrArgument ); + } + + CleanupStack::Pop(4); // locationInfo1,locationInfoArray1,locationInfo,locationInfoArray + locationInfoArray.ResetAndDestroy(); + locationInfoArray1.ResetAndDestroy(); + CleanupStack::PopAndDestroy( 3 ); // locInfoConverter,locInfoConverter1,locMonitorSession + return KErrNone; + } + +// ----------------------------------------------------------------------------- +// CTe_LocMonitorStep5::RLbsLocInfoConverter_Cancel4L +// This test case tests the scenario when user tries to request two conversion +// using two subsessions simultaneously specifying different plugin. +// ----------------------------------------------------------------------------- +// +TInt CTe_LocMonitorStep5::RLbsLocInfoConverter_Cancel4L() + { + INFO_PRINTF1(_L("*** RLbsLocInfoConverter_Cancel4L()")); + RLbsLocMonitorSession locMonitorSession; + TInt error = locMonitorSession.Connect(); + if( error != KErrNone ) + { + return error; + } + CleanupClosePushL( locMonitorSession ); + + // Here we need two subsessions + RLbsLocInfoConverter locInfoConverter,locInfoConverter1; + CleanupClosePushL( locInfoConverter ); + locInfoConverter.OpenL( locMonitorSession ); + + CleanupClosePushL( locInfoConverter1 ); + locInfoConverter1.OpenL( locMonitorSession ); + + RPointerArray locationInfoArray; + CleanupClosePushL( locationInfoArray ); + + RPointerArray locationInfoArray1; + CleanupClosePushL( locationInfoArray1 ); + + TUid conversionModuleId1 = TUid::Uid( KDummyPluginId ); + TUid conversionModuleId2 = TUid::Uid( KSuplPluginId ); + + /** + * Case 1: Users tries to request 2 simultaneous single conversion + * using 2 subsession specifying different conversion uid + * any one request is cancelled. + */ + + CLbsLocationInfo* locationInfo = CreateLocationInfoObjectLC( ELbsAreaWcmdaCellInfoClass ); + + CLbsLocationInfo* locationInfo1 = CreateLocationInfoObjectLC( ELbsAreaWlanInfoClass ); + + locInfoConverter.ConvertLocationInfoL( + *locationInfo,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId1,iConversionHandler->iStatus ); + iConversionHandler->Start(); + + + locInfoConverter1.ConvertLocationInfoL( + *locationInfo1,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId2,iConversionHandler1->iStatus ); + iConversionHandler1->Start(); + + // Here first request is cancelled. + locInfoConverter.CancelConvertLocationInfo(); + + // This is just to block the control till the call back method is called. + // Code after this statement will be resumed when Stop on CActiveScheduler + // is called in the HandleLocationConversion method. + CActiveScheduler::Start(); + + // Here we need to wait till both the request completes.Hence we need to block it once again + // till the 2nd request completes. + if( iConversionHandler->iStatus.Int() == KRequestPending || + iConversionHandler1->iStatus.Int() == KRequestPending ) + { + CActiveScheduler::Start(); + } + + // Check the converted values in both the conversions. + error = iConversionHandler->iStatus.Int(); + if( error == KErrCancel ) + { + CheckPositionConvertedInfoL( locationInfo,ENegative ); + } + else if( !( error == KErrNotFound || error == KErrNotSupported ) ) + { + INFO_PRINTF2(_L("Expected return value KErrCancel, KErrNotFound, KErrNotSupported, got %d)"), error); + User::Leave( KErrArgument ); + } + + error = iConversionHandler1->iStatus.Int(); + if( error == KErrNone ) + { + CheckPositionConvertedInfoL( locationInfo1 ); + } + else if( !( error == KErrNotFound || error == KErrNotSupported ) ) + { + INFO_PRINTF2(_L("Expected return value KErrNone, KErrNotFound, KErrNotSupported, got %d)"), error); + User::Leave( KErrArgument ); + } + + /** + * Case 2: Users tries to request 2 simultaneous bulk conversion + * using 2 subsession specifying same conversion uid and + * one conversion request is cancelled. + */ + + // Before we append the location info object to the info array, + // we need to clear the converted info in each object. + locationInfo->ResetAreaInfo( CLbsLocationInfo::ELbsPosInfo ); + locationInfo1->ResetAreaInfo( CLbsLocationInfo::ELbsPosInfo ); + + locationInfoArray.Append( locationInfo ); + locationInfoArray1.Append( locationInfo1 ); + + locInfoConverter.ConvertLocationInfoL( + locationInfoArray,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId1,iConversionHandler->iStatus ); + iConversionHandler->Start(); + + locInfoConverter1.ConvertLocationInfoL( + locationInfoArray1,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId2,iConversionHandler1->iStatus ); + iConversionHandler1->Start(); + + // Here we cancel 2nd request + locInfoConverter1.CancelConvertLocationInfo(); + + // This is just to block the control till the call back method is called. + // Code after this statement will be resumed when Stop on CActiveScheduler + // is called in the HandleLocationConversion method. + CActiveScheduler::Start(); + + // Here we need to wait till both the request completes.Hence we need to block it once again + // till the 2nd request completes. + if( iConversionHandler->iStatus.Int() == KRequestPending || + iConversionHandler1->iStatus.Int() == KRequestPending ) + { + CActiveScheduler::Start(); + } + + // Check the converted values in both the conversions. + // Iterate through the array and check for converted info. + error = iConversionHandler->iStatus.Int(); + if( error == KErrNone ) + { + for( TInt i=0;i ( locationInfobase ); + CheckPositionConvertedInfoL( locationInfo ); + } + } + else if( !( error == KErrNotFound || error == KErrNotSupported ) ) + { + INFO_PRINTF2(_L("Expected return value KErrNone, KErrNotFound, KErrNotSupported, got %d)"), error); + User::Leave( KErrArgument ); + } + + error = iConversionHandler1->iStatus.Int(); + if( error == KErrCancel ) + { + for( TInt i=0;i ( locationInfobase ); + CheckPositionConvertedInfoL( locationInfo,ENegative ); + } + } + else if( !( error == KErrNotFound || error == KErrNotSupported ) ) + { + INFO_PRINTF2(_L("Expected return value KErrCancel, KErrNotFound, KErrNotSupported, got %d)"), error); + User::Leave( KErrArgument ); + } + + + CleanupStack::Pop(4); // locationInfo1,locationInfoArray1,locationInfo,locationInfoArray + locationInfoArray.ResetAndDestroy(); + locationInfoArray1.ResetAndDestroy(); + CleanupStack::PopAndDestroy( 3 ); // locInfoConverter,locInfoConverter1,locMonitorSession + return KErrNone; + } + + + +// [End of File] diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/te_geolocmonitorsuite/src/te_geolocmonitorstep6.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/te_geolocmonitorsuite/src/te_geolocmonitorstep6.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,121 @@ +/* +* Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ + + +/** + @file te_locmonitorStep6.cpp +*/ + +#include "te_geolocmonitorStep6.h" +#include "te_geolocmonitorsuitedefs.h" +#include "rlbslocinfoconverter.h" +#include "LocInfoConversionHandler.h" +#include + +// Plug in +const TInt KDummyPluginId = 537007117; +const TInt KSuplPluginId = 537028467; + + +CTe_LocMonitorStep6::~CTe_LocMonitorStep6() + { + } + +CTe_LocMonitorStep6::CTe_LocMonitorStep6() + { + SetTestStepName(KLocMonitorStep6); + } + +TVerdict CTe_LocMonitorStep6::doTestStepPreambleL() + { + CTe_LocMonitorStepBase::doTestStepPreambleL(); + + iConversionHandler = CLocInfoConversionHandler::NewL(); + iConversionHandler1 = CLocInfoConversionHandler::NewL(); + + return TestStepResult(); + } + +// +// This test checks that it is possible to connect a session and +// subsession with the Location Monitor and then close both. +// +TVerdict CTe_LocMonitorStep6::doTestStepL() + { + if (TestStepResult()==EPass) + { + // Test 6 panics with 0, ELocMonitorDuplicateRequest + RLbsLocInfoConverter_ConvertLocationInfo6L(); + } + + return TestStepResult(); + } + +TVerdict CTe_LocMonitorStep6::doTestStepPostambleL() + { + delete iConversionHandler; + delete iConversionHandler1; + CTe_LocMonitorStepBase::doTestStepPostambleL(); + return TestStepResult(); + } + +// ----------------------------------------------------------------------------- +// CTe_LocMonitorStep6::RLbsLocInfoConverter_ConvertLocationInfo6L +// This test case tests the scenario when user tries to request new single +// conversion without waiting for completion of previous one. +// ----------------------------------------------------------------------------- +// +TInt CTe_LocMonitorStep6::RLbsLocInfoConverter_ConvertLocationInfo6L() + { + INFO_PRINTF1(_L("*** RLbsLocInfoConverter_ConvertLocationInfo6L()")); + RLbsLocMonitorSession locMonitorSession; + TInt error = locMonitorSession.Connect(); + if( error != KErrNone ) + { + return error; + } + CleanupClosePushL( locMonitorSession ); + RLbsLocInfoConverter locInfoConverter; + CleanupClosePushL( locInfoConverter ); + locInfoConverter.OpenL( locMonitorSession ); + + TUid conversionModuleId = TUid::Uid( KDummyPluginId ); + + CLbsLocationInfo* locationInfo = CreateLocationInfoObjectLC( ELbsAreaGsmCellInfoClass ); + + // Here in this case input area doesnt matter + locInfoConverter.ConvertLocationInfoL( + *locationInfo,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId,iConversionHandler->iStatus ); + iConversionHandler->Start(); + + CLbsLocationInfo* locationInfo1 = CreateLocationInfoObjectLC( ELbsAreaWcmdaCellInfoClass ); + + error = KErrNone; + TRequestStatus status; + + + locInfoConverter.ConvertLocationInfoL( + *locationInfo1,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId,status ); + + CleanupStack::PopAndDestroy( 2 ); // locationInfo1,locationInfo + return KErrNone; + } + + +// [End of File] diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/te_geolocmonitorsuite/src/te_geolocmonitorstep7.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/te_geolocmonitorsuite/src/te_geolocmonitorstep7.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,140 @@ +/* +* Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ + + +/** + @file te_locmonitorStep7.cpp +*/ + +#include "te_geolocmonitorStep7.h" +#include "te_geolocmonitorsuitedefs.h" +#include "rlbslocinfoconverter.h" +#include "LocInfoConversionHandler.h" +#include + +// Plug in +const TInt KDummyPluginId = 537007117; +const TInt KSuplPluginId = 537028467; + + +CTe_LocMonitorStep7::~CTe_LocMonitorStep7() + { + } + +CTe_LocMonitorStep7::CTe_LocMonitorStep7() + { + SetTestStepName(KLocMonitorStep7); + } + +TVerdict CTe_LocMonitorStep7::doTestStepPreambleL() + { + CTe_LocMonitorStepBase::doTestStepPreambleL(); + + iConversionHandler = CLocInfoConversionHandler::NewL(); + iConversionHandler1 = CLocInfoConversionHandler::NewL(); + + return TestStepResult(); + } + +// +// This test checks that it is possible to connect a session and +// subsession with the Location Monitor and then close both. +// +TVerdict CTe_LocMonitorStep7::doTestStepL() + { + if (TestStepResult()==EPass) + { + // Test 7 panics with 0, ELocMonitorDuplicateRequest + RLbsLocInfoConverter_ConvertLocationInfo7L(); + } + + return TestStepResult(); + } + +TVerdict CTe_LocMonitorStep7::doTestStepPostambleL() + { + delete iConversionHandler; + delete iConversionHandler1; + CTe_LocMonitorStepBase::doTestStepPostambleL(); + return TestStepResult(); + } + + + + +// ----------------------------------------------------------------------------- +// CTe_LocMonitorStep7::RLbsLocInfoConverter_ConvertLocationInfo7L +// This test case tests the scenario when user tries to request new batch +// conversion without waiting for completion of previous one. +// ----------------------------------------------------------------------------- +// +TInt CTe_LocMonitorStep7::RLbsLocInfoConverter_ConvertLocationInfo7L() + { + INFO_PRINTF1(_L("*** RLbsLocInfoConverter_ConvertLocationInfo7L()")); + RLbsLocMonitorSession locMonitorSession; + TInt error = locMonitorSession.Connect(); + if( error != KErrNone ) + { + return error; + } + CleanupClosePushL( locMonitorSession ); + RLbsLocInfoConverter locInfoConverter; + CleanupClosePushL( locInfoConverter ); + locInfoConverter.OpenL( locMonitorSession ); + + TUid conversionModuleId = TUid::Uid( KNullUidValue );; + + // Here in this case input area doesnt matter + RPointerArray locationInfoArray; + CleanupClosePushL( locationInfoArray ); + + RPointerArray locationInfoArray1; + CleanupClosePushL( locationInfoArray1 ); + + CLbsLocationInfo* locationInfo = CreateLocationInfoObjectLC( ELbsAreaGsmCellInfoClass ); + + CLbsLocationInfo* locationInfo1 = CreateLocationInfoObjectLC( ELbsAreaWlanInfoClass ); + + locationInfoArray.Append( locationInfo ); + + locInfoConverter.ConvertLocationInfoL( + locationInfoArray,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId ,iConversionHandler->iStatus ); + iConversionHandler->Start(); + + locationInfoArray1.Append( locationInfo1 ); + + TRequestStatus status; + + #pragma message("GEOTAGGING TEST ISSUE: How to replicate next lines behaviour: TestModuleIf().SetExitReason(CTestModuleIf::EPanic, 0)") + // TestModuleIf().SetExitReason( CTestModuleIf::EPanic, 0); + + locInfoConverter.ConvertLocationInfoL( + locationInfoArray1,ELbsConversionNotDefined, + ELbsConversionOutputPosition,conversionModuleId,status ); + + CleanupStack::Pop(4); // locationInfo1,locationInfoArray1,locationInfo,locationInfoArray + locationInfoArray.ResetAndDestroy(); + locationInfoArray1.ResetAndDestroy(); + CleanupStack::PopAndDestroy( 2 ); // locInfoConverter,locMonitorSession + return KErrNone; + } + + + + +// [End of File] diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/te_geolocmonitorsuite/src/te_geolocmonitorstepbase.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/te_geolocmonitorsuite/src/te_geolocmonitorstepbase.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,339 @@ +/* +* Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ + + +/** + @file te_geolocmonitorstepbase.cpp +*/ +#include "te_geolocmonitorstepbase.h" +#include "te_geolocmonitorsuitedefs.h" +#include "tserverstartparams.h" +#include "cserverlaunch.h" +#include "lbslocmonitorserverdata.h" +#include "lbsdevloggermacros.h" + +void CleanUpAreaInfoArray(TAny* aArray) + { + static_cast(aArray)->ResetAndDestroy(); + } + +TVerdict CTe_LocMonitorStepBase::doTestStepPreambleL() + { + LBSLOG(ELogP1, "CTe_LocMonitorStepBase::doTestStepPreambleL()\n"); + // START MEMORY TEST + __UHEAP_MARK; + + // Construct a new ActiveScheduler and install it + iActiveScheduler = new (ELeave) CActiveScheduler(); + CActiveScheduler::Install(iActiveScheduler); + + SetTestStepResult(EPass); + return TestStepResult(); + } + +TVerdict CTe_LocMonitorStepBase::doTestStepPostambleL() + { + LBSLOG(ELogP1, "CTe_LocMonitorStepBase::doTestStepPostambleL()\n"); + + delete iActiveScheduler; + + // END MEMORY TEST + __UHEAP_MARKEND; + + return TestStepResult(); + } + +CTe_LocMonitorStepBase::~CTe_LocMonitorStepBase() + { + LBSLOG(ELogP1, "CTe_LocMonitorStepBase::~CTe_LocMonitorStepBase()\n"); + } + +CTe_LocMonitorStepBase::CTe_LocMonitorStepBase() + { + LBSLOG(ELogP1, "CTe_LocMonitorStepBase::CTe_LocMonitorStepBase()\n"); + } + + +// Helper methods + +// ----------------------------------------------------------------------------- +// CTe_LocMonitorStepBase::CreatePositionObjectLC +// ----------------------------------------------------------------------------- +// +CLbsPositionInfo* CTe_LocMonitorStepBase::CreatePositionInfoObjectLC() + { + INFO_PRINTF1(_L("CreatePositionInfoObjectLC()")); + TLocality locality; + locality.SetCoordinate( 62.5285,23.9385 ); + locality.SetAccuracy( 100,0.0 ); + CLbsPositionInfo* positionInfo = CLbsPositionInfo::NewL( locality ); + CleanupStack::PushL( positionInfo ); + return positionInfo; + } + +// ----------------------------------------------------------------------------- +// CTe_LocMonitorStepBase::CreateGsmCellInfoObjectLC +// ----------------------------------------------------------------------------- +// +CLbsGsmCellInfo* CTe_LocMonitorStepBase::CreateGsmCellInfoObjectLC() + { + INFO_PRINTF1(_L("CreateGsmCellInfoObjectLC()")); + CLbsGsmCellInfo* gsmCellInfo = CLbsGsmCellInfo::NewL( 100,101,102,103); + CleanupStack::PushL( gsmCellInfo ); + return gsmCellInfo; + } + +// ----------------------------------------------------------------------------- +// CTe_LocMonitorStepBase::CreateWcdmaCellInfoObjectLC +// ----------------------------------------------------------------------------- +// +CLbsWcdmaCellInfo* CTe_LocMonitorStepBase::CreateWcdmaCellInfoObjectLC() + { + INFO_PRINTF1(_L("CreateWcdmaCellInfoObjectLC()")); + CLbsWcdmaCellInfo* wcdmaCellInfo = CLbsWcdmaCellInfo::NewL( 100,101,102 ); + CleanupStack::PushL( wcdmaCellInfo ); + return wcdmaCellInfo; + } + +// ----------------------------------------------------------------------------- +// CTe_LocMonitorStepBase::CreateWlanInfoObjectLC +// ----------------------------------------------------------------------------- +// +CLbsWlanInfo* CTe_LocMonitorStepBase::CreateWlanInfoObjectLC() + { + INFO_PRINTF1(_L("CreateWlanInfoObjectLC()")); + TLbsWlanMacAddress macAddress(_L8("10.0.1")); + CLbsWlanInfo* wlanInfo = CLbsWlanInfo::NewL( macAddress,10.1 ); + CleanupStack::PushL( wlanInfo ); + return wlanInfo; + } + + +// ----------------------------------------------------------------------------- +// CTe_LocMonitorStepBase::CreateLocationInfoObjectLC +// ----------------------------------------------------------------------------- +// +CLbsLocationInfo* CTe_LocMonitorStepBase::CreateLocationInfoObjectLC( + TLbsAreaInfoClassType aAreaType ) + { + INFO_PRINTF1(_L("CreateLocationInfoObjectLC()")); + CLbsLocationInfo* locationInfo = CLbsLocationInfo::NewL(); + CleanupStack::PushL( locationInfo ); + AppendAreaInfoObjectToLocationInfoL( locationInfo,aAreaType ); + return locationInfo; + } + +// ----------------------------------------------------------------------------- +// CTe_LocMonitorStepBase::AppendAreaInfoObjectToLocationInfoL +// ----------------------------------------------------------------------------- +// +void CTe_LocMonitorStepBase::AppendAreaInfoObjectToLocationInfoL( + CLbsLocationInfo* aLocationInfo, + TLbsAreaInfoClassType aAreaType ) + { + INFO_PRINTF1(_L("AppendAreaInfoObjectToLocationInfoL()")); + + CLbsPositionInfo* positionInfo = NULL; + CLbsGsmCellInfo* gsmCellInfo = NULL; + CLbsWcdmaCellInfo* wcdmaCellInfo = NULL; + CLbsWlanInfo* wlanInfo = NULL; + + switch( aAreaType ) + { + case ELbsAreaPositionInfoClass: + positionInfo = CreatePositionInfoObjectLC(); + aLocationInfo->AddAreaInfoL( positionInfo ); + CleanupStack::Pop( positionInfo ); + break; + + case ELbsAreaGsmCellInfoClass: + gsmCellInfo = CreateGsmCellInfoObjectLC(); + aLocationInfo->AddAreaInfoL( gsmCellInfo ); + CleanupStack::Pop( gsmCellInfo ); + break; + + case ELbsAreaWcmdaCellInfoClass: + wcdmaCellInfo = CreateWcdmaCellInfoObjectLC(); + aLocationInfo->AddAreaInfoL( wcdmaCellInfo ); + CleanupStack::Pop( wcdmaCellInfo ); + break; + + case ELbsAreaWlanInfoClass: + wlanInfo = CreateWlanInfoObjectLC(); + aLocationInfo->AddAreaInfoL( wlanInfo ); + CleanupStack::Pop( wlanInfo ); + break; + + default: + break; + } + } + +// ----------------------------------------------------------------------------- +// CTe_LocMonitorStepBase::CheckPositionConvertedInfoL +// ----------------------------------------------------------------------------- +// +void CTe_LocMonitorStepBase::CheckPositionConvertedInfoL( CLbsLocationInfo* + aLocationInfo, + TTestType + aTestType ) + { + INFO_PRINTF1(_L("CheckPositionConvertedInfoL()")); + RLbsAreaInfoBaseArray areaInfoArray; + aLocationInfo->GetAreaInfoL( areaInfoArray,CLbsLocationInfo::ELbsPosInfo ); + TInt count = areaInfoArray.Count(); + areaInfoArray.ResetAndDestroy(); + + if( aTestType == EPositive ) + { + if( !count ) + { + INFO_PRINTF2(_L("Expected areaInfoArray.Count() to return a value, got %d)"), count); + User::Leave( KErrArgument ); + } + } + else + { + if( count ) + { + INFO_PRINTF2(_L("Expected areaInfoArray.Count() NOT to return a value, got %d)"), count); + User::Leave( KErrArgument ); + } + } + // and to check out proper ownership of the + // heap items do it again! + + aLocationInfo->GetAreaInfoL( areaInfoArray,CLbsLocationInfo::ELbsPosInfo ); + count = areaInfoArray.Count(); + areaInfoArray.ResetAndDestroy(); + + if( aTestType == EPositive ) + { + if( !count ) + { + INFO_PRINTF2(_L("Expected areaInfoArray.Count() to return a value, got %d)"), count); + User::Leave( KErrArgument ); + } + } + else + { + if( count ) + { + INFO_PRINTF2(_L("Expected areaInfoArray.Count() NOT to return a value, got %d)"), count); + User::Leave( KErrArgument ); + } + } + } + + +// ----------------------------------------------------------------------------- +// CTe_LocMonitorStepBase::CheckGsmCellConvertedInfoL +// ----------------------------------------------------------------------------- +// +void CTe_LocMonitorStepBase::CheckGsmCellConvertedInfoL( CLbsLocationInfo* + aLocationInfo, + TTestType + aTestType ) + { + INFO_PRINTF1(_L("CheckGsmCellConvertedInfoL()")); + RLbsAreaInfoBaseArray areaInfoArray; + aLocationInfo->GetAreaInfoL( areaInfoArray,CLbsLocationInfo::ELbsGsmInfo ); + TInt count = areaInfoArray.Count(); + areaInfoArray.ResetAndDestroy(); + if( aTestType == EPositive ) + { + if( !count ) + { + INFO_PRINTF2(_L("Expected areaInfoArray.Count() to return a value, got %d)"), count); + User::Leave( KErrArgument ); + } + } + else + { + if( count ) + { + INFO_PRINTF2(_L("Expected areaInfoArray.Count() NOT to return a value, got %d)"), count); + User::Leave( KErrArgument ); + } + } + } + +// ----------------------------------------------------------------------------- +// CTe_LocMonitorStepBase::CheckWcdmaCellConvertedInfoL +// ----------------------------------------------------------------------------- +// +void CTe_LocMonitorStepBase::CheckWcdmaCellConvertedInfoL( CLbsLocationInfo* + aLocationInfo, + TTestType + aTestType ) + { + INFO_PRINTF1(_L("CheckWcdmaCellConvertedInfoL()")); + RLbsAreaInfoBaseArray areaInfoArray; + aLocationInfo->GetAreaInfoL( areaInfoArray,CLbsLocationInfo::ELbsWcdmaInfo ); + TInt count = areaInfoArray.Count(); + areaInfoArray.ResetAndDestroy(); + if( aTestType == EPositive ) + { + if( !count ) + { + INFO_PRINTF2(_L("Expected areaInfoArray.Count() to return a value, got %d)"), count); + User::Leave( KErrArgument ); + } + } + else + { + if( count ) + { + INFO_PRINTF2(_L("Expected areaInfoArray.Count() NOT to return a value, got %d)"), count); + User::Leave( KErrArgument ); + } + } + } + +// ----------------------------------------------------------------------------- +// CTe_LocMonitorStepBase::CheckWlanConvertedInfoL +// ----------------------------------------------------------------------------- +// +void CTe_LocMonitorStepBase::CheckWlanConvertedInfoL( CLbsLocationInfo* + aLocationInfo, + TTestType + aTestType ) + { + INFO_PRINTF1(_L("CheckWlanConvertedInfoL()")); + RLbsAreaInfoBaseArray areaInfoArray; + aLocationInfo->GetAreaInfoL( areaInfoArray,CLbsLocationInfo::ELbsWlanInfo ); + TInt count = areaInfoArray.Count(); + areaInfoArray.ResetAndDestroy(); + if( aTestType == EPositive ) + { + if( !count ) + { + INFO_PRINTF2(_L("Expected areaInfoArray.Count() to return a value, got %d)"), count); + User::Leave( KErrArgument ); + } + } + else + { + if( count ) + { + INFO_PRINTF2(_L("Expected areaInfoArray.Count() NOT to return a value, got %d)"), count); + User::Leave( KErrArgument ); + } + } + } + + diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/te_geolocmonitorsuite/src/te_geolocmonitorsuiteserver.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/te_geolocmonitorsuite/src/te_geolocmonitorsuiteserver.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,121 @@ +/* +* Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ + +#include "lbsdevloggermacros.h" + +#include "te_geolocmonitorsuiteserver.h" +#include "te_geolocmonitorstep1.h" +#include "te_geolocmonitorstep2.h" +#include "te_geolocmonitorstep3.h" +#include "te_geolocmonitorstep4.h" +#include "te_geolocmonitorstep5.h" +#include "te_geolocmonitorstep6.h" +#include "te_geolocmonitorstep7.h" + + +_LIT(KServerName,"te_geolocmonitorsuite"); + +CTe_GeoLocMonitorSuite* CTe_GeoLocMonitorSuite::NewL() + { + CTe_GeoLocMonitorSuite * server = new (ELeave) CTe_GeoLocMonitorSuite(); + CleanupStack::PushL(server); + + server->ConstructL(KServerName); + CleanupStack::Pop(server); + return server; + } + +void CTe_GeoLocMonitorSuite::ConstructL(const TDesC& aName) + { + CTestServer::ConstructL(aName); + } + +CTe_GeoLocMonitorSuite::~CTe_GeoLocMonitorSuite() + { + } + +LOCAL_C void MainL() + { + // Leave the hooks in for platform security +#if (defined __DATA_CAGING__) + RProcess().DataCaging(RProcess::EDataCagingOn); + RProcess().DataCaging(RProcess::ESecureApiOn); +#endif + CActiveScheduler* sched=NULL; + sched=new(ELeave) CActiveScheduler; + CActiveScheduler::Install(sched); + CTe_GeoLocMonitorSuite* server = NULL; + // Create the CTestServer derived server + TRAPD(err,server = CTe_GeoLocMonitorSuite::NewL()); + if(!err) + { + // Sync with the client and enter the active scheduler + RProcess::Rendezvous(KErrNone); + sched->Start(); + } + delete server; + delete sched; + } + + +GLDEF_C TInt E32Main() +/** + * @return - Standard Epoc error code on process exit + * Secure variant only + * Process entry point. Called by client using RProcess API + */ + { + LBSLOG_BEGIN(); + LBSLOG(ELogP3, "te_geolocmonitorsuite Start()\n"); + __UHEAP_MARK; + CTrapCleanup* cleanup = CTrapCleanup::New(); + if(cleanup == NULL) + { + return KErrNoMemory; + } + TRAPD(err,MainL()); + delete cleanup; + __UHEAP_MARKEND; + return err; + } + +CTestStep* CTe_GeoLocMonitorSuite::CreateTestStep(const TDesC& aStepName) +/** + * @return - A CTestStep derived instance + * Secure and non-secure variants + * Implementation of CTestServer pure virtual + */ + { + CTestStep* testStep = NULL; + if(aStepName == KLocMonitorStep1) + testStep = new CTe_LocMonitorStep1(); + else if(aStepName == KLocMonitorStep2) + testStep = new CTe_LocMonitorStep2(); + else if(aStepName == KLocMonitorStep3) + testStep = new CTe_LocMonitorStep3(); + else if(aStepName == KLocMonitorStep4) + testStep = new CTe_LocMonitorStep4(); + else if(aStepName == KLocMonitorStep5) + testStep = new CTe_LocMonitorStep5(); + else if(aStepName == KLocMonitorStep6) + testStep = new CTe_LocMonitorStep6(); + else if(aStepName == KLocMonitorStep7) + testStep = new CTe_LocMonitorStep7(); + + + return testStep; + } diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/te_geolocmonitorsuite/testdata/lbsgeolocmonunitconfig.txt --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/te_geolocmonitorsuite/testdata/lbsgeolocmonunitconfig.txt Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,51 @@ +// lbslocmonunitconfig.txt +// +// Copyright (c) 2009 Symbian Software Ltd. All rights reserved. +// +// sim.tsy config used for simulating only the network registration +// status +// +//! This config is used for all last known pos area tests that require only one cellid +// Original file name: lbsgeolocmonunitconfig.txt + +[TEST0] +#single +# PhoneId = ,,, , +PhoneId = Generic, 123, 1.1, 1234567890 + +#single +#SubscriberId = , +SubscriberId = 56789012345678 + +# multiple +# Current Network Name +# NetworkInfo= , , , , , " +NetworkInfo = 0, 0, Unknown, UnKn, Unknown_Network, 0 +NetworkInfo = 234, 15, Vodafone, Voda, Vodafone_UK, 0 + +# multiple +# is one of above +# RegStatus = , , +RegStatus = 5000, 5, 0 +RegStatus = 5000, 5, 1 + +# LocationArea = , , . Where is -1 for true and 0 for false?! +LocationArea = 0, 0, 0 +LocationArea = -1, 1911, 36464 + + +# ONStore= , , +ONStore= 5, 50, 60 +# ONStoreEntry= , , , , , +ONStoreEntry = 1, 447511699393, 2, 0, 8, OwnNumber1 + + +# is time in sec while this status is valid. The last record lasts until shutdown. +# - the set here has no effect. Please use NetworkInfo records instead. +# set here applies only to GetCellInfo/NotifyCellInfoChanges calls, which are not used. +# for getting CellId by our code. We use LocationArea records and GetCurrentNetwork/NotifyCurrentNetworkChange instead. +# - The status of cell info. Look at TCellInfoStatus for the list of values. +# CellInfo = , , , , . +CellInfo = 0, 2, 0, 0, 2 +CellInfo = 0, 2, 0, 0, 2 + diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/te_geolocmonitorsuite/testdata/lbsgeolocmonunitconfigbad.txt --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/te_geolocmonitorsuite/testdata/lbsgeolocmonunitconfigbad.txt Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,47 @@ +// config.txt +// +// Copyright (c) 2006 Symbian Software Ltd. All rights reserved. +// +// sim.tsy config used for simulating unavailability of LAC +// for negative unit test of Location Monitor +// + +[TEST0] +# PhoneId = ,,, , +PhoneId = Generic, 123, 1.1, 1234567890 + +#SubscriberId= = , +SubscriberId= 56789012345678 + +# Current Network Name +# NetworkInfo= , , , , , , +# is a network mode. GSM - 2, Unregistered - 1, WCDMA - 6 +NetworkInfo= 123, 456, Vodafone, Voda, Vodafone_UK, 0, 2 + +# LocationArea = , , . Where is -1 for true #and 0 for false. +#LocationArea= 1, 1, 1 + +# RegStatus = , , . +# Where is time in sec while this status is valid. The last record lasts until shutdown. +# - A registration status. Look at TMobilePhoneRegistrationStatus for the list of values. +# is an index of (NetworkInfo+LocationArea) array. It starts from 0. + +# Initial status. Wait for 15 sec here to allow the test to startup. +RegStatus= 15,5,0 + + + +# CellInfo = , , , . +# Where is time in sec while this status is valid. The last record lasts until shutdown. +# - the set here has no effect. Please use NetworkInfo records instead. +# set here applies only to GetCellInfo/NotifyCellInfoChanges calls, which are not used. +# for getting CellId by our code. We use LocationArea records an GetCurrentNetwork/NotifyCurrentNetworkChange instead. +# Test 0 +CellInfo= 23,2,0,0 + + +# ONStore= , , +ONStore= 5, 50, 60 +# ONStoreEntry= , , , , , +ONStoreEntry= 1, 07747012341, 2, 0, 8, OwnNumber1 + diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/te_geolocmonitorsuite/testdata/te_geolocmonitorsuite.ini --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/te_geolocmonitorsuite/testdata/te_geolocmonitorsuite.ini Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,260 @@ + +[VALIDATEGSMCELLINFO1] +// comment here please! +MCC = 0 +MNC = 0 +LAC = 0 +CID = 0 +TA = 0 +EXPECTEDERROR = 0 + +[VALIDATEGSMCELLINFO2] +MCC = 1 +MNC = 1 +LAC = 1 +CID = 1 +TA = 1 +EXPECTEDERROR = 0 + +[VALIDATEGSMCELLINFO3] +MCC = 1 +MNC = -1 +LAC = -1 +CID = -1 +TA = -1 +EXPECTEDERROR = -6 + +[VALIDATEGSMCELLINFO4] +MCC = 1 +MNC = 1 +LAC = -1 +CID = -1 +TA = -1 +EXPECTEDERROR = -6 + +[VALIDATEGSMCELLINFO5] +MCC = 1 +MNC = 1 +LAC = 1 +CID = -1 +TA = -1 +EXPECTEDERROR = -6 + +[VALIDATEGSMCELLINFO6] +MCC = 1 +MNC = 1 +LAC = 1 +CID = 1 +TA = -1 +EXPECTEDERROR = -6 + +[VALIDATEGSMCELLINFO7] +MCC = 1 +MNC = 1 +LAC = 1 +CID = 1 +TA = 1 + +[VALIDATEGSMCELLINFO8] +MCC = 0 +MNC = 0 +LAC = 0 +CID = 0 +TA = 1 + +[VALIDATEGSMCELLINFO9] +MCC = 0 +MNC = 0 +LAC = 0 +CID = 1 +TA = 1 + +[VALIDATEGSMCELLINFO10] +MCC = 0 +MNC = 0 +LAC = 1 +CID = 1 +TA = 1 + +[VALIDATEGSMCELLINFO11] +MCC = 0 +MNC = 1 +LAC = 1 +CID = 1 +TA = 1 + + +[VALIDATEGSMCELLINFO12] +MCC = 1 +MNC = 1 +LAC = 1 +CID = 1 +TA = 2000 +EXPECTEDERROR = -6 + +[VALIDATEGSMCELLINFO13] +MCC = 1 +MNC = 1 +LAC = 1 +CID = 65538 +TA = 2000 +EXPECTEDERROR = -6 + +[VALIDATEGSMCELLINFO13] +MCC = 1 +MNC = 1 +LAC = 1 +CID = 65538 +TA = 2000 +EXPECTEDERROR = -6 + +[VALIDATEGSMCELLINFO14] +MCC = 1 +MNC = 1 +LAC = 65539 +CID = 65538 +TA = 2000 +EXPECTEDERROR = -6 + +[VALIDATEGSMCELLINFO15] +MCC = 1 +MNC = 1000 +LAC = 65539 +CID = 65538 +TA = 2000 +EXPECTEDERROR = -6 + +[VALIDATEGSMCELLINFO16] +MCC = 1000 +MNC = 1000 +LAC = 65539 +CID = 65538 +TA = 2000 +EXPECTEDERROR = -6 + +[VALIDATEWCDMACELLINFO1] +MCC = 0 +MNC = 0 +UCID = 0 +SC = 0 + +[VALIDATEWCDMACELLINFO2] +MCC = 1 +MNC = 1 +UCID = 1 +SC = 1 + +[VALIDATEWCDMACELLINFO3] +MCC = 1 +MNC = -1 +UCID = -1 +SC = -1 +EXPECTEDERROR = -6 + +[VALIDATEWCDMACELLINFO4] +MCC = 1 +MNC = 1 +UCID = -1 +SC = -1 +EXPECTEDERROR = -6 + +[VALIDATEWCDMACELLINFO5] +MCC = 1 +MNC = 1 +UCID = 1 +SC = -1 +EXPECTEDERROR = -6 + +[VALIDATEWCDMACELLINFO6] +MCC = 1 +MNC = 1 +UCID = 1 +SC = 1 + +[VALIDATEWCDMACELLINFO7] +MCC = 0 +MNC = 0 +UCID = 0 +SC = 1 + +[VALIDATEWCDMACELLINFO8] +MCC = 0 +MNC = 0 +UCID = 1 +SC = 1 + + +[VALIDATEWCDMACELLINFO9] +MCC = 0 +MNC = 1 +UCID = 1 +SC = 1 + +[VALIDATEWCDMACELLINFO10] +MCC = 1 +MNC = 1 +UCID = 1 +SC = 2000 +EXPECTEDERROR = -6 + +[VALIDATEWCDMACELLINFO11] +MCC = 1 +MNC = 1 +UCID = 268435457 +SC = 2000 +EXPECTEDERROR = -6 + +[VALIDATEWCDMACELLINFO12] +MCC = 1000 +MNC = 1000 +UCID = 268435457 +SC = 2000 +EXPECTEDERROR = -6 + +[CREATEGSMCELL] +PROCEDURE = 1 + +[SETTATOGSMCELL] +PROCEDURE = 2 + +[SETNCELLTOGSMCELL] +PROCEDURE = 3 + +[VALIDATEGSMCELLHIERARCHY] +PROCEDURE = 4 + +[CREATEWCDMACELL] +PROCEDURE = 5 + +[SETSCTOWCDMACELL] +PROCEDURE = 6 + +[SETNCELLTOWCDMACELL] +PROCEDURE = 7 + +[VALIDATEWCDMACELLHIERARCHY] +PROCEDURE = 8 + +[CREATECOORDINFO] +PROCEDURE = 9 + +[VALIDATECOORDINFO] +PROCEDURE = 10 + +[CREATEWLANINFO] +PROCEDURE = 11 + +[VALIDATEWLANINFO] +PROCEDURE = 12 + +[ADDCOORDINFOTOLOCINFO] +PROCEDURE = 13 + +[ADDGSMINFOTOLOCINFO] +PROCEDURE = 14 + +[ADDWCDMAINFOTOLOCINFO] +PROCEDURE = 15 + +[ADDWLANINFOTOLOCINFO] +PROCEDURE = 16 diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/te_lbslocationinforconvertertef/group/bld.inf --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/te_lbslocationinforconvertertef/group/bld.inf Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,32 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ + + + + + +PRJ_TESTEXPORTS +../scripts/te_LbsLocationInfoConverterSuite.script /epoc32/winscw/c/testdata/scripts/te_lbslocationinfoconvertersuite.script +../scripts/LbsLocationInfoConverter.ini /epoc32/winscw/c/testdata/configs/lbslocationinfoconverter.ini + +//./te_lbslocationmonitordb.iby /epoc32/rom/include/te_lbslocationmonitordb.iby + +PRJ_TESTMMPFILES +te_lbslocationinfoconverter.mmp + + + diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/te_lbslocationinforconvertertef/group/te_lbslocationinfoconverter.iby --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/te_lbslocationinforconvertertef/group/te_lbslocationinfoconverter.iby Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,30 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ +#ifndef __LBS_TELOCATIONMONITOR_IBY__ +#define __LBS_TELOCATIONMONITOR_IBY__ + +#if !defined(SYMBIAN_EXCLUDE_LOCATION) + +#include + +file=ABI_DIR\DEBUG_DIR\te_lbslocationmonitordb.exe sys\bin\te_lbslocationmonitordb.exe + +data=EPOCROOT##Epoc32\winscw\c\TestData\scripts\te_LbsLocationMonitorDbSuite.script TestData\scripts\te_LbsLocationMonitorDbSuite.script + +#endif // SYMBIAN_EXCLUDE_LOCATION + +#endif diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/te_lbslocationinforconvertertef/group/te_lbslocationinfoconverter.mmp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/te_lbslocationinforconvertertef/group/te_lbslocationinfoconverter.mmp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,59 @@ +/* +* Copyright (c) 2006 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ + + +TARGET te_lbslocationinfoconvertersuite.exe +TARGETTYPE exe + +CAPABILITY ALL -TCB + +UID 0x1000007A 0x102869E2 + +VENDORID 0x70000001 + +//MACRO ENABLE_LBS_DEV_LOGGER +MACRO LBS_LOCMONITORDB_TEST + +SOURCEPATH ../src +SOURCE te_lbslocationinfoconvertersuiteserver.cpp +SOURCE te_lbslocationinfoconvertersuitestepbase.cpp +SOURCE step.cpp +SOURCE Te_locationinfoconversionobserver.cpp +SOURCE Te_locationresolverobserver.cpp + + +OS_LAYER_SYSTEMINCLUDE_SYMBIAN + +USERINCLUDE ../inc +USERINCLUDE ../../../lbslocmonitorserver/inc +USERINCLUDE ../../../../locationcore/LbsPartnerCommon/inc + +LIBRARY euser.lib +LIBRARY testexecuteutils.lib +LIBRARY testexecutelogclient.lib +LIBRARY efsrv.lib +LIBRARY lbs.lib + +LIBRARY lbslocationinfodatatypes.lib +LIBRARY lbslocationinfoconverter.lib + + +LIBRARY lbspartnercommon.lib +LIBRARY lbsinternalapi.lib + +SMPSAFE + diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/te_lbslocationinforconvertertef/inc/Te_locationinfoconversionobserver.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/te_lbslocationinforconvertertef/inc/Te_locationinfoconversionobserver.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,73 @@ +/* +* Copyright (c) 2002 - 2007 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Test module to implement Advanced trigger supervision cases +* +*/ + + + +#ifndef TE_LOCATIONINFOCONVERSIONOBSERVER_H +#define TE_LOCATIONINFOCONVERSIONOBSERVER_H +#include + + + class CTelocationinfoconversionobserver: public CTimer, public MLbsLocationInfoConverterObserver + + { + + public: // Constructors and destructor + + /** + * Two-phased constructor. + */ + static CTelocationinfoconversionobserver* NewL( ); + + /** + * Destructor. + */ + ~CTelocationinfoconversionobserver(); + + + void OnConversionComplete( TInt aStatusCode ); + + void RunL( ); + + void DoCancel( ); + + TInt ConversionResult(); + + // RTimer iTimer; + TRequestStatus iWaitStatus; + + private: + + /** + * C++ default constructor. + */ + CTelocationinfoconversionobserver( ); + + /** + * By default Symbian 2nd phase constructor is private. + */ + void ConstructL(); + + private: + + TInt iStatusCode; + + }; + +#endif // TE_LOCATIONINFOCONVERSIONOBSERVER_H + +// End of File diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/te_lbslocationinforconvertertef/inc/Te_locationresolverobserver.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/te_lbslocationinforconvertertef/inc/Te_locationresolverobserver.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,77 @@ +/* +* Copyright (c) 2002 - 2007 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Test module to implement Advanced trigger supervision cases +* +*/ + + + +#ifndef TE_BASICLOCATIONINFOCONVERSIONOBSERVER_H +#define TE_BASICLOCATIONINFOCONVERSIONOBSERVER_H +#include + + + class CTeLocationResolverObserver: public CTimer, public MLbsLocationResolverObserver + + { + + public: // Constructors and destructor + + /** + * Two-phased constructor. + */ + static CTeLocationResolverObserver* NewL( ); + + /** + * Destructor. + */ + ~CTeLocationResolverObserver(); + + void OnResolveLocationComplete(TInt aStatus, const TLocality& aLocality); + + void RunL( ); + + void DoCancel( ); + + TInt ConversionResult(); + + TInt ConversionLocality(TLocality& aLocality); + + + // RTimer iTimer; + TRequestStatus iWaitStatus; + + private: + + /** + * C++ default constructor. + */ + CTeLocationResolverObserver( ); + + /** + * By default Symbian 2nd phase constructor is private. + */ + void ConstructL(); + + private: + + TInt iStatusCode; + TLocality iLocality; + TBool iFromCache; + + }; + +#endif // TE_LOCATIONINFOCONVERSIONOBSERVER_H + +// End of File diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/te_lbslocationinforconvertertef/inc/ctasyncwaiter.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/te_lbslocationinforconvertertef/inc/ctasyncwaiter.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,52 @@ +/* +* Copyright (c) 2006 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: This is the header file for CT_LbsAsyncWaiter +* +*/ + +/** + @file + @internalTechnology + @test +*/ + +#ifndef __CT_ASYNC_WAITER_H__ +#define __CT_ASYNC_WAITER_H__ + +//epoc includes +#include + +// Implements functions related to active objects +class CT_AsyncWaiter : public CTimer + { +public: + IMPORT_C static CT_AsyncWaiter* NewL(); + ~CT_AsyncWaiter(); + + IMPORT_C void StartAndWait(); + IMPORT_C void StartAndWaitTimer(const TTimeIntervalMicroSeconds32& aTime); + IMPORT_C TInt Result() const; + +private: + CT_AsyncWaiter(); + void ConstructL(); + // from CActive + virtual void RunL(); + virtual void DoCancel(); + +private: + TInt iError; + }; + +#endif // __CT_ASYNC_WAITER_H__ diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/te_lbslocationinforconvertertef/inc/step.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/te_lbslocationinforconvertertef/inc/step.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,261 @@ +/* +* Copyright (c) 2007 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ + +#ifndef __STEP_H__ +#define __STEP_H__ +#include +#include "te_lbslocationinfoconvertersuitestepbase.h" + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include "Te_locationinfoconversionobserver.h" +#include "Te_locationresolverobserver.h" + +class CStep : public CTe_LbsLocationInfoConverterSuiteStepBase + { +public: + CStep(); + ~CStep(); + virtual TVerdict doTestStepPreambleL(); + virtual TVerdict doTestStepL(); + virtual TVerdict doTestStepPostambleL(); + + virtual void ConvertLocationInfoL(TInt conversionprefs=0, TInt requestedinfo=0, TInt fntype=0); + virtual void ConvertLocationInfo2L(TInt conversionprefs=0, TInt requestedinfo=0, TInt fntype=0); + + virtual TInt CreateLocationInfoConverterL(); +// virtual TInt SetCoordinateInfoL( CStifItemParser& aItem ); + + virtual void SetGSMCellInfoL( TInt fntype=1, TInt countrycode=-2, TInt networkcode=-2, + TInt locationcode=-2, TInt cellid=-2, TInt timingadvance=-2, TInt Rxlev=-2, TInt nNeignbourcells=0, + TInt arfcn=-2, TInt bsic=-2, TInt NRxlev=-2); + virtual TInt SetGSMCellInfo2L( TInt fntype=1, TInt countrycode=-2, TInt networkcode=-2, + TInt locationcode=-2, TInt cellid=-2, TInt timingadvance=-2, TInt Rxlev=-2, TInt nNeignbourcells=0, + TInt arfcn=-2, TInt bsic=-2, TInt NRxlev=-2); + virtual TInt SetWCDMACellInfoL(TInt fntype, TInt countrycode=-2, + TInt networkcode=-2, TInt cellid=-2, TInt nNeignbourcells=0, TInt scramblingcode=-2, + TInt neighbourucid=-2, TInt neighbourscode=-2, TInt neighbourpathloss=-2, + TInt neighboursignalstrength=-2); + virtual TInt SetWLanInfoL(TInt fntype=1, TInt macidint=-2, TInt signalstrength=-2); + virtual void AddLocationInfoL(); + virtual void AddLocationInfo2L(); + + virtual TInt ValidateLocationInfo(TInt requestedinfo=1); + virtual TInt ValidateLocationInfo2(TInt requestedinfo=1); + virtual TInt MiscL(TInt testcase); + virtual TInt SetConversionPrefs(TLbsConversionPrefs aSetConversionPrefs=0); + virtual TInt GetAndCheckConversionPrefs(TLbsConversionPrefs aSetConversionPrefs=0); + virtual TInt Cleanup(); + +private: + TInt iApiId; + TInt iPluginUid; + CLbsLocationResolver* iLbsLocationResolver; + CLbsLocationResolver* iLbsLocationResolver2; + CLbsLocationInfoConverter* iLbsLocationInfoConverter; + CLbsLocationInfo* iLbsLocationInfo; + CTeLocationResolverObserver* iResolverObserver; + CTeLocationResolverObserver* iResolverObserver2; + CTelocationinfoconversionobserver* iObserver; + RLbsLocationInfoBaseArray iLbsLocationInfoArray; + RLbsLocationInfoBaseArray iLbsLocationInfoArrayTemp; + + // for testing multipls conversions + CTelocationinfoconversionobserver* iObserver2; + CLbsLocationInfoConverter* iLbsLocationInfoConverter2; + CLbsLocationInfo* iLbsLocationInfo2; + + RLbsLocationInfoBaseArray iLbsLocationInfoArray2; + RLbsLocationInfoBaseArray iLbsLocationInfoArrayTemp2; + +private: + void CallL(TInt aId); + void test_2698_4_1_1_1L(); + void test_2698_4_1_1_3L(); + void test_2698_4_1_1_4L(); + void test_2698_4_1_1_5L(); + void test_2698_4_1_1_6L(); + void test_2698_4_1_1_7L(); + void test_2698_4_1_1_8L(); + void test_2698_4_1_1_9L(); + void test_2698_4_1_1_10L(); + void test_2698_4_1_1_11L(); + void test_2698_4_1_1_12L(); + void test_2698_4_1_1_13L(); + void test_2698_4_1_2L(); + void test_2698_4_1_3L(); + void test_2698_4_1_4L(); + void test_2698_4_1_5L(); + void test_2698_4_1_6L(); + void test_2698_4_1_7L(); + void test_2698_4_1_8L(); + void test_2698_4_1_9L(); + void test_2698_4_1_10L(); + void test_2698_4_1_11L(); + void test_2698_4_1_12L(); + void test_2698_4_1_13L(); + void test_2698_4_1_14L(); + void test_2698_4_1_15L(); + void test_2698_4_1_16L(); + void test_2698_4_1_17L(); + void test_2698_4_1_18L(); + void test_2698_4_1_19L(); + void test_2698_4_1_20L(); + void test_2698_4_1_21L(); + void test_2698_4_1_22L(); + void test_2698_4_1_23L(); + void test_2698_4_1_24L(); + void test_2698_4_1_25L(); + void test_2698_4_1_26L(); + void test_2698_4_1_27L(); + void test_2698_4_1_28_1L(); + void test_2698_4_1_28_1_3L(); + void test_2698_4_1_28_1_4L(); + void test_2698_4_1_28_1_5L(); + void test_2698_4_1_28_1_6L(); + void test_2698_4_1_28_1_7L(); + void test_2698_4_1_28_1_8L(); + void test_2698_4_1_28_1_9L(); + void test_2698_4_1_28_1_10L(); + void test_2698_4_1_28_2L(); + void test_2698_4_1_29L(); + void test_2698_4_1_30L(); + void test_2698_4_1_31L(); + void test_2698_4_1_32L(); + void test_2698_4_1_33L(); + void test_2698_4_1_34L(); + void test_2698_4_1_35L(); + void test_2698_4_1_36L(); + void test_2698_4_1_37L(); + void test_2698_4_1_38L(); + void test_2698_4_1_39L(); + void test_2698_4_1_40L(); + void test_2698_4_1_41L(); + void test_2698_4_1_42L(); + void test_2698_4_1_43L(); + void test_2698_4_1_44L(); + void test_2698_4_1_45L(); + void test_2698_4_1_46L(); + void test_2698_4_1_47_1L(); + void test_2698_4_1_47_2L(); + void test_2698_4_1_47_3L(); + void test_2698_4_1_49_1L(); + void test_2698_4_1_49_2L(); + void test_2698_4_1_51L(); + void test_2698_4_1_52L(); + void test_2698_4_1_53L(); + void test_2698_4_2_1L(); + void test_2698_4_2_2L(); + void test_2698_4_2_3L(); + void test_2698_4_2_4L(); + void test_2698_4_2_5L(); + void test_2698_4_2_6L(); + void test_2698_4_2_7L(); + void test_2698_4_2_8L(); + void test_2698_4_2_9L(); + void test_2698_4_2_10L(); + void test_2698_4_2_11L(); + void test_2698_4_2_12L(); + void test_2698_4_2_13L(); + void test_2698_4_2_14L(); + void test_2698_4_2_15L(); + void test_2698_4_2_16L(); + void test_2698_4_2_17L(); + void test_2698_4_2_18L(); + void test_2698_4_2_19L(); + void test_2698_4_2_20L(); + void test_2698_4_2_21L(); + void test_2698_4_2_22L(); + void test_2698_4_3_1_1L(); + void test_2698_4_3_2_1L(); + void test_2698_4_3_2_2L(); + void test_2698_4_3_4L(); + void test_2698_4_3_5L(); + void test_2698_4_3_6L(); + void test_2698_4_3_7L(); + void test_2698_4_3_8L(); + void test_2698_4_3_9L(); + void test_2698_4_3_10L(); + void test_2698_4_4_1L(); + void test_2698_4_4_2L(); + void test_2698_4_4_3L(); + void test_2698_4_4_4L(); + void test_2698_4_5_1L(); + void test_2698_4_5_2L(); + void test_2698_5_1_1L(); + void test_2698_5_1_2L(); + void test_2698_5_1_3L(); + void test_2698_5_1_4L(); + void test_2698_5_1_5L(); + void test_2698_5_1_6L(); + void test_2698_5_1_7L(); + void test_2698_5_1_8L(); + void test_2698_5_1_9L(); + void test_2698_5_1_10L(); + void test_2698_5_1_11L(); + void test_2698_5_1_12L(); + void test_2698_5_1_13L(); + void test_2698_5_1_14L(); + void test_2698_5_1_15L(); + void test_2698_5_1_16L(); + void test_2698_5_1_17L(); + void test_2698_5_1_18L(); + void test_2698_5_1_19L(); + void test_2698_5_1_20L(); + void test_2698_5_1_21L(); + void test_2698_5_1_22L(); + void test_2698_5_1_23L(); + void test_2698_5_1_24L(); + void test_2698_5_1_25L(); + void test_2698_5_1_26L(); + void test_2698_5_1_27L(); + void test_2698_5_2_1L(); + void test_2698_5_2_2L(); + void test_2698_5_2_3L(); + void test_2698_5_2_4L(); + void test_2698_5_2_5L(); + void test_2698_5_2_6L(); + void test_2698_5_3_1L(); + void test_2698_5_3_2L(); + void test_2698_5_3_3L(); + void test_2698_5_3_4L(); + void test_2698_5_4_1L(); + void test_MultipleSessionsOneAfterAnotherL(); + void test_MultipleCoversionsAtSameTimeL(); + void test_MultipleResolversAtSameTimeL(); + void test_SetAndGetConversionPrefs(); + void test_2698_5_4_2L(); + void test_cacheL(); + void test_cache2L(); + void test_cache3L(); + }; + +_LIT(KStep,"Step"); + +#endif diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/te_lbslocationinforconvertertef/inc/te_lbslocationinfoconvertersuitedefs.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/te_lbslocationinforconvertertef/inc/te_lbslocationinfoconvertersuitedefs.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,36 @@ +/* +* Copyright (c) 2004 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ + +#ifndef __TE_LBSLOCATIONMONITOR_SUITE_DEFS_H__ +#define __TE_LBSLOCATIONMONITOR_SUITE_DEFS_H__ + +#include + +// For Backward Compatibility test +_LIT(KTe_BoolNeedResetFromDefault, "resetall"); +// For test step panics +_LIT(KTe_LbsLocationMonitorSuitePanic, "Te_LbsLocationMonitorSuite"); + +_LIT(KErrorCreateTELBSLocationMonitorTestStep, "The test step can not be created: %d"); +_LIT(ErrorUnexpected, "Unexpected error returned:%d"); + +_LIT(KErrorCheckRunBeforeLeaving, "ErrorCheck run before leaving"); +_LIT(KErrorBackwardCompatibilityNotRespected, "The backward compatibility is not respected anymore"); + + + +#endif diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/te_lbslocationinforconvertertef/inc/te_lbslocationinfoconvertersuiteserver.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/te_lbslocationinforconvertertef/inc/te_lbslocationinfoconvertersuiteserver.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,36 @@ +/* +* Copyright (c) 2006 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ + + +#ifndef __TE_LBSLOCATIONMONITOR_SERVER_H__ +#define __TE_LBSLOCATIONMONITOR_SERVER_H__ +#include + + +class CTe_LbsLocationMonitorSuite : public CTestServer + { +public: + static CTe_LbsLocationMonitorSuite* NewL(); + // Base class pure virtual override + virtual CTestStep* CreateTestStep(const TDesC& aStepName); + IMPORT_C virtual void ConstructL(const TDesC& aName); + ~CTe_LbsLocationMonitorSuite(); + +private: + }; + +#endif diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/te_lbslocationinforconvertertef/inc/te_lbslocationinfoconvertersuitestepbase.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/te_lbslocationinforconvertertef/inc/te_lbslocationinfoconvertersuitestepbase.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,55 @@ +/* +* Copyright (c) 2004 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ + + +#ifndef __TE_LBSLOCATIONMONITOR_STEP_BASE__ +#define __TE_LBSLOCATIONMONITOR_STEP_BASE__ +#include +#include +#include "ctasyncwaiter.h" + + + +// Please add your include here if you have + +/**************************************************************************** +* The reason to have a new step base is that it is very much possible +* that the all individual test steps have project related common variables +* and members +* and this is the place to define these common variable and members. +* +****************************************************************************/ +class CTe_LbsLocationInfoConverterSuiteStepBase : public CTestStep + { + +public: + virtual ~CTe_LbsLocationInfoConverterSuiteStepBase(); + CTe_LbsLocationInfoConverterSuiteStepBase(); + virtual TVerdict doTestStepPreambleL(); + virtual TVerdict doTestStepPostambleL(); + TInt GetTestCaseId(); + TInt GetTestCaseApi(); + TInt GetPluginUid(); +protected: + void InitWaitersL(); + void DeleteWaiters(); + +protected: + CActiveScheduler* iScheduler; + }; + +#endif diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/te_lbslocationinforconvertertef/scripts/LbsLocationInfoConverter.ini --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/te_lbslocationinforconvertertef/scripts/LbsLocationInfoConverter.ini Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,1388 @@ +[MultipleSessions-1] +tc_id=151 +plugin_uid = 537007117 + +[MultipleSessions-2] +tc_id=152 +plugin_uid = 537007117 + +[MultipleSessions-3] +tc_id=153 +plugin_uid = 537007117 + +[Cache-Test-1] +tc_id=156 +plugin_uid = 537007117 + +[Cache-Test-2] +tc_id=157 +plugin_uid = 537007117 + +[Cache-Test-3] +tc_id=158 +plugin_uid = 537007117 + +[GetAllLocationInfo] +tc_id=0 + +[2698-4-1-1-1] +tc_id=1 +plugin_uid = 537007117 + +[2698-4-2-1-1] +tc_id=1 +plugin_uid = 0 + +[2698-4-1-1-3] +tc_id=2 +plugin_uid = 537007117 + +[2698-4-2-1-3] +tc_id=2 +plugin_uid = 0 + +[2698-4-1-1-4] +tc_id=3 +plugin_uid = 537007117 + +[2698-4-1-1-5] +tc_id=4 +plugin_uid = 537007117 + +[2698-4-1-1-6] +tc_id=5 +plugin_uid = 537007117 + +[2698-4-1-1-7] +tc_id=6 +plugin_uid = 537007117 + +[2698-4-1-1-8] +tc_id=7 +plugin_uid = 537007117 + +[2698-4-2-1-8] +tc_id=7 +plugin_uid = 0 + +[2698-4-1-1-9] +tc_id=8 +plugin_uid = 537007117 + + +[2698-4-2-1-9] +tc_id=8 +plugin_uid = 0 + +[2698-4-1-1-10] +tc_id=9 +plugin_uid = 537007117 + +[2698-4-1-1-11] +tc_id=10 +plugin_uid = 537007117 + +[2698-4-1-1-12] +tc_id=11 +plugin_uid = 537007117 + +[2698-4-1-1-13] +tc_id=12 +plugin_uid = 537007117 + +[2698-4-1-2] +tc_id=13 +plugin_uid = 537007117 + +[2698-4-11-2] +tc_id=13 +plugin_uid = 0 + +[2698-4-1-3] +tc_id=14 +plugin_uid = 537007117 + +[2698-4-1-4] +tc_id=15 +plugin_uid = 537007117 + +[2698-4-1-5] +tc_id=16 +plugin_uid = 537007117 + +[2698-4-1-6] +tc_id=17 +plugin_uid = 537007117 + +[2698-4-1-7] +tc_id=18 +plugin_uid = 537007117 + +[2698-4-1-8] +tc_id=19 +plugin_uid = 537007117 + +[2698-4-1-9] +tc_id=20 +plugin_uid = 537007117 + +[2698-4-1-10] +tc_id=21 +plugin_uid = 537007117 + +[2698-4-1-11] +tc_id=22 +plugin_uid = 537007117 + +[2698-4-1-12] +tc_id=23 +plugin_uid = 537007117 + +[2698-4-1-13] +tc_id=24 +plugin_uid = 537007117 + +[2698-4-1-14] +tc_id=25 +plugin_uid = 537007117 + +[2698-4-1-15] +tc_id=26 +plugin_uid = 537007117 + +[2698-4-1-16] +tc_id=27 +plugin_uid = 537007117 + +[2698-4-1-17] +tc_id=28 +plugin_uid = 537007117 + +[2698-4-1-18] +tc_id=29 +plugin_uid = 537007117 + +[2698-4-1-19] +tc_id=30 +plugin_uid = 537007117 + +[2698-4-1-20] +tc_id=31 +plugin_uid = 537007117 + +[2698-4-1-21] +tc_id=32 +plugin_uid = 537007117 + +[2698-4-1-22] +tc_id=33 +plugin_uid = 537007117 + +[2698-4-1-23] +tc_id=34 +plugin_uid = 537007117 + +[2698-4-1-24] +tc_id=35 +plugin_uid = 537007117 + +[2698-4-1-25] +tc_id=36 +plugin_uid = 537007117 + +[2698-4-1-26] +tc_id=37 +plugin_uid = 537007117 + +[2698-4-1-27] +tc_id=38 +plugin_uid = 537007117 + +[2698-4-1-28-1] +tc_id=39 +plugin_uid = 537007117 + +[2698-4-1-28-1-3] +tc_id=40 +plugin_uid = 537007117 + +[2698-4-1-28-1-4] +tc_id=41 +plugin_uid = 537007117 + +[2698-4-1-28-1-5] +tc_id=42 +plugin_uid = 537007117 + +[2698-4-1-28-1-6] +tc_id=43 +plugin_uid = 537007117 + +[2698-4-1-28-1-7] +tc_id=44 +plugin_uid = 537007117 + +[2698-4-1-28-1-8] +tc_id=45 +plugin_uid = 537007117 + +[2698-4-1-28-1-9] +tc_id=46 +plugin_uid = 537007117 + +[2698-4-1-28-1-10] +tc_id=47 +plugin_uid = 537007117 + +[2698-4-1-28-2] +tc_id=48 +plugin_uid = 537007117 + +[2698-4-11-28-2] +tc_id=48 +plugin_uid = 0 + +[2698-4-1-29] +tc_id=49 +plugin_uid = 537007117 + +[2698-4-1-30] +tc_id=50 +plugin_uid = 537007117 + +[2698-4-1-31] +tc_id=51 +plugin_uid = 537007117 + +[2698-4-1-32] +tc_id=52 +plugin_uid = 537007117 + +[2698-4-1-33] +tc_id=53 +plugin_uid = 537007117 + +[2698-4-1-34] +tc_id=54 +plugin_uid = 537007117 + +[2698-4-1-35] +tc_id=55 +plugin_uid = 537007117 + +[2698-4-1-36] +tc_id=56 +plugin_uid = 537007117 + +[2698-4-1-37] +tc_id=57 +plugin_uid = 537007117 + +[2698-4-1-38] +tc_id=58 +plugin_uid = 537007117 + +[2698-4-1-39] +tc_id=59 +plugin_uid = 537007117 + +[2698-4-1-40] +tc_id=60 +plugin_uid = 537007117 + +[2698-4-1-41] +tc_id=61 +plugin_uid = 537007117 + +[2698-4-1-42] +tc_id=62 +plugin_uid = 537007117 + +[2698-4-1-43] +tc_id=63 +plugin_uid = 537007117 + +[2698-4-1-44] +tc_id=64 +plugin_uid = 537007117 + +[2698-4-1-45] +tc_id=65 +plugin_uid = 537007117 + +[2698-4-1-46] +tc_id=66 +plugin_uid = 537007117 + +[2698-4-1-47-1] +tc_id=67 +plugin_uid = 537007117 + +[2698-4-1-47-2] +tc_id=68 +plugin_uid = 537007117 + +[2698-4-1-47-3] +tc_id=69 +plugin_uid = 537007117 + +[2698-4-1-49-1] +tc_id=70 +plugin_uid = 537007117 + +[2698-4-1-49-2] +tc_id=71 +plugin_uid = 537007117 + +[2698-4-1-51] +tc_id=72 +plugin_uid = 537007117 + +[2698-4-1-52] +tc_id=73 +plugin_uid = 537007117 + +[2698-4-1-53] +tc_id=74 +plugin_uid = 537007117 + +[2698-4-2-1] +tc_id=75 +plugin_uid = 537007117 + +[2698-4-2-2] +tc_id=76 +plugin_uid = 537007117 + +[2698-4-2-3] +tc_id=77 +plugin_uid = 537007117 + +[2698-4-2-4] +tc_id=78 +plugin_uid = 537007117 + +[2698-4-2-5] +tc_id=79 +plugin_uid = 537007117 + +[2698-4-2-6] +tc_id=80 +plugin_uid = 537007117 + +[2698-4-2-7] +tc_id=81 +plugin_uid = 537007117 + +[2698-4-2-8] +tc_id=82 +plugin_uid = 537007117 + +[2698-4-2-9] +tc_id=83 +plugin_uid = 537007117 + +[2698-4-2-10] +tc_id=84 +plugin_uid = 537007117 + +[2698-4-2-11] +tc_id=85 +plugin_uid = 537007117 + +[2698-4-2-12] +tc_id=86 +plugin_uid = 537007117 + +[2698-4-2-13] +tc_id=87 +plugin_uid = 537007117 + +[2698-4-2-14] +tc_id=88 +plugin_uid = 537007117 + +[2698-4-2-15] +tc_id=89 +plugin_uid = 537007117 + +[2698-4-2-16] +tc_id=90 +plugin_uid = 537007117 + +[2698-4-2-17] +tc_id=91 +plugin_uid = 537007117 + +[2698-4-2-18] +tc_id=92 +plugin_uid = 537007117 + +[2698-4-2-19] +tc_id=93 +plugin_uid = 537007117 + +[2698-4-2-20] +tc_id=94 +plugin_uid = 537007117 + +[2698-4-2-21] +tc_id=95 +plugin_uid = 537007117 + +[2698-4-2-22] +tc_id=96 +plugin_uid = 537007117 + +[2698-4-3-1-1] +tc_id=97 +plugin_uid = 537007117 + + +[2698-4-3-2-1] +tc_id=98 +plugin_uid = 537007117 + + +[2698-4-3-2-2] +tc_id=99 +plugin_uid = 537007117 + +[2698-4-3-4] +tc_id=100 +plugin_uid = 537007117 + +[2698-4-3-5] +tc_id=101 +plugin_uid = 537007117 + + +[2698-4-3-6] +tc_id=102 +plugin_uid = 537007117 + + +[2698-4-3-7] +tc_id=103 +plugin_uid = 537007117 + +[2698-4-3-8] +tc_id=104 +plugin_uid = 537007117 + +[2698-4-3-9] +tc_id=105 +plugin_uid = 537007117 + +[2698-4-3-10] +tc_id=106 +plugin_uid = 537007117 + +[2698-4-4-1] +tc_id=107 +plugin_uid = 537007117 + +[2698-4-4-2] +tc_id=108 +plugin_uid = 537007117 + +[2698-4-4-3] +tc_id=109 +plugin_uid = 537007117 + +[2698-4-4-4] +tc_id=110 +plugin_uid = 537007117 + +[2698-4-5-1] +tc_id=111 +plugin_uid = 537007117 + +[2698-4-5-2] +tc_id=112 +plugin_uid = 537007117 + +[2698-5-1-1] +tc_id=113 +plugin_uid = 537007117 + +[2698-5-1-2] +tc_id=114 +plugin_uid = 537007117 + +[2698-5-1-3] +tc_id=115 +plugin_uid = 537007117 + +[2698-5-1-4] +tc_id=116 +plugin_uid = 537007117 + +[2698-5-1-5] +tc_id=117 +plugin_uid = 537007117 + +[2698-5-1-6] +tc_id=118 +plugin_uid = 537007117 + +[2698-5-1-7] +tc_id=119 +plugin_uid = 537007117 + +[2698-5-1-8] +tc_id=120 +plugin_uid = 537007117 + +[2698-5-1-9] +tc_id=121 +plugin_uid = 537007117 + +[2698-5-1-10] +tc_id=122 +plugin_uid = 537007117 + +[2698-5-1-11] +tc_id=123 +plugin_uid = 537007117 + + +[2698-5-1-12] +tc_id=124 +plugin_uid = 537007117 + +[2698-5-1-13] +tc_id=125 +plugin_uid = 537007117 + +[2698-5-1-14] +tc_id=126 +plugin_uid = 537007117 + +[2698-5-1-15] +tc_id=127 +plugin_uid = 537007117 + +[2698-5-1-16] +tc_id=128 +plugin_uid = 537007117 + +[2698-5-1-17] +tc_id=129 +plugin_uid = 537007117 + +[2698-5-1-18] +tc_id=130 +plugin_uid = 537007117 + +[2698-5-1-19] +tc_id=131 +plugin_uid = 537007117 + +[2698-5-1-20] +tc_id=132 +plugin_uid = 537007117 + +[2698-5-1-21] +tc_id=133 +plugin_uid = 537007117 + +[2698-5-1-22] +tc_id=134 +plugin_uid = 537007117 + +[2698-5-1-23] +tc_id=135 +plugin_uid = 537007117 + +[2698-5-1-24] +tc_id=136 +plugin_uid = 537007117 + +[2698-5-1-25] +tc_id=137 +plugin_uid = 537007117 + +[2698-5-1-26] +tc_id=138 +plugin_uid = 537007117 + +[2698-5-1-27] +tc_id=139 +plugin_uid = 537007117 + +[2698-5-2-1] +tc_id=140 +plugin_uid = 537007117 + +[2698-5-2-2] +tc_id=141 +plugin_uid = 537007117 + +[2698-5-2-3] +tc_id=142 +plugin_uid = 537007117 + +[2698-5-2-4] +tc_id=143 +plugin_uid = 537007117 + +[2698-5-2-5] +tc_id=144 +plugin_uid = 537007117 + +[2698-5-2-6] +tc_id=145 +plugin_uid = 537007117 + +[2698-5-3-1] +tc_id=146 +plugin_uid = 537007117 + +[2698-5-3-2] +tc_id=147 +plugin_uid = 537007117 + +[2698-5-3-3] +tc_id=148 +plugin_uid = 537007117 + +[2698-5-3-4] +tc_id=149 +plugin_uid = 537007117 + +[2698-5-4-1] +tc_id=150 +plugin_uid = 537007117 + +[2698-5-4-2] +tc_id=154 +plugin_uid = 10 + +[2698-5-4-3] +tc_id=1 +plugin_uid = 0 + +[2698-4-1-1-1-R] +tc_id=1 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-2-1-1-R] +tc_id=1 +tc_api=1 +plugin_uid = 0 + +[2698-4-1-1-3-R] +tc_id=2 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-2-1-3-R] +tc_id=2 +tc_api=1 +plugin_uid = 0 + + +[2698-4-1-1-4-R] +tc_id=3 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-1-5-R] +tc_id=4 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-1-6-R] +tc_id=5 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-1-7-R] +tc_id=6 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-1-8-R] +tc_id=7 +tc_api=1 +plugin_uid = 537007117 + + +[2698-4-2-1-8-R] +tc_id=7 +tc_api=1 +plugin_uid = 0 + +[2698-4-1-1-9-R] +tc_id=8 +tc_api=1 +plugin_uid = 537007117 + + +[2698-4-2-1-9-R] +tc_id=8 +tc_api=1 +plugin_uid = 0 + + +[2698-4-1-1-10-R] +tc_id=9 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-1-11-R] +tc_id=10 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-1-12-R] +tc_id=11 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-1-13-R] +tc_id=12 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-2-R] +tc_id=13 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-11-2-R] +tc_id=13 +tc_api=1 +plugin_uid = 0 + +[2698-4-1-3-R] +tc_id=14 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-4-R] +tc_id=15 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-5-R] +tc_id=16 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-6-R] +tc_id=17 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-7-R] +tc_id=18 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-8-R] +tc_id=19 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-9-R] +tc_id=20 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-10-R] +tc_id=21 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-11-R] +tc_id=22 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-12-R] +tc_id=23 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-13-R] +tc_id=24 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-14-R] +tc_id=25 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-15-R] +tc_id=26 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-16-R] +tc_id=27 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-17-R] +tc_id=28 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-18-R] +tc_id=29 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-19-R] +tc_id=30 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-20-R] +tc_id=31 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-21-R] +tc_id=32 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-22-R] +tc_id=33 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-23-R] +tc_id=34 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-24-R] +tc_id=35 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-25-R] +tc_id=36 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-28-1-R] +tc_id=39 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-28-1-3-R] +tc_id=40 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-28-1-4-R] +tc_id=41 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-28-1-5-R] +tc_id=42 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-28-1-6-R] +tc_id=43 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-28-1-7-R] +tc_id=44 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-28-1-8-R] +tc_id=45 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-28-1-9-R] +tc_id=46 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-28-1-10-R] +tc_id=47 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-28-2-R] +tc_id=48 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-11-28-2-R] +tc_id=48 +tc_api=1 +plugin_uid = 0 + + +[2698-4-1-29-R] +tc_id=49 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-30-R] +tc_id=50 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-31-R] +tc_id=51 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-32-R] +tc_id=52 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-33-R] +tc_id=53 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-34-R] +tc_id=54 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-35-R] +tc_id=55 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-36-R] +tc_id=56 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-37-R] +tc_id=57 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-38-R] +tc_id=58 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-39-R] +tc_id=59 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-40-R] +tc_id=60 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-41-R] +tc_id=61 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-42-R] +tc_id=62 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-43-R] +tc_id=63 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-44-R] +tc_id=64 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-45-R] +tc_id=65 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-46-R] +tc_id=66 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-47-1-R] +tc_id=67 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-47-2-R] +tc_id=68 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-47-3-R] +tc_id=69 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-49-1-R] +tc_id=70 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-49-2-R] +tc_id=71 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-1-51-R] +tc_id=72 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-2-1-R] +tc_id=75 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-2-2-R] +tc_id=76 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-2-3-R] +tc_id=77 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-2-4-R] +tc_id=78 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-2-5-R] +tc_id=79 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-2-6-R] +tc_id=80 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-2-7-R] +tc_id=81 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-2-8-R] +tc_id=82 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-2-9-R] +tc_id=83 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-2-10-R] +tc_id=84 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-2-11-R] +tc_id=85 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-2-12-R] +tc_id=86 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-2-13-R] +tc_id=87 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-2-14-R] +tc_id=88 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-2-15-R] +tc_id=89 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-2-16-R] +tc_id=90 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-2-17-R] +tc_id=91 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-2-18-R] +tc_id=92 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-2-19-R] +tc_id=93 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-2-20-R] +tc_id=94 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-2-21-R] +tc_id=95 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-2-22-R] +tc_id=96 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-3-1-1-R] +tc_id=97 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-3-2-1-R] +tc_id=98 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-3-2-2-R] +tc_id=99 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-3-7-R] +tc_id=103 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-3-8-R] +tc_id=104 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-3-9-R] +tc_id=105 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-3-10-R] +tc_id=106 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-4-1-R] +tc_id=107 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-4-2-R] +tc_id=108 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-4-3-R] +tc_id=109 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-4-4-R] +tc_id=110 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-5-1-R] +tc_id=111 +tc_api=1 +plugin_uid = 537007117 + +[2698-4-5-2-R] +tc_id=112 +tc_api=1 +plugin_uid = 537007117 + +[2698-5-1-1-R] +tc_id=113 +tc_api=1 +plugin_uid = 537007117 + +[2698-5-1-2-R] +tc_id=114 +tc_api=1 +plugin_uid = 537007117 + +[2698-5-1-3-R] +tc_id=115 +tc_api=1 +plugin_uid = 537007117 + +[2698-5-1-4-R] +tc_id=116 +tc_api=1 +plugin_uid = 537007117 + +[2698-5-1-5-R] +tc_id=117 +tc_api=1 +plugin_uid = 537007117 + +[2698-5-1-6-R] +tc_id=118 +tc_api=1 +plugin_uid = 537007117 + +[2698-5-1-7-R] +tc_id=119 +tc_api=1 +plugin_uid = 537007117 + +[2698-5-1-8-R] +tc_id=120 +tc_api=1 +plugin_uid = 537007117 + +[2698-5-1-9-R] +tc_id=121 +tc_api=1 +plugin_uid = 537007117 + +[2698-5-1-10-R] +tc_id=122 +tc_api=1 +plugin_uid = 537007117 + +[2698-5-1-11-R] +tc_id=123 +tc_api=1 +plugin_uid = 537007117 + +[2698-5-1-12-R] +tc_id=124 +tc_api=1 +plugin_uid = 537007117 + +[2698-5-1-13-R] +tc_id=125 +tc_api=1 +plugin_uid = 537007117 + +[2698-5-1-14-R] +tc_id=126 +tc_api=1 +plugin_uid = 537007117 + +[2698-5-1-15-R] +tc_id=127 +tc_api=1 +plugin_uid = 537007117 + +[2698-5-1-16-R] +tc_id=128 +tc_api=1 +plugin_uid = 537007117 + +[2698-5-1-17-R] +tc_id=129 +tc_api=1 +plugin_uid = 537007117 + +[2698-5-1-18-R] +tc_id=130 +tc_api=1 +plugin_uid = 537007117 + +[2698-5-1-21-R] +tc_id=133 +tc_api=1 +plugin_uid = 537007117 + +[2698-5-1-24-R] +tc_id=136 +tc_api=1 +plugin_uid = 537007117 + +[2698-5-2-1-R] +tc_id=140 +tc_api=1 +plugin_uid = 537007117 + +[2698-5-2-2-R] +tc_id=141 +tc_api=1 +plugin_uid = 537007117 + +[2698-5-2-3-R] +tc_id=142 +tc_api=1 +plugin_uid = 537007117 + +[2698-5-2-4-R] +tc_id=143 +tc_api=1 +plugin_uid = 537007117 + +[2698-5-2-5-R] +tc_id=144 +tc_api=1 +plugin_uid = 537007117 + +[2698-5-2-6-R] +tc_id=145 +tc_api=1 +plugin_uid = 537007117 + +[2698-5-3-1-R] +tc_id=146 +tc_api=1 +plugin_uid = 537007117 + +[2698-5-3-2-R] +tc_id=147 +tc_api=1 +plugin_uid = 537007117 + +[2698-5-3-3-R] +tc_id=148 +tc_api=1 +plugin_uid = 537007117 + +[2698-5-3-4-R] +tc_id=149 +tc_api=1 +plugin_uid = 537007117 + +[2698-5-4-1-R] +tc_id=150 +tc_api=1 +plugin_uid = 537007117 + +[2698-5-4-2-R] +tc_id=154 +plugin_uid = 10 + +[SetAndGetConversionPrefs-1] +tc_id=155 +tc_api=1 +plugin_uid = 537007117 diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/te_lbslocationinforconvertertef/scripts/te_LbsLocationInfoConverterSuite.script --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/te_lbslocationinforconvertertef/scripts/te_LbsLocationInfoConverterSuite.script Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,1516 @@ +LOAD_SUITE te_lbslocationinfoconvertersuite +RUN_UTILS DeleteFile c:\config.txt +RUN_UTILS CopyFile c:\testdata\configs\lbsgeolocmonunitconfig.txt c:\config.txt + +RUN_UTILS DeleteFile c:\private\10281e17\[102869DF]lastknownlocarea.db-journal +RUN_UTILS DeleteFile c:\private\10281e17\[102869DF]lastknownlocarea.db + + +START_TESTCASE LBS-Cache-Test-2 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini Cache-Test-2 +END_TESTCASE LBS-Cache-Test-2 + + +START_TESTCASE LBS-Cache-Test-1 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini Cache-Test-1 +END_TESTCASE LBS-Cache-Test-1 + +PRINT now wait for loc monitor to teminate (which it will do after 10 seconds +PRINT this ensures when we try and delete the caches files they are not still in an opened state + +DELAY 12000 + +RUN_UTILS DeleteFile c:\private\10281e17\[102869DF]lastknownlocarea.db-journal +RUN_UTILS DeleteFile c:\private\10281e17\[102869DF]lastknownlocarea.db + +START_TESTCASE LBS-Cache-Test-3 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini Cache-Test-3 +END_TESTCASE LBS-Cache-Test-3 + + +START_TESTCASE LBS-LocationInfoConverter-MultipleSessions-1 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini MultipleSessions-1 +END_TESTCASE LBS-LocationInfoConverter-MultipleSessions-1 + +START_TESTCASE LBS-LocationInfoConverter-MultipleSessions-2 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini MultipleSessions-2 +END_TESTCASE LBS-LocationInfoConverter-MultipleSessions-2 + +START_TESTCASE LBS-LocationInfoConverter-MultipleSessions-3 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini MultipleSessions-3 +END_TESTCASE LBS-LocationInfoConverter-MultipleSessions-3 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-1-1 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-1-1 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-1-1 + +//Test with plugin id 0 +START_TESTCASE LBS-LocationInfoConverter-2698-4-2-1-1 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-2-1-1 +END_TESTCASE LBS-LocationInfoConverter-2698-4-2-1-1 + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-1-3 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-1-3 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-1-3 + +//Test with plugin id 0 +START_TESTCASE LBS-LocationInfoConverter-2698-4-2-1-3 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-2-1-3 +END_TESTCASE LBS-LocationInfoConverter-2698-4-2-1-3 + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-1-4 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-1-4 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-1-4 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-1-5 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-1-5 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-1-5 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-1-6 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-1-6 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-1-6 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-1-7 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-1-7 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-1-7 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-1-8 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-1-8 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-1-8 + +//Test with plugin id 0 +START_TESTCASE LBS-LocationInfoConverter-2698-4-2-1-8 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-2-1-8 +END_TESTCASE LBS-LocationInfoConverter-2698-4-2-1-8 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-1-9 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-1-9 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-1-9 + +//Test with plugin id 0 +START_TESTCASE LBS-LocationInfoConverter-2698-4-2-1-9 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-2-1-9 +END_TESTCASE LBS-LocationInfoConverter-2698-4-2-1-9 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-1-10 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-1-10 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-1-10 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-1-11 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-1-11 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-1-11 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-1-12 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-1-12 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-1-12 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-1-13 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-1-13 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-1-13 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-2 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-2 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-2 + +//Test with plugin id 0 +START_TESTCASE LBS-LocationInfoConverter-2698-4-11-2 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-11-2 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-2 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-3 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-3 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-3 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-4 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-4 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-4 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-5 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-5 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-5 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-6 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-6 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-6 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-7 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-7 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-7 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-8 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-8 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-8 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-9 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-9 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-9 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-10 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-10 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-10 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-11 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-11 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-11 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-12 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-12 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-12 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-13 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-13 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-13 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-14 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-14 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-14 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-15 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-15 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-15 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-16 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-16 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-16 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-17 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-17 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-17 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-18 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-18 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-18 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-19 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-19 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-19 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-20 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-20 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-20 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-21 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-21 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-21 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-22 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-22 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-22 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-23 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-23 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-23 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-24 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-24 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-24 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-25 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-25 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-25 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-26 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-26 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-26 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-27 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-27 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-27 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-28-1 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-28-1 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-28-1 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-28-1-3 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-28-1-3 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-28-1-3 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-28-1-4 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-28-1-4 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-28-1-4 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-28-1-5 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-28-1-5 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-28-1-5 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-28-1-6 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-28-1-6 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-28-1-6 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-28-1-7 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-28-1-7 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-28-1-7 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-28-1-8 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-28-1-8 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-28-1-8 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-28-1-9 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-28-1-9 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-28-1-9 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-28-1-10 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-28-1-10 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-28-1-10 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-28-2 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-28-2 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-28-2 + +//Test with plugin id 0 +START_TESTCASE LBS-LocationInfoConverter-2698-4-11-28-2 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-11-28-2 +END_TESTCASE LBS-LocationInfoConverter-2698-4-11-28-2 + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-29 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-29 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-29 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-30 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-30 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-30 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-31 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-31 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-31 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-32 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-32 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-32 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-33 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-33 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-33 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-34 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-34 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-34 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-35 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-35 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-35 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-36 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-36 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-36 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-37 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-37 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-37 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-38 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-38 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-38 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-39 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-39 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-39 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-40 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-40 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-40 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-41 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-41 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-41 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-42 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-42 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-42 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-43 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-43 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-43 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-44 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-44 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-44 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-45 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-45 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-45 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-46 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-46 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-46 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-47-1 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-47-1 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-47-1 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-47-2 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-47-2 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-47-2 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-47-3 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-47-3 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-47-3 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-49-1 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-49-1 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-49-1 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-49-2 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-49-2 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-49-2 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-51 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-51 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-51 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-52 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-52 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-52 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-53 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-53 +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-53 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-2-1 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-2-1 +END_TESTCASE LBS-LocationInfoConverter-2698-4-2-1 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-2-2 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-2-2 +END_TESTCASE LBS-LocationInfoConverter-2698-4-2-2 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-2-3 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-2-3 +END_TESTCASE LBS-LocationInfoConverter-2698-4-2-3 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-2-4 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-2-4 +END_TESTCASE LBS-LocationInfoConverter-2698-4-2-4 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-2-5 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-2-5 +END_TESTCASE LBS-LocationInfoConverter-2698-4-2-5 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-2-6 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-2-6 +END_TESTCASE LBS-LocationInfoConverter-2698-4-2-6 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-2-7 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-2-7 +END_TESTCASE LBS-LocationInfoConverter-2698-4-2-7 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-2-8 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-2-8 +END_TESTCASE LBS-LocationInfoConverter-2698-4-2-8 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-2-9 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-2-9 +END_TESTCASE LBS-LocationInfoConverter-2698-4-2-9 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-2-10 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-2-10 +END_TESTCASE LBS-LocationInfoConverter-2698-4-2-10 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-2-11 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-2-11 +END_TESTCASE LBS-LocationInfoConverter-2698-4-2-11 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-2-12 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-2-12 +END_TESTCASE LBS-LocationInfoConverter-2698-4-2-12 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-2-13 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-2-13 +END_TESTCASE LBS-LocationInfoConverter-2698-4-2-13 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-2-14 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-2-14 +END_TESTCASE LBS-LocationInfoConverter-2698-4-2-14 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-2-15 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-2-15 +END_TESTCASE LBS-LocationInfoConverter-2698-4-2-15 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-2-16 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-2-16 +END_TESTCASE LBS-LocationInfoConverter-2698-4-2-16 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-2-17 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-2-17 +END_TESTCASE LBS-LocationInfoConverter-2698-4-2-17 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-2-18 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-2-18 +END_TESTCASE LBS-LocationInfoConverter-2698-4-2-18 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-2-19 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-2-19 +END_TESTCASE LBS-LocationInfoConverter-2698-4-2-19 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-2-20 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-2-20 +END_TESTCASE LBS-LocationInfoConverter-2698-4-2-20 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-2-21 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-2-21 +END_TESTCASE LBS-LocationInfoConverter-2698-4-2-21 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-2-22 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-2-22 +END_TESTCASE LBS-LocationInfoConverter-2698-4-2-22 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-3-1-1 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-3-1-1 +END_TESTCASE LBS-LocationInfoConverter-2698-4-3-1-1 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-3-2-1 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-3-2-1 +END_TESTCASE LBS-LocationInfoConverter-2698-4-3-2-1 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-3-2-2 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-3-2-2 +END_TESTCASE LBS-LocationInfoConverter-2698-4-3-2-2 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-3-4 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-3-4 +END_TESTCASE LBS-LocationInfoConverter-2698-4-3-4 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-3-5 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-3-5 +END_TESTCASE LBS-LocationInfoConverter-2698-4-3-5 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-3-6 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-3-6 +END_TESTCASE LBS-LocationInfoConverter-2698-4-3-6 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-3-7 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-3-7 +END_TESTCASE LBS-LocationInfoConverter-2698-4-3-7 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-3-8 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-3-8 +END_TESTCASE LBS-LocationInfoConverter-2698-4-3-8 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-3-9 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-3-9 +END_TESTCASE LBS-LocationInfoConverter-2698-4-3-9 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-3-10 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-3-10 +END_TESTCASE LBS-LocationInfoConverter-2698-4-3-10 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-4-1 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-4-1 +END_TESTCASE LBS-LocationInfoConverter-2698-4-4-1 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-4-2 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-4-2 +END_TESTCASE LBS-LocationInfoConverter-2698-4-4-2 + + +// Not currently run, possible incorrect automated conversion (-1) +//START_TESTCASE LBS-LocationInfoConverter-2698-4-4-3 +//RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-4-3 +//END_TESTCASE LBS-LocationInfoConverter-2698-4-4-3 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-4-4 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-4-4 +END_TESTCASE LBS-LocationInfoConverter-2698-4-4-4 + +// Not currently run, possible incorrect automated conversion (panic 0) +//START_TESTCASE LBS-LocationInfoConverter-2698-4-5-1 +//RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-5-1 +//END_TESTCASE LBS-LocationInfoConverter-2698-4-5-1 + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-5-2 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-5-2 +END_TESTCASE LBS-LocationInfoConverter-2698-4-5-2 + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-1-1 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-1-1 +END_TESTCASE LBS-LocationInfoConverter-2698-5-1-1 + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-1-2 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-1-2 +END_TESTCASE LBS-LocationInfoConverter-2698-5-1-2 + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-1-3 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-1-3 +END_TESTCASE LBS-LocationInfoConverter-2698-5-1-3 + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-1-4 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-1-4 +END_TESTCASE LBS-LocationInfoConverter-2698-5-1-4 + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-1-5 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-1-5 +END_TESTCASE LBS-LocationInfoConverter-2698-5-1-5 + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-1-6 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-1-6 +END_TESTCASE LBS-LocationInfoConverter-2698-5-1-6 + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-1-7 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-1-7 +END_TESTCASE LBS-LocationInfoConverter-2698-5-1-7 + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-1-8 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-1-8 +END_TESTCASE LBS-LocationInfoConverter-2698-5-1-8 + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-1-9 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-1-9 +END_TESTCASE LBS-LocationInfoConverter-2698-5-1-9 + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-1-10 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-1-10 +END_TESTCASE LBS-LocationInfoConverter-2698-5-1-10 + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-1-11 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-1-11 +END_TESTCASE LBS-LocationInfoConverter-2698-5-1-11 + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-1-12 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-1-12 +END_TESTCASE LBS-LocationInfoConverter-2698-5-1-12 + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-1-13 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-1-13 +END_TESTCASE LBS-LocationInfoConverter-2698-5-1-13 + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-1-14 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-1-14 +END_TESTCASE LBS-LocationInfoConverter-2698-5-1-14 + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-1-15 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-1-15 +END_TESTCASE LBS-LocationInfoConverter-2698-5-1-15 + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-1-16 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-1-16 +END_TESTCASE LBS-LocationInfoConverter-2698-5-1-16 + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-1-17 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-1-17 +END_TESTCASE LBS-LocationInfoConverter-2698-5-1-17 + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-1-18 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-1-18 +END_TESTCASE LBS-LocationInfoConverter-2698-5-1-18 + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-1-19 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-1-19 +END_TESTCASE LBS-LocationInfoConverter-2698-5-1-19 + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-1-20 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-1-20 +END_TESTCASE LBS-LocationInfoConverter-2698-5-1-20 + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-1-21 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-1-21 +END_TESTCASE LBS-LocationInfoConverter-2698-5-1-21 + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-1-22 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-1-22 +END_TESTCASE LBS-LocationInfoConverter-2698-5-1-22 + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-1-23 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-1-23 +END_TESTCASE LBS-LocationInfoConverter-2698-5-1-23 + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-1-24 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-1-24 +END_TESTCASE LBS-LocationInfoConverter-2698-5-1-24 + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-1-25 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-1-25 +END_TESTCASE LBS-LocationInfoConverter-2698-5-1-25 + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-1-26 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-1-26 +END_TESTCASE LBS-LocationInfoConverter-2698-5-1-26 + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-1-27 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-1-27 +END_TESTCASE LBS-LocationInfoConverter-2698-5-1-27 + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-2-1 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-2-1 +END_TESTCASE LBS-LocationInfoConverter-2698-5-2-1 + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-2-2 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-2-2 +END_TESTCASE LBS-LocationInfoConverter-2698-5-2-2 + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-2-3 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-2-3 +END_TESTCASE LBS-LocationInfoConverter-2698-5-2-3 + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-2-4 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-2-4 +END_TESTCASE LBS-LocationInfoConverter-2698-5-2-4 + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-2-5 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-2-5 +END_TESTCASE LBS-LocationInfoConverter-2698-5-2-5 + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-2-6 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-2-6 +END_TESTCASE LBS-LocationInfoConverter-2698-5-2-6 + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-3-1 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-3-1 +END_TESTCASE LBS-LocationInfoConverter-2698-5-3-1 + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-3-2 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-3-2 +END_TESTCASE LBS-LocationInfoConverter-2698-5-3-2 + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-3-3 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-3-3 +END_TESTCASE LBS-LocationInfoConverter-2698-5-3-3 + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-3-4 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-3-4 +END_TESTCASE LBS-LocationInfoConverter-2698-5-3-4 + + +Negative test needs rewrite +//START_TESTCASE LBS-LocationInfoConverter-2698-5-4-1 +//RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-4-1 +//END_TESTCASE LBS-LocationInfoConverter-2698-5-4-1 + + +//Test with plugin id 10 +START_TESTCASE LBS-LocationInfoConverter-2698-5-4-2 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-4-2 +END_TESTCASE LBS-LocationInfoConverter-2698-5-4-2 + +////////////////////////////////////////////////////////////////// +/////////////////////////////////////////////////////////////////// +/////////////////////////////////////////////////////////////////////// +///////////////////////////////////////////////////////////////////////////// +///////////////////////////////////////////////////////////////////////////////// + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-1-1-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-1-1-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-1-1-R + +//Test with plugin id 0 +START_TESTCASE LBS-LocationInfoConverter-2698-4-2-1-1-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-2-1-1-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-2-1-1-R + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-1-3-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-1-3-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-1-3-R + +//Test with plugin id 0 +START_TESTCASE LBS-LocationInfoConverter-2698-4-2-1-3-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-2-1-3-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-2-1-3-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-1-4-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-1-4-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-1-4-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-1-5-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-1-5-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-1-5-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-1-6-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-1-6-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-1-6-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-1-7-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-1-7-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-1-7-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-1-8-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-1-8-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-1-8-R + +//Test with plugin id 0 +START_TESTCASE LBS-LocationInfoConverter-2698-4-2-1-8-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-2-1-8-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-2-1-8-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-1-9-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-1-9-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-1-9-R + +//Test with plugin id 0 +START_TESTCASE LBS-LocationInfoConverter-2698-4-2-1-9-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-2-1-9-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-2-1-9-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-1-10-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-1-10-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-1-10-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-1-11-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-1-11-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-1-11-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-1-12-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-1-12-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-1-12-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-1-13-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-1-13-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-1-13-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-2-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-2-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-2-R + +//Test with plugin id 0 +START_TESTCASE LBS-LocationInfoConverter-2698-4-11-2-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-11-2-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-11-2-R + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-3-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-3-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-3-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-4-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-4-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-4-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-5-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-5-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-5-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-6-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-6-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-6-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-7-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-7-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-7-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-8-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-8-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-8-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-9-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-9-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-9-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-10-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-10-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-10-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-11-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-11-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-11-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-12-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-12-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-12-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-13-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-13-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-13-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-14-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-14-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-14-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-15-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-15-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-15-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-16-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-16-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-16-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-17-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-17-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-17-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-18-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-18-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-18-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-19-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-19-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-19-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-20-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-20-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-20-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-21-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-21-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-21-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-22-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-22-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-22-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-23-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-23-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-23-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-24-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-24-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-24-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-25-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-25-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-25-R + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-28-1-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-28-1-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-28-1-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-28-1-3-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-28-1-3-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-28-1-3-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-28-1-4-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-28-1-4-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-28-1-4-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-28-1-5-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-28-1-5-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-28-1-5-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-28-1-6-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-28-1-6-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-28-1-6-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-28-1-7-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-28-1-7-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-28-1-7-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-28-1-8-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-28-1-8-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-28-1-8-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-28-1-9-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-28-1-9-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-28-1-9-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-28-1-10-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-28-1-10-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-28-1-10-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-28-2-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-28-2-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-28-2-R + +//Test with plugin id 0 +START_TESTCASE LBS-LocationInfoConverter-2698-4-11-28-2-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-11-28-2-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-11-28-2-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-29-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-29-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-29-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-30-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-30-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-30-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-31-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-31-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-31-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-32-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-32-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-32-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-33-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-33-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-33-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-34-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-34-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-34-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-35-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-35-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-35-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-36-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-36-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-36-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-37-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-37-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-37-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-38-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-38-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-38-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-39-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-39-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-39-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-40-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-40-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-40-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-41-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-41-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-41-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-42-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-42-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-42-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-43-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-43-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-43-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-44-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-44-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-44-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-45-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-45-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-45-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-46-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-46-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-46-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-47-1-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-47-1-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-47-1-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-47-2-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-47-2-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-47-2-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-47-3-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-47-3-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-47-3-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-49-1-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-49-1-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-49-1-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-49-2-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-49-2-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-49-2-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-1-51-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-1-51-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-1-51-R + +START_TESTCASE LBS-LocationInfoConverter-2698-4-2-1-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-2-1-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-2-1-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-2-2-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-2-2-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-2-2-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-2-3-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-2-3-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-2-3-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-2-4-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-2-4-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-2-4-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-2-5-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-2-5-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-2-5-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-2-6-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-2-6-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-2-6-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-2-7-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-2-7-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-2-7-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-2-8-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-2-8-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-2-8-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-2-9-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-2-9-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-2-9-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-2-10-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-2-10-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-2-10-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-2-11-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-2-11-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-2-11-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-2-12-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-2-12-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-2-12-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-2-13-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-2-13-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-2-13-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-2-14-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-2-14-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-2-14-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-2-15-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-2-15-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-2-15-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-2-16-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-2-16-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-2-16-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-2-17-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-2-17-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-2-17-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-2-18-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-2-18-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-2-18-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-2-19-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-2-19-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-2-19-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-2-20-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-2-20-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-2-20-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-2-21-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-2-21-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-2-21-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-2-22-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-2-22-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-2-22-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-3-1-1-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-3-1-1-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-3-1-1-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-3-2-1-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-3-2-1-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-3-2-1-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-3-2-2-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-3-2-2-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-3-2-2-R + +START_TESTCASE LBS-LocationInfoConverter-2698-4-3-7-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-3-7-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-3-7-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-3-8-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-3-8-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-3-8-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-3-9-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-3-9-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-3-9-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-3-10-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-3-10-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-3-10-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-5-1-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-5-1-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-5-1-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-4-5-2-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-4-5-2-R +END_TESTCASE LBS-LocationInfoConverter-2698-4-5-2-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-1-1-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-1-1-R +END_TESTCASE LBS-LocationInfoConverter-2698-5-1-1-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-1-2-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-1-2-R +END_TESTCASE LBS-LocationInfoConverter-2698-5-1-2-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-1-3-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-1-3-R +END_TESTCASE LBS-LocationInfoConverter-2698-5-1-3-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-1-4-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-1-4-R +END_TESTCASE LBS-LocationInfoConverter-2698-5-1-4-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-1-5-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-1-5-R +END_TESTCASE LBS-LocationInfoConverter-2698-5-1-5-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-1-6-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-1-6-R +END_TESTCASE LBS-LocationInfoConverter-2698-5-1-6-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-1-9-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-1-9-R +END_TESTCASE LBS-LocationInfoConverter-2698-5-1-9-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-1-10-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-1-10-R +END_TESTCASE LBS-LocationInfoConverter-2698-5-1-10-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-1-11-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-1-11-R +END_TESTCASE LBS-LocationInfoConverter-2698-5-1-11-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-1-12-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-1-12-R +END_TESTCASE LBS-LocationInfoConverter-2698-5-1-12-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-1-13-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-1-13-R +END_TESTCASE LBS-LocationInfoConverter-2698-5-1-13-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-1-14-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-1-14-R +END_TESTCASE LBS-LocationInfoConverter-2698-5-1-14-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-1-15-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-1-15-R +END_TESTCASE LBS-LocationInfoConverter-2698-5-1-15-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-1-16-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-1-16-R +END_TESTCASE LBS-LocationInfoConverter-2698-5-1-16-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-1-17-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-1-17-R +END_TESTCASE LBS-LocationInfoConverter-2698-5-1-17-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-1-18-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-1-18-R +END_TESTCASE LBS-LocationInfoConverter-2698-5-1-18-R + +START_TESTCASE LBS-LocationInfoConverter-2698-5-1-21-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-1-21-R +END_TESTCASE LBS-LocationInfoConverter-2698-5-1-21-R + +START_TESTCASE LBS-LocationInfoConverter-2698-5-1-24-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-1-24-R +END_TESTCASE LBS-LocationInfoConverter-2698-5-1-24-R + +START_TESTCASE LBS-LocationInfoConverter-2698-5-2-1-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-2-1-R +END_TESTCASE LBS-LocationInfoConverter-2698-5-2-1-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-2-2-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-2-2-R +END_TESTCASE LBS-LocationInfoConverter-2698-5-2-2-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-2-3-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-2-3-R +END_TESTCASE LBS-LocationInfoConverter-2698-5-2-3-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-2-5-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-2-5-R +END_TESTCASE LBS-LocationInfoConverter-2698-5-2-5-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-2-6-R +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-2-6-R +END_TESTCASE LBS-LocationInfoConverter-2698-5-2-6-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-3-1-R +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-3-1-R +END_TESTCASE LBS-LocationInfoConverter-2698-5-3-1-R + + +START_TESTCASE LBS-LocationInfoConverter-2698-5-3-2 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-3-2 +END_TESTCASE LBS-LocationInfoConverter-2698-5-3-2 + +//Test with plugin id 10 +START_TESTCASE LBS-LocationInfoConverter-2698-5-4-2-R +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-4-2-R +END_TESTCASE LBS-LocationInfoConverter-2698-5-4-2-R + +START_TESTCASE LBS-LocationInfoConverter-SetAndGetConversionPrefs-1 +RUN_TEST_STEP 10 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini SetAndGetConversionPrefs-1 +END_TESTCASE LBS-LocationInfoConverter-SetAndGetConversionPrefs-1 + +//Delete the cenrep file out of the way to test behaviour when it's not found +RUN_UTILS DeleteFile c:\private\10202be9\20026814.txt + +//Test with plugin id 0 +START_TESTCASE LBS-LocationInfoConverter-2698-5-4-3 +RUN_TEST_STEP 100 te_lbslocationinfoconvertersuite Step c:\testdata\configs\LbsLocationInfoConverter.ini 2698-5-4-3 +END_TESTCASE LBS-LocationInfoConverter-2698-5-4-3 + +// now wait for loc monitor to teminate (which it will do after 10 seconds - +// this ensures that we pick up any memory leaks detected when the heap is checked in +// the loc monitor's destructor. If we don't have this delay then you will not see +// any heap check panics! + +PRINT now wait for loc monitor to teminate (which it will do after 10 seconds +PRINT this ensures that we pick up any memory leaks detected when the heap is checked in +PRINT the loc monitor's destructor. If we don't have this delay then you will not see any heap check panics! + + +DELAY 12000 + + + diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/te_lbslocationinforconvertertef/src/Te_locationinfoconversionobserver.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/te_lbslocationinforconvertertef/src/Te_locationinfoconversionobserver.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,101 @@ +/* +* Copyright (c) 2002 - 2007 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Test module to implement Advanced trigger supervision cases +* +*/ + + + +// INCLUDE FILES +#include +#include "Te_locationinfoconversionobserver.h" + + + + +// ============================ MEMBER FUNCTIONS =============================== + +// ----------------------------------------------------------------------------- +// CTriggerFireObserver::CTriggerFireObserver +// C++ default constructor can NOT contain any code, that +// might leave. +// ----------------------------------------------------------------------------- +// +CTelocationinfoconversionobserver::CTelocationinfoconversionobserver( ):CTimer( CTimer::EPriorityStandard ) + { + + CActiveScheduler::Add(this); + } + +// ----------------------------------------------------------------------------- +// CTriggerFireObserver::ConstructL +// Symbian 2nd phase constructor can leave. +// ----------------------------------------------------------------------------- +// +void CTelocationinfoconversionobserver::ConstructL() + { + iStatusCode=KErrGeneral; + CTimer::ConstructL(); + + } + +// ----------------------------------------------------------------------------- +// CTriggerFireObserver::NewL +// Two-phased constructor. +// ----------------------------------------------------------------------------- +// +CTelocationinfoconversionobserver* CTelocationinfoconversionobserver::NewL( ) + { + + CTelocationinfoconversionobserver* self = new (ELeave) CTelocationinfoconversionobserver( ); + CleanupStack::PushL( self ); + self->ConstructL( ); + CleanupStack::Pop(); + return self; + + } + +// Destructor +CTelocationinfoconversionobserver::~CTelocationinfoconversionobserver() + { + Cancel(); + } + +void CTelocationinfoconversionobserver::OnConversionComplete( TInt aStatusCode ) + { + iStatusCode = aStatusCode; + CActiveScheduler::Stop(); + } + +TInt CTelocationinfoconversionobserver::ConversionResult() + { + return iStatusCode; + } + + + +void CTelocationinfoconversionobserver::RunL( ) + { + iStatusCode = KErrCancel; + CActiveScheduler::Stop(); + + } + +void CTelocationinfoconversionobserver::DoCancel( ) + { + + + } + +//End of file diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/te_lbslocationinforconvertertef/src/Te_locationresolverobserver.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/te_lbslocationinforconvertertef/src/Te_locationresolverobserver.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,137 @@ +/* +* Copyright (c) 2002 - 2007 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Test module to implement Advanced trigger supervision cases +* +*/ + + + +// INCLUDE FILES +#include +#include "Te_locationresolverobserver.h" + +// ============================ MEMBER FUNCTIONS =============================== + +// ----------------------------------------------------------------------------- +// CTriggerFireObserver::CTriggerFireObserver +// C++ default constructor can NOT contain any code, that +// might leave. +// ----------------------------------------------------------------------------- +// +CTeLocationResolverObserver::CTeLocationResolverObserver( ):CTimer( CTimer::EPriorityStandard ) + { + + CActiveScheduler::Add(this); + } + +// ----------------------------------------------------------------------------- +// CTriggerFireObserver::ConstructL +// Symbian 2nd phase constructor can leave. +// ----------------------------------------------------------------------------- +// +void CTeLocationResolverObserver::ConstructL() + { + iStatusCode=KErrGeneral; + CTimer::ConstructL(); + } + +// ----------------------------------------------------------------------------- +// CTriggerFireObserver::NewL +// Two-phased constructor. +// ----------------------------------------------------------------------------- +// +CTeLocationResolverObserver* CTeLocationResolverObserver::NewL( ) + { + + CTeLocationResolverObserver* self = new (ELeave) CTeLocationResolverObserver( ); + CleanupStack::PushL( self ); + self->ConstructL( ); + CleanupStack::Pop(); + return self; + + } + +// Destructor +CTeLocationResolverObserver::~CTeLocationResolverObserver() + { + Cancel(); + } + + +void CTeLocationResolverObserver::OnResolveLocationComplete(TInt aStatus, const TLocality& aLocality) + { + iStatusCode = aStatus; + + if (iStatusCode == KErrNone) + { + TReal64 lat = aLocality.Latitude(); + TReal64 lng = aLocality.Longitude(); + TReal32 alt =aLocality.Altitude(); + TPositionDatumId datum = aLocality.Datum(); + TReal32 horAcc = aLocality.HorizontalAccuracy(); + TReal32 vertAcc = aLocality.VerticalAccuracy(); + + iLocality = aLocality; + + // the horAcc is interesting ... + // when the locality is not delivered from the cache then the hor acc is that returned by the test plugin + // when it comes out of the cahche then it's the loc monitor that sets it according to + // the country code e.t.c + // similarly for the vertical accuracy ... its set to Nan when brought out of the cache + // but its whatever came from the converter otherwise. + + + // this test ensures that when a locality comes out of the cash that + // vertical accuracy is a Nan. So we can use this to check that + // values come out of the cache when they should. + if (Math::IsNaN(vertAcc)) + { + iFromCache = ETrue; + } + else + { + iFromCache = EFalse; + } + } + CActiveScheduler::Stop(); + } + + + +TInt CTeLocationResolverObserver::ConversionResult() + { + return iStatusCode; + } + +TInt CTeLocationResolverObserver::ConversionLocality(TLocality& aLocality) + { + aLocality = iLocality; + return iFromCache; + } + + +void CTeLocationResolverObserver::RunL( ) + { + iStatusCode = KErrCancel; + CActiveScheduler::Stop(); + + } + +void CTeLocationResolverObserver::DoCancel( ) + { + + + } + +//End of file diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/te_lbslocationinforconvertertef/src/step.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/te_lbslocationinforconvertertef/src/step.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,5112 @@ +/* +* Copyright (c) 2007 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ + +#include "step.h" +#include "te_lbslocationinfoconvertersuitedefs.h" + +#include "Te_locationinfoconversionobserver.h" + +#include + +// the test code sets the timing advance in the GSM vell info to this value +// which instructs the test converter to constuct TLocalitys with +// latitude ser to country code, longitude set to +// network code and altitiude set to local area code +const TInt KTimingAdvanceSpecialValue= 254; + +const TInt KTimingAdvanceSaveToCacheTrue= 253; + +const TInt KTimingAdvanceSaveToCacheFalse= 252; + +CStep::~CStep() +/** + * Destructor + */ + { + + } + +CStep::CStep() +/** + * Constructor + */ + { + SetTestStepName(KStep); + } + +TVerdict CStep::doTestStepPreambleL() +/** + * @return - TVerdict code + * Override of base class virtual + */ + { + CTe_LbsLocationInfoConverterSuiteStepBase::doTestStepPreambleL(); + return TestStepResult(); + } + + +TVerdict CStep::doTestStepL() +/** + * @return - TVerdict code + * This test check that KErrArgument is returned when calling the Get function for the + * KLbsSpecialFeatureMaximumRequestDelay entry with an out of range delay value. + */ + { + TInt id = GetTestCaseId(); + iApiId = GetTestCaseApi(); + iPluginUid = GetPluginUid(); + + __UHEAP_MARK; + CallL(id); + __UHEAP_MARKEND; + return TestStepResult(); + } + + + +TVerdict CStep::doTestStepPostambleL() +/** + * @return - TVerdict code + */ + { + + return TestStepResult(); + } + + + + + + + +// ----------------------------------------------------------------------------- +// CStep::CreateLocationInfoConverterL +// Creates and initializes Location info converter object +// (other items were commented in a header). +// ----------------------------------------------------------------------------- +// +TInt CStep::CreateLocationInfoConverterL() + { + TUid uid = TUid::Uid(iPluginUid); + iLbsLocationInfo = CLbsLocationInfo::NewL(); + + if(iApiId == 0) + { + iObserver = CTelocationinfoconversionobserver::NewL(); + iObserver->Version(); + if(iPluginUid!=0) + { + iLbsLocationInfoConverter = CLbsLocationInfoConverter::NewL(*iObserver,uid); + } + else + { + iLbsLocationInfoConverter = CLbsLocationInfoConverter::NewL(*iObserver); + } + } + else + { + iResolverObserver = CTeLocationResolverObserver::NewL(); + iResolverObserver->Version(); + if(iPluginUid!=0) + { + iLbsLocationResolver = CLbsLocationResolver::NewL(*iResolverObserver,uid); + } + else + { + iLbsLocationResolver = CLbsLocationResolver::NewL(*iResolverObserver); + } + } + + return KErrNone; + + } + +//// ----------------------------------------------------------------------------- +//// CStep::SetCoordinateInfoL +//// Converts one location info to its corresponding position info. +//// (other items were commented in a header). +//// ----------------------------------------------------------------------------- +//// +//TInt CStep::SetCoordinateInfoL(CStifItemParser& aItem ) +// { +// TInt fntype; +// aItem.GetNextInt(fntype); +// TPtrC Llatidude,Llongitude,Laltidude,Lhoracc,LVerAcc; +// aItem.GetNextString( KLatitude, Llatidude); +// aItem.GetNextString( KLongitude, Llongitude); +// aItem.GetNextString( KAltitude, Laltidude); +// aItem.GetNextString( KHorizontalAccuracy, Lhoracc); +// aItem.GetNextString( KVerticalAccuracy, LVerAcc); +// +// TReal64 latitude =0 ; +// TLex16 lat(Llatidude); +// lat.Val(latitude); +// +// TReal64 longitude =0; +// TLex16 longi(Llongitude); +// longi.Val(longitude); +// +// TReal32 Altitude =0; +// TLex16 Alt(Laltidude); +// Alt.Val(Altitude); +// +// TReal32 HorizontalAccuracy =0; +// TLex16 HA(Lhoracc); +// HA.Val(HorizontalAccuracy); +// +// TReal32 VerticalAccuracy =0; +// TLex16 VA(LVerAcc); +// VA.Val(VerticalAccuracy); +// TLocality Locality; +// if(latitude!=0 && longitude!=0 && Altitude==0) +// { +// Locality.SetCoordinate(latitude,longitude); +// } +// else if (latitude!=0 && longitude!=0 && Altitude!=0) +// { +// Locality.SetCoordinate(latitude,longitude,Altitude); +// } +// +// +// if(HorizontalAccuracy!=0 ) +// { +// Locality.SetHorizontalAccuracy(HorizontalAccuracy); +// } +// if(VerticalAccuracy!=0 ) +// { +// Locality.SetVerticalAccuracy(VerticalAccuracy); +// } +// +// CLbsPositionInfo* Posinfo; +// if(fntype==1) +// { +// Posinfo=CLbsPositionInfo::NewL( Locality); +// } +// else if(fntype==2) +// { +// Posinfo=CLbsPositionInfo::NewL(); +// Posinfo->SetLocality(Locality); +// } +// +// ilbslocationinfo->AddAreaInfoL(Posinfo); +// return KErrNone; +// } + + +// ----------------------------------------------------------------------------- +// CStep::SetGSMCellInfoL +// . +// (other items were commented in a header). +// ----------------------------------------------------------------------------- +// +void CStep::SetGSMCellInfoL( TInt fntype, TInt countrycode, TInt networkcode, + TInt locationcode, TInt cellid, TInt timingadvance, TInt Rxlev, TInt nNeignbourcells, + TInt arfcn, TInt bsic, TInt NRxlev) + { + INFO_PRINTF5(_L("SetGSMCellInfoL(CC=%d, NC=%d, LC=%d CID=%d)"),countrycode,networkcode,locationcode,cellid); + CLbsGsmCellInfo* gsmcellinfo; + if(fntype==1) + { + gsmcellinfo=CLbsGsmCellInfo::NewL( countrycode,networkcode,locationcode,cellid); + if(timingadvance!=-2) + { + gsmcellinfo->SetTimingAdvance(timingadvance); + } + if(Rxlev!=-2) + { + gsmcellinfo->SetRxLevel(Rxlev); + } + if(nNeignbourcells!=0) + { + TLbsGsmNeighbourCellInfo neighbourcell; + for(TInt i =0 ; iAddNeighbouringCellInfoL(&neighbourcell); + + } + } + } + else if(fntype==2) + { + gsmcellinfo=CLbsGsmCellInfo::NewL(); + if(countrycode!=-2) + { + gsmcellinfo->SetMobileCountryCode(countrycode); + } + if(networkcode!=-2) + { + gsmcellinfo->SetMobileNetworkCode(networkcode); + } + if(locationcode!=-2) + { + gsmcellinfo->SetLocationAreaCode(locationcode); + } + if(cellid!=-2) + { + gsmcellinfo->SetCellId(cellid); + } + if(timingadvance!=-2) + { + gsmcellinfo->SetTimingAdvance(timingadvance); + } + if(Rxlev!=-2) + { + gsmcellinfo->SetRxLevel(Rxlev); + } + if(nNeignbourcells!=0) + { + + + for(TInt i =0 ; iAddNeighbouringCellInfoL(&neighbourcell); + + } + } + } + + iLbsLocationInfo->AddAreaInfoL(gsmcellinfo); + + } + +TInt CStep::SetGSMCellInfo2L( TInt fntype, TInt countrycode, TInt networkcode, + TInt locationcode, TInt cellid, TInt timingadvance, TInt Rxlev, TInt nNeignbourcells, + TInt arfcn, TInt bsic, TInt NRxlev) + { + INFO_PRINTF5(_L("SetGSMCellInfo2L(CC=%d, NC=%d, LC=%d CID=%d)"),countrycode,networkcode,locationcode,cellid); + + CLbsGsmCellInfo* gsmcellinfo; + if(fntype==1) + { + gsmcellinfo=CLbsGsmCellInfo::NewL( countrycode,networkcode,locationcode,cellid); + if(timingadvance!=-2) + { + gsmcellinfo->SetTimingAdvance(timingadvance); + } + if(Rxlev!=-2) + { + gsmcellinfo->SetRxLevel(Rxlev); + } + if(nNeignbourcells!=0) + { + TLbsGsmNeighbourCellInfo neighbourcell; + for(TInt i =0 ; iAddNeighbouringCellInfoL(&neighbourcell); + + } + } + } + else if(fntype==2) + { + gsmcellinfo=CLbsGsmCellInfo::NewL(); + if(countrycode!=-2) + { + gsmcellinfo->SetMobileCountryCode(countrycode); + } + if(networkcode!=-2) + { + gsmcellinfo->SetMobileNetworkCode(networkcode); + } + if(locationcode!=-2) + { + gsmcellinfo->SetLocationAreaCode(locationcode); + } + if(cellid!=-2) + { + gsmcellinfo->SetCellId(cellid); + } + if(timingadvance!=-2) + { + gsmcellinfo->SetTimingAdvance(timingadvance); + } + if(Rxlev!=-2) + { + gsmcellinfo->SetRxLevel(Rxlev); + } + if(nNeignbourcells!=0) + { + + + for(TInt i =0 ; iAddNeighbouringCellInfoL(&neighbourcell); + + } + } + } + + iLbsLocationInfo2->AddAreaInfoL(gsmcellinfo); + return KErrNone; + } +// ----------------------------------------------------------------------------- +// CStep::SetWCDMACellInfoL +// . +// (other items were commented in a header). +// ----------------------------------------------------------------------------- +// +TInt CStep::SetWCDMACellInfoL(TInt fntype, TInt countrycode, + TInt networkcode, TInt cellid, TInt nNeignbourcells, TInt scramblingcode, + TInt neighbourucid, TInt neighbourscode, TInt neighbourpathloss, + TInt neighboursignalstrength) + { + CLbsWcdmaCellInfo* wcdmacellinfo; + if(fntype==1) + { + wcdmacellinfo=CLbsWcdmaCellInfo::NewL( countrycode,networkcode,cellid); + if(scramblingcode!=-2) + { + wcdmacellinfo->SetScramblingCode(scramblingcode); + } + if(nNeignbourcells!=0) + { + TLbsWcdmaNeighbourCellInfo neighbourcell; + for(TInt i =0 ; iAddNeighbouringCellInfoL(&neighbourcell); + } + } + } + else if(fntype==2) + { + wcdmacellinfo=CLbsWcdmaCellInfo::NewL(); + if(countrycode!=-2) + { + wcdmacellinfo->SetMobileCountryCode(countrycode); + } + if(networkcode!=-2) + { + wcdmacellinfo->SetMobileNetworkCode(networkcode); + } + if(cellid!=-2) + { + wcdmacellinfo->SetUniqueCellId(cellid); + } + if(scramblingcode!=-2) + { + wcdmacellinfo->SetScramblingCode(scramblingcode); + } + if(nNeignbourcells!=0) + { + for(TInt i =0 ; iAddNeighbouringCellInfoL(&neighbourcell); + } + } + } + + iLbsLocationInfo->AddAreaInfoL(wcdmacellinfo); + return KErrNone; + } + +// ----------------------------------------------------------------------------- +// CStep::SetWLanInfoL +// . +// (other items were commented in a header). +// ----------------------------------------------------------------------------- +// +TInt CStep::SetWLanInfoL(TInt fntype, TInt macidint, TInt signalstrength) + { + TBuf8<6> macidbuf; + macidbuf.AppendNum(macidint); + CLbsWlanInfo* wlaninfo; + if(fntype==1) + { + wlaninfo=CLbsWlanInfo::NewL( macidbuf,signalstrength); + } + else if(fntype==2) + { + wlaninfo=CLbsWlanInfo::NewL(); + if (macidbuf.Length()!=0) + { + wlaninfo->SetMacAddress(macidbuf); + } + if(signalstrength!=-2) + { + wlaninfo->SetSignalStrength(signalstrength); + } + } + iLbsLocationInfo->AddAreaInfoL(wlaninfo); + return KErrNone; + } +// ----------------------------------------------------------------------------- +// CStep::AddLocationInfoL +// Converts one location info to its corresponding position info. +// (other items were commented in a header). +// ----------------------------------------------------------------------------- +// +void CStep::AddLocationInfoL() + { + TInt nTimes =1; + iLbsLocationInfoArrayTemp.Append(iLbsLocationInfo); + for (TInt i=0 ; iConvertLocationInfoL(*iLbsLocationInfoArray[0],conversionprefs,requestedinfo); + } + else if (fntype==2) + { + iLbsLocationInfoConverter->ConvertLocationInfoL(iLbsLocationInfoArray,conversionprefs,requestedinfo); + } + } + else + { + CLbsLocationInfo* input = static_cast(iLbsLocationInfoArray[0]); + iLbsLocationResolver->ResolveLocationL(*input); + } + + CActiveScheduler::Start(); + + } + +void CStep::ConvertLocationInfo2L(TInt conversionprefs, TInt requestedinfo, TInt fntype) + { + + if(iApiId == 0) + { + if(fntype==0) + { + iLbsLocationInfoConverter2->ConvertLocationInfoL(*iLbsLocationInfoArray2[0],conversionprefs,requestedinfo); + } + else if (fntype==2) + { + iLbsLocationInfoConverter2->ConvertLocationInfoL(iLbsLocationInfoArray2,conversionprefs,requestedinfo); + } + } + else + { + CLbsLocationInfo* input = static_cast(iLbsLocationInfoArray2[0]); + iLbsLocationResolver2->ResolveLocationL(*input); + } + + CActiveScheduler::Start(); + + } +// ----------------------------------------------------------------------------- +// CStep::CancelConvertLocationInfo +// Converts one location info to its corresponding position info. +// (other items were commented in a header). +// ----------------------------------------------------------------------------- +// +TInt CStep::MiscL(TInt testcase) + { + switch(testcase) + { + case 1: + if(iApiId == 0) + { + iLbsLocationInfoConverter->ConvertLocationInfoL(*iLbsLocationInfo,0,1); + iLbsLocationInfoConverter->CancelConvertLocationInfo(); + iObserver->After(1500000); + CActiveScheduler::Start(); + } + else + { + CLbsLocationInfo* input = static_cast(iLbsLocationInfoArray[0]); + iLbsLocationResolver->ResolveLocationL(*input); + iLbsLocationResolver->CancelResolveLocation(); + iResolverObserver->After(1500000); + CActiveScheduler::Start(); + } + break; + case 2: + if(iApiId == 0) + { + iLbsLocationInfoConverter->ConvertLocationInfoL(*iLbsLocationInfo,0,1); + CActiveScheduler::Start(); + iLbsLocationInfoConverter->CancelConvertLocationInfo(); + } + else + { + CLbsLocationInfo* input = static_cast(iLbsLocationInfoArray[0]); + iLbsLocationResolver->ResolveLocationL(*input); + CActiveScheduler::Start(); + iLbsLocationResolver->CancelResolveLocation(); + } + break; + case 3: + if(iApiId == 0) + { + iLbsLocationInfoConverter->CancelConvertLocationInfo(); + return KErrNone; + } + else + { + iLbsLocationResolver->CancelResolveLocation(); + return KErrNone; + } + break; + case 4: +// TODO +// TestModuleIf().SetExitReason( CTestModuleIf::EPanic, 0); + if(iApiId == 0) + { + iLbsLocationInfoConverter->ConvertLocationInfoL(*iLbsLocationInfo,0,1); + iLbsLocationInfoConverter->ConvertLocationInfoL(*iLbsLocationInfo,0,1); + } + else + { + CLbsLocationInfo* input = static_cast(iLbsLocationInfoArray[0]); + iLbsLocationResolver->ResolveLocationL(*input); + iLbsLocationResolver->ResolveLocationL(*input); + } + break; + case 5: + if(iApiId == 0) + { + iLbsLocationInfoConverter->ConvertLocationInfoL(iLbsLocationInfoArray,0,1); + iLbsLocationInfoConverter->CancelConvertLocationInfo(); + iObserver->After(1500000); + CActiveScheduler::Start(); + } + else + { + CLbsLocationInfo* input = static_cast(iLbsLocationInfoArray[0]); + iLbsLocationResolver->ResolveLocationL(*input); + iLbsLocationResolver->CancelResolveLocation(); + iResolverObserver->After(1500000); + CActiveScheduler::Start(); + } + break; + case 6: + if(iApiId == 0) + { + iLbsLocationInfoConverter->ConvertLocationInfoL(iLbsLocationInfoArray,0,1); + CActiveScheduler::Start(); + iLbsLocationInfoConverter->CancelConvertLocationInfo(); + } + else + { + CLbsLocationInfo* input = static_cast(iLbsLocationInfoArray[0]); + iLbsLocationResolver->ResolveLocationL(*input); + CActiveScheduler::Start(); + iLbsLocationResolver->CancelResolveLocation(); + } + break; + case 7: + if(iApiId == 0) + { + iLbsLocationInfoConverter->CancelConvertLocationInfo(); + return KErrNone; + } + else + { + iLbsLocationResolver->CancelResolveLocation(); + return KErrNone; + } + break; + case 8: + if(iApiId == 0) + { + iLbsLocationInfoConverter->ConvertLocationInfoL(iLbsLocationInfoArray,0,1); + iLbsLocationInfoConverter->ConvertLocationInfoL(iLbsLocationInfoArray,0,1); + } + else + { + CLbsLocationInfo* input = static_cast(iLbsLocationInfoArray[0]); + iLbsLocationResolver->ResolveLocationL(*input); + iLbsLocationResolver->ResolveLocationL(*input); + } + break; + } + + if(iApiId == 0) + { + return iObserver->ConversionResult(); + } + else + { + return iResolverObserver->ConversionResult(); + } + } + + + +TInt CStep::ValidateLocationInfo(TInt requestedinfo) + { + if(iApiId == 0) + { + if( iObserver->ConversionResult() == KErrNone ) + { + if(requestedinfo ==1) + { + TInt count = iLbsLocationInfoArray.Count(); + for(TInt i=0; i PosInfoList; + TRAPD(error, static_cast(iLbsLocationInfoArray[i])->GetAreaInfoL(PosInfoList,CLbsLocationInfo::ELbsPosInfo)); + if (KErrNone != error) + { + PosInfoList.ResetAndDestroy(); + PosInfoList.Close(); + return error; + } + TInt count2 = PosInfoList.Count(); + PosInfoList.ResetAndDestroy(); + PosInfoList.Close(); + if(count2>=1) + { + return KErrNone; + } + } + } + } + + return iObserver->ConversionResult(); + } + else + { + if( iResolverObserver->ConversionResult() == KErrNone ) + { + if(requestedinfo ==1) + { + TInt count = iLbsLocationInfoArray.Count(); + for(TInt i=0; i PosInfoList; + TRAPD(error, static_cast(iLbsLocationInfoArray[i])->GetAreaInfoL(PosInfoList,CLbsLocationInfo::ELbsPosInfo)); + if (KErrNone != error) + { + PosInfoList.ResetAndDestroy(); + PosInfoList.Close(); + return error; + } + TInt count2 = PosInfoList.Count(); + PosInfoList.ResetAndDestroy(); + PosInfoList.Close(); + if(count2>=1) + { + return KErrNone; + } + } + } + } + return iResolverObserver->ConversionResult(); + } + } + + +TInt CStep::ValidateLocationInfo2(TInt requestedinfo) + { + if(iApiId == 0) + { + if( iObserver2->ConversionResult() == KErrNotSupported || + iObserver2->ConversionResult() == KErrNotFound ) + return KErrNone; + + if( iObserver2->ConversionResult() == KErrNone ) + { + if(requestedinfo ==1) + { + TInt count = iLbsLocationInfoArray2.Count(); + for(TInt i=0; i PosInfoList; + static_cast(iLbsLocationInfoArray2[i])->GetAreaInfoL(PosInfoList,CLbsLocationInfo::ELbsPosInfo); + TInt count2 = PosInfoList.Count(); + PosInfoList.ResetAndDestroy(); + PosInfoList.Close(); + if(count2>=1) + { + return KErrNone; + } + } + return KErrGeneral; + } + } + + return iObserver2->ConversionResult(); + } + else + { + if( iResolverObserver2->ConversionResult() == KErrNotSupported || + iResolverObserver2->ConversionResult() == KErrNotFound ) + return KErrNone; + + if( iResolverObserver2->ConversionResult() == KErrNone ) + { + if(requestedinfo ==1) + { + TInt count = iLbsLocationInfoArray2.Count(); + for(TInt i=0; i PosInfoList; + static_cast(iLbsLocationInfoArray2[i])->GetAreaInfoL(PosInfoList,CLbsLocationInfo::ELbsPosInfo); + TInt count2 = PosInfoList.Count(); + PosInfoList.ResetAndDestroy(); + PosInfoList.Close(); + if(count2>=1) + { + return KErrNone; + } + } + } + } + return iResolverObserver->ConversionResult(); + } + } + + +// ----------------------------------------------------------------------------- +// CStep::SetConversionPrefs +// Converts one location info to its corresponding position info. +// (other items were commented in a header). +// ----------------------------------------------------------------------------- +// +TInt CStep::SetConversionPrefs(TLbsConversionPrefs aSetConversionPrefs) + { + TRAPD( err, + if(iApiId != 0) + { + err = iLbsLocationResolver->SetConversionPreferences(aSetConversionPrefs); + } + ) + + if (err) + return err; + else + return KErrNone; + } + + +// ----------------------------------------------------------------------------- +// CStep::GetAndCheckConversionPrefs +// Converts one location info to its corresponding position info. +// (other items were commented in a header). +// ----------------------------------------------------------------------------- +// +TInt CStep::GetAndCheckConversionPrefs(TLbsConversionPrefs aSetConversionPrefs) + { + TRAPD( err, + if(iApiId != 0) + { + TLbsConversionPrefs readConversionPrefs = iLbsLocationResolver->ConversionPreferences(); + if (readConversionPrefs != aSetConversionPrefs) + { + err = KErrGeneral; + } + } + ) + if (err) + return err; + else + return KErrNone; + } + + + +TInt CStep::Cleanup() + { + if(iLbsLocationInfo) + { + delete iLbsLocationInfo; + iLbsLocationInfo = NULL; + } + if(iLbsLocationInfoConverter) + { + delete iLbsLocationInfoConverter; + iLbsLocationInfoConverter = NULL; + } + if(iLbsLocationResolver) + { + delete iLbsLocationResolver; + iLbsLocationResolver = NULL; + } + if(iObserver) + { + delete iObserver; + iObserver = NULL; + } + if(iResolverObserver) + { + delete iResolverObserver; + iResolverObserver = NULL; + } + iLbsLocationInfoArrayTemp.ResetAndDestroy(); + iLbsLocationInfoArray.Reset(); + + return KErrNone; + } + +void CStep::test_2698_4_1_1_1L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 404, 49, 16, 7141); + + AddLocationInfoL(); + + TRAP(err,ConvertLocationInfoL(1, 1, 0)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_1_3L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 0, 0, 0, 0); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_1_4L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 999, 999, 65535, 65535); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_1_5L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, -1, 0, 0, 0); + + AddLocationInfoL(); + + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_1_6L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, -1, 0, 0); + + AddLocationInfoL(); + + TRAP (err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_1_7L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, -1, 0); + + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP (err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_1_8L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, -1); + + AddLocationInfoL(); + + TRAP (err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_1_9L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 1000, 0, 0, 0); + + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_1_10L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 1000, 0, 0); + + AddLocationInfoL(); + + TRAP (err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_1_11L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 65536, 0); + + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_1_12L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 65536); + + AddLocationInfoL(); + + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_1_13L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(2, 100, 200, 300, 30); + + AddLocationInfoL(); + + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_2L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(2, 100); + + AddLocationInfoL(); + + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_3L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(2, 999); + + AddLocationInfoL(); + + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_4L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(2, 0); + + AddLocationInfoL(); + + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_5L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(2, 1000); + + AddLocationInfoL(); + + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_6L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(2, -1); + + AddLocationInfoL(); + + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_7L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(2, 100, 200); + + AddLocationInfoL(); + + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_8L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(2, 100, 999); + + AddLocationInfoL(); + + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_9L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(2, 100, 0); + + AddLocationInfoL(); + + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_10L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(2, 100, 1000); + + AddLocationInfoL(); + + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_11L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(2, 100, -1); + + AddLocationInfoL(); + + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_12L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(2, 100, 200, 300); + + AddLocationInfoL(); + + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_13L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(2, 100, 200, 65535); + + AddLocationInfoL(); + + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_14L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(2, 100, 200, 0); + + AddLocationInfoL(); + + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_15L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(2, 100, 200, 65536); + + AddLocationInfoL(); + + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_16L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(2, 100, 200, -1); + + AddLocationInfoL(); + + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_17L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(2, 100, 200, 300, 65535); + + AddLocationInfoL(); + + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_18L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(2, 100, 200, 300, 0); + + AddLocationInfoL(); + + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_19L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(2, 100, 200, 300, 65536); + + AddLocationInfoL(); + + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_20L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(2, 100, 200, 300, -1); + + AddLocationInfoL(); + + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_21L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(2, 100, 200, 300, 30, 255); + + AddLocationInfoL(); + + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_22L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(2, 100, 200, 300, 30, 0); + + AddLocationInfoL(); + + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_23L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(2, 100, 200, 300, 30, -1); + + AddLocationInfoL(); + + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_24L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(2, 100, 200, 300, 30, 256); + + AddLocationInfoL(); + + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_25L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30); + + AddLocationInfoL(); + + ConvertLocationInfoL(1, 1, 0); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_26L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + + ConvertLocationInfoL(2, 1, 0); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_27L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + + ConvertLocationInfoL(4, 1, 0); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_28_1L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_28_1_3L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 0, 0, 0); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_28_1_4L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 999, 999, 65535); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_28_1_5L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, -1, 200, 300); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_28_1_6L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, -1, 300); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_28_1_7L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, -1); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_28_1_8L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 1000, 200, 300); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_28_1_9L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 1000, 300); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_28_1_10L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 268435456); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_28_2L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(2, 100, 200, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_29L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(2, 100); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_30L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(2, 999); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_31L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(2, 0); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_32L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(2, 1000); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_33L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(2, -1); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_34L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(2, 100, 200); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_35L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(2, 100, 999); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_36L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(2, 100, 0); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_37L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(2, 100, 1000); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_38L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(2, 100, -1); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_39L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(2, 100, 200, 65535); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_40L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(2, 100, 200, 0); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_41L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(2, 100, 200, 268435456); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_42L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(2, 100, 200, -1); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_43L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(2, 100, 200, 30, 0, 511); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_44L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(2, 100, 200, 30, 0); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_45L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(2, 100, 200, 30, 512); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_46L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(2, 100, 200, 30, -1); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_47_1L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(2, 200); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_47_2L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(2, 100, 300, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_47_3L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(2, 100, 300, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_49_1L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 200, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_49_2L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 200, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_51L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(2, 100, 200, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + ConvertLocationInfoL(1, 1, 0); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_52L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(2, 100, 200, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + ConvertLocationInfoL(2, 1, 0); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_1_53L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(2, 100, 200, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + ConvertLocationInfoL(4, 1, 0); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_2_1L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30, -2, 1, 0, 1, 3); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_2_2L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30, -2, -2, 1, 3, 63, 1); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_2_3L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30, -2, -2, 2, 3, 10, 1); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_2_4L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30, 1, -1, 1, 3); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_2_5L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30, 1, 64, 1, 3); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_2_6L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30, -2, -2, 1, 0, 63, 1); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_2_7L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30, -2, -2, 1, 1023, 63, 1); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_2_8L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30, 1, 63, 1, -1); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_2_9L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30, 1, 63, 1, 1024); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_2_10L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30, 1, 63, 0, 1023); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_2_11L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30, -2, -2, 1, 1023, 63, 63); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_2_12L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30, 1, 63, -1, 1023); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_2_13L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30, 1, 63, 64, 1023); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_2_14L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30, 1, -2, 0, 15, 46, 0); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_2_15L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30, 1, 0, 268435455, 15, 47, 0); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_2_16L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30, 2, 15, 44, 15, 46, 0); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_2_17L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30, 1, -1, 15); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_2_18L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30, 1, 268435456, 15); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_2_19L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30, 1, 0, 0, 0, 47, 0); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_2_20L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30, 1, -2, 268435455, 511, 47, 0); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_2_21L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30, 1, 0, -1); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_2_22L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30, 1, 268435455, 512); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_3_1_1L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWLanInfoL(1, 100000, 3); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_3_2_1L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWLanInfoL(2, 100000); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_3_2_2L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWLanInfoL(2); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_3_4L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWLanInfoL(2, 100000, 3); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + ConvertLocationInfoL(1, 1, 0); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_3_5L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWLanInfoL(2, 100000, 3); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + ConvertLocationInfoL(2, 1, 0); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_3_6L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWLanInfoL(2, 100000, 3); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + ConvertLocationInfoL(2, 1, 0); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_3_7L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWLanInfoL(2, 100000, 0); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_3_8L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWLanInfoL(2, 100000, 255); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_3_9L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWLanInfoL(2, 100000, -1); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_3_10L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWLanInfoL(2, 100000, 256); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_4_1L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30); + if(err != KErrNone) User::Leave(err); + err = MiscL(1); + if(err != KErrCancel) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_4_2L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWLanInfoL(2, 100000, 255); + if(err != KErrNone) User::Leave(err); + err = MiscL(1); + if(err != KErrCancel) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_4_3L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30); + if(err != KErrNone) User::Leave(err); + err = MiscL(2); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_4_4L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30); + if(err != KErrNone) User::Leave(err); + err = MiscL(3); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_4_5_1L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + if(iApiId == 0) + { + err = MiscL(4); + if(err != KErrNone) User::Leave(err); + } + else + { + TRAPD(leaveErr, MiscL(4)); + if(leaveErr != KErrInUse) User::Leave(leaveErr); + CActiveScheduler::Start(); + } + + Cleanup(); + +}; + + +void CStep::test_2698_4_5_2L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_5_1_1L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30, -2, 60, 1, 1023, 63, 63); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30, 40, 60, 1, 1023, 63, 63); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 2)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_5_1_2L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30, 1, -2, 268435455, 511, 47, 0); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30, 1, 511, 268435455, 511, 47, 0); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 2)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_5_1_3L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30, -2, -2, 1, 1023, 63, 63); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30, -2, -2, 1, 1023, 63, 63); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 2)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_5_1_4L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30, 1, 2, 268435455, 511, 47, 0); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30, 1, 2, 268435455, 511, 47, 0); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 2)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_5_1_5L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 2)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_5_1_6L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 2)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_5_1_7L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 2)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_5_1_8L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 2)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_5_1_9L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30, -2, -2, 1, 1023, 63, 63); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30, -2, -2, 1, 1023, 63, 63); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 1000, -1, 300, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 2)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_5_1_10L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30, -2, -2, 1, 1023, 63, 63); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30, 40, 1, 64, 64, 1023); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 2)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_5_1_11L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30, -2, -2, 1, 1023, 63, 63); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30, -1, 1, 63, 63, 1023); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 2)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_5_1_12L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30, -2, -2, 1, 1023, 63, 63); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30, 40, 1, 63, 63, 1023); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 300, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 2)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_5_1_13L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30, 1, -2, 268435455, 511, 47, 0); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30, 1, 511, 268435455, 511, 47, 0); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 1000, 200, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 2)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_5_1_14L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30, 1, 268435456, 511); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30, 1, 511, 268435455, 511, 47, 0); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 2)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_5_1_15L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30, 1, -2, 268435455, 511, 47, 0); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30, 512, 1, 268435455, 511); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 2)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_5_1_16L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30, 1, -2, 268435455, 511, 47, 0); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30, 1, 511, 268435455, 511, 47, 0); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 2)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_5_1_17L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30, 1, -2, 268435455, 511, 47, 0); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30, 40, 63, 1, 1023, 63, 63); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 2)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_5_1_18L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30, -2, -2, 1, 1023, 63, 63); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30, 40, -2, 1, 1023, 63, 63); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + ConvertLocationInfoL(1, 1, 2); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_5_1_19L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30, -2, 63, 1, 1023, 63, 63); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30, 40, 63, 1, 1023, 63, 63); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + ConvertLocationInfoL(2, 1, 2); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_5_1_20L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30, -2, 63, 1, 1023, 63, 63); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30, 40, 63, 1, 1023, 63, 63); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + ConvertLocationInfoL(4, 1, 2); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_5_1_21L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30, 1, -2, 268435455, 511, 47, 0); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30, 1, 511, 268435455, 511, 47, 0); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + ConvertLocationInfoL(1, 1, 2); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_5_1_22L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30, 1, -2, 268435455, 511, 47, 0); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30, 1, 511, 268435455, 511, 47, 0); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + ConvertLocationInfoL(2, 1, 2); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_5_1_23L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30, 1, -2, 268435455, 511, 47, 0); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30, 1, 511, 268435455, 511, 47, 0); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + ConvertLocationInfoL(4, 1, 2); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_5_1_24L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30, 1, -2, 268435455, 511, 47, 0); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30, 40, -2, 1, 1023, 63, 63); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + ConvertLocationInfoL(0, 0, 2); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_5_1_25L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30, 1, -2, 268435455, 511, 47, 0); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30, 40, -2, 1, 1023, 63, 63); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + ConvertLocationInfoL(0, 2, 2); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNotSupported) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_5_1_26L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30, 1, -2, 268435455, 511, 47, 0); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30, 40, -2, 1, 1023, 63, 63); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 4, 2)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(iApiId == 0) + { + if(err != KErrNotSupported) User::Leave(err); + } + Cleanup(); + +}; + + +void CStep::test_2698_5_1_27L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30, 1, -2, 268435455, 511, 47, 0); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWCDMACellInfoL(1, 100, 200, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30, 40, 63, 1, 1023, 63, 63); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 8, 2)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_5_2_1L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWLanInfoL(1, 100000, 3); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWLanInfoL(1, 100000, 3); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWLanInfoL(1, 100000, 3); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWLanInfoL(1, 100000, 3); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWLanInfoL(1, 100000, 3); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_5_2_2L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWLanInfoL(1, 100000, 3); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWLanInfoL(1, 200000, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWLanInfoL(1, 100000, 3); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWLanInfoL(1, 100000, 3); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWLanInfoL(1, 200000, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_5_2_3L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWLanInfoL(1, 100000, 3); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_5_2_4L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 2)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_5_2_5L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWLanInfoL(1, 100000, 3); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWLanInfoL(1, 100000, 3); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWLanInfoL(1, 100000, 3); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWLanInfoL(1, 100000, 256); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWLanInfoL(1, 100000, 3); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 2)); + if(err != KErrArgument) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_5_2_6L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWLanInfoL(1, 100000, 3); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWLanInfoL(1, 100000, 3); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = SetWLanInfoL(1, 100000, 3); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30, 63, 1, 63, 1023); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + TRAP(err,ConvertLocationInfoL(0, 1, 0)); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_5_3_1L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = MiscL(5); + if(err != KErrCancel) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_5_3_2L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = SetWLanInfoL(2, 100000, 255); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = MiscL(5); + if(err != KErrCancel) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_5_3_3L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = MiscL(6); + // Unsure of the correct result here, should be an error after cancellation? + if(err != KErrNotFound) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_5_3_4L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = MiscL(7); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + +void CStep::test_2698_5_4_1L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 100, 200, 300, 30); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + err = MiscL(8); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +}; + + + +void CStep::test_MultipleSessionsOneAfterAnotherL() +{ + TInt err = KErrNone; + TUint Uidinteger = 537007117; // Example + TUid uid = TUid::Uid( Uidinteger ); + iLbsLocationInfo = CLbsLocationInfo::NewLC(); + CleanupStack::Pop(iLbsLocationInfo); + + iObserver = CTelocationinfoconversionobserver::NewL(); + iLbsLocationInfoConverter = CLbsLocationInfoConverter::NewL(*iObserver,uid); + TBuf8<6> macidbuf; + TInt macidint = 1; + macidbuf.AppendNum(macidint); + CLbsWlanInfo* wlaninfo; + TInt signalstrength = 20; + wlaninfo=CLbsWlanInfo::NewL( macidbuf,signalstrength); + iLbsLocationInfo->AddAreaInfoL(wlaninfo); + + iLbsLocationInfoArrayTemp.Append(iLbsLocationInfo); + + iLbsLocationInfoArray.Append(iLbsLocationInfo); + + iLbsLocationInfo = CLbsLocationInfo::NewL(); + + iLbsLocationInfoConverter->ConvertLocationInfoL(iLbsLocationInfoArray,ELbsConversionSilent,ELbsConversionOutputPosition); + + + CActiveScheduler::Start(); + + if( iObserver->ConversionResult() == KErrNone ) + { + RPointerArray PosInfoList; + static_cast(iLbsLocationInfoArray[0])->GetAreaInfoL(PosInfoList,CLbsLocationInfo::ELbsPosInfo); + TInt count2 = PosInfoList.Count(); + PosInfoList.ResetAndDestroy(); + } + + // Cleanup(); + + err = KErrNone; + TUint Uidinteger2 = 537007117; // Example + TUid uid2 = TUid::Uid( Uidinteger2 ); + iLbsLocationInfo2 = CLbsLocationInfo::NewL(); + + iObserver2 = CTelocationinfoconversionobserver::NewL(); + iLbsLocationInfoConverter2 = CLbsLocationInfoConverter::NewL(*iObserver2,uid2); + TBuf8<6> macidbuf2; + TInt macidint2 = 1; + macidbuf2.AppendNum(macidint2); + CLbsWlanInfo* wlaninfo2; + TInt signalstrength2 = 20; + wlaninfo2=CLbsWlanInfo::NewL( macidbuf2,signalstrength2); + iLbsLocationInfo2->AddAreaInfoL(wlaninfo2); + + iLbsLocationInfoArrayTemp.Append(iLbsLocationInfo2); + + iLbsLocationInfoArray.Append(iLbsLocationInfo2); + + iLbsLocationInfo2 = CLbsLocationInfo::NewL(); + + iLbsLocationInfoConverter2->ConvertLocationInfoL(iLbsLocationInfoArray,ELbsConversionSilent,ELbsConversionOutputPosition); + + CActiveScheduler::Start(); + + if( iObserver2->ConversionResult() == KErrNone ) + { + RPointerArray PosInfoList; + static_cast(iLbsLocationInfoArray[0])->GetAreaInfoL(PosInfoList,CLbsLocationInfo::ELbsPosInfo); + TInt count2 = PosInfoList.Count(); + PosInfoList.ResetAndDestroy(); + } + + Cleanup(); + + if(iLbsLocationInfo2) + { + delete iLbsLocationInfo2; + iLbsLocationInfo2 = NULL; + } + if(iLbsLocationInfoConverter2) + { + delete iLbsLocationInfoConverter2; + iLbsLocationInfoConverter2 = NULL; + } + + if(iObserver2) + { + delete iObserver2; + iObserver2 = NULL; + } + +}; + +void CStep::test_MultipleCoversionsAtSameTimeL() +{ // two conversion at same time! + TInt err = KErrNone; + TUint Uidinteger = 537007117; // Example + TUid uid = TUid::Uid( Uidinteger ); + iLbsLocationInfo = CLbsLocationInfo::NewL(); + + iObserver = CTelocationinfoconversionobserver::NewL(); + iLbsLocationInfoConverter = CLbsLocationInfoConverter::NewL(*iObserver,uid); + TBuf8<6> macidbuf; + TInt macidint = 1; + macidbuf.AppendNum(macidint); + CLbsWlanInfo* wlaninfo; + TInt signalstrength = 20; + wlaninfo=CLbsWlanInfo::NewL( macidbuf,signalstrength); + iLbsLocationInfo->AddAreaInfoL(wlaninfo); + + iLbsLocationInfoArrayTemp.Append(iLbsLocationInfo); + + iLbsLocationInfoArray.Append(iLbsLocationInfo); + + iLbsLocationInfo = CLbsLocationInfo::NewL(); + + err = KErrNone; + TUint Uidinteger2 = 537007117; // Example + TUid uid2 = TUid::Uid( Uidinteger2 ); + iLbsLocationInfo2 = CLbsLocationInfo::NewL(); + + iObserver2 = CTelocationinfoconversionobserver::NewL(); + iLbsLocationInfoConverter2 = CLbsLocationInfoConverter::NewL(*iObserver2,uid2); + TBuf8<6> macidbuf2; + TInt macidint2 = 1; + macidbuf2.AppendNum(macidint2); + CLbsWlanInfo* wlaninfo2; + TInt signalstrength2 = 20; + wlaninfo2=CLbsWlanInfo::NewL( macidbuf2,signalstrength2); + iLbsLocationInfo2->AddAreaInfoL(wlaninfo2); + + iLbsLocationInfoArrayTemp2.Append(iLbsLocationInfo2); + + iLbsLocationInfoArray2.Append(iLbsLocationInfo2); + + iLbsLocationInfo2 = CLbsLocationInfo::NewL(); + + iLbsLocationInfoConverter->ConvertLocationInfoL(iLbsLocationInfoArray,ELbsConversionSilent,ELbsConversionOutputPosition); + iLbsLocationInfoConverter2->ConvertLocationInfoL(iLbsLocationInfoArray2,ELbsConversionSilent,ELbsConversionOutputPosition); + + CActiveScheduler::Start(); + + TInt error = iObserver->ConversionResult(); + if( error == KErrNone ) + { + RPointerArray PosInfoList; + static_cast(iLbsLocationInfoArray[0])->GetAreaInfoL(PosInfoList,CLbsLocationInfo::ELbsPosInfo); + TInt count2 = PosInfoList.Count(); + PosInfoList.ResetAndDestroy(); + } + else + { + INFO_PRINTF2(_L("iObserver->ConversionResulterror = %d"), error); + + } + + CActiveScheduler::Start(); + + error = iObserver2->ConversionResult(); + if( error == KErrNone ) + { + RPointerArray PosInfoList; + static_cast(iLbsLocationInfoArray2[0])->GetAreaInfoL(PosInfoList,CLbsLocationInfo::ELbsPosInfo); + TInt count2 = PosInfoList.Count(); + PosInfoList.ResetAndDestroy(); + } + else + { + INFO_PRINTF2(_L("iObserver->ConversionResult error = %d"), error); + User::Leave(error); + } + + Cleanup(); + + if(iLbsLocationInfo2) + { + delete iLbsLocationInfo2; + iLbsLocationInfo2 = NULL; + } + if(iLbsLocationInfoConverter2) + { + delete iLbsLocationInfoConverter2; + iLbsLocationInfoConverter2 = NULL; + } + + if(iObserver2) + { + delete iObserver2; + iObserver2 = NULL; + } + iLbsLocationInfoArrayTemp2.ResetAndDestroy(); + iLbsLocationInfoArray2.Reset(); +}; + +void CStep::test_MultipleResolversAtSameTimeL() +{ + TInt err = KErrNone; + + iApiId =1; // use resolver + + + TUint Uidinteger = 537007117; // Example + TUid uid = TUid::Uid( Uidinteger ); + iLbsLocationInfo = CLbsLocationInfo::NewL(); + + iResolverObserver = CTeLocationResolverObserver::NewL(); + iLbsLocationResolver = CLbsLocationResolver::NewL(*iResolverObserver,uid); + + + iLbsLocationInfo2 = CLbsLocationInfo::NewL(); + + iResolverObserver2 = CTeLocationResolverObserver::NewL(); + iLbsLocationResolver2 = CLbsLocationResolver::NewL(*iResolverObserver2,uid); + + SetGSMCellInfoL(1, 404, 49, 16, 7141); + if(err != KErrNone) User::Leave(err); + + err = SetGSMCellInfo2L(1, 404, 49, 16, 7141); + if(err != KErrNone) User::Leave(err); + + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + + AddLocationInfo2L(); + if(err != KErrNone) User::Leave(err); + + ConvertLocationInfoL(1, 1, 0); + + ConvertLocationInfo2L(1, 1, 0); + + err = ValidateLocationInfo(); + if(err != KErrNone) User::Leave(err); + + err = ValidateLocationInfo2(); + if(err != KErrNone) User::Leave(err); + Cleanup(); + +// + + if(iLbsLocationInfo2) + { + delete iLbsLocationInfo2; + iLbsLocationInfo2 = NULL; + } + if(iLbsLocationInfoConverter2) + { + delete iLbsLocationInfoConverter2; + iLbsLocationInfoConverter2 = NULL; + } + if(iLbsLocationResolver2) + { + delete iLbsLocationResolver2; + iLbsLocationResolver2 = NULL; + } + if(iObserver2) + { + delete iObserver2; + iObserver2 = NULL; + } + if(iResolverObserver2) + { + delete iResolverObserver2; + iResolverObserver2 = NULL; + } + iLbsLocationInfoArrayTemp2.ResetAndDestroy(); + iLbsLocationInfoArray2.Reset(); + + // +}; + + + +void CStep::test_2698_5_4_2L() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + SetGSMCellInfoL(1, 404, 49, 16, 7141); + if(err != KErrNone) User::Leave(err); + AddLocationInfoL(); + if(err != KErrNone) User::Leave(err); + ConvertLocationInfoL(1, 1, 0); + if(err != KErrNone) User::Leave(err); + err = ValidateLocationInfo(); + if(err != KErrNotFound) User::Leave(err); + Cleanup(); +}; + + +void CStep::test_SetAndGetConversionPrefs() +{ + TInt err = KErrNone; + + err = CreateLocationInfoConverterL(); + if(err != KErrNone) User::Leave(err); + err = GetAndCheckConversionPrefs(0);//default value ELbsConversionNotDefined (0x0000) + if(err != KErrNone) User::Leave(err); + err = SetConversionPrefs(4); //ELbsConversionPrompt(0x0004) + if(err != KErrNone) User::Leave(err); + err = GetAndCheckConversionPrefs(4); + if(err != KErrNone) User::Leave(err); + err = SetConversionPrefs(15); + if(err != KErrArgument) User::Leave(err); + err = SetConversionPrefs(999999999); + if(err != KErrArgument) User::Leave(err); + err = GetAndCheckConversionPrefs(4); //Check if previously set value has been retained + if(err != KErrNone) User::Leave(err); + err = SetConversionPrefs(64); //Is a valid value though the current max in the enum list is only 4 + if(err != KErrNone) User::Leave(err); + err = GetAndCheckConversionPrefs(64); //Check if previously set value has been retained + if(err != KErrNone) User::Leave(err); + + Cleanup(); +}; + +typedef struct + { + TInt countryCode; + TInt networkCode; + TInt locationCode; + TInt cellId; + TBool fromPlugin; + } +sGsmInfo; + +/* + * Here, we test the mode where localities coming from the converter are cache. + * Thus the third and forth localities should come from the cache and NOT the + * plugin + */ +const TInt KTestCacheArraySize= 4; +sGsmInfo testArray[KTestCacheArraySize] = { + {44, 49, 16, 714, ETrue }, + {45, 50, 17, 714, ETrue}, + {45, 50, 17, 714, EFalse}, + {45, 50, 17, 714, EFalse} +}; + + +void CStep::test_cacheL() +{ + TInt err = KErrNone; + iApiId =1; // use resolver + + TUint Uidinteger = 537007117; + TUid uid = TUid::Uid( Uidinteger ); + + for (TUint i = 0; i < KTestCacheArraySize; i++) + { + TRAPD(leaveErr, iLbsLocationInfo = CLbsLocationInfo::NewL()); + if (KErrNone != leaveErr ) + { + INFO_PRINTF2(_L("iLbsLocationInfo = CLbsLocationInfo::NewL() LEAVES, error =%d"), leaveErr); + User::Leave(leaveErr); + } + + TRAP(leaveErr,iResolverObserver = CTeLocationResolverObserver::NewL()); + if (KErrNone != leaveErr ) + { + INFO_PRINTF2(_L("CTeLocationResolverObserver::NewL() LEAVES, error =%d"), leaveErr); + User::Leave(leaveErr); + } + + TRAP(leaveErr,iLbsLocationResolver = CLbsLocationResolver::NewL(*iResolverObserver,uid)); + if (KErrNone != leaveErr ) + { + INFO_PRINTF2(_L("iLbsLocationResolver = CLbsLocationResolver::NewL(*iResolverObserver,uid) LEAVES, error =%d"), leaveErr); + User::Leave(leaveErr); + } + + TRAP(leaveErr,SetGSMCellInfoL(1, + testArray[i].countryCode, + testArray[i].networkCode, + testArray[i].locationCode, + testArray[i].cellId , KTimingAdvanceSpecialValue)); // timing advance 254 is special! + if (KErrNone != leaveErr ) + { + INFO_PRINTF2(_L("SetGSMCellInfoL LEAVES, error =%d"), leaveErr); + User::Leave(leaveErr); + } + + TRAP(leaveErr, AddLocationInfoL()); + if( KErrNone !=leaveErr) + { + INFO_PRINTF2(_L("AddLocationInfoL() LEAVES, error =%d"), leaveErr); + User::Leave(leaveErr); + } + + TRAP(leaveErr, ConvertLocationInfoL(1, 1, 0)); + if( KErrNone !=leaveErr) + { + INFO_PRINTF2(_L("ConvertLocationInfoL(1, 1, 0)) LEAVES, error =%d"), leaveErr); + User::Leave(leaveErr); + } + + TInt err = ValidateLocationInfo(); + if( KErrNone !=err) + { + INFO_PRINTF2(_L("ValidateLocationInfo() returns error =%d"), err); + User::Leave(err); + } + + TLocality locality; + TBool fromCache = iResolverObserver->ConversionLocality(locality); + + TReal64 lat = locality.Latitude(); + TReal64 lng = locality.Longitude(); + TReal32 alt = locality.Altitude(); + + TInt cCode = testArray[i].countryCode; + if (cCode != (TInt)lat) + { + INFO_PRINTF2(_L("VcCode != (TInt)lat error =%d"), KErrGeneral); + + User::Leave(KErrGeneral); + } + + TInt nCode = testArray[i].networkCode; + if (nCode != (TInt)lng) + { + INFO_PRINTF2(_L("nCode != (TInt)lng error =%d"), KErrGeneral); + + User::Leave(KErrGeneral); + } + + TInt lCode = testArray[i].locationCode; + if (lCode != (TInt)alt) + { + INFO_PRINTF2(_L("lCode != (TInt)alt error =%d"), KErrGeneral); + + User::Leave(KErrGeneral); + } + + + if (fromCache) + { + INFO_PRINTF4(_L("From Cache(lat=%Lf, lng=%Lf, alt=%f"),lat,lng,alt); + if (testArray[i].fromPlugin) + { + INFO_PRINTF1(_L("Test failed - Position got from Cache bit should have come from plugin")); + User::Leave(KErrGeneral); + } + } + else + { // from plugin! + INFO_PRINTF4(_L("From plugin(lat=%Lf, lng=%Lf, alt=%f"),lat,lng,alt); + if (!testArray[i].fromPlugin) + { + INFO_PRINTF1(_L("Test failed - Position got from plugin but should have come from Cache")); + User::Leave(KErrGeneral); + } + } + Cleanup(); + } // end of for loop +}; + +const TInt KTest2ArraySize= 4; + +/* + * Here all four converts should from the cache as the + * loc monitor has been instructed NOT to put things into the cache. + * The timing advance is used by the test (in an adhoc way!) + * to instruct the test plugin to tell the loc monitor NOT to put stuff + * in the cache + */ +sGsmInfo testArray2[KTest2ArraySize] = { + {44, 49, 16, 7141, ETrue }, + {45, 50, 17, 714, ETrue}, + {45, 50, 17, 714, ETrue}, + {45, 50, 17, 714, ETrue} + +}; +void CStep::test_cache2L() +{ + TInt err = KErrNone; + + iApiId =1; // use resolver + + TUint Uidinteger = 537007117; // Example + TUid uid = TUid::Uid( Uidinteger ); + + for (TUint i = 0; i < KTest2ArraySize; i++) + { + TRAPD(leaveErr, iLbsLocationInfo = CLbsLocationInfo::NewL()); + if (KErrNone != leaveErr ) + { + INFO_PRINTF2(_L("iLbsLocationInfo = CLbsLocationInfo::NewL() LEAVES, error =%d"), leaveErr); + User::Leave(leaveErr); + } + + TRAP(leaveErr,iResolverObserver = CTeLocationResolverObserver::NewL()); + if (KErrNone != leaveErr ) + { + INFO_PRINTF2(_L("CTeLocationResolverObserver::NewL() LEAVES, error =%d"), leaveErr); + User::Leave(leaveErr); + } + + TRAP(leaveErr,iLbsLocationResolver = CLbsLocationResolver::NewL(*iResolverObserver,uid)); + if (KErrNone != leaveErr ) + { + INFO_PRINTF2(_L("iLbsLocationResolver = CLbsLocationResolver::NewL(*iResolverObserver,uid) LEAVES, error =%d"), leaveErr); + User::Leave(leaveErr); + } + + TRAP(leaveErr,SetGSMCellInfoL(1, + testArray2[i].countryCode, + testArray2[i].networkCode, + testArray2[i].locationCode, + testArray2[i].cellId , KTimingAdvanceSaveToCacheFalse)); // timing advance is special! + if (KErrNone != leaveErr ) + { + INFO_PRINTF2(_L("SetGSMCellInfoL LEAVES, error =%d"), leaveErr); + User::Leave(leaveErr); + } + + TRAP(leaveErr, AddLocationInfoL()); + if( KErrNone !=leaveErr) + { + INFO_PRINTF2(_L("AddLocationInfoL() LEAVES, error =%d"), leaveErr); + User::Leave(leaveErr); + } + + TRAP(leaveErr, ConvertLocationInfoL(1, 1, 0)); + if( KErrNone !=leaveErr) + { + INFO_PRINTF2(_L("ConvertLocationInfoL(1, 1, 0)) LEAVES, error =%d"), leaveErr); + User::Leave(leaveErr); + } + + TInt err = ValidateLocationInfo(); + if( KErrNone !=err) + { + INFO_PRINTF2(_L("ValidateLocationInfo() returns error =%d"), err); + User::Leave(err); + } + + TLocality locality; + TBool fromCache = iResolverObserver->ConversionLocality(locality); + + TReal64 lat = locality.Latitude(); + TReal64 lng = locality.Longitude(); + TReal32 alt = locality.Altitude(); + + TInt cCode = testArray2[i].countryCode; + if (cCode != (TInt)lat) + { + INFO_PRINTF2(_L("VcCode != (TInt)lat error =%d"), KErrGeneral); + + User::Leave(KErrGeneral); + } + + TInt nCode = testArray2[i].networkCode; + if (nCode != (TInt)lng) + { + INFO_PRINTF2(_L("nCode != (TInt)lng error =%d"), KErrGeneral); + + User::Leave(KErrGeneral); + } + + TInt lCode = testArray2[i].locationCode; + if (lCode != (TInt)alt) + { + INFO_PRINTF2(_L("lCode != (TInt)alt error =%d"), KErrGeneral); + + User::Leave(KErrGeneral); + } + + + if (fromCache) + { + INFO_PRINTF4(_L("From Cache(lat=%Lf, lng=%Lf, alt=%f"),lat,lng,alt); + if (testArray2[i].fromPlugin) + { + INFO_PRINTF1(_L("Test failed - Position got from Cache bit should have come from plugin")); + User::Leave(KErrGeneral); + } + } + else + { // from plugin! + INFO_PRINTF4(_L("From plugin(lat=%Lf, lng=%Lf, alt=%f"),lat,lng,alt); + if (!testArray2[i].fromPlugin) + { + INFO_PRINTF1(_L("Test failed - Position got from plugin but should have come from Cache")); + User::Leave(KErrGeneral); + } + } + Cleanup(); + } // end of for loop +}; + + + +/* this tests the cache behaviour when a non-exact match occurs. + * For example, when cache contains + * CC=A, NC=B, LC=C, CID=D Lat=20.0, Long=30.0 Acc=5.0m + * and we look up + * CC=A, NC=B, LC=X, CID=Y + * then CC=A, NC=B results in a partial match occurs and the accuracy + * of Lat=20.0, Long=30.0 is the accuracy associated with a + * partial CC=A, NC=B match (1000000.0) + * Notes: + * CC=A, NC=B, LC=C, CID=D Lat=20.0, Long=30.0 Acc=5.0m + * followed by + * CC=A, NC=B, LC=C, CID=D Lat=20.0, Long=30.1 Acc=5.1m + * results inn a single entry of + * CC=A, NC=B, LC=C, CID=D Lat=20.0, Long=30.1 Acc=5.1m in cache + * KWlanAccuracy = 100.0; - not used currently + * KCellFullAccuracy = 3000.0; CC and NC and LC and CID + * KCellLocationAccuracy = 30000.0; CC and NC and LC match + * KCellCountryAccuracy = 1000000.0; CC only or CC + NC + * + * If in cache we have: + * CC=A, NC=B, LC=C, CID=D Lat=20.0, Long=30.0 Acc=5.0m + * CC=A, NC=B, LC=C, CID=E Lat=20.1, Long=30.0 Acc=6.0m + * + * and we try to match + * CC=A, NC=B, LC=C + * then we get from the cache the most recent and not the most accurate + * Lat=20.1, Long=30.0 Acc=3000.0 + * + */ + + +typedef struct + { + TInt countryCode; // -> lat of position composed by plugin + TInt networkCode; // -> long of position composed by plugin + TInt locationCode; // -> alt of position composed by plugin + TInt cellId; // -> horizontal accuracy of position composed by plugin + TBool fromPlugin; // when false then it is expected that locality comes out of cache + TInt expectedHorAccuracyWhenFromCache; // and these values below are the expected values + TInt expectedLatitudeWhenFromCache; + TInt expectedLongitudeWhenFromCache; // note absence of Vertical accuracy + // here - as it is set to Nan by the lc monitor + } +sGsmInfoExtended; + +const TInt KTestArraySize= 18; + +sGsmInfoExtended testArray3[KTestArraySize] = { +// test the case where there a non-exact match +// and the position returned by the plugin is less accurate +// than the one deduced from the cache +// cc nc lc cid + + {44, 49, 16, 714, ETrue, -1, -1, -1}, //stored in cash + {45, 50, 17, 714, ETrue, -1, -1, -1}, + {45, 50, 17, 30001, EFalse, 30000, 45, 50},// not saved in cache - cc and nc and lc match with plugins less accurate than cached + {45, 50, 18, 1000001, EFalse, 1000000,45, 50},// not saved in cache - cc and nc match with plugins less accurate than cached + {45, 51, 18, 1000001, EFalse, 1000000,45, 50},// not saved in cache -cc only match with plugins less accurate than cached + {45, 50, 17, 714, EFalse, 3000, 45, 50},// exact match - to cellid level + // regardless, should use cache + // test the case where there a non-exact match + // and the position returned by the plugin is more accurate + // than the one deduced from the cache + {54, 49, 16, 714, ETrue, -1, -1, -1}, + {55, 50, 17, 714, ETrue, -1, -1, -1}, + {55, 50, 17, 2999, ETrue, -1, -1, -1}, // cc and nc and lc match with plugins less accurate than cached + {55, 50, 18, 29999, ETrue, -1, -1, -1}, // cc and nc match with plugins less accurate than cached + {55, 51, 18, 999999, ETrue, -1, -1, -1}, // cc only match with plugins less accurate than cached + {55, 50, 17, 714, EFalse, 3000, 55, 50}, // exact match - to cellid level + // regardless, should use cache + // now check that cache contains all the exact matches it should + // note that several of the entries above were NOT saved in cache + // because the value returned by the plugin was not accurate enough + {44, 49, 16, 714, EFalse, 3000, 44, 49}, + {45, 50, 17, 714, EFalse, 3000, 45, 50}, + {45, 50, 17, 714, EFalse, 3000, 45, 50}, + {54, 49, 16, 714, EFalse, 3000, 54, 49}, + {45, 50, 17, 714, EFalse, 3000, 45, 50}, + {45, 50, 17, 714, EFalse, 3000, 45, 50} +}; + +void CStep::test_cache3L() +{ + TInt err = KErrNone; + + iApiId =1; // use resolver + + TUint Uidinteger = 537007117; // Example + TUid uid = TUid::Uid( Uidinteger ); + + for (TUint i = 0; i < KTestArraySize; i++) + { + + TRAPD(leaveErr, iLbsLocationInfo = CLbsLocationInfo::NewL()); + if (KErrNone != leaveErr ) + { + INFO_PRINTF2(_L("iLbsLocationInfo = CLbsLocationInfo::NewL() LEAVES, error =%d"), leaveErr); + User::Leave(leaveErr); + } + + TRAP(leaveErr,iResolverObserver = CTeLocationResolverObserver::NewL()); + if (KErrNone != leaveErr ) + { + INFO_PRINTF2(_L("CTeLocationResolverObserver::NewL() LEAVES, error =%d"), leaveErr); + User::Leave(leaveErr); + } + + TRAP(leaveErr,iLbsLocationResolver = CLbsLocationResolver::NewL(*iResolverObserver,uid)); + if (KErrNone != leaveErr ) + { + INFO_PRINTF2(_L("iLbsLocationResolver = CLbsLocationResolver::NewL(*iResolverObserver,uid) LEAVES, error =%d"), leaveErr); + User::Leave(leaveErr); + } + + TRAP(leaveErr,SetGSMCellInfoL(1, + testArray3[i].countryCode, + testArray3[i].networkCode, + testArray3[i].locationCode, + testArray3[i].cellId , KTimingAdvanceSaveToCacheTrue)); // timing advance is special! + if (KErrNone != leaveErr ) + { + INFO_PRINTF2(_L("SetGSMCellInfoL LEAVES, error =%d"), leaveErr); + User::Leave(leaveErr); + } + + TRAP(leaveErr, AddLocationInfoL()); + if( KErrNone !=leaveErr) + { + INFO_PRINTF2(_L("AddLocationInfoL() LEAVES, error =%d"), leaveErr); + User::Leave(leaveErr); + } + + TRAP(leaveErr, ConvertLocationInfoL(1, 1, 0)); + if( KErrNone !=leaveErr) + { + INFO_PRINTF2(_L("ConvertLocationInfoL(1, 1, 0)) LEAVES, error =%d"), leaveErr); + User::Leave(leaveErr); + } + + TInt err = ValidateLocationInfo(); + if( KErrNone !=err) + { + INFO_PRINTF2(_L("ValidateLocationInfo() returns error =%d"), err); + User::Leave(err); + } + + TLocality locality; + TBool fromCache = iResolverObserver->ConversionLocality(locality); + + TReal64 lat = locality.Latitude(); + TReal64 lng = locality.Longitude(); + TReal32 alt = locality.Altitude(); + + TReal32 horAcc = locality.HorizontalAccuracy(); + + + + if (fromCache) + { + INFO_PRINTF5(_L("From Cache(lat=%Lf, lng=%Lf, alt=%f horacc=%f"),lat,lng,alt,horAcc); + if (testArray3[i].fromPlugin) + { + INFO_PRINTF1(_L("Test failed - Position got from Cache bit should have come from plugin")); + User::Leave(KErrGeneral); + } + // now check horizontal accuracy + TInt expectedAccuracy = testArray3[i].expectedHorAccuracyWhenFromCache; + if ( expectedAccuracy != (TInt)horAcc) + { + INFO_PRINTF1(_L("Test failed - incorrect horizontal accuracy read from plugin")); + INFO_PRINTF3(_L("Expected %d and got %d"),expectedAccuracy,(TInt)horAcc); + + User::Leave(KErrGeneral); + } + // now check latitude + TInt expectedLatitude = testArray3[i].expectedLatitudeWhenFromCache; + if ( expectedLatitude != (TInt)lat) + { + INFO_PRINTF1(_L("Test failed - incorrect latitude read from plugin")); + INFO_PRINTF3(_L("Expected %d and got %d"),expectedLatitude,(TInt)lat); + + User::Leave(KErrGeneral); + } + + // now check longitude + TInt expectedLongitude = testArray3[i].expectedLongitudeWhenFromCache; + if ( expectedLongitude != (TInt)lng) + { + INFO_PRINTF1(_L("Test failed - incorrect Longitude read from plugin")); + INFO_PRINTF3(_L("Expected %d and got %d"),expectedLongitude,(TInt)lng); + + User::Leave(KErrGeneral); + } + + } + else + { // from plugin! + INFO_PRINTF5(_L("From plugin(lat=%Lf, lng=%Lf, alt=%f horacc=%f"),lat,lng,alt,horAcc); + if (!testArray3[i].fromPlugin) + { + INFO_PRINTF1(_L("Test failed - Position got from plugin but should have come from Cache")); + User::Leave(KErrGeneral); + } + // now check horizontal accuracy + TInt cellId = testArray3[i].cellId; + if ( cellId != (TInt)horAcc) + { + INFO_PRINTF1(_L("Test failed - incorrect horizontal accuracy read from plugin")); + INFO_PRINTF3(_L("Expected %d and got %d"),cellId,(TInt)horAcc); + + User::Leave(KErrGeneral); + } + TInt cCode = testArray3[i].countryCode; + if (cCode != (TInt)lat) + { + INFO_PRINTF2(_L("VcCode != (TInt)lat error =%d"), KErrGeneral); + + User::Leave(KErrGeneral); + } + + TInt nCode = testArray3[i].networkCode; + if (nCode != (TInt)lng) + { + INFO_PRINTF2(_L("nCode != (TInt)lng error =%d"), KErrGeneral); + + User::Leave(KErrGeneral); + } + + TInt lCode = testArray3[i].locationCode; + if (lCode != (TInt)alt) + { + INFO_PRINTF2(_L("lCode != (TInt)alt error =%d"), KErrGeneral); + + User::Leave(KErrGeneral); + } + + } + Cleanup(); + } // end of for loop +}; +void CStep::CallL(TInt aId) +{ + switch(aId) + { +// case 0: GetAllLocationInfoL(); break; + case KErrNotFound: + INFO_PRINTF1(_L("Test case not found")); + User::Leave(KErrNotFound); + break; + + case 1: test_2698_4_1_1_1L(); break; + case 2: test_2698_4_1_1_3L(); break; + case 3: test_2698_4_1_1_4L(); break; + case 4: test_2698_4_1_1_5L(); break; + case 5: test_2698_4_1_1_6L(); break; + case 6: test_2698_4_1_1_7L(); break; + case 7: test_2698_4_1_1_8L(); break; + case 8: test_2698_4_1_1_9L(); break; + case 9: test_2698_4_1_1_10L(); break; + case 10: test_2698_4_1_1_11L(); break; + case 11: test_2698_4_1_1_12L(); break; + case 12: test_2698_4_1_1_13L(); break; + case 13: test_2698_4_1_2L(); break; + case 14: test_2698_4_1_3L(); break; + case 15: test_2698_4_1_4L(); break; + case 16: test_2698_4_1_5L(); break; + case 17: test_2698_4_1_6L(); break; + case 18: test_2698_4_1_7L(); break; + case 19: test_2698_4_1_8L(); break; + case 20: test_2698_4_1_9L(); break; + case 21: test_2698_4_1_10L(); break; + case 22: test_2698_4_1_11L(); break; + case 23: test_2698_4_1_12L(); break; + case 24: test_2698_4_1_13L(); break; + case 25: test_2698_4_1_14L(); break; + case 26: test_2698_4_1_15L(); break; + case 27: test_2698_4_1_16L(); break; + case 28: test_2698_4_1_17L(); break; + case 29: test_2698_4_1_18L(); break; + case 30: test_2698_4_1_19L(); break; + case 31: test_2698_4_1_20L(); break; + case 32: test_2698_4_1_21L(); break; + case 33: test_2698_4_1_22L(); break; + case 34: test_2698_4_1_23L(); break; + case 35: test_2698_4_1_24L(); break; + case 36: test_2698_4_1_25L(); break; + case 37: test_2698_4_1_26L(); break; + case 38: test_2698_4_1_27L(); break; + case 39: test_2698_4_1_28_1L(); break; + case 40: test_2698_4_1_28_1_3L(); break; + case 41: test_2698_4_1_28_1_4L(); break; + case 42: test_2698_4_1_28_1_5L(); break; + case 43: test_2698_4_1_28_1_6L(); break; + case 44: test_2698_4_1_28_1_7L(); break; + case 45: test_2698_4_1_28_1_8L(); break; + case 46: test_2698_4_1_28_1_9L(); break; + case 47: test_2698_4_1_28_1_10L(); break; + case 48: test_2698_4_1_28_2L(); break; + case 49: test_2698_4_1_29L(); break; + case 50: test_2698_4_1_30L(); break; + case 51: test_2698_4_1_31L(); break; + case 52: test_2698_4_1_32L(); break; + case 53: test_2698_4_1_33L(); break; + case 54: test_2698_4_1_34L(); break; + case 55: test_2698_4_1_35L(); break; + case 56: test_2698_4_1_36L(); break; + case 57: test_2698_4_1_37L(); break; + case 58: test_2698_4_1_38L(); break; + case 59: test_2698_4_1_39L(); break; + case 60: test_2698_4_1_40L(); break; + case 61: test_2698_4_1_41L(); break; + case 62: test_2698_4_1_42L(); break; + case 63: test_2698_4_1_43L(); break; + case 64: test_2698_4_1_44L(); break; + case 65: test_2698_4_1_45L(); break; + case 66: test_2698_4_1_46L(); break; + case 67: test_2698_4_1_47_1L(); break; + case 68: test_2698_4_1_47_2L(); break; + case 69: test_2698_4_1_47_3L(); break; + case 70: test_2698_4_1_49_1L(); break; + case 71: test_2698_4_1_49_2L(); break; + case 72: test_2698_4_1_51L(); break; + case 73: test_2698_4_1_52L(); break; + case 74: test_2698_4_1_53L(); break; + case 75: test_2698_4_2_1L(); break; + case 76: test_2698_4_2_2L(); break; + case 77: test_2698_4_2_3L(); break; + case 78: test_2698_4_2_4L(); break; + case 79: test_2698_4_2_5L(); break; + case 80: test_2698_4_2_6L(); break; + case 81: test_2698_4_2_7L(); break; + case 82: test_2698_4_2_8L(); break; + case 83: test_2698_4_2_9L(); break; + case 84: test_2698_4_2_10L(); break; + case 85: test_2698_4_2_11L(); break; + case 86: test_2698_4_2_12L(); break; + case 87: test_2698_4_2_13L(); break; + case 88: test_2698_4_2_14L(); break; + case 89: test_2698_4_2_15L(); break; + case 90: test_2698_4_2_16L(); break; + case 91: test_2698_4_2_17L(); break; + case 92: test_2698_4_2_18L(); break; + case 93: test_2698_4_2_19L(); break; + case 94: test_2698_4_2_20L(); break; + case 95: test_2698_4_2_21L(); break; + case 96: test_2698_4_2_22L(); break; + case 97: test_2698_4_3_1_1L(); break; + case 98: test_2698_4_3_2_1L(); break; + case 99: test_2698_4_3_2_2L(); break; + case 100: test_2698_4_3_4L(); break; + case 101: test_2698_4_3_5L(); break; + case 102: test_2698_4_3_6L(); break; + case 103: test_2698_4_3_7L(); break; + case 104: test_2698_4_3_8L(); break; + case 105: test_2698_4_3_9L(); break; + case 106: test_2698_4_3_10L(); break; + case 107: test_2698_4_4_1L(); break; + case 108: test_2698_4_4_2L(); break; + case 109: test_2698_4_4_3L(); break; + case 110: test_2698_4_4_4L(); break; + case 111: test_2698_4_5_1L(); break; + case 112: test_2698_4_5_2L(); break; + case 113: test_2698_5_1_1L(); break; + case 114: test_2698_5_1_2L(); break; + case 115: test_2698_5_1_3L(); break; + case 116: test_2698_5_1_4L(); break; + case 117: test_2698_5_1_5L(); break; + case 118: test_2698_5_1_6L(); break; + case 119: test_2698_5_1_7L(); break; + case 120: test_2698_5_1_8L(); break; + case 121: test_2698_5_1_9L(); break; + case 122: test_2698_5_1_10L(); break; + case 123: test_2698_5_1_11L(); break; + case 124: test_2698_5_1_12L(); break; + case 125: test_2698_5_1_13L(); break; + case 126: test_2698_5_1_14L(); break; + case 127: test_2698_5_1_15L(); break; + case 128: test_2698_5_1_16L(); break; + case 129: test_2698_5_1_17L(); break; + case 130: test_2698_5_1_18L(); break; + case 131: test_2698_5_1_19L(); break; + case 132: test_2698_5_1_20L(); break; + case 133: test_2698_5_1_21L(); break; + case 134: test_2698_5_1_22L(); break; + case 135: test_2698_5_1_23L(); break; + case 136: test_2698_5_1_24L(); break; + case 137: test_2698_5_1_25L(); break; + case 138: test_2698_5_1_26L(); break; + case 139: test_2698_5_1_27L(); break; + case 140: test_2698_5_2_1L(); break; + case 141: test_2698_5_2_2L(); break; + case 142: test_2698_5_2_3L(); break; + case 143: test_2698_5_2_4L(); break; + case 144: test_2698_5_2_5L(); break; + case 145: test_2698_5_2_6L(); break; + case 146: test_2698_5_3_1L(); break; + case 147: test_2698_5_3_2L(); break; + case 148: test_2698_5_3_3L(); break; + case 149: test_2698_5_3_4L(); break; + case 150: test_2698_5_4_1L(); break; + case 151: test_MultipleCoversionsAtSameTimeL(); break; + case 152: test_MultipleSessionsOneAfterAnotherL(); break; + case 153: test_MultipleResolversAtSameTimeL(); break; + case 154: test_2698_5_4_2L(); break; + case 155: test_SetAndGetConversionPrefs(); break; + case 156: test_cacheL(); break; + case 157: test_cache2L(); break; + case 158: test_cache3L(); break; + }; +}; diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/te_lbslocationinforconvertertef/src/te_lbslocationinfoconvertersuiteserver.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/te_lbslocationinforconvertertef/src/te_lbslocationinfoconvertersuiteserver.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,123 @@ +/* +* Copyright (c) 2005 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ + + +#include "te_lbslocationinfoconvertersuiteserver.h" +#include "step.h" + +#include "te_lbslocationinfoconvertersuitedefs.h" +_LIT(KServerName,"te_lbslocationinfoconvertersuite"); +CTe_LbsLocationMonitorSuite* CTe_LbsLocationMonitorSuite::NewL() +/** + * @return - Instance of the test server + * Same code for Secure and non-secure variants + * Called inside the MainL() function to create and start the + * CTestServer derived server. + */ + { + CTe_LbsLocationMonitorSuite * server = new (ELeave) CTe_LbsLocationMonitorSuite(); + CleanupStack::PushL(server); + + server->ConstructL(KServerName); + CleanupStack::Pop(server); + return server; + } + +void CTe_LbsLocationMonitorSuite::ConstructL(const TDesC& aName) + { + CTestServer::ConstructL(aName); + + } + +CTe_LbsLocationMonitorSuite::~CTe_LbsLocationMonitorSuite() + { + + } + + + +// Secure variants much simpler +// For EKA2, just an E32Main and a MainL() +LOCAL_C void MainL() +/** + * Secure variant + * Much simpler, uses the new Rendezvous() call to sync with the client + */ + { + // Leave the hooks in for platform security +#if (defined __DATA_CAGING__) + RProcess().DataCaging(RProcess::EDataCagingOn); + RProcess().DataCaging(RProcess::ESecureApiOn); +#endif + CActiveScheduler* sched=NULL; + sched=new(ELeave) CActiveScheduler; + CActiveScheduler::Install(sched); + CTe_LbsLocationMonitorSuite* server = NULL; + // Create the CTestServer derived server + TRAPD(err,server = CTe_LbsLocationMonitorSuite::NewL()); + if(!err) + { + // Sync with the client and enter the active scheduler + RProcess::Rendezvous(KErrNone); + sched->Start(); + } + delete server; + delete sched; + } + + + +GLDEF_C TInt E32Main() +/** + * @return - Standard Epoc error code on process exit + * Secure variant only + * Process entry point. Called by client using RProcess API + */ + { + __UHEAP_MARK; + CTrapCleanup* cleanup = CTrapCleanup::New(); + if(cleanup == NULL) + { + return KErrNoMemory; + } + TRAPD(err,MainL()); + delete cleanup; + __UHEAP_MARKEND; + return err; + } + + +CTestStep* CTe_LbsLocationMonitorSuite::CreateTestStep(const TDesC& aStepName) +/** + * @return - A CTestStep derived instance + * Secure and non-secure variants + * Implementation of CTestServer pure virtual + */ + { + CTestStep* testStep = NULL; + + TRAPD(err, + if(aStepName == KStep) + testStep = new(ELeave) CStep(); + ); + if(KErrNone != err) + { + INFO_PRINTF2(KErrorCreateTELBSLocationMonitorTestStep, err); + } + + return testStep; + } diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/te_lbslocationinforconvertertef/src/te_lbslocationinfoconvertersuitestepbase.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/te_lbslocationinforconvertertef/src/te_lbslocationinfoconvertersuitestepbase.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,98 @@ +/* +* Copyright (c) 2006 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ + + +#include "te_lbslocationinfoconvertersuitestepbase.h" + + +TVerdict CTe_LbsLocationInfoConverterSuiteStepBase::doTestStepPreambleL() +/** + * @return - TVerdict + * Implementation of CTestStep base class virtual + * It is used for doing all initialisation common to derived classes in here. + * Make it being able to leave if there are any errors here as there's no point in + * trying to run a test step if anything fails. + * The leave will be picked up by the framework. + */ + { + iScheduler = new(ELeave) CActiveScheduler(); + CActiveScheduler::Install(iScheduler); + + SetTestStepResult(EPass); + return TestStepResult(); + } + +TVerdict CTe_LbsLocationInfoConverterSuiteStepBase::doTestStepPostambleL() +/** + * @return - TVerdict + * Implementation of CTestStep base class virtual + * It is used for doing all after test treatment common to derived classes in here. + * Make it being able to leave + * The leave will be picked up by the framework. + */ + { + return TestStepResult(); + } + +CTe_LbsLocationInfoConverterSuiteStepBase::~CTe_LbsLocationInfoConverterSuiteStepBase() + { + + } + +CTe_LbsLocationInfoConverterSuiteStepBase::CTe_LbsLocationInfoConverterSuiteStepBase() + { + + } + + +TInt CTe_LbsLocationInfoConverterSuiteStepBase::GetTestCaseId() + { + TInt testCaseId(KErrNotFound); + // Ini file key names for test cases + _LIT(KTestCaseId, "tc_id"); + TInt err = GetIntFromConfig(ConfigSection(), KTestCaseId, testCaseId); + return testCaseId; + } + +TInt CTe_LbsLocationInfoConverterSuiteStepBase::GetTestCaseApi() + { + TInt testCaseApi(0); + // Ini file key names for test cases + _LIT(KTestCaseApi, "tc_api"); + TInt err = GetIntFromConfig(ConfigSection(), KTestCaseApi, testCaseApi); + return testCaseApi; + } + +TInt CTe_LbsLocationInfoConverterSuiteStepBase::GetPluginUid() + { + TInt pluginUid(KErrNotFound); + // Ini file key names for test cases + _LIT(KPluginUid, "plugin_uid"); + TInt err = GetIntFromConfig(ConfigSection(), KPluginUid, pluginUid); + return pluginUid; + } +void CTe_LbsLocationInfoConverterSuiteStepBase::InitWaitersL() + { + + } + + +void CTe_LbsLocationInfoConverterSuiteStepBase::DeleteWaiters() + { + + } + diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/te_locmonitorsuite/group/te_locmonitorsuite.mmp --- a/locationmgmt/locmonitor/test/te_locmonitorsuite/group/te_locmonitorsuite.mmp Thu Jun 24 11:27:31 2010 +0100 +++ b/locationmgmt/locmonitor/test/te_locmonitorsuite/group/te_locmonitorsuite.mmp Thu Jun 24 11:28:34 2010 +0100 @@ -71,7 +71,7 @@ SOURCE tstartparamsbase.cpp // Various LBS subsystem headers -USERINCLUDE ../../../lbslocmonitorclient/inc +USERINCLUDE ../../../lbslocmonitorapis/CommonClientServerApi/inc USERINCLUDE ../../../lbslocmonitorserver/inc USERINCLUDE ../../../../locationcore/LbsInternalApi/inc USERINCLUDE ../../../../locationcore/LbsNetInternalApi/inc diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/te_locmonitorsuite/src/te_locmonitorstepbase.cpp --- a/locationmgmt/locmonitor/test/te_locmonitorsuite/src/te_locmonitorstepbase.cpp Thu Jun 24 11:27:31 2010 +0100 +++ b/locationmgmt/locmonitor/test/te_locmonitorsuite/src/te_locmonitorstepbase.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -304,7 +304,11 @@ CPositionInjector::~CPositionInjector() { LBSLOG(ELogP1, "CPositionInjector::doTestStepPostambleL()\n"); - RLbsPositionUpdates::ShutDownL(); + TRAPD(err,RLbsPositionUpdates::ShutDownL()); + if(err!=KErrNone) + { + LBSLOG2(ELogP3, "RLbsPositionUpdates::ShutDownL()left with error = %d\n", err); + } } void CPositionInjector::InjectGpsPosition(const TPosition& aPosition) diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/testlocationmonitor/group/testlocationmonitor.mmp --- a/locationmgmt/locmonitor/test/testlocationmonitor/group/testlocationmonitor.mmp Thu Jun 24 11:27:31 2010 +0100 +++ b/locationmgmt/locmonitor/test/testlocationmonitor/group/testlocationmonitor.mmp Thu Jun 24 11:28:34 2010 +0100 @@ -28,6 +28,20 @@ SOURCEPATH ../src SOURCE testrlbslocmonitordb.cpp +SOURCEPATH ../../../lbslocmonitorapis/ConversionDataTypes/src +SOURCE lbslocationcommon.cpp +SOURCE lbslocationinfo.cpp +SOURCE lbslocationposinfo.cpp +SOURCE lbslocationgsminfo.cpp +SOURCE lbslocationwcdmainfo.cpp +SOURCE lbslocationwlaninfo.cpp +SOURCE lbslocationwcdmaneighbourinfo.cpp +SOURCE lbslocationgsmneighbourinfo.cpp + +SOURCEPATH ../../../lbslocmonitorapis/ConversionApi\ConversionPluginApi\src +SOURCE lbslocinfoconverterpluginbase.cpp +SOURCE lbslocinfoconverterplugincommon.cpp + // Files from real Location Monitor server SOURCEPATH ../../../lbslocmonitorserver/src SOURCE clbslocmonitormain.cpp @@ -41,6 +55,9 @@ SOURCE clbslocmonitorutils.cpp SOURCE lbslocmonitorareainfodefs.cpp SOURCE clbslocmonitorrequesthandler.cpp +SOURCE clbslocmonitorpluginresolver.cpp +SOURCE clbsconversionpositionersubsession.cpp +SOURCE clbslocmonitorconversionhandler.cpp // Panic codes //SOURCE lbslocmonitorpanic.cpp @@ -69,7 +86,7 @@ USERINCLUDE ../../../../locationcore/LbsPartnerCommon/inc USERINCLUDE ../../../../locationcore/LbsLocCommon/ServerFramework/inc USERINCLUDE ../../../../locationcore/LbsDebug/inc -USERINCLUDE ../../../../locationcore/LbsLogging/inc +USERINCLUDE ../../../../locationcore/LbsLogging/inc USERINCLUDE ../../../../locationcore/LbsCommonInternalDataTypes/inc OS_LAYER_SYSTEMINCLUDE_SYMBIAN @@ -84,6 +101,8 @@ LIBRARY etel.lib LIBRARY etelmm.lib LIBRARY commsdat.lib +LIBRARY ecom.lib +LIBRARY centralrepository.lib LIBRARY lbsinternalapi.lib LIBRARY lbsnetinternalapi.lib diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/testlocationmonitor/inc/clbsareapositionersubsession.h --- a/locationmgmt/locmonitor/test/testlocationmonitor/inc/clbsareapositionersubsession.h Thu Jun 24 11:27:31 2010 +0100 +++ b/locationmgmt/locmonitor/test/testlocationmonitor/inc/clbsareapositionersubsession.h Thu Jun 24 11:28:34 2010 +0100 @@ -46,20 +46,20 @@ This subsession is also used by clients to supply an accurate position (e.g, a position obtained with GPS) so that the position is kept in a database together with - area information. + area information. */ class CLbsAreaPositionerSubsession : public CBase, public MSubSessionImpl, public MLocMonServerDestructObserver { public: - static CLbsAreaPositionerSubsession* NewL(); + static CLbsAreaPositionerSubsession* NewL(); ~CLbsAreaPositionerSubsession(); - // From MSubSessionImpl - virtual void DispatchL(const RMessage2& aMessage); - virtual void DispatchError(const RMessage2& aMessage, TInt aError); - virtual void CreateSubSessionL(const RMessage2& aMessage, const CSecureServerBase* aServer); - virtual void CloseSubSession(); + // From MSubSessionImpl + virtual void DispatchL(const RMessage2& aMessage); + virtual void DispatchError(const RMessage2& aMessage, TInt aError); + virtual void CreateSubSessionL(const RMessage2& aMessage, const CSecureServerBase* aServer); + virtual void CloseSubSession(); // via MSubSessionImpl::MRelease void VirtualRelease(); @@ -67,22 +67,22 @@ void LocMonServerDestructed(); protected: - CLbsAreaPositionerSubsession(); - void ConstructL(); + CLbsAreaPositionerSubsession(); + void ConstructL(); - // - // action methods. - // - void GetPositionL(const RMessage2& aMessage); - void CancelGetPositionL(const RMessage2& aMessage); - void SetLastKnownPositionL(const RMessage2& aMessage); - + // + // action methods. + // + void GetPositionL(const RMessage2& aMessage); + void CancelGetPositionL(const RMessage2& aMessage); + void SetLastKnownPositionL(const RMessage2& aMessage); + private: - const CLbsLocMonitorServer* iLocMonitorServer; + const CLbsLocMonitorServer* iLocMonitorServer; - // Unique ID of this subsession - CLbsLocMonitorUtils::sessionAndSubSessionId iSubsessionId; - }; + // Unique ID of this subsession + CLbsLocMonitorUtils::sessionAndSubSessionId iSubsessionId; + }; #endif //CLBSLOCMONITORPOSITIONERSUBSESSION_H diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/testlocationmonitor/inc/clbsconversionpositionersubsession.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/testlocationmonitor/inc/clbsconversionpositionersubsession.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,76 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ + + +#ifndef CLBSCONVERSIONPOSITIONERSUBSESSION_H_ +#define CLBSCONVERSIONPOSITIONERSUBSESSION_H_ + + +#include +#include "tserverstartparams.h" +#include "csecureasbase.h" +#include "csecureserverbase.h" +#include "csecuresessionbase.h" +#include "csecuresessionsubsessionbase.h" +#include "csubsessionbase.h" +#include "messageutils.h" +#include "clbslocmonitorutils.h" + +class CLbsLocMonitorServer; + +/* + Server side subsession of the Location Monitor server. + This subsession handles client's requests for the + location info conversion. +*/ +class CLbsConversionPositionerSubsession : public CBase, + public MSubSessionImpl + { +public: + static CLbsConversionPositionerSubsession* NewL(); + + ~CLbsConversionPositionerSubsession(); + + // From MSubSessionImpl + virtual void DispatchL(const RMessage2& aMessage); + virtual void DispatchError(const RMessage2& aMessage, TInt aError); + virtual void CreateSubSessionL(const RMessage2& aMessage, const CSecureServerBase* aServer); + virtual void CloseSubSession(); + + // via MSubSessionImpl::MRelease + void VirtualRelease(); + +protected: + CLbsConversionPositionerSubsession(); + void ConstructL(); + + // + // action methods. + // + void GetPositionL(const RMessage2& aMessage); + void CancelGetPositionL(const RMessage2& aMessage); + void SetLastKnownPositionL(const RMessage2& aMessage); + +private: + + CLbsLocMonitorServer* iLocMonitorServer; + + // Unique ID of this subsession + CLbsLocMonitorUtils::sessionAndSubSessionId iSubsessionId; + }; + +#endif /*CLBSCONVERSIONPOSITIONERSUBSESSION_H_*/ diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/testlocationmonitor/inc/clbslocmonitorconversionhandler.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/testlocationmonitor/inc/clbslocmonitorconversionhandler.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,254 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Declaration of CLbsLocMonitorConversionHandler class. +* +*/ + +#ifndef CLBSLOCMONITORCONVERSIONHANDLER_H_ +#define CLBSLOCMONITORCONVERSIONHANDLER_H_ + +#include +#include +#include +#include "mlbsconversioncompleteobserver.h" +#include "rlbslocmonitordb.h" + +/** + * This class is responsible for requesting location conversion from + * the plug in and later to handle the converted information. + */ +class CLbsLocMonitorConversionHandler : public CActive, + public MLbsLocInfoConverterPluginObserver + { +public: + /** + * Validation info assosciated with each client + */ + struct TValidationInfo + { + TSecureId iClientSecureId; + }; /** + * This represent different state of conversion handler. + */ + enum TState + { + EStateIdle, + EStateValidation, + EStateConversion, + EStateCacheSave, + EStateCacheSaveComplete + }; + +public: + /** + * Creates new instance of CLbsLocMonitorConversionHandler object. + */ + static CLbsLocMonitorConversionHandler* NewL( + MLbsConversionCompleteObserver& + aConversionCompleteObserver, + TUid aConversionPluginUid ); + + /** + * Destructor + */ + ~CLbsLocMonitorConversionHandler(); + + /** + * Returns the size of converted location information to the client. + */ + void GetConvertLocationInfoSizeL(const RMessage2& aMessage); + + /** + * Returns the converted location information to the client. + */ + void GetConvertedLocationInfoL(const RMessage2& aMessage); + + /** + * Cancel location info conversion. + */ + void CancelLocationInfoConversionL(const RMessage2& aMessage); + + /** + * Returns Uid of conversion plugin that is loaded. + */ + TUid ConversionPluginUid(); + + /** + * Returns ETrue is any message corresponding to subsession id + * is present in the handler. + */ + TBool IsMessagePresent(const RMessage2& aMessage); + + /** + * Returns ETrue if secure id and subsession id matches else EFalse. + */ + TBool CompareMessage(const RMessage2& aSrc,const RMessage2& aDes); + + + TReal32 AccuracyFromMatchLevel(TPositionAreaExtendedInfo::TArea aMatchlevel); + + + +public: // from MLbsLocInfoConverterPluginObserver + virtual void OnConversionComplete(TInt aStatusCode); + + virtual void OnValidationComplete(TInt aStatusCode); + +protected: // from CActive + void RunL(); + void DoCancel(); + +private: + /** + * Constructor. + */ + CLbsLocMonitorConversionHandler(MLbsConversionCompleteObserver& + aConversionCompleteObserver); + + /** + * Symbian 2 phase constructor. + */ + void ConstructL(TUid aConversionPluginUid); + + /** + * Processes the request which is recently validated. + */ + TInt ProcessRequestL(); + + /** + * Loads the conversion module specified by client. + */ + void LoadConversionPluginL(TUid aConversionModuleId); + + /** + * Writes converted position information to the stream. + */ + void WriteAreaInfoL(RBufWriteStream& aWriteStream, + CLbsLocationInfo::TAreaInfoMask aAreaInfoMask); + + /** + * Completes client's message. + */ + void CompleteRequest(const RMessage2& aMessage,TInt aReason); + + /** + * This is called after each conversion request complete + */ + void RequestCompleteL(); + + + void WriteResultToBufferL(); + + + /** + * Fills in partial results from cache where they are better than those returned from the plugin + */ + void FillInPartialL(); + + /** + * Sends requests from iRequestedInfo to the cacne and uses the result to + * fill in iCacheLookupResults, the RunL will decide which responses to + * write back into iRequestedInfo and send back to the client + */ + TBool CacheLookupL(); + + /* + * Writes any cellid + location pairs received as part of a query back into + * the cache + */ + TBool CacheSaveL(); + +private: // Member variables + /** + * Handle to conversion complete observer + */ + MLbsConversionCompleteObserver& iConversionCompleteObserver; + + /** + * Conversion request. + */ + RMessage2 iConversionRequest; + + /** + * Validation request array. + */ + RArray iValidationRequestQueue; + + /** + * Pointer to conversion plugin + */ + CLbsLocInfoConverterPluginBase* iLocInfoConverterPlugIn; + + /** + * Handle to buffer that contains converted information. + */ + CBufFlat* iBuffer; + + /** + * Client specified request info + */ + TLbsConversionOutputInfoMask iRequestedInfo; + + /** + * Location information array passed from client. + */ + RLbsLocationInfoArray iLocationInfoArray; + + + /** + * A subset of location information array passed from client. + * requests that have been solved by the cache are ommitted + * this array DOES NOT OWN its contents and should not destroy them. + * as the ownership remains with iLocationInfoArray + */ + RLbsLocationInfoArray iSubsetLocationInfoArray; + + /** + * Uid of currently loaded conversion plug in + */ + TUid iConversionPluginId; + + /** + * State of conversion handler. + */ + TState iState; + + /** + * Secure id of client that has outstanding request + */ + TSecureId iCurrentRequestSecureId; + + /** + * Subsession id of client that has outstanding request + */ + TInt iCurrentRequestSubsessionId; + + + /* + * Cache lookup results + */ + RArray iCachePartialResults; + + + /** + * Cache for lookups + */ + RLbsLocMonitorDb iCache; + + + TInt iSavedToCacheCount; + + }; + +#endif /*CLBSLOCMONITORCONVERSIONHANDLER_H_*/ diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/testlocationmonitor/inc/clbslocmonitordbengine.h --- a/locationmgmt/locmonitor/test/testlocationmonitor/inc/clbslocmonitordbengine.h Thu Jun 24 11:27:31 2010 +0100 +++ b/locationmgmt/locmonitor/test/testlocationmonitor/inc/clbslocmonitordbengine.h Thu Jun 24 11:28:34 2010 +0100 @@ -22,16 +22,15 @@ //------------------------------------------------------------------------------- #include -#include -#include +#include +#include #include #include "rlbslocmonitordb.h" -#include "clbslocmonitordbtimer.h" //------------------------------------------------------------------------------- /** */ -class CLbsLocMonitorDbEngine : public CActive, MLocMonitorDBCallback +class CLbsLocMonitorDbEngine : public CActive { public: @@ -43,9 +42,7 @@ TUint aCid, TPosition& aPosition, TPositionAreaExtendedInfo& aMatchingAreaInfo, TRequestStatus& aStatus); TInt GetPosition(TPosition& aPosition, TRequestStatus& aStatus); TInt ClearDatabase(); - - // from CLbsLocMonitorDbTimer - void FlushTimerCallback(); + static TInt FlushTimerCallback(TAny* aPtr); private: @@ -65,13 +62,12 @@ private: RSqlDatabase iDatabase; + CPeriodic* iPeriodic; TTimeIntervalMicroSeconds32 iFlushInterval; TInt iCount; RSqlStatement iSqlSaveStatement; TRequestStatus* iClientStatus; - CLbsLocMonitorDbTimer* iDbTimer; - TBool iDBInitialised; TInt iLastMcc; TInt iLastMnc; TInt iLastLac; diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/testlocationmonitor/inc/clbslocmonitorgpsbus.h --- a/locationmgmt/locmonitor/test/testlocationmonitor/inc/clbslocmonitorgpsbus.h Thu Jun 24 11:27:31 2010 +0100 +++ b/locationmgmt/locmonitor/test/testlocationmonitor/inc/clbslocmonitorgpsbus.h Thu Jun 24 11:28:34 2010 +0100 @@ -71,7 +71,7 @@ class MLbsLocMonitorGpsBusObserver { public: - virtual void GpsPositionAvailable(const TPosition& aPosition) = 0; + virtual void GpsPositionAvailableL(const TPosition& aPosition) = 0; }; #endif // CLBSLOCMONITORGPSBUS_H \ No newline at end of file diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/testlocationmonitor/inc/clbslocmonitorpluginresolver.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/testlocationmonitor/inc/clbslocmonitorpluginresolver.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,86 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Declaration of CLbsLocMonitorPluginResolver class +* +*/ + +#ifndef CLBSLOCMONITORPLUGINRESOLVER_H_ +#define CLBSLOCMONITORPLUGINRESOLVER_H_ + +#include +#include + +/** + * This class is responsible for choosing the default converter plugin based + * on vendorid and plugin priority. + * + */ +class CLbsLocMonitorPluginResolver : public CActive + { +public: + /** + * Constructs new object of CLbsLocMonitorPluginResolver. + */ + static CLbsLocMonitorPluginResolver* NewL(); + + /** + * Destructor. + */ + ~CLbsLocMonitorPluginResolver(); + + /** + * Returns uid of default converter. + * @param[out] aConverterPluginUid Default converter plugin id. + * @return KErrNotFound If none of converter plugin available. + */ + TInt DefaultConverterUid(TUid& aConverterPluginUid); + +protected: // From CActive + void RunL(); + void DoCancel(); + + +private: + /** + * Default constructor. + */ + CLbsLocMonitorPluginResolver(); + + /** + * Symbian 2nd phase constructor. + */ + void ConstructL(); + + /** + * Finds default converter plugin + */ + void FindDefaultConverterPluginL(); + + /** + * + */ + TInt PriorityInfo(const TDesC8& aOpaqueData); +private: // Member variables + + /** + * Pointer to ecom session + */ + REComSession* iEcomSession; + + /** + * Default converter plugin uid. + */ + TUid iDefaultConverterPluginId; + }; +#endif /* CLBSLOCMONITORPLUGINRESOLVER_H_ */ diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/testlocationmonitor/inc/clbslocmonitorposlistener.h --- a/locationmgmt/locmonitor/test/testlocationmonitor/inc/clbslocmonitorposlistener.h Thu Jun 24 11:27:31 2010 +0100 +++ b/locationmgmt/locmonitor/test/testlocationmonitor/inc/clbslocmonitorposlistener.h Thu Jun 24 11:28:34 2010 +0100 @@ -23,7 +23,7 @@ class MLbsLocMonitorPosListenerObserver { public: - virtual void PositionAvailable(const TPosition& aPosition) = 0; + virtual void PositionAvailableL(const TPosition& aPosition) = 0; }; /** @@ -44,7 +44,7 @@ ~CLbsLocMonitorPosListener(); // From MLbsLocMonitorGpsBusObserver - void GpsPositionAvailable(const TPosition& aPosition); + void GpsPositionAvailableL(const TPosition& aPosition); private: CLbsLocMonitorPosListener(MLbsLocMonitorPosListenerObserver& aObserver); diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/testlocationmonitor/inc/clbslocmonitorrequesthandler.h --- a/locationmgmt/locmonitor/test/testlocationmonitor/inc/clbslocmonitorrequesthandler.h Thu Jun 24 11:27:31 2010 +0100 +++ b/locationmgmt/locmonitor/test/testlocationmonitor/inc/clbslocmonitorrequesthandler.h Thu Jun 24 11:28:34 2010 +0100 @@ -126,7 +126,7 @@ as a consequence of a new position being observed on an internal position bus. */ - void PositionAvailable(const TPosition& aPosition); + void PositionAvailableL(const TPosition& aPosition); private: diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/testlocationmonitor/inc/clbslocmonitorserver.h --- a/locationmgmt/locmonitor/test/testlocationmonitor/inc/clbslocmonitorserver.h Thu Jun 24 11:27:31 2010 +0100 +++ b/locationmgmt/locmonitor/test/testlocationmonitor/inc/clbslocmonitorserver.h Thu Jun 24 11:28:34 2010 +0100 @@ -33,10 +33,12 @@ #include "clbslocmonitorposlistener.h" #include "lbsrootapi.h" #include "lbsprocesssupervisor.h" +#include "mlbsconversioncompleteobserver.h" +#include "clbslocmonitorconversionhandler.h" +#include "clbslocmonitorpluginresolver.h" -// forward classes -//class CLbsLocMonitorPositonWriter; + class CSession2; /** @@ -90,7 +92,8 @@ @released */ class CLbsLocMonitorServer : public CSecureServerBase, - public MLbsProcessCloseDown + public MLbsProcessCloseDown, + public MLbsConversionCompleteObserver { enum TAreaInfoFinder @@ -112,18 +115,28 @@ // to database for writting and reading positions and area info. CLbsLocMonitorRequestHandler& ReadRequestHandler() const; + CLbsLocMonitorConversionHandler* ConversionHandlerL( TUid aConversionPluginId ); + + CLbsLocMonitorConversionHandler* ConversionHandler( const RMessage2& aMessage ); + + CLbsLocMonitorPluginResolver* PluginResolver(); + void SetLocMonServerDestructObserverL(const MLocMonServerDestructObserver& aDestructObserver); void UnsetLocMonServerDestructObserver(const MLocMonServerDestructObserver& aDestructObserver); public: // From MLbsProcessCloseDown void OnProcessCloseDown(); + +public: // From MLbsConversionCompleteObserver + void HandleConversionComplete( CLbsLocMonitorConversionHandler* + aConversionHandler ); protected: // From CSecureServerBase (from CPolicyServer) CPolicyServer::TCustomResult CustomSecurityCheckL(const RMessage2& aMsg, TInt& aAction, TSecurityInfo& aMissing); TBool FindRootProcess(); - + protected: TVersion iVersion; @@ -138,6 +151,9 @@ CLbsCloseDownRequestDetector* iCloseDownRequestDetector; + RPointerArray iConversionHandlerArray; + + CLbsLocMonitorPluginResolver* iPluginResolver; RPointerArray iDestructionObservers; }; diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/testlocationmonitor/inc/clbslocmonitorsession.h --- a/locationmgmt/locmonitor/test/testlocationmonitor/inc/clbslocmonitorsession.h Thu Jun 24 11:27:31 2010 +0100 +++ b/locationmgmt/locmonitor/test/testlocationmonitor/inc/clbslocmonitorsession.h Thu Jun 24 11:28:34 2010 +0100 @@ -26,7 +26,6 @@ #define CLBSLOCMONITORSESSION_H #include -//#include #include "tserverstartparams.h" #include "csecureasbase.h" #include "csecureserverbase.h" @@ -35,7 +34,7 @@ #include "csubsessionbase.h" #include "messageutils.h" -/* +/** Client side session of the Location Monitor server. It derives from the class CSecureSessionSubSessionBase (from Server Framework) diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/testlocationmonitor/inc/lbslocmonitorareainfodefs.h --- a/locationmgmt/locmonitor/test/testlocationmonitor/inc/lbslocmonitorareainfodefs.h Thu Jun 24 11:27:31 2010 +0100 +++ b/locationmgmt/locmonitor/test/testlocationmonitor/inc/lbslocmonitorareainfodefs.h Thu Jun 24 11:28:34 2010 +0100 @@ -78,4 +78,4 @@ TUint iCid; }; -#endif // LBSLOCMONITORAREAINFODEFS_H \ No newline at end of file +#endif // LBSLOCMONITORAREAINFODEFS_H diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/testlocationmonitor/inc/lbslocmonitorclientconsts.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/testlocationmonitor/inc/lbslocmonitorclientconsts.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,58 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ + + +#ifndef LBSLOCMONITORCLIENTCONSTS_H_ +#define LBSLOCMONITORCLIENTCONSTS_H_ + +#include +#include + +/** + * Message parameters index in a message of RMessage2. The server has to use + * the parameter index defined below to write and read data into the IPC message. + */ + +// This position in the IPC is used by the client library to receive +// buffer size. +const TInt KParamBufferSize = 0; + + +// This position in the IPC is used by the client library to send location +// information. +const TInt KParamLocationInfo = 1; + +// This position in the IPC is used by the client library to send client preferences. +const TInt KParamClientPrefs = 2; + +// This position in the IPC is used by the server to send converted info +const TInt KParamConvertedInfo = 0; + +/** + * This structure holds conversion prefs,location info mask and + * the conversion module id. + */ +struct TLbsClientPrefs + { + TLbsConversionPrefs iConversionPrefs; + + TLbsConversionOutputInfoMask iRequestedInfo; + + TUid iConverterModuleId; + }; + +#endif /*LBSLOCMONITORCLIENTCONSTS_H_*/ diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/testlocationmonitor/inc/lbslocmonitordbenginedefs.h --- a/locationmgmt/locmonitor/test/testlocationmonitor/inc/lbslocmonitordbenginedefs.h Thu Jun 24 11:27:31 2010 +0100 +++ b/locationmgmt/locmonitor/test/testlocationmonitor/inc/lbslocmonitordbenginedefs.h Thu Jun 24 11:28:34 2010 +0100 @@ -25,11 +25,13 @@ const TTimeIntervalMicroSeconds32 KInitialPeriod = 200000000; const TTimeIntervalMicroSeconds32 KFlushPeriod = 30000000; -// Secure database name MUST contain UID of process that owns it -#ifndef LBS_LOCMONITORDB_TEST + +#if defined (LBS_LOCMONITORDB_TEST) && defined (__WINS__) // Unit test emulator +_LIT(KSecureLocMonDB, "C:\\lastknownlocarea.db"); +#elif defined (LBS_LOCMONITORDB_TEST) && !defined (__WINSCW__) // Unit test hw +_LIT(KSecureLocMonDB, "E:\\lastknownlocarea.db"); +#else // production code _LIT(KSecureLocMonDB, "[102869DF]lastknownlocarea.db"); -#else -_LIT(KSecureLocMonDB, "[102869E2]lastknownlocarea.db"); #endif _LIT(KCreateTable, "CREATE TABLE monitorstore (mcc INTEGER, mnc INTEGER, lac INTEGER, cid INTEGER, date INTEGER, data TEXT);"); diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/testlocationmonitor/inc/lbslocmonitorserverdata.h --- a/locationmgmt/locmonitor/test/testlocationmonitor/inc/lbslocmonitorserverdata.h Thu Jun 24 11:27:31 2010 +0100 +++ b/locationmgmt/locmonitor/test/testlocationmonitor/inc/lbslocmonitorserverdata.h Thu Jun 24 11:28:34 2010 +0100 @@ -72,7 +72,13 @@ EGetLastKnownPositionArea = EAreaPositionerFirstMsgId + 2, ECancelGetLastKnownPosition = EAreaPositionerFirstMsgId + 3, ECancelGetLastKnownPositionArea = EAreaPositionerFirstMsgId + 4, - + + EConvertSingleLocationInfoBufferSize = EAreaPositionerFirstMsgId + 5, + EGetSingleLocationInfo = EAreaPositionerFirstMsgId + 6, + EConvertMultipleLocationInfoBufferSize = EAreaPositionerFirstMsgId + 7, + EGetMultipleLocationInfo = EAreaPositionerFirstMsgId + 8, + ECancelConvertLocationInfo = EAreaPositionerFirstMsgId + 9, + // Add here any new message IDs for subsession type AreaPositioner EAreaPositionerLastMessageId, @@ -89,6 +95,8 @@ { ELocMonitorSubSessionTypeUnknown = 0, ELocMonitorSubSessionTypeAreaPositioner, + ELocMonitorSubSessionTypeConversionPositiner, + ELocMonitorSubSessionTypeLocInfoConverter, }; /* Initialisation data sent to the Location Monitor server @@ -97,9 +105,18 @@ class TLbsLocMonitorAreaPositionerData { public: - TInt aUnused; /* Reserved for future use */ + TInt iUnused; /* Reserved for future use */ }; +/* Initialisation data sent to the Location Monitor server + when creating a new conversion Positioner subsession. +*/ +class TLbsLocMonitorConversionPositionerData + { +public: + TInt iUnused; /* Reserved for future use */ + }; + /* Parameters sent from client to server in a GetLastKnownPositionArea request diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/testlocationmonitor/inc/locmonitorsettingskeys.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/testlocationmonitor/inc/locmonitorsettingskeys.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,34 @@ +/* +* Copyright (c) 2006 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Defines the cenrep keys of location monitor +* +*/ + + +#ifndef LOCMONITORSETTINGSKEYS_H +#define LOCMONITORSETTINGSKEYS_H + +// CONSTANTS + +// ENUMERATION FOR CENTRAL REPOSITORY KEYS +enum TCenRepKeys + { + EPhoneVendorId = 0x00000001, + }; + +// CENTRAL REPOSITORY UID +const TUid KCRUidLocMonitorSettings = {0x20026814}; + + +#endif // LOCMONITORSETTINGSKEYS_H diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/locmonitor/test/testlocationmonitor/inc/mlbsconversioncompleteobserver.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locationmgmt/locmonitor/test/testlocationmonitor/inc/mlbsconversioncompleteobserver.h Thu Jun 24 11:28:34 2010 +0100 @@ -0,0 +1,37 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ + +#ifndef MLBSCONVERSIONCOMPLETEOBSERVER_H_ +#define MLBSCONVERSIONCOMPLETEOBSERVER_H_ + +// Forward declarations +class CLbsLocMonitorConversionHandler; + +/** + * Class that needs to implement this interface to listen + * to conversion complete event from the handler. + * + */ +class MLbsConversionCompleteObserver + { +public: + virtual void HandleConversionComplete( CLbsLocMonitorConversionHandler* + aConversionHandler ) = 0; + }; + + +#endif /*MLBSCONVERSIONCOMPLETEOBSERVER_H_*/ diff -r 8e58c1bec439 -r a85dbb892d75 locationmgmt/networkgateway/group/lbsnetgateway.mmp --- a/locationmgmt/networkgateway/group/lbsnetgateway.mmp Thu Jun 24 11:27:31 2010 +0100 +++ b/locationmgmt/networkgateway/group/lbsnetgateway.mmp Thu Jun 24 11:28:34 2010 +0100 @@ -59,7 +59,7 @@ USERINCLUDE ../../locationcore/LbsLogging/inc USERINCLUDE ../../locationcore/LbsNetProtocol/inc USERINCLUDE ../../locationcore/LbsDebug/inc -USERINCLUDE ../../locmonitor/lbslocmonitorclient/inc +USERINCLUDE ../../locmonitor/lbslocmonitorapis/CommonClientServerApi/inc USERINCLUDE ../../locmonitor/lbslocmonitorserver/inc OS_LAYER_SYSTEMINCLUDE_SYMBIAN diff -r 8e58c1bec439 -r a85dbb892d75 locationrequestmgmt/locationserver/group/EPos_Server.mmp --- a/locationrequestmgmt/locationserver/group/EPos_Server.mmp Thu Jun 24 11:27:31 2010 +0100 +++ b/locationrequestmgmt/locationserver/group/EPos_Server.mmp Thu Jun 24 11:28:34 2010 +0100 @@ -65,7 +65,7 @@ USERINCLUDE ../../../locationmgmt/locationcore/LbsPartnerCommon/inc // for the lbsdevloggermacros.h USERINCLUDE ../../../locationmgmt/locationcore/LbsCommonInternalDataTypes/inc // for using loc monitor (sub)session -USERINCLUDE ../../../locationmgmt/locmonitor/lbslocmonitorclient/inc +USERINCLUDE ../../../locationmgmt/locmonitor/lbslocmonitorapis/CommonClientServerApi/inc/ USERINCLUDE ../../../locationmgmt/locmonitor/lbslocmonitorserver/inc USERINCLUDE ../../../locationmgmt/locationcore/LbsLocCommon/ServerFramework/inc USERINCLUDE ../../../locationmgmt/locationcore/LbsNetRegStatusInt/inc diff -r 8e58c1bec439 -r a85dbb892d75 locationrequestmgmt/locationserver/lbstestpsys/group/bld.inf --- a/locationrequestmgmt/locationserver/lbstestpsys/group/bld.inf Thu Jun 24 11:27:31 2010 +0100 +++ b/locationrequestmgmt/locationserver/lbstestpsys/group/bld.inf Thu Jun 24 11:28:34 2010 +0100 @@ -14,8 +14,6 @@ * Description: * */ -// BLD.INF -// Component description file PRJ_PLATFORMS DEFAULT diff -r 8e58c1bec439 -r a85dbb892d75 locationrequestmgmt/locationserver/test/te_locsrvtestlocmonsuite/group/bld.inf --- a/locationrequestmgmt/locationserver/test/te_locsrvtestlocmonsuite/group/bld.inf Thu Jun 24 11:27:31 2010 +0100 +++ b/locationrequestmgmt/locationserver/test/te_locsrvtestlocmonsuite/group/bld.inf Thu Jun 24 11:28:34 2010 +0100 @@ -20,7 +20,7 @@ // Locserver's unit test is dependent on these test location monitor components // Modified Location Server that uses the test location monitor API #include "../../testLocMonitorApi/group/bld.inf" -#include "../../testLocMonitorServer/group/BLD.INF" +#include "../../testLocMonitorServer/group/bld.inf" #include "../../testLocServer/group/bld.inf" diff -r 8e58c1bec439 -r a85dbb892d75 locationrequestmgmt/networkrequesthandler/LBSPrivacyNotification/LbsQueryAndNotification/group/BLD.INF --- a/locationrequestmgmt/networkrequesthandler/LBSPrivacyNotification/LbsQueryAndNotification/group/BLD.INF Thu Jun 24 11:27:31 2010 +0100 +++ b/locationrequestmgmt/networkrequesthandler/LBSPrivacyNotification/LbsQueryAndNotification/group/BLD.INF Thu Jun 24 11:28:34 2010 +0100 @@ -13,5 +13,5 @@ // Description: // -#include "../PrivacyDataTypes/group/Bld.inf" -#include "../QueryAndNotificationAPI/group/Bld.inf" +#include "../PrivacyDataTypes/group/bld.inf" +#include "../QueryAndNotificationAPI/group/bld.inf" diff -r 8e58c1bec439 -r a85dbb892d75 locationrequestmgmt/networkrequesthandler/LBSPrivacyNotification/group/BLD.INF --- a/locationrequestmgmt/networkrequesthandler/LBSPrivacyNotification/group/BLD.INF Thu Jun 24 11:27:31 2010 +0100 +++ b/locationrequestmgmt/networkrequesthandler/LBSPrivacyNotification/group/BLD.INF Thu Jun 24 11:28:34 2010 +0100 @@ -13,8 +13,8 @@ // Description: // -#include "../LbsPrivacyController/group/BLD.INF" -#include "../LbsPrivacyExtNotifiers/group/BLD.INF" +#include "../LbsPrivacyController/group/bld.inf" +#include "../LbsPrivacyExtNotifiers/group/bld.inf" #ifdef SYMBIAN_LOCATION_PRIVACY_V2 - #include "../LbsQueryAndNotification/group/BLD.INF" + #include "../LbsQueryAndNotification/group/bld.inf" #endif diff -r 8e58c1bec439 -r a85dbb892d75 locationrequestmgmt/networkrequesthandler/LbsX3P/group/BLD.INF --- a/locationrequestmgmt/networkrequesthandler/LbsX3P/group/BLD.INF Thu Jun 24 11:27:31 2010 +0100 +++ b/locationrequestmgmt/networkrequesthandler/LbsX3P/group/BLD.INF Thu Jun 24 11:28:34 2010 +0100 @@ -14,5 +14,5 @@ // // Main projects, in build order -#include "../LbsX3PApi/group/BLD.INF" +#include "../LbsX3PApi/group/bld.inf" diff -r 8e58c1bec439 -r a85dbb892d75 locationrequestmgmt/networkrequesthandler/group/bld.inf --- a/locationrequestmgmt/networkrequesthandler/group/bld.inf Thu Jun 24 11:27:31 2010 +0100 +++ b/locationrequestmgmt/networkrequesthandler/group/bld.inf Thu Jun 24 11:28:34 2010 +0100 @@ -13,8 +13,8 @@ // Description: // -#include "../LBSPrivacyNotification/group/BLD.INF" -#include "../LbsX3P/group/BLD.INF" +#include "../LBSPrivacyNotification/group/bld.inf" +#include "../LbsX3P/group/bld.inf" #include "../test/group/bld.inf" diff -r 8e58c1bec439 -r a85dbb892d75 locationrequestmgmt/networkrequesthandler/inc/EPos_CPosDialogCtrl.h --- a/locationrequestmgmt/networkrequesthandler/inc/EPos_CPosDialogCtrl.h Thu Jun 24 11:27:31 2010 +0100 +++ b/locationrequestmgmt/networkrequesthandler/inc/EPos_CPosDialogCtrl.h Thu Jun 24 11:28:34 2010 +0100 @@ -209,7 +209,8 @@ void DeferNotificationL(); void CreateNotificationAndEnqueueL(); - + void UpdateProperty(); + private: // Data RNotifier iNotifier; RArray iRequestQueue; diff -r 8e58c1bec439 -r a85dbb892d75 locationrequestmgmt/networkrequesthandler/src/EPos_CPosDialogCtrl.cpp --- a/locationrequestmgmt/networkrequesthandler/src/EPos_CPosDialogCtrl.cpp Thu Jun 24 11:27:31 2010 +0100 +++ b/locationrequestmgmt/networkrequesthandler/src/EPos_CPosDialogCtrl.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -17,6 +17,7 @@ // INCLUDE FILES #include +#include #include #include #include @@ -36,6 +37,9 @@ const TUid KNotifierUid = { KPosPrivacyNotifierImplUid }; #endif // NRH_UNIT_TEST +// P&S Key so NG can check the status of notifications +const TInt EPrivacyNumberOfRequest = 0x1028720F; + // The output descriptor for Notifier calls. Since we want to pass // just a dummy null descriptor there is no need to create a HBufC // each time. @@ -58,6 +62,10 @@ { TInt err = iNotifier.Connect(); User::LeaveIfError(err); + + // Define the property + RProperty::Define(KUidSystemCategory, EPrivacyNumberOfRequest, RProperty::EInt); + UpdateProperty(); } // Two-phased constructor. @@ -78,12 +86,11 @@ for (TInt i = 0; i < count; i++) { DoCompleteRequest(0, KErrServerTerminated); - // Delete the pointer items - delete iRequestQueue[i].iRequestInfo; } iNotifier.Close(); iRequestQueue.Close(); + RProperty::Delete(KUidSystemCategory, EPrivacyNumberOfRequest); } // --------------------------------------------------------- @@ -279,10 +286,19 @@ TInt aIndex, TInt aCompletionCode) { - TRequestStatus* status = iRequestQueue[aIndex].iStatus; - User::RequestComplete(status, aCompletionCode); + TRequest request = iRequestQueue[aIndex]; + if (request.iType == TPosQNInputData::ENotification) + { + delete request.iRequestInfo; + } + else + { + TRequestStatus* status = request.iStatus; + User::RequestComplete(status, aCompletionCode); + } iRequestQueue.Remove(aIndex); iRequestQueue.Compress(); + UpdateProperty(); } // --------------------------------------------------------- @@ -296,6 +312,7 @@ // Start a new request. aRequest.iId = ++iRequestId; User::LeaveIfError(iRequestQueue.Append(aRequest)); + UpdateProperty(); if (iRequestQueue.Count() == 1) { @@ -365,22 +382,10 @@ delete reqStackBuf; reqStackBuf = NULL; - if (data.iType == TPosQNInputData::ENotification) // We dont expect a resonse from a notfication - { - iNotifier.StartNotifier(KNotifierUid, nullPtr, nullPtr); - - // As we wont be getting a response remove from the notification list - delete iRequestQueue[0].iRequestInfo; - iRequestQueue.Remove(0); - iRequestQueue.Compress(); - } - else - { - iNotifier.StartNotifierAndGetResponse( - iStatus, KNotifierUid, nullPtr, nullPtr); - SetActive(); - } - + iNotifier.StartNotifierAndGetResponse( + iStatus, KNotifierUid, nullPtr, nullPtr); + SetActive(); + err = iNotifier.UpdateNotifier(KNotifierUid, *buffer, nullPtr); if (err != KErrNone) { @@ -623,11 +628,13 @@ if ( iRequestQueue[i].iType == TPosQNInputData::ENotification ) { User::LeaveIfError(iRequestQueue.Insert( aRequest,i )); + UpdateProperty(); return; } } User::LeaveIfError(iRequestQueue.Append(aRequest)); + UpdateProperty(); } // --------------------------------------------------------- @@ -647,6 +654,7 @@ } iRequestQueue.Remove(0); iRequestQueue.Compress(); + UpdateProperty(); NextRequest(); } @@ -691,4 +699,11 @@ CleanupStack::Pop(requestinfocopy); } + +void CPosDialogCtrl::UpdateProperty() + { + RProperty::Set(KUidSystemCategory, EPrivacyNumberOfRequest, iRequestQueue.Count()); + } + + // End of File diff -r 8e58c1bec439 -r a85dbb892d75 locationrequestmgmt/networkrequesthandler/src/EPos_CPosPrivManager.cpp --- a/locationrequestmgmt/networkrequesthandler/src/EPos_CPosPrivManager.cpp Thu Jun 24 11:27:31 2010 +0100 +++ b/locationrequestmgmt/networkrequesthandler/src/EPos_CPosPrivManager.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -287,7 +287,6 @@ { iRequestData.iNotificationReason = EPosDecisionByRequestSource; iDlgCtrl->NotifyL(*iRequestInfo, iRequestData); - delete iRequestInfo; iRequestInfo = NULL; iRequestInfo = new (ELeave) TLbsExternalRequestInfo2; } @@ -396,7 +395,6 @@ iRequestData.iCancelReason = EPosCancelReasonNotAvailable; iDlgCtrl->NotifyL(*iRequestInfo, iRequestData); - delete iRequestInfo; iRequestInfo = NULL; iRequestInfo = new (ELeave) TLbsExternalRequestInfo2; } diff -r 8e58c1bec439 -r a85dbb892d75 networkprotocolmodules/privacyprotocolmodule/PrivacyProtocolModule/inc/privacyshutdown.h --- a/networkprotocolmodules/privacyprotocolmodule/PrivacyProtocolModule/inc/privacyshutdown.h Thu Jun 24 11:27:31 2010 +0100 +++ b/networkprotocolmodules/privacyprotocolmodule/PrivacyProtocolModule/inc/privacyshutdown.h Thu Jun 24 11:28:34 2010 +0100 @@ -58,6 +58,7 @@ private: TShutdownState iState; + TTimeIntervalMicroSeconds32 iTimerCount; }; #endif // __PRIVACYSHUTDOWN_H__ diff -r 8e58c1bec439 -r a85dbb892d75 networkprotocolmodules/privacyprotocolmodule/PrivacyProtocolModule/src/privacyshutdown.cpp --- a/networkprotocolmodules/privacyprotocolmodule/PrivacyProtocolModule/src/privacyshutdown.cpp Thu Jun 24 11:27:31 2010 +0100 +++ b/networkprotocolmodules/privacyprotocolmodule/PrivacyProtocolModule/src/privacyshutdown.cpp Thu Jun 24 11:28:34 2010 +0100 @@ -19,6 +19,10 @@ #include "privacyshutdown.h" +// P&S Key we check how many outstanding requests there are +const TInt EPrivacyNumberOfRequest = 0x1028720F; + + /** Static public constructor */ @@ -39,7 +43,8 @@ add timer to active scheduler. */ CPrivacyShutdown::CPrivacyShutdown() : CTimer(CActive::EPriorityStandard), - iState(EShutdownStateIdle) + iState(EShutdownStateIdle), + iTimerCount(0) { LBSLOG(ELogP1, "CPrivacyShutdown::CPrivacyShutdown() Begin\n"); CActiveScheduler::Add(this); @@ -79,6 +84,7 @@ { LBSLOG(ELogP1, "CPrivacyShutdown::Start() Begin\n"); iState = EShutdownStateTimerStarted; + iTimerCount = aDelay; After(aDelay); LBSLOG(ELogP1, "CPrivacyShutdown::Start() End\n"); } @@ -102,16 +108,27 @@ { LBSLOG(ELogP1, "CPrivacyShutdown::RunL() Begin\n"); - iState = EShutdownStateShutdownRequested; - - RLbsSystemController systemController; - RProcess process; - systemController.OpenL(process.SecureId()); - CleanupClosePushL(systemController); - - systemController.RequestSystemCloseDown(ETrue); - - CleanupStack::PopAndDestroy(&systemController); + // Check if there are any notifications outstanding + TInt outstandingRequests = 0; + RProperty::Get(KUidSystemCategory, EPrivacyNumberOfRequest, outstandingRequests); + if (outstandingRequests > 0) + { + LBSLOG(ELogP1, "CPrivacyShutdown::RunL() - Restarting Timer\n") + Start(iTimerCount); + } + else + { + iState = EShutdownStateShutdownRequested; + + RLbsSystemController systemController; + RProcess process; + systemController.OpenL(process.SecureId()); + CleanupClosePushL(systemController); + + systemController.RequestSystemCloseDown(ETrue); + + CleanupStack::PopAndDestroy(&systemController); + } LBSLOG(ELogP1, "CPrivacyShutdown::RunL() End\n"); } diff -r 8e58c1bec439 -r a85dbb892d75 networkprotocolmodules/privacyprotocolmodule/test/group/bld.inf --- a/networkprotocolmodules/privacyprotocolmodule/test/group/bld.inf Thu Jun 24 11:27:31 2010 +0100 +++ b/networkprotocolmodules/privacyprotocolmodule/test/group/bld.inf Thu Jun 24 11:28:34 2010 +0100 @@ -14,5 +14,5 @@ // #include "../te_lbsnetworkprivacy/group/bld.inf" -#include "../te_dummynetgateway/group/BLD.INF" -#include "../te_lbsprivfwcap/group/BLD.INF" +#include "../te_dummynetgateway/group/bld.inf" +#include "../te_lbsprivfwcap/group/bld.inf" diff -r 8e58c1bec439 -r a85dbb892d75 networkprotocolmodules/suplcontrolplaneprotocols/common/suplrrlpprotocol/test/te_suplrrlp/group/bld.inf --- a/networkprotocolmodules/suplcontrolplaneprotocols/common/suplrrlpprotocol/test/te_suplrrlp/group/bld.inf Thu Jun 24 11:27:31 2010 +0100 +++ b/networkprotocolmodules/suplcontrolplaneprotocols/common/suplrrlpprotocol/test/te_suplrrlp/group/bld.inf Thu Jun 24 11:28:34 2010 +0100 @@ -14,7 +14,7 @@ // PRJ_TESTEXPORTS -../scripts/te_suplrrlpSuite.script c:/testdata/scripts/te_suplrrlpSuite.script +../scripts/te_suplrrlpsuite.script c:/testdata/scripts/te_suplrrlpsuite.script ../testdata/te_suplrrlpsuite.ini c:/testdata/configs/te_suplrrlpsuite.ini te_suplrrlpsuite.iby /epoc32/rom/include/te_suplrrlpsuite.iby diff -r 8e58c1bec439 -r a85dbb892d75 networkprotocolmodules/suplproxyprotocolmodule/suplproxyprotocolmodule/group/bld.inf --- a/networkprotocolmodules/suplproxyprotocolmodule/suplproxyprotocolmodule/group/bld.inf Thu Jun 24 11:27:31 2010 +0100 +++ b/networkprotocolmodules/suplproxyprotocolmodule/suplproxyprotocolmodule/group/bld.inf Thu Jun 24 11:28:34 2010 +0100 @@ -19,8 +19,8 @@ PRJ_EXPORTS lbssuplproxyprotocolmodule.iby /epoc32/rom/include/lbssuplproxyprotocolmodule.iby -102871ED.cre z:/private/10202be9/102871ED.cre +102871ed.cre z:/private/10202be9/102871ed.cre // ConfML files ../conf/suplproxyprotocolmodule.confml OS_LAYER_EXPORTS_CONFML(suplproxyprotocolmodule.confml) -../conf/suplproxyprotocolmodule_102871ED.crml OS_LAYER_EXPORTS_CRML(suplproxyprotocolmodule_102871ED.crml) +../conf/suplproxyprotocolmodule_102871ed.crml OS_LAYER_EXPORTS_CRML(suplproxyprotocolmodule_102871ed.crml) diff -r 8e58c1bec439 -r a85dbb892d75 networkprotocolmodules/suplproxyprotocolmodule/test/group/bld.inf --- a/networkprotocolmodules/suplproxyprotocolmodule/test/group/bld.inf Thu Jun 24 11:27:31 2010 +0100 +++ b/networkprotocolmodules/suplproxyprotocolmodule/test/group/bld.inf Thu Jun 24 11:28:34 2010 +0100 @@ -15,8 +15,8 @@ #include "../te_lbs_sppm_networkprivacy/group/bld.inf" -#include "../te_sppm_dummynetgateway/group/BLD.INF" -#include "../te_lbs_sppm_privfwcap/group/BLD.INF" +#include "../te_sppm_dummynetgateway/group/bld.inf" +#include "../te_lbs_sppm_privfwcap/group/bld.inf" #include "../te_terminalplugin/group/bld.inf" #include "../te_suplproxyprotocolmodule/group/bld.inf" -#include "../te_sppm_reflocplugin/group/bld.inf" \ No newline at end of file +#include "../te_sppm_reflocplugin/group/bld.inf" diff -r 8e58c1bec439 -r a85dbb892d75 package_definition.xml --- a/package_definition.xml Thu Jun 24 11:27:31 2010 +0100 +++ b/package_definition.xml Thu Jun 24 11:28:34 2010 +0100 @@ -20,6 +20,9 @@ + + + diff -r 8e58c1bec439 -r a85dbb892d75 sysdef_1_4_0.dtd --- a/sysdef_1_4_0.dtd Thu Jun 24 11:27:31 2010 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,86 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -