branch | RCL_3 |
changeset 45 | a9c0808a1095 |
parent 44 | 0b68a1b0c15e |
44:0b68a1b0c15e | 45:a9c0808a1095 |
---|---|
293 TInt code = err.AsTInt32(); |
293 TInt code = err.AsTInt32(); |
294 |
294 |
295 if(iCase == EModifyContactComplete) |
295 if(iCase == EModifyContactComplete) |
296 { |
296 { |
297 //call the get list once again to check whether the contact is modified |
297 //call the get list once again to check whether the contact is modified |
298 CStifItemParser* stiff; |
298 CStifItemParser* stiff = NULL; |
299 iCase = EModifyContactVerify; |
299 iCase = EModifyContactVerify; |
300 //this time call the getlist with the contact id to get only the modified contact |
300 //this time call the getlist with the contact id to get only the modified contact |
301 GetContactALL(*stiff); |
301 GetContactALL(*stiff); |
302 } |
302 } |
303 else if(iCase == EGetAllContacts ||iCase == EDeleteContact |
303 else if(iCase == EGetAllContacts ||iCase == EDeleteContact |
574 iResult = KErrNone; |
574 iResult = KErrNone; |
575 } |
575 } |
576 else if(aEventId == KLiwEventCompleted && code == KErrNone ) |
576 else if(aEventId == KLiwEventCompleted && code == KErrNone ) |
577 { |
577 { |
578 iCase = EVerifyGroupAdd; |
578 iCase = EVerifyGroupAdd; |
579 CStifItemParser* stiff; |
579 CStifItemParser* stiff = NULL; |
580 iIdArrayList.ResetAndDestroy(); |
580 iIdArrayList.ResetAndDestroy(); |
581 GetGroup(*stiff); |
581 GetGroup(*stiff); |
582 } |
582 } |
583 else |
583 else |
584 { |
584 { |
608 iResult = KErrNone; |
608 iResult = KErrNone; |
609 } |
609 } |
610 else if(aEventId == KLiwEventCompleted && code == KErrNone ) |
610 else if(aEventId == KLiwEventCompleted && code == KErrNone ) |
611 { |
611 { |
612 iCase = EVerifyImport; |
612 iCase = EVerifyImport; |
613 CStifItemParser* stiff; |
613 CStifItemParser* stiff = NULL; |
614 GetContactALL(*stiff); |
614 GetContactALL(*stiff); |
615 } |
615 } |
616 else |
616 else |
617 { |
617 { |
618 iResult = code; |
618 iResult = code; |
621 else if( iCase == EOrganizeDelete ) |
621 else if( iCase == EOrganizeDelete ) |
622 { |
622 { |
623 if(aEventId == KLiwEventCompleted && code == KErrNone ) |
623 if(aEventId == KLiwEventCompleted && code == KErrNone ) |
624 { |
624 { |
625 iCase = EVerifyOrganizeDelete; |
625 iCase = EVerifyOrganizeDelete; |
626 CStifItemParser* stiff; |
626 CStifItemParser* stiff = NULL; |
627 iIdArrayList.ResetAndDestroy(); |
627 iIdArrayList.ResetAndDestroy(); |
628 GetGroup(*stiff); |
628 GetGroup(*stiff); |
629 } |
629 } |
630 else |
630 else |
631 { |
631 { |
712 mapField->FindL(KFieldValue,firstname); |
712 mapField->FindL(KFieldValue,firstname); |
713 firstName = firstname.AsDes(); |
713 firstName = firstname.AsDes(); |
714 if(firstName.CompareF(_L("Barbie")) != 0) |
714 if(firstName.CompareF(_L("Barbie")) != 0) |
715 { |
715 { |
716 iResult = KErrGeneral; |
716 iResult = KErrGeneral; |
717 return; |
717 return 0; |
718 } |
718 } |
719 |
719 |
720 if(map->FindL(KSecondName,mapfield)) |
720 if(map->FindL(KSecondName,mapfield)) |
721 mapField = mapfield.AsMap(); |
721 mapField = mapfield.AsMap(); |
722 count = mapField->Count(); |
722 count = mapField->Count(); |
723 mapField->FindL(KFieldValue,secname); |
723 mapField->FindL(KFieldValue,secname); |
724 secName = secname.AsDes(); |
724 secName = secname.AsDes(); |
725 if(secName.CompareF(_L("Doll")) != 0) |
725 if(secName.CompareF(_L("Doll")) != 0) |
726 { |
726 { |
727 iResult = KErrGeneral; |
727 iResult = KErrGeneral; |
728 return; |
728 return 0; |
729 } |
729 } |
730 |
730 |
731 if(map->FindL(KCallerObjImg,mapfield)) |
731 if(map->FindL(KCallerObjImg,mapfield)) |
732 mapField = mapfield.AsMap(); |
732 mapField = mapfield.AsMap(); |
733 count = mapField->Count(); |
733 count = mapField->Count(); |
734 mapField->FindL(KFieldValue,callerobjimg); |
734 mapField->FindL(KFieldValue,callerobjimg); |
735 callerObjImg = callerobjimg.AsDes(); |
735 callerObjImg = callerobjimg.AsDes(); |
736 if(callerObjImg.CompareF(_L("C:\\data\\images\\pic.jpg")) != 0) |
736 if(callerObjImg.CompareF(_L("C:\\data\\images\\pic.jpg")) != 0) |
737 { |
737 { |
738 iResult = KErrGeneral; |
738 iResult = KErrGeneral; |
739 return; |
739 return 0; |
740 } |
740 } |
741 if(map->FindL(KNote,mapfield)) |
741 if(map->FindL(KNote,mapfield)) |
742 mapField = mapfield.AsMap(); |
742 mapField = mapfield.AsMap(); |
743 count = mapField->Count(); |
743 count = mapField->Count(); |
744 mapField->FindL(KFieldValue,note); |
744 mapField->FindL(KFieldValue,note); |
745 Note = note.AsDes(); |
745 Note = note.AsDes(); |
746 if(Note.CompareF(_L("Lead role in Barbie, the island princess")) != 0) |
746 if(Note.CompareF(_L("Lead role in Barbie, the island princess")) != 0) |
747 { |
747 { |
748 iResult = KErrGeneral; |
748 iResult = KErrGeneral; |
749 return; |
749 return 0; |
750 } |
750 } |
751 |
751 |
752 if(map->FindL(KXSPID,mapfield)) |
752 if(map->FindL(KXSPID,mapfield)) |
753 mapField = mapfield.AsMap(); |
753 mapField = mapfield.AsMap(); |
754 //count = mapField->Count(); |
754 //count = mapField->Count(); |
761 { |
761 { |
762 TPtrC ptrVal = xspidVal.AsDes(); |
762 TPtrC ptrVal = xspidVal.AsDes(); |
763 if(ptrVal.CompareF(_L("Yahoo:Barbie@yahoo.co.in")) != 0 && ptrVal.CompareF(_L("Google:Barbie@gmail.com")) != 0) |
763 if(ptrVal.CompareF(_L("Yahoo:Barbie@yahoo.co.in")) != 0 && ptrVal.CompareF(_L("Google:Barbie@gmail.com")) != 0) |
764 { |
764 { |
765 iResult = KErrGeneral; |
765 iResult = KErrGeneral; |
766 return; |
766 return 0; |
767 } |
767 } |
768 } |
768 } |
769 } |
769 } |
770 |
770 |
771 } |
771 } |
773 else |
773 else |
774 { |
774 { |
775 iResult = code; |
775 iResult = code; |
776 } |
776 } |
777 } |
777 } |
778 return 0; |
|
778 } |
779 } |
779 |
780 |
780 void CTestProvider::LoadService() |
781 void CTestProvider::LoadService() |
781 { |
782 { |
782 TInt pos = 0; |
783 TInt pos = 0; |
1398 |
1399 |
1399 return iResult ; |
1400 return iResult ; |
1400 } |
1401 } |
1401 |
1402 |
1402 TInt CTestProvider :: ModifyGroup(CStifItemParser& /*aItem*/) |
1403 TInt CTestProvider :: ModifyGroup(CStifItemParser& /*aItem*/) |
1403 { |
1404 { return 0; |
1404 } |
1405 } |
1405 |
1406 |
1406 TInt CTestProvider :: ExportL( CStifItemParser& aItem ) |
1407 TInt CTestProvider :: ExportL( CStifItemParser& aItem ) |
1407 { |
1408 { |
1408 iCase = EDeleteContact; |
1409 iCase = EDeleteContact; |
1993 /** |
1994 /** |
1994 *Math Operation Find distance : Position based parameter |
1995 *Math Operation Find distance : Position based parameter |
1995 */ |
1996 */ |
1996 TInt CTestProvider :: ModifyContactPosBased(CStifItemParser& /*aItem*/) |
1997 TInt CTestProvider :: ModifyContactPosBased(CStifItemParser& /*aItem*/) |
1997 { |
1998 { |
1998 |
1999 return 0; |
1999 } |
2000 } |
2000 /** |
2001 /** |
2001 * Math operation BearingTo Test |
2002 * Math operation BearingTo Test |
2002 */ |
2003 */ |
2003 |
2004 |
2004 TInt CTestProvider ::ModifyGroupPosBased(CStifItemParser& /*aItem*/) |
2005 TInt CTestProvider ::ModifyGroupPosBased(CStifItemParser& /*aItem*/) |
2005 { |
2006 { return 0; |
2006 } |
2007 } |
2007 |
2008 |
2008 TInt CTestProvider :: ExportPosBased(CStifItemParser& aItem) |
2009 TInt CTestProvider :: ExportPosBased(CStifItemParser& aItem) |
2009 { |
2010 { |
2010 AddOneContactL(_L("Arnold")); |
2011 AddOneContactL(_L("Arnold")); |