|
1 // Copyright (c) 2000-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 // |
|
15 |
|
16 #ifndef __PUSHCLIENTMTM_H__ |
|
17 #define __PUSHCLIENTMTM_H__ |
|
18 |
|
19 #include <e32base.h> |
|
20 #include <mtclbase.h> |
|
21 |
|
22 /** |
|
23 * Skeleton Client MTM for the WAP Push Service. This is required by the MTM architecture, so that |
|
24 * Push Messages can be saved under a single WAP Push Service Entry. |
|
25 * The Push MTM neither sends nor recieves via a remote server, none of the MTM feature are supported |
|
26 * except for Find() |
|
27 */ |
|
28 |
|
29 //##ModelId=3B659E3F02B7 |
|
30 class CWapPushClientMtm : public CBaseMtm |
|
31 /** |
|
32 @internalTechnology |
|
33 @released |
|
34 */ |
|
35 { |
|
36 public: |
|
37 //##ModelId=3B659E3F02F6 |
|
38 IMPORT_C static CWapPushClientMtm* NewL(CRegisteredMtmDll& aRegisteredMtmDll, CMsvSession& aSession); |
|
39 //##ModelId=3B659E3F02F5 |
|
40 ~CWapPushClientMtm(); |
|
41 |
|
42 // from MMsvEntryObserver |
|
43 //##ModelId=3B659E3F02F0 |
|
44 void HandleEntryEvent(TMsvEntryEvent aEvent, TAny* aArg1, TAny* aArg2, TAny* aArg3); |
|
45 // |
|
46 // from CBaseMtm |
|
47 //##ModelId=3B659E3F02EF |
|
48 void SaveMessageL(); |
|
49 //##ModelId=3B659E3F02EE |
|
50 void LoadMessageL(); |
|
51 //##ModelId=3B659E3F02EA |
|
52 CMsvOperation* ReplyL (TMsvId aDestination, TMsvPartList aPartlist, TRequestStatus& aCompletionStatus); |
|
53 //##ModelId=3B659E3F02E2 |
|
54 CMsvOperation* ForwardL(TMsvId aDestination, TMsvPartList aPartList, TRequestStatus& aCompletionStatus); |
|
55 //##ModelId=3B659E3F02E0 |
|
56 TMsvPartList ValidateMessage(TMsvPartList aPartList); |
|
57 //##ModelId=3B659E3F02DD |
|
58 TMsvPartList Find(const TDesC& aTextToFind, TMsvPartList aPartList); |
|
59 //##ModelId=3B659E3F02DC |
|
60 #ifndef __MESSAGING_API_V2__ |
|
61 const CDesCArray& AddresseeList(); |
|
62 #endif // __MESSAGING_API_V2__ |
|
63 //##ModelId=3B659E3F02D7 |
|
64 void AddAddresseeL(const TDesC& aRealAddress); |
|
65 //##ModelId=3B659E3F02D9 |
|
66 void AddAddresseeL(const TDesC& aRealAddress, const TDesC& aAlias); |
|
67 //##ModelId=3B659E3F02D5 |
|
68 void RemoveAddressee(TInt aIndex); |
|
69 // --- RTTI functions --- |
|
70 //##ModelId=3B659E3F02D1 |
|
71 void InvokeSyncFunctionL(TInt aFunctionId,const CMsvEntrySelection& aSelection, TDes8& aParameter); |
|
72 //##ModelId=3B659E3F02CC |
|
73 CMsvOperation* InvokeAsyncFunctionL(TInt aFunctionId,const CMsvEntrySelection& aSelection, TDes8& aParameter, TRequestStatus& aCompletionStatus); |
|
74 |
|
75 protected: |
|
76 // from CBaseMtm |
|
77 //##ModelId=3B659E3F02CB |
|
78 void ContextEntrySwitched(); |
|
79 |
|
80 private: |
|
81 //##ModelId=3B659E3F02C0 |
|
82 CWapPushClientMtm(CRegisteredMtmDll& aRegisteredMtmDll, CMsvSession& aSession); |
|
83 |
|
84 TMsvPartList DoFindL(const TDesC& aTextToFind, TMsvPartList aPartList); |
|
85 }; |
|
86 |
|
87 |
|
88 #endif // __PUSHCLIENTMTM_H__ |