|
1 /* |
|
2 * Copyright (c) 2003-2009 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: |
|
15 * Name : sipprofileitchelper.h |
|
16 * Part of : SIP Profile Client |
|
17 * Interface : private |
|
18 * The wrapper class to hide SOS ITC access |
|
19 * Version : 1.0 |
|
20 * |
|
21 */ |
|
22 |
|
23 |
|
24 |
|
25 |
|
26 /** |
|
27 @internalComponent |
|
28 */ |
|
29 |
|
30 #ifndef CSIPPROFILEITCHELPER_H |
|
31 #define CSIPPROFILEITCHELPER_H |
|
32 |
|
33 // INCLUDES |
|
34 |
|
35 #include <e32base.h> |
|
36 #include <s32mem.h> |
|
37 #include <bamdesca.h> |
|
38 #include "sipprofilecs.h" |
|
39 |
|
40 // FORWARD DECLARATIONS |
|
41 |
|
42 class RSIPProfile; |
|
43 class CSIPConcreteProfile; |
|
44 class CSIPConcreteProfileHolder; |
|
45 class TSIPProfileSlots; |
|
46 class CSIPProfilePlugins; |
|
47 |
|
48 // CLASS DECLARATION |
|
49 |
|
50 /** |
|
51 * The class hides SOS ITC access. Separation done mainly for simplifying testing. |
|
52 * |
|
53 * @lib sipprofilecli.lib |
|
54 */ |
|
55 class CSIPProfileITCHelper: public CBase |
|
56 { |
|
57 public: |
|
58 |
|
59 /** |
|
60 * Constructor |
|
61 * @param aSip class providing ITC connection |
|
62 */ |
|
63 CSIPProfileITCHelper(RSIPProfile& aSip); |
|
64 |
|
65 /** |
|
66 * Genegal send of any ITC function |
|
67 * @param aArgs data to be passed |
|
68 * @param aFunction function to be called |
|
69 */ |
|
70 void SendL(TIpcArgs& aArgs, TSipProfileItcFunctions aFunction); |
|
71 |
|
72 /** |
|
73 * Send for TSIPProfileSlots class with any ITC function |
|
74 * @param aIds data to be passed |
|
75 * @param aITCFunction function to be called |
|
76 */ |
|
77 void SendL(TSIPProfileSlots& aIds, |
|
78 TSipProfileItcFunctions aITCFunction); |
|
79 |
|
80 /** |
|
81 * Send for TSIPProfileSlots class and narrator with any ITC function |
|
82 * @param aIds data to be passed |
|
83 * @param aITCFunction function to be called |
|
84 * @param aNarrator data that extra parameter for function |
|
85 */ |
|
86 void SendL(TSIPProfileSlots& aIds, |
|
87 TSipProfileItcFunctions aITCFunction, |
|
88 const TDesC8& aNarrator); |
|
89 |
|
90 /** |
|
91 * Send for CSIPConcreteProfile class with any ITC function |
|
92 * @param aITCFunction function to be called |
|
93 * @param aProfile profile to be passed |
|
94 */ |
|
95 void SendL(TSipProfileItcFunctions aITCFunction, |
|
96 const CSIPConcreteProfile& aProfile); |
|
97 |
|
98 /** |
|
99 * Send for TSIPProfileSlots and CSIPConcreteProfile class |
|
100 * with any ITC function |
|
101 * @param aIds data to be passed |
|
102 * @param aITCFunction function to be called |
|
103 * @param aProfile profile to be passed |
|
104 */ |
|
105 void SendL(TSIPProfileSlots& aIds, |
|
106 TSipProfileItcFunctions aITCFunction, |
|
107 const CSIPConcreteProfile& aProfile); |
|
108 |
|
109 /** |
|
110 * Send for TSIPProfileSlots class with any ITC function, does not leave |
|
111 * @param aIds data to be passed |
|
112 * @param aITCFunction function to be called |
|
113 * @return KErrNone if OK, otherwise error code. |
|
114 */ |
|
115 TInt Send(TSIPProfileSlots& aIds, TSipProfileItcFunctions aITCFunction); |
|
116 |
|
117 private: |
|
118 |
|
119 /** |
|
120 * Templete method for serializing passed data |
|
121 * @param aElements data to be serialized |
|
122 * @return serialized data. |
|
123 */ |
|
124 template<class T> CBufFlat* ExternalizeLC(const T& aElements); |
|
125 |
|
126 private: |
|
127 |
|
128 RSIPProfile& iSip; |
|
129 TIpcArgs iITCMsgArgs; |
|
130 }; |
|
131 |
|
132 #endif |