|
1 // Copyright (c) 2001-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 __CWSPCAPABILITYINFO_H__ |
|
17 #define __CWSPCAPABILITYINFO_H__ |
|
18 |
|
19 #include <e32base.h> |
|
20 #include <wsp/mwspcapabilityviewer.h> |
|
21 #include <wsp/mwspcapabilitysetter.h> |
|
22 |
|
23 class CWspAliasAddresses; |
|
24 class CWspExtendedMethods; |
|
25 class CWspHeaderCodePages; |
|
26 class CWspUnknownCapabilities; |
|
27 |
|
28 // Types used for arguments in this file (e.g. TWspBearer) are from the Wap namespace |
|
29 using namespace Wap; |
|
30 |
|
31 /** The CWspCapabilityInfo class implements the MWspCapabilityViewer and |
|
32 MWspCapabilitySetter APIs. |
|
33 @see MWspCapabilityViewer |
|
34 @see MWspCapabilitySetter |
|
35 */ |
|
36 //##ModelId=3C4C419F0099 |
|
37 class CWspCapabilityInfo : public CBase, public MWspCapabilityViewer, |
|
38 public MWspCapabilitySetter |
|
39 { |
|
40 public: // Methods |
|
41 |
|
42 /** Static factory function. |
|
43 @since 7.0 |
|
44 @leave This function will leave if the object fails to be created. |
|
45 @return A pointer to created CWspCapabilityInfo object. |
|
46 */ |
|
47 //##ModelId=3C4C419F0252 |
|
48 static CWspCapabilityInfo* NewL(); |
|
49 |
|
50 /** Destructor. |
|
51 @since 7.0 |
|
52 */ |
|
53 //##ModelId=3C4C419F0249 |
|
54 ~CWspCapabilityInfo(); |
|
55 |
|
56 public: // Methods from MWspCapabilityViewer |
|
57 |
|
58 /** |
|
59 @see MWspCapabilityViewer |
|
60 */ |
|
61 //##ModelId=3C4C419F0248 |
|
62 virtual const MWspAliasAddresses& GetAliasAddresses() const; |
|
63 |
|
64 /** |
|
65 @see MWspCapabilityViewer |
|
66 */ |
|
67 //##ModelId=3C4C419F0240 |
|
68 virtual const MWspExtendedMethods& GetExtendedMethods() const; |
|
69 |
|
70 /** |
|
71 @see MWspCapabilityViewer |
|
72 */ |
|
73 //##ModelId=3C4C419F023F |
|
74 virtual const MWspHeaderCodePages& GetHeaderCodePages() const; |
|
75 |
|
76 /** |
|
77 @see MWspCapabilityViewer |
|
78 */ |
|
79 //##ModelId=3C4C419F023E |
|
80 virtual TUint8 GetMethodMOR() const; |
|
81 |
|
82 /** |
|
83 @see MWspCapabilityViewer |
|
84 */ |
|
85 //##ModelId=3C4C419F0235 |
|
86 virtual TUint8 GetPushMOR() const; |
|
87 |
|
88 /** |
|
89 @see MWspCapabilityViewer |
|
90 */ |
|
91 //##ModelId=3C4C419F0234 |
|
92 virtual TUint8 GetProtocolOptions() const; |
|
93 |
|
94 /** |
|
95 @see MWspCapabilityViewer |
|
96 */ |
|
97 //##ModelId=3C4C419F022B |
|
98 virtual TUint32 GetClientSDUSize() const; |
|
99 |
|
100 /** |
|
101 @see MWspCapabilityViewer |
|
102 */ |
|
103 //##ModelId=3C4C419F022A |
|
104 virtual TUint32 GetServerSDUSize() const; |
|
105 |
|
106 /** |
|
107 @see MWspCapabilityViewer |
|
108 */ |
|
109 //##ModelId=3C4C419F0221 |
|
110 virtual TUint32 GetClientMessageSize() const; |
|
111 |
|
112 /** |
|
113 @see MWspCapabilityViewer |
|
114 */ |
|
115 //##ModelId=3C4C419F0220 |
|
116 virtual TUint32 GetServerMessageSize() const; |
|
117 |
|
118 /** |
|
119 @see MWspCapabilityViewer |
|
120 */ |
|
121 //##ModelId=3C4C419F0216 |
|
122 virtual const MWspUnknownCapabilities& GetUnknownCapabilities() const; |
|
123 |
|
124 public: // Methods from MWspCapabilitySetter |
|
125 |
|
126 /** |
|
127 @see MWspCapabilitySetter |
|
128 */ |
|
129 //##ModelId=3C4C419F020C |
|
130 virtual void Reset(TWspCapability aCapability = EAllCapabilities); |
|
131 |
|
132 /** |
|
133 @see MWspCapabilitySetter |
|
134 */ |
|
135 //##ModelId=3C4C419F01E4 |
|
136 virtual void AddAliasAddressL(TWspBearer aBearer, TUint16 aPort, const TDesC8& aAddress); |
|
137 |
|
138 /** |
|
139 @see MWspCapabilitySetter |
|
140 */ |
|
141 //##ModelId=3C4C419F01D0 |
|
142 virtual void AddExtendedMethodL(TUint8 aPDUType, const TDesC8& aMethodName); |
|
143 |
|
144 /** |
|
145 @see MWspCapabilitySetter |
|
146 */ |
|
147 //##ModelId=3C4C419F01B2 |
|
148 virtual void AddHeaderCodePageL(TUint8 aPageCode, const TDesC8& aPageName); |
|
149 |
|
150 /** |
|
151 @see MWspCapabilitySetter |
|
152 */ |
|
153 //##ModelId=3C4C419F01A8 |
|
154 virtual void SetMethodMOR(TUint8 aMOR); |
|
155 |
|
156 /** |
|
157 @see MWspCapabilitySetter |
|
158 */ |
|
159 //##ModelId=3C4C419F019E |
|
160 virtual void SetPushMOR(TUint8 aMOR); |
|
161 |
|
162 /** |
|
163 @see MWspCapabilitySetter |
|
164 */ |
|
165 //##ModelId=3C4C419F018A |
|
166 virtual void SetProtocolOptions(TUint8 aProtocolOptions); |
|
167 |
|
168 /** |
|
169 @see MWspCapabilitySetter |
|
170 */ |
|
171 //##ModelId=3C4C419F0180 |
|
172 virtual void SetClientSDUSize(TUint32 aSize); |
|
173 |
|
174 /** |
|
175 @see MWspCapabilitySetter |
|
176 */ |
|
177 //##ModelId=3C4C419F016C |
|
178 virtual void SetServerSDUSize(TUint32 aSize); |
|
179 |
|
180 /** |
|
181 @see MWspCapabilitySetter |
|
182 */ |
|
183 //##ModelId=3C4C419F0162 |
|
184 virtual void SetClientMessageSize(TUint32 aSize); |
|
185 |
|
186 /** |
|
187 @see MWspCapabilitySetter |
|
188 */ |
|
189 //##ModelId=3C4C419F0158 |
|
190 virtual void SetServerMessageSize(TUint32 aSize); |
|
191 |
|
192 /** |
|
193 @see MWspCapabilitySetter |
|
194 */ |
|
195 //##ModelId=3C4C419F013B |
|
196 virtual void AddUnknownCapabilityL(const TDesC8& aIdentifier, const TDesC8& aValue); |
|
197 |
|
198 private: // Methods |
|
199 |
|
200 /** |
|
201 Default constructor. |
|
202 @since 7.0 |
|
203 */ |
|
204 //##ModelId=3C4C419F013A |
|
205 CWspCapabilityInfo(); |
|
206 |
|
207 /**Second phase construction function. Does any required |
|
208 allocations needed to initialise object. |
|
209 @since 7.0 |
|
210 */ |
|
211 //##ModelId=3C4C419F0139 |
|
212 void ConstructL(); |
|
213 |
|
214 private: // Attributes |
|
215 |
|
216 /** The set of alias addresses. |
|
217 */ |
|
218 //##ModelId=3C4C419F012F |
|
219 CWspAliasAddresses* iAliasAddresses; |
|
220 |
|
221 /** The set of extended methods. |
|
222 */ |
|
223 //##ModelId=3C4C419F011D |
|
224 CWspExtendedMethods* iExtendedMethods; |
|
225 |
|
226 /** The set of header code pages. |
|
227 */ |
|
228 //##ModelId=3C4C419F0111 |
|
229 CWspHeaderCodePages* iHeaderCodePages; |
|
230 |
|
231 /** The method MOR value. |
|
232 */ |
|
233 //##ModelId=3C4C419F0107 |
|
234 TUint8 iMethodMOR; |
|
235 |
|
236 /** The push MOR value. |
|
237 */ |
|
238 //##ModelId=3C4C419F00F5 |
|
239 TUint8 iPushMOR; |
|
240 |
|
241 /** The set of protocol options. |
|
242 */ |
|
243 //##ModelId=3C4C419F00EB |
|
244 TUint8 iProtocolOptions; |
|
245 |
|
246 /** The Client SDU size. |
|
247 */ |
|
248 //##ModelId=3C4C419F00DF |
|
249 TUint32 iClientSDUSize; |
|
250 |
|
251 /** The Server SDU size. |
|
252 */ |
|
253 //##ModelId=3C4C419F00CD |
|
254 TUint32 iServerSDUSize; |
|
255 |
|
256 /** The Client message size. |
|
257 */ |
|
258 //##ModelId=3C4C419F00C3 |
|
259 TUint32 iClientMessageSize; |
|
260 |
|
261 /** The Server message size. |
|
262 */ |
|
263 //##ModelId=3C4C419F00B9 |
|
264 TUint32 iServerMessageSize; |
|
265 |
|
266 /** The set of unknown capabilities. |
|
267 */ |
|
268 //##ModelId=3C4C419F00B0 |
|
269 CWspUnknownCapabilities* iUnknownCapabilities; |
|
270 |
|
271 }; |
|
272 |
|
273 #endif // __CWSPCAPABILITYINFO_H__ |