|
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: This file contains the header file of the |
|
15 * : CSsServiceHandlerVoip class. |
|
16 * |
|
17 */ |
|
18 |
|
19 |
|
20 |
|
21 #ifndef CSSSETTINGSHANDLER_H |
|
22 #define CSSSETTINGSHANDLER_H |
|
23 |
|
24 // INCLUDES |
|
25 #include "cssconnectionhandler.h" |
|
26 #include <spsettings.h> |
|
27 #include <e32base.h> |
|
28 |
|
29 // CONSTANTS |
|
30 //None |
|
31 |
|
32 // MACROS |
|
33 //None |
|
34 |
|
35 // DATA TYPES |
|
36 //None. |
|
37 |
|
38 // FUNCTION PROTOTYPES |
|
39 //None |
|
40 |
|
41 // FORWARD DECLARATIONS |
|
42 |
|
43 // CLASS DECLARATION |
|
44 |
|
45 /** |
|
46 * VoIP settings handler class for service selector |
|
47 * |
|
48 * @lib ServiceSelector.lib |
|
49 * @since Series60_5.0 |
|
50 */ |
|
51 NONSHARABLE_CLASS( CSsSettingsHandler ) |
|
52 : public CBase |
|
53 { |
|
54 public: // Constructors and destructor |
|
55 |
|
56 /** |
|
57 * Two-phased constructor. |
|
58 */ |
|
59 static CSsSettingsHandler* NewL(); |
|
60 |
|
61 /** |
|
62 * Destructor. |
|
63 */ |
|
64 virtual ~CSsSettingsHandler(); |
|
65 |
|
66 public: // New functions |
|
67 |
|
68 /** |
|
69 * Gets registered services. |
|
70 * @param aConnection Connection handler. |
|
71 * @param aServiceIds Array of found services. |
|
72 * @return KErrNone if registered service(s) exists. |
|
73 */ |
|
74 TInt GetRegisteredServices( |
|
75 CSsConnectionHandler& aConnection, |
|
76 RArray<TUint>& aServiceIds ) const; |
|
77 |
|
78 /** |
|
79 * Gets all available services. |
|
80 * @param aServiceIds Array of found services. |
|
81 * @param aServiceNames Service name array of found services. |
|
82 * @return KErrNone if registered service(s) exists. |
|
83 */ |
|
84 TInt GetAllServices( |
|
85 RArray<TUint>& aServiceIds ) const; |
|
86 |
|
87 /** |
|
88 * Gets service names from sp settings by service id array. |
|
89 * @param aServiceIds Service id array. |
|
90 * @param aServiceNames Names of the services are returned |
|
91 * by the parameter. |
|
92 */ |
|
93 void GetServiceNamesL( RArray<TUint>& aServiceIds, |
|
94 CDesCArray& aServiceNames ) const; |
|
95 |
|
96 /** |
|
97 * Gets brand id for service. |
|
98 * @since S60 5.0 |
|
99 * @param aServiceId Used Service |
|
100 * @param aBrandId On completion, contains Brand Id |
|
101 */ |
|
102 void BrandIdL( TInt aServiceId, TDes8& aBrandId ); |
|
103 |
|
104 private: // New functions |
|
105 |
|
106 /** |
|
107 * Gets registered services. Leaves on failure. |
|
108 * Leaves with KErrNotFound if not any registered |
|
109 * services available. |
|
110 * @param aConnection Connection handler. |
|
111 * @param aServiceIds Array of found services. |
|
112 */ |
|
113 void DoGetRegisteredServicesL( |
|
114 CSsConnectionHandler& aConnection, |
|
115 RArray<TUint>& aServiceIds ) const; |
|
116 |
|
117 /** |
|
118 * Gets all available services. Leaves on failure. |
|
119 * Leaves with KErrNotFound if not any VoIP capable |
|
120 * services available. |
|
121 * @param aServiceIds Array of found services. |
|
122 */ |
|
123 void DoGetAllServicesL( |
|
124 RArray<TUint>& aServiceIds ) const; |
|
125 |
|
126 /** |
|
127 * Gets voip capable services from sp settings. |
|
128 * @param aServiceIds Array of the voip capable services. |
|
129 */ |
|
130 void GetVoipServicesL( RArray<TUint>& aServiceIds ) const; |
|
131 |
|
132 /** |
|
133 * Checks is the service as voip service. |
|
134 * @param aServiceId Id of the service. |
|
135 * @return ETrue if service is voip capable service. |
|
136 */ |
|
137 TBool IsVoipServiceL( TUint aServiceId ) const; |
|
138 |
|
139 |
|
140 private: |
|
141 |
|
142 /** |
|
143 * C++ default constructor. |
|
144 */ |
|
145 CSsSettingsHandler(); |
|
146 |
|
147 /** |
|
148 * By default Symbian 2nd phase constructor is private. |
|
149 */ |
|
150 void ConstructL(); |
|
151 |
|
152 |
|
153 private: // Data |
|
154 |
|
155 // Pointer to SP settings |
|
156 CSPSettings* iSettings; |
|
157 |
|
158 }; |
|
159 |
|
160 #endif // CSSSETTINGSHANDLER_H |
|
161 |
|
162 // End of File |