|
1 /* |
|
2 * Copyright (c) 2007 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: Header file for the CUpnpCommandParameters class. |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 #ifndef UPNP_COMMAND_PARAMETERS_H |
|
20 #define UPNP_COMMAND_PARAMETERS_H |
|
21 |
|
22 // INCLUDES |
|
23 #include <e32base.h> |
|
24 #include "upnpcommandcons.h" |
|
25 |
|
26 // FORWARD DECLARATIONS |
|
27 class MUpnpCommandCallback; |
|
28 |
|
29 /** |
|
30 * This class works as a storage class, storing parameter values used in |
|
31 * UpnpCommand component. |
|
32 */ |
|
33 class CUpnpCommandParameters : public CBase |
|
34 { |
|
35 public: // Instantiation methods |
|
36 |
|
37 /** |
|
38 * Creates an instance of the implementation. |
|
39 * |
|
40 * @return instance of this class. |
|
41 */ |
|
42 static CUpnpCommandParameters* NewL(); |
|
43 |
|
44 /** |
|
45 * Destructor. |
|
46 */ |
|
47 virtual ~CUpnpCommandParameters(); |
|
48 |
|
49 public: // Business logic methods |
|
50 |
|
51 /** |
|
52 * Sets the callback interface |
|
53 */ |
|
54 void SetObserver( MUpnpCommandCallback* aCallback ); |
|
55 |
|
56 /** |
|
57 * The callback interface |
|
58 */ |
|
59 MUpnpCommandCallback* Observer(); |
|
60 |
|
61 /** |
|
62 * Sets a parameter |
|
63 * |
|
64 * @param aParamType the parameter category (see upnpcommandcons.h) |
|
65 * @param aParamValue value to be set for the parameter |
|
66 */ |
|
67 void SetL( UpnpCommand::TUpnpParameterType aParamType, |
|
68 const TDesC& aParamValue ); |
|
69 |
|
70 /** |
|
71 * Returns a parameter |
|
72 * |
|
73 * @param aParamType the parameter category (see upnpcommandcons.h) |
|
74 * @return the parameter value |
|
75 */ |
|
76 const TDesC& Get( UpnpCommand::TUpnpParameterType aParamType ); |
|
77 |
|
78 /** |
|
79 * Clears all parameters |
|
80 */ |
|
81 void Reset(); |
|
82 |
|
83 private: // Private construction methods |
|
84 |
|
85 /** |
|
86 * Perform the first phase of two phase construction. |
|
87 */ |
|
88 CUpnpCommandParameters(); |
|
89 |
|
90 private: // Data members |
|
91 |
|
92 /** |
|
93 * Stores the collection name parameter. Owned. |
|
94 */ |
|
95 HBufC* iCollectionName; |
|
96 |
|
97 /** |
|
98 * Pointer to the command callback interface. Not owned. |
|
99 */ |
|
100 MUpnpCommandCallback* iCallback; |
|
101 |
|
102 }; |
|
103 |
|
104 #endif // UPNP_COMMAND_PARAMETERS_H |
|
105 |
|
106 // End of File |