|
1 // Copyright (c) 2006-2009 Nokia Corporation and/or its subsidiary(-ies). |
|
2 // All rights reserved. |
|
3 // This component and the accompanying materials are made available |
|
4 // under the terms of "Eclipse Public License v1.0" |
|
5 // which accompanies this distribution, and is available |
|
6 // at the URL "http://www.eclipse.org/legal/epl-v10.html". |
|
7 // |
|
8 // Initial Contributors: |
|
9 // Nokia Corporation - initial contribution. |
|
10 // |
|
11 // Contributors: |
|
12 // |
|
13 // Description: |
|
14 // @file ctlbsconflictstepcanceltrackingconflictb.h |
|
15 // This contains the header file for Location Data Source Tests |
|
16 // |
|
17 // |
|
18 |
|
19 #ifndef __CT_LBS_CONFLICT_STEP_CANCELTRACKINGCONFLICTB_H__ |
|
20 #define __CT_LBS_CONFLICT_STEP_CANCELTRACKINGCONFLICTB_H__ |
|
21 |
|
22 // LBS includes. |
|
23 #include <lbs.h> |
|
24 #include <lbscommon.h> |
|
25 #include <lbs/lbsnetcommon.h> |
|
26 |
|
27 |
|
28 // LBS test includes. |
|
29 #include "ctlbsconflictstep.h" |
|
30 #include "ctlbsconflictserver.h" |
|
31 #include "ctlbsdoposupdate.h" |
|
32 #include "ctlbsdox3p.h" |
|
33 |
|
34 // Literals used |
|
35 _LIT(KLbsConflictStep_canceltrackingconflictb, "LbsConflictStep_canceltrackingconflictb"); |
|
36 |
|
37 // Callbacks flags. |
|
38 //const TLbsCallbackFlags KLbsCallback_Got_NotifyUpdate = 0x1000; |
|
39 //const TLbsCallbackFlags KLbsCallback_Got_X3P = 0x4000; |
|
40 //const TLbsCallbackFlags KLbsCallback_Got_ModuleConflictAnswer = 0x2000; |
|
41 |
|
42 |
|
43 class CT_LbsConflictStep_canceltrackingconflictb : public CT_LbsConflictStep, |
|
44 public MT_LbsDoPosUpdateObserver, |
|
45 public MT_LbsDoX3PObserver |
|
46 // public MT_LbsConflictModuleDataBusObserver, |
|
47 // public MLbsPrivacyObserver |
|
48 { |
|
49 public: |
|
50 ~CT_LbsConflictStep_canceltrackingconflictb(); |
|
51 |
|
52 static CT_LbsConflictStep_canceltrackingconflictb* New(CT_LbsConflictServer& aParent); |
|
53 virtual TVerdict doTestStepL(); |
|
54 |
|
55 // From CT_LbsNetSimStep via CT_LbsConflictStep |
|
56 void Connected(); |
|
57 void Disconnected(); |
|
58 void NotifyRegisterLcsMoLr(const TDesC& aData); |
|
59 void NotifyReleaseLcsMoLr(TInt aReason); |
|
60 void NotifyMeasurementControlLocation(const TPositionInfo& aPosition, const RLbsAssistanceDataBuilderSet& aData, const TLbsNetPosRequestQuality& aQuality); |
|
61 void NotifyReleaseLcsLocationNotification(const CLbsNetworkProtocolBase::TLbsPrivacyResponse& aResult); |
|
62 void NotifyFacilityLcsMoLrResult(TInt aReason, const TPositionInfo& aPosition); |
|
63 void NotifyMeasurementReportLocation(const TPositionInfo& aPosition); |
|
64 void NotifyMeasurementReportRequestMoreAssistanceData(const TLbsAssistanceDataGroup& aFilter); |
|
65 void NotifyMeasurementReportControlFailure(TInt aReason); |
|
66 |
|
67 // From MT_LbsDoPosUpdateObserver - Position notify update callback. |
|
68 void MT_LbsDoPosUpdateCallback(TRequestStatus& aStatus); |
|
69 // put this in base class maybe !! no keep here |
|
70 |
|
71 void MT_LbsDoX3PCallback(TInt aTransmitId, TRequestStatus& aStatus); |
|
72 |
|
73 // From MT_LbsDoPosUpdateObserver - Module out data bus updated. |
|
74 // void HandleDataBusUpdateL(const TModuleDataOut& aModuleDataOut); |
|
75 |
|
76 // From MLbsPrivacyObserver. |
|
77 // void ProcessNetworkLocationRequest(TUint aRequestId, const TLbsExternalRequestInfo& aRequestInfo, const TNotificationType& aNotificationType); |
|
78 // void ProcessNetworkPositionUpdate(TUint aRequestId, const TPositionInfo& aPosInfo); |
|
79 // void ProcessRequestComplete(TUint aRequestId, TInt aReason); |
|
80 |
|
81 private: |
|
82 CT_LbsConflictStep_canceltrackingconflictb(CT_LbsConflictServer& aParent); |
|
83 void ConstructL(); |
|
84 |
|
85 void SetExpectedSeq(); |
|
86 void VerifyPosInfos(); |
|
87 |
|
88 enum { EReqPosUpdate = CT_LbsConflictStep::ELast, |
|
89 EReqX3P}; |
|
90 |
|
91 |
|
92 /** Current test case being executed. |
|
93 */ |
|
94 TInt iTestCaseId; |
|
95 |
|
96 /** Active object wrapper to allow MO-LRs. |
|
97 */ |
|
98 // move to base class, no keep here |
|
99 CT_LbsDoPosUpdate* iDoPosUpdate; |
|
100 |
|
101 CT_LbsDoX3P* iDoX3P; |
|
102 // so each test writes it's own netsim func it needs, an doposupdate + dox3p |
|
103 |
|
104 |
|
105 |
|
106 /** Test module data bus monitor, to allow the module to return test status to |
|
107 the test step. |
|
108 */ |
|
109 // CT_LbsConflictModuleDataBusMonitor* iModuleDataBusMonitor; |
|
110 |
|
111 /** Privacy controller, required to preform a MT-LR. |
|
112 */ |
|
113 // CLbsPrivacyController* iPrivacyController; |
|
114 |
|
115 /** MT-LR request id, used to verify the request ids passed to MT-LR callbacks. |
|
116 */ |
|
117 // TUint iMtlrRequestId; |
|
118 |
|
119 /** Used to monitor the number of assistance data events we receviced during a test. |
|
120 */ |
|
121 // TUint iAssEventCount; |
|
122 |
|
123 |
|
124 /** Indicates cancel in operation. |
|
125 */ |
|
126 TBool iCancelSubState; |
|
127 |
|
128 /** Indivcates expecting self locate request to completed with KErrPositionHighPriorityReceive |
|
129 */ |
|
130 // TBool iKErrHighPriorityRecExpected; |
|
131 |
|
132 /** Indivcates expecting self locate request to completed with KErrServerBusy |
|
133 */ |
|
134 TBool iKErrServerBusyExpected; |
|
135 |
|
136 TBool iDoX3PPushWhenMoLrReleased; |
|
137 |
|
138 TBool iX3PPush; |
|
139 |
|
140 TBool iDoAX3PTimer; |
|
141 |
|
142 TBool iHadLastCallBack; |
|
143 }; |
|
144 |
|
145 |
|
146 // Helper function, to copy position infos. |
|
147 //TInt CopyPositionTypes(TPositionInfoBase& aTo, const TPositionInfoBase& aFrom); |
|
148 //TInt SupportedType(const TUint32& aType, const TInt& aSize); |
|
149 |
|
150 #endif //__CT_LBS_CONFLICT_STEP_CANCELTRACKINGCONFLICTB_H__ |