44
|
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: Global WLAN settings Adapter
|
|
15 |
*
|
|
16 |
*/
|
|
17 |
|
|
18 |
|
|
19 |
|
|
20 |
#include "globalwlanadapter.h"
|
|
21 |
#include "nsmldebug.h"
|
|
22 |
#include <implementationproxy.h> // For TImplementationProxy definition
|
|
23 |
#include <commdb.h>
|
|
24 |
#include <WlanCdbCols.h>
|
|
25 |
#include <utf.h>
|
|
26 |
#include <cdbstore.h>
|
|
27 |
#include <cdbcols.h>
|
|
28 |
#include <f32file.h>
|
|
29 |
#include <e32const.h>
|
|
30 |
#include <s32strm.h>
|
|
31 |
#include <e32base.h>
|
|
32 |
#include <sysutil.h>
|
|
33 |
#include <e32cmn.h>
|
|
34 |
#include <featmgr.h>
|
|
35 |
|
|
36 |
#include <centralrepository.h>
|
|
37 |
#include <commsdattypesv1_1.h>
|
|
38 |
|
|
39 |
|
|
40 |
#ifndef __WINS__
|
|
41 |
// This lowers the unnecessary compiler warning (armv5) to remark.
|
|
42 |
// "Warning: #174-D: expression has no effect..." is caused by
|
|
43 |
// DBG_ARGS8 macro in no-debug builds.
|
|
44 |
#pragma diag_remark 174
|
|
45 |
#endif
|
|
46 |
|
|
47 |
|
|
48 |
//------------------------------------------------------------------------------
|
|
49 |
//
|
|
50 |
//------------------------------------------------------------------------------
|
|
51 |
const TImplementationProxy ImplementationTable[] =
|
|
52 |
{
|
|
53 |
IMPLEMENTATION_PROXY_ENTRY(0x1315DBE, CGlobalWLANAdapter::NewL)
|
|
54 |
};
|
|
55 |
|
|
56 |
//------------------------------------------------------------------------------
|
|
57 |
// TImplementationProxy* ImplementationGroupProxy()
|
|
58 |
//------------------------------------------------------------------------------
|
|
59 |
EXPORT_C const TImplementationProxy* ImplementationGroupProxy( TInt& aTableCount )
|
|
60 |
{
|
|
61 |
_DBG_FILE("ImplementationGroupProxy() for CGlobalWLANAdapter: begin");
|
|
62 |
|
|
63 |
aTableCount = sizeof(ImplementationTable) / sizeof(TImplementationProxy);
|
|
64 |
|
|
65 |
_DBG_FILE("ImplementationGroupProxy() for CGlobalWLANAdapter: end");
|
|
66 |
return ImplementationTable;
|
|
67 |
}
|
|
68 |
|
|
69 |
|
|
70 |
//-----------------------------------------------------------------------------
|
|
71 |
// CGlobalWLANAdapter* CGlobalWLANAdapter::NewL( )
|
|
72 |
//-----------------------------------------------------------------------------
|
|
73 |
CGlobalWLANAdapter* CGlobalWLANAdapter::NewL( MSmlDmCallback* aDmCallback )
|
|
74 |
{
|
|
75 |
_DBG_FILE("CGlobalWLANAdapter::NewL(): begin");
|
|
76 |
|
|
77 |
CGlobalWLANAdapter* self = NewLC( aDmCallback );
|
|
78 |
CleanupStack::Pop( self );
|
|
79 |
|
|
80 |
_DBG_FILE("CGlobalWLANAdapter::NewL(): end");
|
|
81 |
return self;
|
|
82 |
}
|
|
83 |
|
|
84 |
//-----------------------------------------------------------------------------
|
|
85 |
// CGlobalWLANAdapter* CGlobalWLANAdapter::NewLC( )
|
|
86 |
//-----------------------------------------------------------------------------
|
|
87 |
CGlobalWLANAdapter* CGlobalWLANAdapter::NewLC( MSmlDmCallback* aDmCallback )
|
|
88 |
{
|
|
89 |
_DBG_FILE("CGlobalWLANAdapter::NewLC(): begin");
|
|
90 |
|
|
91 |
CGlobalWLANAdapter* self = new(ELeave) CGlobalWLANAdapter(aDmCallback);
|
|
92 |
CleanupStack::PushL( self );
|
|
93 |
|
|
94 |
self->iCallBack = aDmCallback;
|
|
95 |
_DBG_FILE("CGlobalWLANAdapter::NewLC(): call constructL");
|
|
96 |
self->ConstructL( );
|
|
97 |
|
|
98 |
_DBG_FILE("CGlobalWLANAdapter::NewLC(): end");
|
|
99 |
return self;
|
|
100 |
}
|
|
101 |
|
|
102 |
//-----------------------------------------------------------------------------
|
|
103 |
// void CGlobalWLAdapter::ConstructL( )
|
|
104 |
// Second phase constructor
|
|
105 |
//-----------------------------------------------------------------------------
|
|
106 |
void CGlobalWLANAdapter::ConstructL( )
|
|
107 |
{
|
|
108 |
_DBG_FILE("CGlobalWLANAdapter::ConstructL(): begin");
|
|
109 |
|
|
110 |
// checks if Wlan feature is supported
|
|
111 |
FeatureManager::InitializeLibL();
|
|
112 |
iWlanSupported = FeatureManager::FeatureSupported( KFeatureIdProtocolWlan );
|
|
113 |
FeatureManager::UnInitializeLib();
|
|
114 |
|
|
115 |
iWriteSettings = new(ELeave) TGlobalSettings;
|
|
116 |
iReadSettings = new(ELeave) TGlobalSettings;
|
|
117 |
iReadStatuses = new(ELeave) TStatusResult;
|
|
118 |
iWriteStatuses = new(ELeave) TStatusResult;
|
|
119 |
|
|
120 |
// set "present" variables to false, since symbian inits thems as true
|
|
121 |
InitMemberVariables();
|
|
122 |
|
|
123 |
_DBG_FILE("CGlobalWLANAdapter::ConstructL(): end");
|
|
124 |
}
|
|
125 |
|
|
126 |
//-----------------------------------------------------------------------------
|
|
127 |
// CGlobalWLANAdapter::CGlobalWLANAdapter( )
|
|
128 |
// Constructor
|
|
129 |
//-----------------------------------------------------------------------------
|
|
130 |
CGlobalWLANAdapter::CGlobalWLANAdapter( TAny* aEcomArguments )
|
|
131 |
: CSmlDmAdapter(aEcomArguments)
|
|
132 |
{
|
|
133 |
_DBG_FILE("CGlobalWLANAdapter::CGlobalWLANAdapter(): begin");
|
|
134 |
_DBG_FILE("CGlobalWLANAdapter::CGlobalWLANAdapter(): end");
|
|
135 |
}
|
|
136 |
|
|
137 |
//-----------------------------------------------------------------------------
|
|
138 |
// CGlobalWLANAdapter::~CGlobalWLANAdapter( )
|
|
139 |
// Destructor
|
|
140 |
//-----------------------------------------------------------------------------
|
|
141 |
CGlobalWLANAdapter::~CGlobalWLANAdapter( )
|
|
142 |
{
|
|
143 |
_DBG_FILE("CGlobalWLANAdapter::~CGlobalWLANAdapter(): begin");
|
|
144 |
|
|
145 |
delete iWriteSettings;
|
|
146 |
delete iReadSettings;
|
|
147 |
delete iReadStatuses;
|
|
148 |
delete iWriteStatuses;
|
|
149 |
|
|
150 |
_DBG_FILE("CGlobalWLANAdapter::~CGlobalWLANAdapter(): end");
|
|
151 |
}
|
|
152 |
|
|
153 |
|
|
154 |
//-----------------------------------------------------------------------------
|
|
155 |
// CGlobalWLANAdapter* CGlobalWLANAdapter::DDFVersionL( CBufBase& aDDFVersion )
|
|
156 |
//-----------------------------------------------------------------------------
|
|
157 |
void CGlobalWLANAdapter::DDFVersionL( CBufBase& aDDFVersion )
|
|
158 |
{
|
|
159 |
_DBG_FILE("CGlobalWLANAdapter::DDFVersionL(): begin");
|
|
160 |
|
|
161 |
aDDFVersion.InsertL( 0, KNSmGlobalWlanAdapterDDFversion );
|
|
162 |
|
|
163 |
_DBG_FILE("CGlobalWLANAdapter::DDFVersionL(): end");
|
|
164 |
}
|
|
165 |
|
|
166 |
//-----------------------------------------------------------------------------
|
|
167 |
// CGlobalWLANAdapter* CGlobalWLANAdapter::DDFStructureL( MSmlDmDDFObject& aDDF )
|
|
168 |
//-----------------------------------------------------------------------------
|
|
169 |
void CGlobalWLANAdapter::DDFStructureL( MSmlDmDDFObject& aDDF )
|
|
170 |
{
|
|
171 |
_DBG_FILE("CGlobalWLANAdapter::DDFStructureL(): begin");
|
|
172 |
if( !iWlanSupported )
|
|
173 |
{
|
|
174 |
_DBG_FILE("CGlobalWLANAdapter::DDFStructureL(): WLAN not supported.");
|
|
175 |
return;
|
|
176 |
}
|
|
177 |
//
|
|
178 |
// Set Get, add and replace as acceptable operations
|
|
179 |
//
|
|
180 |
|
|
181 |
TSmlDmAccessTypes accessTypesGetAddReplace;
|
|
182 |
accessTypesGetAddReplace.SetAdd();
|
|
183 |
accessTypesGetAddReplace.SetGet();
|
|
184 |
accessTypesGetAddReplace.SetReplace();
|
|
185 |
|
|
186 |
//WLAN
|
|
187 |
MSmlDmDDFObject& rootWLan = aDDF.AddChildObjectL( KNSmlWLan );
|
|
188 |
FillNodeInfoL( rootWLan,
|
|
189 |
accessTypesGetAddReplace,
|
|
190 |
MSmlDmDDFObject::EZeroOrOne,
|
|
191 |
MSmlDmDDFObject::EDynamic,
|
|
192 |
MSmlDmDDFObject::ENode,
|
|
193 |
KNSmlEmpty );
|
|
194 |
|
|
195 |
//WLAN/InternetConnectivityTest
|
|
196 |
MSmlDmDDFObject& internetConnectivityTest = rootWLan.AddChildObjectL( KNSmlWLanInternetConnectivityTest );
|
|
197 |
FillNodeInfoL( internetConnectivityTest,
|
|
198 |
accessTypesGetAddReplace,
|
|
199 |
MSmlDmDDFObject::EZeroOrOne,
|
|
200 |
MSmlDmDDFObject::EDynamic,
|
|
201 |
MSmlDmDDFObject::EInt,
|
|
202 |
KNSmlEmpty );
|
|
203 |
|
|
204 |
//WLAN/UseDefaultSettings
|
|
205 |
MSmlDmDDFObject& useDefaultSettings = rootWLan.AddChildObjectL( KNSmlWLanUseDefaultSettings );
|
|
206 |
FillNodeInfoL( useDefaultSettings,
|
|
207 |
accessTypesGetAddReplace,
|
|
208 |
MSmlDmDDFObject::EZeroOrOne,
|
|
209 |
MSmlDmDDFObject::EDynamic,
|
|
210 |
MSmlDmDDFObject::EBool,
|
|
211 |
KNSmlEmpty );
|
|
212 |
|
|
213 |
//WLAN/LongRetryLimit
|
|
214 |
MSmlDmDDFObject& longRetryLimit = rootWLan.AddChildObjectL( KNSmlWLanLongRetryLimit );
|
|
215 |
FillNodeInfoL( longRetryLimit,
|
|
216 |
accessTypesGetAddReplace,
|
|
217 |
MSmlDmDDFObject::EZeroOrOne,
|
|
218 |
MSmlDmDDFObject::EDynamic,
|
|
219 |
MSmlDmDDFObject::EInt,
|
|
220 |
KNSmlEmpty );
|
|
221 |
|
|
222 |
//WLAN/ShortRetryLimit
|
|
223 |
MSmlDmDDFObject& shortRetryLimit = rootWLan.AddChildObjectL( KNSmlWLanShortRetryLimit );
|
|
224 |
FillNodeInfoL( shortRetryLimit,
|
|
225 |
accessTypesGetAddReplace,
|
|
226 |
MSmlDmDDFObject::EZeroOrOne,
|
|
227 |
MSmlDmDDFObject::EDynamic,
|
|
228 |
MSmlDmDDFObject::EInt,
|
|
229 |
KNSmlEmpty );
|
|
230 |
|
|
231 |
|
|
232 |
//WLAN/RTSThreshold
|
|
233 |
MSmlDmDDFObject& RTSThreshold = rootWLan.AddChildObjectL( KNSmlWLanRTSThreshold );
|
|
234 |
FillNodeInfoL( RTSThreshold,
|
|
235 |
accessTypesGetAddReplace,
|
|
236 |
MSmlDmDDFObject::EZeroOrOne,
|
|
237 |
MSmlDmDDFObject::EDynamic,
|
|
238 |
MSmlDmDDFObject::EInt,
|
|
239 |
KNSmlEmpty );
|
|
240 |
|
|
241 |
//WLAN/TXPowerLevel
|
|
242 |
MSmlDmDDFObject& TXPowerLevel = rootWLan.AddChildObjectL( KNSmlWLanTXPowerLevel );
|
|
243 |
FillNodeInfoL( TXPowerLevel,
|
|
244 |
accessTypesGetAddReplace,
|
|
245 |
MSmlDmDDFObject::EZeroOrOne,
|
|
246 |
MSmlDmDDFObject::EDynamic,
|
|
247 |
MSmlDmDDFObject::EInt,
|
|
248 |
KNSmlEmpty );
|
|
249 |
|
|
250 |
//WLAN/PowerSaving
|
|
251 |
MSmlDmDDFObject& powerSaving = rootWLan.AddChildObjectL( KNSmlWLanPowerSaving );
|
|
252 |
FillNodeInfoL( powerSaving,
|
|
253 |
accessTypesGetAddReplace,
|
|
254 |
MSmlDmDDFObject::EZeroOrOne,
|
|
255 |
MSmlDmDDFObject::EDynamic,
|
|
256 |
MSmlDmDDFObject::EBool,
|
|
257 |
KNSmlEmpty );
|
|
258 |
|
|
259 |
//WLAN/BackgroundScanInterval
|
|
260 |
MSmlDmDDFObject& backgroundScanInterval = rootWLan.AddChildObjectL( KNSmlWLanBackgroundScanInterval );
|
|
261 |
FillNodeInfoL( backgroundScanInterval,
|
|
262 |
accessTypesGetAddReplace,
|
|
263 |
MSmlDmDDFObject::EZeroOrOne,
|
|
264 |
MSmlDmDDFObject::EDynamic,
|
|
265 |
MSmlDmDDFObject::EInt,
|
|
266 |
KNSmlEmpty );
|
|
267 |
|
|
268 |
//WLAN/ScanRate
|
|
269 |
MSmlDmDDFObject& scanRate = rootWLan.AddChildObjectL( KNSmlWLanScanRate );
|
|
270 |
FillNodeInfoL( scanRate,
|
|
271 |
accessTypesGetAddReplace,
|
|
272 |
MSmlDmDDFObject::EZeroOrOne,
|
|
273 |
MSmlDmDDFObject::EDynamic,
|
|
274 |
MSmlDmDDFObject::EInt,
|
|
275 |
KNSmlEmpty );
|
|
276 |
|
|
277 |
//WLAN/RCPITrigger
|
|
278 |
MSmlDmDDFObject& RCPITrigger = rootWLan.AddChildObjectL( KNSmlWLanRCPITrigger );
|
|
279 |
FillNodeInfoL( RCPITrigger,
|
|
280 |
accessTypesGetAddReplace,
|
|
281 |
MSmlDmDDFObject::EZeroOrOne,
|
|
282 |
MSmlDmDDFObject::EDynamic,
|
|
283 |
MSmlDmDDFObject::EInt,
|
|
284 |
KNSmlEmpty );
|
|
285 |
|
|
286 |
//WLAN/MinActiveChannelTime
|
|
287 |
MSmlDmDDFObject& minActiveChannelTime = rootWLan.AddChildObjectL( KNSmlWLanMinActiveChannelTime );
|
|
288 |
FillNodeInfoL( minActiveChannelTime,
|
|
289 |
accessTypesGetAddReplace,
|
|
290 |
MSmlDmDDFObject::EZeroOrOne,
|
|
291 |
MSmlDmDDFObject::EDynamic,
|
|
292 |
MSmlDmDDFObject::EInt,
|
|
293 |
KNSmlEmpty );
|
|
294 |
|
|
295 |
//WLAN/MaxActiveChannelTime
|
|
296 |
MSmlDmDDFObject& maxActiveChannelTime = rootWLan.AddChildObjectL( KNSmlWLanMaxActiveChannelTime );
|
|
297 |
FillNodeInfoL( maxActiveChannelTime,
|
|
298 |
accessTypesGetAddReplace,
|
|
299 |
MSmlDmDDFObject::EZeroOrOne,
|
|
300 |
MSmlDmDDFObject::EDynamic,
|
|
301 |
MSmlDmDDFObject::EInt,
|
|
302 |
KNSmlEmpty );
|
|
303 |
|
|
304 |
//WLAN/MaxTxMSDULifeTime
|
|
305 |
MSmlDmDDFObject& maxTxMSDULifeTime = rootWLan.AddChildObjectL( KNSmlWLanMaxTxMSDULifeTime );
|
|
306 |
FillNodeInfoL( maxTxMSDULifeTime,
|
|
307 |
accessTypesGetAddReplace,
|
|
308 |
MSmlDmDDFObject::EZeroOrOne,
|
|
309 |
MSmlDmDDFObject::EDynamic,
|
|
310 |
MSmlDmDDFObject::EInt,
|
|
311 |
KNSmlEmpty );
|
|
312 |
|
|
313 |
//WLAN/ScanExpirationTimer
|
|
314 |
MSmlDmDDFObject& scanExpirationTimer = rootWLan.AddChildObjectL( KNSmlWLanScanExpirationTimer );
|
|
315 |
FillNodeInfoL( scanExpirationTimer,
|
|
316 |
accessTypesGetAddReplace,
|
|
317 |
MSmlDmDDFObject::EZeroOrOne,
|
|
318 |
MSmlDmDDFObject::EDynamic,
|
|
319 |
MSmlDmDDFObject::EInt,
|
|
320 |
KNSmlEmpty );
|
|
321 |
|
|
322 |
//WLAN/UnloadDriverTimer
|
|
323 |
MSmlDmDDFObject& unloadDriverTimer = rootWLan.AddChildObjectL( KNSmlWLanUnloadDriverTimer );
|
|
324 |
FillNodeInfoL( unloadDriverTimer,
|
|
325 |
accessTypesGetAddReplace,
|
|
326 |
MSmlDmDDFObject::EZeroOrOne,
|
|
327 |
MSmlDmDDFObject::EDynamic,
|
|
328 |
MSmlDmDDFObject::EInt,
|
|
329 |
KNSmlEmpty );
|
|
330 |
|
|
331 |
//WLAN/RoamTimer
|
|
332 |
MSmlDmDDFObject& roamTimer = rootWLan.AddChildObjectL( KNSmlWLanRoamTimer );
|
|
333 |
FillNodeInfoL( roamTimer,
|
|
334 |
accessTypesGetAddReplace,
|
|
335 |
MSmlDmDDFObject::EZeroOrOne,
|
|
336 |
MSmlDmDDFObject::EDynamic,
|
|
337 |
MSmlDmDDFObject::EInt,
|
|
338 |
KNSmlEmpty );
|
|
339 |
|
|
340 |
//WLAN/KNSmlWLanRCPIDifference
|
|
341 |
MSmlDmDDFObject& RCPIDifference = rootWLan.AddChildObjectL( KNSmlWLanRCPIDifference );
|
|
342 |
FillNodeInfoL( RCPIDifference,
|
|
343 |
accessTypesGetAddReplace,
|
|
344 |
MSmlDmDDFObject::EZeroOrOne,
|
|
345 |
MSmlDmDDFObject::EDynamic,
|
|
346 |
MSmlDmDDFObject::EInt,
|
|
347 |
KNSmlEmpty );
|
|
348 |
|
|
349 |
//WLAN/ConnRegainTimer
|
|
350 |
MSmlDmDDFObject& connRegainTimer = rootWLan.AddChildObjectL( KNSmlWLanConnRegainTimer );
|
|
351 |
FillNodeInfoL( connRegainTimer,
|
|
352 |
accessTypesGetAddReplace,
|
|
353 |
MSmlDmDDFObject::EZeroOrOne,
|
|
354 |
MSmlDmDDFObject::EDynamic,
|
|
355 |
MSmlDmDDFObject::EInt,
|
|
356 |
KNSmlEmpty );
|
|
357 |
|
|
358 |
//WLAN/MaxTriesToFindNw
|
|
359 |
MSmlDmDDFObject& maxTriesToFindNw = rootWLan.AddChildObjectL( KNSmlWLanMaxTriesToFindNw );
|
|
360 |
FillNodeInfoL( maxTriesToFindNw,
|
|
361 |
accessTypesGetAddReplace,
|
|
362 |
MSmlDmDDFObject::EZeroOrOne,
|
|
363 |
MSmlDmDDFObject::EDynamic,
|
|
364 |
MSmlDmDDFObject::EInt,
|
|
365 |
KNSmlEmpty );
|
|
366 |
|
|
367 |
//WLAN/DelayBetweenFindNw
|
|
368 |
MSmlDmDDFObject& delayBetweenFindNw = rootWLan.AddChildObjectL( KNSmlWLanDelayBetweenFindNw );
|
|
369 |
FillNodeInfoL( delayBetweenFindNw,
|
|
370 |
accessTypesGetAddReplace,
|
|
371 |
MSmlDmDDFObject::EZeroOrOne,
|
|
372 |
MSmlDmDDFObject::EDynamic,
|
|
373 |
MSmlDmDDFObject::EInt,
|
|
374 |
KNSmlEmpty );
|
|
375 |
|
|
376 |
//WLAN/AllowRadioMeasurements
|
|
377 |
MSmlDmDDFObject& allowRadioMeasurements = rootWLan.AddChildObjectL( KNSmlWLanAllowRadioMeasurements );
|
|
378 |
FillNodeInfoL( allowRadioMeasurements,
|
|
379 |
accessTypesGetAddReplace,
|
|
380 |
MSmlDmDDFObject::EZeroOrOne,
|
|
381 |
MSmlDmDDFObject::EDynamic,
|
|
382 |
MSmlDmDDFObject::EBool,
|
|
383 |
KNSmlEmpty );
|
|
384 |
|
|
385 |
//WLAN/MinPassiveChannelTime
|
|
386 |
MSmlDmDDFObject& minPassiveChannelTime = rootWLan.AddChildObjectL( KNSmlWLanMinPassiveChannelTime );
|
|
387 |
FillNodeInfoL( minPassiveChannelTime,
|
|
388 |
accessTypesGetAddReplace,
|
|
389 |
MSmlDmDDFObject::EZeroOrOne,
|
|
390 |
MSmlDmDDFObject::EDynamic,
|
|
391 |
MSmlDmDDFObject::EInt,
|
|
392 |
KNSmlEmpty );
|
|
393 |
|
|
394 |
//WLAN/MaxPassiveChannelTime
|
|
395 |
MSmlDmDDFObject& maxPassiveChannelTime = rootWLan.AddChildObjectL( KNSmlWLanMaxPassiveChannelTime );
|
|
396 |
FillNodeInfoL( maxPassiveChannelTime,
|
|
397 |
accessTypesGetAddReplace,
|
|
398 |
MSmlDmDDFObject::EZeroOrOne,
|
|
399 |
MSmlDmDDFObject::EDynamic,
|
|
400 |
MSmlDmDDFObject::EInt,
|
|
401 |
KNSmlEmpty );
|
|
402 |
|
|
403 |
//WLAN/MaxApFailureCount
|
|
404 |
MSmlDmDDFObject& maxApFailureCount = rootWLan.AddChildObjectL( KNSmlWLanMaxApFailureCount );
|
|
405 |
FillNodeInfoL( maxApFailureCount,
|
|
406 |
accessTypesGetAddReplace,
|
|
407 |
MSmlDmDDFObject::EZeroOrOne,
|
|
408 |
MSmlDmDDFObject::EDynamic,
|
|
409 |
MSmlDmDDFObject::EInt,
|
|
410 |
KNSmlEmpty );
|
|
411 |
|
|
412 |
//WLAN/LongBeaconFindCount
|
|
413 |
MSmlDmDDFObject& longBeaconFindCount = rootWLan.AddChildObjectL( KNSmlWLanLongBeaconFindCount );
|
|
414 |
FillNodeInfoL( longBeaconFindCount,
|
|
415 |
accessTypesGetAddReplace,
|
|
416 |
MSmlDmDDFObject::EZeroOrOne,
|
|
417 |
MSmlDmDDFObject::EDynamic,
|
|
418 |
MSmlDmDDFObject::EInt,
|
|
419 |
KNSmlEmpty );
|
|
420 |
|
|
421 |
//WLAN/QosNullFrameInterval
|
|
422 |
MSmlDmDDFObject& qosNullFrameInterval = rootWLan.AddChildObjectL( KNSmlWLanQosNullFrameInterval );
|
|
423 |
FillNodeInfoL( qosNullFrameInterval,
|
|
424 |
accessTypesGetAddReplace,
|
|
425 |
MSmlDmDDFObject::EZeroOrOne,
|
|
426 |
MSmlDmDDFObject::EDynamic,
|
|
427 |
MSmlDmDDFObject::EInt,
|
|
428 |
KNSmlEmpty );
|
|
429 |
|
|
430 |
//WLAN/QosNullFrameTimeout
|
|
431 |
MSmlDmDDFObject& qosNullFrameTimeout = rootWLan.AddChildObjectL( KNSmlWLanQosNullFrameTimeout );
|
|
432 |
FillNodeInfoL( qosNullFrameTimeout,
|
|
433 |
accessTypesGetAddReplace,
|
|
434 |
MSmlDmDDFObject::EZeroOrOne,
|
|
435 |
MSmlDmDDFObject::EDynamic,
|
|
436 |
MSmlDmDDFObject::EInt,
|
|
437 |
KNSmlEmpty );
|
|
438 |
|
|
439 |
//WLAN/MTU
|
|
440 |
MSmlDmDDFObject& MTU = rootWLan.AddChildObjectL( KNSmlWLanMTU );
|
|
441 |
FillNodeInfoL( MTU,
|
|
442 |
accessTypesGetAddReplace,
|
|
443 |
MSmlDmDDFObject::EZeroOrOne,
|
|
444 |
MSmlDmDDFObject::EDynamic,
|
|
445 |
MSmlDmDDFObject::EInt,
|
|
446 |
KNSmlEmpty );
|
|
447 |
|
|
448 |
|
|
449 |
_DBG_FILE("CGlobalWLANAdapter::DDFStructureL(): end");
|
|
450 |
}
|
|
451 |
|
|
452 |
|
|
453 |
|
|
454 |
//-----------------------------------------------------------------------------
|
|
455 |
// CGlobalWLANAdapter* CGlobalWLANAdapter::AddLeafObjectL( const TDesC& aURI,const
|
|
456 |
// TDesC& aParentLUID, const TDesC8& aObject, const TDesC& aType,
|
|
457 |
// const TInt aStatusRef )
|
|
458 |
//-----------------------------------------------------------------------------
|
|
459 |
void CGlobalWLANAdapter::AddLeafObjectL( const TDesC8& aURI,
|
|
460 |
const TDesC8& aParentLUID,
|
|
461 |
const TDesC8& aObject,
|
|
462 |
const TDesC8& /*aType*/,
|
|
463 |
const TInt aStatusRef )
|
|
464 |
{
|
|
465 |
DBG_ARGS8(_S8("CGlobalWLANAdapter::AddLeafObjectL - <%S> <%S>"), &aURI, &aParentLUID );
|
|
466 |
|
|
467 |
// Get the last uri segment and the number of uri items in the input
|
|
468 |
TInt uriSegs = NumOfUriSegs( aURI );
|
|
469 |
TInt err(KErrNone);
|
|
470 |
TPtrC8 lastUriSeg = GetLastUriSeg( aURI );
|
|
471 |
|
|
472 |
//**************************************************************************
|
|
473 |
// Check which leaf is in question
|
|
474 |
//**************************************************************************
|
|
475 |
if( aURI.Match( _L8("WLAN/*" ) ) != KErrNotFound && uriSegs==2 )
|
|
476 |
{
|
|
477 |
// *****************************************************************
|
|
478 |
if( lastUriSeg.Match( KNSmlWLanInternetConnectivityTest ) != KErrNotFound )
|
|
479 |
{
|
|
480 |
// check whether input is of legal size
|
|
481 |
if ( aObject.Size() <= KInputMaxLength )
|
|
482 |
{
|
|
483 |
//store the parameter
|
|
484 |
DBG_ARGS8(_S8("CGlobalWLANAdapter::AddLeafObjectL, add leaf - <%S>"), &aURI );
|
|
485 |
|
|
486 |
err = DesToInt( aObject );
|
|
487 |
if ( err >= 0 )
|
|
488 |
{
|
|
489 |
iWriteSettings->internetConnectivityTest = err;
|
|
490 |
iWriteSettings->internetConnectivityTestPresent = ETrue;
|
|
491 |
iWriteStatuses->internetConnectivityTestStatus = aStatusRef;
|
|
492 |
err = KErrNone;
|
|
493 |
}
|
|
494 |
}
|
|
495 |
else
|
|
496 |
{
|
|
497 |
err = KErrTooBig;
|
|
498 |
}
|
|
499 |
}
|
|
500 |
|
|
501 |
// *****************************************************************
|
|
502 |
else if( lastUriSeg.Match( KNSmlWLanUseDefaultSettings ) != KErrNotFound )
|
|
503 |
{
|
|
504 |
// check whether input is of legal size
|
|
505 |
if ( aObject.Size() <= KInputMaxLength )
|
|
506 |
{
|
|
507 |
//store the parameter
|
|
508 |
if( aObject.MatchF( _L8("True")) != KErrNotFound ||
|
|
509 |
aObject.MatchF( _L8("true")) != KErrNotFound )
|
|
510 |
{
|
|
511 |
DBG_ARGS8(_S8("CGlobalWLANAdapter::AddLeafObjectL, add leaf - <%S>"), &aURI );
|
|
512 |
iWriteSettings->useDefaultSettings = ETrue;
|
|
513 |
iWriteSettings->useDefaultSettingsPresent = ETrue;
|
|
514 |
iWriteStatuses->useDefaultSettingsStatus = aStatusRef;
|
|
515 |
}
|
|
516 |
else if ( aObject.MatchF( _L8("False")) != KErrNotFound ||
|
|
517 |
aObject.MatchF( _L8("false")) != KErrNotFound )
|
|
518 |
{
|
|
519 |
DBG_ARGS8(_S8("CGlobalWLANAdapter::AddLeafObjectL, add leaf - <%S>"), &aURI );
|
|
520 |
iWriteSettings->useDefaultSettings = EFalse;
|
|
521 |
iWriteSettings->useDefaultSettingsPresent = ETrue;
|
|
522 |
iWriteStatuses->useDefaultSettingsStatus = aStatusRef;
|
|
523 |
}
|
|
524 |
else
|
|
525 |
{
|
|
526 |
err = KErrArgument;
|
|
527 |
}
|
|
528 |
}
|
|
529 |
else
|
|
530 |
{
|
|
531 |
err = KErrTooBig;
|
|
532 |
}
|
|
533 |
}
|
|
534 |
// *****************************************************************
|
|
535 |
else if( lastUriSeg.Match( KNSmlWLanLongRetryLimit ) != KErrNotFound )
|
|
536 |
{
|
|
537 |
// check whether input is of legal size
|
|
538 |
if ( aObject.Size() <= KInputMaxLength )
|
|
539 |
{
|
|
540 |
//store the parameter
|
|
541 |
DBG_ARGS8(_S8("CGlobalWLANAdapter::AddLeafObjectL, add leaf - <%S>"), &aURI );
|
|
542 |
err = DesToInt( aObject );
|
|
543 |
if ( err >= 0 )
|
|
544 |
{
|
|
545 |
iWriteSettings->longRetryLimit = err;
|
|
546 |
iWriteSettings->longRetryLimitPresent = ETrue;
|
|
547 |
iWriteStatuses->longRetryLimitStatus = aStatusRef;
|
|
548 |
err = KErrNone;
|
|
549 |
}
|
|
550 |
}
|
|
551 |
else
|
|
552 |
{
|
|
553 |
err = KErrTooBig;
|
|
554 |
}
|
|
555 |
}
|
|
556 |
// *****************************************************************
|
|
557 |
else if( lastUriSeg.Match( KNSmlWLanShortRetryLimit ) != KErrNotFound )
|
|
558 |
{
|
|
559 |
// check whether input is of legal size
|
|
560 |
if ( aObject.Size() <= KInputMaxLength )
|
|
561 |
{
|
|
562 |
//store the parameter
|
|
563 |
DBG_ARGS8(_S8("CGlobalWLANAdapter::AddLeafObjectL, add leaf - <%S>"), &aURI );
|
|
564 |
err = DesToInt( aObject );
|
|
565 |
if ( err >= 0 )
|
|
566 |
{
|
|
567 |
iWriteSettings->shortRetryLimit = err;
|
|
568 |
iWriteSettings->shortRetryLimitPresent = ETrue;
|
|
569 |
iWriteStatuses->shortRetryLimitStatus = aStatusRef;
|
|
570 |
err = KErrNone;
|
|
571 |
}
|
|
572 |
}
|
|
573 |
else
|
|
574 |
{
|
|
575 |
err = KErrTooBig;
|
|
576 |
}
|
|
577 |
}
|
|
578 |
// *****************************************************************
|
|
579 |
else if( lastUriSeg.Match( KNSmlWLanRTSThreshold ) != KErrNotFound )
|
|
580 |
{
|
|
581 |
// check whether input is of legal size
|
|
582 |
if ( aObject.Size() <= KInputMaxLength )
|
|
583 |
{
|
|
584 |
DBG_ARGS8(_S8("CGlobalWLANAdapter::AddLeafObjectL, add leaf - <%S>"), &aURI );
|
|
585 |
err = DesToInt( aObject );
|
|
586 |
if ( err >= 0 )
|
|
587 |
{
|
|
588 |
iWriteSettings->RTSThreshold = err;
|
|
589 |
iWriteSettings->RTSThresholdPresent = ETrue;
|
|
590 |
iWriteStatuses->RTSThresholdStatus = aStatusRef;
|
|
591 |
err = KErrNone;
|
|
592 |
}
|
|
593 |
}
|
|
594 |
else
|
|
595 |
{
|
|
596 |
err = KErrTooBig;
|
|
597 |
}
|
|
598 |
}
|
|
599 |
// *****************************************************************
|
|
600 |
else if( lastUriSeg.Match( KNSmlWLanTXPowerLevel ) != KErrNotFound )
|
|
601 |
{
|
|
602 |
// check whether input is of legal size
|
|
603 |
if ( aObject.Size() <= KInputMaxLength )
|
|
604 |
{
|
|
605 |
DBG_ARGS8(_S8("CGlobalWLANAdapter::AddLeafObjectL, add leaf - <%S>"), &aURI );
|
|
606 |
//store the parameter
|
|
607 |
err = DesToInt( aObject );
|
|
608 |
if ( err >= 0)
|
|
609 |
{
|
|
610 |
iWriteSettings->TXPowerLevel = err;
|
|
611 |
iWriteSettings->TXPowerLevelPresent = ETrue;
|
|
612 |
iWriteStatuses->TXPowerLevelStatus = aStatusRef;
|
|
613 |
err = KErrNone;
|
|
614 |
}
|
|
615 |
}
|
|
616 |
else
|
|
617 |
{
|
|
618 |
err = KErrTooBig;
|
|
619 |
}
|
|
620 |
}
|
|
621 |
// *****************************************************************
|
|
622 |
else if( lastUriSeg.Match( KNSmlWLanPowerSaving ) != KErrNotFound )
|
|
623 |
{
|
|
624 |
// check whether input is of legal size
|
|
625 |
if ( aObject.Size() <= KInputMaxLength )
|
|
626 |
{
|
|
627 |
//store the parameter
|
|
628 |
if( aObject.MatchF( _L8("True")) != KErrNotFound ||
|
|
629 |
aObject.MatchF( _L8("true")) != KErrNotFound )
|
|
630 |
{
|
|
631 |
DBG_ARGS8(_S8("CGlobalWLANAdapter::AddLeafObjectL, add leaf - <%S>"), &aURI );
|
|
632 |
iWriteSettings->powerSaving = ETrue;
|
|
633 |
iWriteSettings->powerSavingPresent = ETrue;
|
|
634 |
iWriteStatuses->powerSavingStatus = aStatusRef;
|
|
635 |
}
|
|
636 |
else if ( aObject.MatchF( _L8("False")) != KErrNotFound ||
|
|
637 |
aObject.MatchF( _L8("false")) != KErrNotFound )
|
|
638 |
{
|
|
639 |
DBG_ARGS8(_S8("CGlobalWLANAdapter::AddLeafObjectL, add leaf - <%S>"), &aURI );
|
|
640 |
iWriteSettings->powerSaving = EFalse;
|
|
641 |
iWriteSettings->powerSavingPresent = ETrue;
|
|
642 |
iWriteStatuses->powerSavingStatus = aStatusRef;
|
|
643 |
}
|
|
644 |
else
|
|
645 |
{
|
|
646 |
err = KErrArgument;
|
|
647 |
}
|
|
648 |
}
|
|
649 |
else
|
|
650 |
{
|
|
651 |
err = KErrTooBig;
|
|
652 |
}
|
|
653 |
}
|
|
654 |
// *****************************************************************
|
|
655 |
else if( lastUriSeg.Match( KNSmlWLanBackgroundScanInterval ) != KErrNotFound )
|
|
656 |
{
|
|
657 |
// check whether input is of legal size
|
|
658 |
if ( aObject.Size() <= KInputMaxLength )
|
|
659 |
{
|
|
660 |
//store the parameter
|
|
661 |
DBG_ARGS8(_S8("CGlobalWLANAdapter::AddLeafObjectL, add leaf - <%S>"), &aURI );
|
|
662 |
err = DesToInt( aObject );
|
|
663 |
if ( err >= 0 )
|
|
664 |
{
|
|
665 |
iWriteSettings->backgroundScanInterval = err;
|
|
666 |
iWriteSettings->backgroundScanIntervalPresent = ETrue;
|
|
667 |
iWriteStatuses->backgroundScanIntervalStatus = aStatusRef;
|
|
668 |
err = KErrNone;
|
|
669 |
}
|
|
670 |
}
|
|
671 |
else
|
|
672 |
{
|
|
673 |
err = KErrTooBig;
|
|
674 |
}
|
|
675 |
}
|
|
676 |
// *****************************************************************
|
|
677 |
else if( lastUriSeg.Match( KNSmlWLanScanRate ) != KErrNotFound )
|
|
678 |
{
|
|
679 |
// check whether input is of legal size
|
|
680 |
if ( aObject.Size() <= KInputMaxLength )
|
|
681 |
{
|
|
682 |
//store the parameter
|
|
683 |
DBG_ARGS8(_S8("CGlobalWLANAdapter::AddLeafObjectL, add leaf - <%S>"), &aURI );
|
|
684 |
err = DesToInt( aObject );
|
|
685 |
if ( err >= 0 )
|
|
686 |
{
|
|
687 |
iWriteSettings->scanRate = err;
|
|
688 |
iWriteSettings->scanRatePresent = ETrue;
|
|
689 |
iWriteStatuses->scanRateStatus = aStatusRef;
|
|
690 |
err = KErrNone;
|
|
691 |
}
|
|
692 |
}
|
|
693 |
else
|
|
694 |
{
|
|
695 |
err = KErrTooBig;
|
|
696 |
}
|
|
697 |
}
|
|
698 |
// *****************************************************************
|
|
699 |
else if( lastUriSeg.Match( KNSmlWLanRCPITrigger ) != KErrNotFound )
|
|
700 |
{
|
|
701 |
// check whether input is of legal size
|
|
702 |
if ( aObject.Size() <= KInputMaxLength )
|
|
703 |
{
|
|
704 |
//store the parameter
|
|
705 |
DBG_ARGS8(_S8("CGlobalWLANAdapter::AddLeafObjectL, add leaf - <%S>"), &aURI );
|
|
706 |
err = DesToInt( aObject );
|
|
707 |
if ( err >= 0)
|
|
708 |
{
|
|
709 |
iWriteSettings->RCPITrigger = err;
|
|
710 |
iWriteSettings->RCPITriggerPresent = ETrue;
|
|
711 |
iWriteStatuses->RCPITriggerStatus = aStatusRef;
|
|
712 |
err = KErrNone;
|
|
713 |
}
|
|
714 |
}
|
|
715 |
else
|
|
716 |
{
|
|
717 |
err = KErrTooBig;
|
|
718 |
}
|
|
719 |
}
|
|
720 |
// *****************************************************************
|
|
721 |
else if( lastUriSeg.Match( KNSmlWLanMinActiveChannelTime ) != KErrNotFound )
|
|
722 |
{
|
|
723 |
// check whether input is of legal size
|
|
724 |
if ( aObject.Size() <= KInputMaxLength )
|
|
725 |
{
|
|
726 |
//store the parameter
|
|
727 |
DBG_ARGS8(_S8("CGlobalWLANAdapter::AddLeafObjectL, add leaf - <%S>"), &aURI );
|
|
728 |
err = DesToInt( aObject );
|
|
729 |
if ( err >= 0 )
|
|
730 |
{
|
|
731 |
iWriteSettings->minActiveChannelTime = err;
|
|
732 |
iWriteSettings->minActiveChannelTimePresent = ETrue;
|
|
733 |
iWriteStatuses->minActiveChannelTimeStatus = aStatusRef;
|
|
734 |
err = KErrNone;
|
|
735 |
}
|
|
736 |
}
|
|
737 |
else
|
|
738 |
{
|
|
739 |
err = KErrTooBig;
|
|
740 |
}
|
|
741 |
}
|
|
742 |
// *****************************************************************
|
|
743 |
else if( lastUriSeg.Match( KNSmlWLanMaxActiveChannelTime ) != KErrNotFound )
|
|
744 |
{
|
|
745 |
// check whether input is of legal size
|
|
746 |
if ( aObject.Size() <= KInputMaxLength )
|
|
747 |
{
|
|
748 |
//store the parameter
|
|
749 |
DBG_ARGS8(_S8("CGlobalWLANAdapter::AddLeafObjectL, add leaf - <%S>"), &aURI );
|
|
750 |
err = DesToInt( aObject );
|
|
751 |
if ( err >= 0)
|
|
752 |
{
|
|
753 |
iWriteSettings->maxActiveChannelTime = err;
|
|
754 |
iWriteSettings->maxActiveChannelTimePresent = ETrue;
|
|
755 |
iWriteStatuses->maxActiveChannelTimeStatus = aStatusRef;
|
|
756 |
err = KErrNone;
|
|
757 |
}
|
|
758 |
}
|
|
759 |
else
|
|
760 |
{
|
|
761 |
err = KErrTooBig;
|
|
762 |
}
|
|
763 |
}
|
|
764 |
// *****************************************************************
|
|
765 |
else if( lastUriSeg.Match( KNSmlWLanMaxTxMSDULifeTime ) != KErrNotFound )
|
|
766 |
{
|
|
767 |
// check whether input is of legal size
|
|
768 |
if ( aObject.Size() <= KInputMaxLength )
|
|
769 |
{
|
|
770 |
//store the parameter
|
|
771 |
DBG_ARGS8(_S8("CGlobalWLANAdapter::AddLeafObjectL, add leaf - <%S>"), &aURI );
|
|
772 |
err = DesToInt( aObject );
|
|
773 |
if ( err >= 0 )
|
|
774 |
{
|
|
775 |
iWriteSettings->maxTxMSDULifeTime = err;
|
|
776 |
iWriteSettings->maxTxMSDULifeTimePresent = ETrue;
|
|
777 |
iWriteStatuses->maxTxMSDULifeTimeStatus = aStatusRef;
|
|
778 |
err = KErrNone;
|
|
779 |
}
|
|
780 |
}
|
|
781 |
else
|
|
782 |
{
|
|
783 |
err = KErrTooBig;
|
|
784 |
}
|
|
785 |
}
|
|
786 |
// *****************************************************************
|
|
787 |
else if( lastUriSeg.Match( KNSmlWLanScanExpirationTimer ) != KErrNotFound )
|
|
788 |
{
|
|
789 |
// check whether input is of legal size
|
|
790 |
if ( aObject.Size() <= KInputMaxLength )
|
|
791 |
{
|
|
792 |
//store the parameter
|
|
793 |
DBG_ARGS8(_S8("CGlobalWLANAdapter::AddLeafObjectL, add leaf - <%S>"), &aURI );
|
|
794 |
err = DesToInt( aObject );
|
|
795 |
if ( err >= 0 )
|
|
796 |
{
|
|
797 |
iWriteSettings->scanExpirationTimer = err;
|
|
798 |
iWriteSettings->scanExpirationTimerPresent = ETrue;
|
|
799 |
iWriteStatuses->scanExpirationTimerStatus = aStatusRef;
|
|
800 |
err = KErrNone;
|
|
801 |
}
|
|
802 |
}
|
|
803 |
else
|
|
804 |
{
|
|
805 |
err = KErrTooBig;
|
|
806 |
}
|
|
807 |
}
|
|
808 |
// *****************************************************************
|
|
809 |
else if( lastUriSeg.Match( KNSmlWLanUnloadDriverTimer ) != KErrNotFound )
|
|
810 |
{
|
|
811 |
// check whether input is of legal size
|
|
812 |
if ( aObject.Size() <= KInputMaxLength )
|
|
813 |
{
|
|
814 |
//store the parameter
|
|
815 |
DBG_ARGS8(_S8("CGlobalWLANAdapter::AddLeafObjectL, add leaf - <%S>"), &aURI );
|
|
816 |
err = DesToInt( aObject );
|
|
817 |
if ( err >= 0 )
|
|
818 |
{
|
|
819 |
iWriteSettings->unloadDriverTimer = err;
|
|
820 |
iWriteSettings->unloadDriverTimerPresent = ETrue;
|
|
821 |
iWriteStatuses->unloadDriverTimerStatus = aStatusRef;
|
|
822 |
err = KErrNone;
|
|
823 |
}
|
|
824 |
}
|
|
825 |
else
|
|
826 |
{
|
|
827 |
err = KErrTooBig;
|
|
828 |
}
|
|
829 |
}
|
|
830 |
// *****************************************************************
|
|
831 |
else if( lastUriSeg.Match( KNSmlWLanRoamTimer ) != KErrNotFound )
|
|
832 |
{
|
|
833 |
// check whether input is of legal size
|
|
834 |
if ( aObject.Size() <= KInputMaxLength )
|
|
835 |
{
|
|
836 |
//store the parameter
|
|
837 |
DBG_ARGS8(_S8("CGlobalWLANAdapter::AddLeafObjectL, add leaf - <%S>"), &aURI );
|
|
838 |
err = DesToInt( aObject );
|
|
839 |
if ( err >= 0 )
|
|
840 |
{
|
|
841 |
iWriteSettings->roamTimer = err;
|
|
842 |
iWriteSettings->roamTimerPresent = ETrue;
|
|
843 |
iWriteStatuses->roamTimerStatus = aStatusRef;
|
|
844 |
err = KErrNone;
|
|
845 |
}
|
|
846 |
}
|
|
847 |
else
|
|
848 |
{
|
|
849 |
err = KErrTooBig;
|
|
850 |
}
|
|
851 |
}
|
|
852 |
// *****************************************************************
|
|
853 |
else if( lastUriSeg.Match( KNSmlWLanRCPIDifference ) != KErrNotFound )
|
|
854 |
{
|
|
855 |
// check whether input is of legal size
|
|
856 |
if ( aObject.Size() <= KInputMaxLength )
|
|
857 |
{
|
|
858 |
//store the parameter
|
|
859 |
DBG_ARGS8(_S8("CGlobalWLANAdapter::AddLeafObjectL, add leaf - <%S>"), &aURI );
|
|
860 |
err = DesToInt( aObject );
|
|
861 |
if ( err >= 0 )
|
|
862 |
{
|
|
863 |
iWriteSettings->RCPIDifference = err;
|
|
864 |
iWriteSettings->RCPIDifferencePresent = ETrue;
|
|
865 |
iWriteStatuses->RCPIDifferenceStatus = aStatusRef;
|
|
866 |
err = KErrNone;
|
|
867 |
}
|
|
868 |
}
|
|
869 |
else
|
|
870 |
{
|
|
871 |
err = KErrTooBig;
|
|
872 |
}
|
|
873 |
}
|
|
874 |
// *****************************************************************
|
|
875 |
else if( lastUriSeg.Match( KNSmlWLanConnRegainTimer ) != KErrNotFound )
|
|
876 |
{
|
|
877 |
// check whether input is of legal size
|
|
878 |
if ( aObject.Size() <= KInputMaxLength )
|
|
879 |
{
|
|
880 |
//store the parameter
|
|
881 |
DBG_ARGS8(_S8("CGlobalWLANAdapter::AddLeafObjectL, add leaf - <%S>"), &aURI );
|
|
882 |
err = DesToInt( aObject );
|
|
883 |
if ( err >= 0 )
|
|
884 |
{
|
|
885 |
iWriteSettings->connRegainTimer = err;
|
|
886 |
iWriteSettings->connRegainTimerPresent = ETrue;
|
|
887 |
iWriteStatuses->connRegainTimerStatus = aStatusRef;
|
|
888 |
err = KErrNone;
|
|
889 |
}
|
|
890 |
}
|
|
891 |
else
|
|
892 |
{
|
|
893 |
err = KErrTooBig;
|
|
894 |
}
|
|
895 |
}
|
|
896 |
// *****************************************************************
|
|
897 |
else if( lastUriSeg.Match( KNSmlWLanMaxTriesToFindNw ) != KErrNotFound )
|
|
898 |
{
|
|
899 |
// check whether input is of legal size
|
|
900 |
if ( aObject.Size() <= KInputMaxLength )
|
|
901 |
{
|
|
902 |
//store the parameter
|
|
903 |
DBG_ARGS8(_S8("CGlobalWLANAdapter::AddLeafObjectL, add leaf - <%S>"), &aURI );
|
|
904 |
err = DesToInt( aObject );
|
|
905 |
if ( err >= 0)
|
|
906 |
{
|
|
907 |
iWriteSettings->maxTriesToFindNw = err;
|
|
908 |
iWriteSettings->maxTriesToFindNwPresent = ETrue;
|
|
909 |
iWriteStatuses->maxTriesToFindNwStatus = aStatusRef;
|
|
910 |
err = KErrNone;
|
|
911 |
}
|
|
912 |
}
|
|
913 |
else
|
|
914 |
{
|
|
915 |
err = KErrTooBig;
|
|
916 |
}
|
|
917 |
}
|
|
918 |
// *****************************************************************
|
|
919 |
else if( lastUriSeg.Match( KNSmlWLanDelayBetweenFindNw ) != KErrNotFound )
|
|
920 |
{
|
|
921 |
// check whether input is of legal size
|
|
922 |
if ( aObject.Size() <= KInputMaxLength )
|
|
923 |
{
|
|
924 |
//store the parameter
|
|
925 |
DBG_ARGS8(_S8("CGlobalWLANAdapter::AddLeafObjectL, add leaf - <%S>"), &aURI );
|
|
926 |
err = DesToInt( aObject );
|
|
927 |
if ( err >= 0 )
|
|
928 |
{
|
|
929 |
iWriteSettings->delayBetweenFindNw = err;
|
|
930 |
iWriteSettings->delayBetweenFindNwPresent = ETrue;
|
|
931 |
iWriteStatuses->delayBetweenFindNwStatus = aStatusRef;
|
|
932 |
err = KErrNone;
|
|
933 |
}
|
|
934 |
}
|
|
935 |
else
|
|
936 |
{
|
|
937 |
err = KErrTooBig;
|
|
938 |
}
|
|
939 |
}
|
|
940 |
// *****************************************************************
|
|
941 |
else if( lastUriSeg.Match( KNSmlWLanAllowRadioMeasurements ) != KErrNotFound )
|
|
942 |
{
|
|
943 |
// check whether input is of legal size
|
|
944 |
if ( aObject.Size() <= KInputMaxLength )
|
|
945 |
{
|
|
946 |
if( aObject.MatchF( _L8("True")) != KErrNotFound ||
|
|
947 |
aObject.MatchF( _L8("true")) != KErrNotFound )
|
|
948 |
{
|
|
949 |
DBG_ARGS8(_S8("CGlobalWLANAdapter::AddLeafObjectL, add leaf - <%S>"), &aURI );
|
|
950 |
iWriteSettings->allowRadioMeasurements = ETrue;
|
|
951 |
iWriteSettings->allowRadioMeasurementsPresent = ETrue;
|
|
952 |
iWriteStatuses->allowRadioMeasurementsStatus = aStatusRef;
|
|
953 |
}
|
|
954 |
else if ( aObject.MatchF( _L8("False")) != KErrNotFound ||
|
|
955 |
aObject.MatchF( _L8("false")) != KErrNotFound )
|
|
956 |
{
|
|
957 |
DBG_ARGS8(_S8("CGlobalWLANAdapter::AddLeafObjectL, add leaf - <%S>"), &aURI );
|
|
958 |
iWriteSettings->allowRadioMeasurements = EFalse;
|
|
959 |
iWriteSettings->allowRadioMeasurementsPresent = ETrue;
|
|
960 |
iWriteStatuses->allowRadioMeasurementsStatus = aStatusRef;
|
|
961 |
}
|
|
962 |
else
|
|
963 |
{
|
|
964 |
err = KErrArgument;
|
|
965 |
}
|
|
966 |
}
|
|
967 |
else
|
|
968 |
{
|
|
969 |
err = KErrTooBig;
|
|
970 |
}
|
|
971 |
}
|
|
972 |
// *****************************************************************
|
|
973 |
else if( lastUriSeg.Match( KNSmlWLanMinPassiveChannelTime ) != KErrNotFound )
|
|
974 |
{
|
|
975 |
// check whether input is of legal size
|
|
976 |
if ( aObject.Size() <= KInputMaxLength )
|
|
977 |
{
|
|
978 |
//store the parameter
|
|
979 |
DBG_ARGS8(_S8("CGlobalWLANAdapter::AddLeafObjectL, add leaf - <%S>"), &aURI );
|
|
980 |
err = DesToInt( aObject );
|
|
981 |
if ( err >= 0 )
|
|
982 |
{
|
|
983 |
iWriteSettings->minPassiveChannelTime = err;
|
|
984 |
iWriteSettings->minPassiveChannelTimePresent = ETrue;
|
|
985 |
iWriteStatuses->minPassiveChannelTimeStatus = aStatusRef;
|
|
986 |
err = KErrNone;
|
|
987 |
}
|
|
988 |
}
|
|
989 |
else
|
|
990 |
{
|
|
991 |
err = KErrTooBig;
|
|
992 |
}
|
|
993 |
}
|
|
994 |
// *****************************************************************
|
|
995 |
else if( lastUriSeg.Match( KNSmlWLanMaxPassiveChannelTime ) != KErrNotFound )
|
|
996 |
{
|
|
997 |
// check whether input is of legal size
|
|
998 |
if ( aObject.Size() <= KInputMaxLength )
|
|
999 |
{
|
|
1000 |
//store the parameter
|
|
1001 |
DBG_ARGS8(_S8("CGlobalWLANAdapter::AddLeafObjectL, add leaf - <%S>"), &aURI );
|
|
1002 |
err = DesToInt( aObject );
|
|
1003 |
if ( err >= 0 )
|
|
1004 |
{
|
|
1005 |
iWriteSettings->maxPassiveChannelTime = err;
|
|
1006 |
iWriteSettings->maxPassiveChannelTimePresent = ETrue;
|
|
1007 |
iWriteStatuses->maxPassiveChannelTimeStatus = aStatusRef;
|
|
1008 |
err = KErrNone;
|
|
1009 |
}
|
|
1010 |
}
|
|
1011 |
else
|
|
1012 |
{
|
|
1013 |
err = KErrTooBig;
|
|
1014 |
}
|
|
1015 |
}
|
|
1016 |
// *****************************************************************
|
|
1017 |
else if( lastUriSeg.Match( KNSmlWLanMaxApFailureCount ) != KErrNotFound )
|
|
1018 |
{
|
|
1019 |
// check whether input is of legal size
|
|
1020 |
if ( aObject.Size() <= KInputMaxLength )
|
|
1021 |
{
|
|
1022 |
//store the parameter
|
|
1023 |
DBG_ARGS8(_S8("CGlobalWLANAdapter::AddLeafObjectL, add leaf - <%S>"), &aURI );
|
|
1024 |
err = DesToInt( aObject );
|
|
1025 |
if ( err >= 0 )
|
|
1026 |
{
|
|
1027 |
iWriteSettings->maxApFailureCount = err;
|
|
1028 |
iWriteSettings->maxApFailureCountPresent = ETrue;
|
|
1029 |
iWriteStatuses->maxApFailureCountStatus = aStatusRef;
|
|
1030 |
err = KErrNone;
|
|
1031 |
}
|
|
1032 |
}
|
|
1033 |
else
|
|
1034 |
{
|
|
1035 |
err = KErrTooBig;
|
|
1036 |
}
|
|
1037 |
}
|
|
1038 |
// *****************************************************************
|
|
1039 |
else if( lastUriSeg.Match( KNSmlWLanLongBeaconFindCount ) != KErrNotFound )
|
|
1040 |
{
|
|
1041 |
// check whether input is of legal size
|
|
1042 |
if ( aObject.Size() <= KInputMaxLength )
|
|
1043 |
{
|
|
1044 |
//store the parameter
|
|
1045 |
DBG_ARGS8(_S8("CGlobalWLANAdapter::AddLeafObjectL, add leaf - <%S>"), &aURI );
|
|
1046 |
err = DesToInt( aObject );
|
|
1047 |
if ( err >= 0 )
|
|
1048 |
{
|
|
1049 |
iWriteSettings->longBeaconFindCount = err;
|
|
1050 |
iWriteSettings->longBeaconFindCountPresent = ETrue;
|
|
1051 |
iWriteStatuses->longBeaconFindCountStatus = aStatusRef;
|
|
1052 |
err = KErrNone;
|
|
1053 |
}
|
|
1054 |
}
|
|
1055 |
else
|
|
1056 |
{
|
|
1057 |
err = KErrTooBig;
|
|
1058 |
}
|
|
1059 |
}
|
|
1060 |
// *****************************************************************
|
|
1061 |
else if( lastUriSeg.Match( KNSmlWLanQosNullFrameInterval ) != KErrNotFound )
|
|
1062 |
{
|
|
1063 |
// check whether input is of legal size
|
|
1064 |
if ( aObject.Size() <= KInputMaxLength )
|
|
1065 |
{
|
|
1066 |
//store the parameter
|
|
1067 |
DBG_ARGS8(_S8("CGlobalWLANAdapter::AddLeafObjectL, add leaf - <%S>"), &aURI );
|
|
1068 |
err = DesToInt( aObject );
|
|
1069 |
if ( err >= 0 )
|
|
1070 |
{
|
|
1071 |
iWriteSettings->qosNullFrameInterval = err;
|
|
1072 |
iWriteSettings->qosNullFrameIntervalPresent = ETrue;
|
|
1073 |
iWriteStatuses->qosNullFrameIntervalStatus = aStatusRef;
|
|
1074 |
err = KErrNone;
|
|
1075 |
}
|
|
1076 |
}
|
|
1077 |
else
|
|
1078 |
{
|
|
1079 |
err = KErrTooBig;
|
|
1080 |
}
|
|
1081 |
}
|
|
1082 |
// *****************************************************************
|
|
1083 |
else if( lastUriSeg.Match( KNSmlWLanQosNullFrameTimeout ) != KErrNotFound )
|
|
1084 |
{
|
|
1085 |
// check whether input is of legal size
|
|
1086 |
if ( aObject.Size() <= KInputMaxLength )
|
|
1087 |
{
|
|
1088 |
//store the parameter
|
|
1089 |
DBG_ARGS8(_S8("CGlobalWLANAdapter::AddLeafObjectL, add leaf - <%S>"), &aURI );
|
|
1090 |
err = DesToInt( aObject );
|
|
1091 |
if ( err >= 0 )
|
|
1092 |
{
|
|
1093 |
iWriteSettings->qosNullFrameTimeout = err;
|
|
1094 |
iWriteSettings->qosNullFrameTimeoutPresent = ETrue;
|
|
1095 |
iWriteStatuses->qosNullFrameTimeoutStatus = aStatusRef;
|
|
1096 |
err = KErrNone;
|
|
1097 |
}
|
|
1098 |
}
|
|
1099 |
else
|
|
1100 |
{
|
|
1101 |
err = KErrTooBig;
|
|
1102 |
}
|
|
1103 |
}
|
|
1104 |
// *****************************************************************
|
|
1105 |
else if( lastUriSeg.Match( KNSmlWLanMTU ) != KErrNotFound )
|
|
1106 |
{
|
|
1107 |
// check whether input is of legal size
|
|
1108 |
if ( aObject.Size() <= KInputMaxLength )
|
|
1109 |
{
|
|
1110 |
//store the parameter
|
|
1111 |
DBG_ARGS8(_S8("CGlobalWLANAdapter::AddLeafObjectL, add leaf - <%S>"), &aURI );
|
|
1112 |
err = DesToInt( aObject );
|
|
1113 |
if ( err >= 0 )
|
|
1114 |
{
|
|
1115 |
iWriteSettings->MTU = err;
|
|
1116 |
iWriteSettings->MTUPresent = ETrue;
|
|
1117 |
iWriteStatuses->MTUStatus = aStatusRef;
|
|
1118 |
err = KErrNone;
|
|
1119 |
}
|
|
1120 |
}
|
|
1121 |
else
|
|
1122 |
{
|
|
1123 |
err = KErrTooBig;
|
|
1124 |
}
|
|
1125 |
}
|
|
1126 |
// *****************************************************************
|
|
1127 |
// The given leaf was not found
|
|
1128 |
else
|
|
1129 |
{
|
|
1130 |
err = KErrNotFound;
|
|
1131 |
}
|
|
1132 |
}
|
|
1133 |
else
|
|
1134 |
{
|
|
1135 |
// Something went wrong
|
|
1136 |
_DBG_FILE("CGlobalWLANAdapter::AddLeafObjectL(): Leaf addition failed");
|
|
1137 |
err = KErrGeneral;
|
|
1138 |
}
|
|
1139 |
|
|
1140 |
// Update the possible failure to the status, success is updated when the
|
|
1141 |
// actual writing to db is done
|
|
1142 |
switch ( err )
|
|
1143 |
{
|
|
1144 |
case KErrTooBig:
|
|
1145 |
iCallBack->SetStatusL( aStatusRef, CSmlDmAdapter::ETooLargeObject );
|
|
1146 |
break;
|
|
1147 |
|
|
1148 |
case KErrNotFound:
|
|
1149 |
iCallBack->SetStatusL( aStatusRef, CSmlDmAdapter::EInvalidObject );
|
|
1150 |
break;
|
|
1151 |
|
|
1152 |
case KErrGeneral:
|
|
1153 |
iCallBack->SetStatusL( aStatusRef, CSmlDmAdapter::EError );
|
|
1154 |
break;
|
|
1155 |
|
|
1156 |
case KErrArgument:
|
|
1157 |
iCallBack->SetStatusL( aStatusRef, CSmlDmAdapter::EInvalidObject );
|
|
1158 |
break;
|
|
1159 |
|
|
1160 |
case KErrOverflow:
|
|
1161 |
iCallBack->SetStatusL( aStatusRef, CSmlDmAdapter::EInvalidObject );
|
|
1162 |
break;
|
|
1163 |
}
|
|
1164 |
|
|
1165 |
_DBG_FILE("CGlobalWLANAdapter::AddLeafObjectL(): end");
|
|
1166 |
}
|
|
1167 |
|
|
1168 |
//-----------------------------------------------------------------------------
|
|
1169 |
// CGlobalWLANAdapter* CGlobalWLANAdapter::UpdateLeafObjectL( const TDesC& aURI,
|
|
1170 |
// const TDesC& aLUID, const TDesC8& aObject, const TDesC& aType,
|
|
1171 |
// const TInt aStatusRef )
|
|
1172 |
//-----------------------------------------------------------------------------
|
|
1173 |
void CGlobalWLANAdapter::UpdateLeafObjectL( const TDesC8& aURI,
|
|
1174 |
const TDesC8& aLUID,
|
|
1175 |
const TDesC8& aObject,
|
|
1176 |
const TDesC8& aType,
|
|
1177 |
const TInt aStatusRef )
|
|
1178 |
{
|
|
1179 |
_DBG_FILE("CGlobalWLANAdapter::UpdateLeafObjectL(): begin");
|
|
1180 |
DBG_ARGS8(_S8("CGlobalWLANAdapter::UpdateLeafObjectL - <%S> <%S>"), &aURI, &aLUID );
|
|
1181 |
|
|
1182 |
AddLeafObjectL( aURI, aLUID, aObject, aType, aStatusRef );
|
|
1183 |
|
|
1184 |
_DBG_FILE("CGlobalWLANAdapter::UpdateLeafObjectL(): end");
|
|
1185 |
}
|
|
1186 |
|
|
1187 |
//------------------------------------------------------------------------------
|
|
1188 |
// CGlobalWLANAdapter::UpdateLeafObjectL( const TDesC8& aURI,
|
|
1189 |
// const TDesC8& aLUID, const TDesC8& aObject, const TDesC8& aType )
|
|
1190 |
// Not supported
|
|
1191 |
//------------------------------------------------------------------------------
|
|
1192 |
|
|
1193 |
void CGlobalWLANAdapter::UpdateLeafObjectL( const TDesC8& /*aURI*/,
|
|
1194 |
const TDesC8& /*aLUID*/,
|
|
1195 |
RWriteStream*& /*aStream*/,
|
|
1196 |
const TDesC8& /*aType*/,
|
|
1197 |
TInt aStatusRef )
|
|
1198 |
{
|
|
1199 |
_DBG_FILE("CGlobalWLANAdapter::UpdateLeafObjectL(): streaming: begin");
|
|
1200 |
|
|
1201 |
iCallBack->SetStatusL(aStatusRef, CSmlDmAdapter::EError);
|
|
1202 |
|
|
1203 |
_DBG_FILE("CGlobalWLANAdapter::UpdateLeafObjectL() streaming: end");
|
|
1204 |
}
|
|
1205 |
|
|
1206 |
//-----------------------------------------------------------------------------
|
|
1207 |
// CGlobalWLANAdapter* CGlobalWLANAdapter::DeleteObjectL( const TDesC8& aURI,
|
|
1208 |
// const TDesC8& aLUID, const TInt aStatusRef )
|
|
1209 |
// Not supported
|
|
1210 |
//-----------------------------------------------------------------------------
|
|
1211 |
void CGlobalWLANAdapter::DeleteObjectL( const TDesC8& /*aURI*/,
|
|
1212 |
const TDesC8& /*aLUID*/,
|
|
1213 |
const TInt aStatusRef )
|
|
1214 |
{
|
|
1215 |
_DBG_FILE("CGlobalWLANAdapter::DeleteObjectL(): begin");
|
|
1216 |
|
|
1217 |
iCallBack->SetStatusL(aStatusRef, CSmlDmAdapter::EError);
|
|
1218 |
|
|
1219 |
_DBG_FILE("CGlobalWLANAdapter::DeleteObjectL(): end");
|
|
1220 |
}
|
|
1221 |
|
|
1222 |
//-----------------------------------------------------------------------------
|
|
1223 |
// CGlobalWLANAdapter* CGlobalWLANAdapter::FetchLeafObjectSizeL( const TDesC8& aURI,
|
|
1224 |
// const TDesC8& aLUID, const TDesC8& aType,
|
|
1225 |
// const TInt aResultsRef, const TInt aStatusRef )
|
|
1226 |
// not supported
|
|
1227 |
//-----------------------------------------------------------------------------
|
|
1228 |
|
|
1229 |
void CGlobalWLANAdapter::FetchLeafObjectSizeL( const TDesC8& /*aURI*/,
|
|
1230 |
const TDesC8& /*aLUID*/,
|
|
1231 |
const TDesC8& /*aType*/,
|
|
1232 |
TInt /*aResultsRef*/,
|
|
1233 |
TInt /*aStatusRef*/ )
|
|
1234 |
{
|
|
1235 |
_DBG_FILE("CGlobalWLANAdapter::FetchLeafObjectSizeL(): begin");
|
|
1236 |
_DBG_FILE("CGlobalWLANAdapter::FetchLeafObjectSizeL(): end");
|
|
1237 |
return;
|
|
1238 |
}
|
|
1239 |
|
|
1240 |
|
|
1241 |
//-----------------------------------------------------------------------------
|
|
1242 |
// CGlobalWLANAdapter* CGlobalWLANAdapter::FetchLeafObjectL( const TDesC8& aURI,
|
|
1243 |
// const TDesC8& aLUID, const TDesC8& aType,
|
|
1244 |
// const TInt aResultsRef, const TInt aStatusRef )
|
|
1245 |
//
|
|
1246 |
//-----------------------------------------------------------------------------
|
|
1247 |
void CGlobalWLANAdapter::FetchLeafObjectL( const TDesC8& aURI,
|
|
1248 |
const TDesC8& aLUID,
|
|
1249 |
const TDesC8& /*aType*/,
|
|
1250 |
const TInt aResultsRef,
|
|
1251 |
const TInt aStatusRef )
|
|
1252 |
{
|
|
1253 |
_DBG_FILE("CGlobalWLANAdapter::FetchLeafObjectL(): begin");
|
|
1254 |
DBG_ARGS8(_S8("Fetch aURI - %S - %S"), &aURI, &aLUID);
|
|
1255 |
|
|
1256 |
// Store the required parameters into the struct. Actual reading will be done in
|
|
1257 |
// when CompleteOutstandingCommands is called
|
|
1258 |
|
|
1259 |
// Get the last uri segment
|
|
1260 |
TPtrC8 lastUriSeg = GetLastUriSeg( aURI );
|
|
1261 |
DBG_ARGS8(_S8("Fetch leaf, lasturiseg - %S"), &lastUriSeg);
|
|
1262 |
|
|
1263 |
//**************************************************************************
|
|
1264 |
// Check which leaf is in question
|
|
1265 |
//**************************************************************************
|
|
1266 |
if( aURI.Match( _L8("WLAN/*" ) ) != KErrNotFound )
|
|
1267 |
{
|
|
1268 |
_DBG_FILE("CGlobalWLANAdapter::FetchLeafObjectL(): WLAN/* found in uri");
|
|
1269 |
// *****************************************************************
|
|
1270 |
if( lastUriSeg.Match( KNSmlWLanInternetConnectivityTest ) != KErrNotFound )
|
|
1271 |
{
|
|
1272 |
_DBG_FILE("CGlobalWLANAdapter::FetchLeafObjectL(): leaf");
|
|
1273 |
iReadSettings->internetConnectivityTestPresent = ETrue;
|
|
1274 |
iReadStatuses->internetConnectivityTestResult = aResultsRef;
|
|
1275 |
iReadStatuses->internetConnectivityTestStatus = aStatusRef;
|
|
1276 |
}
|
|
1277 |
|
|
1278 |
// *****************************************************************
|
|
1279 |
else if( lastUriSeg.Match( KNSmlWLanUseDefaultSettings ) != KErrNotFound )
|
|
1280 |
{
|
|
1281 |
_DBG_FILE("CGlobalWLANAdapter::FetchLeafObjectL(): leaf");
|
|
1282 |
iReadSettings->useDefaultSettingsPresent = ETrue;
|
|
1283 |
iReadStatuses->useDefaultSettingsResult = aResultsRef;
|
|
1284 |
iReadStatuses->useDefaultSettingsStatus = aStatusRef;
|
|
1285 |
}
|
|
1286 |
|
|
1287 |
// *****************************************************************
|
|
1288 |
else if( lastUriSeg.Match( KNSmlWLanLongRetryLimit ) != KErrNotFound )
|
|
1289 |
{
|
|
1290 |
_DBG_FILE("CGlobalWLANAdapter::FetchLeafObjectL(): leaf");
|
|
1291 |
iReadSettings->longRetryLimitPresent = ETrue;
|
|
1292 |
iReadStatuses->longRetryLimitResult = aResultsRef;
|
|
1293 |
iReadStatuses->longRetryLimitStatus = aStatusRef;
|
|
1294 |
}
|
|
1295 |
|
|
1296 |
// *****************************************************************
|
|
1297 |
else if( lastUriSeg.Match( KNSmlWLanShortRetryLimit ) != KErrNotFound )
|
|
1298 |
{
|
|
1299 |
_DBG_FILE("CGlobalWLANAdapter::FetchLeafObjectL(): leaf");
|
|
1300 |
iReadSettings->shortRetryLimitPresent = ETrue;
|
|
1301 |
iReadStatuses->shortRetryLimitResult = aResultsRef;
|
|
1302 |
iReadStatuses->shortRetryLimitStatus = aStatusRef;
|
|
1303 |
}
|
|
1304 |
|
|
1305 |
// *****************************************************************
|
|
1306 |
else if( lastUriSeg.Match( KNSmlWLanRTSThreshold ) != KErrNotFound )
|
|
1307 |
{
|
|
1308 |
_DBG_FILE("CGlobalWLANAdapter::FetchLeafObjectL(): leaf");
|
|
1309 |
iReadSettings->RTSThresholdPresent = ETrue;
|
|
1310 |
iReadStatuses->RTSThresholdResult = aResultsRef;
|
|
1311 |
iReadStatuses->RTSThresholdStatus = aStatusRef;
|
|
1312 |
}
|
|
1313 |
|
|
1314 |
// *****************************************************************
|
|
1315 |
else if( lastUriSeg.Match( KNSmlWLanTXPowerLevel ) != KErrNotFound )
|
|
1316 |
{
|
|
1317 |
_DBG_FILE("CGlobalWLANAdapter::FetchLeafObjectL(): leaf");
|
|
1318 |
iReadSettings->TXPowerLevelPresent = ETrue;
|
|
1319 |
iReadStatuses->TXPowerLevelResult = aResultsRef;
|
|
1320 |
iReadStatuses->TXPowerLevelStatus = aStatusRef;
|
|
1321 |
}
|
|
1322 |
|
|
1323 |
// *****************************************************************
|
|
1324 |
else if( lastUriSeg.Match( KNSmlWLanPowerSaving ) != KErrNotFound )
|
|
1325 |
{
|
|
1326 |
_DBG_FILE("CGlobalWLANAdapter::FetchLeafObjectL(): leaf");
|
|
1327 |
iReadSettings->powerSavingPresent = ETrue;
|
|
1328 |
iReadStatuses->powerSavingResult = aResultsRef;
|
|
1329 |
iReadStatuses->powerSavingStatus = aStatusRef;
|
|
1330 |
}
|
|
1331 |
|
|
1332 |
// *****************************************************************
|
|
1333 |
else if( lastUriSeg.Match( KNSmlWLanBackgroundScanInterval ) != KErrNotFound )
|
|
1334 |
{
|
|
1335 |
_DBG_FILE("CGlobalWLANAdapter::FetchLeafObjectL(): leaf");
|
|
1336 |
iReadSettings->backgroundScanIntervalPresent = ETrue;
|
|
1337 |
iReadStatuses->backgroundScanIntervalResult = aResultsRef;
|
|
1338 |
iReadStatuses->backgroundScanIntervalStatus = aStatusRef;
|
|
1339 |
}
|
|
1340 |
|
|
1341 |
// *****************************************************************
|
|
1342 |
else if( lastUriSeg.Match( KNSmlWLanScanRate ) != KErrNotFound )
|
|
1343 |
{
|
|
1344 |
_DBG_FILE("CGlobalWLANAdapter::FetchLeafObjectL(): leaf");
|
|
1345 |
iReadSettings->scanRatePresent = ETrue;
|
|
1346 |
iReadStatuses->scanRateResult = aResultsRef;
|
|
1347 |
iReadStatuses->scanRateStatus = aStatusRef;
|
|
1348 |
}
|
|
1349 |
|
|
1350 |
// *****************************************************************
|
|
1351 |
else if( lastUriSeg.Match( KNSmlWLanRCPITrigger ) != KErrNotFound )
|
|
1352 |
{
|
|
1353 |
_DBG_FILE("CGlobalWLANAdapter::FetchLeafObjectL(): leaf");
|
|
1354 |
iReadSettings->RCPITriggerPresent = ETrue;
|
|
1355 |
iReadStatuses->RCPITriggerResult = aResultsRef;
|
|
1356 |
iReadStatuses->RCPITriggerStatus = aStatusRef;
|
|
1357 |
}
|
|
1358 |
|
|
1359 |
// *****************************************************************
|
|
1360 |
else if( lastUriSeg.Match( KNSmlWLanMinActiveChannelTime ) != KErrNotFound )
|
|
1361 |
{
|
|
1362 |
_DBG_FILE("CGlobalWLANAdapter::FetchLeafObjectL(): leaf");
|
|
1363 |
iReadSettings->minActiveChannelTimePresent = ETrue;
|
|
1364 |
iReadStatuses->minActiveChannelTimeResult = aResultsRef;
|
|
1365 |
iReadStatuses->minActiveChannelTimeStatus = aStatusRef;
|
|
1366 |
}
|
|
1367 |
|
|
1368 |
// *****************************************************************
|
|
1369 |
else if( lastUriSeg.Match( KNSmlWLanMaxActiveChannelTime ) != KErrNotFound )
|
|
1370 |
{
|
|
1371 |
_DBG_FILE("CGlobalWLANAdapter::FetchLeafObjectL(): leaf");
|
|
1372 |
iReadSettings->maxActiveChannelTimePresent = ETrue;
|
|
1373 |
iReadStatuses->maxActiveChannelTimeResult = aResultsRef;
|
|
1374 |
iReadStatuses->maxActiveChannelTimeStatus = aStatusRef;
|
|
1375 |
}
|
|
1376 |
|
|
1377 |
// *****************************************************************
|
|
1378 |
else if( lastUriSeg.Match( KNSmlWLanMaxTxMSDULifeTime ) != KErrNotFound )
|
|
1379 |
{
|
|
1380 |
_DBG_FILE("CGlobalWLANAdapter::FetchLeafObjectL(): leaf");
|
|
1381 |
iReadSettings->maxTxMSDULifeTimePresent = ETrue;
|
|
1382 |
iReadStatuses->maxTxMSDULifeTimeResult = aResultsRef;
|
|
1383 |
iReadStatuses->maxTxMSDULifeTimeStatus = aStatusRef;
|
|
1384 |
}
|
|
1385 |
|
|
1386 |
// *****************************************************************
|
|
1387 |
else if( lastUriSeg.Match( KNSmlWLanScanExpirationTimer ) != KErrNotFound )
|
|
1388 |
{
|
|
1389 |
_DBG_FILE("CGlobalWLANAdapter::FetchLeafObjectL(): leaf");
|
|
1390 |
iReadSettings->scanExpirationTimerPresent = ETrue;
|
|
1391 |
iReadStatuses->scanExpirationTimerResult = aResultsRef;
|
|
1392 |
iReadStatuses->scanExpirationTimerStatus = aStatusRef;
|
|
1393 |
}
|
|
1394 |
|
|
1395 |
// *****************************************************************
|
|
1396 |
else if( lastUriSeg.Match( KNSmlWLanUnloadDriverTimer ) != KErrNotFound )
|
|
1397 |
{
|
|
1398 |
_DBG_FILE("CGlobalWLANAdapter::FetchLeafObjectL(): leaf");
|
|
1399 |
iReadSettings->unloadDriverTimerPresent = ETrue;
|
|
1400 |
iReadStatuses->unloadDriverTimerResult = aResultsRef;
|
|
1401 |
iReadStatuses->unloadDriverTimerStatus = aStatusRef;
|
|
1402 |
}
|
|
1403 |
|
|
1404 |
// *****************************************************************
|
|
1405 |
else if( lastUriSeg.Match( KNSmlWLanRoamTimer ) != KErrNotFound )
|
|
1406 |
{
|
|
1407 |
_DBG_FILE("CGlobalWLANAdapter::FetchLeafObjectL(): leaf");
|
|
1408 |
iReadSettings->roamTimerPresent = ETrue;
|
|
1409 |
iReadStatuses->roamTimerResult = aResultsRef;
|
|
1410 |
iReadStatuses->roamTimerStatus = aStatusRef;
|
|
1411 |
}
|
|
1412 |
|
|
1413 |
// *****************************************************************
|
|
1414 |
else if( lastUriSeg.Match( KNSmlWLanRCPIDifference ) != KErrNotFound )
|
|
1415 |
{
|
|
1416 |
_DBG_FILE("CGlobalWLANAdapter::FetchLeafObjectL(): leaf");
|
|
1417 |
iReadSettings->RCPIDifferencePresent = ETrue;
|
|
1418 |
iReadStatuses->RCPIDifferenceResult = aResultsRef;
|
|
1419 |
iReadStatuses->RCPIDifferenceStatus = aStatusRef;
|
|
1420 |
}
|
|
1421 |
|
|
1422 |
// *****************************************************************
|
|
1423 |
else if( lastUriSeg.Match( KNSmlWLanConnRegainTimer ) != KErrNotFound )
|
|
1424 |
{
|
|
1425 |
_DBG_FILE("CGlobalWLANAdapter::FetchLeafObjectL(): leaf");
|
|
1426 |
iReadSettings->connRegainTimerPresent = ETrue;
|
|
1427 |
iReadStatuses->connRegainTimerResult = aResultsRef;
|
|
1428 |
iReadStatuses->connRegainTimerStatus = aStatusRef;
|
|
1429 |
}
|
|
1430 |
|
|
1431 |
// *****************************************************************
|
|
1432 |
else if( lastUriSeg.Match( KNSmlWLanMaxTriesToFindNw ) != KErrNotFound )
|
|
1433 |
{
|
|
1434 |
_DBG_FILE("CGlobalWLANAdapter::FetchLeafObjectL(): leaf");
|
|
1435 |
iReadSettings->maxTriesToFindNwPresent = ETrue;
|
|
1436 |
iReadStatuses->maxTriesToFindNwResult = aResultsRef;
|
|
1437 |
iReadStatuses->maxTriesToFindNwStatus = aStatusRef;
|
|
1438 |
}
|
|
1439 |
|
|
1440 |
// *****************************************************************
|
|
1441 |
else if( lastUriSeg.Match( KNSmlWLanDelayBetweenFindNw ) != KErrNotFound )
|
|
1442 |
{
|
|
1443 |
_DBG_FILE("CGlobalWLANAdapter::FetchLeafObjectL(): leaf");
|
|
1444 |
iReadSettings->delayBetweenFindNwPresent = ETrue;
|
|
1445 |
iReadStatuses->delayBetweenFindNwResult = aResultsRef;
|
|
1446 |
iReadStatuses->delayBetweenFindNwStatus = aStatusRef;
|
|
1447 |
}
|
|
1448 |
|
|
1449 |
// *****************************************************************
|
|
1450 |
else if( lastUriSeg.Match( KNSmlWLanAllowRadioMeasurements ) != KErrNotFound )
|
|
1451 |
{
|
|
1452 |
_DBG_FILE("CGlobalWLANAdapter::FetchLeafObjectL(): leaf");
|
|
1453 |
iReadSettings->allowRadioMeasurementsPresent = ETrue;
|
|
1454 |
iReadStatuses->allowRadioMeasurementsResult = aResultsRef;
|
|
1455 |
iReadStatuses->allowRadioMeasurementsStatus = aStatusRef;
|
|
1456 |
}
|
|
1457 |
|
|
1458 |
// *****************************************************************
|
|
1459 |
else if( lastUriSeg.Match( KNSmlWLanMinPassiveChannelTime ) != KErrNotFound )
|
|
1460 |
{
|
|
1461 |
_DBG_FILE("CGlobalWLANAdapter::FetchLeafObjectL(): leaf");
|
|
1462 |
iReadSettings->minPassiveChannelTimePresent = ETrue;
|
|
1463 |
iReadStatuses->minPassiveChannelTimeResult = aResultsRef;
|
|
1464 |
iReadStatuses->minPassiveChannelTimeStatus = aStatusRef;
|
|
1465 |
}
|
|
1466 |
|
|
1467 |
// *****************************************************************
|
|
1468 |
else if( lastUriSeg.Match( KNSmlWLanMaxPassiveChannelTime ) != KErrNotFound )
|
|
1469 |
{
|
|
1470 |
_DBG_FILE("CGlobalWLANAdapter::FetchLeafObjectL(): leaf");
|
|
1471 |
iReadSettings->maxPassiveChannelTimePresent = ETrue;
|
|
1472 |
iReadStatuses->maxPassiveChannelTimeResult = aResultsRef;
|
|
1473 |
iReadStatuses->maxPassiveChannelTimeStatus = aStatusRef;
|
|
1474 |
}
|
|
1475 |
|
|
1476 |
// *****************************************************************
|
|
1477 |
else if( lastUriSeg.Match( KNSmlWLanMaxApFailureCount ) != KErrNotFound )
|
|
1478 |
{
|
|
1479 |
_DBG_FILE("CGlobalWLANAdapter::FetchLeafObjectL(): leaf");
|
|
1480 |
iReadSettings->maxApFailureCountPresent = ETrue;
|
|
1481 |
iReadStatuses->maxApFailureCountResult = aResultsRef;
|
|
1482 |
iReadStatuses->maxApFailureCountStatus = aStatusRef;
|
|
1483 |
}
|
|
1484 |
|
|
1485 |
// *****************************************************************
|
|
1486 |
else if( lastUriSeg.Match( KNSmlWLanLongBeaconFindCount ) != KErrNotFound )
|
|
1487 |
{
|
|
1488 |
_DBG_FILE("CGlobalWLANAdapter::FetchLeafObjectL(): leaf");
|
|
1489 |
iReadSettings->longBeaconFindCountPresent = ETrue;
|
|
1490 |
iReadStatuses->longBeaconFindCountResult = aResultsRef;
|
|
1491 |
iReadStatuses->longBeaconFindCountStatus = aStatusRef;
|
|
1492 |
}
|
|
1493 |
|
|
1494 |
// *****************************************************************
|
|
1495 |
else if( lastUriSeg.Match( KNSmlWLanQosNullFrameInterval ) != KErrNotFound )
|
|
1496 |
{
|
|
1497 |
_DBG_FILE("CGlobalWLANAdapter::FetchLeafObjectL(): leaf");
|
|
1498 |
iReadSettings->qosNullFrameIntervalPresent = ETrue;
|
|
1499 |
iReadStatuses->qosNullFrameIntervalResult = aResultsRef;
|
|
1500 |
iReadStatuses->qosNullFrameIntervalStatus = aStatusRef;
|
|
1501 |
}
|
|
1502 |
|
|
1503 |
// *****************************************************************
|
|
1504 |
else if( lastUriSeg.Match( KNSmlWLanQosNullFrameTimeout ) != KErrNotFound )
|
|
1505 |
{
|
|
1506 |
_DBG_FILE("CGlobalWLANAdapter::FetchLeafObjectL(): leaf");
|
|
1507 |
iReadSettings->qosNullFrameTimeoutPresent = ETrue;
|
|
1508 |
iReadStatuses->qosNullFrameTimeoutResult = aResultsRef;
|
|
1509 |
iReadStatuses->qosNullFrameTimeoutStatus = aStatusRef;
|
|
1510 |
}
|
|
1511 |
|
|
1512 |
// *****************************************************************
|
|
1513 |
else if( lastUriSeg.Match( KNSmlWLanMTU ) != KErrNotFound )
|
|
1514 |
{
|
|
1515 |
_DBG_FILE("CGlobalWLANAdapter::FetchLeafObjectL(): leaf");
|
|
1516 |
iReadSettings->MTUPresent = ETrue;
|
|
1517 |
iReadStatuses->MTUResult = aResultsRef;
|
|
1518 |
iReadStatuses->MTUStatus = aStatusRef;
|
|
1519 |
}
|
|
1520 |
|
|
1521 |
// *****************************************************************
|
|
1522 |
// The given leaf was not found
|
|
1523 |
else
|
|
1524 |
{
|
|
1525 |
_DBG_FILE("CGlobalWLANAdapter::FetchLeafObjectL(): No matchin leaf was found");
|
|
1526 |
iCallBack->SetStatusL(aStatusRef, ENotFound);
|
|
1527 |
}
|
|
1528 |
}
|
|
1529 |
else
|
|
1530 |
{
|
|
1531 |
// Something went wrong
|
|
1532 |
_DBG_FILE("CGlobalWLANAdapter::FetchLeafObjectL(): No matchin node was found");
|
|
1533 |
iCallBack->SetStatusL(aStatusRef, EInvalidObject);
|
|
1534 |
}
|
|
1535 |
|
|
1536 |
_DBG_FILE("CGlobalWLANAdapter::FetchLeafObjectL(): end");
|
|
1537 |
|
|
1538 |
}
|
|
1539 |
|
|
1540 |
|
|
1541 |
//-----------------------------------------------------------------------------
|
|
1542 |
// CGlobalWLANAdapter* CGlobalWLANAdapter::ChildURIListL( const TDesC& aURI,
|
|
1543 |
// const TDesC& aLUID, const CArrayFix<TNSmlDmMappingInfo>& aPreviousURISegmentList,
|
|
1544 |
// const TInt aResultsRef, const TInt aStatusRef )
|
|
1545 |
//-----------------------------------------------------------------------------
|
|
1546 |
void CGlobalWLANAdapter::ChildURIListL( const TDesC8& aURI,
|
|
1547 |
const TDesC8& /*aLUID*/,
|
|
1548 |
const CArrayFix<TSmlDmMappingInfo>& /*aPreviousURISegmentList*/,
|
|
1549 |
const TInt aResultsRef,
|
|
1550 |
const TInt aStatusRef )
|
|
1551 |
{
|
|
1552 |
_DBG_FILE("CGlobalWLANAdapter::ChildURIListL(): begin");
|
|
1553 |
DBG_ARGS8(_S8("globalwlanadapter::ChildUriList - <%S>"), &aURI );
|
|
1554 |
|
|
1555 |
CBufBase* currentUriSegmentList = CBufFlat::NewL( KUriSegListLength );
|
|
1556 |
CleanupStack::PushL( currentUriSegmentList );
|
|
1557 |
TEntry currentEntry;
|
|
1558 |
TInt uriSegs = NumOfUriSegs( aURI );
|
|
1559 |
|
|
1560 |
// Check whether WLAN node in question
|
|
1561 |
if ( aURI.Match(_L8("WLAN" ))!= KErrNotFound && uriSegs == 1 )
|
|
1562 |
{
|
|
1563 |
_DBG_FILE("CGlobalWLANAdapter::ChildURIListL(): WLAN");
|
|
1564 |
currentUriSegmentList->InsertL( 0, KNSmlWLanNode );
|
|
1565 |
iCallBack->SetResultsL( aResultsRef, *currentUriSegmentList, KNullDesC8 );
|
|
1566 |
iCallBack->SetStatusL( aStatusRef, CSmlDmAdapter::EOk );
|
|
1567 |
_DBG_FILE("CGlobalWLANAdapter::ChildURIListL(): WLAN leafs returned");
|
|
1568 |
}
|
|
1569 |
|
|
1570 |
// Some illegal node/leaf in question
|
|
1571 |
else
|
|
1572 |
{
|
|
1573 |
iCallBack->SetStatusL(aStatusRef,CSmlDmAdapter::ENotFound);
|
|
1574 |
_DBG_FILE("CNSmlInternetAdapter::ChildURIListL(): ENotFound end");
|
|
1575 |
}
|
|
1576 |
|
|
1577 |
// delete the list
|
|
1578 |
CleanupStack::PopAndDestroy( currentUriSegmentList );
|
|
1579 |
_DBG_FILE("CGlobalWLANAdapter::ChildURIListL(): end");
|
|
1580 |
}
|
|
1581 |
|
|
1582 |
//-----------------------------------------------------------------------------
|
|
1583 |
// void CGlobalWLANAdapter::AddNodeObjectL( const TDesC& aURI, const TDesC& aParentLUID,
|
|
1584 |
// const TInt aStatusRef )
|
|
1585 |
//-----------------------------------------------------------------------------
|
|
1586 |
void CGlobalWLANAdapter::AddNodeObjectL( const TDesC8& aURI,
|
|
1587 |
const TDesC8& aParentLUID,
|
|
1588 |
const TInt aStatusRef )
|
|
1589 |
{
|
|
1590 |
|
|
1591 |
DBG_ARGS8(_S8("CGlobalWLANAdapter::AddNodeObjectL - uri: <%S> to aParentLuid: <%S>"),
|
|
1592 |
&aURI, &aParentLUID );
|
|
1593 |
|
|
1594 |
TInt uriSegs = NumOfUriSegs( aURI );
|
|
1595 |
|
|
1596 |
// The only node is WLAN, lets check if that is in question
|
|
1597 |
if( aURI.Match( _L8("WLAN" ) ) != KErrNotFound && uriSegs==1 )
|
|
1598 |
{
|
|
1599 |
// No actions needed, the table is created and filled in the
|
|
1600 |
// Execution function.
|
|
1601 |
iCallBack->SetStatusL(aStatusRef, CSmlDmAdapter::EOk);
|
|
1602 |
}
|
|
1603 |
else
|
|
1604 |
{
|
|
1605 |
iCallBack->SetStatusL(aStatusRef, CSmlDmAdapter::EError);
|
|
1606 |
}
|
|
1607 |
|
|
1608 |
_DBG_FILE("CGlobalWLANAdapter::AddNodeObjectL(): end");
|
|
1609 |
}
|
|
1610 |
|
|
1611 |
//------------------------------------------------------------------------------
|
|
1612 |
// CGlobalWLANAdapter::ExecuteCommandL
|
|
1613 |
// not supported
|
|
1614 |
//------------------------------------------------------------------------------
|
|
1615 |
void CGlobalWLANAdapter::ExecuteCommandL( const TDesC8& /*aURI*/,
|
|
1616 |
const TDesC8& /*aLUID*/,
|
|
1617 |
const TDesC8& /*aArgument*/,
|
|
1618 |
const TDesC8& /*aType*/,
|
|
1619 |
TInt aStatusRef )
|
|
1620 |
{
|
|
1621 |
_DBG_FILE("CGlobalWLANAdapter::ExecuteCommandL(): begin");
|
|
1622 |
|
|
1623 |
iCallBack->SetStatusL(aStatusRef, CSmlDmAdapter::EError);
|
|
1624 |
|
|
1625 |
_DBG_FILE("CGlobalWLANAdapter::ExecuteCommandL(): end");
|
|
1626 |
}
|
|
1627 |
|
|
1628 |
//------------------------------------------------------------------------------
|
|
1629 |
// CGlobalWLANAdapter::ExecuteCommandL ( .. RWriteStream ..)
|
|
1630 |
// not supported
|
|
1631 |
//------------------------------------------------------------------------------
|
|
1632 |
void CGlobalWLANAdapter::ExecuteCommandL( const TDesC8& /*aURI*/,
|
|
1633 |
const TDesC8& /*aLUID*/,
|
|
1634 |
RWriteStream*& /*aStream*/,
|
|
1635 |
const TDesC8& /*aType*/,
|
|
1636 |
TInt aStatusref )
|
|
1637 |
{
|
|
1638 |
_DBG_FILE("CGlobalWLANAdapter::ExecuteCommandL(): begin");
|
|
1639 |
|
|
1640 |
iCallBack->SetStatusL( aStatusref, CSmlDmAdapter::EError );
|
|
1641 |
|
|
1642 |
_DBG_FILE("CGlobalWLANAdapter::ExecuteCommandL(): end");
|
|
1643 |
}
|
|
1644 |
|
|
1645 |
//------------------------------------------------------------------------------
|
|
1646 |
// CGlobalWLANAdapter::CopyCommandL
|
|
1647 |
// not supported
|
|
1648 |
//------------------------------------------------------------------------------
|
|
1649 |
void CGlobalWLANAdapter::CopyCommandL( const TDesC8& /*aTargetURI*/,
|
|
1650 |
const TDesC8& /*aTargetLUID*/,
|
|
1651 |
const TDesC8& /* aSourceURI*/,
|
|
1652 |
const TDesC8& /*aSourceLUID*/,
|
|
1653 |
const TDesC8& /*aType*/,
|
|
1654 |
TInt aStatusRef )
|
|
1655 |
{
|
|
1656 |
_DBG_FILE("CGlobalWLANAdapter::CopyCommandL(): begin");
|
|
1657 |
|
|
1658 |
iCallBack->SetStatusL(aStatusRef, CSmlDmAdapter::EError);
|
|
1659 |
|
|
1660 |
_DBG_FILE("CGlobalWLANAdapter::CopyCommandL(): end");
|
|
1661 |
}
|
|
1662 |
//------------------------------------------------------------------------------
|
|
1663 |
// CGlobalWLANAdapter::StartAtomicL
|
|
1664 |
// not supported
|
|
1665 |
//------------------------------------------------------------------------------
|
|
1666 |
void CGlobalWLANAdapter::StartAtomicL()
|
|
1667 |
{
|
|
1668 |
_DBG_FILE("CGlobalWLANAdapter::StartAtomicL(): begin");
|
|
1669 |
_DBG_FILE("CGlobalWLANAdapter::StartAtomicL(): end");
|
|
1670 |
}
|
|
1671 |
|
|
1672 |
//------------------------------------------------------------------------------
|
|
1673 |
// CGlobalWLANAdapter::CommitAtomicL
|
|
1674 |
// not supported
|
|
1675 |
//------------------------------------------------------------------------------
|
|
1676 |
void CGlobalWLANAdapter::CommitAtomicL()
|
|
1677 |
{
|
|
1678 |
_DBG_FILE("CGlobalWLANAdapter::CommitAtomicL(): begin");
|
|
1679 |
_DBG_FILE("CGlobalWLANAdapter::CommitAtomicL(): end");
|
|
1680 |
}
|
|
1681 |
|
|
1682 |
//------------------------------------------------------------------------------
|
|
1683 |
// CGlobalWLANAdapter::RollbackAtomicL
|
|
1684 |
// returns EError
|
|
1685 |
//------------------------------------------------------------------------------
|
|
1686 |
void CGlobalWLANAdapter::RollbackAtomicL()
|
|
1687 |
{
|
|
1688 |
_DBG_FILE("CGlobalWLANAdapter::RollbackAtomicL(): begin");
|
|
1689 |
_DBG_FILE("CGlobalWLANAdapter::RollbackAtomicL(): end");
|
|
1690 |
}
|
|
1691 |
|
|
1692 |
|
|
1693 |
//------------------------------------------------------------------------------
|
|
1694 |
// CGlobalWLANAdapter::StreamingSupport
|
|
1695 |
// returns ETrue, streaming is supported
|
|
1696 |
//------------------------------------------------------------------------------
|
|
1697 |
|
|
1698 |
TBool CGlobalWLANAdapter::StreamingSupport( TInt& /*aItemSize*/ )
|
|
1699 |
{
|
|
1700 |
_DBG_FILE("CGlobalWLANAdapter::StreamingSupport(): begin");
|
|
1701 |
_DBG_FILE("CGlobalWLANAdapter::StreamingSupport(): end");
|
|
1702 |
return EFalse;
|
|
1703 |
}
|
|
1704 |
|
|
1705 |
//------------------------------------------------------------------------------
|
|
1706 |
// CGlobalWLANAdapter::StreamCommittedL
|
|
1707 |
// not used in this adapter
|
|
1708 |
//------------------------------------------------------------------------------
|
|
1709 |
|
|
1710 |
void CGlobalWLANAdapter::StreamCommittedL()
|
|
1711 |
{
|
|
1712 |
_DBG_FILE("CGlobalWLANAdapter::StreamCommittedL(): begin");
|
|
1713 |
_DBG_FILE("CGlobalWLANAdapter::StreamCommittedL(): end");
|
|
1714 |
}
|
|
1715 |
|
|
1716 |
//-----------------------------------------------------------------------------
|
|
1717 |
// CGlobalWLANAdapter* CGlobalWLANAdapter::CompleteOutstandingCmdsL( )
|
|
1718 |
//-----------------------------------------------------------------------------
|
|
1719 |
void CGlobalWLANAdapter::CompleteOutstandingCmdsL( )
|
|
1720 |
{
|
|
1721 |
_DBG_FILE("CGlobalWLANAdapter::CompleteOutStandingCmdsL(): begin");
|
|
1722 |
|
|
1723 |
ExecuteBufferL( ETrue );
|
|
1724 |
|
|
1725 |
_DBG_FILE("CGlobalWLANAdapter::CompleteOutStandingCmdsL(): end");
|
|
1726 |
}
|
|
1727 |
|
|
1728 |
|
|
1729 |
// -------------------------------------------------------------------------------------
|
|
1730 |
// CGlobalWLANAdapter::FillNodeInfoL()
|
|
1731 |
// Fills the node info in ddf structure
|
|
1732 |
// -------------------------------------------------------------------------------------
|
|
1733 |
void CGlobalWLANAdapter::FillNodeInfoL( MSmlDmDDFObject& aNode,
|
|
1734 |
TSmlDmAccessTypes aAccTypes,
|
|
1735 |
MSmlDmDDFObject::TOccurence aOccurrence,
|
|
1736 |
MSmlDmDDFObject::TScope aScope,
|
|
1737 |
MSmlDmDDFObject::TDFFormat aFormat,
|
|
1738 |
const TDesC8& aDescription )
|
|
1739 |
|
|
1740 |
{
|
|
1741 |
aNode.SetAccessTypesL(aAccTypes);
|
|
1742 |
aNode.SetOccurenceL(aOccurrence);
|
|
1743 |
aNode.SetScopeL(aScope);
|
|
1744 |
aNode.SetDFFormatL(aFormat);
|
|
1745 |
if(aFormat!=MSmlDmDDFObject::ENode)
|
|
1746 |
{
|
|
1747 |
aNode.AddDFTypeMimeTypeL(KNSmlMimeType);
|
|
1748 |
}
|
|
1749 |
aNode.SetDescriptionL(aDescription);
|
|
1750 |
}
|
|
1751 |
|
|
1752 |
|
|
1753 |
// ------------------------------------------------------------------------------------------------
|
|
1754 |
// void CGlobalWLANAdapter::ExecuteBufferL( TBool aFinal )
|
|
1755 |
// Executes buffered commands
|
|
1756 |
// ------------------------------------------------------------------------------------------------
|
|
1757 |
void CGlobalWLANAdapter::ExecuteBufferL( TBool /*aFinal*/ )
|
|
1758 |
{
|
|
1759 |
|
|
1760 |
_DBG_FILE("CGlobalWLANAdapter::ExecuteBuffer(): begin");
|
|
1761 |
|
|
1762 |
// Store the given values into cenrep and commsdb and
|
|
1763 |
// read the required parameters from cenrep and commsdb
|
|
1764 |
TRAPD (err1, StoreCenRepParamsL());
|
|
1765 |
TRAPD (err2, StoreCommsDBParamsL());
|
|
1766 |
TRAPD (err3, ReadCenRepParamsL());
|
|
1767 |
TRAPD (err4, ReadCommsDBParamsL());
|
|
1768 |
|
|
1769 |
// Init the member variables after updates
|
|
1770 |
InitMemberVariables();
|
|
1771 |
|
|
1772 |
// If some of the operations failed, then leave
|
|
1773 |
User::LeaveIfError( err1 );
|
|
1774 |
User::LeaveIfError( err2 );
|
|
1775 |
User::LeaveIfError( err3 );
|
|
1776 |
User::LeaveIfError( err4 );
|
|
1777 |
|
|
1778 |
_DBG_FILE("CGlobalWLANAdapter::ExecuteBuffer(): End");
|
|
1779 |
}
|
|
1780 |
|
|
1781 |
|
|
1782 |
// ------------------------------------------------------------------------------------------------
|
|
1783 |
// TBool CGlobalWLANAdapter::StoreCenRepParamsL( )
|
|
1784 |
// Stores the parameters to central repository
|
|
1785 |
// ------------------------------------------------------------------------------------------------
|
|
1786 |
void CGlobalWLANAdapter::StoreCenRepParamsL()
|
|
1787 |
{
|
|
1788 |
|
|
1789 |
_DBG_FILE("CGlobalWLANAdapter::StoreCenRepParams(): begin");
|
|
1790 |
|
|
1791 |
CRepository* repository = NULL;
|
|
1792 |
CRepository* conSettRep = NULL;
|
|
1793 |
TInt err = KErrNone;
|
|
1794 |
|
|
1795 |
|
|
1796 |
// Write KWlanInternetConnectivityTest
|
|
1797 |
if ( iWriteSettings->internetConnectivityTestPresent )
|
|
1798 |
{
|
|
1799 |
_DBG_FILE("CGlobalWLANAdapter:StoreCenRepParams() KWlanInternetConnectivityTest start " );
|
|
1800 |
// Open the cenrep for internet connectivity settings. This is the only global wlan parameter
|
|
1801 |
// from this cenrep
|
|
1802 |
conSettRep = CRepository::NewL( KCRUidInternetConnectivitySettings );
|
|
1803 |
|
|
1804 |
// There is no pointer to the repository, leave
|
|
1805 |
if ( conSettRep == NULL )
|
|
1806 |
{
|
|
1807 |
User::LeaveIfError( KErrGeneral );
|
|
1808 |
}
|
|
1809 |
|
|
1810 |
CleanupStack::PushL(conSettRep);
|
|
1811 |
|
|
1812 |
err = conSettRep->Set( KIctsTestPermission, static_cast<TInt>( iWriteSettings->internetConnectivityTest ) );
|
|
1813 |
_DBG_FILE("CGlobalWLANAdapter:StoreCenRepParams() KWlanInternetConnectivityTest set to cenRep " );
|
|
1814 |
if( err == KErrNone )
|
|
1815 |
{
|
|
1816 |
_DBG_FILE("CGlobalWLANAdapter:StoreCenRepParams() KWlanInternetConnectivityTest" );
|
|
1817 |
iCallBack->SetStatusL(iWriteStatuses->internetConnectivityTestStatus, CSmlDmAdapter::EOk);
|
|
1818 |
}
|
|
1819 |
else
|
|
1820 |
{
|
|
1821 |
_DBG_FILE("CGlobalWLANAdapter:StoreCenRepParams() KWlanInternetConnectivityTest failed " );
|
|
1822 |
iCallBack->SetStatusL(iWriteStatuses->internetConnectivityTestStatus, CSmlDmAdapter::EError);
|
|
1823 |
}
|
|
1824 |
CleanupStack::PopAndDestroy(conSettRep);
|
|
1825 |
}
|
|
1826 |
|
|
1827 |
|
|
1828 |
// The rest of the parameters are stored to Wlan device settings cenRep
|
|
1829 |
repository = CRepository::NewL( KCRUidWlanDeviceSettingsRegistryId );
|
|
1830 |
|
|
1831 |
// There is no pointer to the repository, leave
|
|
1832 |
if ( repository == NULL )
|
|
1833 |
{
|
|
1834 |
User::LeaveIfError( KErrGeneral );
|
|
1835 |
}
|
|
1836 |
|
|
1837 |
CleanupStack::PushL(repository);
|
|
1838 |
|
|
1839 |
if ( iWriteSettings->MTUPresent )
|
|
1840 |
{
|
|
1841 |
err = repository->Set( KWlanMTU, static_cast<TInt>( iWriteSettings->MTU ) );
|
|
1842 |
|
|
1843 |
DBG_ARGS8(_S8("CGlobalWLANAdapter::StoreCenRepParams, MTU status - (%d)"), err );
|
|
1844 |
if( err == KErrNone )
|
|
1845 |
{
|
|
1846 |
_DBG_FILE("CGlobalWLANAdapter:StoreCenRepParams() MTU" );
|
|
1847 |
iCallBack->SetStatusL(iWriteStatuses->MTUStatus, CSmlDmAdapter::EOk);
|
|
1848 |
}
|
|
1849 |
else
|
|
1850 |
{
|
|
1851 |
_DBG_FILE("CGlobalWLANAdapter:StoreCenRepParams() MTU failed " );
|
|
1852 |
iCallBack->SetStatusL(iWriteStatuses->MTUStatus, CSmlDmAdapter::EError);
|
|
1853 |
}
|
|
1854 |
}
|
|
1855 |
|
|
1856 |
// Write KWlanScanRate
|
|
1857 |
if ( iWriteSettings->scanRatePresent )
|
|
1858 |
{
|
|
1859 |
err = repository->Set( KWlanScanRate, static_cast<TInt>( iWriteSettings->scanRate ) );
|
|
1860 |
|
|
1861 |
DBG_ARGS8(_S8("CGlobalWLANAdapter::StoreCenRepParams, scanrate status - (%d)"), err );
|
|
1862 |
if( err == KErrNone )
|
|
1863 |
{
|
|
1864 |
_DBG_FILE("CGlobalWLANAdapter:StoreCenRepParams() WlanScanRate" );
|
|
1865 |
iCallBack->SetStatusL(iWriteStatuses->scanRateStatus, CSmlDmAdapter::EOk);
|
|
1866 |
}
|
|
1867 |
else
|
|
1868 |
{
|
|
1869 |
_DBG_FILE("CGlobalWLANAdapter:StoreCenRepParams() WlanScanRate failed " );
|
|
1870 |
iCallBack->SetStatusL(iWriteStatuses->scanRateStatus, CSmlDmAdapter::EError);
|
|
1871 |
}
|
|
1872 |
}
|
|
1873 |
|
|
1874 |
// Write KWlanRcpiTrigger
|
|
1875 |
if ( iWriteSettings->RCPITriggerPresent )
|
|
1876 |
{
|
|
1877 |
err = repository->Set( KWlanRcpiTrigger, static_cast<TInt>( iWriteSettings->RCPITrigger ) );
|
|
1878 |
|
|
1879 |
if( err == KErrNone )
|
|
1880 |
{
|
|
1881 |
_DBG_FILE("CGlobalWLANAdapter:StoreCenRepParams() KWlanRcpiTrigger" );
|
|
1882 |
iCallBack->SetStatusL(iWriteStatuses->RCPITriggerStatus, CSmlDmAdapter::EOk);
|
|
1883 |
}
|
|
1884 |
else
|
|
1885 |
{
|
|
1886 |
_DBG_FILE("CGlobalWLANAdapter:StoreCenRepParams() KWlanRcpiTrigger failed" );
|
|
1887 |
iCallBack->SetStatusL(iWriteStatuses->RCPITriggerStatus, CSmlDmAdapter::EError);
|
|
1888 |
}
|
|
1889 |
}
|
|
1890 |
|
|
1891 |
// Write KWlanMinActiveChannelTime
|
|
1892 |
if ( iWriteSettings->minActiveChannelTimePresent )
|
|
1893 |
{
|
|
1894 |
err = repository->Set( KWlanMinActiveChannelTime, static_cast<TInt>( iWriteSettings->minActiveChannelTime ) );
|
|
1895 |
|
|
1896 |
if( err == KErrNone )
|
|
1897 |
{
|
|
1898 |
_DBG_FILE("CGlobalWLANAdapter:StoreCenRepParams() KWlanMinActiveChannelTime" );
|
|
1899 |
iCallBack->SetStatusL(iWriteStatuses->minActiveChannelTimeStatus, CSmlDmAdapter::EOk);
|
|
1900 |
}
|
|
1901 |
else
|
|
1902 |
{
|
|
1903 |
_DBG_FILE("CGlobalWLANAdapter:StoreCenRepParams() KWlanMinActiveChannelTime failed" );
|
|
1904 |
iCallBack->SetStatusL(iWriteStatuses->minActiveChannelTimeStatus, CSmlDmAdapter::EError);
|
|
1905 |
}
|
|
1906 |
}
|
|
1907 |
|
|
1908 |
// Write KWlanMaxActiveChannelTime
|
|
1909 |
if ( iWriteSettings->maxActiveChannelTimePresent )
|
|
1910 |
{
|
|
1911 |
err = repository->Set( KWlanMaxActiveChannelTime, static_cast<TInt>( iWriteSettings->maxActiveChannelTime ) );
|
|
1912 |
|
|
1913 |
if( err == KErrNone )
|
|
1914 |
{
|
|
1915 |
_DBG_FILE("CGlobalWLANAdapter:StoreCenRepParams() KWlanMaxActiveChannelTime" );
|
|
1916 |
iCallBack->SetStatusL(iWriteStatuses->maxActiveChannelTimeStatus, CSmlDmAdapter::EOk);
|
|
1917 |
}
|
|
1918 |
else
|
|
1919 |
{
|
|
1920 |
_DBG_FILE("CGlobalWLANAdapter:StoreCenRepParams() KWlanMaxActiveChannelTime failed" );
|
|
1921 |
iCallBack->SetStatusL(iWriteStatuses->maxActiveChannelTimeStatus, CSmlDmAdapter::EError);
|
|
1922 |
}
|
|
1923 |
}
|
|
1924 |
|
|
1925 |
// Write KWlanMaxTxMSDULifeTime
|
|
1926 |
if ( iWriteSettings->maxTxMSDULifeTimePresent )
|
|
1927 |
{
|
|
1928 |
err = repository->Set( KWlanMaxTxMSDULifeTime, static_cast<TInt>( iWriteSettings->maxTxMSDULifeTime ) );
|
|
1929 |
|
|
1930 |
if( err == KErrNone )
|
|
1931 |
{
|
|
1932 |
_DBG_FILE("CGlobalWLANAdapter:StoreCenRepParams()KWlanMaxTxMSDULifeTime" );
|
|
1933 |
iCallBack->SetStatusL(iWriteStatuses->maxTxMSDULifeTimeStatus, CSmlDmAdapter::EOk);
|
|
1934 |
}
|
|
1935 |
else
|
|
1936 |
{
|
|
1937 |
_DBG_FILE("CGlobalWLANAdapter:StoreCenRepParams()KWlanMaxTxMSDULifeTime failed" );
|
|
1938 |
iCallBack->SetStatusL(iWriteStatuses->maxTxMSDULifeTimeStatus, CSmlDmAdapter::EError);
|
|
1939 |
}
|
|
1940 |
}
|
|
1941 |
|
|
1942 |
// Write KWlanScanExpirationTimer
|
|
1943 |
if ( iWriteSettings->scanExpirationTimerPresent )
|
|
1944 |
{
|
|
1945 |
err = repository->Set( KWlanScanExpirationTimer, static_cast<TInt>( iWriteSettings->scanExpirationTimer ) );
|
|
1946 |
|
|
1947 |
if( err == KErrNone )
|
|
1948 |
{
|
|
1949 |
_DBG_FILE("CGlobalWLANAdapter:StoreCenRepParams()KWlanScanExpirationTimer" );
|
|
1950 |
iCallBack->SetStatusL(iWriteStatuses->scanExpirationTimerStatus, CSmlDmAdapter::EOk);
|
|
1951 |
}
|
|
1952 |
else
|
|
1953 |
{
|
|
1954 |
_DBG_FILE("CGlobalWLANAdapter:StoreCenRepParams()KWlanScanExpirationTimer failed" );
|
|
1955 |
iCallBack->SetStatusL(iWriteStatuses->scanExpirationTimerStatus, CSmlDmAdapter::EError);
|
|
1956 |
}
|
|
1957 |
}
|
|
1958 |
|
|
1959 |
// Write KWlanUnloadDriverTimer
|
|
1960 |
if ( iWriteSettings->unloadDriverTimerPresent )
|
|
1961 |
{
|
|
1962 |
err = repository->Set( KWlanUnloadDriverTimer, static_cast<TInt>( iWriteSettings->unloadDriverTimer ) );
|
|
1963 |
|
|
1964 |
if( err == KErrNone )
|
|
1965 |
{
|
|
1966 |
_DBG_FILE("CGlobalWLANAdapter:StoreCenRepParams()KWlanUnloadDriverTimer" );
|
|
1967 |
iCallBack->SetStatusL(iWriteStatuses->unloadDriverTimerStatus, CSmlDmAdapter::EOk);
|
|
1968 |
}
|
|
1969 |
else
|
|
1970 |
{
|
|
1971 |
_DBG_FILE("CGlobalWLANAdapter:StoreCenRepParams()KWlanUnloadDriverTimer failed" );
|
|
1972 |
iCallBack->SetStatusL(iWriteStatuses->unloadDriverTimerStatus, CSmlDmAdapter::EError);
|
|
1973 |
}
|
|
1974 |
}
|
|
1975 |
|
|
1976 |
// Write KWlanRoamTimer
|
|
1977 |
if ( iWriteSettings->roamTimerPresent )
|
|
1978 |
{
|
|
1979 |
err = repository->Set( KWlanRoamTimer, static_cast<TInt>( iWriteSettings->roamTimer ) );
|
|
1980 |
|
|
1981 |
if( err == KErrNone)
|
|
1982 |
{
|
|
1983 |
_DBG_FILE("CGlobalWLANAdapter:StoreCenRepParams() KWlanRoamTimer" );
|
|
1984 |
iCallBack->SetStatusL(iWriteStatuses->roamTimerStatus, CSmlDmAdapter::EOk);
|
|
1985 |
}
|
|
1986 |
else
|
|
1987 |
{
|
|
1988 |
_DBG_FILE("CGlobalWLANAdapter:StoreCenRepParams() KWlanRoamTimer failed" );
|
|
1989 |
iCallBack->SetStatusL(iWriteStatuses->roamTimerStatus, CSmlDmAdapter::EError);
|
|
1990 |
}
|
|
1991 |
}
|
|
1992 |
|
|
1993 |
// Write KWlanRcpiDifference
|
|
1994 |
if ( iWriteSettings->RCPIDifferencePresent )
|
|
1995 |
{
|
|
1996 |
err = repository->Set( KWlanRcpiDifference, static_cast<TInt>( iWriteSettings->RCPIDifference ) );
|
|
1997 |
|
|
1998 |
DBG_ARGS8(_S8("CGlobalWLANAdapter::StoreCenRepParams, rcpidifference status - (%d)"), err );
|
|
1999 |
if( err == KErrNone)
|
|
2000 |
{
|
|
2001 |
_DBG_FILE("CGlobalWLANAdapter:StoreCenRepParams() KWlanRcpiDifference" );
|
|
2002 |
iCallBack->SetStatusL(iWriteStatuses->RCPIDifferenceStatus, CSmlDmAdapter::EOk);
|
|
2003 |
}
|
|
2004 |
else
|
|
2005 |
{
|
|
2006 |
_DBG_FILE("CGlobalWLANAdapter:StoreCenRepParams() KWlanRcpiDifference failed" );
|
|
2007 |
iCallBack->SetStatusL(iWriteStatuses->RCPIDifferenceStatus, CSmlDmAdapter::EError);
|
|
2008 |
}
|
|
2009 |
}
|
|
2010 |
|
|
2011 |
// Write KWlanConnRegainTimer
|
|
2012 |
if ( iWriteSettings->connRegainTimerPresent )
|
|
2013 |
{
|
|
2014 |
err = repository->Set( KWlanConnRegainTimer, static_cast<TInt>( iWriteSettings->connRegainTimer ) );
|
|
2015 |
|
|
2016 |
if( err == KErrNone )
|
|
2017 |
{
|
|
2018 |
_DBG_FILE("CGlobalWLANAdapter:StoreCenRepParams() KWlanConnRegainTimer" );
|
|
2019 |
iCallBack->SetStatusL(iWriteStatuses->connRegainTimerStatus, CSmlDmAdapter::EOk);
|
|
2020 |
}
|
|
2021 |
else
|
|
2022 |
{
|
|
2023 |
_DBG_FILE("CGlobalWLANAdapter:StoreCenRepParams() KWlanConnRegainTimer failed" );
|
|
2024 |
iCallBack->SetStatusL(iWriteStatuses->connRegainTimerStatus, CSmlDmAdapter::EError);
|
|
2025 |
}
|
|
2026 |
}
|
|
2027 |
|
|
2028 |
// Write KWlanMaxTriesToFindNw
|
|
2029 |
if ( iWriteSettings->maxTriesToFindNwPresent )
|
|
2030 |
{
|
|
2031 |
err = repository->Set( KWlanMaxTriesToFindNw, static_cast<TInt>( iWriteSettings->maxTriesToFindNw ) );
|
|
2032 |
|
|
2033 |
if( err == KErrNone )
|
|
2034 |
{
|
|
2035 |
_DBG_FILE("CGlobalWLANAdapter:StoreCenRepParams() KWlanMaxTriesToFindNw ");
|
|
2036 |
iCallBack->SetStatusL(iWriteStatuses->maxTriesToFindNwStatus, CSmlDmAdapter::EOk);
|
|
2037 |
}
|
|
2038 |
else
|
|
2039 |
{
|
|
2040 |
_DBG_FILE("CGlobalWLANAdapter:StoreCenRepParams() KWlanMaxTriesToFindNw failed");
|
|
2041 |
iCallBack->SetStatusL(iWriteStatuses->maxTriesToFindNwStatus, CSmlDmAdapter::EError);
|
|
2042 |
}
|
|
2043 |
}
|
|
2044 |
|
|
2045 |
// Write KWlanDelayBetweenFindNw
|
|
2046 |
if ( iWriteSettings->delayBetweenFindNwPresent )
|
|
2047 |
{
|
|
2048 |
err = repository->Set( KWlanDelayBetweenFindNw, static_cast<TInt>( iWriteSettings->delayBetweenFindNw ) );
|
|
2049 |
|
|
2050 |
if( err == KErrNone )
|
|
2051 |
{
|
|
2052 |
_DBG_FILE("CGlobalWLANAdapter:StoreCenRepParams() KWlanDelayBetweenFindNw" );
|
|
2053 |
iCallBack->SetStatusL(iWriteStatuses->delayBetweenFindNwStatus, CSmlDmAdapter::EOk);
|
|
2054 |
}
|
|
2055 |
else
|
|
2056 |
{
|
|
2057 |
_DBG_FILE("CGlobalWLANAdapter:StoreCenRepParams() KWlanDelayBetweenFindNw failed" );
|
|
2058 |
iCallBack->SetStatusL(iWriteStatuses->delayBetweenFindNwStatus, CSmlDmAdapter::EError);
|
|
2059 |
}
|
|
2060 |
}
|
|
2061 |
|
|
2062 |
// Write KWlanMinPassiveChannelTime
|
|
2063 |
if ( iWriteSettings->minPassiveChannelTimePresent )
|
|
2064 |
{
|
|
2065 |
err = repository->Set( KWlanMinPassiveChannelTime, static_cast<TInt>( iWriteSettings->minPassiveChannelTime ) );
|
|
2066 |
|
|
2067 |
if( err == KErrNone )
|
|
2068 |
{
|
|
2069 |
_DBG_FILE("CGlobalWLANAdapter:StoreCenRepParams() KWlanMinPassiveChannelTime" );
|
|
2070 |
iCallBack->SetStatusL(iWriteStatuses->minPassiveChannelTimeStatus, CSmlDmAdapter::EOk);
|
|
2071 |
}
|
|
2072 |
else
|
|
2073 |
{
|
|
2074 |
_DBG_FILE("CGlobalWLANAdapter:StoreCenRepParams() KWlanMinPassiveChannelTime failed" );
|
|
2075 |
iCallBack->SetStatusL(iWriteStatuses->minPassiveChannelTimeStatus, CSmlDmAdapter::EError);
|
|
2076 |
}
|
|
2077 |
}
|
|
2078 |
|
|
2079 |
// Write KWlanMaxPassiveChannelTime
|
|
2080 |
if ( iWriteSettings->maxPassiveChannelTimePresent )
|
|
2081 |
{
|
|
2082 |
err = repository->Set( KWlanMaxPassiveChannelTime, static_cast<TInt>( iWriteSettings->maxPassiveChannelTime ) );
|
|
2083 |
|
|
2084 |
if( err == KErrNone )
|
|
2085 |
{
|
|
2086 |
_DBG_FILE("CGlobalWLANAdapter:StoreCenRepParams() KWlanMaxPassiveChannelTime" );
|
|
2087 |
iCallBack->SetStatusL(iWriteStatuses->maxPassiveChannelTimeStatus, CSmlDmAdapter::EOk);
|
|
2088 |
}
|
|
2089 |
else
|
|
2090 |
{
|
|
2091 |
_DBG_FILE("CGlobalWLANAdapter:StoreCenRepParams() KWlanMaxPassiveChannelTime failed" );
|
|
2092 |
iCallBack->SetStatusL(iWriteStatuses->maxPassiveChannelTimeStatus, CSmlDmAdapter::EError);
|
|
2093 |
}
|
|
2094 |
}
|
|
2095 |
|
|
2096 |
// Write KWlanMaxApFailureCount
|
|
2097 |
if ( iWriteSettings->maxApFailureCountPresent )
|
|
2098 |
{
|
|
2099 |
err = repository->Set( KWlanMaxApFailureCount, static_cast<TInt>( iWriteSettings->maxApFailureCount ) );
|
|
2100 |
|
|
2101 |
if( err == KErrNone )
|
|
2102 |
{
|
|
2103 |
_DBG_FILE("CGlobalWLANAdapter:StoreCenRepParams() KWlanMaxApFailureCount" );
|
|
2104 |
iCallBack->SetStatusL(iWriteStatuses->maxApFailureCountStatus, CSmlDmAdapter::EOk);
|
|
2105 |
}
|
|
2106 |
else
|
|
2107 |
{
|
|
2108 |
_DBG_FILE("CGlobalWLANAdapter:StoreCenRepParams() KWlanMaxApFailureCount failed" );
|
|
2109 |
iCallBack->SetStatusL(iWriteStatuses->maxApFailureCountStatus, CSmlDmAdapter::EError);
|
|
2110 |
}
|
|
2111 |
}
|
|
2112 |
|
|
2113 |
// Write KWlanLongBeaconFindCount
|
|
2114 |
if ( iWriteSettings->longBeaconFindCountPresent )
|
|
2115 |
{
|
|
2116 |
err = repository->Set( KWlanLongBeaconFindCount, static_cast<TInt>( iWriteSettings->longBeaconFindCount ) );
|
|
2117 |
|
|
2118 |
if( err == KErrNone )
|
|
2119 |
{
|
|
2120 |
_DBG_FILE("CGlobalWLANAdapter:StoreCenRepParams() KWlanLongBeaconFindCount" );
|
|
2121 |
iCallBack->SetStatusL(iWriteStatuses->longBeaconFindCountStatus, CSmlDmAdapter::EOk);
|
|
2122 |
}
|
|
2123 |
else
|
|
2124 |
{
|
|
2125 |
_DBG_FILE("CGlobalWLANAdapter:StoreCenRepParams() KWlanLongBeaconFindCount failed" );
|
|
2126 |
iCallBack->SetStatusL(iWriteStatuses->longBeaconFindCountStatus, CSmlDmAdapter::EError);
|
|
2127 |
}
|
|
2128 |
}
|
|
2129 |
|
|
2130 |
// Write KWlanQosNullFrameInterval
|
|
2131 |
if ( iWriteSettings->qosNullFrameIntervalPresent )
|
|
2132 |
{
|
|
2133 |
err = repository->Set( KWlanQosNullFrameInterval, static_cast<TInt>( iWriteSettings->qosNullFrameInterval ) );
|
|
2134 |
|
|
2135 |
if( err == KErrNone )
|
|
2136 |
{
|
|
2137 |
_DBG_FILE("CGlobalWLANAdapter:StoreCenRepParams() KWlanQosNullFrameInterval" );
|
|
2138 |
iCallBack->SetStatusL(iWriteStatuses->qosNullFrameIntervalStatus, CSmlDmAdapter::EOk);
|
|
2139 |
}
|
|
2140 |
else
|
|
2141 |
{
|
|
2142 |
_DBG_FILE("CGlobalWLANAdapter:StoreCenRepParams() KWlanQosNullFrameInterval failed" );
|
|
2143 |
iCallBack->SetStatusL(iWriteStatuses->qosNullFrameIntervalStatus, CSmlDmAdapter::EError);
|
|
2144 |
}
|
|
2145 |
}
|
|
2146 |
|
|
2147 |
// Write KWlanQosNullFrameTimeout
|
|
2148 |
if ( iWriteSettings->qosNullFrameTimeoutPresent )
|
|
2149 |
{
|
|
2150 |
err = repository->Set( KWlanQosNullFrameTimeout, static_cast<TInt>( iWriteSettings->qosNullFrameTimeout ) );
|
|
2151 |
|
|
2152 |
if( err == KErrNone )
|
|
2153 |
{
|
|
2154 |
_DBG_FILE("CGlobalWLANAdapter:StoreCenRepParams() KWlanQosNullFrameTimeout" );
|
|
2155 |
iCallBack->SetStatusL(iWriteStatuses->qosNullFrameTimeoutStatus, CSmlDmAdapter::EOk);
|
|
2156 |
}
|
|
2157 |
else
|
|
2158 |
{
|
|
2159 |
_DBG_FILE("CGlobalWLANAdapter:StoreCenRepParams() KWlanQosNullFrameTimeout failed" );
|
|
2160 |
iCallBack->SetStatusL(iWriteStatuses->qosNullFrameTimeoutStatus, CSmlDmAdapter::EError);
|
|
2161 |
}
|
|
2162 |
}
|
|
2163 |
|
|
2164 |
// Cleanup
|
|
2165 |
CleanupStack::PopAndDestroy(repository);
|
|
2166 |
_DBG_FILE("CGlobalWLANAdapter::StoreCenRepParams(): end");
|
|
2167 |
return;
|
|
2168 |
}
|
|
2169 |
|
|
2170 |
// ------------------------------------------------------------------------------------------------
|
|
2171 |
// void CGlobalWLANAdapter::StoreCommsDBParams( )
|
|
2172 |
// Stores the parameters to central repository
|
|
2173 |
// ------------------------------------------------------------------------------------------------
|
|
2174 |
void CGlobalWLANAdapter::StoreCommsDBParamsL()
|
|
2175 |
{
|
|
2176 |
|
|
2177 |
_DBG_FILE("CGlobalWLANAdapter::StoreCommsDBParams(): begin");
|
|
2178 |
|
|
2179 |
CCommsDatabase* db = CCommsDatabase::NewL();
|
|
2180 |
CleanupStack::PushL(db);
|
|
2181 |
|
|
2182 |
// User defined WLAN device settings table from Comms database
|
|
2183 |
CCommsDbTableView* usrTable;
|
|
2184 |
|
|
2185 |
// Open user settings.
|
|
2186 |
usrTable = db->OpenViewMatchingUintLC( TPtrC(WLAN_DEVICE_SETTINGS),
|
|
2187 |
TPtrC(WLAN_DEVICE_SETTINGS_TYPE),
|
|
2188 |
KWlanUserSettings );
|
|
2189 |
|
|
2190 |
// if record did not exist, then it is created.
|
|
2191 |
if ( usrTable->GotoFirstRecord() != KErrNone )
|
|
2192 |
{
|
|
2193 |
_DBG_FILE("CGlobalWLANAdapter::StoreCommsDBParams(): Record creation");
|
|
2194 |
TUint32 id;
|
|
2195 |
User::LeaveIfError( usrTable->InsertRecord( id ) );
|
|
2196 |
|
|
2197 |
usrTable->WriteUintL( TPtrC(WLAN_DEVICE_SETTINGS_TYPE), KWlanUserSettings );
|
|
2198 |
//usrTable->WriteUintL( TPtrC(WLAN_TABLE_VERSION), KWlanDeviceSettingsTableVersion );
|
|
2199 |
User::LeaveIfError( usrTable->PutRecordChanges() ); // End and save changes.
|
|
2200 |
}
|
|
2201 |
|
|
2202 |
// Write CommsDat settings
|
|
2203 |
User::LeaveIfError( usrTable->UpdateRecord() ); // Begin changes.
|
|
2204 |
|
|
2205 |
// Check which parameters are present in the structure, store them into commsdb and
|
|
2206 |
// update the status to OK/Error accordingly
|
|
2207 |
if ( iWriteSettings->backgroundScanIntervalPresent )
|
|
2208 |
{
|
|
2209 |
_DBG_FILE("CGlobalWLANAdapter::StoreCommsDBParams(): write KBgScanInterval");
|
|
2210 |
TRAPD( err, usrTable->WriteUintL( TPtrC(WLAN_BG_SCAN_INTERVAL), iWriteSettings->backgroundScanInterval ));
|
|
2211 |
if ( err == KErrNone)
|
|
2212 |
{
|
|
2213 |
iCallBack->SetStatusL(iWriteStatuses->backgroundScanIntervalStatus, CSmlDmAdapter::EOk);
|
|
2214 |
}
|
|
2215 |
else
|
|
2216 |
{
|
|
2217 |
iCallBack->SetStatusL(iWriteStatuses->backgroundScanIntervalStatus, CSmlDmAdapter::EError);
|
|
2218 |
}
|
|
2219 |
}
|
|
2220 |
|
|
2221 |
if ( iWriteSettings->useDefaultSettingsPresent )
|
|
2222 |
{
|
|
2223 |
_DBG_FILE("CGlobalWLANAdapter::StoreCommsDBParams(): write KUseDefaultSettings");
|
|
2224 |
TRAPD( err, usrTable->WriteBoolL( TPtrC(WLAN_USE_DEFAULT_SETTINGS), iWriteSettings->useDefaultSettings ));
|
|
2225 |
if ( err == KErrNone)
|
|
2226 |
{
|
|
2227 |
iCallBack->SetStatusL(iWriteStatuses->useDefaultSettingsStatus, CSmlDmAdapter::EOk);
|
|
2228 |
}
|
|
2229 |
else
|
|
2230 |
{
|
|
2231 |
iCallBack->SetStatusL(iWriteStatuses->useDefaultSettingsStatus, CSmlDmAdapter::EError);
|
|
2232 |
}
|
|
2233 |
}
|
|
2234 |
|
|
2235 |
if ( iWriteSettings->longRetryLimitPresent )
|
|
2236 |
{
|
|
2237 |
_DBG_FILE("CGlobalWLANAdapter::StoreCommsDBParams(): write KWlanLongRetry");
|
|
2238 |
TRAPD( err, usrTable->WriteUintL( TPtrC(WLAN_LONG_RETRY), iWriteSettings->longRetryLimit ));
|
|
2239 |
if ( err == KErrNone)
|
|
2240 |
{
|
|
2241 |
iCallBack->SetStatusL(iWriteStatuses->longRetryLimitStatus, CSmlDmAdapter::EOk);
|
|
2242 |
}
|
|
2243 |
else
|
|
2244 |
{
|
|
2245 |
iCallBack->SetStatusL(iWriteStatuses->longRetryLimitStatus, CSmlDmAdapter::EError);
|
|
2246 |
}
|
|
2247 |
}
|
|
2248 |
|
|
2249 |
if ( iWriteSettings->shortRetryLimitPresent )
|
|
2250 |
{
|
|
2251 |
_DBG_FILE("CGlobalWLANAdapter::StoreCommsDBParams(): write KWlanShortRetry");
|
|
2252 |
TRAPD( err, usrTable->WriteUintL( TPtrC(WLAN_SHORT_RETRY), iWriteSettings->shortRetryLimit ));
|
|
2253 |
if ( err == KErrNone)
|
|
2254 |
{
|
|
2255 |
iCallBack->SetStatusL(iWriteStatuses->shortRetryLimitStatus, CSmlDmAdapter::EOk);
|
|
2256 |
}
|
|
2257 |
else
|
|
2258 |
{
|
|
2259 |
iCallBack->SetStatusL(iWriteStatuses->shortRetryLimitStatus, CSmlDmAdapter::EError);
|
|
2260 |
}
|
|
2261 |
}
|
|
2262 |
|
|
2263 |
if ( iWriteSettings->RTSThresholdPresent )
|
|
2264 |
{
|
|
2265 |
_DBG_FILE("CGlobalWLANAdapter::StoreCommsDBParams(): write KWlanRTSThreshold");
|
|
2266 |
TRAPD( err, usrTable->WriteUintL( TPtrC(WLAN_RTS_THRESHOLD), iWriteSettings->RTSThreshold ));
|
|
2267 |
if ( err == KErrNone)
|
|
2268 |
{
|
|
2269 |
iCallBack->SetStatusL(iWriteStatuses->RTSThresholdStatus, CSmlDmAdapter::EOk);
|
|
2270 |
}
|
|
2271 |
else
|
|
2272 |
{
|
|
2273 |
iCallBack->SetStatusL(iWriteStatuses->RTSThresholdStatus, CSmlDmAdapter::EError);
|
|
2274 |
}
|
|
2275 |
}
|
|
2276 |
|
|
2277 |
if ( iWriteSettings->TXPowerLevelPresent )
|
|
2278 |
{
|
|
2279 |
_DBG_FILE("CGlobalWLANAdapter::StoreCommsDBParams(): write KWlanTxPowerLevel");
|
|
2280 |
TRAPD( err, usrTable->WriteUintL( TPtrC(NU_WLAN_TX_POWER_LEVEL), iWriteSettings->TXPowerLevel ));
|
|
2281 |
if ( err == KErrNone)
|
|
2282 |
{
|
|
2283 |
iCallBack->SetStatusL(iWriteStatuses->TXPowerLevelStatus, CSmlDmAdapter::EOk);
|
|
2284 |
}
|
|
2285 |
else
|
|
2286 |
{
|
|
2287 |
iCallBack->SetStatusL(iWriteStatuses->TXPowerLevelStatus, CSmlDmAdapter::EError);
|
|
2288 |
}
|
|
2289 |
}
|
|
2290 |
|
|
2291 |
if ( iWriteSettings->allowRadioMeasurementsPresent )
|
|
2292 |
{
|
|
2293 |
_DBG_FILE("CGlobalWLANAdapter::StoreCommsDBParams(): write KWlanAllowRadioMeasurements");
|
|
2294 |
TRAPD( err, usrTable->WriteBoolL( TPtrC(WLAN_ALLOW_RADIO_MEASUREMENTS), iWriteSettings->allowRadioMeasurements ));
|
|
2295 |
if ( err == KErrNone)
|
|
2296 |
{
|
|
2297 |
iCallBack->SetStatusL(iWriteStatuses->allowRadioMeasurementsStatus, CSmlDmAdapter::EOk);
|
|
2298 |
}
|
|
2299 |
else
|
|
2300 |
{
|
|
2301 |
iCallBack->SetStatusL(iWriteStatuses->allowRadioMeasurementsStatus, CSmlDmAdapter::EError);
|
|
2302 |
}
|
|
2303 |
}
|
|
2304 |
|
|
2305 |
if ( iWriteSettings->powerSavingPresent )
|
|
2306 |
{
|
|
2307 |
_DBG_FILE("CGlobalWLANAdapter::StoreCommsDBParams(): write KWlanPowerSaving");
|
|
2308 |
TRAPD( err, usrTable->WriteBoolL( TPtrC(WLAN_POWER_MODE), iWriteSettings->powerSaving ));
|
|
2309 |
if ( err == KErrNone)
|
|
2310 |
{
|
|
2311 |
iCallBack->SetStatusL(iWriteStatuses->powerSavingStatus, CSmlDmAdapter::EOk);
|
|
2312 |
}
|
|
2313 |
else
|
|
2314 |
{
|
|
2315 |
iCallBack->SetStatusL(iWriteStatuses->powerSavingStatus, CSmlDmAdapter::EError);
|
|
2316 |
}
|
|
2317 |
}
|
|
2318 |
|
|
2319 |
_DBG_FILE("CGlobalWLANAdapter::StoreCommsDBParams(): end");
|
|
2320 |
User::LeaveIfError( usrTable->PutRecordChanges() ); // End and save changes.
|
|
2321 |
CleanupStack::PopAndDestroy( usrTable );
|
|
2322 |
CleanupStack::PopAndDestroy( db );
|
|
2323 |
return;
|
|
2324 |
|
|
2325 |
}
|
|
2326 |
|
|
2327 |
|
|
2328 |
// ------------------------------------------------------------------------------------------------
|
|
2329 |
// void CGlobalWLANAdapter::ReadCenRepParams( )
|
|
2330 |
// Reads parameters from central repository
|
|
2331 |
// ------------------------------------------------------------------------------------------------
|
|
2332 |
void CGlobalWLANAdapter::ReadCenRepParamsL()
|
|
2333 |
{
|
|
2334 |
|
|
2335 |
_DBG_FILE("CGlobalWLANAdapter::ReadCenRepParams(): begin");
|
|
2336 |
|
|
2337 |
TInt err = KErrNone;
|
|
2338 |
CRepository* repository = NULL;
|
|
2339 |
TBuf8<KInputMaxLength> value;
|
|
2340 |
TBuf8<KTypeMaxLength> type;
|
|
2341 |
TInt temp = 0;
|
|
2342 |
|
|
2343 |
// InternetConnectivityTest parameter is in a different cenRep than the other parameters
|
|
2344 |
// Write KWlanScanRate
|
|
2345 |
if ( iReadSettings->internetConnectivityTestPresent )
|
|
2346 |
{
|
|
2347 |
// This parameter is in the internet connectivity settings cenRep, open the repository
|
|
2348 |
repository = CRepository::NewL( KCRUidInternetConnectivitySettings );
|
|
2349 |
CleanupStack::PushL(repository);
|
|
2350 |
|
|
2351 |
value.Zero();
|
|
2352 |
type.Zero();
|
|
2353 |
|
|
2354 |
// if opening the cenrtral repository failed, then leave this function
|
|
2355 |
if ( repository == NULL )
|
|
2356 |
{
|
|
2357 |
User::LeaveIfError( KErrGeneral );
|
|
2358 |
}
|
|
2359 |
|
|
2360 |
err = repository->Get( KIctsTestPermission, temp );
|
|
2361 |
value.Num(temp);
|
|
2362 |
type.Append( KNSmlWLanInternetConnectivityTest );
|
|
2363 |
UpdateStatusAndResultL( iReadStatuses->internetConnectivityTestResult, iReadStatuses->internetConnectivityTestStatus,
|
|
2364 |
value, type, err );
|
|
2365 |
|
|
2366 |
CleanupStack::PopAndDestroy(repository);
|
|
2367 |
}
|
|
2368 |
|
|
2369 |
// The rest of the parameters are in WlanDeviceSettings cenRep
|
|
2370 |
repository = CRepository::NewL( KCRUidWlanDeviceSettingsRegistryId );
|
|
2371 |
CleanupStack::PushL(repository);
|
|
2372 |
|
|
2373 |
// if opening the cenrtral repository failed, then leave this function
|
|
2374 |
if ( repository == NULL )
|
|
2375 |
{
|
|
2376 |
User::LeaveIfError( KErrGeneral );
|
|
2377 |
}
|
|
2378 |
|
|
2379 |
if ( iReadSettings->MTUPresent )
|
|
2380 |
{
|
|
2381 |
value.Zero();
|
|
2382 |
type.Zero();
|
|
2383 |
err = repository->Get( KWlanMTU, temp );
|
|
2384 |
value.Num(temp);
|
|
2385 |
type.Append( KNSmlWLanMTU );
|
|
2386 |
UpdateStatusAndResultL( iReadStatuses->MTUResult, iReadStatuses->MTUStatus,
|
|
2387 |
value, type, err );
|
|
2388 |
}
|
|
2389 |
|
|
2390 |
// Write KWlanScanRate
|
|
2391 |
if ( iReadSettings->scanRatePresent )
|
|
2392 |
{
|
|
2393 |
value.Zero();
|
|
2394 |
type.Zero();
|
|
2395 |
err = repository->Get( KWlanScanRate, temp );
|
|
2396 |
value.Num(temp);
|
|
2397 |
type.Append( KNSmlWLanScanRate );
|
|
2398 |
UpdateStatusAndResultL( iReadStatuses->scanRateResult, iReadStatuses->scanRateStatus,
|
|
2399 |
value, type, err );
|
|
2400 |
}
|
|
2401 |
|
|
2402 |
// Write KWlanRcpiTrigger
|
|
2403 |
if ( iReadSettings->RCPITriggerPresent )
|
|
2404 |
{
|
|
2405 |
value.Zero();
|
|
2406 |
type.Zero();
|
|
2407 |
err = repository->Get( KWlanRcpiTrigger, temp );
|
|
2408 |
value.Num(temp);
|
|
2409 |
type.Append( KNSmlWLanRCPITrigger );
|
|
2410 |
UpdateStatusAndResultL( iReadStatuses->RCPITriggerResult, iReadStatuses->RCPITriggerStatus,
|
|
2411 |
value, type, err );
|
|
2412 |
}
|
|
2413 |
|
|
2414 |
// Write KWlanMinActiveChannelTime
|
|
2415 |
if ( iReadSettings->minActiveChannelTimePresent )
|
|
2416 |
{
|
|
2417 |
value.Zero();
|
|
2418 |
type.Zero();
|
|
2419 |
err = repository->Get( KWlanMinActiveChannelTime, temp );
|
|
2420 |
value.Num(temp);
|
|
2421 |
type.Append( KNSmlWLanMinActiveChannelTime );
|
|
2422 |
UpdateStatusAndResultL( iReadStatuses->minActiveChannelTimeResult, iReadStatuses->minActiveChannelTimeStatus,
|
|
2423 |
value, type, err );
|
|
2424 |
}
|
|
2425 |
|
|
2426 |
// Write KWlanMaxActiveChannelTime
|
|
2427 |
if ( iReadSettings->maxActiveChannelTimePresent )
|
|
2428 |
{
|
|
2429 |
value.Zero();
|
|
2430 |
type.Zero();
|
|
2431 |
err = repository->Get( KWlanMaxActiveChannelTime, temp );
|
|
2432 |
value.Num(temp);
|
|
2433 |
type.Append( KNSmlWLanMaxActiveChannelTime );
|
|
2434 |
UpdateStatusAndResultL( iReadStatuses->maxActiveChannelTimeResult, iReadStatuses->maxActiveChannelTimeStatus,
|
|
2435 |
value, type, err );
|
|
2436 |
}
|
|
2437 |
|
|
2438 |
// Write KWlanMaxTxMSDULifeTime
|
|
2439 |
if ( iReadSettings->maxTxMSDULifeTimePresent )
|
|
2440 |
{
|
|
2441 |
value.Zero();
|
|
2442 |
type.Zero();
|
|
2443 |
err = repository->Get( KWlanMaxTxMSDULifeTime, temp );
|
|
2444 |
value.Num(temp);
|
|
2445 |
type.Append( KNSmlWLanMaxTxMSDULifeTime );
|
|
2446 |
UpdateStatusAndResultL( iReadStatuses->maxTxMSDULifeTimeResult, iReadStatuses->maxTxMSDULifeTimeStatus,
|
|
2447 |
value, type, err );
|
|
2448 |
}
|
|
2449 |
|
|
2450 |
// Write KWlanScanExpirationTimer
|
|
2451 |
if ( iReadSettings->scanExpirationTimerPresent )
|
|
2452 |
{
|
|
2453 |
value.Zero();
|
|
2454 |
type.Zero();
|
|
2455 |
err = repository->Get( KWlanScanExpirationTimer, temp );
|
|
2456 |
value.Num(temp);
|
|
2457 |
type.Append( KNSmlWLanScanExpirationTimer );
|
|
2458 |
UpdateStatusAndResultL( iReadStatuses->scanExpirationTimerResult, iReadStatuses->scanExpirationTimerStatus,
|
|
2459 |
value, type, err );
|
|
2460 |
}
|
|
2461 |
|
|
2462 |
// Write KWlanUnloadDriverTimer
|
|
2463 |
if ( iReadSettings->unloadDriverTimerPresent )
|
|
2464 |
{
|
|
2465 |
value.Zero();
|
|
2466 |
type.Zero();
|
|
2467 |
err = repository->Get( KWlanUnloadDriverTimer, temp );
|
|
2468 |
value.Num(temp);
|
|
2469 |
type.Append( KNSmlWLanUnloadDriverTimer );
|
|
2470 |
UpdateStatusAndResultL( iReadStatuses->unloadDriverTimerResult, iReadStatuses->unloadDriverTimerStatus,
|
|
2471 |
value, type, err );
|
|
2472 |
}
|
|
2473 |
|
|
2474 |
// Write KWlanRoamTimer
|
|
2475 |
if ( iReadSettings->roamTimerPresent )
|
|
2476 |
{
|
|
2477 |
value.Zero();
|
|
2478 |
type.Zero();
|
|
2479 |
err = repository->Get( KWlanRoamTimer, temp );
|
|
2480 |
value.Num(temp);
|
|
2481 |
type.Append( KNSmlWLanRoamTimer );
|
|
2482 |
UpdateStatusAndResultL( iReadStatuses->roamTimerResult, iReadStatuses->roamTimerStatus,
|
|
2483 |
value, type, err );
|
|
2484 |
}
|
|
2485 |
|
|
2486 |
// Write KWlanRcpiDifference
|
|
2487 |
if ( iReadSettings->RCPIDifferencePresent )
|
|
2488 |
{
|
|
2489 |
value.Zero();
|
|
2490 |
type.Zero();
|
|
2491 |
type.Append( KNSmlWLanRCPIDifference );
|
|
2492 |
err = repository->Get( KWlanRcpiDifference, temp );
|
|
2493 |
value.Num(temp);
|
|
2494 |
UpdateStatusAndResultL( iReadStatuses->RCPIDifferenceResult, iReadStatuses->RCPIDifferenceStatus,
|
|
2495 |
value, type, err );
|
|
2496 |
}
|
|
2497 |
|
|
2498 |
// Write KWlanConnRegainTimer
|
|
2499 |
if ( iReadSettings->connRegainTimerPresent )
|
|
2500 |
{
|
|
2501 |
value.Zero();
|
|
2502 |
type.Zero();
|
|
2503 |
type.Append( KNSmlWLanConnRegainTimer );
|
|
2504 |
err = repository->Get( KWlanConnRegainTimer, temp );
|
|
2505 |
value.Num(temp);
|
|
2506 |
UpdateStatusAndResultL( iReadStatuses->connRegainTimerResult, iReadStatuses->connRegainTimerStatus,
|
|
2507 |
value, type, err );
|
|
2508 |
}
|
|
2509 |
|
|
2510 |
// Write KWlanMaxTriesToFindNw
|
|
2511 |
if ( iReadSettings->maxTriesToFindNwPresent )
|
|
2512 |
{
|
|
2513 |
value.Zero();
|
|
2514 |
type.Zero();
|
|
2515 |
err = repository->Get( KWlanMaxTriesToFindNw, temp );
|
|
2516 |
value.Num(temp);
|
|
2517 |
type.Append( KNSmlWLanMaxTriesToFindNw );
|
|
2518 |
UpdateStatusAndResultL( iReadStatuses->maxTriesToFindNwResult, iReadStatuses->maxTriesToFindNwStatus,
|
|
2519 |
value, type, err );
|
|
2520 |
}
|
|
2521 |
|
|
2522 |
// Write KWlanDelayBetweenFindNw
|
|
2523 |
if ( iReadSettings->delayBetweenFindNwPresent )
|
|
2524 |
{
|
|
2525 |
value.Zero();
|
|
2526 |
type.Zero();
|
|
2527 |
err = repository->Get( KWlanDelayBetweenFindNw, temp );
|
|
2528 |
value.Num(temp);
|
|
2529 |
type.Append( KNSmlWLanDelayBetweenFindNw );
|
|
2530 |
UpdateStatusAndResultL( iReadStatuses->delayBetweenFindNwResult, iReadStatuses->delayBetweenFindNwStatus,
|
|
2531 |
value, type, err );
|
|
2532 |
}
|
|
2533 |
|
|
2534 |
// Write KWlanMinPassiveChannelTime
|
|
2535 |
if ( iReadSettings->minPassiveChannelTimePresent )
|
|
2536 |
{
|
|
2537 |
value.Zero();
|
|
2538 |
type.Zero();
|
|
2539 |
err = repository->Get( KWlanMinPassiveChannelTime, temp );
|
|
2540 |
value.Num(temp);
|
|
2541 |
type.Append( KNSmlWLanRCPITrigger );
|
|
2542 |
UpdateStatusAndResultL( iReadStatuses->minPassiveChannelTimeResult, iReadStatuses->minPassiveChannelTimeStatus,
|
|
2543 |
value, type, err );
|
|
2544 |
}
|
|
2545 |
|
|
2546 |
// Write KWlanMaxPassiveChannelTime
|
|
2547 |
if ( iReadSettings->maxPassiveChannelTimePresent )
|
|
2548 |
{
|
|
2549 |
value.Zero();
|
|
2550 |
type.Zero();
|
|
2551 |
err = repository->Get( KWlanMaxPassiveChannelTime, temp );
|
|
2552 |
value.Num(temp);
|
|
2553 |
type.Append( KNSmlWLanMinPassiveChannelTime );
|
|
2554 |
UpdateStatusAndResultL( iReadStatuses->maxPassiveChannelTimeResult, iReadStatuses->maxPassiveChannelTimeStatus,
|
|
2555 |
value, type, err );
|
|
2556 |
}
|
|
2557 |
|
|
2558 |
// Write KWlanMaxApFailureCount
|
|
2559 |
if ( iReadSettings->maxApFailureCountPresent )
|
|
2560 |
{
|
|
2561 |
value.Zero();
|
|
2562 |
type.Zero();
|
|
2563 |
err = repository->Get( KWlanMaxApFailureCount, temp );
|
|
2564 |
value.Num(temp);
|
|
2565 |
type.Append( KNSmlWLanMaxApFailureCount );
|
|
2566 |
UpdateStatusAndResultL( iReadStatuses->maxApFailureCountResult, iReadStatuses->maxApFailureCountStatus,
|
|
2567 |
value, type, err );
|
|
2568 |
}
|
|
2569 |
|
|
2570 |
// Write KWlanLongBeaconFindCount
|
|
2571 |
if ( iReadSettings->longBeaconFindCountPresent )
|
|
2572 |
{
|
|
2573 |
value.Zero();
|
|
2574 |
type.Zero();
|
|
2575 |
err = repository->Get( KWlanLongBeaconFindCount, temp );
|
|
2576 |
value.Num(temp);
|
|
2577 |
type.Append( KNSmlWLanLongBeaconFindCount );
|
|
2578 |
UpdateStatusAndResultL( iReadStatuses->longBeaconFindCountResult, iReadStatuses->longBeaconFindCountStatus,
|
|
2579 |
value, type, err );
|
|
2580 |
}
|
|
2581 |
|
|
2582 |
// Write KWlanQosNullFrameInterval
|
|
2583 |
if ( iReadSettings->qosNullFrameIntervalPresent )
|
|
2584 |
{
|
|
2585 |
value.Zero();
|
|
2586 |
type.Zero();
|
|
2587 |
err = repository->Get( KWlanQosNullFrameInterval, temp );
|
|
2588 |
value.Num(temp);
|
|
2589 |
type.Append( KNSmlWLanQosNullFrameInterval );
|
|
2590 |
UpdateStatusAndResultL( iReadStatuses->qosNullFrameIntervalResult, iReadStatuses->qosNullFrameIntervalStatus,
|
|
2591 |
value, type, err );
|
|
2592 |
}
|
|
2593 |
|
|
2594 |
// Write KWlanQosNullFrameTimeout
|
|
2595 |
if ( iReadSettings->qosNullFrameTimeoutPresent )
|
|
2596 |
{
|
|
2597 |
value.Zero();
|
|
2598 |
type.Zero();
|
|
2599 |
err = repository->Get( KWlanQosNullFrameTimeout, temp );
|
|
2600 |
value.Num(temp);
|
|
2601 |
type.Append( KNSmlWLanQosNullFrameTimeout );
|
|
2602 |
UpdateStatusAndResultL( iReadStatuses->qosNullFrameTimeoutResult, iReadStatuses->qosNullFrameTimeoutStatus,
|
|
2603 |
value, type, err );
|
|
2604 |
}
|
|
2605 |
|
|
2606 |
// Cleanup
|
|
2607 |
CleanupStack::PopAndDestroy(repository);
|
|
2608 |
_DBG_FILE("CGlobalWLANAdapter::ReadCenRepParams(): end");
|
|
2609 |
return;
|
|
2610 |
|
|
2611 |
}
|
|
2612 |
|
|
2613 |
// ------------------------------------------------------------------------------------------------
|
|
2614 |
// void CGlobalWLANAdapter::UpdateStatusAndResultL( )
|
|
2615 |
// Reads parameters from cenrep and updates result/status
|
|
2616 |
// ------------------------------------------------------------------------------------------------
|
|
2617 |
void CGlobalWLANAdapter::UpdateStatusAndResultL( TInt aResult, TInt aStatus, TDesC8& aValue, TDesC8& aType, TInt aStoreErr )
|
|
2618 |
{
|
|
2619 |
|
|
2620 |
_DBG_FILE("CGlobalWLANAdapter::UpdateStatusAndResultL(): begin");
|
|
2621 |
|
|
2622 |
CBufBase *lObject = CBufFlat::NewL(KInputMaxLength);
|
|
2623 |
CleanupStack::PushL(lObject);
|
|
2624 |
|
|
2625 |
// If reading went ok, then we can set the results and statuses
|
|
2626 |
if ( aStoreErr == KErrNone )
|
|
2627 |
{
|
|
2628 |
lObject->InsertL(0, aValue);
|
|
2629 |
iCallBack->SetResultsL( aResult,*lObject,aType );
|
|
2630 |
iCallBack->SetStatusL( aStatus, CSmlDmAdapter::EOk);
|
|
2631 |
}
|
|
2632 |
else
|
|
2633 |
{
|
|
2634 |
iCallBack->SetStatusL( aStatus, CSmlDmAdapter::EError );
|
|
2635 |
}
|
|
2636 |
|
|
2637 |
_DBG_FILE("CGlobalWLANAdapter::UpdateStatusAndResultL(): end");
|
|
2638 |
CleanupStack::PopAndDestroy(lObject);
|
|
2639 |
return;
|
|
2640 |
}
|
|
2641 |
|
|
2642 |
// ------------------------------------------------------------------------------------------------
|
|
2643 |
// void CGlobalWLANAdapter::ReadCommsDBParams( )
|
|
2644 |
// Reads parameters from commsDB
|
|
2645 |
// ------------------------------------------------------------------------------------------------
|
|
2646 |
void CGlobalWLANAdapter::ReadCommsDBParamsL()
|
|
2647 |
{
|
|
2648 |
_DBG_FILE("CGlobalWLANAdapter::ReadCommsDBParams() begin" );
|
|
2649 |
|
|
2650 |
CCommsDatabase* db = CCommsDatabase::NewL();
|
|
2651 |
CleanupStack::PushL(db);
|
|
2652 |
|
|
2653 |
// User defined WLAN device settings table from Comms database
|
|
2654 |
CCommsDbTableView* usrTable;
|
|
2655 |
|
|
2656 |
// Open user settings.
|
|
2657 |
usrTable = db->OpenViewMatchingUintLC( TPtrC(WLAN_DEVICE_SETTINGS),
|
|
2658 |
TPtrC(WLAN_DEVICE_SETTINGS_TYPE),
|
|
2659 |
KWlanUserSettings );
|
|
2660 |
|
|
2661 |
TUint32 intVal;
|
|
2662 |
TBool boolVal = EFalse;
|
|
2663 |
TBuf8<KInputMaxLength> value;
|
|
2664 |
TBuf8<KTypeMaxLength> type;
|
|
2665 |
TInt err = KErrNone;
|
|
2666 |
TInt readErr = KErrNone;
|
|
2667 |
_LIT8(KTrue,"True");
|
|
2668 |
_LIT8(KFalse,"False");
|
|
2669 |
|
|
2670 |
// if record did not exist, then we don't do anything
|
|
2671 |
if ( usrTable == NULL )
|
|
2672 |
readErr = KErrGeneral;
|
|
2673 |
else
|
|
2674 |
readErr = usrTable->GotoFirstRecord();
|
|
2675 |
|
|
2676 |
// Check whether parameter was requested to be fetched
|
|
2677 |
if ( iReadSettings->backgroundScanIntervalPresent )
|
|
2678 |
{
|
|
2679 |
// The reading is done if the commdb record was opened successfully, otherwise the err
|
|
2680 |
// is updated so that the ReadAndSetStatus function can update thet status correctly
|
|
2681 |
if ( readErr == KErrNone )
|
|
2682 |
{
|
|
2683 |
TRAP( err, usrTable->ReadUintL( TPtrC(WLAN_BG_SCAN_INTERVAL), intVal ));
|
|
2684 |
}
|
|
2685 |
else
|
|
2686 |
{
|
|
2687 |
err=readErr;
|
|
2688 |
}
|
|
2689 |
|
|
2690 |
value.Zero();
|
|
2691 |
type.Zero();
|
|
2692 |
value.Num(intVal);
|
|
2693 |
type.Append( KNSmlWLanBackgroundScanInterval );
|
|
2694 |
UpdateStatusAndResultL( iReadStatuses->backgroundScanIntervalResult, iReadStatuses->backgroundScanIntervalStatus,
|
|
2695 |
value, type, err );
|
|
2696 |
}
|
|
2697 |
|
|
2698 |
if ( iReadSettings->useDefaultSettingsPresent )
|
|
2699 |
{
|
|
2700 |
if ( readErr == KErrNone )
|
|
2701 |
{
|
|
2702 |
TRAP( err, usrTable->ReadBoolL( TPtrC(WLAN_USE_DEFAULT_SETTINGS), boolVal ));
|
|
2703 |
}
|
|
2704 |
else
|
|
2705 |
{
|
|
2706 |
err=readErr;
|
|
2707 |
}
|
|
2708 |
|
|
2709 |
value.Zero();
|
|
2710 |
type.Zero();
|
|
2711 |
if ( boolVal == 0 )
|
|
2712 |
value.Copy(KFalse);
|
|
2713 |
else
|
|
2714 |
value.Copy(KTrue);
|
|
2715 |
|
|
2716 |
type.Append( KNSmlWLanUseDefaultSettings );
|
|
2717 |
_DBG_FILE("CGlobalWLANAdapter::ReadCommsDBParams() go set status" );
|
|
2718 |
UpdateStatusAndResultL( iReadStatuses->useDefaultSettingsResult, iReadStatuses->useDefaultSettingsStatus,
|
|
2719 |
value, type, err );
|
|
2720 |
}
|
|
2721 |
|
|
2722 |
if ( iReadSettings->longRetryLimitPresent )
|
|
2723 |
{
|
|
2724 |
if ( readErr == KErrNone )
|
|
2725 |
{
|
|
2726 |
TRAP( err, usrTable->ReadUintL( TPtrC(WLAN_LONG_RETRY), intVal ));
|
|
2727 |
}
|
|
2728 |
else
|
|
2729 |
{
|
|
2730 |
err = readErr;
|
|
2731 |
}
|
|
2732 |
|
|
2733 |
value.Zero();
|
|
2734 |
value.Num(intVal);
|
|
2735 |
type.Zero();
|
|
2736 |
type.Append( KNSmlWLanLongRetryLimit );
|
|
2737 |
UpdateStatusAndResultL( iReadStatuses->longRetryLimitResult, iReadStatuses->longRetryLimitStatus,
|
|
2738 |
value, type, err );
|
|
2739 |
}
|
|
2740 |
|
|
2741 |
if ( iReadSettings->shortRetryLimitPresent )
|
|
2742 |
{
|
|
2743 |
if ( readErr == KErrNone )
|
|
2744 |
{
|
|
2745 |
TRAP( err, usrTable->ReadUintL( TPtrC(WLAN_SHORT_RETRY), intVal ));
|
|
2746 |
}
|
|
2747 |
else
|
|
2748 |
{
|
|
2749 |
err = readErr;
|
|
2750 |
}
|
|
2751 |
|
|
2752 |
value.Zero();
|
|
2753 |
type.Zero();
|
|
2754 |
value.Num(intVal);
|
|
2755 |
type.Append( KNSmlWLanShortRetryLimit );
|
|
2756 |
UpdateStatusAndResultL( iReadStatuses->shortRetryLimitResult, iReadStatuses->shortRetryLimitStatus,
|
|
2757 |
value, type, err );
|
|
2758 |
}
|
|
2759 |
|
|
2760 |
if ( iReadSettings->RTSThresholdPresent )
|
|
2761 |
{
|
|
2762 |
if ( readErr == KErrNone )
|
|
2763 |
{
|
|
2764 |
TRAP( err, usrTable->ReadUintL( TPtrC(WLAN_RTS_THRESHOLD), intVal ));
|
|
2765 |
}
|
|
2766 |
else
|
|
2767 |
{
|
|
2768 |
err = readErr;
|
|
2769 |
}
|
|
2770 |
|
|
2771 |
value.Zero();
|
|
2772 |
type.Zero();
|
|
2773 |
value.Num(intVal);
|
|
2774 |
type.Append( KNSmlWLanRTSThreshold );
|
|
2775 |
UpdateStatusAndResultL( iReadStatuses->RTSThresholdResult, iReadStatuses->RTSThresholdStatus,
|
|
2776 |
value, type, err );
|
|
2777 |
}
|
|
2778 |
|
|
2779 |
if ( iReadSettings->TXPowerLevelPresent )
|
|
2780 |
{
|
|
2781 |
if ( readErr == KErrNone )
|
|
2782 |
{
|
|
2783 |
TRAP( err, usrTable->ReadUintL( TPtrC(NU_WLAN_TX_POWER_LEVEL), intVal ));
|
|
2784 |
}
|
|
2785 |
else
|
|
2786 |
{
|
|
2787 |
err = readErr;
|
|
2788 |
}
|
|
2789 |
|
|
2790 |
value.Zero();
|
|
2791 |
type.Zero();
|
|
2792 |
value.Num(intVal);
|
|
2793 |
type.Append( KNSmlWLanTXPowerLevel );
|
|
2794 |
UpdateStatusAndResultL( iReadStatuses->TXPowerLevelResult, iReadStatuses->TXPowerLevelStatus,
|
|
2795 |
value, type, err );
|
|
2796 |
}
|
|
2797 |
|
|
2798 |
if ( iReadSettings->allowRadioMeasurementsPresent )
|
|
2799 |
{
|
|
2800 |
if ( readErr == KErrNone )
|
|
2801 |
{
|
|
2802 |
TRAP( err, usrTable->ReadBoolL( TPtrC(WLAN_ALLOW_RADIO_MEASUREMENTS), boolVal ));
|
|
2803 |
}
|
|
2804 |
else
|
|
2805 |
{
|
|
2806 |
err = readErr;
|
|
2807 |
}
|
|
2808 |
|
|
2809 |
value.Zero();
|
|
2810 |
type.Zero();
|
|
2811 |
if ( boolVal )
|
|
2812 |
value.Copy(_L8("True"));
|
|
2813 |
else
|
|
2814 |
value.Copy(_L8("False"));
|
|
2815 |
|
|
2816 |
type.Append( KNSmlWLanAllowRadioMeasurements );
|
|
2817 |
UpdateStatusAndResultL( iReadStatuses->allowRadioMeasurementsResult, iReadStatuses->allowRadioMeasurementsStatus,
|
|
2818 |
value, type, err );
|
|
2819 |
}
|
|
2820 |
|
|
2821 |
if ( iReadSettings->powerSavingPresent )
|
|
2822 |
{
|
|
2823 |
if ( readErr == KErrNone )
|
|
2824 |
{
|
|
2825 |
TRAP( err, usrTable->ReadBoolL( TPtrC(WLAN_POWER_MODE), boolVal ));
|
|
2826 |
}
|
|
2827 |
else
|
|
2828 |
{
|
|
2829 |
err = readErr;
|
|
2830 |
}
|
|
2831 |
|
|
2832 |
value.Zero();
|
|
2833 |
type.Zero();
|
|
2834 |
if ( boolVal )
|
|
2835 |
value.Copy(_L8("True"));
|
|
2836 |
else
|
|
2837 |
value.Copy(_L8("False"));
|
|
2838 |
|
|
2839 |
type.Append( KNSmlWLanPowerSaving );
|
|
2840 |
UpdateStatusAndResultL( iReadStatuses->powerSavingResult, iReadStatuses->powerSavingStatus,
|
|
2841 |
value, type, err );
|
|
2842 |
}
|
|
2843 |
|
|
2844 |
CleanupStack::PopAndDestroy( usrTable );
|
|
2845 |
CleanupStack::PopAndDestroy( db );
|
|
2846 |
_DBG_FILE("CGlobalWLANAdapter::ReadCommsDBParams() end" );
|
|
2847 |
return;
|
|
2848 |
}
|
|
2849 |
|
|
2850 |
|
|
2851 |
|
|
2852 |
// ------------------------------------------------------------------------------------------------
|
|
2853 |
// TInt CGlobalWLANAdapter::NumOfUriSegs( const TDesC8& aUri )
|
|
2854 |
// Return count of URI segments of aUri
|
|
2855 |
// ------------------------------------------------------------------------------------------------
|
|
2856 |
TInt CGlobalWLANAdapter::NumOfUriSegs( const TDesC8& aUri )
|
|
2857 |
{
|
|
2858 |
_DBG_FILE("CGlobalWLANAdapter::NumOfUriSegs(): begin");
|
|
2859 |
|
|
2860 |
TInt count = 1;
|
|
2861 |
for( TInt i=0; i<aUri.Length(); i++ )
|
|
2862 |
{
|
|
2863 |
if( aUri[i] == '/' )
|
|
2864 |
count ++;
|
|
2865 |
}
|
|
2866 |
|
|
2867 |
_DBG_FILE("CGlobalWLANAdapter::NumOfUriSegs(): end");
|
|
2868 |
return count;
|
|
2869 |
}
|
|
2870 |
|
|
2871 |
|
|
2872 |
// ------------------------------------------------------------------------------------------------
|
|
2873 |
// TPtrC8 CGlobalWLANAdapter::GetLastUriSeg(const TDesC8& aURI)
|
|
2874 |
// Returns only the last uri segemnt
|
|
2875 |
// ------------------------------------------------------------------------------------------------
|
|
2876 |
TPtrC8 CGlobalWLANAdapter::GetLastUriSeg( const TDesC8& aURI )
|
|
2877 |
{
|
|
2878 |
_DBG_FILE("CGlobalWLANAdapter::GetLastUriSeg(): begin");
|
|
2879 |
|
|
2880 |
// search for the segment after the last slash
|
|
2881 |
TInt i;
|
|
2882 |
for( i = aURI.Length() - 1; i >= 0; i-- )
|
|
2883 |
{
|
|
2884 |
if( aURI[i] == '/' )
|
|
2885 |
{
|
|
2886 |
break;
|
|
2887 |
}
|
|
2888 |
}
|
|
2889 |
|
|
2890 |
if( i == 0 )
|
|
2891 |
{
|
|
2892 |
_DBG_FILE("CGlobalWLANAdapter::GetLastUriSeg(): end");
|
|
2893 |
return aURI;
|
|
2894 |
}
|
|
2895 |
else
|
|
2896 |
{
|
|
2897 |
_DBG_FILE("CGlobalWLANAdapter::GetLastUriSeg(): end");
|
|
2898 |
return aURI.Mid( i + 1 );
|
|
2899 |
}
|
|
2900 |
}
|
|
2901 |
|
|
2902 |
|
|
2903 |
// ------------------------------------------------------------------------------------------------
|
|
2904 |
// TInt CNSmlWLanAdapter::DesToInt( const TDesC8& aNumber )
|
|
2905 |
// Returns aLuid as integer value
|
|
2906 |
// ------------------------------------------------------------------------------------------------
|
|
2907 |
TInt CGlobalWLANAdapter::DesToInt( const TDesC8& aNumber )
|
|
2908 |
{
|
|
2909 |
_DBG_FILE("CGlobalWLANAdapter::DesToInt(): begin");
|
|
2910 |
|
|
2911 |
TInt err = KErrNone;
|
|
2912 |
TLex8 lex(aNumber);
|
|
2913 |
TInt value = 0;
|
|
2914 |
err = lex.Val( value );
|
|
2915 |
|
|
2916 |
DBG_ARGS8(_S8("CGlobalWLANAdapter::DesToInt() - Des: <%S> Int: <%D>"), &aNumber, value );
|
|
2917 |
_DBG_FILE("CGlobalWLANAdapter::DesToInt(): end");
|
|
2918 |
|
|
2919 |
// the input might have been illegal. Return error code if conversion failed.
|
|
2920 |
if ( err == KErrNone )
|
|
2921 |
return value;
|
|
2922 |
else
|
|
2923 |
return err;
|
|
2924 |
}
|
|
2925 |
|
|
2926 |
|
|
2927 |
// ------------------------------------------------------------------------------------------------
|
|
2928 |
// TInt CNSmlWLanAdapter::InitMemberVariables
|
|
2929 |
// Inits the member variable structures
|
|
2930 |
// ------------------------------------------------------------------------------------------------
|
|
2931 |
void CGlobalWLANAdapter::InitMemberVariables()
|
|
2932 |
{
|
|
2933 |
_DBG_FILE("CGlobalWLANAdapter::InitMemberVariables(): begin");
|
|
2934 |
|
|
2935 |
iWriteSettings->RCPITriggerPresent=EFalse;
|
|
2936 |
iWriteSettings->internetConnectivityTestPresent=EFalse;
|
|
2937 |
iWriteSettings->useDefaultSettingsPresent=EFalse;
|
|
2938 |
iWriteSettings->longRetryLimitPresent=EFalse;
|
|
2939 |
iWriteSettings->shortRetryLimitPresent=EFalse;
|
|
2940 |
iWriteSettings->RTSThresholdPresent=EFalse;
|
|
2941 |
iWriteSettings->TXPowerLevelPresent=EFalse;
|
|
2942 |
iWriteSettings->powerSavingPresent=EFalse;
|
|
2943 |
iWriteSettings->backgroundScanIntervalPresent=EFalse;
|
|
2944 |
iWriteSettings->scanRatePresent=EFalse;
|
|
2945 |
iWriteSettings->RCPITriggerPresent=EFalse;
|
|
2946 |
iWriteSettings->minActiveChannelTimePresent=EFalse;
|
|
2947 |
iWriteSettings->maxActiveChannelTimePresent=EFalse;
|
|
2948 |
iWriteSettings->maxTxMSDULifeTimePresent=EFalse;
|
|
2949 |
iWriteSettings->scanExpirationTimerPresent=EFalse;
|
|
2950 |
iWriteSettings->unloadDriverTimerPresent=EFalse;
|
|
2951 |
iWriteSettings->roamTimerPresent=EFalse;
|
|
2952 |
iWriteSettings->RCPIDifferencePresent=EFalse;
|
|
2953 |
iWriteSettings->connRegainTimerPresent=EFalse;
|
|
2954 |
iWriteSettings->maxTriesToFindNwPresent=EFalse;
|
|
2955 |
iWriteSettings->delayBetweenFindNwPresent=EFalse;
|
|
2956 |
iWriteSettings->allowRadioMeasurementsPresent=EFalse;
|
|
2957 |
iWriteSettings->minPassiveChannelTimePresent=EFalse;
|
|
2958 |
iWriteSettings->maxPassiveChannelTimePresent=EFalse;
|
|
2959 |
iWriteSettings->maxApFailureCountPresent=EFalse;
|
|
2960 |
iWriteSettings->longBeaconFindCountPresent=EFalse;
|
|
2961 |
iWriteSettings->qosNullFrameIntervalPresent=EFalse;
|
|
2962 |
iWriteSettings->qosNullFrameTimeoutPresent=EFalse;
|
|
2963 |
iWriteSettings->MTUPresent=EFalse;
|
|
2964 |
|
|
2965 |
iReadSettings->RCPITriggerPresent=EFalse;
|
|
2966 |
iReadSettings->internetConnectivityTestPresent=EFalse;
|
|
2967 |
iReadSettings->useDefaultSettingsPresent=EFalse;
|
|
2968 |
iReadSettings->longRetryLimitPresent=EFalse;
|
|
2969 |
iReadSettings->shortRetryLimitPresent=EFalse;
|
|
2970 |
iReadSettings->RTSThresholdPresent=EFalse;
|
|
2971 |
iReadSettings->TXPowerLevelPresent=EFalse;
|
|
2972 |
iReadSettings->powerSavingPresent=EFalse;
|
|
2973 |
iReadSettings->backgroundScanIntervalPresent=EFalse;
|
|
2974 |
iReadSettings->scanRatePresent=EFalse;
|
|
2975 |
iReadSettings->RCPITriggerPresent=EFalse;
|
|
2976 |
iReadSettings->minActiveChannelTimePresent=EFalse;
|
|
2977 |
iReadSettings->maxActiveChannelTimePresent=EFalse;
|
|
2978 |
iReadSettings->maxTxMSDULifeTimePresent=EFalse;
|
|
2979 |
iReadSettings->scanExpirationTimerPresent=EFalse;
|
|
2980 |
iReadSettings->unloadDriverTimerPresent=EFalse;
|
|
2981 |
iReadSettings->roamTimerPresent=EFalse;
|
|
2982 |
iReadSettings->RCPIDifferencePresent=EFalse;
|
|
2983 |
iReadSettings->connRegainTimerPresent=EFalse;
|
|
2984 |
iReadSettings->maxTriesToFindNwPresent=EFalse;
|
|
2985 |
iReadSettings->delayBetweenFindNwPresent=EFalse;
|
|
2986 |
iReadSettings->allowRadioMeasurementsPresent=EFalse;
|
|
2987 |
iReadSettings->minPassiveChannelTimePresent=EFalse;
|
|
2988 |
iReadSettings->maxPassiveChannelTimePresent=EFalse;
|
|
2989 |
iReadSettings->maxApFailureCountPresent=EFalse;
|
|
2990 |
iReadSettings->longBeaconFindCountPresent=EFalse;
|
|
2991 |
iReadSettings->qosNullFrameIntervalPresent=EFalse;
|
|
2992 |
iReadSettings->qosNullFrameTimeoutPresent=EFalse;
|
|
2993 |
iReadSettings->MTUPresent=EFalse;
|
|
2994 |
|
|
2995 |
_DBG_FILE("CGlobalWLANAdapter::InitMemberVariables(): begin");
|
|
2996 |
}
|
|
2997 |
|
|
2998 |
// end of file
|