|
1 /** @file |
|
2 * Copyright (c) 2008 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: Provides default implementation of MUpnpCpHttpClientRequestor interface. |
|
15 * |
|
16 */ |
|
17 |
|
18 #ifndef UPNPCPSTACKREQUESTORIMPL_H_ |
|
19 #define UPNPCPSTACKREQUESTORIMPL_H_ |
|
20 |
|
21 #include <e32base.h> |
|
22 #include "upnpcpstackrequestorimplbase.h" |
|
23 |
|
24 class CUpnpDispatcher; |
|
25 class CUpnpControlPoint; |
|
26 class MUpnpDiscoveryObserver; |
|
27 |
|
28 /** |
|
29 * @brief Class provides default implementation |
|
30 * of MUpnpCpStackRequestor interface |
|
31 * It simply delegates requests to the CUpnpDispatcher. |
|
32 * |
|
33 * @since Series60 3.2 |
|
34 */ |
|
35 NONSHARABLE_CLASS( CUpnpCpStackRequestorImpl ) : public CUpnpCpStackRequestorImplBase |
|
36 { |
|
37 public: |
|
38 /** |
|
39 * Two phased constructor |
|
40 * @since Series60 3.2 |
|
41 * @return an instance of CUpnpCpStackRequestorImpl class |
|
42 */ |
|
43 static CUpnpCpStackRequestorImpl* NewL( MUpnpDiscoveryObserver& aDiscoveryObserver ); |
|
44 |
|
45 /** |
|
46 * Destructor |
|
47 * @since Series60 3.2 |
|
48 */ |
|
49 virtual ~CUpnpCpStackRequestorImpl(); |
|
50 |
|
51 public: //from MUpnpCpStackRequestor |
|
52 |
|
53 virtual void SearchL( const TDesC8& aSearchString ); |
|
54 virtual void SearchL( const TDesC16& aSearchString ); |
|
55 virtual void AddCustomerL( const MUpnpDispatcherCustomer& aCustomer ); |
|
56 virtual void RemoveCustomer( const MUpnpDispatcherCustomer& aCustomer ); |
|
57 virtual TInetAddr HttpServerAddress(); |
|
58 |
|
59 |
|
60 virtual void SendLocalRequestL( CUpnpHttpMessage* aMessage, |
|
61 MUpnpDispatcherCustomer& aCustomer ); |
|
62 |
|
63 virtual void SendMessageL( CUpnpHttpMessage* aMessage, |
|
64 MUpnpDispatcherCustomer& aCustomer, |
|
65 TBool aIsLocal ); |
|
66 |
|
67 virtual void StopIgnoringL( const TDesC8& aUuids ); |
|
68 |
|
69 virtual void StartIPFilteringL(); |
|
70 virtual void StopIPFiltering(); |
|
71 |
|
72 /** |
|
73 * Stops http server |
|
74 */ |
|
75 virtual void StopHttpServer(); |
|
76 |
|
77 /** |
|
78 * Starts http server |
|
79 */ |
|
80 virtual void StartHttpServerL(); |
|
81 |
|
82 private: |
|
83 |
|
84 /** |
|
85 * C++ constructor |
|
86 */ |
|
87 CUpnpCpStackRequestorImpl(); |
|
88 |
|
89 /** |
|
90 * 2nd phase constructor |
|
91 */ |
|
92 void ConstructL( MUpnpDiscoveryObserver& aDiscoveryObserver ); |
|
93 |
|
94 private: |
|
95 |
|
96 // pointer to dispatcher |
|
97 CUpnpDispatcher* iDispatcher; |
|
98 }; |
|
99 |
|
100 #endif //UPNPCPSTACKREQUESTORIMPL_H_ |