author | Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com> |
Tue, 24 Nov 2009 08:56:33 +0200 | |
changeset 33 | 50974a8b132e |
parent 19 | 989d2f495d90 |
permissions | -rw-r--r-- |
19 | 1 |
/* |
2 |
* Copyright (c) 2002 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 the License "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: ?Description |
|
15 |
* |
|
16 |
*/ |
|
17 |
||
18 |
||
19 |
||
20 |
||
21 |
// INCLUDE FILES |
|
22 |
#include <e32svr.h> |
|
23 |
#include <StifParser.h> |
|
33
50974a8b132e
Revision: 200945
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
19
diff
changeset
|
24 |
#include <StifTestInterface.h> |
19 | 25 |
#include <msvids.h> |
26 |
////#include <senduiconsts.h> |
|
33
50974a8b132e
Revision: 200945
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
19
diff
changeset
|
27 |
#include <liwcommon.h> |
19 | 28 |
#include "messaginginterface.h" |
33
50974a8b132e
Revision: 200945
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
19
diff
changeset
|
29 |
#include<liwservicehandler.h> |
19 | 30 |
|
33
50974a8b132e
Revision: 200945
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
19
diff
changeset
|
31 |
#include "tdeletemessagetest.h" |
19 | 32 |
|
33 |
// ----------------------------------------------------------------------------- |
|
34 |
// CTDeleteMessageTest::Delete |
|
35 |
// Delete here all resources allocated and opened from test methods. |
|
36 |
// Called from destructor. |
|
37 |
// ----------------------------------------------------------------------------- |
|
38 |
// |
|
39 |
void CTDeleteMessageTest::Delete() |
|
40 |
{ |
|
41 |
||
42 |
} |
|
43 |
||
44 |
// ----------------------------------------------------------------------------- |
|
45 |
// CTDeleteMessageTest::RunMethodL |
|
46 |
// Run specified method. Contains also table of test mothods and their names. |
|
47 |
// ----------------------------------------------------------------------------- |
|
48 |
// |
|
49 |
TInt CTDeleteMessageTest::RunMethodL( |
|
50 |
CStifItemParser& aItem ) |
|
51 |
{ |
|
52 |
||
53 |
static TStifFunctionInfo const KFunctions[] = |
|
54 |
{ |
|
55 |
||
56 |
ENTRY( "DeleteMessageInvalid", CTDeleteMessageTest::DeleteMessageInvalid), |
|
57 |
ENTRY( "DeleteMessageSms", CTDeleteMessageTest::DeleteMessageSms), |
|
58 |
ENTRY( "DeleteMessageMms", CTDeleteMessageTest::DeleteMessageMms), |
|
59 |
||
60 |
}; |
|
61 |
||
62 |
const TInt count = sizeof( KFunctions ) / |
|
63 |
sizeof( TStifFunctionInfo ); |
|
64 |
||
65 |
return RunInternalL( KFunctions, count, aItem ); |
|
66 |
||
67 |
} |
|
68 |
||
69 |
_LIT8(KTestInterface, "IMessaging"); |
|
70 |
_LIT8(KTestContent, "Service.Messaging"); |
|
71 |
_LIT8(KCmd, "Delete"); |
|
72 |
_LIT8(KErrorCode, "ErrorCode"); |
|
73 |
||
74 |
||
75 |
_LIT8(KCmdGetHeaderList, "GetList"); |
|
76 |
||
77 |
_LIT8(KFilter, "Filter"); |
|
78 |
_LIT8(KMessageList, "MessageList" ); |
|
79 |
||
80 |
_LIT8(KMessageId,"MessageId"); |
|
81 |
||
82 |
||
83 |
_LIT(KMsgTypeSMS, "SMS"); |
|
84 |
_LIT(KMsgTypeMMS, "MMS"); |
|
85 |
||
86 |
||
87 |
TInt CTDeleteMessageTest::DeleteMessageInvalid(CStifItemParser& /*aItem*/) |
|
88 |
{ |
|
89 |
__UHEAP_MARK; |
|
90 |
CLiwServiceHandler* iServiceHandler = CLiwServiceHandler::NewL(); |
|
91 |
CleanupStack::PushL(iServiceHandler); |
|
92 |
CLiwGenericParamList* inparam = &(iServiceHandler->InParamListL()); |
|
93 |
CLiwGenericParamList* outparam = &(iServiceHandler->OutParamListL()); |
|
94 |
||
95 |
TInt err = KErrNone; |
|
96 |
||
97 |
CLiwCriteriaItem* crit = CLiwCriteriaItem::NewL(1, KTestInterface,KTestContent); |
|
98 |
crit->SetServiceClass(TUid::Uid(KLiwClassBase)); |
|
99 |
||
100 |
RCriteriaArray a; |
|
101 |
a.AppendL(crit); |
|
102 |
||
103 |
iServiceHandler->AttachL(a); |
|
104 |
||
105 |
iServiceHandler->ExecuteServiceCmdL(*crit, *inparam, *outparam); |
|
106 |
||
107 |
delete crit; |
|
108 |
a.Reset(); |
|
109 |
||
110 |
TInt pos = 0; |
|
111 |
MLiwInterface* interface = NULL; |
|
112 |
outparam->FindFirst( pos, KTestInterface ); |
|
113 |
if(pos != KErrNotFound) |
|
114 |
{ |
|
115 |
interface = (*outparam)[pos].Value().AsInterface(); |
|
116 |
} |
|
117 |
||
118 |
outparam->Reset(); |
|
119 |
inparam->Reset(); |
|
120 |
if(interface) |
|
121 |
{ |
|
122 |
TLiwGenericParam msgid; |
|
123 |
TLiwVariant msgidvalue; |
|
124 |
||
125 |
msgidvalue.Set(-1); |
|
126 |
msgid.SetNameAndValueL(KMessageId,msgidvalue); |
|
127 |
||
128 |
inparam->AppendL(msgid); |
|
129 |
||
130 |
msgid.Reset(); |
|
131 |
msgidvalue.Reset(); |
|
132 |
||
133 |
TRAP(err, interface->ExecuteCmdL(KCmd,*inparam,*outparam)); |
|
134 |
||
135 |
TInt32 returnerr = 0; |
|
136 |
pos = 0; |
|
137 |
outparam->FindFirst( pos, KErrorCode ); |
|
138 |
if(pos != KErrNotFound) |
|
139 |
{ |
|
140 |
if( (*outparam)[pos].Value().AsTInt32() != KErrNone ) |
|
141 |
err = (TInt)((*outparam)[pos].Value().AsTInt32()); |
|
142 |
} |
|
143 |
||
144 |
interface->Close(); |
|
145 |
outparam->Reset(); |
|
146 |
inparam->Reset(); |
|
147 |
} |
|
148 |
||
149 |
CleanupStack::PopAndDestroy(iServiceHandler); |
|
150 |
||
151 |
__UHEAP_MARKEND; |
|
152 |
||
153 |
if (err != KErrNone) |
|
154 |
return KErrNone; |
|
155 |
else |
|
156 |
return KErrGeneral; |
|
157 |
} |
|
158 |
||
159 |
||
160 |
TInt CTDeleteMessageTest::DeleteMessageSms(CStifItemParser& /*aItem*/) |
|
161 |
{ |
|
162 |
__UHEAP_MARK; |
|
163 |
TInt result = KErrNone; |
|
164 |
// RFile fs; |
|
165 |
// RFs rFs; |
|
166 |
// rFs.Connect(); |
|
167 |
// rFs.Delete(_L("c:\\logfile_deletesms.txt")); |
|
168 |
// fs.Create(rFs, _L("c:\\logfile_deletesms.txt"), EFileShareExclusive|EFileWrite) ; |
|
169 |
//fs.Write(_L8("Started")); |
|
170 |
||
171 |
CLiwServiceHandler* iServiceHandler = CLiwServiceHandler::NewL(); |
|
172 |
CleanupStack::PushL(iServiceHandler); |
|
173 |
CLiwGenericParamList* inParamList = &(iServiceHandler->InParamListL()); |
|
174 |
CLiwGenericParamList* outParamList = &(iServiceHandler->OutParamListL()); |
|
175 |
||
176 |
CLiwCriteriaItem* crit = CLiwCriteriaItem::NewL(1, KTestInterface,KTestContent); |
|
177 |
crit->SetServiceClass(TUid::Uid(KLiwClassBase)); |
|
178 |
||
179 |
RCriteriaArray a; |
|
180 |
a.AppendL(crit); |
|
181 |
||
182 |
iServiceHandler->AttachL(a); |
|
183 |
||
184 |
iServiceHandler->ExecuteServiceCmdL(*crit, *inParamList, *outParamList); |
|
185 |
||
186 |
a.Reset(); |
|
187 |
delete crit; |
|
188 |
||
189 |
TInt pos = 0; |
|
190 |
MLiwInterface* interface = NULL; |
|
191 |
outParamList->FindFirst(pos,KTestInterface ); |
|
192 |
if(pos != KErrNotFound) |
|
193 |
{ |
|
194 |
interface = (*outParamList)[pos].Value().AsInterface(); |
|
195 |
} |
|
196 |
||
197 |
outParamList->Reset(); |
|
198 |
inParamList->Reset(); |
|
199 |
||
200 |
if( interface ) |
|
201 |
{ |
|
202 |
pos =0; |
|
203 |
TLiwVariant content(_L("Inbox")); |
|
204 |
TLiwGenericParam elem ; |
|
205 |
elem.SetNameAndValueL(_L8("Type"),content); |
|
206 |
inParamList->AppendL(elem); |
|
207 |
content.Reset(); |
|
208 |
elem.Reset(); |
|
209 |
||
210 |
CLiwDefaultMap* map = CLiwDefaultMap::NewL(); |
|
211 |
CleanupStack::PushL(map); |
|
212 |
||
213 |
CLiwDefaultList* mtmtypelist = CLiwDefaultList::NewL(); |
|
214 |
CleanupStack::PushL(mtmtypelist); |
|
215 |
||
216 |
||
217 |
TLiwVariant smsmtm(KMsgTypeSMS); // how the user wud gv this param |
|
218 |
mtmtypelist->AppendL(smsmtm); |
|
219 |
smsmtm.Reset(); |
|
220 |
||
221 |
TLiwVariant add1(mtmtypelist); |
|
222 |
||
223 |
map->InsertL(_L8("MessageTypeList"), add1); // Mtmtype is added |
|
224 |
mtmtypelist->DecRef(); |
|
225 |
CleanupStack::Pop(mtmtypelist); |
|
226 |
add1.Reset(); |
|
227 |
||
228 |
||
229 |
TLiwVariant filterparam(map); |
|
230 |
TLiwGenericParam element ; |
|
231 |
element.SetNameAndValueL(_L8("Filter"),filterparam); |
|
232 |
filterparam.Reset(); |
|
233 |
||
234 |
||
235 |
inParamList->AppendL(element); |
|
236 |
element.Reset(); |
|
237 |
||
238 |
map->DecRef(); |
|
239 |
CleanupStack::Pop(map); |
|
240 |
||
241 |
||
242 |
TInt err = 0; |
|
243 |
TRAP(err,interface->ExecuteCmdL( KCmdGetHeaderList ,*inParamList ,*outParamList)); |
|
244 |
pos = 0 ; |
|
245 |
||
246 |
const TLiwGenericParam* output = outParamList->FindFirst( pos,_L8("ReturnValue")); |
|
247 |
||
248 |
TInt32 testmessageid = 0; |
|
249 |
||
250 |
if(output) |
|
251 |
{ |
|
252 |
CLiwIterable* iterlist = output->Value().AsIterable(); |
|
253 |
||
254 |
if(iterlist) |
|
255 |
{ |
|
256 |
TLiwVariant data; |
|
257 |
if(iterlist->NextL(data)) |
|
258 |
{ |
|
259 |
const CLiwMap* Map = data.AsMap(); |
|
260 |
if ( Map ) |
|
261 |
{ |
|
262 |
TLiwVariant messageid; |
|
263 |
Map->FindL(_L8("MessageId"),messageid); |
|
264 |
testmessageid = (TInt)messageid.AsTInt32(); |
|
265 |
messageid.Reset(); |
|
266 |
} |
|
267 |
} |
|
268 |
data.Reset(); |
|
269 |
} |
|
270 |
} |
|
271 |
inParamList->Reset(); |
|
272 |
outParamList->Reset(); |
|
273 |
||
274 |
//fs.Write(_L8("Got messageid = ")); |
|
275 |
TBuf8<50> tmpBuf; |
|
276 |
tmpBuf.Num(testmessageid); |
|
277 |
//fs.Write(_L8("Got messageid = ")); |
|
278 |
//fs.Write(tmpBuf); |
|
279 |
//fs.Flush(); |
|
280 |
||
281 |
if(testmessageid > 0) |
|
282 |
{ |
|
283 |
TLiwGenericParam msgid; |
|
284 |
TLiwVariant msgidvalue; |
|
285 |
||
286 |
msgidvalue.Set(testmessageid); |
|
287 |
msgid.SetNameAndValueL(KMessageId,msgidvalue); |
|
288 |
||
289 |
inParamList->AppendL(msgid); |
|
290 |
||
291 |
msgid.Reset(); |
|
292 |
msgidvalue.Reset(); |
|
293 |
||
294 |
//fs.Write(_L8("Before delete")); |
|
295 |
//fs.Flush(); |
|
296 |
interface->ExecuteCmdL(KCmd,*inParamList,*outParamList); |
|
297 |
//fs.Write(_L8("After delete")); |
|
298 |
//fs.Flush(); |
|
299 |
||
300 |
inParamList->Reset(); |
|
301 |
outParamList->Reset(); |
|
302 |
||
303 |
||
304 |
TLiwVariant content(_L("Inbox")); |
|
305 |
TLiwGenericParam elem ; |
|
306 |
elem.SetNameAndValueL(_L8("Type"),content); |
|
307 |
inParamList->AppendL(elem); |
|
308 |
content.Reset(); |
|
309 |
elem.Reset(); |
|
310 |
||
311 |
CLiwDefaultMap* filtermap = CLiwDefaultMap::NewL(); |
|
312 |
CleanupStack::PushL(filtermap); |
|
313 |
||
314 |
TLiwVariant filterid( testmessageid ); |
|
315 |
map->InsertL(KMessageId, filterid); // Mtmtype is added |
|
316 |
filterid.Reset(); |
|
317 |
||
318 |
||
319 |
TLiwVariant filterparam(map); |
|
320 |
TLiwGenericParam element ; |
|
321 |
element.SetNameAndValueL(_L8("Filter"),filterparam); |
|
322 |
filterparam.Reset(); |
|
323 |
||
324 |
inParamList->AppendL(element); |
|
325 |
element.Reset(); |
|
326 |
||
327 |
map->DecRef(); |
|
328 |
CleanupStack::Pop(map); |
|
329 |
||
330 |
//fs.Write(_L8("Before HeaderList")); |
|
331 |
//fs.Flush(); |
|
332 |
||
333 |
TInt err = 0; |
|
334 |
TRAP(err,interface->ExecuteCmdL( KCmdGetHeaderList ,*inParamList ,*outParamList)); |
|
335 |
pos = 0 ; |
|
336 |
||
337 |
//fs.Write(_L8("After HeaderList")); |
|
338 |
//fs.Flush(); |
|
339 |
||
340 |
const TLiwGenericParam* finaloutput = outParamList->FindFirst( pos,_L8("ReturnValue")); |
|
341 |
||
342 |
if ( finaloutput ) |
|
343 |
{ |
|
344 |
CLiwIterable* iterlist = finaloutput->Value().AsIterable(); |
|
345 |
||
346 |
//fs.Write(_L8("Got Iterable")); |
|
347 |
//fs.Flush(); |
|
348 |
||
349 |
if(iterlist) |
|
350 |
{ |
|
351 |
TLiwVariant data; |
|
352 |
||
353 |
if ( iterlist->NextL(data) ) |
|
354 |
result = KErrGeneral; |
|
355 |
||
356 |
//fs.Write(_L8("Before reset")); |
|
357 |
//fs.Flush(); |
|
358 |
data.Reset(); |
|
359 |
||
360 |
} |
|
361 |
} |
|
362 |
||
363 |
//fs.Write(_L8("Before param reset")); |
|
364 |
//fs.Flush(); |
|
365 |
inParamList->Reset(); |
|
366 |
outParamList->Reset(); |
|
367 |
} |
|
368 |
||
369 |
} |
|
370 |
//fs.Write(_L8("Before Interface reset")); |
|
371 |
//fs.Flush(); |
|
372 |
||
373 |
interface->Close(); |
|
374 |
//fs.Write(_L8("After interface close")); |
|
375 |
//fs.Flush(); |
|
376 |
||
377 |
//fs.Close(); |
|
378 |
//rFs.Close(); |
|
379 |
||
380 |
CleanupStack::PopAndDestroy( iServiceHandler ); |
|
381 |
||
382 |
__UHEAP_MARKEND; |
|
383 |
||
384 |
return result; |
|
385 |
||
386 |
} |
|
387 |
||
388 |
||
389 |
TInt CTDeleteMessageTest::DeleteMessageMms(CStifItemParser& /*aItem*/) |
|
390 |
{ |
|
391 |
__UHEAP_MARK; |
|
392 |
TInt result = KErrNone; |
|
393 |
||
394 |
CLiwServiceHandler* iServiceHandler = CLiwServiceHandler::NewL(); |
|
395 |
CleanupStack::PushL(iServiceHandler); |
|
396 |
CLiwGenericParamList* inParamList = &(iServiceHandler->InParamListL()); |
|
397 |
CLiwGenericParamList* outParamList = &(iServiceHandler->OutParamListL()); |
|
398 |
||
399 |
CLiwCriteriaItem* crit = CLiwCriteriaItem::NewL(1, KTestInterface,KTestContent); |
|
400 |
crit->SetServiceClass(TUid::Uid(KLiwClassBase)); |
|
401 |
||
402 |
RCriteriaArray a; |
|
403 |
a.AppendL(crit); |
|
404 |
||
405 |
iServiceHandler->AttachL(a); |
|
406 |
||
407 |
iServiceHandler->ExecuteServiceCmdL(*crit, *inParamList, *outParamList); |
|
408 |
||
409 |
a.Reset(); |
|
410 |
delete crit; |
|
411 |
||
412 |
TInt pos = 0; |
|
413 |
MLiwInterface* interface = NULL; |
|
414 |
outParamList->FindFirst(pos,KTestInterface ); |
|
415 |
if(pos != KErrNotFound) |
|
416 |
{ |
|
417 |
interface = (*outParamList)[pos].Value().AsInterface(); |
|
418 |
} |
|
419 |
||
420 |
outParamList->Reset(); |
|
421 |
inParamList->Reset(); |
|
422 |
||
423 |
if( interface ) |
|
424 |
{ |
|
425 |
pos =0; |
|
426 |
TLiwVariant content(_L("Inbox")); |
|
427 |
TLiwGenericParam elem ; |
|
428 |
elem.SetNameAndValueL(_L8("Type"),content); |
|
429 |
inParamList->AppendL(elem); |
|
430 |
content.Reset(); |
|
431 |
elem.Reset(); |
|
432 |
||
433 |
CLiwDefaultMap* map = CLiwDefaultMap::NewL(); |
|
434 |
CleanupStack::PushL(map); |
|
435 |
||
436 |
CLiwDefaultList* mtmtypelist = CLiwDefaultList::NewL(); |
|
437 |
CleanupStack::PushL(mtmtypelist); |
|
438 |
||
439 |
||
440 |
TLiwVariant smsmtm(KMsgTypeMMS); // how the user wud gv this param |
|
441 |
mtmtypelist->AppendL(smsmtm); |
|
442 |
smsmtm.Reset(); |
|
443 |
||
444 |
TLiwVariant add1(mtmtypelist); |
|
445 |
||
446 |
map->InsertL(_L8("MessageTypeList"), add1); // Mtmtype is added |
|
447 |
mtmtypelist->DecRef(); |
|
448 |
CleanupStack::Pop(mtmtypelist); |
|
449 |
add1.Reset(); |
|
450 |
||
451 |
||
452 |
TLiwVariant filterparam(map); |
|
453 |
TLiwGenericParam element ; |
|
454 |
element.SetNameAndValueL(_L8("Filter"),filterparam); |
|
455 |
filterparam.Reset(); |
|
456 |
||
457 |
||
458 |
inParamList->AppendL(element); |
|
459 |
element.Reset(); |
|
460 |
||
461 |
map->DecRef(); |
|
462 |
CleanupStack::Pop(map); |
|
463 |
||
464 |
||
465 |
TInt err = 0; |
|
466 |
TRAP(err,interface->ExecuteCmdL( KCmdGetHeaderList ,*inParamList ,*outParamList)); |
|
467 |
pos = 0 ; |
|
468 |
||
469 |
const TLiwGenericParam* output = outParamList->FindFirst( pos,_L8("ReturnValue")); |
|
470 |
||
471 |
TInt32 testmessageid = 0; |
|
472 |
||
473 |
if(output) |
|
474 |
{ |
|
475 |
CLiwIterable* iterlist = output->Value().AsIterable(); |
|
476 |
||
477 |
if(iterlist) |
|
478 |
{ |
|
479 |
TLiwVariant data; |
|
480 |
if(iterlist->NextL(data)) |
|
481 |
{ |
|
482 |
const CLiwMap* Map = data.AsMap(); |
|
483 |
if ( Map ) |
|
484 |
{ |
|
485 |
TLiwVariant messageid; |
|
486 |
Map->FindL(_L8("MessageId"),messageid); |
|
487 |
testmessageid = (TInt)messageid.AsTInt32(); |
|
488 |
messageid.Reset(); |
|
489 |
} |
|
490 |
} |
|
491 |
data.Reset(); |
|
492 |
} |
|
493 |
} |
|
494 |
inParamList->Reset(); |
|
495 |
outParamList->Reset(); |
|
496 |
||
497 |
if(testmessageid > 0) |
|
498 |
{ |
|
499 |
TLiwGenericParam msgid; |
|
500 |
TLiwVariant msgidvalue; |
|
501 |
||
502 |
msgidvalue.Set(testmessageid); |
|
503 |
msgid.SetNameAndValueL(KMessageId,msgidvalue); |
|
504 |
||
505 |
inParamList->AppendL(msgid); |
|
506 |
||
507 |
msgid.Reset(); |
|
508 |
msgidvalue.Reset(); |
|
509 |
||
510 |
interface->ExecuteCmdL(KCmd,*inParamList,*outParamList); |
|
511 |
||
512 |
inParamList->Reset(); |
|
513 |
outParamList->Reset(); |
|
514 |
||
515 |
||
516 |
TLiwVariant content(_L("Inbox")); |
|
517 |
TLiwGenericParam elem ; |
|
518 |
elem.SetNameAndValueL(_L8("Type"),content); |
|
519 |
inParamList->AppendL(elem); |
|
520 |
content.Reset(); |
|
521 |
elem.Reset(); |
|
522 |
||
523 |
CLiwDefaultMap* filtermap = CLiwDefaultMap::NewL(); |
|
524 |
CleanupStack::PushL(filtermap); |
|
525 |
||
526 |
TLiwVariant filterid( testmessageid ); |
|
527 |
map->InsertL(KMessageId, filterid); // Mtmtype is added |
|
528 |
filterid.Reset(); |
|
529 |
||
530 |
||
531 |
TLiwVariant filterparam(map); |
|
532 |
TLiwGenericParam element ; |
|
533 |
element.SetNameAndValueL(_L8("Filter"),filterparam); |
|
534 |
filterparam.Reset(); |
|
535 |
||
536 |
inParamList->AppendL(element); |
|
537 |
element.Reset(); |
|
538 |
||
539 |
map->DecRef(); |
|
540 |
CleanupStack::Pop(map); |
|
541 |
||
542 |
||
543 |
TInt err = 0; |
|
544 |
TRAP(err,interface->ExecuteCmdL( KCmdGetHeaderList ,*inParamList ,*outParamList)); |
|
545 |
pos = 0 ; |
|
546 |
||
547 |
||
548 |
const TLiwGenericParam* finaloutput = outParamList->FindFirst( pos,_L8("ReturnValue")); |
|
549 |
||
550 |
if ( finaloutput ) |
|
551 |
{ |
|
552 |
CLiwIterable* iterlist = finaloutput->Value().AsIterable(); |
|
553 |
||
554 |
if(iterlist) |
|
555 |
{ |
|
556 |
TLiwVariant data; |
|
557 |
||
558 |
if ( iterlist->NextL(data) ) |
|
559 |
result = KErrGeneral; |
|
560 |
||
561 |
data.Reset(); |
|
562 |
||
563 |
} |
|
564 |
} |
|
565 |
||
566 |
inParamList->Reset(); |
|
567 |
outParamList->Reset(); |
|
568 |
} |
|
569 |
} |
|
570 |
||
571 |
interface->Close(); |
|
572 |
||
573 |
CleanupStack::PopAndDestroy( iServiceHandler ); |
|
574 |
||
575 |
__UHEAP_MARKEND; |
|
576 |
||
577 |
return result; |
|
578 |
} |
|
579 |