|
1 // Copyright (c) 2008-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 __UPNPPARAMSET_H__ |
|
17 #define __UPNPPARAMSET_H__ |
|
18 |
|
19 #include <es_sock.h> |
|
20 #include <pnpextparameterfamily.h> |
|
21 #include <appprotintf/app_protintf_msgs.h> |
|
22 |
|
23 const TInt KUPnPParamsFactoryUid = 0x2000D05E; |
|
24 |
|
25 /** |
|
26 UPnP ParameterSet Family Identifiers. |
|
27 @publishedPartner |
|
28 @prototype |
|
29 */ |
|
30 enum TUPnPParamSetFamily |
|
31 { |
|
32 // Used by Control Point |
|
33 EUPnPRegisterAnnouncementParamSet = 1, |
|
34 EUPnPAbsenceAnnouncementParamSet = 2, |
|
35 EUPnPPresenceAnnouncementParamSet = 3, |
|
36 EUPnPDiscoverRequestParamSet = 4, |
|
37 EUPnPDiscoverResponseParamSet = 5, |
|
38 //Do not use the 6 as it is used by family which carries implementation UID of SCPR. |
|
39 EUPnPDescribeRequestParamSet = 7, |
|
40 EUPnPDescribeResponseParamSet = 8, |
|
41 EUPnPSubscribeRequestParamSet = 9, |
|
42 EUPnPSubscribeResponseParamSet = 10, |
|
43 EUPnPNotifyEventParamSet = 11, |
|
44 EUPnPCancelDiscoverParamSet = 12, |
|
45 EUPnPCancelDescribeParamSet = 13, |
|
46 EUPnPCancelSubscribeParamSet = 14, |
|
47 EUPnPCancelRegisterNotifyParamSet = 15, |
|
48 EUPnPRequestParamSet = 16, |
|
49 EUPnPResponseParamSet = 17, |
|
50 |
|
51 // Used by Service Point |
|
52 EUPnPServiceRegisterParamSet = 18, |
|
53 EUPnPDeviceRegisterParamSet = 19, |
|
54 EUPnPServiceNotificationParamSet = 20, |
|
55 EUPnPServiceRefreshParamSet = 21, |
|
56 EUPnPPublishResponseParamSet = 22, |
|
57 |
|
58 //@internalTechnology |
|
59 //@prototype |
|
60 //Used by UPnP Server to clear responses handled to UPnP Client with GetParameters |
|
61 EUPnPClearParamSet, |
|
62 EUPnPDeviceRegisterParamSetBase, |
|
63 EUPnPDeviceRegisterParamSetExt, |
|
64 }; |
|
65 |
|
66 /** |
|
67 class TUPnPEvent |
|
68 UPnPEvent class defines the reason code for an event callback. |
|
69 @publishedPartner |
|
70 @prototype |
|
71 */ |
|
72 NONSHARABLE_CLASS(TUPnPEvent) |
|
73 { |
|
74 public: |
|
75 /** Type of UPnP Event. */ |
|
76 enum TEventType |
|
77 { |
|
78 /** This signifies that the operation completed successfully. */ |
|
79 ESuccess, |
|
80 /** This is a 'catch-all' for communicating failures. The actual error reason is |
|
81 shown in error code. */ |
|
82 EFail, |
|
83 /** This signifies a discovery search timeout */ |
|
84 EDiscoveryTimeout, |
|
85 /** This signifies a subscription request timeout */ |
|
86 ESubscriptionTimeout |
|
87 }; |
|
88 |
|
89 public: |
|
90 /** The event status. */ |
|
91 TInt iStatus; |
|
92 /** The error code value. */ |
|
93 TInt iErrorCode; |
|
94 }; |
|
95 |
|
96 |
|
97 |
|
98 |
|
99 /** |
|
100 The base class for all UPnP ParamSet classes. |
|
101 |
|
102 @internalTechnology |
|
103 @prototype |
|
104 */ |
|
105 NONSHARABLE_CLASS (CUPnPParamSetBase) : public CSubConExtensionParameterSet |
|
106 { |
|
107 public: |
|
108 inline static CUPnPParamSetBase* NewL ( RParameterFamily& aFamily, TUPnPParamSetFamily aFamilyType ); |
|
109 protected: |
|
110 inline CUPnPParamSetBase (); |
|
111 }; |
|
112 |
|
113 |
|
114 // ------------------------------------------------------------------- |
|
115 |
|
116 /** |
|
117 Parameter set class containing a Uri. All UPnP Request ParamSet classes derive from this class. |
|
118 |
|
119 @internalTechnology |
|
120 @prototype |
|
121 */ |
|
122 NONSHARABLE_CLASS ( CUPnPRequestParamSetBase ) : public CUPnPParamSetBase |
|
123 { |
|
124 protected: |
|
125 RBuf8 iUri; |
|
126 public: |
|
127 inline void SetUriL ( const TDesC8& aUri ); |
|
128 inline const TDesC8& Uri () const; |
|
129 protected: |
|
130 inline CUPnPRequestParamSetBase (); |
|
131 inline ~CUPnPRequestParamSetBase (); |
|
132 protected: |
|
133 DATA_VTABLE |
|
134 }; |
|
135 |
|
136 // ---------------------------------------------------------------------- |
|
137 |
|
138 /** |
|
139 Parameter set class containing a UPnP Event. All UPnP Response ParamSet classes derive from this class. |
|
140 |
|
141 @internalTechnology |
|
142 @prototype |
|
143 */ |
|
144 NONSHARABLE_CLASS ( CUPnPResponseParamSetBase ) : public CUPnPRequestParamSetBase |
|
145 { |
|
146 protected: |
|
147 TUPnPEvent iUPnPEvent; |
|
148 public: |
|
149 inline void SetUPnPEvent ( const TUPnPEvent& aEvent ); |
|
150 inline const TUPnPEvent& UPnPEvent () const; |
|
151 protected: |
|
152 inline CUPnPResponseParamSetBase (); |
|
153 protected: |
|
154 DATA_VTABLE |
|
155 }; |
|
156 |
|
157 // ------------------------------------------------------------------------- |
|
158 |
|
159 /** UPnP Control Point ParameterSet classes. */ |
|
160 |
|
161 /** |
|
162 Parameter set class for discovering services/devices. |
|
163 Calling client should set the ServiceType/DeviceType and maximum wait time. |
|
164 |
|
165 @publishedPartner |
|
166 @prototype |
|
167 */ |
|
168 NONSHARABLE_CLASS(CUPnPDiscoverRequestParamSet) : public CUPnPRequestParamSetBase |
|
169 { |
|
170 private: |
|
171 TInt iTimeToDelayResponse; |
|
172 public : |
|
173 inline static CUPnPDiscoverRequestParamSet* NewL( RParameterFamily& aFamily ); |
|
174 inline void SetResponseTime(TInt aResponseTime); |
|
175 inline TInt ResponseTime( ) const ; |
|
176 protected: |
|
177 DATA_VTABLE |
|
178 }; |
|
179 |
|
180 // --------------------------------------------------------------------------- |
|
181 |
|
182 /** |
|
183 Parameter set class for subscribing to remote service. Client should set the ServiceLocation and Duration |
|
184 of subscription. |
|
185 |
|
186 @publishedPartner |
|
187 @prototype |
|
188 */ |
|
189 NONSHARABLE_CLASS(CUPnPSubscribeRequestParamSet) : public CUPnPRequestParamSetBase |
|
190 { |
|
191 protected: |
|
192 TInt iTimeoutSeconds; |
|
193 TAppProtAddr iRemoteHost; |
|
194 |
|
195 public: |
|
196 inline static CUPnPSubscribeRequestParamSet* NewL( RParameterFamily& aFamily ); |
|
197 inline void SetDuration(TInt aDuration); |
|
198 inline TInt Duration( ) const ; |
|
199 |
|
200 //@internalTechnology |
|
201 //@prototype |
|
202 inline void SetRemoteHost( const TInetAddr& aHost ); |
|
203 //@internalTechnology |
|
204 //@prototype |
|
205 inline const TAppProtAddr& RemoteHost ( ) const; |
|
206 protected: |
|
207 DATA_VTABLE |
|
208 }; |
|
209 |
|
210 // ---------------------------------------------------------------------------- |
|
211 |
|
212 /** |
|
213 Parameter set class for registering SSDP:Alive request of a service/device. Caller should send the |
|
214 ServiceType/DeviceType to register for announcements. |
|
215 |
|
216 @publishedPartner |
|
217 @prototype |
|
218 */ |
|
219 NONSHARABLE_CLASS(CUPnPRegisterAnnouncementParamSet) : public CUPnPRequestParamSetBase |
|
220 { |
|
221 public: |
|
222 TBool iRegister; |
|
223 inline static CUPnPRegisterAnnouncementParamSet* NewL ( RParameterFamily& aFamily ); |
|
224 inline void SetRegisterVariable(TBool aValue); |
|
225 inline TBool RegisterVariable(); |
|
226 protected: |
|
227 DATA_VTABLE |
|
228 }; |
|
229 |
|
230 // ----------------------------------------------------------------------------- |
|
231 |
|
232 /** |
|
233 Parameter set class for describe request. Caller should set the ServiceType/DeviceType to be described. |
|
234 |
|
235 @publishedPartner |
|
236 @prototype |
|
237 */ |
|
238 NONSHARABLE_CLASS(CUPnPDescribeRequestParamSet) : public CUPnPRequestParamSetBase |
|
239 { |
|
240 private: |
|
241 TAppProtAddr iHostAddr; |
|
242 |
|
243 public: |
|
244 inline static CUPnPDescribeRequestParamSet* NewL ( RParameterFamily& aFamily ); |
|
245 |
|
246 //@internalTechnology |
|
247 //@prototype |
|
248 inline void SetRemoteHost( const TInetAddr& aHost ); |
|
249 //@internalTechnology |
|
250 //@prototype |
|
251 inline const TAppProtAddr& RemoteHost ( ) const; |
|
252 |
|
253 protected: |
|
254 DATA_VTABLE |
|
255 }; |
|
256 // ----------------------------------------------------------------------------- |
|
257 /** |
|
258 Parameter set class for cancel discover request. |
|
259 @publishedPartner |
|
260 @prototype |
|
261 */ |
|
262 |
|
263 NONSHARABLE_CLASS(CUPnPCancelDiscoverParamSet) : public CUPnPRequestParamSetBase |
|
264 { |
|
265 public: |
|
266 inline static CUPnPCancelDiscoverParamSet* NewL( RParameterFamily& aFamily ); |
|
267 |
|
268 protected: |
|
269 DATA_VTABLE |
|
270 }; |
|
271 |
|
272 // ----------------------------------------------------------------------------- |
|
273 /** |
|
274 Parameter set class for cancel describe request. |
|
275 @publishedPartner |
|
276 @prototype |
|
277 */ |
|
278 |
|
279 NONSHARABLE_CLASS(CUPnPCancelDescribeParamSet) : public CUPnPRequestParamSetBase |
|
280 { |
|
281 public: |
|
282 inline static CUPnPCancelDescribeParamSet* NewL( RParameterFamily& aFamily ); |
|
283 |
|
284 protected: |
|
285 DATA_VTABLE |
|
286 }; |
|
287 |
|
288 // ----------------------------------------------------------------------------- |
|
289 /** |
|
290 Parameter set class for cancel subscribe request. |
|
291 @publishedPartner |
|
292 @prototype |
|
293 */ |
|
294 |
|
295 NONSHARABLE_CLASS(CUPnPCancelSubscribeParamSet) : public CUPnPRequestParamSetBase |
|
296 { |
|
297 public: |
|
298 inline static CUPnPCancelSubscribeParamSet* NewL( RParameterFamily& aFamily ); |
|
299 |
|
300 protected: |
|
301 DATA_VTABLE |
|
302 }; |
|
303 |
|
304 // ----------------------------------------------------------------------------- |
|
305 /** |
|
306 Parameter set class for cancel register notify request. |
|
307 @publishedPartner |
|
308 @prototype |
|
309 */ |
|
310 NONSHARABLE_CLASS(CUPnPCancelRegisterNotifyParamSet) : public CUPnPRequestParamSetBase |
|
311 { |
|
312 public: |
|
313 inline static CUPnPCancelRegisterNotifyParamSet* NewL( RParameterFamily& aFamily ); |
|
314 |
|
315 protected: |
|
316 DATA_VTABLE |
|
317 }; |
|
318 |
|
319 // ----------------------------------------------------------------------------- |
|
320 |
|
321 /** |
|
322 Parameter set class for retrieving the responses of discovery requests. Client can extract remote device |
|
323 information such as Device Location, Unique Service Name (USN) and Max age of the advertisement in |
|
324 callback function. |
|
325 |
|
326 @publishedPartner |
|
327 @prototype |
|
328 */ |
|
329 NONSHARABLE_CLASS(CUPnPDiscoverResponseParamSet) : public CUPnPResponseParamSetBase |
|
330 { |
|
331 private: |
|
332 TInt iExpiration; |
|
333 RBuf8 iDeviceLocation; |
|
334 RBuf8 iUSN; |
|
335 public : |
|
336 |
|
337 inline TInt ExpiryTime ( ) const ; |
|
338 inline const TDesC8& DeviceLocation ( ) const ; |
|
339 inline const TDesC8& USN ( ) const ; |
|
340 |
|
341 // Internal APIs |
|
342 inline static CUPnPDiscoverResponseParamSet* NewL( RParameterFamily& aFamily ); |
|
343 inline void SetExpiryTime( TInt aExpiryTime ); |
|
344 inline void SetDeviceLocationL( const TDesC8& aDeviceLocation ); |
|
345 inline void SetUSNL( const TDesC8& aUSN ); |
|
346 |
|
347 // D'tor |
|
348 inline ~CUPnPDiscoverResponseParamSet (); |
|
349 protected: |
|
350 DATA_VTABLE |
|
351 }; |
|
352 |
|
353 // ------------------------------------------------------------------------------------- |
|
354 |
|
355 /** |
|
356 Parameter set class for retrieving responses of describe requests. Client can extract the device description |
|
357 in callback function. |
|
358 |
|
359 @publishedPartner |
|
360 @prototype |
|
361 */ |
|
362 NONSHARABLE_CLASS(CUPnPDescribeResponseParamSet) : public CUPnPResponseParamSetBase |
|
363 { |
|
364 private: |
|
365 RBuf8 iDescription; |
|
366 public: |
|
367 inline const TDesC8& Description( ) const ; |
|
368 inline static CUPnPDescribeResponseParamSet* NewL( RParameterFamily& aFamily ); |
|
369 inline void SetDescriptionL( const TDesC8& aDescription ); |
|
370 inline ~CUPnPDescribeResponseParamSet (); |
|
371 protected: |
|
372 DATA_VTABLE |
|
373 }; |
|
374 // ------------------------------------------------------------------------------------- |
|
375 |
|
376 /** |
|
377 Parameter set class for retrieving response of subscription request. Calling client can extract the |
|
378 subscription status in callback function. |
|
379 |
|
380 @publishedPartner |
|
381 @prototype |
|
382 */ |
|
383 NONSHARABLE_CLASS(CUPnPSubscribeResponseParamSet) : public CUPnPResponseParamSetBase |
|
384 { |
|
385 private: |
|
386 TInt iTimeoutSeconds; |
|
387 public: |
|
388 inline TInt GetTimerExpiry() const; |
|
389 inline void SetTimerExpiry(TInt aExpiryTime); |
|
390 inline static CUPnPSubscribeResponseParamSet* NewL( RParameterFamily& aFamily ); |
|
391 protected: |
|
392 DATA_VTABLE |
|
393 }; |
|
394 // ------------------------------------------------------------------------------------- |
|
395 |
|
396 /** |
|
397 Parameter set class for retrieving the event notification. Calling client can extract the |
|
398 notification information in callback function. If notification order is not matched an error code |
|
399 is returned to the client. |
|
400 |
|
401 @publishedPartner |
|
402 @prototype |
|
403 */ |
|
404 NONSHARABLE_CLASS(CUPnPNotifyEventParamSet) : public CUPnPResponseParamSetBase |
|
405 { |
|
406 private: |
|
407 RBuf8 iNotifyData; |
|
408 public: |
|
409 inline const TDesC8& Notification( ) const ; |
|
410 inline static CUPnPNotifyEventParamSet* NewL( RParameterFamily& aFamily ); |
|
411 inline void SetNotificationL ( const TDesC8& aNotification ); |
|
412 inline ~CUPnPNotifyEventParamSet (); |
|
413 protected: |
|
414 DATA_VTABLE |
|
415 }; |
|
416 // ------------------------------------------------------------------------------------- |
|
417 |
|
418 /** |
|
419 Parameter set class for retrieving the SSDP:ByeBye message. Calling client can extract the |
|
420 published information in callback function. |
|
421 |
|
422 @publishedPartner |
|
423 @prototype |
|
424 */ |
|
425 NONSHARABLE_CLASS(CUPnPAbsenceAnnouncementParamSet) : public CUPnPResponseParamSetBase |
|
426 { |
|
427 protected: |
|
428 RBuf8 iUSN; |
|
429 public: |
|
430 inline const TDesC8& USN( ) const ; |
|
431 inline static CUPnPAbsenceAnnouncementParamSet* NewL( RParameterFamily& aFamily ); |
|
432 inline void SetUSNL(const TDesC8& aUSN); |
|
433 |
|
434 // D'tor |
|
435 inline ~CUPnPAbsenceAnnouncementParamSet (); |
|
436 protected: |
|
437 DATA_VTABLE |
|
438 }; |
|
439 // ------------------------------------------------------------------------------------- |
|
440 |
|
441 /** |
|
442 Parameter set class for retrieving SSDP:Alive message. Calling client can extract the |
|
443 published information in callback function. |
|
444 |
|
445 @publishedPartner |
|
446 @prototype |
|
447 */ |
|
448 NONSHARABLE_CLASS(CUPnPPresenceAnnouncementParamSet) : public CUPnPAbsenceAnnouncementParamSet |
|
449 { |
|
450 private: |
|
451 TInt iExpiration; |
|
452 RBuf8 iLocation; |
|
453 public: |
|
454 inline TInt Duration( ) const ; |
|
455 inline const TDesC8& ServiceLocation( ) const ; |
|
456 // Internal APIs |
|
457 inline static CUPnPPresenceAnnouncementParamSet* NewL( RParameterFamily& aFamily ); |
|
458 inline void SetDuration( TInt aDuration ); |
|
459 inline void SetServiceLocationL( const TDesC8& aServiceLocation ); |
|
460 |
|
461 // D'tor |
|
462 inline ~CUPnPPresenceAnnouncementParamSet (); |
|
463 protected: |
|
464 DATA_VTABLE |
|
465 }; |
|
466 // ------------------------------------------------------------------------------------- |
|
467 |
|
468 /** UPnP Service Point ParameterSet classes. */ |
|
469 |
|
470 /** |
|
471 Parameter set class for registering the service and publishing the service information. Service Client |
|
472 should set the following fields : |
|
473 |
|
474 CUPnPRequestParamSetBase::SetUriL ServiceType |
|
475 SetDeviceUidL Root device uid |
|
476 SetCacheControlData Max age of notification |
|
477 SetServiceDescriptionL Scdp url (url for description) |
|
478 SetInitialMessageL Initial Eventing message ( This message is the same as the initial eventing message which is sent along with subscribe response |
|
479 See UPnP Device Architecture 1.0 ) |
|
480 |
|
481 Refer to UPnP Device Architecture 1.0 |
|
482 |
|
483 @publishedPartner |
|
484 @prototype |
|
485 */ |
|
486 NONSHARABLE_CLASS( CUPnPServiceRegisterParamSet ) : public CUPnPRequestParamSetBase |
|
487 { |
|
488 |
|
489 private: |
|
490 RBuf8 iDeviceUid; |
|
491 TInt iCacheControl; |
|
492 RBuf8 iServiceDescription; |
|
493 RBuf8 iInitialEventMessage; |
|
494 TInt iTimeOut; |
|
495 |
|
496 public: |
|
497 inline ~CUPnPServiceRegisterParamSet (); |
|
498 inline static CUPnPServiceRegisterParamSet* NewL(RParameterFamily& aFamily); |
|
499 inline void SetDeviceUidL(const TDesC8& aUSN); |
|
500 inline void SetCacheControlData(TInt aCacheControlData); |
|
501 inline void SetServiceDescriptionL(const TDesC8& aServiceDescription); |
|
502 inline void SetInitialMessageL(const TDesC8& aInitialMessage); |
|
503 inline void SetSubscriptionDuration(TInt aTimeOut); |
|
504 |
|
505 inline const TDesC8& DeviceUid( ) const ; |
|
506 inline TInt CacheControlData( ) const ; |
|
507 inline const TDesC8& ServiceDescription( ) const ; |
|
508 inline const TDesC8& InitialMessage() const; |
|
509 inline TInt SubscriptionDuration( ) const; |
|
510 |
|
511 protected: |
|
512 DATA_VTABLE |
|
513 }; |
|
514 |
|
515 /** Parameter class to register Icon for embedded device.User should set the required parameters |
|
516 SetMimeTypeL Format of the Image |
|
517 SetUrlL Url to the Icon (Relative to Base Url) |
|
518 SetWidth Horizontal pixels |
|
519 SetHeight Vertical pixels |
|
520 SetDepth Color Depth |
|
521 |
|
522 Refer to UPnP Device Architecture 1.0 |
|
523 @publishedPartner |
|
524 @prototype |
|
525 */ |
|
526 class CUPnPIconParams: public CBase |
|
527 { |
|
528 public: |
|
529 inline static CUPnPIconParams* NewL(); |
|
530 inline ~CUPnPIconParams (); |
|
531 |
|
532 inline void SetMimeTypeL ( const TDesC8& aMimeType ); |
|
533 inline void SetUrlL ( const TDesC8& aUrl ); |
|
534 inline void SetWidth ( TInt aWidth ); |
|
535 inline void SetHeight ( TInt aHeight ); |
|
536 inline void SetDepth ( TInt aDepth ); |
|
537 |
|
538 inline const TDesC8& MimeType () const; |
|
539 inline const TDesC8& Url () const; |
|
540 inline TInt Width () const; |
|
541 inline TInt Height () const; |
|
542 inline TInt Depth () const; |
|
543 |
|
544 private: |
|
545 RBuf8 iMimeType; |
|
546 RBuf8 iUrl; |
|
547 TInt iWidth; |
|
548 TInt iHeight; |
|
549 TInt iDepth; |
|
550 }; |
|
551 |
|
552 typedef RPointerArray < CUPnPIconParams > CUPnPIconList; |
|
553 |
|
554 /** Parameter set base class for registering the device.User should set the required parameters |
|
555 SetCacheControlData Time for which notification is valid |
|
556 SetParentDeviceUidL If the device is an embedded device then its parent device should be specified here |
|
557 SetFriendlyNameL Friendly name ( length < 64 chars) |
|
558 SetManufacturerL Manufacturers name ( length < 64 chars) |
|
559 SetManufactureUrlL Manufacturer url(optional) |
|
560 SetModelDescL Short model description (optional ,length < 128 chars) |
|
561 SetModelNameL Model name ( length < 32 chars) |
|
562 SetModelNumberL Optional (length < 32 chars) |
|
563 SetModelUriL Web site for model ( optional ) |
|
564 SetPresentationL This is the url of the GUI of the service point if any provided |
|
565 SetSerialNumberL Serial Number (optional, length < 64 chars) |
|
566 SetUDNL Unique device name |
|
567 SetUPCL Universal product code ( optional, 12 digits) |
|
568 |
|
569 Refer to UPnP Device Architecture 1.0 |
|
570 @publishedPartner |
|
571 @prototype |
|
572 */ |
|
573 NONSHARABLE_CLASS( CUPnPDeviceRegisterParamSetBase ) : public CUPnPRequestParamSetBase |
|
574 { |
|
575 |
|
576 protected: |
|
577 TInt iCacheControl; |
|
578 RBuf8 iParentDeviceUid; |
|
579 RBuf8 iFriendlyName; |
|
580 RBuf8 iManufacturer; |
|
581 RBuf8 iManufacturerURL; |
|
582 RBuf8 iModelDescription; |
|
583 RBuf8 iModelName; |
|
584 RBuf8 iModelNumber; |
|
585 RBuf8 iModelURL; |
|
586 RBuf8 iPresentationURL; |
|
587 RBuf8 iSerialNumber; |
|
588 RBuf8 iUDN; |
|
589 RBuf8 iUPC; |
|
590 |
|
591 protected: |
|
592 inline CUPnPDeviceRegisterParamSetBase (); |
|
593 inline ~CUPnPDeviceRegisterParamSetBase (); |
|
594 |
|
595 public: |
|
596 inline void SetCacheControlData (TInt aCacheControlData); |
|
597 inline void SetParentDeviceUidL ( const TDesC8& aParentDeviceUid ); |
|
598 inline void SetFriendlyNameL ( const TDesC8& aFriendlyName ); |
|
599 inline void SetManufacturerL ( const TDesC8& aManufacturer ); |
|
600 inline void SetManufactureUrlL ( const TDesC8& aManUrl ); |
|
601 inline void SetModelDescL ( const TDesC8& aModelDesc ); |
|
602 inline void SetModelNameL ( const TDesC8& aModelName ); |
|
603 inline void SetModelNumberL ( const TDesC8& aModelNumber ); |
|
604 inline void SetModelUriL ( const TDesC8& aModelUri ); |
|
605 inline void SetPresentationL ( const TDesC8& aPresentationUri ); |
|
606 inline void SetSerialNumberL ( const TDesC8& aSerialNumber ); |
|
607 inline void SetUDNL ( const TDesC8& aUri ); |
|
608 inline void SetUPCL ( const TDesC8& aUri ); |
|
609 |
|
610 inline TInt CacheControlData( ) const ; |
|
611 inline const TDesC8& ParentDeviceUid() const; |
|
612 inline const TDesC8& FriendlyName() const; |
|
613 inline const TDesC8& Manufacturer() const; |
|
614 inline const TDesC8& ManufacturerUrl() const; |
|
615 inline const TDesC8& ModelDesc() const; |
|
616 inline const TDesC8& ModelName() const; |
|
617 inline const TDesC8& ModelNumber() const; |
|
618 inline const TDesC8& ModelUri() const; |
|
619 inline const TDesC8& PresentationUri() const; |
|
620 inline const TDesC8& SerialNumber() const; |
|
621 inline const TDesC8& UDN() const; |
|
622 inline const TDesC8& UPC() const; |
|
623 |
|
624 protected: |
|
625 DATA_VTABLE |
|
626 }; |
|
627 |
|
628 /** Parameter set class for registering the device.User should set the required parameters |
|
629 SetIconInfoL Icons related to the embedded device |
|
630 Refer to UPnP Device Architecture 1.0 |
|
631 @publishedPartner |
|
632 @prototype |
|
633 */ |
|
634 NONSHARABLE_CLASS( CUPnPDeviceRegisterParamSet ) : public CUPnPDeviceRegisterParamSetBase |
|
635 { |
|
636 private: |
|
637 CUPnPIconList iIconList; |
|
638 |
|
639 public: |
|
640 inline static CUPnPDeviceRegisterParamSet* NewL(RParameterFamily& aFamily); |
|
641 inline ~CUPnPDeviceRegisterParamSet(); |
|
642 |
|
643 inline void SetIconInfoL ( CUPnPIconParams* aIconInfo ); |
|
644 inline const CUPnPIconList& IconList () const; |
|
645 |
|
646 protected: |
|
647 DATA_VTABLE |
|
648 }; |
|
649 |
|
650 /** |
|
651 Parameter set class for sending event notifications. |
|
652 |
|
653 @publishedPartner |
|
654 @prototype |
|
655 */ |
|
656 NONSHARABLE_CLASS(CUPnPServiceNotificationParamSet) : public CUPnPRequestParamSetBase |
|
657 { |
|
658 private: |
|
659 RBuf8 iNotifyData; |
|
660 public: |
|
661 inline const TDesC8& Notification( ) const ; |
|
662 inline static CUPnPServiceNotificationParamSet* NewL( RParameterFamily& aFamily ); |
|
663 inline void SetNotificationL( const TDesC8& aNotification ); |
|
664 inline ~CUPnPServiceNotificationParamSet (); |
|
665 protected: |
|
666 DATA_VTABLE |
|
667 }; |
|
668 |
|
669 /** Parameter set class for receiving success or failure for service or device |
|
670 registration |
|
671 |
|
672 @publishedPartner |
|
673 @prototype |
|
674 */ |
|
675 NONSHARABLE_CLASS(CUPnPPublishResponseParamSet) : public CUPnPResponseParamSetBase |
|
676 { |
|
677 public: |
|
678 inline static CUPnPPublishResponseParamSet* NewL( RParameterFamily& aFamily); |
|
679 protected: |
|
680 DATA_VTABLE |
|
681 |
|
682 }; |
|
683 |
|
684 // ------------------------------------------------------------------------------------- |
|
685 |
|
686 |
|
687 |
|
688 // @internalTechnology |
|
689 // @prototype |
|
690 // Used by UPnP Client/Server serailize Icon List |
|
691 NONSHARABLE_CLASS( CUPnPDeviceRegisterParamSetExt ) : public CUPnPDeviceRegisterParamSetBase |
|
692 { |
|
693 private: |
|
694 RBuf8 iIconData; |
|
695 |
|
696 public: |
|
697 inline ~CUPnPDeviceRegisterParamSetExt(); |
|
698 inline static CUPnPDeviceRegisterParamSetExt* NewL(RParameterFamily& aFamily); |
|
699 |
|
700 inline void SetIconDataL ( const TDesC8& aIconData ); |
|
701 inline const TDesC8& IconData () const; |
|
702 |
|
703 protected: |
|
704 DATA_VTABLE |
|
705 }; |
|
706 // ------------------------------------------------------------------------------------- |
|
707 |
|
708 |
|
709 #include "upnpparamset.inl" |
|
710 |
|
711 #endif // __UPNPPARAMSET_H__ |