harmony 鸿蒙Wi-Fi Subsystem Changelog
Wi-Fi Subsystem Changelog
cl.wifiManager.1 Change of the API Permissions
Involved APIs
API | Permission Before Change | Permission After Change |
---|---|---|
function getCandidateConfigs(): Array |
The location permission is required. | The location permission is not required. |
function getDeviceConfigs(): Array |
The location permission is required. | The location permission is not required. |
function getStations(): Array |
1. The location permission is required. 2. The physical MAC address is returned. |
1. The location permission is not required. 2. A random MAC address is returned (the GET_PEER_MAC permission is required if a real MAC address is returned). |
function getCurrentP2pGroup(): Promise |
The location permission is required. | The location permission is not required. |
function getCurrentP2pGroup(callback: AsyncCallback |
The location permission is required. | The location permission is not required. |
function getP2pPeerDevices(): Promise |
1. The location permission is required. 2. The physical MAC address is returned. |
1. The location permission is not required. 2. A random MAC address is returned (the GET_PEER_MAC permission is required if a real MAC address is returned). |
function getP2pPeerDevices(callback: AsyncCallback |
The location permission is required. | 1. The location permission is not required. 2. A random MAC address is returned (the GET_PEER_MAC permission is required if a real MAC address is returned). |
function p2pConnect(config: WifiP2PConfig): void; | The location permission is required. | The location permission is not required. |
function startDiscoverDevices(): void; | The location permission is required. | The location permission is not required. |
function getP2pGroups(): Promise |
The location permission is required. | The location permission is not required. |
function getP2pGroups(callback: AsyncCallback |
The location permission is required. | The location permission is not required. |
function on(type: “p2pDeviceChange”, callback: Callback |
1. The location permission is required. 2. The physical MAC address is returned. |
1. The location permission is not required. 2. A random MAC address is returned (the GET_PEER_MAC permission is required if a real MAC address is returned). |
function off(type: “p2pDeviceChange”, callback?: Callback |
1. The location permission is required. 2. The physical MAC address is returned. |
1. The location permission is not required. 2. A random MAC address is returned (the GET_PEER_MAC permission is required if a real MAC address is returned). |
function on(type: “p2pPeerDeviceChange”, callback: Callback |
1. The location permission is required. 2. The physical MAC address is returned. |
1. The location permission is not required. 2. A random MAC address is returned (the GET_PEER_MAC permission is required if a real MAC address is returned). |
function off(type: “p2pPeerDeviceChange”, callback?: Callback |
1. The location permission is required. 2. The physical MAC address is returned. |
1. The location permission is not required. 2. A random MAC address is returned (the GET_PEER_MAC permission is required if a real MAC address is returned). |
Change Impact If your application is developed using the involved APIs of earlier versions, apply for the required permissions for the new APIs.
Key API/Component Changes NA
Adaptation Guide Apply for the required permissions for the involved APIs.
cl.wifiManager.2 Change of the APIs Related to Wi-Fi Scan Capabilities
Deprecated scan(), getScanResults(), and getScanResultsSync(), and added new APIs to provide the related capabilities.
Change Impact The following APIs are deprecated since API 10, without affecting the compatibility of developed applications. However, you are advised to use new APIs.
Key API/Component Changes
|Deprecated API|New API|Description|
|————-|——————————————————–|———————–|
|function scan(): void;|function startScan(): void;|Use startScan to start Wi-Fi scan.|
|function getScanResults(): Promise
Adaptation Guide Use the new APIs.
你可能感兴趣的鸿蒙文章
harmony 鸿蒙ArkUI Subsystem Changelog
harmony 鸿蒙Application Access Control Subsystem Changelog
harmony 鸿蒙Account Subsystem Changelog
harmony 鸿蒙Bluetooth Subsystem Changelog
harmony 鸿蒙Bundle Management Subsystem Changelog
harmony 鸿蒙Security Subsystem Changelog
harmony 鸿蒙Graphics Subsystem Changelog
harmony 鸿蒙Input Method Framework Subsystem – Input Method Framework Service Changelog
- 所属分类: 后端技术
- 本文标签:
热门推荐
-
2、 - 优质文章
-
3、 gate.io
-
8、 golang
-
9、 openharmony
-
10、 Vue中input框自动聚焦