# WLAN >**NOTE:** >The initial APIs of this module are supported since API version 6. Newly added APIs will be marked with a superscript to indicate their earliest API version. ## Modules to Import ``` import wifi from '@ohos.wifi'; ``` ## wifi.isWifiActive isWifiActive\(\): boolean Checks whether the WLAN is activated. - Return values
Returns true if the WLAN is activated; returns false otherwise. |
Returns true if the scan is successful; returns false otherwise. |
Promise< Array<WifiScanInfo> > |
Promise used to return the scan result, which is a list of hotspot information. |
AsyncCallback< Array<WifiScanInfo>> |
Callback invoked to return the scan result, which is a list of hotspot information. |
Received Signal Strength Indicator (RSSI) of the hotspot, in dBm. |
|||
Returns true if the WLAN is connected; returns false otherwise. |
Promise<WifiLinkedInfo> |
AsyncCallback<WifiLinkedInfo> |
Returns true if the feature is supported; returns false otherwise. |
Generic Advertisement Service (GAS)/Access Network Query Protocol (ANQP) feature. |
|
Callback used to report the WLAN state. If this parameter is not specified, all callbacks associated with the specified event will be unregistered. |
Callback used to report the WLAN connection state. If this parameter is not specified, all callbacks associated with the specified event will be unregistered. |
Callback used to report the WLAN scan state. If this parameter is not specified, all callbacks associated with the specified event will be unregistered. |
Callback used to report the RSSI. If this parameter is not specified, all callbacks associated with the specified event will be unregistered. |
Callback used to report the hotspot state. If this parameter is not specified, all callbacks associated with the specified event will be unregistered. |