1 /* |
|
2 * Copyright (c) 2010 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: WPS Wizard: Wrapper for middleware calls |
|
15 * |
|
16 */ |
|
17 |
|
18 #ifndef CWPSACTIVERUNNER_H_ |
|
19 #define CWPSACTIVERUNNER_H_ |
|
20 |
|
21 // System includes |
|
22 #include <e32base.h> |
|
23 #include <wlanmgmtclient.h> |
|
24 |
|
25 // User includes |
|
26 #include "mwpsactiverunnercallback.h" |
|
27 |
|
28 // Forward declarations |
|
29 // External data types |
|
30 // Constants |
|
31 |
|
32 /*! |
|
33 * @addtogroup group_wps_wizard_plugin |
|
34 * @{ |
|
35 */ |
|
36 // Class declaration |
|
37 class CWpsActiveRunner : public CActive |
|
38 { |
|
39 public: |
|
40 static CWpsActiveRunner* NewL(MWpsActiveRunnerCallback& aObserver); |
|
41 virtual ~CWpsActiveRunner(); |
|
42 public: |
|
43 |
|
44 void RunL(); |
|
45 void DoCancel(); |
|
46 TInt RunError(TInt aError); |
|
47 void StartSetup(RBuf8& aSsid, int aPin); |
|
48 |
|
49 protected: |
|
50 |
|
51 private: |
|
52 explicit CWpsActiveRunner(MWpsActiveRunnerCallback& aObserver); |
|
53 void ConstructL(); |
|
54 void InitializeL(); |
|
55 private: |
|
56 |
|
57 //! observer for notification of WPS setup completion |
|
58 MWpsActiveRunnerCallback& iObserver; |
|
59 //! To know if cancel was called before the completion |
|
60 TBool isCancelTriggered; |
|
61 //! WLAN management client object |
|
62 CWlanMgmtClient* iWLANMgmtClient; |
|
63 //! Array to hold the results of the WPS setup |
|
64 CArrayFixSeg<TWlanProtectedSetupCredentialAttribute>* iIapParametersArray; |
|
65 |
|
66 friend class TestWlanWizardContext; |
|
67 }; |
|
68 |
|
69 #endif /* CWPSACTIVERUNNER_H_ */ |
|