|
1 /* |
|
2 * Copyright (c) 2006 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 "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: Utils for message handling |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 |
|
20 #ifndef IMMESSAGEUTILSPC_H |
|
21 #define IMMESSAGEUTILSPC_H |
|
22 |
|
23 // INCLUDES |
|
24 #include <e32base.h> |
|
25 #include <apgcli.h> // RApaLsSession |
|
26 |
|
27 // FORWARD DECLARATIONS |
|
28 |
|
29 class MCAConversationPC; |
|
30 class MCAConversationMessage; |
|
31 class MCARecordedChatsPC; |
|
32 class MCAMessageContainer; |
|
33 class MCAMessageFlowHandlerPC; |
|
34 class MCAGroupPC; |
|
35 |
|
36 |
|
37 |
|
38 // CLASS DECLARATION |
|
39 |
|
40 /** |
|
41 * Utils for message handling |
|
42 * |
|
43 * @lib wvuiprocessng.lib |
|
44 * @since 3.2 |
|
45 */ |
|
46 class IMMessageUtilsPC |
|
47 { |
|
48 public: |
|
49 |
|
50 IMPORT_C static void SendFileL( |
|
51 MCAConversationPC& aMessageRWInterfacePC, |
|
52 const MDesCArray* aSelectedNames, |
|
53 const TBool aFileProtected, |
|
54 const TDesC& aFileName, |
|
55 const TDesC8& aContentType, |
|
56 const TDesC8& aContentData, |
|
57 const TDesC& aSender = KNullDesC, |
|
58 const TDesC& aSapId = KNullDesC, |
|
59 const TDesC& aUserId = KNullDesC, |
|
60 const MDesCArray* aRecipients = NULL ) ; |
|
61 |
|
62 IMPORT_C static TBool SendMessageL( |
|
63 const MCAConversationMessage& aMessage, |
|
64 const TDesC& aRecipient, |
|
65 MCAConversationPC& aMessageRWInterfacePC, |
|
66 const MDesCArray* aSelectedNames, |
|
67 const TDesC& aSender = KNullDesC, |
|
68 const TDesC& aSapId = KNullDesC, |
|
69 const TDesC& aUserId = KNullDesC, |
|
70 const TDesC& aFileName = KNullDesC, |
|
71 const MDesCArray* aRecipients = NULL ) ; |
|
72 |
|
73 /** |
|
74 * Create a clone from source message |
|
75 * @param aFwdSource, source message |
|
76 * @return New cloned message - transfers ownership to the caller |
|
77 */ |
|
78 IMPORT_C static MCAConversationMessage* CloneMessageL( |
|
79 const MCAConversationMessage& aFwdSource ); |
|
80 |
|
81 |
|
82 /** |
|
83 * Creates and returns the instance to Message Flow handler |
|
84 * The caller has to free this |
|
85 * @param aMessageContainer - ref to message container |
|
86 * @param aConversationPC - ref to conversation PC |
|
87 * @param aRecordedChatHandler Is this handler for recorded chat |
|
88 * or not. |
|
89 */ |
|
90 IMPORT_C static MCAMessageFlowHandlerPC* CreateInstanceL( |
|
91 MCAMessageContainer& aMessageContainer, |
|
92 MCAConversationPC& aConversationPC, |
|
93 TBool aRecordedChatHandler ); |
|
94 |
|
95 |
|
96 /** |
|
97 * Creates and returns the instance to Message Flow handler |
|
98 * The caller has to free this |
|
99 * @param aMessageContainer - ref to message container |
|
100 * @param aGroupPC - ref to group PC |
|
101 * @param aRecordedChatHandler Is this handler for recorded chat |
|
102 * or not. |
|
103 */ |
|
104 IMPORT_C static MCAMessageFlowHandlerPC* CreateInstanceL( |
|
105 MCAMessageContainer& aMessageContainer, |
|
106 MCAGroupPC& aGroupPC, |
|
107 TBool aRecordedChatHandler ); |
|
108 /** |
|
109 * Creates and returns the instance to Message Flow handler |
|
110 * The caller has to free this |
|
111 * @param aMessageContainer - ref to message container |
|
112 * @param aRecordedChatsPC - ref to RecordedChats PC |
|
113 * @param aRecordedChatHandler Is this handler for recorded chat |
|
114 * or not. |
|
115 */ |
|
116 IMPORT_C static MCAMessageFlowHandlerPC* CreateInstanceL( |
|
117 MCAMessageContainer& aMessageContainer, |
|
118 MCARecordedChatsPC& aRecordedChatsPC, |
|
119 TBool aRecordedChatHandler ); |
|
120 |
|
121 IMPORT_C static void SendFileL( |
|
122 MCAGroupPC& aMessageRWInterfacePC, |
|
123 const MDesCArray* aSelectedNames, |
|
124 const TBool aFileProtected, |
|
125 const TDesC& aFileName, |
|
126 const TDesC8& aContentType, |
|
127 const TDesC8& aContentData, |
|
128 const TDesC& aSender = KNullDesC, |
|
129 const TDesC& aSapId = KNullDesC, |
|
130 const TDesC& aUserId = KNullDesC, |
|
131 const MDesCArray* aRecipients = NULL ) ; |
|
132 |
|
133 IMPORT_C static TBool SendMessageL( |
|
134 const MCAConversationMessage& aMessage, |
|
135 const TDesC& aRecipient, |
|
136 MCAGroupPC& aMessageRWInterfacePC, |
|
137 const MDesCArray* aSelectedNames, |
|
138 const TDesC& aSender = KNullDesC, |
|
139 const TDesC& aSapId = KNullDesC, |
|
140 const TDesC& aUserId = KNullDesC, |
|
141 const TDesC& aFileName = KNullDesC, |
|
142 const MDesCArray* aRecipients = NULL ) ; |
|
143 |
|
144 }; |
|
145 |
|
146 #endif // IMMESSAGEUTILSPC_H |
|
147 |
|
148 // End of File |