wlan_bearer/wlanengine/wlan_symbian/wlanengine_symbian_3.1/inc/wlanbgscanawscomms.h
equal
deleted
inserted
replaced
14 * Description: Class implementing WLAN BgScan AWS communications |
14 * Description: Class implementing WLAN BgScan AWS communications |
15 * |
15 * |
16 */ |
16 */ |
17 |
17 |
18 /* |
18 /* |
19 * %version: 1 % |
19 * %version: 2 % |
20 */ |
20 */ |
21 |
21 |
22 #ifndef WLANBGSCANAWSCOMMS_H |
22 #ifndef WLANBGSCANAWSCOMMS_H |
23 #define WLANBGSCANAWSCOMMS_H |
23 #define WLANBGSCANAWSCOMMS_H |
24 |
24 |
38 * @since S60 S60 v5.2 |
38 * @since S60 S60 v5.2 |
39 */ |
39 */ |
40 NONSHARABLE_CLASS( CWlanBgScanAwsComms ) : |
40 NONSHARABLE_CLASS( CWlanBgScanAwsComms ) : |
41 public CActive, |
41 public CActive, |
42 public MAwsBgScanProvider, |
42 public MAwsBgScanProvider, |
43 public MWlanBgScanCommandListener |
43 public MWlanBgScanCommandListener, |
|
44 public MWlanBgScanAwsComms |
44 { |
45 { |
45 |
46 |
46 public: |
47 public: |
47 |
|
48 /** |
|
49 * AWS commands. |
|
50 */ |
|
51 enum TAwsCommand |
|
52 { |
|
53 EStart = 0, |
|
54 EStop, |
|
55 ESetPowerSaveMode, |
|
56 EAwsCommandMax //not a real command |
|
57 }; |
|
58 |
|
59 /** |
|
60 * AWS message. |
|
61 */ |
|
62 struct TAwsMessage |
|
63 { |
|
64 TAwsCommand iCmd; |
|
65 TInt iParameter; |
|
66 }; |
|
67 |
48 |
68 /** |
49 /** |
69 * Two-phased constructor. |
50 * Two-phased constructor. |
70 */ |
51 */ |
71 static CWlanBgScanAwsComms* NewL( CWlanBgScan& aBgScan ); |
52 static CWlanBgScanAwsComms* NewL( CWlanBgScan& aBgScan ); |
101 * |
82 * |
102 * @param aMessage Message to be sent |
83 * @param aMessage Message to be sent |
103 * @since S60 v5.2 |
84 * @since S60 v5.2 |
104 */ |
85 */ |
105 void SendOrQueueAwsCommand( TAwsMessage& aMessage ); |
86 void SendOrQueueAwsCommand( TAwsMessage& aMessage ); |
106 |
87 |
107 /** |
88 /** |
108 * Whether AWS is present in system. |
89 * Blocks calling thread until AWS is constructed. |
109 * |
90 * |
110 * @since S60 v5.2 |
91 * @since S60 v5.2 |
111 * @return ETrue if present, EFalse if not |
92 */ |
112 */ |
93 //void WaitForAwsStartupToComplete(); |
113 TBool IsAwsPresent(); |
|
114 |
94 |
115 private: // From CActive |
95 private: // From CActive |
116 |
96 |
117 /** |
97 /** |
118 * Handles an active object's request completion event. |
98 * Handles an active object's request completion event. |
167 * @return Symbian specific error code. |
147 * @return Symbian specific error code. |
168 */ |
148 */ |
169 static TInt AwsThreadEntryPoint( TAny* aThisPtr ); |
149 static TInt AwsThreadEntryPoint( TAny* aThisPtr ); |
170 |
150 |
171 /** |
151 /** |
172 * Instantiate AWS ECOM Plugin. |
152 * Instantiate and run AWS ECOM Plugin. |
173 */ |
153 */ |
174 void InstantiateAwsPluginL(); |
154 void InstantiateAndRunAwsPluginL(); |
175 |
155 |
176 /** |
156 /** |
177 * Send message to AWS. |
157 * Send message to AWS. |
178 * |
158 * |
179 * @param aMessage Message to be sent |
159 * @param aMessage Message to be sent |
192 * Reference to Adaptive WLAN Scanning component. |
172 * Reference to Adaptive WLAN Scanning component. |
193 */ |
173 */ |
194 CAwsEngineBase* iAws; |
174 CAwsEngineBase* iAws; |
195 |
175 |
196 /** |
176 /** |
197 * Reference to AWS ECOM plugin implementation info. |
177 * AWS ECOM plugin UID. |
198 */ |
178 */ |
199 CImplementationInformation* iAwsImplInfo; |
179 TInt iAwsImplUid; |
200 |
180 |
201 /** |
181 /** |
202 * Command Handler. |
182 * Command Handler. |
203 */ |
183 */ |
204 CWlanBgScanCommand* iCommandHandler; |
184 CWlanBgScanCommand* iCommandHandler; |
220 |
200 |
221 /** |
201 /** |
222 * If AWS instantiation was successful. |
202 * If AWS instantiation was successful. |
223 */ |
203 */ |
224 TBool iAwsOk; |
204 TBool iAwsOk; |
|
205 |
|
206 /** |
|
207 * Synchronization object between WLAN Engine and AWS threads. |
|
208 */ |
|
209 //RSemaphore iStartupLock; |
|
210 |
|
211 /** |
|
212 * Handle to WLAN Engine thread. |
|
213 */ |
|
214 RThread iWlanEngineThread; |
225 |
215 |
226 }; |
216 }; |
227 |
217 |
228 #endif // WLANBGSCANAWSCOMMS_H |
218 #endif // WLANBGSCANAWSCOMMS_H |