52 |
52 |
53 // P&S KEYS and categories |
53 // P&S KEYS and categories |
54 const TUid KTestPropertyCat={0x10012349}; |
54 const TUid KTestPropertyCat={0x10012349}; |
55 enum TTestPropertyKeys |
55 enum TTestPropertyKeys |
56 { |
56 { |
57 ETestCaseStateProperty = 1, |
57 ETestCaseStateProperty = 1, |
58 ETestParameterTypeProperty |
58 ETestParameterTypeProperty |
59 }; |
59 }; |
|
60 |
|
61 enum TCmsContactStore |
|
62 { |
|
63 ECmsContactStorePbk = 0, |
|
64 ECmsContactStoreSim, |
|
65 ECmsContactStoreSdn |
|
66 }; |
|
67 |
|
68 enum TCmsContactIdentifierType |
|
69 { |
|
70 ECmsPackedContactLinkArray = 0 |
|
71 }; |
60 |
72 |
61 // used in CCmsContactFieldItem creation |
73 // used in CCmsContactFieldItem creation |
62 const TInt PHONE = 1; |
74 const TInt PHONE = 1; |
63 const TInt EMAIL = 2; |
75 const TInt EMAIL = 2; |
64 const TInt VOIP = 3; |
76 const TInt VOIP = 3; |
66 const TInt PHONE2 = 5; |
78 const TInt PHONE2 = 5; |
67 const TInt EMAIL2 = 6; |
79 const TInt EMAIL2 = 6; |
68 const TInt VOIP2 = 7; |
80 const TInt VOIP2 = 7; |
69 const TInt NAME = 8; |
81 const TInt NAME = 8; |
70 |
82 |
71 /////////////////////////////////////////////////// |
83 // ----------------------------------------------------------------------------- |
72 // Dummy class interface |
84 // Dummy class |
73 // MCCAParameter |
85 // MCCAParameter |
74 /////////////////////////////////////////////////// |
86 // ----------------------------------------------------------------------------- |
75 class MCCAParameter |
87 class MCCAParameter |
76 { |
88 { |
77 |
89 |
78 public: |
90 public: |
79 |
91 |
178 private: |
190 private: |
179 void ConstructL() |
191 void ConstructL() |
180 { |
192 { |
181 // get property using category and key |
193 // get property using category and key |
182 TInt type( MCCAParameter::EContactNone ); |
194 TInt type( MCCAParameter::EContactNone ); |
183 TInt err = RProperty::Get( KTestPropertyCat, ETestParameterTypeProperty, type ); |
195 TInt err = RProperty::Get( |
|
196 KTestPropertyCat, ETestParameterTypeProperty, type ); |
184 |
197 |
185 if ( KErrNone == err ) |
198 if ( KErrNone == err ) |
186 { |
199 { |
187 switch ( type ) |
200 switch ( type ) |
188 { |
201 { |
220 |
233 |
221 TContactDataFlags iContactDataFlag; |
234 TContactDataFlags iContactDataFlag; |
222 HBufC* iContactData; |
235 HBufC* iContactData; |
223 |
236 |
224 }; |
237 }; |
225 |
238 |
226 |
239 |
227 /** |
240 // ----------------------------------------------------------------------------- |
228 * Contact identifier. |
241 // Dummy class |
229 */ |
242 // CCmsContactBase |
230 enum TCmsContactIdentifierType |
243 // ----------------------------------------------------------------------------- |
231 { |
|
232 ECmsPackedContactLinkArray = 0 |
|
233 }; |
|
234 |
|
235 |
|
236 /////////////////////////////////////////////////// |
|
237 // Dummy class |
|
238 // CCCAParameter |
|
239 /////////////////////////////////////////////////// |
|
240 class CCmsContactBase : public CBase |
244 class CCmsContactBase : public CBase |
241 { |
245 { |
242 public: |
246 public: |
243 CCmsContactBase( ) |
247 CCmsContactBase( ) |
244 { |
248 { |
330 TInt iDummyDefaultAttributeBitMask; |
337 TInt iDummyDefaultAttributeBitMask; |
331 TInt iDummy; |
338 TInt iDummy; |
332 TInt iType; |
339 TInt iType; |
333 }; |
340 }; |
334 |
341 |
335 /////////////////////////////////////////////////// |
342 // ----------------------------------------------------------------------------- |
336 // Dummy class |
343 // Dummy class |
337 // CCCAParameter |
344 // CCmsContactFieldInfo |
338 /////////////////////////////////////////////////// |
345 // ----------------------------------------------------------------------------- |
339 class CCmsContactFieldInfo : public CCmsContactBase |
346 class CCmsContactFieldInfo : public CCmsContactBase |
340 { |
347 { |
341 public: |
348 public: |
342 static CCmsContactFieldInfo* NewL() |
349 static CCmsContactFieldInfo* NewL() |
343 { |
350 { |
348 void ConstructL() |
355 void ConstructL() |
349 { |
356 { |
350 iArray = new (ELeave) RArray<CCmsContactFieldItem::TCmsContactField>(); |
357 iArray = new (ELeave) RArray<CCmsContactFieldItem::TCmsContactField>(); |
351 TInt testCase( 0 ); |
358 TInt testCase( 0 ); |
352 // get property using category and key |
359 // get property using category and key |
353 TInt err = RProperty::Get( KTestPropertyCat, ETestCaseStateProperty, testCase ); |
360 TInt err = RProperty::Get( |
|
361 KTestPropertyCat, ETestCaseStateProperty, testCase ); |
354 |
362 |
355 if ( KTestOneContactFieldItem == testCase |
363 if ( KTestOneContactFieldItem == testCase |
356 || KTestCompleteOpenWithError == testCase |
364 || KTestCompleteOpenWithError == testCase |
357 || KTestCompleteFetchWithError == testCase ) |
365 || KTestCompleteFetchWithError == testCase ) |
358 { |
366 { |
413 void Close() |
421 void Close() |
414 { |
422 { |
415 }; |
423 }; |
416 }; |
424 }; |
417 |
425 |
418 /////////////////////////////////////////////////// |
426 // ----------------------------------------------------------------------------- |
419 // Dummy class |
427 // Dummy class |
420 // RCmsContact |
428 // RCmsContact |
421 /////////////////////////////////////////////////// |
429 // ----------------------------------------------------------------------------- |
422 enum TCmsContactStore |
|
423 { |
|
424 ECmsContactStorePbk = 0, |
|
425 ECmsContactStoreSim, |
|
426 ECmsContactStoreSdn |
|
427 }; |
|
428 |
430 |
429 class RCmsContact : public CBase |
431 class RCmsContact : public CBase |
430 { |
432 { |
431 public: // New functions |
433 public: // New functions |
432 |
434 RCmsContact() : iTopContact( ETrue ){} |
433 TInt Open( RCmsSession& /*aSession*/, |
435 TInt Open( RCmsSession& /*aSession*/, |
434 TInt32 aContactId ) |
436 TInt32 aContactId ) |
435 { |
437 { |
436 iDesDummy.AppendNum( aContactId ); |
438 iDesDummy.AppendNum( aContactId ); |
437 return KErrNone; |
439 return KErrNone; |
480 HBufC8* GetContactIdentifierL() |
482 HBufC8* GetContactIdentifierL() |
481 { |
483 { |
482 return NULL; |
484 return NULL; |
483 }; |
485 }; |
484 |
486 |
485 TBool IsServiceAvailable( VPbkFieldTypeSelectorFactory::TVPbkContactActionTypeSelector /*aContactAction*/ ) const |
487 TBool IsServiceAvailable( |
|
488 VPbkFieldTypeSelectorFactory::TVPbkContactActionTypeSelector |
|
489 /*aContactAction*/ ) const |
486 { |
490 { |
487 return ETrue; |
491 return ETrue; |
488 }; |
492 }; |
489 |
493 |
490 void OrderNotificationsL( |
494 void OrderNotificationsL( |
491 MCmsNotificationHandlerAPI* /*aHandler*/, |
495 MCmsNotificationHandlerAPI* /*aHandler*/, |
492 CCmsContactFieldItem::TCmsContactNotification /*aNotificationType*/ ) |
496 CCmsContactFieldItem::TCmsContactNotification |
|
497 /*aNotificationType*/ ) |
493 { |
498 { |
494 }; |
499 }; |
495 |
500 |
496 TCmsContactStore ContactStore() const |
501 TCmsContactStore ContactStore() const |
497 { |
502 { |
498 const_cast<TBool&>(iContactStore_called) = ETrue; |
503 const_cast<TBool&>(iContactStore_called) = ETrue; |
|
504 return ECmsContactStorePbk; |
499 }; |
505 }; |
500 |
506 |
501 void CancelNotifications( |
507 void CancelNotifications( |
502 CCmsContactFieldItem::TCmsContactNotification /*aNotificationType*/ ) {}; |
508 CCmsContactFieldItem::TCmsContactNotification |
|
509 /*aNotificationType*/ ) {}; |
503 |
510 |
504 void DeleteL(){}; |
511 void DeleteL(){}; |
505 |
512 |
506 ~RCmsContact(){}; |
513 ~RCmsContact(){}; |
507 |
514 |
508 TInt GetContactActionFieldCount( |
515 TInt GetContactActionFieldCount( |
509 VPbkFieldTypeSelectorFactory::TVPbkContactActionTypeSelector /*aContactAction*/) |
516 VPbkFieldTypeSelectorFactory::TVPbkContactActionTypeSelector |
510 { |
517 /*aContactAction*/) |
511 return ETrue; //SendReceive( ECmsGetContactActionFieldCount, TIpcArgs( aContactAction ) ); |
518 { |
|
519 return ETrue; |
|
520 } |
|
521 |
|
522 void SetVoiceCallDefault( TRequestStatus& aStatus ) const |
|
523 { |
|
524 aStatus = KRequestPending; |
|
525 } |
|
526 TBool IsTopContact() |
|
527 { |
|
528 return iTopContact; |
512 } |
529 } |
513 |
530 |
514 public: |
531 public: |
515 |
532 |
516 TRequestStatus* iStatus; |
533 TRequestStatus* iStatus; |
517 TBuf8<128> iDes8Dummy; |
534 TBuf8<128> iDes8Dummy; |
518 TBuf<128> iDesDummy; |
535 TBuf<128> iDesDummy; |
519 |
536 |
520 TBool iContactStore_called; |
537 TBool iContactStore_called; |
|
538 TBool iTopContact; |
521 }; |
539 }; |
522 |
540 |
523 #include "ccacmscontactfetcherwrapper.h" |
541 #include "ccacmscontactfetcherwrapper.h" |
524 |
542 |
525 #endif // __CCACLIENTHEADERS_H__ |
543 #endif // __CCACLIENTHEADERS_H__ |