|
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: Defination of class HspsServiceUtilities |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 #ifndef _HSPSSERVICEUTILITIES_H |
|
20 #define _HSPSSERVICEUTILITIES_H |
|
21 |
|
22 |
|
23 // SYSTEM INCLUDES |
|
24 #include <f32file.h> |
|
25 #include <e32base.h> |
|
26 #include <hspsthememanagement.h> |
|
27 |
|
28 // USER INCLUDES |
|
29 |
|
30 /** |
|
31 * request Notification parameters |
|
32 */ |
|
33 struct THspsParamsRequestNotification |
|
34 { |
|
35 TInt event; // event |
|
36 TInt appUid; // uid of the application |
|
37 TInt appConfUid; // uid of application configuration |
|
38 TInt pluginUid; // uid of the plugin configuration to be added |
|
39 TInt pluginId; // Plugin Id |
|
40 TInt parentPluginId; // Id of the plugins parent plugin |
|
41 TBuf8<KMaxFileName> name; // name of the plugin |
|
42 }; |
|
43 // FORWARD DECLARATIONS |
|
44 |
|
45 /** |
|
46 * @ingroup group_hsps_sapi |
|
47 * This class provides common functionalties for HSPS services |
|
48 */ |
|
49 class HspsServiceUtilities |
|
50 { |
|
51 public: // Static method |
|
52 |
|
53 /** |
|
54 * Converts a hex value string (0xXXXX) to TInt |
|
55 * @param aStr String containing hex value |
|
56 * @return corresponding TInt |
|
57 */ |
|
58 static TInt HexString2IntL( |
|
59 const TDesC8& aStr ); |
|
60 |
|
61 /** |
|
62 * Converts a decimal value string to TInt |
|
63 * @param aStr String containing hex value |
|
64 * @return corresponding TInt |
|
65 */ |
|
66 static TInt DecString2Int( |
|
67 const TDesC8& aStr ); |
|
68 |
|
69 /** |
|
70 * Converts a configuration type string to the corresponding |
|
71 * configuration type enumeration. |
|
72 * @param aTypeStr Configuration type string |
|
73 * @param aType |
|
74 */ |
|
75 static void GetConfigurationTypeL( |
|
76 const TDesC8& aTypeStr, |
|
77 TUint& aType ); |
|
78 |
|
79 /** |
|
80 * Converts a configuration state string to the corresponding |
|
81 * configuration state enumeration. |
|
82 * @param aStateStr Configuration state string |
|
83 * @param aState |
|
84 */ |
|
85 static void GetConfigurationStateL( |
|
86 const TDesC8& aStateStr, |
|
87 ThspsConfigurationState& aState ); |
|
88 |
|
89 /** |
|
90 * Converts a configuration state filter string to the corresponding |
|
91 * configuration state filter enumeration. |
|
92 * @param aFilterStr Configuration state filter |
|
93 * @param aFilter |
|
94 */ |
|
95 static void GetConfigurationStateFilterL( |
|
96 const TDesC8& aFilterStr, |
|
97 ThspsConfStateChangeFilter& aFilter ); |
|
98 |
|
99 }; |
|
100 |
|
101 #endif // C_HSPSSERVICEUTILITIES_H |
|
102 |
|
103 // End of File. |