|
1 // Copyright (c) 2002-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 // Name : sipprofileitc |
|
15 // Part of : SIP Profile Client |
|
16 // implementation |
|
17 // Version : 1.0 |
|
18 // INCLUDE FILES |
|
19 // |
|
20 |
|
21 |
|
22 |
|
23 #include "SIPProfileITC.h" |
|
24 #include "SIPRemoteProfile.h" |
|
25 #include "sipconcreteprofile.h" |
|
26 #include "sipconcreteprofileholder.h" |
|
27 #include "sipprofileslots.h" |
|
28 #include "sipprofileplugins.h" |
|
29 |
|
30 const TInt KBufInitSize = 100; |
|
31 |
|
32 // ----------------------------------------------------------------------------- |
|
33 // template::InternalizeL |
|
34 // ----------------------------------------------------------------------------- |
|
35 // |
|
36 template<class T> T* InternalizeL(const TDesC8& aBuf) |
|
37 { |
|
38 CBufFlat* internalizeBuf = CBufFlat::NewL(KBufInitSize); |
|
39 CleanupStack::PushL(internalizeBuf); |
|
40 internalizeBuf->InsertL(0,aBuf); |
|
41 |
|
42 RBufReadStream readStream(*internalizeBuf,0); |
|
43 readStream.PushL(); |
|
44 T* profile = static_cast<T*>(T::InternalizeL(readStream)); |
|
45 readStream.Pop(); |
|
46 readStream.Close(); |
|
47 CleanupStack::PopAndDestroy(internalizeBuf); |
|
48 return profile; |
|
49 } |
|
50 |
|
51 // ============================ MEMBER FUNCTIONS =============================== |
|
52 |
|
53 // ----------------------------------------------------------------------------- |
|
54 // CSIPProfileITC::NewL |
|
55 // Two-phased constructor. |
|
56 // ----------------------------------------------------------------------------- |
|
57 // |
|
58 CSIPProfileITC* CSIPProfileITC::NewL(RSIPProfile& aSipProfile) |
|
59 { |
|
60 CSIPProfileITC* self = CSIPProfileITC::NewLC (aSipProfile); |
|
61 CleanupStack::Pop(self); |
|
62 return self; |
|
63 } |
|
64 |
|
65 // ----------------------------------------------------------------------------- |
|
66 // CSIPProfileITC::NewLC |
|
67 // Two-phased constructor. |
|
68 // ----------------------------------------------------------------------------- |
|
69 // |
|
70 CSIPProfileITC* CSIPProfileITC::NewLC(RSIPProfile& aSipProfile) |
|
71 { |
|
72 CSIPProfileITC* self = new (ELeave) CSIPProfileITC(aSipProfile); |
|
73 CleanupStack::PushL(self); |
|
74 self->ConstructL(); |
|
75 return self; |
|
76 } |
|
77 |
|
78 // ----------------------------------------------------------------------------- |
|
79 // CSIPProfileITC::CSIPProfileITC |
|
80 // ----------------------------------------------------------------------------- |
|
81 // |
|
82 CSIPProfileITC::CSIPProfileITC(RSIPProfile& aSipProfile) |
|
83 : iHelper (aSipProfile) |
|
84 { |
|
85 } |
|
86 |
|
87 // ----------------------------------------------------------------------------- |
|
88 // CSIPProfileITC::ConstructL |
|
89 // ----------------------------------------------------------------------------- |
|
90 // |
|
91 void CSIPProfileITC::ConstructL() |
|
92 { |
|
93 iEmptyContent = HBufC8::NewL(0); |
|
94 } |
|
95 |
|
96 // ----------------------------------------------------------------------------- |
|
97 // CSIPProfileITC::~CSIPProfileITC |
|
98 // ----------------------------------------------------------------------------- |
|
99 // |
|
100 CSIPProfileITC::~CSIPProfileITC() |
|
101 { |
|
102 delete iEmptyContent; |
|
103 iEmptyContent = 0; |
|
104 } |
|
105 |
|
106 // ----------------------------------------------------------------------------- |
|
107 // CSIPProfileITC::AddSIPProfileL |
|
108 // ----------------------------------------------------------------------------- |
|
109 // |
|
110 void CSIPProfileITC::AddSIPProfileL(CSIPConcreteProfile& aProfile) |
|
111 { |
|
112 TSIPProfileSlots ids; |
|
113 iHelper.SendL(ids,ESipProfileItcOpAddProfile,aProfile); |
|
114 aProfile.SetId(ids.iProfileId); |
|
115 } |
|
116 |
|
117 // ----------------------------------------------------------------------------- |
|
118 // CSIPProfileITC::UpdateSIPProfileL |
|
119 // ----------------------------------------------------------------------------- |
|
120 // |
|
121 void CSIPProfileITC::UpdateSIPProfileL(CSIPConcreteProfile& aProfile) |
|
122 { |
|
123 iHelper.SendL(ESipProfileItcOpUpdateProfile,aProfile); |
|
124 } |
|
125 |
|
126 // ----------------------------------------------------------------------------- |
|
127 // CSIPProfileITC::SIPProfileUsageL |
|
128 // ----------------------------------------------------------------------------- |
|
129 // |
|
130 TInt CSIPProfileITC::SIPProfileUsageL(TUint32 aProfileId) |
|
131 { |
|
132 TSIPProfileSlots ids; |
|
133 ids.iProfileId = aProfileId; |
|
134 iHelper.SendL(ids,ESipProfileItcOpUsage); |
|
135 return ids.iSlot1; |
|
136 } |
|
137 |
|
138 // ----------------------------------------------------------------------------- |
|
139 // CSIPProfileITC::RemoveSIPProfileL |
|
140 // ----------------------------------------------------------------------------- |
|
141 // |
|
142 void CSIPProfileITC::RemoveSIPProfileL(TUint32 aProfileId) |
|
143 { |
|
144 iITCMsgArgs.Set (ESipProfileItcArgProfileId, aProfileId); |
|
145 iHelper.SendL(iITCMsgArgs,ESipProfileItcOpRemoveProfile); |
|
146 } |
|
147 |
|
148 // ----------------------------------------------------------------------------- |
|
149 // CSIPProfileITC::EnableSIPProfileL |
|
150 // ----------------------------------------------------------------------------- |
|
151 // |
|
152 TInt CSIPProfileITC::EnableSIPProfileL(TUint32 aProfileId) |
|
153 { |
|
154 TSIPProfileSlots ids; |
|
155 ids.iProfileId = aProfileId; |
|
156 iHelper.SendL(ids,ESipProfileItcOpEnable); |
|
157 return ids.iSlot1; |
|
158 } |
|
159 |
|
160 // ----------------------------------------------------------------------------- |
|
161 // CSIPProfileITC::DisableSIPProfileL |
|
162 // ----------------------------------------------------------------------------- |
|
163 // |
|
164 TInt CSIPProfileITC::DisableSIPProfileL(TUint32 aProfileId) |
|
165 { |
|
166 TSIPProfileSlots ids; |
|
167 ids.iProfileId = aProfileId; |
|
168 iHelper.SendL(ids,ESipProfileItcOpDisable); |
|
169 return ids.iSlot1; |
|
170 } |
|
171 |
|
172 // ----------------------------------------------------------------------------- |
|
173 // CSIPProfileITC::ForceDisableSIPProfileL |
|
174 // ----------------------------------------------------------------------------- |
|
175 // |
|
176 TInt CSIPProfileITC::ForceDisableSIPProfileL(TUint32 aProfileId) |
|
177 { |
|
178 TSIPProfileSlots ids; |
|
179 ids.iProfileId = aProfileId; |
|
180 iHelper.SendL(ids,ESipProfileItcOpForceDisable); |
|
181 return ids.iSlot1; |
|
182 } |
|
183 |
|
184 // ----------------------------------------------------------------------------- |
|
185 // CSIPProfileITC::SIPProfileL |
|
186 // ----------------------------------------------------------------------------- |
|
187 // |
|
188 CSIPConcreteProfile* CSIPProfileITC::SIPProfileL(TUint32 aProfileId, TUint aSize) |
|
189 { |
|
190 TSIPProfileSlots ids; |
|
191 ids.iProfileId = aProfileId; |
|
192 |
|
193 if (aSize == 0) |
|
194 { |
|
195 iHelper.SendL(ids,ESipProfileItcOpProfileSize); |
|
196 aSize = ids.iSlot1; |
|
197 if (aSize == 0) |
|
198 { |
|
199 User::Leave(KErrNotFound); |
|
200 } |
|
201 } |
|
202 |
|
203 HBufC8* buf = HBufC8::NewLC(aSize); |
|
204 TPtr8 bufPtr = buf->Des(); |
|
205 iITCMsgArgs.Set(ESipProfileItcArgProfileId, aProfileId); |
|
206 iITCMsgArgs.Set(ESipProfileItcArgProfile, &bufPtr); |
|
207 |
|
208 iHelper.SendL(iITCMsgArgs,ESipProfileItcOpProfile); |
|
209 |
|
210 CSIPConcreteProfile* profile = InternalizeL<CSIPConcreteProfile>(*buf); |
|
211 |
|
212 CleanupStack::PopAndDestroy(buf); |
|
213 |
|
214 profile->SetDefault(EFalse); |
|
215 return profile; |
|
216 } |
|
217 |
|
218 // ----------------------------------------------------------------------------- |
|
219 // CSIPProfileITC::SIPProfileRefreshL |
|
220 // ----------------------------------------------------------------------------- |
|
221 // |
|
222 CSIPConcreteProfile* CSIPProfileITC::SIPProfileRefreshL( |
|
223 TUint32 aProfileId, TUint aSize) |
|
224 { |
|
225 __ASSERT_ALWAYS(aProfileId != 0, User::Leave(KErrArgument)); |
|
226 TSIPProfileSlots ids; |
|
227 ids.iProfileId = aProfileId; |
|
228 |
|
229 if (aSize == 0) |
|
230 { |
|
231 iHelper.SendL(ids,ESipProfileItcOpProfileSize); |
|
232 aSize = ids.iSlot1; |
|
233 if (aSize == 0) |
|
234 { |
|
235 User::Leave(KErrNotFound); |
|
236 } |
|
237 } |
|
238 |
|
239 HBufC8* buf = HBufC8::NewLC(aSize); |
|
240 TPtr8 bufPtr = buf->Des(); |
|
241 iITCMsgArgs.Set(ESipProfileItcArgProfileId, aProfileId); |
|
242 iITCMsgArgs.Set(ESipProfileItcArgProfile, &bufPtr); |
|
243 |
|
244 iHelper.SendL(iITCMsgArgs,ESipProfileItcOpProfileRefresh); |
|
245 |
|
246 CSIPConcreteProfile* profile = InternalizeL<CSIPConcreteProfile>(*buf); |
|
247 |
|
248 CleanupStack::PopAndDestroy(buf); |
|
249 |
|
250 profile->SetDefault(EFalse); |
|
251 return profile; |
|
252 } |
|
253 |
|
254 // ----------------------------------------------------------------------------- |
|
255 // CSIPProfileITC::SIPProfileDefaultL |
|
256 // ----------------------------------------------------------------------------- |
|
257 // |
|
258 void CSIPProfileITC::SIPProfileDefaultL(TUint& aSize, TUint32& aProfileId) |
|
259 { |
|
260 TSIPProfileSlots ids; |
|
261 iHelper.SendL(ids,ESipProfileItcOpProfileSizeDefault); |
|
262 aSize = ids.iSlot1; |
|
263 aProfileId = ids.iProfileId; |
|
264 } |
|
265 |
|
266 // ----------------------------------------------------------------------------- |
|
267 // CSIPProfileITC::SIPProfilesByAORL |
|
268 // ----------------------------------------------------------------------------- |
|
269 // |
|
270 CSIPConcreteProfileHolder* CSIPProfileITC::SIPProfilesByAORL(const TDesC8& aAOR) |
|
271 { |
|
272 TSIPProfileSlots ids; |
|
273 |
|
274 HBufC8* aor = aAOR.AllocL(); |
|
275 CleanupStack::PushL(aor); |
|
276 TPtr8 aorPtr = aor->Des(); |
|
277 |
|
278 TPckgBuf<TSIPProfileSlots> sipIdsPckg(ids); |
|
279 |
|
280 iITCMsgArgs.Set(ESipProfileItcArgNarrator, &aorPtr); |
|
281 iITCMsgArgs.Set(ESipProfileItcArgSlots, &sipIdsPckg); |
|
282 |
|
283 iHelper.SendL(iITCMsgArgs, ESipProfileItcOpProfilesSizeByAOR); |
|
284 ids = sipIdsPckg(); |
|
285 |
|
286 TUint size = ids.iSlot1; |
|
287 HBufC8* buf = HBufC8::NewLC(size); |
|
288 TPtr8 bufPtr = buf->Des(); |
|
289 |
|
290 iITCMsgArgs.Set(ESipProfileItcArgNarrator, &aorPtr); |
|
291 iITCMsgArgs.Set(ESipProfileItcArgProfiles, &bufPtr); |
|
292 |
|
293 iHelper.SendL(iITCMsgArgs, ESipProfileItcOpProfilesByAOR); |
|
294 |
|
295 CSIPConcreteProfileHolder* holder = |
|
296 InternalizeL<CSIPConcreteProfileHolder>(*buf); |
|
297 CleanupStack::PopAndDestroy(buf); |
|
298 CleanupStack::PopAndDestroy(aor); |
|
299 return holder; |
|
300 } |
|
301 |
|
302 // ----------------------------------------------------------------------------- |
|
303 // CSIPProfileITC::SIPProfileDefaultIdL |
|
304 // ----------------------------------------------------------------------------- |
|
305 // |
|
306 TUint CSIPProfileITC::SIPProfileDefaultIdL() |
|
307 { |
|
308 TSIPProfileSlots ids; |
|
309 iHelper.SendL(ids,ESipProfileItcOpProfileSizeDefault); |
|
310 return ids.iProfileId; |
|
311 } |
|
312 |
|
313 // ----------------------------------------------------------------------------- |
|
314 // CSIPProfileITC::DeleteSIPProfileL |
|
315 // ----------------------------------------------------------------------------- |
|
316 // |
|
317 void CSIPProfileITC::DeleteSIPProfileL(TUint32 aProfileId) |
|
318 { |
|
319 iITCMsgArgs.Set(ESipProfileItcArgProfileId, aProfileId); |
|
320 |
|
321 iHelper.SendL(iITCMsgArgs,ESipProfileItcOpDeleteProfile); |
|
322 } |
|
323 |
|
324 // ----------------------------------------------------------------------------- |
|
325 // CSIPProfileITC::SIPProfilePluginsL |
|
326 // ----------------------------------------------------------------------------- |
|
327 // |
|
328 CSIPProfilePlugins* CSIPProfileITC::SIPProfilePluginsL() |
|
329 { |
|
330 TSIPProfileSlots ids; |
|
331 iHelper.SendL(ids,ESipProfileItcOpPluginsSize); |
|
332 TUint size = ids.iSlot1; |
|
333 |
|
334 HBufC8* buf = HBufC8::NewLC(size); |
|
335 TPtr8 bufPtr = buf->Des(); |
|
336 iITCMsgArgs.Set(ESipProfileItcArgPlugins, &bufPtr); |
|
337 |
|
338 iHelper.SendL(iITCMsgArgs,ESipProfileItcOpPlugins); |
|
339 |
|
340 CSIPProfilePlugins* plugins = InternalizeL<CSIPProfilePlugins>(*buf); |
|
341 CleanupStack::PopAndDestroy(buf); |
|
342 |
|
343 return plugins; |
|
344 } |
|
345 |
|
346 // ----------------------------------------------------------------------------- |
|
347 // CSIPProfileITC::SIPProfilesL |
|
348 // ----------------------------------------------------------------------------- |
|
349 // |
|
350 CSIPConcreteProfileHolder* CSIPProfileITC::SIPProfilesL() |
|
351 { |
|
352 TSIPProfileSlots ids; |
|
353 |
|
354 TPckgBuf<TSIPProfileSlots> sipIdsPckg(ids); |
|
355 |
|
356 iITCMsgArgs.Set(ESipProfileItcArgSlots, &sipIdsPckg); |
|
357 |
|
358 iHelper.SendL(iITCMsgArgs, ESipProfileItcOpProfilesSize); |
|
359 ids = sipIdsPckg(); |
|
360 |
|
361 TUint size = ids.iSlot1; |
|
362 HBufC8* buf = HBufC8::NewLC(size); |
|
363 TPtr8 bufPtr = buf->Des(); |
|
364 |
|
365 iITCMsgArgs.Set(ESipProfileItcArgProfiles, &bufPtr); |
|
366 |
|
367 iHelper.SendL(iITCMsgArgs, ESipProfileItcOpProfiles); |
|
368 |
|
369 CSIPConcreteProfileHolder* holder = |
|
370 InternalizeL<CSIPConcreteProfileHolder>(*buf); |
|
371 CleanupStack::PopAndDestroy(buf); |
|
372 |
|
373 return holder; |
|
374 } |
|
375 |
|
376 // ----------------------------------------------------------------------------- |
|
377 // CSIPProfileITC::SIPProfilesByTypeL |
|
378 // ----------------------------------------------------------------------------- |
|
379 // |
|
380 CSIPConcreteProfileHolder* CSIPProfileITC::SIPProfilesByTypeL( |
|
381 const TSIPProfileTypeInfo& aType) |
|
382 { |
|
383 TSIPProfileSlots ids; |
|
384 |
|
385 HBufC8* type = aType.iSIPProfileName.AllocL(); |
|
386 CleanupStack::PushL(type); |
|
387 TPtr8 typePtr = type->Des(); |
|
388 |
|
389 TPckgBuf<TSIPProfileSlots> sipIdsPckg(ids); |
|
390 |
|
391 iITCMsgArgs.Set(ESipProfileItcArgNarrator, &typePtr); |
|
392 iITCMsgArgs.Set(ESipProfileItcArgSlots, &sipIdsPckg); |
|
393 iITCMsgArgs.Set(ESipProfileItcArgType, aType.iSIPProfileClass); |
|
394 |
|
395 iHelper.SendL(iITCMsgArgs, ESipProfileItcOpProfilesSizeByType); |
|
396 ids = sipIdsPckg(); |
|
397 |
|
398 TUint size = ids.iSlot1; |
|
399 HBufC8* buf = HBufC8::NewLC(size); |
|
400 TPtr8 bufPtr = buf->Des(); |
|
401 |
|
402 iITCMsgArgs.Set(ESipProfileItcArgNarrator, &typePtr); |
|
403 iITCMsgArgs.Set(ESipProfileItcArgProfiles, &bufPtr); |
|
404 iITCMsgArgs.Set(ESipProfileItcArgType, aType.iSIPProfileClass); |
|
405 |
|
406 iHelper.SendL(iITCMsgArgs, ESipProfileItcOpProfilesByType); |
|
407 |
|
408 CSIPConcreteProfileHolder* holder = |
|
409 InternalizeL<CSIPConcreteProfileHolder>(*buf); |
|
410 CleanupStack::PopAndDestroy(buf); |
|
411 CleanupStack::PopAndDestroy(type); |
|
412 return holder; |
|
413 } |
|
414 |
|
415 // ----------------------------------------------------------------------------- |
|
416 // CSIPProfileITC::SIPCreateProfileL |
|
417 // ----------------------------------------------------------------------------- |
|
418 // |
|
419 CSIPConcreteProfile* CSIPProfileITC::SIPCreateProfileL( |
|
420 const TSIPProfileTypeInfo& aType) |
|
421 { |
|
422 TSIPProfileSlots ids; |
|
423 |
|
424 HBufC8* type = aType.iSIPProfileName.AllocL(); |
|
425 CleanupStack::PushL(type); |
|
426 TPtr8 typePtr = type->Des(); |
|
427 |
|
428 TPckgBuf<TSIPProfileSlots> sipIdsPckg(ids); |
|
429 |
|
430 iITCMsgArgs.Set(ESipProfileItcArgNarrator, &typePtr); |
|
431 iITCMsgArgs.Set(ESipProfileItcArgSlots, &sipIdsPckg); |
|
432 iITCMsgArgs.Set(ESipProfileItcArgType, aType.iSIPProfileClass); |
|
433 |
|
434 iHelper.SendL(iITCMsgArgs, ESipProfileItcOpCreateProfileSize); |
|
435 ids = sipIdsPckg(); |
|
436 |
|
437 TUint size = ids.iSlot1; |
|
438 |
|
439 if (size == 0) |
|
440 { |
|
441 User::Leave(KErrNotFound); |
|
442 } |
|
443 |
|
444 HBufC8* buf = HBufC8::NewLC(size); |
|
445 TPtr8 bufPtr = buf->Des(); |
|
446 iITCMsgArgs.Set(ESipProfileItcArgNarrator, &typePtr); |
|
447 iITCMsgArgs.Set(ESipProfileItcArgSlots, &sipIdsPckg); |
|
448 iITCMsgArgs.Set(ESipProfileItcArgType, aType.iSIPProfileClass); |
|
449 iITCMsgArgs.Set(ESipProfileItcArgProfile, &bufPtr); |
|
450 |
|
451 iHelper.SendL(iITCMsgArgs,ESipProfileItcOpCreateProfile); |
|
452 |
|
453 CSIPConcreteProfile* profile = InternalizeL<CSIPConcreteProfile>(*buf); |
|
454 |
|
455 CleanupStack::PopAndDestroy(buf); |
|
456 CleanupStack::PopAndDestroy(type); |
|
457 |
|
458 return profile; |
|
459 } |
|
460 |
|
461 // ----------------------------------------------------------------------------- |
|
462 // CSIPProfileITC::NegotiatedSecurityMechanismL |
|
463 // ----------------------------------------------------------------------------- |
|
464 // |
|
465 void CSIPProfileITC::NegotiatedSecurityMechanismL(CSIPConcreteProfile& aProfile) |
|
466 { |
|
467 TSIPProfileSlots ids; |
|
468 ids.iProfileId = aProfile.Id(); |
|
469 |
|
470 iHelper.SendL(ids,ESipProfileItcOpNegotiatedSecuritySize); |
|
471 TUint size = ids.iSlot1; |
|
472 HBufC8* buf = HBufC8::NewLC(size); |
|
473 if (size != 0) |
|
474 { |
|
475 TPtr8 bufPtr = buf->Des(); |
|
476 iITCMsgArgs.Set(ESipProfileItcArgProfileId, aProfile.Id()); |
|
477 iITCMsgArgs.Set(ESipProfileItcArgNegotiated, &bufPtr); |
|
478 iHelper.SendL(iITCMsgArgs,ESipProfileItcOpNegotiatedSecurity); |
|
479 aProfile.SetNegotiatedSecurityMechanismL(*buf); |
|
480 } |
|
481 else |
|
482 { |
|
483 aProfile.SetNegotiatedSecurityMechanismL(*buf); |
|
484 } |
|
485 CleanupStack::PopAndDestroy(buf); |
|
486 } |
|
487 |
|
488 // ----------------------------------------------------------------------------- |
|
489 // CSIPProfileITC::RegisteredAORsL |
|
490 // ----------------------------------------------------------------------------- |
|
491 // |
|
492 void CSIPProfileITC::RegisteredAORsL(CSIPConcreteProfile& aProfile) |
|
493 { |
|
494 TSIPProfileSlots ids; |
|
495 ids.iProfileId = aProfile.Id(); |
|
496 |
|
497 iHelper.SendL(ids,ESipProfileItcOpRegisteredAORsSize); |
|
498 TUint size = ids.iSlot1; |
|
499 if (size != 0) |
|
500 { |
|
501 HBufC8* buf = HBufC8::NewLC(size); |
|
502 TPtr8 bufPtr = buf->Des(); |
|
503 iITCMsgArgs.Set(ESipProfileItcArgProfileId, aProfile.Id()); |
|
504 iITCMsgArgs.Set(ESipProfileItcArgAORs, &bufPtr); |
|
505 iHelper.SendL(iITCMsgArgs,ESipProfileItcOpRegisteredAORs); |
|
506 |
|
507 CBufFlat* internalizeBuf = CBufFlat::NewL(KBufInitSize); |
|
508 CleanupStack::PushL(internalizeBuf); |
|
509 internalizeBuf->InsertL(0, *buf); |
|
510 |
|
511 RBufReadStream readStream(*internalizeBuf,0); |
|
512 readStream.PushL(); |
|
513 aProfile.InternalizeRegisteredAORsL(readStream); |
|
514 readStream.Pop(); |
|
515 readStream.Close(); |
|
516 CleanupStack::PopAndDestroy(internalizeBuf); |
|
517 CleanupStack::PopAndDestroy(buf); |
|
518 } |
|
519 else |
|
520 { |
|
521 CDesC8ArrayFlat* tmp = new (ELeave) CDesC8ArrayFlat(1); |
|
522 CleanupStack::PushL(tmp); |
|
523 aProfile.SetRegisteredAORsL(*tmp); |
|
524 CleanupStack::PopAndDestroy(tmp); |
|
525 } |
|
526 } |
|
527 |
|
528 // ----------------------------------------------------------------------------- |
|
529 // CSIPProfileITC::AllowMigrationL |
|
530 // ----------------------------------------------------------------------------- |
|
531 // |
|
532 void CSIPProfileITC::AllowMigrationL(TUint32 aProfileId, TUint32 aIapId) |
|
533 { |
|
534 TSIPProfileSlots ids; |
|
535 ids.iProfileId = aProfileId; |
|
536 ids.iSlot1 = aIapId; |
|
537 iHelper.SendL(ids,ESipProfileItcOpAllowMigration); |
|
538 } |
|
539 |
|
540 // ----------------------------------------------------------------------------- |
|
541 // CSIPProfileITC::DisallowMigrationL |
|
542 // ----------------------------------------------------------------------------- |
|
543 // |
|
544 void CSIPProfileITC::DisallowMigrationL(TUint32 aProfileId, TUint32 aIapId) |
|
545 { |
|
546 TSIPProfileSlots ids; |
|
547 ids.iProfileId = aProfileId; |
|
548 ids.iSlot1 = aIapId; |
|
549 iHelper.SendL(ids,ESipProfileItcOpDisallowMigration); |
|
550 } |
|
551 |
|
552 // ----------------------------------------------------------------------------- |
|
553 // CSIPProfileITC::AddALRObserverL |
|
554 // ----------------------------------------------------------------------------- |
|
555 // |
|
556 void CSIPProfileITC::AddALRObserverL() |
|
557 { |
|
558 TSIPProfileSlots ids; // We won't need this at server side. |
|
559 iHelper.SendL(ids,ESipProfileItcOpAddALRObserver); |
|
560 } |
|
561 |
|
562 // ----------------------------------------------------------------------------- |
|
563 // CSIPProfileITC::RemoveALRObserver |
|
564 // ----------------------------------------------------------------------------- |
|
565 // |
|
566 void CSIPProfileITC::RemoveALRObserver() |
|
567 { |
|
568 TSIPProfileSlots ids; // We won't need this at server side. |
|
569 iHelper.Send(ids,ESipProfileItcOpRemoveALRObserver); |
|
570 } |
|
571 |
|
572 // ----------------------------------------------------------------------------- |
|
573 // CSIPProfileITC::RefreshIapAvailabilityL |
|
574 // ----------------------------------------------------------------------------- |
|
575 // |
|
576 void CSIPProfileITC::RefreshIapAvailabilityL(TUint32 aProfileId) |
|
577 { |
|
578 TSIPProfileSlots ids; |
|
579 ids.iProfileId = aProfileId; |
|
580 iHelper.SendL(ids,ESipProfileItcOpRefreshIapAvailability); |
|
581 } |
|
582 |
|
583 |