|
1 /* |
|
2 * Copyright (c) 2002-2005 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: Interface definition for WLAN scan results. |
|
15 * |
|
16 */ |
|
17 |
|
18 /* |
|
19 * %version: 11 % |
|
20 */ |
|
21 |
|
22 #ifndef WLANSCANINFOINTERFACE_H |
|
23 #define WLANSCANINFOINTERFACE_H |
|
24 |
|
25 // INCLUDES |
|
26 #include "wlanmgmtcommon.h" |
|
27 |
|
28 // DATA TYPES |
|
29 typedef TUint8 TWlanScanInfoFrame; |
|
30 |
|
31 // CLASS DECLARATION |
|
32 /** |
|
33 * @brief ECom interface class for WLAN scan results iterator. |
|
34 * |
|
35 * This class contains the methods for iterating through |
|
36 * WLAN scan results. |
|
37 * @since S60 3.0 |
|
38 */ |
|
39 class MWlanScanInfoIteratorBase |
|
40 { |
|
41 public: // Methods |
|
42 |
|
43 /** |
|
44 * Return the size of the scan info. The size includes Status Info, |
|
45 * MAC header and Frame Body. |
|
46 * @return The size of the scan info in bytes. |
|
47 */ |
|
48 virtual TUint16 Size() const = 0; |
|
49 |
|
50 /** |
|
51 * Find the data of the first access point. |
|
52 * @return Pointer at the beginning of the first access point stored |
|
53 * in the scan list. NULL if not any. |
|
54 */ |
|
55 virtual const TWlanScanInfoFrame* First() = 0; |
|
56 |
|
57 /** |
|
58 * Find the data of the next access point. |
|
59 * @return Pointer at the beginning of the next access point stored |
|
60 * in the scan list. NULL if not any. |
|
61 */ |
|
62 virtual const TWlanScanInfoFrame* Next() = 0; |
|
63 |
|
64 /** |
|
65 * Find the data of the current access point. |
|
66 * @return Pointer at the beginning of the current access point stored |
|
67 * in the scan list. NULL if not any. |
|
68 */ |
|
69 virtual const TWlanScanInfoFrame* Current() const = 0; |
|
70 |
|
71 /** |
|
72 * Find is there any more unhandled access points. |
|
73 * @return EFalse if there is access points in the list left, |
|
74 * ETrue if not. |
|
75 */ |
|
76 virtual TBool IsDone() const = 0; |
|
77 |
|
78 }; |
|
79 |
|
80 /** |
|
81 * @brief ECom interface class for WLAN scan results. |
|
82 * |
|
83 * This class contains the methods for parsing the scan results |
|
84 * of a WLAN network. |
|
85 * @since S60 3.0 |
|
86 */ |
|
87 class MWlanScanInfoBase |
|
88 { |
|
89 public: // Methods |
|
90 |
|
91 /** |
|
92 * Return RX level of the BSS. |
|
93 * @return RX level. |
|
94 */ |
|
95 virtual TUint8 RXLevel() const = 0; |
|
96 |
|
97 /** |
|
98 * Return BSSID of the BSS. |
|
99 * @param aBssid ID of the access point or IBSS network. |
|
100 * @return Pointer to the beginning of the BSSID. Length is always 6 bytes. |
|
101 */ |
|
102 virtual void Bssid( |
|
103 TWlanBssid& aBssid ) const = 0; |
|
104 |
|
105 /** |
|
106 * Get beacon interval of the BSS. |
|
107 * @return the beacon interval. |
|
108 */ |
|
109 virtual TUint16 BeaconInterval() const = 0; |
|
110 |
|
111 /** |
|
112 * Get capability of the BSS (see IEEE 802.11 section 7.3.1.4. |
|
113 * @return The capability information. |
|
114 */ |
|
115 virtual TUint16 Capability() const = 0; |
|
116 |
|
117 /** |
|
118 * Get security mode of the BSS. |
|
119 * @return security mode. |
|
120 * @deprecated This method is offered for backward compatibility reasons, |
|
121 * ExtendedSecurityMode() should be used instead. |
|
122 */ |
|
123 virtual TWlanConnectionSecurityMode SecurityMode() const = 0; |
|
124 |
|
125 /** |
|
126 * Return requested information element. |
|
127 * @param aIE Id of the requested IE data. |
|
128 * @param aLength Length of the IE. Zero if IE not found. |
|
129 * @param aData Pointer to the beginning of the IE data. NULL if IE not found. |
|
130 * @return General error message. |
|
131 */ |
|
132 virtual TInt InformationElement( |
|
133 TUint8 aIE, |
|
134 TUint8& aLength, |
|
135 const TUint8** aData ) = 0; |
|
136 |
|
137 /** |
|
138 * Return WPA information element. |
|
139 * @param aLength Length of the IE. Zero if IE not found. |
|
140 * @param aData Pointer to the beginning of the IE data. NULL if IE not found. |
|
141 * @return General error message. |
|
142 */ |
|
143 virtual TInt WpaIE( |
|
144 TUint8& aLength, |
|
145 const TUint8** aData ) = 0; |
|
146 |
|
147 /** |
|
148 * Return the first information element. |
|
149 * @param aIE Id of the IE. See IEEE 802.11 section 7.3.2. |
|
150 * @param aLength Length of the IE. Zero if IE not found. |
|
151 * @param aData Pointer to the beginning of the IE data. NULL if IE not found. |
|
152 * @return General error message. |
|
153 */ |
|
154 virtual TInt FirstIE( |
|
155 TUint8& aIE, |
|
156 TUint8& aLength, |
|
157 const TUint8** aData ) = 0; |
|
158 |
|
159 /** |
|
160 * Return next information element. |
|
161 * @param aIE Id of the IE. See IEEE 802.11 section 7.3.2. |
|
162 * @param aLength Length of the IE. Zero if IE not found. |
|
163 * @param aData Pointer to the beginning of the IE data. NULL if IE not found. |
|
164 * @return General error message. |
|
165 */ |
|
166 virtual TInt NextIE( |
|
167 TUint8& aIE, |
|
168 TUint8& aLength, |
|
169 const TUint8** aData ) = 0; |
|
170 |
|
171 /** |
|
172 * Find whether Wi-Fi Protected Setup is supported. |
|
173 * @return ETrue if AP supports Wi-Fi Protected Setup, |
|
174 * EFalse if not. |
|
175 */ |
|
176 virtual TBool IsProtectedSetupSupported() = 0; |
|
177 |
|
178 /** |
|
179 * Get security mode of the BSS. |
|
180 * @return security mode. |
|
181 */ |
|
182 virtual TWlanConnectionExtentedSecurityMode ExtendedSecurityMode() const = 0; |
|
183 |
|
184 }; |
|
185 |
|
186 #endif // WLANSCANINFOINTERFACE_H |
|
187 |
|
188 // End of File |