|
1 /** @file |
|
2 * Copyright (c) 2005-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: Declares RUpnpDispatcherSession class |
|
15 * |
|
16 */ |
|
17 |
|
18 #ifndef C_RUPNPDISPATCHERSESSION_H |
|
19 #define C_RUPNPDISPATCHERSESSION_H |
|
20 |
|
21 // INCLUDES |
|
22 #include "upnpsessionbase.h" |
|
23 #include "upnpcommonstructs.h" |
|
24 |
|
25 // FORWARD DECLARATIONS |
|
26 |
|
27 |
|
28 // CLASS DECLARATION |
|
29 |
|
30 /** |
|
31 @brief Client-side interface to Message Handler |
|
32 |
|
33 This class provides the client-side interface to the message handler session |
|
34 */ |
|
35 class RUpnpDispatcherSession : public RUpnpSessionBase |
|
36 { |
|
37 public: |
|
38 |
|
39 /** |
|
40 * Construct the object |
|
41 */ |
|
42 RUpnpDispatcherSession(); |
|
43 |
|
44 /** |
|
45 * Establish connection with server |
|
46 */ |
|
47 TInt Connect(); |
|
48 |
|
49 /** |
|
50 * Requests Message Handler to start SSDP server. This server uses |
|
51 * aIap as Internet Access Point. This way all servers are bound to |
|
52 * same interface. |
|
53 */ |
|
54 void RequestStartSsdpL() const; |
|
55 |
|
56 /** |
|
57 * Requests Message Handler to get state SSDP server. This server uses |
|
58 */ |
|
59 void RequestCheckError( TInt& aIsStarted ); |
|
60 |
|
61 /** |
|
62 * Requests Message Handler to tell what IAP number it is using |
|
63 * and returns it to client. |
|
64 * @param aStatus The TRequestStatus variable of the dispatcher |
|
65 * @param aIap Reference to TInt that will hold the correct IAP |
|
66 * value after call finishes. |
|
67 */ |
|
68 void RequestActiveIap( TRequestStatus& aStatus, TInt& aIap ); |
|
69 |
|
70 /** |
|
71 * Asks Message Handler to send SSDP search with given string as SSDP |
|
72 * ST -header. |
|
73 * @param aStatus The TRequestStatus variable of the dispatcher |
|
74 * @param aSearch value of ST -header. |
|
75 * @param aMX values |
|
76 */ |
|
77 void RequestSsdpSearch( TRequestStatus& aStatus, TDesC8& aSearch, |
|
78 TDesC8& aMX ); |
|
79 |
|
80 /** |
|
81 * Request the Message Handler to add a local device to the network. |
|
82 * @param aStatus The TRequestStatus variable of the dispatcher |
|
83 * @param aDevice Structure containing buffer indexes to parse the buffer |
|
84 * @param aBuffer A buffer containing the actual data about the device |
|
85 */ |
|
86 void RequestAddLocalDevice( TRequestStatus& aStatus, |
|
87 TUpnpAddLocalDevice& aDevice, TPtr8& aBuffer ); |
|
88 |
|
89 /** |
|
90 * Request the Message Handler to remove a local device. |
|
91 * @param aStatus The TRequestStatus variable of the dispatcher |
|
92 * @param aUuid UUID of the device that will be removed from |
|
93 * device library. |
|
94 */ |
|
95 void RequestRemoveLocalDevice( TRequestStatus& aStatus, |
|
96 const TDesC8& aUuid ); |
|
97 |
|
98 /** |
|
99 * Request the Message Handler to remove silent a local device. |
|
100 * @param aStatus The TRequestStatus variable of the dispatcher |
|
101 * @param aUuid UUID of the device that will be removed from |
|
102 * device library. |
|
103 */ |
|
104 void RequestRemoveSilentLocalDevice( TRequestStatus& aStatus, |
|
105 const TDesC8& aUuid ); |
|
106 |
|
107 /** |
|
108 * Request the Message Handler to add a local control point client. |
|
109 */ |
|
110 void RequestAddControlPoint( TRequestStatus& aStatus ); |
|
111 |
|
112 /** |
|
113 * Request the Message Handler to remove a local control point client. |
|
114 */ |
|
115 void RequestRemoveControlPoint( TRequestStatus& aStatus ); |
|
116 |
|
117 /** |
|
118 * Request the Message Handler to get device list size. |
|
119 * @param aUuids Uuids of devices that should not be filtered. |
|
120 */ |
|
121 void RequestStopFiltering( const TDesC8& aUuids ); |
|
122 |
|
123 /** |
|
124 * Request the Message Handler to get device list size. |
|
125 * @param aStatus The TRequestStatus variable of the dispatcher |
|
126 * @param aSize Reference to structure that will contain numbers of |
|
127 * new devices and services. |
|
128 */ |
|
129 void RequestGetDeviceListSize( TRequestStatus& aStatus, |
|
130 TUpnpGetDeviceListSize& aSize ); |
|
131 |
|
132 /** |
|
133 * Request the Message Handler to get device list. |
|
134 * @param aStatus The TRequestStatus variable of the dispatcher |
|
135 * @param aDevPtr Pointer to buffer that will be used to store |
|
136 * information about new devices. |
|
137 * @param aServPtr Pointer to buffer that will be used to store |
|
138 * information about new services. |
|
139 */ |
|
140 void RequestGetDeviceList( TRequestStatus& aStatus, TPtr8& aDevPtr, |
|
141 TPtr8& aServPtr ) const; |
|
142 |
|
143 /** |
|
144 * Request stop |
|
145 */ |
|
146 void RequestStop(); |
|
147 |
|
148 private: |
|
149 |
|
150 /**Pointer for first parameter */ |
|
151 TPtr8 iParameter0; |
|
152 }; |
|
153 |
|
154 #endif // C_RUPNPDISPATCHERSESSION_H |
|
155 // End of File |