|
1 // Copyright (c) 2008-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 // |
|
15 |
|
16 /** |
|
17 @file |
|
18 @internalTechnology |
|
19 |
|
20 */ |
|
21 |
|
22 #ifndef RRLP_MEASURE_POSITION_RESPONSE_H |
|
23 #define RRLP_MEASURE_POSITION_RESPONSE_H |
|
24 |
|
25 #include "rrlpmessagebase.h" |
|
26 #include <lbspositioninfo.h> |
|
27 #include <lbs/lbsassistancedatabase.h> |
|
28 #include <lbs/lbsgpsmeasurement.h> |
|
29 #include <lbs/lbsgpstimingmeasurement.h> |
|
30 |
|
31 /** TRrlpLocError typedef. |
|
32 @internalTechnology |
|
33 */ |
|
34 typedef TUint32 TRrlpLocError; |
|
35 |
|
36 /** |
|
37 Enumeration for location error Code parameter. |
|
38 |
|
39 @internalTechnology |
|
40 */ |
|
41 enum _TRrlpLocError |
|
42 { |
|
43 ERrlpLocErrorUnDefined = 0, |
|
44 ERrlpLocErrorNotEnoughBTSs = 1, |
|
45 ERrlpLocErrorNotEnoughSats = 2, |
|
46 ERrlpLocErrorEotdLocCalAssDataMissing = 3, |
|
47 ERrlpLocErrorEotdAssDataMissing = 4, |
|
48 ERrlpLocErrorGpsLocCalAssDataMissing = 5, |
|
49 ERrlpLocErrorGpsAssDataMissing = 6, |
|
50 ERrlpLocErrorMethodNotSupported = 7, |
|
51 ERrlpLocErrorNotProcessed = 8, |
|
52 ERrlpLocErrorRefBTSForGPSNotServingBTS = 9, |
|
53 ERrlpLocErrorRefBTSForEOTDNotServingBTS = 10 |
|
54 }; |
|
55 |
|
56 /** TGeoInfo typedef. |
|
57 @internalTechnology |
|
58 */ |
|
59 typedef TUint32 TGeoInfo; |
|
60 |
|
61 /** |
|
62 Enumeration for location estimate type |
|
63 |
|
64 @internalTechnology |
|
65 |
|
66 */ |
|
67 enum _TGeoInfo |
|
68 { |
|
69 EGeoInfoEllipsoidPoint = 0, |
|
70 EGeoInfoEllipsoidPointWithUncertaintyCircle = 1, |
|
71 EGeoInfoEllipsoidPointWithUncertaintyEllipse = 3, |
|
72 EGeoInfoPolygon = 5, // not supported by RRLP |
|
73 EGeoInfoEllipsoidPointWithAltitude = 8, // not supported by RRLP |
|
74 EGeoInfoEllipsoidPointWithAltitudeAndUncertaintyEllipsoid = 9, |
|
75 EGeoInfoEllipsoidArc = 10 // not supported by RRLP |
|
76 }; |
|
77 |
|
78 |
|
79 /** |
|
80 Encapsulation for received CRrlpMeasurePositionResponse messages. |
|
81 |
|
82 @internalTechnology |
|
83 |
|
84 */ |
|
85 NONSHARABLE_CLASS(CRrlpMeasurePositionResponse) : public CRrlpMessageBase |
|
86 { |
|
87 public: |
|
88 IMPORT_C static CRrlpMeasurePositionResponse* NewL(); |
|
89 IMPORT_C static CRrlpMeasurePositionResponse* NewLC(); |
|
90 |
|
91 public: |
|
92 virtual ~CRrlpMeasurePositionResponse(); |
|
93 |
|
94 public: |
|
95 |
|
96 /** Sets location information parameters */ |
|
97 IMPORT_C TInt SetLocationInformation(TPositionInfoBase& aPosInfo); |
|
98 |
|
99 /** Sets measurement information parameters */ |
|
100 IMPORT_C TInt SetMeasurementInformation(const TPositionInfoBase& aPosInfo); |
|
101 |
|
102 /** Sets Location Error Parameters */ |
|
103 IMPORT_C TInt SetLocationError(TRrlpLocError aLocError); |
|
104 |
|
105 /** Sets Location Error Parameters with request for additional assistance data */ |
|
106 IMPORT_C TInt SetLocationError(TRrlpLocError aLocError, const TLbsAsistanceDataGroup& aDataReqMask); |
|
107 |
|
108 protected: |
|
109 |
|
110 /** Sets the extended reference parameters */ |
|
111 TInt SetExtendedReference(const TRrlpReference& aRrlpRef); |
|
112 |
|
113 /** Sets GPS Fine Timing Data */ |
|
114 void SetGpsTimingData(const TGpsTimingMeasurementData& aTimingData); |
|
115 |
|
116 private: |
|
117 |
|
118 /** Constructor */ |
|
119 CRrlpMeasurePositionResponse(); |
|
120 |
|
121 /** second stage constructor */ |
|
122 void ConstructL(); |
|
123 |
|
124 /** Prohibit copy constructor */ |
|
125 CRrlpMeasurePositionResponse(const CRrlpMeasurePositionResponse&); |
|
126 |
|
127 /** Prohibit assigment operator */ |
|
128 CRrlpMeasurePositionResponse& operator= (const CRrlpMeasurePositionResponse&); |
|
129 |
|
130 private: |
|
131 |
|
132 /** Calculates horizontal uncertainty constant from value in meters */ |
|
133 TInt MetersToHorizontalUncertainty(const TReal32& aDistance); |
|
134 |
|
135 /** Calculates vertical uncertainty constant from value in meters */ |
|
136 TInt MetersToVerticalUncertainty(const TReal32& aDistance); |
|
137 |
|
138 }; |
|
139 |
|
140 |
|
141 #endif // RRLP_MEASURE_POSITION_RESPONSE_H |
|
142 |