|
1 /* |
|
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: Presents plugin info using states uid, interface, type and name |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 |
|
20 #ifndef C_CPLUGININFO_H |
|
21 #define C_CPLUGININFO_H |
|
22 |
|
23 #include <e32base.h> |
|
24 |
|
25 namespace hspswrapper{ |
|
26 |
|
27 /** |
|
28 * Presents plugin info using states uid, interface, type and name |
|
29 * |
|
30 * @code |
|
31 * @endcode |
|
32 * |
|
33 * @lib xnlayoutengine.lib |
|
34 * @since S60 v5.0 |
|
35 */ |
|
36 class CPluginInfo : public CBase |
|
37 { |
|
38 public: |
|
39 /** |
|
40 * Two-phased constructor. |
|
41 */ |
|
42 IMPORT_C static CPluginInfo* NewL(); |
|
43 IMPORT_C static CPluginInfo* NewLC(); |
|
44 |
|
45 |
|
46 /** |
|
47 * Destructor. |
|
48 */ |
|
49 IMPORT_C virtual ~CPluginInfo(); |
|
50 |
|
51 /** |
|
52 * Set configuration uid |
|
53 * |
|
54 * @param aUid configuration uid |
|
55 */ |
|
56 IMPORT_C CPluginInfo& SetUidL(const TDesC8& aUid); |
|
57 |
|
58 /** |
|
59 * Get configuration uid |
|
60 * |
|
61 * @return configuration uid or KNullDesC8 |
|
62 */ |
|
63 IMPORT_C const TDesC8& Uid()const; |
|
64 |
|
65 /** |
|
66 * Set configuration type |
|
67 * |
|
68 * @param aType configuration type |
|
69 */ |
|
70 IMPORT_C CPluginInfo& SetTypeL(const TDesC8& aType); |
|
71 |
|
72 /** |
|
73 * Get configuration type |
|
74 * |
|
75 * @return configuration type or KNullDesC8 |
|
76 */ |
|
77 IMPORT_C const TDesC8& Type()const; |
|
78 |
|
79 /** |
|
80 * Set configuration interface |
|
81 * |
|
82 * @param aInterface configuration interface |
|
83 */ |
|
84 IMPORT_C CPluginInfo& SetInterfaceL(const TDesC8& aInterface); |
|
85 |
|
86 /** |
|
87 * Get configuration interface |
|
88 * |
|
89 * @return configuration interface or KNullDesC8 |
|
90 */ |
|
91 IMPORT_C const TDesC8& Interface()const; |
|
92 |
|
93 /** |
|
94 * Set configuration name |
|
95 * |
|
96 * @param aName configuration name |
|
97 */ |
|
98 IMPORT_C CPluginInfo& SetNameL(const TDesC8& aName); |
|
99 |
|
100 /** |
|
101 * Get configuration name |
|
102 * |
|
103 * @return configuration name or KNullDesC8 |
|
104 */ |
|
105 IMPORT_C const TDesC8& Name()const; |
|
106 |
|
107 /** |
|
108 * Set configuration state |
|
109 * |
|
110 * @param aConfigurationState configuration state |
|
111 */ |
|
112 IMPORT_C CPluginInfo& SetConfigurationStateL( |
|
113 const TDesC8& aConfigurationState); |
|
114 |
|
115 /** |
|
116 * Get configuration state |
|
117 * |
|
118 * @return configuration state or KNullDesC8 |
|
119 */ |
|
120 IMPORT_C const TDesC8& ConfigurationState()const; |
|
121 |
|
122 /** |
|
123 * Set widget multiinstance |
|
124 * |
|
125 * @param aMultiInstance widget multiinstance |
|
126 */ |
|
127 IMPORT_C CPluginInfo& SetMultiInstanceL( const TInt32 aMultiInstance ); |
|
128 |
|
129 /** |
|
130 * Get widget multiinstance |
|
131 * |
|
132 * @return widget multiinstance or KNullDesC8 |
|
133 */ |
|
134 IMPORT_C const TInt32& MultiInstance()const; |
|
135 |
|
136 |
|
137 /** |
|
138 * Get max children for the plugin |
|
139 * |
|
140 * @return max children |
|
141 */ |
|
142 IMPORT_C const TInt32& MaxChild() const; |
|
143 |
|
144 /** |
|
145 * Set maximum of children allowed |
|
146 * |
|
147 * @param aMaxChild max. number of children |
|
148 */ |
|
149 IMPORT_C CPluginInfo& SetMaxChild( const TInt32 aMaxChild ); |
|
150 |
|
151 /** |
|
152 * Set widget description |
|
153 * |
|
154 * @param aDescription widget description |
|
155 */ |
|
156 IMPORT_C CPluginInfo& SetDescriptionL( const TDesC& aDescription ); |
|
157 |
|
158 /** |
|
159 * Set widget description (TDesC8) |
|
160 * |
|
161 * @param aDescription widget description |
|
162 */ |
|
163 IMPORT_C CPluginInfo& SetDescriptionL( const TDesC8& aDescription ); |
|
164 |
|
165 /** |
|
166 * Get widget description |
|
167 * |
|
168 * @return Description widget description or KNullDesC |
|
169 */ |
|
170 IMPORT_C const TDesC& Description() const; |
|
171 |
|
172 /** |
|
173 * Set Logo icon |
|
174 * |
|
175 * @param aLogoIcon logo icon |
|
176 */ |
|
177 IMPORT_C CPluginInfo& SetLogoIconL( const TDesC& aLogoIcon ); |
|
178 |
|
179 /** |
|
180 * Set Logo icon (TDesC8) |
|
181 * |
|
182 * @param aLogoIcon logo icon |
|
183 */ |
|
184 IMPORT_C CPluginInfo& SetLogoIconL( const TDesC8& aLogoIcon ); |
|
185 |
|
186 /** |
|
187 * Get Logo icon |
|
188 * |
|
189 * @return LogoIcon logo icon or KNullDesC |
|
190 */ |
|
191 IMPORT_C const TDesC& LogoIcon() const; |
|
192 |
|
193 private: |
|
194 |
|
195 CPluginInfo(); |
|
196 |
|
197 void ConstructL(); |
|
198 |
|
199 |
|
200 private: // data |
|
201 |
|
202 /** |
|
203 * Own. Plugin uid |
|
204 */ |
|
205 HBufC8* iUid; |
|
206 |
|
207 /** |
|
208 * Own. Plugin interface |
|
209 */ |
|
210 HBufC8* iInterface; |
|
211 |
|
212 /** |
|
213 * Own. Plugin type |
|
214 */ |
|
215 HBufC8* iType; |
|
216 |
|
217 /** |
|
218 * Own. Plugin name |
|
219 */ |
|
220 HBufC8* iName; |
|
221 |
|
222 /** |
|
223 * Own. Plugin configuration state |
|
224 */ |
|
225 HBufC8* iConfigurationState; |
|
226 |
|
227 /** |
|
228 * Number of children allowed |
|
229 */ |
|
230 TInt32 iMaxChilds; |
|
231 |
|
232 /** |
|
233 * Own. Plugin description |
|
234 */ |
|
235 HBufC* iDescription; |
|
236 |
|
237 /** |
|
238 * Own. Plugin logo icon |
|
239 */ |
|
240 HBufC* iLogoIcon; |
|
241 |
|
242 /** |
|
243 * Own. Plugin instances |
|
244 */ |
|
245 TInt32 iMultiInstance; |
|
246 }; |
|
247 } |
|
248 |
|
249 #endif // C_CPLUGININFO_H |