|
1 /* |
|
2 * Copyright (c) 2002-2005 Nokia Corporation and/or its subsidiary(-ies). |
|
3 * All rights reserved. |
|
4 * This component and the accompanying materials are made available |
|
5 * under the terms of "Eclipse Public License v1.0" |
|
6 * which accompanies this distribution, and is available |
|
7 * at the URL "http://www.eclipse.org/legal/epl-v10.html". |
|
8 * |
|
9 * Initial Contributors: |
|
10 * Nokia Corporation - initial contribution. |
|
11 * |
|
12 * Contributors: |
|
13 * |
|
14 * Description: Header file for supl 2.0 set capabilities |
|
15 * |
|
16 */ |
|
17 |
|
18 // INCLUDE FILES |
|
19 |
|
20 #include "epos_comasuplsetcapabilitiesver2.h" |
|
21 #include "lbs/epos_tomasuplposprotocolversion.h" |
|
22 #include "lbs/epos_eomasuplposerrors.h" |
|
23 |
|
24 // ----------------------------------------------------------------------------- |
|
25 // TOMASuplPosTechnology::TOMASuplPosTechnology2() |
|
26 // (other items were commented in a header). |
|
27 // ----------------------------------------------------------------------------- |
|
28 // |
|
29 EXPORT_C TOMASuplPosTechnology2::TOMASuplPosTechnology2():iIsVer2ExtSet(EFalse) |
|
30 { |
|
31 } |
|
32 |
|
33 // ----------------------------------------------------------------------------- |
|
34 // TOMASuplPosTechnology::GetVer2PosExtn() |
|
35 // (other items were commented in a header). |
|
36 // ----------------------------------------------------------------------------- |
|
37 // |
|
38 EXPORT_C TInt TOMASuplPosTechnology2::GetVer2PosExtn(TOMASuplVer2PosTechExt& aExtn)const |
|
39 { |
|
40 if(iIsVer2ExtSet) //if GANSS pos methods are present this wil be set |
|
41 { |
|
42 aExtn = iVer2Ext; |
|
43 return KErrNone; |
|
44 } |
|
45 return KErrOMASuplParamNotSet; |
|
46 |
|
47 } |
|
48 |
|
49 // ----------------------------------------------------------------------------- |
|
50 // TOMASuplPosTechnology::SetVer2PosExtn() |
|
51 // (other items were commented in a header). |
|
52 // ----------------------------------------------------------------------------- |
|
53 // |
|
54 EXPORT_C void TOMASuplPosTechnology2::SetVer2PosExtn(TOMASuplVer2PosTechExt aExtn) |
|
55 { |
|
56 iVer2Ext = aExtn; |
|
57 iIsVer2ExtSet = ETrue; |
|
58 } |
|
59 |
|
60 // ----------------------------------------------------------------------------- |
|
61 // TOMASuplPosProtocol2::TOMASuplPosProtocol2() ,Constuctor |
|
62 // (other items were commented in a header). |
|
63 // ----------------------------------------------------------------------------- |
|
64 // |
|
65 EXPORT_C TOMASuplPosProtocol2::TOMASuplPosProtocol2() |
|
66 { |
|
67 iIsVer2ExtnSet = EFalse; |
|
68 } |
|
69 |
|
70 // ----------------------------------------------------------------------------- |
|
71 // TOMASuplPosProtocol2::GetVer2PosProtocolExtn() |
|
72 // (other items were commented in a header). |
|
73 // ----------------------------------------------------------------------------- |
|
74 // |
|
75 EXPORT_C TInt TOMASuplPosProtocol2::GetVer2PosProtocolExtn(TOMASuplVer2ProtocolExt& aVer2Extn)const |
|
76 { |
|
77 if(iIsVer2ExtnSet) |
|
78 { |
|
79 aVer2Extn = iVer2Ext; |
|
80 return KErrNone; |
|
81 } |
|
82 return KErrOMASuplParamNotSet; |
|
83 } |
|
84 |
|
85 // ----------------------------------------------------------------------------- |
|
86 // TOMASuplPosProtocol2::SetVer2PosProtocolExtn() |
|
87 // (other items were commented in a header). |
|
88 // ----------------------------------------------------------------------------- |
|
89 // |
|
90 EXPORT_C void TOMASuplPosProtocol2::SetVer2PosProtoExtn(TOMASuplVer2ProtocolExt aVer2Extn) |
|
91 { |
|
92 iIsVer2ExtnSet = ETrue; |
|
93 iVer2Ext = aVer2Extn; |
|
94 } |
|
95 // ============================ MEMBER FUNCTIONS OF COMASuplSETCapabilities =============================== |
|
96 |
|
97 // |
|
98 // --------------------------------------------------------- |
|
99 // constuctor |
|
100 // |
|
101 // (other items were commented in a header). |
|
102 // --------------------------------------------------------- |
|
103 // |
|
104 EXPORT_C COMASuplSETCapabilitiesVer2::COMASuplSETCapabilitiesVer2() |
|
105 { |
|
106 iPrefMethod = EOMAPrefMethodUnknown; |
|
107 iIsVer2SetCapExtnSet = EFalse; |
|
108 } |
|
109 |
|
110 // |
|
111 // --------------------------------------------------------- |
|
112 // destructor |
|
113 // |
|
114 // (other items were commented in a header). |
|
115 // --------------------------------------------------------- |
|
116 // |
|
117 EXPORT_C COMASuplSETCapabilitiesVer2::~COMASuplSETCapabilitiesVer2() |
|
118 { |
|
119 } |
|
120 |
|
121 // |
|
122 // --------------------------------------------------------- |
|
123 // Static Factory method to create the COMASuplHorizVelocity |
|
124 // implementation |
|
125 // |
|
126 // (other items were commented in a header). |
|
127 // --------------------------------------------------------- |
|
128 // |
|
129 |
|
130 EXPORT_C COMASuplSETCapabilitiesVer2* COMASuplSETCapabilitiesVer2::NewL() |
|
131 { |
|
132 COMASuplSETCapabilitiesVer2* self = new(ELeave) COMASuplSETCapabilitiesVer2; |
|
133 CleanupStack::PushL(self); |
|
134 self->ConstructL(); |
|
135 CleanupStack::Pop(self); |
|
136 return self; |
|
137 } |
|
138 |
|
139 // |
|
140 // ------------------------------------------------------------- |
|
141 // Two Phase constructor |
|
142 // |
|
143 // (other items were commented in a header). |
|
144 // ------------------------------------------------------------- |
|
145 // |
|
146 EXPORT_C void COMASuplSETCapabilitiesVer2::ConstructL() |
|
147 { |
|
148 iPrefMethod = EOMANoPreferred; |
|
149 } |
|
150 |
|
151 // ----------------------------------------------------------------------------- |
|
152 // COMASuplSETCapabilities::PosTechnology |
|
153 // (other items were commented in a header). |
|
154 // ----------------------------------------------------------------------------- |
|
155 // |
|
156 |
|
157 EXPORT_C void COMASuplSETCapabilitiesVer2::GetSETCapabilities(TOMASuplPosTechnology2& aPosTechnology, |
|
158 TOMASuplPrefMethod2& aPrefMethod, |
|
159 TOMASuplPosProtocol2& aPosProtocol) const |
|
160 { |
|
161 aPosTechnology = iPosTechnology; |
|
162 aPrefMethod = iPrefMethod; |
|
163 aPosProtocol = iPosProtocol; |
|
164 } |
|
165 // ----------------------------------------------------------------------------- |
|
166 // COMASuplSETCapabilities::PrefferedMode |
|
167 // (other items were commented in a header). |
|
168 // ----------------------------------------------------------------------------- |
|
169 // |
|
170 |
|
171 EXPORT_C void COMASuplSETCapabilitiesVer2::SetSETCapabilities(const TOMASuplPosTechnology2& aPosTechnology, |
|
172 const TOMASuplPrefMethod2& aPrefMethod, |
|
173 const TOMASuplPosProtocol2& aPosProtocol) |
|
174 { |
|
175 iPosTechnology = aPosTechnology; |
|
176 iPrefMethod = aPrefMethod; |
|
177 iPosProtocol = aPosProtocol; |
|
178 } |
|
179 |
|
180 EXPORT_C TInt COMASuplSETCapabilitiesVer2::GetVer2SetCapExtn(TOMAVer2SetCapExtn& aCapExtn) const |
|
181 { |
|
182 if(iIsVer2SetCapExtnSet) |
|
183 { |
|
184 aCapExtn = iVer2SetCapExtn; |
|
185 return KErrNone; |
|
186 } |
|
187 return KErrOMASuplParamNotSet; |
|
188 } |
|
189 |
|
190 EXPORT_C void COMASuplSETCapabilitiesVer2::SetVer2SetCapExtn(const TOMAVer2SetCapExtn aCapExtn) |
|
191 { |
|
192 iIsVer2SetCapExtnSet = ETrue; |
|
193 iVer2SetCapExtn = aCapExtn; |
|
194 } |
|
195 EXPORT_C TBool COMASuplSETCapabilitiesVer2::IsVer2SetCapExtnPresent()const |
|
196 { |
|
197 return iIsVer2SetCapExtnSet; |
|
198 } |
|
199 // ----------------------------------------------------------------------------- |
|
200 // COMASuplSETCapabilitiesVer2::CloneL() |
|
201 // (other items were commented in a header). |
|
202 // ----------------------------------------------------------------------------- |
|
203 // |
|
204 EXPORT_C COMASuplSETCapabilitiesVer2* COMASuplSETCapabilitiesVer2::CloneL() |
|
205 { |
|
206 |
|
207 COMASuplSETCapabilitiesVer2* cloneCapabilities = COMASuplSETCapabilitiesVer2::NewL(); |
|
208 |
|
209 cloneCapabilities->SetSETCapabilities(iPosTechnology,iPrefMethod,iPosProtocol); |
|
210 if(iIsVer2SetCapExtnSet) |
|
211 cloneCapabilities->SetVer2SetCapExtn(iVer2SetCapExtn); |
|
212 |
|
213 return (cloneCapabilities); |
|
214 |
|
215 |
|
216 } |
|
217 |
|
218 |
|
219 // ----------------------------------------------------------------------------- |
|
220 // TOMASuplVer2PosTechExt::TOMASuplVer2PosTechExt() ,Constuctor |
|
221 // (other items were commented in a header). |
|
222 // ----------------------------------------------------------------------------- |
|
223 // |
|
224 EXPORT_C TOMASuplVer2PosTechExt::TOMASuplVer2PosTechExt() |
|
225 { |
|
226 } |
|
227 |
|
228 |
|
229 // ----------------------------------------------------------------------------- |
|
230 // TOMASuplSupported3GPP2PosProtoVer::TOMASuplSupported3GPP2PosProtoVer() ,Constuctor |
|
231 // (other items were commented in a header). |
|
232 // ----------------------------------------------------------------------------- |
|
233 // |
|
234 EXPORT_C TOMASuplSupported3GPP2PosProtoVer::TOMASuplSupported3GPP2PosProtoVer() |
|
235 { |
|
236 iRevNumber = 0; |
|
237 iPointReleaseNumber = 0; |
|
238 iInternalEditLevel = 0; |
|
239 } |
|
240 // ----------------------------------------------------------------------------- |
|
241 // TPosProtocol::TIA801() |
|
242 // (other items were commented in a header). |
|
243 // ----------------------------------------------------------------------------- |
|
244 // |
|
245 EXPORT_C void TOMASuplSupported3GPP2PosProtoVer::GetTOMASuplSupported3GPP2PosProtoVer(TUint16& aRevNum,TInt& aPointReleaseNumber,TInt& aInternalEditLevel) const |
|
246 { |
|
247 aRevNum = iRevNumber; |
|
248 aPointReleaseNumber = iPointReleaseNumber; |
|
249 aInternalEditLevel = iInternalEditLevel; |
|
250 } |
|
251 // ----------------------------------------------------------------------------- |
|
252 // TPosProtocol::RRLP() |
|
253 // (other items were commented in a header). |
|
254 // ----------------------------------------------------------------------------- |
|
255 // |
|
256 EXPORT_C void TOMASuplSupported3GPP2PosProtoVer::SetTOMASuplSupported3GPP2PosProtoVer(TUint16 aRevNumber,TInt aPointReleaseNumber,TInt aInternalEditLevel) |
|
257 { |
|
258 iRevNumber = aRevNumber; |
|
259 iPointReleaseNumber = aPointReleaseNumber; |
|
260 iInternalEditLevel = aInternalEditLevel; |
|
261 } |
|
262 // ----------------------------------------------------------------------------- |
|
263 // TOMASuplPosProtocolVersion3GPP2::TOMASuplPosProtocolVersion3GPP2() ,Constuctor |
|
264 // (other items were commented in a header). |
|
265 // ----------------------------------------------------------------------------- |
|
266 // |
|
267 EXPORT_C TOMASuplPosProtocolVersion3GPP2::TOMASuplPosProtocolVersion3GPP2() |
|
268 { |
|
269 } |
|
270 // ----------------------------------------------------------------------------- |
|
271 // TPosProtocol::TIA801() |
|
272 // (other items were commented in a header). |
|
273 // ----------------------------------------------------------------------------- |
|
274 // |
|
275 EXPORT_C void TOMASuplPosProtocolVersion3GPP2::SetTOMASuplPosProtocolVersion3GPP2(TOMASuplSupported3GPP2PosProtoVer aVersion) |
|
276 { |
|
277 iSupProtoVer.Append(aVersion); |
|
278 } |
|
279 |
|
280 EXPORT_C void TOMASuplPosProtocolVersion3GPP2::GetTOMASuplPosProtocolVersion3GPP2(RArray<TOMASuplSupported3GPP2PosProtoVer>& aSupProtoVer) const |
|
281 { |
|
282 aSupProtoVer = iSupProtoVer; |
|
283 } |
|
284 // ----------------------------------------------------------------------------- |
|
285 // TOMASuplVer2ProtocolExt::TOMASuplVer2ProtocolExt() ,Constuctor |
|
286 // (other items were commented in a header). |
|
287 // ----------------------------------------------------------------------------- |
|
288 // |
|
289 EXPORT_C TOMASuplVer2ProtocolExt::TOMASuplVer2ProtocolExt() |
|
290 { |
|
291 } |
|
292 // ----------------------------------------------------------------------------- |
|
293 // TPosProtocol::TIA801() |
|
294 // (other items were commented in a header). |
|
295 // ----------------------------------------------------------------------------- |
|
296 // |
|
297 EXPORT_C void TOMASuplVer2ProtocolExt::GetTOMASuplVer2ProtocolExt(TOMASuplPosProtocolVersion& aRRLPVersion,TOMASuplPosProtocolVersion& aRRCVersion,TOMASuplPosProtocolVersion3GPP2& aTIA801Version) const |
|
298 { |
|
299 aRRLPVersion = iPosProtocolVersionRRLP; |
|
300 aRRCVersion = iPosProtocolVersionRRC; |
|
301 aTIA801Version = iPosProtocolVersionTIA801; |
|
302 } |
|
303 // ----------------------------------------------------------------------------- |
|
304 // TPosProtocol::RRLP() |
|
305 // (other items were commented in a header). |
|
306 // ----------------------------------------------------------------------------- |
|
307 // |
|
308 EXPORT_C void TOMASuplVer2ProtocolExt::SetTOMASuplVer2ProtocolExt(TOMASuplPosProtocolVersion aRRLPVersion,TOMASuplPosProtocolVersion aRRCVersion,TOMASuplPosProtocolVersion3GPP2 aTIA801Version) |
|
309 { |
|
310 iPosProtocolVersionRRLP = aRRLPVersion; |
|
311 iPosProtocolVersionRRC = aRRCVersion; |
|
312 iPosProtocolVersionTIA801 = aTIA801Version; |
|
313 } |
|
314 |
|
315 EXPORT_C TOMASuplReportingCap::TOMASuplReportingCap() |
|
316 { |
|
317 iOptionalMask = 0; |
|
318 } |
|
319 EXPORT_C TInt TOMASuplReportingCap::GetReportMode(TOMASuplReportMode &aReportMode)const |
|
320 { |
|
321 if(iOptionalMask & (1<<1)) |
|
322 { |
|
323 aReportMode = iReportMode; |
|
324 return KErrNone; |
|
325 } |
|
326 return KErrOMASuplParamNotSet; |
|
327 } |
|
328 EXPORT_C TInt TOMASuplReportingCap::GetBatchReportMode(TOMASuplBatchReportMode &aBatchReportMode)const |
|
329 { |
|
330 if(iOptionalMask & 1) |
|
331 { |
|
332 aBatchReportMode = iBatchRepMode; |
|
333 return KErrNone; |
|
334 } |
|
335 return KErrOMASuplParamNotSet; |
|
336 } |
|
337 |
|
338 EXPORT_C void TOMASuplReportingCap::SetReportMode(const TOMASuplReportMode aReportMode) |
|
339 { |
|
340 iOptionalMask |= (1<<1); |
|
341 iReportMode = aReportMode; |
|
342 } |
|
343 EXPORT_C void TOMASuplReportingCap::SetBatchReportMode(const TOMASuplBatchReportMode aBatchReportMode) |
|
344 { |
|
345 iOptionalMask |= 1; |
|
346 iBatchRepMode = aBatchReportMode; |
|
347 } |
|
348 EXPORT_C TOMASuplReportMode::TOMASuplReportMode() |
|
349 { |
|
350 iRealTime = EFalse; |
|
351 iQuasiRealTime = EFalse; |
|
352 iBatch = EFalse; |
|
353 } |
|
354 EXPORT_C void TOMASuplReportMode::GetRealTime(TBool &aRealTime)const |
|
355 { |
|
356 aRealTime = iRealTime; |
|
357 } |
|
358 EXPORT_C void TOMASuplReportMode::GetQuasiRealTime(TBool &aQuasiRealTime)const |
|
359 { |
|
360 aQuasiRealTime = iQuasiRealTime; |
|
361 } |
|
362 EXPORT_C void TOMASuplReportMode::GetBatch(TBool &aBatch)const |
|
363 { |
|
364 aBatch = iBatch; |
|
365 } |
|
366 |
|
367 EXPORT_C void TOMASuplReportMode::SetRealTime(const TBool aRealTime) |
|
368 { |
|
369 iRealTime = aRealTime; |
|
370 } |
|
371 EXPORT_C void TOMASuplReportMode::SetQuasiRealTime(const TBool aQuasiRealTime) |
|
372 { |
|
373 iQuasiRealTime = aQuasiRealTime; |
|
374 } |
|
375 EXPORT_C void TOMASuplReportMode::SetBatch(const TBool aBatch) |
|
376 { |
|
377 iBatch = aBatch; |
|
378 } |
|
379 |
|
380 |
|
381 EXPORT_C TOMASuplBatchReportMode::TOMASuplBatchReportMode() |
|
382 { |
|
383 iOptionalMask = 0; |
|
384 } |
|
385 EXPORT_C TInt TOMASuplBatchReportMode::GetReportPosition(TBool &aReportPosition)const |
|
386 { |
|
387 if(iOptionalMask & (1<<3)) |
|
388 { |
|
389 aReportPosition = iReportPosition; |
|
390 return KErrNone; |
|
391 } |
|
392 return KErrOMASuplParamNotSet; |
|
393 |
|
394 } |
|
395 EXPORT_C TInt TOMASuplBatchReportMode::GetReportMeasurement(TBool &aReportMeasurement)const |
|
396 { |
|
397 if(iOptionalMask & (1<<2)) |
|
398 { |
|
399 aReportMeasurement = iReportMeasurements; |
|
400 return KErrNone; |
|
401 } |
|
402 return KErrOMASuplParamNotSet; |
|
403 |
|
404 } |
|
405 EXPORT_C TInt TOMASuplBatchReportMode::GetMaxPositions(TInt &aMaxPositions)const |
|
406 { |
|
407 if(iOptionalMask & (1<<1)) |
|
408 { |
|
409 aMaxPositions = iMaxPositions; |
|
410 return KErrNone; |
|
411 } |
|
412 return KErrOMASuplParamNotSet; |
|
413 |
|
414 } |
|
415 EXPORT_C TInt TOMASuplBatchReportMode::GetMaxMeasurements(TInt &aMaxMeasurements)const |
|
416 { |
|
417 if(iOptionalMask & (1)) |
|
418 { |
|
419 aMaxMeasurements = iMaxMeasurements; |
|
420 return KErrNone; |
|
421 } |
|
422 return KErrOMASuplParamNotSet; |
|
423 |
|
424 } |
|
425 |
|
426 EXPORT_C void TOMASuplBatchReportMode::SetReportPosition(const TBool aReportPosition) |
|
427 { |
|
428 iOptionalMask |= (1<<3); |
|
429 iReportPosition = aReportPosition; |
|
430 } |
|
431 EXPORT_C void TOMASuplBatchReportMode::SetReportMeasurement(const TBool aReportMeasurement) |
|
432 { |
|
433 iOptionalMask |= (1<<2); |
|
434 iReportMeasurements = aReportMeasurement; |
|
435 } |
|
436 EXPORT_C void TOMASuplBatchReportMode::SetMaxPositions(const TInt aMaxPositions) |
|
437 { |
|
438 iOptionalMask |= (1<<1); |
|
439 iMaxPositions = aMaxPositions; |
|
440 } |
|
441 EXPORT_C void TOMASuplBatchReportMode::SetMaxMeasurements(const TInt aMaxMeasurements) |
|
442 { |
|
443 iOptionalMask |= (1); |
|
444 iMaxMeasurements = aMaxMeasurements; |
|
445 } |
|
446 EXPORT_C TOMAVer2SetCapExtn::TOMAVer2SetCapExtn() |
|
447 { |
|
448 iIsServiceCapSet = EFalse; |
|
449 } |
|
450 EXPORT_C void TOMAVer2SetCapExtn::SetServiceCaps(const TOMAServiceCapabilities aServiceCaps) |
|
451 { |
|
452 iServiceCaps = aServiceCaps; |
|
453 iIsServiceCapSet = ETrue; |
|
454 } |
|
455 EXPORT_C TInt TOMAVer2SetCapExtn::GetServiceCaps(TOMAServiceCapabilities& aServiceCaps) const |
|
456 { |
|
457 if(iIsServiceCapSet) |
|
458 { |
|
459 aServiceCaps = iServiceCaps; |
|
460 return KErrNone; |
|
461 } |
|
462 return KErrOMASuplParamNotSet; |
|
463 |
|
464 |
|
465 } |
|
466 EXPORT_C TOMAServiceCapabilities::TOMAServiceCapabilities() |
|
467 { |
|
468 iOptionalMask = 0; |
|
469 } |
|
470 EXPORT_C void TOMAServiceCapabilities::SetEventTriggerCapabilities(const TOMASuplEventTriggerCapabilities aEventTriggerCapabilities) |
|
471 { |
|
472 iOptionalMask |= (1<<1); |
|
473 iEventTriggerCapabilities = aEventTriggerCapabilities; |
|
474 } |
|
475 EXPORT_C TInt TOMAServiceCapabilities::GetEventTriggerCapabilities(TOMASuplEventTriggerCapabilities& aEventTriggerCapabilities) const |
|
476 { |
|
477 if(iOptionalMask & (1<<1)) |
|
478 { |
|
479 aEventTriggerCapabilities = iEventTriggerCapabilities; |
|
480 return KErrNone; |
|
481 } |
|
482 return KErrOMASuplParamNotSet; |
|
483 } |
|
484 EXPORT_C void TOMAServiceCapabilities::SetSuplServiceSupported(const TOMASuplServiceSupported aServicesSupported) |
|
485 { |
|
486 iOptionalMask |= (1<<2) ; |
|
487 iServicesSupported = aServicesSupported; |
|
488 } |
|
489 EXPORT_C TInt TOMAServiceCapabilities::GetSuplServiceSupported(TOMASuplServiceSupported& aServicesSupported) const |
|
490 { |
|
491 if(iOptionalMask & (1<<2)) |
|
492 { |
|
493 aServicesSupported = iServicesSupported; |
|
494 return KErrNone; |
|
495 } |
|
496 return KErrOMASuplParamNotSet; |
|
497 } |
|
498 |
|
499 EXPORT_C void TOMAServiceCapabilities::SetSuplReportingCap(const TOMASuplReportingCap aReportingCapabilities) |
|
500 { |
|
501 iOptionalMask |= (1<<3); |
|
502 iReportingCapabilities = aReportingCapabilities; |
|
503 } |
|
504 EXPORT_C TInt TOMAServiceCapabilities::GetSuplReportingCap(TOMASuplReportingCap& aReportingCapabilities) const |
|
505 { |
|
506 if(iOptionalMask & (1<<3)) |
|
507 { |
|
508 aReportingCapabilities = iReportingCapabilities; |
|
509 return KErrNone; |
|
510 } |
|
511 return KErrOMASuplParamNotSet; |
|
512 } |
|
513 |
|
514 EXPORT_C void TOMAServiceCapabilities::SetSuplSessionCapabilities(const TOMASuplSessionCapabilities aSessionCapabilities) |
|
515 { |
|
516 iOptionalMask |= 1; |
|
517 iSessionCapabilities = aSessionCapabilities; |
|
518 } |
|
519 EXPORT_C TInt TOMAServiceCapabilities::GetSuplSessionCapabilities(TOMASuplSessionCapabilities& aSessionCapabilities) const |
|
520 { |
|
521 if(iOptionalMask & (1)) |
|
522 { |
|
523 aSessionCapabilities = iSessionCapabilities; |
|
524 return KErrNone; |
|
525 } |
|
526 return KErrOMASuplParamNotSet; |
|
527 } |
|
528 EXPORT_C TOMASuplSessionCapabilities::TOMASuplSessionCapabilities() |
|
529 { |
|
530 iOptionalMask = 0; |
|
531 } |
|
532 EXPORT_C TInt TOMASuplSessionCapabilities::GetMaxNumberPeriodicSessions(TInt8& aMaxNumberPeriodicSessions) const |
|
533 { |
|
534 if(iOptionalMask & (1<<1)) |
|
535 { |
|
536 aMaxNumberPeriodicSessions = iMaxNumberPeriodicSessions; |
|
537 return KErrNone; |
|
538 } |
|
539 return KErrOMASuplParamNotSet; |
|
540 } |
|
541 |
|
542 EXPORT_C TInt TOMASuplSessionCapabilities::GetMaxNumberTotalSessions(TInt& aMaxNumberTotalSessions) const |
|
543 { |
|
544 if(iOptionalMask & (1<<2)) |
|
545 { |
|
546 aMaxNumberTotalSessions = iMaxNumberTotalSessions; |
|
547 return KErrNone; |
|
548 } |
|
549 return KErrOMASuplParamNotSet; |
|
550 } |
|
551 |
|
552 EXPORT_C TInt TOMASuplSessionCapabilities::GetMaxNumberTriggeredSessions(TInt8& aMaxNumberTriggeredSessions) const |
|
553 { |
|
554 if(iOptionalMask & (1<<0)) |
|
555 { |
|
556 aMaxNumberTriggeredSessions = iMaxNumberTriggeredSessions; |
|
557 return KErrNone; |
|
558 } |
|
559 return KErrOMASuplParamNotSet; |
|
560 } |
|
561 |
|
562 EXPORT_C void TOMASuplSessionCapabilities::SetMaxNumberTriggeredSessions(const TInt8 aMaxNumberTriggeredSessions) |
|
563 { |
|
564 iOptionalMask |= (1<<0); |
|
565 iMaxNumberTriggeredSessions = aMaxNumberTriggeredSessions; |
|
566 } |
|
567 |
|
568 EXPORT_C void TOMASuplSessionCapabilities::SetMaxNumberTotalSessions(const TInt aMaxNumberTotalSessions) |
|
569 { |
|
570 iOptionalMask |= (1<<2); |
|
571 iMaxNumberTotalSessions = aMaxNumberTotalSessions; |
|
572 } |
|
573 |
|
574 EXPORT_C void TOMASuplSessionCapabilities::SetMaxNumberPeriodicSessions(const TInt8 aMaxNumberPeriodicSessions) |
|
575 { |
|
576 iOptionalMask |= (1<<1); |
|
577 iMaxNumberPeriodicSessions = aMaxNumberPeriodicSessions; |
|
578 } |
|
579 |
|
580 EXPORT_C void TOMASuplServiceSupported::GetPeriodicTrigger(TBool& aPeriodicTrigger)const |
|
581 { |
|
582 aPeriodicTrigger = iPeriodicTrigger; |
|
583 } |
|
584 EXPORT_C void TOMASuplServiceSupported::GetAreaEventTrigger(TBool& aAreaEventTrigger)const |
|
585 { |
|
586 aAreaEventTrigger = iAreaEventTrigger; |
|
587 } |
|
588 |
|
589 EXPORT_C void TOMASuplServiceSupported::SetPeriodicTrigger(TBool aPeriodicTrigger) |
|
590 { |
|
591 iPeriodicTrigger = aPeriodicTrigger; |
|
592 } |
|
593 EXPORT_C void TOMASuplServiceSupported::SetAreaEventTrigger(TBool aAreaEventTrigger) |
|
594 { |
|
595 iAreaEventTrigger = aAreaEventTrigger; |
|
596 } |
|
597 |
|
598 // End of File |