“74bc2ecfb5ca14d22eec1b6b8d476735067fa8db”上不存在“src/share/classes/sun/nio/fs/DynamicFileAttributeView.java”
提交 51afa37f 编写于 作者: G Gloria

Update docs against 21843+21847+21995+21967+21917

Signed-off-by: wusongqing<wusongqing@huawei.com>
上级 ce2c54fa
# OpenHarmony 4.0 Beta2
## Version Description
The standard system capabilities of OpenHarmony 4.0 are continuously improved. ArkUI further enhances the capabilities of basic components. The application framework supports ArkTS widget updates triggered by agents. The bundle manager subsystem supports data sharing across atomic services, as well as enterprise application installation. The DSoftBus subsystem supports session-level transmission capability negotiation. The Unified Data Management Framework (UDMF) supports temporary authorization for files in distributed directories in cross-device dragging scenarios. The file management subsystem supports device-cloud synchronization of public image files. The multimedia subsystem further enhances the audio, media playback, and audio/video codec capabilities. The graphics rendering library is upgraded to Skia 0310. The window component capability is enhanced. The common event and notification subsystem supports batch notification deletion. The security subsystem supports Digital Signature Algorithm (DSA). ArkCompiler Runtime supports JSContext and dynamic profile guided optimization (PGO). DFX provides a unified collection framework for easier application debugging.
## Feature Description
### Application Framework
- The content of an ArkTS widget can be updated through a data agent.
- Static configuration and static graph display are provided for ArkTS widgets.
### ArkUI
- **\<XComponent>** supports texture rendering. Popup positions can be customized, and popups can be closed layer by layer by pressing the **Esc** key. The **\<ListItem>** component supports the swipe-to-delete gesture, which means that users can long swipe left to delete an element. ArkTS/JS widgets support callbacks triggered upon the completion of rendering. The **\<Image>** and **\<Text>** components support obscuring. The **\<ContextMenu>** component supports segment-based display.
- The animation effect is enhanced, including the layout attribute, background image size and position, and show/hide attribute (implicit animation). **scrollToIndex** can be used to set animation effects for lists. Fuzzy animations are provided for tabs, and display/disappearance animations are provided for popups. Custom animations are also supported.
- Named routes are supported so that page-specific switching animations can be set. The lite ArkUI framework supports global data objects and data sharing between pages within an application.
- Global APIs support the stage model multiton scenario.
### Bundle Management
- APIs are provided to set and query the application distribution type and attachment information.
- Applications that can open a file are identified through the file name extension, implementing the mapping between a file name extension and an application.
- Enterprise applications can be installed. To install an application whose certificate type is **enterprise**, you must request the **ohos.permission.INSTALL_ENTERPRISE_BUNDLE** permission.
### Distributed Data Management
- The UDMF supports temporary authorization for files in distributed directories in cross-device dragging scenarios.
- RDB store NDK interfaces are provided. These interfaces are used for transaction addition, deletion, modification, and query, data encryption, hierarchical data protection, and backup and restore.
- The system can automatically selects a Bluetooth or Wi-Fi P2P channel for synchronization of key-value and distributed data objects based on the data volume.
### DSoftBus
- Management of soft bus link information is supported.
- Cross-device transmission capability negotiation is provided at the session level.
### Distributed Hardware
- The audio recording latency in distributed scenarios is optimized.
- The distributed file system supports mutual file access over Bluetooth P2P connections.
- A listener can be provided to listen for device name changes.
### File Management
- Public image files can be synchronized between the device and cloud (on the prerequisite that the cloud service is enabled for the login account of the device). Images on the cloud can be selected through the picker.
- Applications can customize the directories to be backed up.
- Public images can be managed by category. Users can classify user images through albums in Gallery.
- Applications can listen for the addition, modification, and deletion of files in the sandbox.
- Applications can share files in the sandbox across devices.
### Graphics & Window
**Graphics**
- APIs are provided to pick the color of a selected region in an image. Applications can use the APIs to select a region in an image and obtain its dominant color and average color value.
- APIs are provided to set the offset of the rotation center on the z-axis anchor point so that the rendered anchor point can be modified during rotation.
- The rendering library on which the graphics subsystem depends is upgraded to Skia 0310.
**Window**
- The way for obtaining the parameter values of the display module is optimized. Now actual parameter values are directly obtained from the hardware instead of the software.
- The window component capability is enhanced. The window supports window attributes, child windows, modal windows, window effects, window decoration, screen-on/screen-off, screenshot, and screen recording in component mode.
### Multimedia
**Audio**
- The sound effect framework is supported. Device vendors can configure sound effect policies and load custom sound effects. Applications can query, switch, or disable the sound effect mode.
- Intra-system recording is supported. Audio data played in the system can be filtered and recorded based on the audio scene attribute.
- The display name of the audio output device can be obtained from the playback object information.
**Media Playback**
Audio effect parameters can be configured.
**Audio/Video Codecs**
- Native APIs can be used to query the audio and video codecs of the system.
- Native APIs can be used to encapsulate audio and video data, that is, to store encoded media data in files in a certain format.
- Native APIs can be used to decapsulate audio and video data, that is, to extract media frame data from bit stream data.
### Common Event and Notification
- Notifications can be deleted in batches.
- The emitter supports unsubscription of condition-specific callbacks.
### Basic Communications
- The Wi-Fi module supports background scanning.
- The Wi-Fi module supports random MAC addresses in STA mode.
### Network and Communication
- A TCP socket can be used for communication with the server.
- Data transfer to a remote server is supported.
- HTTPS certificate management adaptation is supported.
- The NIC proxy is supported.
### System Service Management
- System services can be started as required, for example, called by external systems or triggered by events. System services can be automatically stopped when the device is idle.
- The system service configuration format is optimized by using the JSON format instead of the XML format.
### Power Supply
- New APIs are provided to enable the system to enter the sleep state immediately.
- Events and behavior can be customized based on the hibernation source.
- Wakeup events can be customized based on the wakeup source.
### Multimodal Input
- Original events of keyboard input devices are mapped to the intent event of normalized interaction, so that you do not need to pay attention to whether the input behavior comes from the touch or keyboard during application development.
- Users can customize the touchpad based on their use habits.
- Both the press and touch actions can be used to map a click on the left mouse button.
- Both of the following actions can be used to map a right-click on the mouse: touching the left or lower right corner, and pressing or touching the left or lower right corner with two fingers.
- 10 speed levels are supported.
- Both of the following actions can be used to map a scroll with mouse: content moving in the same direction as your finger moves, and content moving in the reverse direction as your finger moves.
### Theme Framework
- The lock screen management service supports lock screen event callbacks, static/dynamic wallpaper, and service status query when the screen is locked.
- The wallpaper management service allows users to customize and reset wallpapers, and lock/unlock the screen.
### Upload and Download
Users can query upload and download tasks, synchronize and query task status, persistently store task records, and rectify exceptions.
### Security
**Crypto Framework**
- DSA is supported.
- APIs are provided to parse DSA, Elliptic Curve Cryptography (ECC), and Rivest Shamir Adleman (RSA) keys and obtain key parameters.
- APIs are provided to obtain the algorithm type used to generate random numbers.
- APIs are provided to randomly generate, convert, encrypt, and decrypt SM4 keys.
- The Hash-based Message Authentication Code (HMAC) and hash capabilities are provided for SM3 keys.
- APIs are provided to randomly generate, convert, sign, verify, encrypt, and decrypt SM2 keys.
**Key Management**
- HUKS key encryption is supported.
- The service identity field of the key can be added to the Key Attestation public key certificate.
- Standard HDIs are provided.
**Mutual Authentication Between Devices**
Pseudonyms can be generated and identified in the following scenarios:
- Mutual authentication on multiple devices that use the same account to log in
- Mutual authentication on two devices that are connected in P2P mode using different accounts
### Ability Access Control
- The display of the permission management menu is optimized. The permission groups of media assets and files are split, and the authorization granularity of corresponding permissions is more refined.
- Compatibility with SELinux in the Treble architecture is supported.
### Account
- Third-party applications can use the account authorization capability.
- Management on domain account plugins is provided to support domain account management and authentication.
### WebView
- The web camera capability and HTML5 tag capabilities such as bindContextMenu, Select, and date input are supplemented.
- Multiple rendering processes can be split.
- Basic text and image dragging capabilities are provided.
- WebRTC video conferencing (excluding camera sharing) is supported.
- Independent SELinux labels are provided for rendering processes to enhance basic security.
### ArkCompiler
- ArkCompiler Runtime supports JSContext and dynamic PGO, which collects type and function hotspot information at runtime and generates AP files. The NAPI library can be dynamically imported and loaded.
- In type compilation mode of ArkCompiler, the front-end compilation toolchain is switched to es2abc.
- New APIs are provided for the NAPI buffer, object, arraybuffer, and object types.
- The task pool supports task interruption and cancellation, task group definition, task status and scheduling information dotting, and identification and recovery of tasks that wait for a long time.
- Different versions can be built for system users and user **root**. The user version supports Wukong and XTS.
- The compiler toolchain supports debugging of the previewer.
### DFX
- A unified collection framework is provided for application debugging.
- Unified trace collection is provided.
- Native HiTraceMeter APIs are provided.
- The performance radar provides tool classes for service modules (subsystems) to transfer performance tracing point records and settlement performance data in service processes.
### Kernel
Code execution permission control is enhanced as follows:
- Secure memory is supported.
- Scenario-specific code execution permission control policies are provided.
- Full lifecycle management is provided for code execution permission control.
- Executable files can be parsed to obtain code segment information.
- Integrity protection is provided for code pages.
### Driver
- The extended device driver framework provides the following capabilities:
- Based on the DriverExtensionAbility, the extended device driver framework builds lifecycle management capabilities, including developing, deploying, installing, updating, uninstalling, and running extended driver packages in the application state.
- USB device extension driver packages that are developed by third-party device vendors and do not comply with standard protocols can be installed on OpenHarmony devices. After such a USB device is inserted, the system can identify it and matches an extension driver package.
- Third-party applications can query and bind to a USB device extension driver package through the extended device management framework.
- The camera driver provides the following capabilities:
- Identifying USB camera hot swap events during startup check and after startup.
- Preview, photographing, and video recording of USB cameras, and query and configuration of the camera format and resolution.
- The codec driver provides hardware decoding acceleration for JPEG images, including obtaining hardware decoding information, initializing and deinitializing instances, decoding JPEG images, and applying for and releasing a buffer.
- The sensor driver provides driving for temperature and humidity sensors. It supports the query of temperature and humidity components of small-system devices, component enabling/disabling, and data query.
## Version Mapping
**Table 1** Version mapping of software and tools
| Software/Tool| Version| Remarks|
| -------- | -------- | -------- |
| OpenHarmony | 4.0 Beta2 | NA |
| Public SDK | Ohos_sdk_public 4.0.9.6 (API Version 10 Beta2) | This toolkit is intended for application developers and does not contain system APIs that require system permissions. It is provided as standard in DevEco Studio.|
| (Optional) HUAWEI DevEco Studio| 4.0 Beta2 | Recommended for developing OpenHarmony applications How to obtain:<br><br>SHA-256 checksum: ae9b228fb1f79e99441e10bdcf347ebfc42266be8b170bbce3c9764ba32d82a4<br><br>SHA-256 checksum: 5c9afc5b1262868b58376155f1e8576d33c1ade8b01091edc4d7d397cd34026c<br><br>SHA-256 checksum: ea6c98cafd5036e4a6fd46b0b1cde3a306953b1eef423d5940f1af7c632205d6 |
| (Optional) HUAWEI DevEco Device Tool| 4.0 Beta1 | Recommended for developing OpenHarmony smart devices How to obtain:<br>[Click here to go to the download page](https://device.harmonyos.com/cn/develop/ide#download).|
## Source Code Acquisition
### **Prerequisites**
1. Register your account with Gitee.
2. Register an SSH public key for access to Gitee.
3. Install the [git client](https://git-scm.com/book/en/v2/Getting-Started-Installing-Git) and [git-lfs](https://gitee.com/vcs-all-in-one/git-lfs?_from=gitee_search#downloading), and configure user information.
```
git config --global user.name "yourname"
git config --global user.email "your-email-address"
git config --global credential.helper store
```
4. Run the following commands to install the **repo** tool:
```
curl -s https://gitee.com/oschina/repo/raw/fork_flow/repo-py3 > /usr/local/bin/repo # If you do not have the permission, download the tool to another directory and configure it as an environment variable by running the chmod a+x /usr/local/bin/repo command.
pip3 install -i https://repo.huaweicloud.com/repository/pypi/simple requests
```
### Acquiring Source Code Using the repo Tool
**Method 1 (recommended)**
Use the **repo** tool to download the source code over SSH. (You must have an SSH public key for access to Gitee.)
- Obtain the source code from the version branch. You can obtain the latest source code of the version branch, which includes the code that has been incorporated into the branch up until the time you run the following commands:
```
repo init -u git@gitee.com:openharmony/manifest.git -b OpenHarmony-4.0-Beta2 --no-repo-verify
repo sync -c
repo forall -c 'git lfs pull'
```
- Obtain the source code from the version tag, which is the same as that released with the version.
```
repo init -u git@gitee.com:openharmony/manifest.git -b refs/tags/OpenHarmony-v4.0-Beta2 --no-repo-verify
repo sync -c
repo forall -c 'git lfs pull'
```
**Method 2**
Use the **repo** tool to download the source code over HTTPS.
- Obtain the source code from the version branch. You can obtain the latest source code of the version branch, which includes the code that has been incorporated into the branch up until the time you run the following commands:
```
repo init -u https://gitee.com/openharmony/manifest -b OpenHarmony-4.0-Beta2 --no-repo-verify
repo sync -c
repo forall -c 'git lfs pull'
```
- Obtain the source code from the version tag, which is the same as that released with the version.
```
repo init -u https://gitee.com/openharmony/manifest -b refs/tags/OpenHarmony-v4.0-Beta2 --no-repo-verify
repo sync -c
repo forall -c 'git lfs pull'
```
### Acquiring Source Code from Mirrors
**Table 2** Mirrors for acquiring source code
| Source Code | Version| **Site** | **SHA-256 Checksum** | Software Package Size|
| --------------------------------------- | ------------ | ------------------------------------------------------------ | ------------------------------------------------------------ | -------- |
| Full code base (for mini, small, and standard systems) | 4.0 Beta2 | [Download](https://repo.huaweicloud.com/openharmony/os/4.0-Beta2/code-v4.0-Beta2.tar.gz)| [Download](https://repo.huaweicloud.com/openharmony/os/4.0-Beta2/code-v4.0-Beta2.tar.gz.sha256)| 27.7 GB |
| Hi3861 solution (binary) | 4.0 Beta2 | [Download](https://repo.huaweicloud.com/openharmony/os/4.0-Beta2/hispark_pegasus.tar.gz)| [Download](https://repo.huaweicloud.com/openharmony/os/4.0-Beta2/hispark_pegasus.tar.gz.sha256)| 27.5 MB |
| Hi3516 solution-LiteOS (binary)| 4.0 Beta2 | [Download](https://repo.huaweicloud.com/openharmony/os/4.0-Beta2/hispark_taurus_LiteOS.tar.gz)| [Download](https://repo.huaweicloud.com/openharmony/os/4.0-Beta2/hispark_taurus_LiteOS.tar.gz.sha256)| 300.9 MB |
| Hi3516 solution-Linux (binary) | 4.0 Beta2 | [Download](https://repo.huaweicloud.com/openharmony/os/4.0-Beta2/hispark_taurus_Linux.tar.gz)| [Download](https://repo.huaweicloud.com/openharmony/os/4.0-Beta2/hispark_taurus_Linux.tar.gz.sha256)| 192.4 MB |
| RK3568 standard system solution (binary) | 4.0 Beta2 | [Download](https://repo.huaweicloud.com/openharmony/os/4.0-Beta2/dayu200_standard_arm32.tar.gz)| [Download](https://repo.huaweicloud.com/openharmony/os/4.0-Beta2/dayu200_standard_arm32.tar.gz.sha256)| 5.2 GB |
| Public SDK package for the standard system (macOS) | 4.0.9.6 | [Download](https://repo.huaweicloud.com/openharmony/os/4.0-Beta2/ohos-sdk-mac-public.tar.gz)| [Download](https://repo.huaweicloud.com/openharmony/os/4.0-Beta2/ohos-sdk-mac-public.tar.gz.sha256)| 832.3 MB |
| Public SDK package for the standard system (macOS-M1) | 4.0.9.6 | [Download](https://repo.huaweicloud.com/openharmony/os/4.0-Beta2/L2-SDK-MAC-M1-PUBLIC.tar.gz)| [Download](https://repo.huaweicloud.com/openharmony/os/4.0-Beta2/L2-SDK-MAC-M1-PUBLIC.tar.gz.sha256)| 788.4 MB |
| Public SDK package for the standard system (Windows\Linux) | 4.0.9.6 | [Download](https://repo.huaweicloud.com/openharmony/os/4.0-Beta2/ohos-sdk-windows_linux-public.tar.gz)| [Download](https://repo.huaweicloud.com/openharmony/os/4.0-Beta2/ohos-sdk-windows_linux-public.tar.gz.sha256)| 2.0 GB |
## What's New
This version has the following updates to OpenHarmony 4.0 Beta1.
### API
For details about the API changes over OpenHarmony 4.0 Beta1, see [API Differences](/api-diff/v4.0-beta2/Readme-EN.md). A few API changes may affect applications developed using API version 9 or earlier. For details about the change impact and adaptation guide, see [Changelogs](changelogs/v4.0-beta2/Readme-EN.md).
### Feature Updates
[Version Description](#version-description)
### Chip and Development Board Adaptation
For details about the adaptation status, see [SIG_DevBoard](https://gitee.com/openharmony/community/blob/master/sig/sig_devboard/sig_devboard.md).
### Samples
**Table 3** New samples
| Subsystem| Name| Introduction| Programming Language|
| -------- | -------- | -------- | -------- |
| Connectivity| [Upload and Download](https://gitee.com/openharmony/applications_app_samples/tree/OpenHarmony-4.0-Beta2/code/BasicFeature/Connectivity/UploadAndDownLoad)| This sample uses the **\@ohos.request** APIs to create and query upload and download tasks. In this sample, an HTTP File Server (HFS) functions as the server.| ArkTS |
| File management| [Application Access Data Backup and Restore](https://gitee.com/openharmony/applications_app_samples/tree/OpenHarmony-4.0-Beta2/code/BasicFeature/FileManagement/FileBackupExtension)<br>(Full SDK)| The BackupExtensionAbility enables an application to access the backup and restore framework.<br>**BackupExtensionAbility** is a derived class of **ExtensionAbility** in the stage model. You can modify the configuration file to customize the backup and restore framework behavior, including whether to allow backup and restore and specifying the files to be backed up.<br>This sample provides an application for the backup process to generate and display data.| ArkTS |
| Common event and notification| [Custom Badge](https://gitee.com/openharmony/applications_app_samples/tree/OpenHarmony-4.0-Beta2/code/BasicFeature/Notification/CustomNotificationBadge)| This sample shows how to use the **\@ohos.notificationManager** APIs to set a badge on the home screen and send and obtain notifications.| ArkTS |
| Common event and notification| [Custom Notification Push](https://gitee.com/openharmony/applications_app_samples/tree/OpenHarmony-4.0-Beta2/code/BasicFeature/Notification/CustomNotificationPush)<br>(Full SDK)| This sample shows how to use the **\@ohos.notificationManager** APIs to listen for callbacks to determine whether to send notifications. It implements notification filtering callback management.| ArkTS |
| NDK | [Native Xcomponent](https://gitee.com/openharmony/applications_app_samples/tree/master/code/BasicFeature/Native/NdkXComponent)<br>(Native SDK)| This sample shows how to use the native XComponent interface to obtain a **NativeWindow** instance, obtain the layout/event information, register an event callback, and draw shapes on the page through OpenGL/EGL. In this sample application, you can click the button to draw a pentagon and click the XComponent area to change the pentagon color.| Native C++ |
| Application Model| [Data Agent Widget - Database Update](https://gitee.com/openharmony/applications_app_samples/tree/OpenHarmony-4.0-Beta2/code/SystemFeature/ApplicationModels/PersistentProxyForm)<br>(Full SDK)| This sample shows a data agent widget. It uses the **\@ohos.application.DataShareExtensionAbility**, **\@ohos.data.dataShare**, and **\@ohos.data.dataSharePredicates** APIs to implement widget content updates along with RDB changes after widget subscription information is modified.| ArkTS |
| Application Model| [Data Agent Widget - Push Application Update](https://gitee.com/openharmony/applications_app_samples/tree/OpenHarmony-4.0-Beta2/code/SystemFeature/ApplicationModels/ProcessProxyForm)<br>(Full SDK)| This sample shows how to use the data agent widget in the push application form. It uses the **\@ohos.data.dataShare** APIs to modify subscription conditions of the data agent widget and publish the widget data.| ArkTS |
| Application Model| [Edit Application](https://gitee.com/openharmony/applications_app_samples/tree/OpenHarmony-4.0-Beta2/code/SystemFeature/ApplicationModels/Receiver)| This sample implements simple sharing, including sharing cancellation and completion, based on the UIExtension. In the sample application, you can touch **Return Share** to return to the calling application; you can also touch **Stay Edit App** to stay in the current application.| ArkTS |
| Application Model| [Initiating Application Sharing](https://gitee.com/openharmony/applications_app_samples/tree/OpenHarmony-4.0-Beta2/code/SystemFeature/ApplicationModels/Share)<br>(Full SDK)| This sample implements the initiation of sharing through the **Share** button. It provides two application icons: share demo and share edit. You can touch one of them to initiate sharing and redirect to the corresponding application.| ArkTS |
| Application Model| [Text Application](https://gitee.com/openharmony/applications_app_samples/tree/OpenHarmony-4.0-Beta2/code/SystemFeature/ApplicationModels/Template)<br>(Full SDK)| This sample implements simple sharing, including sharing cancellation and completion, based on the UIExtension. In the sample application, you can touch **Return Share** to return to the calling application; you can also touch **Stay Share Text** to stay in the current application.| ArkTS |
For more information, visit [Samples](https://gitee.com/openharmony/applications_app_samples).
## Resolved Issues
**Table 4** Resolved issues
| Issue No.| Description|
| -------- | -------- |
| I6U4ZT | The first photo in Gallery cannot be opened when the power supply is disconnected immediately after the photo is taken.|
| I79752 | There is a medium probability that the .ohos.smartperf thread of the com.ohos.smartperf process causes a C++ crash in libark_jsruntime.so.|
| I79P3K | There is a low probability that the onDestroy stack encounters a JS crash in the com.ohos.callui process.|
| I79TCB | There is a low probability that the VizCompositorTh thread of the com.ohos.note process causes a C++ crash in libweb_engine.soTh.|
| I78CBC | Memory leakage occurs in libace.z.so when a user touches an image folder in Gallery to browse images in grid form and then exits repeatedly.|
| I78CH7 | Memory leakage occurs in libace.z.so when applications are repeatedly added to or removed from the dock bar.|
## Known Issues
**Table 5** Known issues
| Issue No.| Description| Impact| To Be Resolved By|
| -------- | -------- | -------- | -------- |
| I78C9W | Memory leakage occurs in libace.z.so when a user touches an image in Gallery to maximize it and then exits repeatedly.| This operation scenario is uncommon, and the leak issue disappears after the application is restarted. The impact is controllable.| 2023-08-30|
| I7BF3M | During the long-term running test, the launcher process occasionally encounters app freezing because STRINGID:APPLICATION_BLOCK_INPUT is stuck in libeventhandler.z.so.| This issue does not cause the system to restart. The impact is controllable.| 2023-08-30|
| I7M51R | There is a low probability that a C++ crash occurs in the render_service thread of the com.ohos.systemui process.| The render_service thread will restart automatically. The impact is controllable.| 2023-08-30|
| I7NWF3 | Due to compatibility issues, the session fails to be enabled for a Wi-Fi P2P connection between a device running 3.2.x and a device running 4.0.x. | This issue does not occur when both devices run 4.0.x. The impact is controllable. | 2023-08-30 |
| I7BOAO | Multiple GLES3 test cases of the third-party repository fail to be executed. | The third-party vendor is carrying out adaptation. | 2023-08-30 |
...@@ -2,6 +2,7 @@ ...@@ -2,6 +2,7 @@
## OpenHarmony 4.x Releases ## OpenHarmony 4.x Releases
- [OpenHarmony v4.0 Beta2 (2023-08-02)](OpenHarmony-v4.0-beta2.md)
- [OpenHarmony v4.0 Beta1 (2023-06-03)](OpenHarmony-v4.0-beta1.md) - [OpenHarmony v4.0 Beta1 (2023-06-03)](OpenHarmony-v4.0-beta1.md)
## OpenHarmony 3.x Releases ## OpenHarmony 3.x Releases
......
# Readme
- [Ability framework](js-apidiff-ability.md)
- [Account subsystem](js-apidiff-account.md)
- [AI subsystem](js-apidiff-ai.md)
- [System Applications](js-apidiff-application.md)
- [ArkUI development framework](js-apidiff-arkui.md)
- [Power management subsystem](js-apidiff-battery.md)
- [Bundle management framework](js-apidiff-bundle.md)
- [Communication subsystem](js-apidiff-communication.md)
- [Compiler and runtime subsystem](js-apidiff-compiler-and-runtime.md)
- [Customization subsystem](js-apidiff-customization.md)
- [DFX subsystem](js-apidiff-dfx.md)
- [Distributed data management subsystem](js-apidiff-distributed-data.md)
- [Distributed hardware subsystem](js-apidiff-distributed-hardware.md)
- [Upload and download](js-apidiff-download-upload.md)
- [Driver subsystem](js-apidiff-driver.md)
- [File management subsystem](js-apidiff-file-management.md)
- [Geolocation subsystem](js-apidiff-geolocation.md)
- [Globalization subsystem](js-apidiff-global.md)
- [Misc services subsystem](js-apidiff-misc.md)
- [MSDP subsystem](js-apidiff-msdp.md)
- [Multimodal input subsystem](js-apidiff-multi-modal-input.md)
- [Multimedia subsystem](js-apidiff-multimedia.md)
- [Common event and notification subsystem](js-apidiff-notification.md)
- [Resource scheduler subsystem](js-apidiff-resource-scheduler.md)
- [Security subsystem](js-apidiff-security.md)
- [Pan-sensor subsystem](js-apidiff-sensor.md)
- [Startup subsystem](js-apidiff-start-up.md)
- [Telephony subsystem](js-apidiff-telephony.md)
- [Test subsystem](js-apidiff-unitest.md)
- [USB subsystem](js-apidiff-usb.md)
- [Web subsystem](js-apidiff-web.md)
- [Window manager subsystem](js-apidiff-window.md)
\ No newline at end of file
因为 它太大了无法显示 source diff 。你可以改为 查看blob
| Change Type | Old Version | New Version | d.ts File |
| ---- | ------ | ------ | -------- |
|Added|NA|Class name: AuthorizationExtensionAbility;<br>Method or attribute name: onStartAuthorization(request: AuthorizationRequest, callback: AuthorizationCallback): void;|@ohos.account.appAccount.AuthorizationExtensionAbility.d.ts|
|Added|NA|Class name: AuthorizationRequest;<br>Method or attribute name: readonly callerUid: number;|@ohos.account.appAccount.AuthorizationExtensionAbility.d.ts|
|Added|NA|Class name: AuthorizationRequest;<br>Method or attribute name: readonly parameters: appAccount.AccountCapabilityRequest;|@ohos.account.appAccount.AuthorizationExtensionAbility.d.ts|
|Added|NA|Class name: AuthorizationCallback;<br>Method or attribute name: onResult: AsyncCallback\<appAccount.AccountCapabilityResponse, { [key: string]: object }>;|@ohos.account.appAccount.AuthorizationExtensionAbility.d.ts|
|Added|NA|Class name: AccountCapabilityType;<br>Method or attribute name: AUTHORIZATION = 1|@ohos.account.appAccount.d.ts|
|Added|NA|Class name: AccountCapabilityProvider;<br>Method or attribute name: readonly capabilityType: AccountCapabilityType;|@ohos.account.appAccount.d.ts|
|Added|NA|Class name: AccountCapabilityProvider;<br>Method or attribute name: constructor(capabilityType: AccountCapabilityType);|@ohos.account.appAccount.d.ts|
|Added|NA|Class name: AuthorizationProvider;<br>Method or attribute name: constructor(info: AuthorizationProviderInfo);|@ohos.account.appAccount.d.ts|
|Added|NA|Class name: AuthorizationProviderInfo;<br>Method or attribute name: readonly bundleName: string;|@ohos.account.appAccount.d.ts|
|Added|NA|Class name: AuthorizationProviderInfo;<br>Method or attribute name: readonly abilityName: string;|@ohos.account.appAccount.d.ts|
|Added|NA|Class name: AccountCapabilityRequest;<br>Method or attribute name: constructor(provider: AccountCapabilityProvider);|@ohos.account.appAccount.d.ts|
|Added|NA|Class name: AccountCapabilityResponse;<br>Method or attribute name: readonly request: AccountCapabilityRequest;|@ohos.account.appAccount.d.ts|
|Added|NA|Class name: AccountCapabilityResponse;<br>Method or attribute name: constructor(request: AccountCapabilityRequest);|@ohos.account.appAccount.d.ts|
|Added|NA|Class name: AccountCapabilityScheduler;<br>Method or attribute name: executeRequest(<br> request: AccountCapabilityRequest,<br> callback: AsyncCallback\<AccountCapabilityResponse, { [key: string]: object }><br> ): void;|@ohos.account.appAccount.d.ts|
|Added|NA|Class name: AccountCapabilityScheduler;<br>Method or attribute name: executeRequest(request: AccountCapabilityRequest): Promise\<AccountCapabilityResponse>;|@ohos.account.appAccount.d.ts|
| Change Type | Old Version | New Version | d.ts File |
| ---- | ------ | ------ | -------- |
|Added|NA|Class name: mindSporeLite;<br>Method or attribute name: function loadModelFromFile(<br> model: string,<br> context?: Context): Promise\<Model>;|@ohos.ai.mindSporeLite.d.ts|
|Added|NA|Class name: mindSporeLite;<br>Method or attribute name: function loadModelFromFile(<br> model: string, callback: Callback\<Model>): void;|@ohos.ai.mindSporeLite.d.ts|
|Added|NA|Class name: mindSporeLite;<br>Method or attribute name: function loadModelFromFile(<br> model: string,<br> context: Context, callback: Callback\<Model>): void;|@ohos.ai.mindSporeLite.d.ts|
|Added|NA|Class name: mindSporeLite;<br>Method or attribute name: function loadModelFromBuffer(<br> model: ArrayBuffer,<br> context?: Context): Promise\<Model>;|@ohos.ai.mindSporeLite.d.ts|
|Added|NA|Class name: mindSporeLite;<br>Method or attribute name: function loadModelFromBuffer(<br> model: ArrayBuffer, callback: Callback\<Model>): void;|@ohos.ai.mindSporeLite.d.ts|
|Added|NA|Class name: mindSporeLite;<br>Method or attribute name: function loadModelFromBuffer(<br> model: ArrayBuffer,<br> context: Context, callback: Callback\<Model>): void;|@ohos.ai.mindSporeLite.d.ts|
|Added|NA|Class name: mindSporeLite;<br>Method or attribute name: function loadModelFromFd(<br> model: number,<br> context?: Context): Promise\<Model>;|@ohos.ai.mindSporeLite.d.ts|
|Added|NA|Class name: mindSporeLite;<br>Method or attribute name: function loadModelFromFd(<br> model: number, callback: Callback\<Model>): void;|@ohos.ai.mindSporeLite.d.ts|
|Added|NA|Class name: mindSporeLite;<br>Method or attribute name: function loadModelFromFd(<br> model: number,<br> context: Context, callback: Callback\<Model>): void;|@ohos.ai.mindSporeLite.d.ts|
|Added|NA|Class name: Model;<br>Method or attribute name: getInputs(): MSTensor[];|@ohos.ai.mindSporeLite.d.ts|
|Added|NA|Class name: Model;<br>Method or attribute name: predict(inputs: MSTensor[], callback: Callback\<MSTensor[]>): void;|@ohos.ai.mindSporeLite.d.ts|
|Added|NA|Class name: Model;<br>Method or attribute name: predict(inputs: MSTensor[]): Promise\<MSTensor[]>;|@ohos.ai.mindSporeLite.d.ts|
|Added|NA|Class name: Model;<br>Method or attribute name: resize(inputs: MSTensor[], dims: Array\<Array\<number>>): boolean;|@ohos.ai.mindSporeLite.d.ts|
|Added|NA|Class name: Context;<br>Method or attribute name: target?: string[];|@ohos.ai.mindSporeLite.d.ts|
|Added|NA|Class name: Context;<br>Method or attribute name: cpu?: CpuDevice;|@ohos.ai.mindSporeLite.d.ts|
|Added|NA|Class name: Context;<br>Method or attribute name: nnrt?: NNRTDevice;|@ohos.ai.mindSporeLite.d.ts|
|Added|NA|Class name: CpuDevice;<br>Method or attribute name: threadNum?: number;|@ohos.ai.mindSporeLite.d.ts|
|Added|NA|Class name: CpuDevice;<br>Method or attribute name: threadAffinityMode?: ThreadAffinityMode;|@ohos.ai.mindSporeLite.d.ts|
|Added|NA|Class name: CpuDevice;<br>Method or attribute name: threadAffinityCoreList?: number[];|@ohos.ai.mindSporeLite.d.ts|
|Added|NA|Class name: CpuDevice;<br>Method or attribute name: precisionMode?: string;|@ohos.ai.mindSporeLite.d.ts|
|Added|NA|Class name: ThreadAffinityMode;<br>Method or attribute name: NO_AFFINITIES = 0|@ohos.ai.mindSporeLite.d.ts|
|Added|NA|Class name: ThreadAffinityMode;<br>Method or attribute name: BIG_CORES_FIRST = 1|@ohos.ai.mindSporeLite.d.ts|
|Added|NA|Class name: ThreadAffinityMode;<br>Method or attribute name: LITTLE_CORES_FIRST = 2|@ohos.ai.mindSporeLite.d.ts|
|Added|NA|Class name: MSTensor;<br>Method or attribute name: name: string;|@ohos.ai.mindSporeLite.d.ts|
|Added|NA|Class name: MSTensor;<br>Method or attribute name: shape: number[];|@ohos.ai.mindSporeLite.d.ts|
|Added|NA|Class name: MSTensor;<br>Method or attribute name: elementNum: number;|@ohos.ai.mindSporeLite.d.ts|
|Added|NA|Class name: MSTensor;<br>Method or attribute name: dataSize: number;|@ohos.ai.mindSporeLite.d.ts|
|Added|NA|Class name: MSTensor;<br>Method or attribute name: dtype: DataType;|@ohos.ai.mindSporeLite.d.ts|
|Added|NA|Class name: MSTensor;<br>Method or attribute name: format: Format;|@ohos.ai.mindSporeLite.d.ts|
|Added|NA|Class name: MSTensor;<br>Method or attribute name: getData(): ArrayBuffer;|@ohos.ai.mindSporeLite.d.ts|
|Added|NA|Class name: MSTensor;<br>Method or attribute name: setData(inputArray: ArrayBuffer): void;|@ohos.ai.mindSporeLite.d.ts|
|Added|NA|Class name: DataType;<br>Method or attribute name: TYPE_UNKNOWN = 0|@ohos.ai.mindSporeLite.d.ts|
|Added|NA|Class name: DataType;<br>Method or attribute name: NUMBER_TYPE_INT8 = 32|@ohos.ai.mindSporeLite.d.ts|
|Added|NA|Class name: DataType;<br>Method or attribute name: NUMBER_TYPE_INT16 = 33|@ohos.ai.mindSporeLite.d.ts|
|Added|NA|Class name: DataType;<br>Method or attribute name: NUMBER_TYPE_INT32 = 34|@ohos.ai.mindSporeLite.d.ts|
|Added|NA|Class name: DataType;<br>Method or attribute name: NUMBER_TYPE_INT64 = 35|@ohos.ai.mindSporeLite.d.ts|
|Added|NA|Class name: DataType;<br>Method or attribute name: NUMBER_TYPE_UINT8 = 37|@ohos.ai.mindSporeLite.d.ts|
|Added|NA|Class name: DataType;<br>Method or attribute name: NUMBER_TYPE_UINT16 = 38|@ohos.ai.mindSporeLite.d.ts|
|Added|NA|Class name: DataType;<br>Method or attribute name: NUMBER_TYPE_UINT32 = 39|@ohos.ai.mindSporeLite.d.ts|
|Added|NA|Class name: DataType;<br>Method or attribute name: NUMBER_TYPE_UINT64 = 40|@ohos.ai.mindSporeLite.d.ts|
|Added|NA|Class name: DataType;<br>Method or attribute name: NUMBER_TYPE_FLOAT16 = 42|@ohos.ai.mindSporeLite.d.ts|
|Added|NA|Class name: DataType;<br>Method or attribute name: NUMBER_TYPE_FLOAT32 = 43|@ohos.ai.mindSporeLite.d.ts|
|Added|NA|Class name: DataType;<br>Method or attribute name: NUMBER_TYPE_FLOAT64 = 44|@ohos.ai.mindSporeLite.d.ts|
|Added|NA|Class name: Format;<br>Method or attribute name: DEFAULT_FORMAT = -1|@ohos.ai.mindSporeLite.d.ts|
|Added|NA|Class name: Format;<br>Method or attribute name: NCHW = 0|@ohos.ai.mindSporeLite.d.ts|
|Added|NA|Class name: Format;<br>Method or attribute name: NHWC = 1|@ohos.ai.mindSporeLite.d.ts|
|Added|NA|Class name: Format;<br>Method or attribute name: NHWC4 = 2|@ohos.ai.mindSporeLite.d.ts|
|Added|NA|Class name: Format;<br>Method or attribute name: HWKC = 3|@ohos.ai.mindSporeLite.d.ts|
|Added|NA|Class name: Format;<br>Method or attribute name: HWCK = 4|@ohos.ai.mindSporeLite.d.ts|
|Added|NA|Class name: Format;<br>Method or attribute name: KCHW = 5|@ohos.ai.mindSporeLite.d.ts|
| Change Type | Old Version | New Version | d.ts File |
| ---- | ------ | ------ | -------- |
|Added|NA|Class name: settings;<br>Method or attribute name: function getValue(context: Context, name: string, callback: AsyncCallback\<string>): void;|@ohos.settings.d.ts|
|Added|NA|Class name: settings;<br>Method or attribute name: function getValue(context: Context, name: string): Promise\<string>;|@ohos.settings.d.ts|
|Added|NA|Class name: settings;<br>Method or attribute name: function setValue(context: Context, name: string, value: string, callback: AsyncCallback\<boolean>): void;|@ohos.settings.d.ts|
|Added|NA|Class name: settings;<br>Method or attribute name: function setValue(context: Context, name: string, value: string): Promise\<boolean>;|@ohos.settings.d.ts|
|Added|NA|Class name: settings;<br>Method or attribute name: function getValueSync(context: Context, name: string, defValue: string): string;|@ohos.settings.d.ts|
|Added|NA|Class name: settings;<br>Method or attribute name: function setValueSync(context: Context, name: string, value: string): boolean;|@ohos.settings.d.ts|
|Deprecated version changed|Class name: settings;<br>Method or attribute name: function getURI(name: string): Promise\<object>;<br>Old version information: |Class name: settings;<br>Method or attribute name: function getURI(name: string): Promise\<object>;<br>New version information: 9<br>Substitute API: |@ohos.settings.d.ts|
|Deprecated version changed|Class name: settings;<br>Method or attribute name: function getValue(dataAbilityHelper: DataAbilityHelper, name: string): Promise\<object>;<br>Old version information: |Class name: settings;<br>Method or attribute name: function getValue(dataAbilityHelper: DataAbilityHelper, name: string): Promise\<object>;<br>New version information: 9<br>Substitute API: ohos.settings#getValue|@ohos.settings.d.ts|
|Deprecated version changed|Class name: settings;<br>Method or attribute name: function setValue(dataAbilityHelper: DataAbilityHelper, name: string, value: object): Promise\<boolean>;<br>Old version information: |Class name: settings;<br>Method or attribute name: function setValue(dataAbilityHelper: DataAbilityHelper, name: string, value: object): Promise\<boolean>;<br>New version information: 9<br>Substitute API: ohos.settings#setValue|@ohos.settings.d.ts|
|Error code added|Class name: call;<br>Method or attribute name: function makeCall(phoneNumber: string): Promise\<void>;<br>Old version information: |Class name: call;<br>Method or attribute name: function makeCall(phoneNumber: string): Promise\<void>;<br>New version information: 401,8300001,8300002,8300003,8300999|@ohos.telephony.call.d.ts|
|Access level changed|Class name: settings;<br>Method or attribute name: function setValue(dataAbilityHelper: DataAbilityHelper, name: string, value: object): Promise\<boolean>;<br>Old version information: |Class name: settings;<br>Method or attribute name: function setValue(dataAbilityHelper: DataAbilityHelper, name: string, value: object): Promise\<boolean>;<br>New version information: systemapi|@ohos.settings.d.ts|
|Model changed|Class name: settings;<br>Method or attribute name: function getValue(dataAbilityHelper: DataAbilityHelper, name: string, callback: AsyncCallback\<object>): void;<br>Old version information: FAModelOnly|Class name: settings;<br>Method or attribute name: function getValue(dataAbilityHelper: DataAbilityHelper, name: string, callback: AsyncCallback\<object>): void;<br>New version information: famodelonly|@ohos.settings.d.ts|
|Model changed|Class name: settings;<br>Method or attribute name: function getValue(dataAbilityHelper: DataAbilityHelper, name: string): Promise\<object>;<br>Old version information: |Class name: settings;<br>Method or attribute name: function getValue(dataAbilityHelper: DataAbilityHelper, name: string): Promise\<object>;<br>New version information: famodelonly|@ohos.settings.d.ts|
|Model changed|Class name: settings;<br>Method or attribute name: function setValue(dataAbilityHelper: DataAbilityHelper, name: string, value: object, callback: AsyncCallback\<boolean>): void;<br>Old version information: FAModelOnly|Class name: settings;<br>Method or attribute name: function setValue(dataAbilityHelper: DataAbilityHelper, name: string, value: object, callback: AsyncCallback\<boolean>): void;<br>New version information: famodelonly|@ohos.settings.d.ts|
|Model changed|Class name: settings;<br>Method or attribute name: function setValue(dataAbilityHelper: DataAbilityHelper, name: string, value: object): Promise\<boolean>;<br>Old version information: |Class name: settings;<br>Method or attribute name: function setValue(dataAbilityHelper: DataAbilityHelper, name: string, value: object): Promise\<boolean>;<br>New version information: famodelonly|@ohos.settings.d.ts|
|Model changed|Class name: settings;<br>Method or attribute name: function getValueSync(dataAbilityHelper: DataAbilityHelper, name: string, defValue: string): string;<br>Old version information: FAModelOnly|Class name: settings;<br>Method or attribute name: function getValueSync(dataAbilityHelper: DataAbilityHelper, name: string, defValue: string): string;<br>New version information: famodelonly|@ohos.settings.d.ts|
|Model changed|Class name: settings;<br>Method or attribute name: function setValueSync(dataAbilityHelper: DataAbilityHelper, name: string, value: string): boolean;<br>Old version information: FAModelOnly|Class name: settings;<br>Method or attribute name: function setValueSync(dataAbilityHelper: DataAbilityHelper, name: string, value: string): boolean;<br>New version information: famodelonly|@ohos.settings.d.ts|
因为 它太大了无法显示 source diff 。你可以改为 查看blob
| Change Type | Old Version | New Version | d.ts File |
| ---- | ------ | ------ | -------- |
|Added|NA|Class name: power;<br>Method or attribute name: function isStandby(): boolean;|@ohos.power.d.ts|
|Access level changed|Class name: ConsumptionType;<br>Method or attribute name: CONSUMPTION_TYPE_INVALID = -17<br>Old version information: |Class name: ConsumptionType;<br>Method or attribute name: CONSUMPTION_TYPE_INVALID = -17<br>New version information: systemapi|@ohos.batteryStatistics.d.ts|
|Access level changed|Class name: ConsumptionType;<br>Method or attribute name: CONSUMPTION_TYPE_APP<br>Old version information: |Class name: ConsumptionType;<br>Method or attribute name: CONSUMPTION_TYPE_APP<br>New version information: systemapi|@ohos.batteryStatistics.d.ts|
|Access level changed|Class name: ConsumptionType;<br>Method or attribute name: CONSUMPTION_TYPE_BLUETOOTH<br>Old version information: |Class name: ConsumptionType;<br>Method or attribute name: CONSUMPTION_TYPE_BLUETOOTH<br>New version information: systemapi|@ohos.batteryStatistics.d.ts|
|Access level changed|Class name: ConsumptionType;<br>Method or attribute name: CONSUMPTION_TYPE_IDLE<br>Old version information: |Class name: ConsumptionType;<br>Method or attribute name: CONSUMPTION_TYPE_IDLE<br>New version information: systemapi|@ohos.batteryStatistics.d.ts|
|Access level changed|Class name: ConsumptionType;<br>Method or attribute name: CONSUMPTION_TYPE_PHONE<br>Old version information: |Class name: ConsumptionType;<br>Method or attribute name: CONSUMPTION_TYPE_PHONE<br>New version information: systemapi|@ohos.batteryStatistics.d.ts|
|Access level changed|Class name: ConsumptionType;<br>Method or attribute name: CONSUMPTION_TYPE_RADIO<br>Old version information: |Class name: ConsumptionType;<br>Method or attribute name: CONSUMPTION_TYPE_RADIO<br>New version information: systemapi|@ohos.batteryStatistics.d.ts|
|Access level changed|Class name: ConsumptionType;<br>Method or attribute name: CONSUMPTION_TYPE_SCREEN<br>Old version information: |Class name: ConsumptionType;<br>Method or attribute name: CONSUMPTION_TYPE_SCREEN<br>New version information: systemapi|@ohos.batteryStatistics.d.ts|
|Access level changed|Class name: ConsumptionType;<br>Method or attribute name: CONSUMPTION_TYPE_USER<br>Old version information: |Class name: ConsumptionType;<br>Method or attribute name: CONSUMPTION_TYPE_USER<br>New version information: systemapi|@ohos.batteryStatistics.d.ts|
|Access level changed|Class name: ConsumptionType;<br>Method or attribute name: CONSUMPTION_TYPE_WIFI<br>Old version information: |Class name: ConsumptionType;<br>Method or attribute name: CONSUMPTION_TYPE_WIFI<br>New version information: systemapi|@ohos.batteryStatistics.d.ts|
|Access level changed|Class name: BatteryStatsInfo;<br>Method or attribute name: uid: number;<br>Old version information: |Class name: BatteryStatsInfo;<br>Method or attribute name: uid: number;<br>New version information: systemapi|@ohos.batteryStatistics.d.ts|
|Access level changed|Class name: BatteryStatsInfo;<br>Method or attribute name: type: ConsumptionType;<br>Old version information: |Class name: BatteryStatsInfo;<br>Method or attribute name: type: ConsumptionType;<br>New version information: systemapi|@ohos.batteryStatistics.d.ts|
|Access level changed|Class name: BatteryStatsInfo;<br>Method or attribute name: power: number;<br>Old version information: |Class name: BatteryStatsInfo;<br>Method or attribute name: power: number;<br>New version information: systemapi|@ohos.batteryStatistics.d.ts|
| Change Type | Old Version | New Version | d.ts File |
| ---- | ------ | ------ | -------- |
|Deleted|Class name: BusinessAbilityInfo;<br>Method or attribute name: readonly bundleName: string;|NA|BusinessAbilityInfo.d.ts|
|Deleted|Class name: BusinessAbilityInfo;<br>Method or attribute name: readonly moduleName: string;|NA|BusinessAbilityInfo.d.ts|
|Deleted|Class name: BusinessAbilityInfo;<br>Method or attribute name: readonly name: string;|NA|BusinessAbilityInfo.d.ts|
|Deleted|Class name: BusinessAbilityInfo;<br>Method or attribute name: readonly labelId: number;|NA|BusinessAbilityInfo.d.ts|
|Deleted|Class name: BusinessAbilityInfo;<br>Method or attribute name: readonly descriptionId: number;|NA|BusinessAbilityInfo.d.ts|
|Deleted|Class name: BusinessAbilityInfo;<br>Method or attribute name: readonly iconId: number;|NA|BusinessAbilityInfo.d.ts|
|Deleted|Class name: BusinessAbilityInfo;<br>Method or attribute name: readonly businessType: businessAbilityRouter.BusinessType;|NA|BusinessAbilityInfo.d.ts|
|Deleted|Class name: BusinessAbilityInfo;<br>Method or attribute name: readonly applicationInfo: ApplicationInfo;|NA|BusinessAbilityInfo.d.ts|
|Added|NA|Class name: bundleManager;<br>Method or attribute name: function getBundleInfoForSelfSync(bundleFlags: number): BundleInfo;|@ohos.bundle.bundleManager.d.ts|
|Added|NA|Class name: bundleManager;<br>Method or attribute name: function getSpecifiedDistributionType(bundleName: string): string;|@ohos.bundle.bundleManager.d.ts|
|Added|NA|Class name: bundleManager;<br>Method or attribute name: function getAdditionalInfo(bundleName: string): string;|@ohos.bundle.bundleManager.d.ts|
|Added|NA|Class name: ExtensionAbilityType;<br>Method or attribute name: PUSH = 17|@ohos.bundle.bundleManager.d.ts|
|Added|NA|Class name: ExtensionAbilityType;<br>Method or attribute name: APP_ACCOUNT_AUTHORIZATION = 19|@ohos.bundle.bundleManager.d.ts|
|Added|NA|Class name: VerifyCodeParam;<br>Method or attribute name: moduleName: string;|@ohos.bundle.installer.d.ts|
|Added|NA|Class name: VerifyCodeParam;<br>Method or attribute name: signatureFilePath: string;|@ohos.bundle.installer.d.ts|
|Added|NA|Class name: InstallParam;<br>Method or attribute name: specifiedDistributionType?: string;|@ohos.bundle.installer.d.ts|
|Added|NA|Class name: InstallParam;<br>Method or attribute name: additionalInfo?: string;|@ohos.bundle.installer.d.ts|
|Added|NA|Class name: InstallParam;<br>Method or attribute name: verifyCodeParams?: Array\<VerifyCodeParam>;|@ohos.bundle.installer.d.ts|
|Added|NA|Class name: ReqPermissionDetail;<br>Method or attribute name: moduleName: string;|BundleInfo.d.ts|
|Error code changed|Class name: BundleInstaller;<br>Method or attribute name: install(hapFilePaths: Array\<string>, installParam: InstallParam, callback: AsyncCallback\<void>): void;<br>Old version information: 201,202,401,17700004,17700010,17700011,17700012,17700015,17700016,17700017,17700018,17700031,17700036,17700039,17700041,17700042,17700043,17700044,17700047|Class name: BundleInstaller;<br>Method or attribute name: install(hapFilePaths: Array\<string>, installParam: InstallParam, callback: AsyncCallback\<void>): void;<br>New version information: 201,202,401,17700004,17700010,17700011,17700012,17700015,17700016,17700017,17700018,17700031,17700036,17700039,17700041,17700042,17700043,17700044,17700047,17700048|@ohos.bundle.installer.d.ts|
|Error code changed|Class name: BundleInstaller;<br>Method or attribute name: install(hapFilePaths: Array\<string>, callback: AsyncCallback\<void>): void;<br>Old version information: 201,202,401,17700010,17700011,17700012,17700015,17700016,17700017,17700018,17700031,17700036,17700039,17700041,17700042,17700043,17700044,17700047|Class name: BundleInstaller;<br>Method or attribute name: install(hapFilePaths: Array\<string>, callback: AsyncCallback\<void>): void;<br>New version information: 201,202,401,17700010,17700011,17700012,17700015,17700016,17700017,17700018,17700031,17700036,17700039,17700041,17700042,17700043,17700044,17700047,17700048|@ohos.bundle.installer.d.ts|
|Error code changed|Class name: BundleInstaller;<br>Method or attribute name: install(hapFilePaths: Array\<string>, installParam?: InstallParam): Promise\<void>;<br>Old version information: 201,202,401,17700004,17700010,17700011,17700012,17700015,17700016,17700017,17700018,17700031,17700036,17700039,17700041,17700042,17700043,17700044,17700047|Class name: BundleInstaller;<br>Method or attribute name: install(hapFilePaths: Array\<string>, installParam?: InstallParam): Promise\<void>;<br>New version information: 201,202,401,17700004,17700010,17700011,17700012,17700015,17700016,17700017,17700018,17700031,17700036,17700039,17700041,17700042,17700043,17700044,17700047,17700048|@ohos.bundle.installer.d.ts|
|Error code changed|Class name: zlib;<br>Method or attribute name: function decompressFile(inFile: string, outFile: string, options: Options, callback: AsyncCallback\<void>): void;<br>Old version information: 401,900001,900002|Class name: zlib;<br>Method or attribute name: function decompressFile(inFile: string, outFile: string, options: Options, callback: AsyncCallback\<void>): void;<br>New version information: 401,900001,900002,900003|@ohos.zlib.d.ts|
|Error code changed|Class name: zlib;<br>Method or attribute name: function decompressFile(inFile: string, outFile: string, options: Options): Promise\<void>;<br>Old version information: 401,900001,900002|Class name: zlib;<br>Method or attribute name: function decompressFile(inFile: string, outFile: string, options: Options): Promise\<void>;<br>New version information: 401,900001,900002,900003|@ohos.zlib.d.ts|
|Permission changed|Class name: bundleManager;<br>Method or attribute name: function getAllBundleInfo(bundleFlags: number, callback: AsyncCallback\<Array\<BundleInfo>>): void;<br>Old version information: ohos.permission.GET_BUNDLE_INFO_PRIVILEGED|Class name: bundleManager;<br>Method or attribute name: function getAllBundleInfo(bundleFlags: number, callback: AsyncCallback\<Array\<BundleInfo>>): void;<br>New version information: ohos.permission.GET_INSTALLED_BUNDLE_LIST|@ohos.bundle.bundleManager.d.ts|
|Permission changed|Class name: bundleManager;<br>Method or attribute name: function getAllBundleInfo(bundleFlags: number, userId: number, callback: AsyncCallback\<Array\<BundleInfo>>): void;<br>Old version information: ohos.permission.GET_BUNDLE_INFO_PRIVILEGED|Class name: bundleManager;<br>Method or attribute name: function getAllBundleInfo(bundleFlags: number, userId: number, callback: AsyncCallback\<Array\<BundleInfo>>): void;<br>New version information: ohos.permission.GET_INSTALLED_BUNDLE_LIST|@ohos.bundle.bundleManager.d.ts|
|Permission changed|Class name: bundleManager;<br>Method or attribute name: function getAllBundleInfo(bundleFlags: number, userId?: number): Promise\<Array\<BundleInfo>>;<br>Old version information: ohos.permission.GET_BUNDLE_INFO_PRIVILEGED|Class name: bundleManager;<br>Method or attribute name: function getAllBundleInfo(bundleFlags: number, userId?: number): Promise\<Array\<BundleInfo>>;<br>New version information: ohos.permission.GET_INSTALLED_BUNDLE_LIST|@ohos.bundle.bundleManager.d.ts|
|Permission changed|Class name: bundleManager;<br>Method or attribute name: function getAllApplicationInfo(appFlags: number, callback: AsyncCallback\<Array\<ApplicationInfo>>): void;<br>Old version information: ohos.permission.GET_BUNDLE_INFO_PRIVILEGED|Class name: bundleManager;<br>Method or attribute name: function getAllApplicationInfo(appFlags: number, callback: AsyncCallback\<Array\<ApplicationInfo>>): void;<br>New version information: ohos.permission.GET_INSTALLED_BUNDLE_LIST|@ohos.bundle.bundleManager.d.ts|
|Permission changed|Class name: bundleManager;<br>Method or attribute name: function getAllApplicationInfo(appFlags: number,<br><br> userId: number, callback: AsyncCallback\<Array\<ApplicationInfo>>): void;<br>Old version information: ohos.permission.GET_BUNDLE_INFO_PRIVILEGED|Class name: bundleManager;<br>Method or attribute name: function getAllApplicationInfo(appFlags: number,<br><br> userId: number, callback: AsyncCallback\<Array\<ApplicationInfo>>): void;<br>New version information: ohos.permission.GET_INSTALLED_BUNDLE_LIST|@ohos.bundle.bundleManager.d.ts|
|Permission changed|Class name: bundleManager;<br>Method or attribute name: function getAllApplicationInfo(appFlags: number, userId?: number): Promise\<Array\<ApplicationInfo>>;<br>Old version information: ohos.permission.GET_BUNDLE_INFO_PRIVILEGED|Class name: bundleManager;<br>Method or attribute name: function getAllApplicationInfo(appFlags: number, userId?: number): Promise\<Array\<ApplicationInfo>>;<br>New version information: ohos.permission.GET_INSTALLED_BUNDLE_LIST|@ohos.bundle.bundleManager.d.ts|
|Permission changed|Class name: BundleInstaller;<br>Method or attribute name: install(hapFilePaths: Array\<string>, installParam: InstallParam, callback: AsyncCallback\<void>): void;<br>Old version information: ohos.permission.INSTALL_BUNDLE|Class name: BundleInstaller;<br>Method or attribute name: install(hapFilePaths: Array\<string>, installParam: InstallParam, callback: AsyncCallback\<void>): void;<br>New version information: ohos.permission.INSTALL_BUNDLE,ohos.permission.INSTALL_ENTERPRISE_BUNDLE|@ohos.bundle.installer.d.ts|
|Permission changed|Class name: BundleInstaller;<br>Method or attribute name: install(hapFilePaths: Array\<string>, callback: AsyncCallback\<void>): void;<br>Old version information: ohos.permission.INSTALL_BUNDLE|Class name: BundleInstaller;<br>Method or attribute name: install(hapFilePaths: Array\<string>, callback: AsyncCallback\<void>): void;<br>New version information: ohos.permission.INSTALL_BUNDLE,ohos.permission.INSTALL_ENTERPRISE_BUNDLE|@ohos.bundle.installer.d.ts|
|Permission changed|Class name: BundleInstaller;<br>Method or attribute name: install(hapFilePaths: Array\<string>, installParam?: InstallParam): Promise\<void>;<br>Old version information: ohos.permission.INSTALL_BUNDLE|Class name: BundleInstaller;<br>Method or attribute name: install(hapFilePaths: Array\<string>, installParam?: InstallParam): Promise\<void>;<br>New version information: ohos.permission.INSTALL_BUNDLE,ohos.permission.INSTALL_ENTERPRISE_BUNDLE|@ohos.bundle.installer.d.ts|
|Model changed|Class name: AbilityType;<br>Method or attribute name: PAGE = 1<br>Old version information: |Class name: AbilityType;<br>Method or attribute name: PAGE = 1<br>New version information: FAModelOnly|@ohos.bundle.bundleManager.d.ts|
|Model changed|Class name: AbilityType;<br>Method or attribute name: SERVICE = 2<br>Old version information: |Class name: AbilityType;<br>Method or attribute name: SERVICE = 2<br>New version information: FAModelOnly|@ohos.bundle.bundleManager.d.ts|
|Model changed|Class name: AbilityType;<br>Method or attribute name: DATA = 3<br>Old version information: |Class name: AbilityType;<br>Method or attribute name: DATA = 3<br>New version information: FAModelOnly|@ohos.bundle.bundleManager.d.ts|
| Change Type | Old Version | New Version | d.ts File |
| ---- | ------ | ------ | -------- |
|Deleted|Class name: wifiManager;<br>Method or attribute name: function getScanInfoList(): Array\<WifiScanInfo>;|NA|@ohos.wifiManager.d.ts|
|Deleted|Class name: wifiManager;<br>Method or attribute name: function updateDeviceConfig(config: WifiDeviceConfig): number;|NA|@ohos.wifiManager.d.ts|
|Deleted|Class name: wifiManager;<br>Method or attribute name: function disableDeviceConfig(networkId: number): void;|NA|@ohos.wifiManager.d.ts|
|Deleted|Class name: wifiManager;<br>Method or attribute name: function removeAllDeviceConfigs(): void;|NA|@ohos.wifiManager.d.ts|
|Deleted|Class name: wifiManager;<br>Method or attribute name: function removeDeviceConfig(networkId: number): void;|NA|@ohos.wifiManager.d.ts|
|Deleted|Class name: wifiManager;<br>Method or attribute name: function getHotspotStations(): Array\<StationInfo>;|NA|@ohos.wifiManager.d.ts|
|Deleted|Class name: wifiManager;<br>Method or attribute name: function createP2pGroup(config: WifiP2PConfig): void;|NA|@ohos.wifiManager.d.ts|
|Deleted|Class name: wifiManager;<br>Method or attribute name: function removeP2pGroup(): void;|NA|@ohos.wifiManager.d.ts|
|Deleted|Class name: wifiManager;<br>Method or attribute name: function startDiscoverP2pDevices(): void;|NA|@ohos.wifiManager.d.ts|
|Deleted|Class name: wifiManager;<br>Method or attribute name: function stopDiscoverP2pDevices(): void;|NA|@ohos.wifiManager.d.ts|
|Deleted|Class name: wifiManager;<br>Method or attribute name: function deletePersistentP2pGroup(netId: number): void;|NA|@ohos.wifiManager.d.ts|
|Deleted|Class name: wifiManager;<br>Method or attribute name: function setP2pDeviceName(devName: string): void;|NA|@ohos.wifiManager.d.ts|
|Added|NA|Class name: TCPSocketConnection;<br>Method or attribute name: close(): Promise\<void>;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TLSSocketConnection;<br>Method or attribute name: close(): Promise\<void>;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TCPSocketServer;<br>Method or attribute name: getState(): Promise\<SocketStateBase>;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TLSSocketServer;<br>Method or attribute name: getState(): Promise\<SocketStateBase>;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TCPSocketConnection;<br>Method or attribute name: send(options: TCPSendOptions): Promise\<void>;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TCPSocketConnection;<br>Method or attribute name: getRemoteAddress(): Promise\<NetAddress>;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TLSSocketConnection;<br>Method or attribute name: getRemoteAddress(): Promise\<NetAddress>;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TCPSocketServer;<br>Method or attribute name: setExtraOptions(options: TCPExtraOptions): Promise\<void>;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TLSSocketServer;<br>Method or attribute name: setExtraOptions(options: TCPExtraOptions): Promise\<void>;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TLSSocketServer;<br>Method or attribute name: getCertificate(): Promise\<X509CertRawData>;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TLSSocketConnection;<br>Method or attribute name: getRemoteCertificate(): Promise\<X509CertRawData>;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TLSSocketServer;<br>Method or attribute name: getProtocol(): Promise\<string>;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TLSSocketConnection;<br>Method or attribute name: getCipherSuite(): Promise\<Array\<string>>;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TLSSocketConnection;<br>Method or attribute name: getSignatureAlgorithms(): Promise\<Array\<string>>;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TLSSocketConnection;<br>Method or attribute name: send(data: string): Promise\<void>;|@ohos.net.socket.d.ts|
|Added|NA|Class name: bluetoothManager;<br>Method or attribute name: function pairCredibleDevice(deviceId: string, transport: BluetoothTransport, callback: AsyncCallback\<void>): void;|@ohos.bluetoothManager.d.ts|
|Added|NA|Class name: bluetoothManager;<br>Method or attribute name: function pairCredibleDevice(deviceId: string, transport: BluetoothTransport): Promise\<void>;|@ohos.bluetoothManager.d.ts|
|Added|NA|Class name: bluetoothManager;<br>Method or attribute name: function getRemoteProfileUuids(device: string, callback: AsyncCallback\<Array\<ProfileUuids>>): void;|@ohos.bluetoothManager.d.ts|
|Added|NA|Class name: bluetoothManager;<br>Method or attribute name: function getRemoteProfileUuids(device: string): Promise\<Array\<ProfileUuids>>;|@ohos.bluetoothManager.d.ts|
|Added|NA|Class name: bluetoothManager;<br>Method or attribute name: function getLocalProfileUuids(callback: AsyncCallback\<Array\<ProfileUuids>>): void;|@ohos.bluetoothManager.d.ts|
|Added|NA|Class name: bluetoothManager;<br>Method or attribute name: function getLocalProfileUuids(): Promise\<Array\<ProfileUuids>>;|@ohos.bluetoothManager.d.ts|
|Added|NA|Class name: BaseProfile;<br>Method or attribute name: setConnectionStrategy(device: string, strategy: ConnectionStrategy, callback: AsyncCallback\<void>): void;|@ohos.bluetoothManager.d.ts|
|Added|NA|Class name: BaseProfile;<br>Method or attribute name: setConnectionStrategy(device: string, strategy: ConnectionStrategy): Promise\<void>;|@ohos.bluetoothManager.d.ts|
|Added|NA|Class name: BaseProfile;<br>Method or attribute name: getConnectionStrategy(device: string, callback: AsyncCallback\<ConnectionStrategy>): void;|@ohos.bluetoothManager.d.ts|
|Added|NA|Class name: BaseProfile;<br>Method or attribute name: getConnectionStrategy(device: string): Promise\<ConnectionStrategy>;|@ohos.bluetoothManager.d.ts|
|Added|NA|Class name: AdvertiseData;<br>Method or attribute name: includeDeviceName?: boolean;|@ohos.bluetoothManager.d.ts|
|Added|NA|Class name: BluetoothTransport;<br>Method or attribute name: TRANSPORT_BR_EDR = 0|@ohos.bluetoothManager.d.ts|
|Added|NA|Class name: BluetoothTransport;<br>Method or attribute name: TRANSPORT_LE = 1|@ohos.bluetoothManager.d.ts|
|Added|NA|Class name: ConnectionStrategy;<br>Method or attribute name: CONNECT_STRATEGY_UNSUPPORTED = 0|@ohos.bluetoothManager.d.ts|
|Added|NA|Class name: ConnectionStrategy;<br>Method or attribute name: CONNECT_STRATEGY_ALLOWED = 1|@ohos.bluetoothManager.d.ts|
|Added|NA|Class name: ConnectionStrategy;<br>Method or attribute name: CONNECT_STRATEGY_FORBIDDEN = 2|@ohos.bluetoothManager.d.ts|
|Added|NA|Class name: ProfileUuids;<br>Method or attribute name: PROFILE_UUID_HFP_AG = '0000111F-0000-1000-8000-00805F9B34FB'|@ohos.bluetoothManager.d.ts|
|Added|NA|Class name: ProfileUuids;<br>Method or attribute name: PROFILE_UUID_HFP_HF = '0000111E-0000-1000-8000-00805F9B34FB'|@ohos.bluetoothManager.d.ts|
|Added|NA|Class name: ProfileUuids;<br>Method or attribute name: PROFILE_UUID_HSP_AG = '00001112-0000-1000-8000-00805F9B34FB'|@ohos.bluetoothManager.d.ts|
|Added|NA|Class name: ProfileUuids;<br>Method or attribute name: PROFILE_UUID_HSP_HS = '00001108-0000-1000-8000-00805F9B34FB'|@ohos.bluetoothManager.d.ts|
|Added|NA|Class name: ProfileUuids;<br>Method or attribute name: PROFILE_UUID_A2DP_SRC = '0000110A-0000-1000-8000-00805F9B34FB'|@ohos.bluetoothManager.d.ts|
|Added|NA|Class name: ProfileUuids;<br>Method or attribute name: PROFILE_UUID_A2DP_SINK = '0000110B-0000-1000-8000-00805F9B34FB'|@ohos.bluetoothManager.d.ts|
|Added|NA|Class name: ProfileUuids;<br>Method or attribute name: PROFILE_UUID_AVRCP_CT = '0000110E-0000-1000-8000-00805F9B34FB'|@ohos.bluetoothManager.d.ts|
|Added|NA|Class name: ProfileUuids;<br>Method or attribute name: PROFILE_UUID_AVRCP_TG = '0000110C-0000-1000-8000-00805F9B34FB'|@ohos.bluetoothManager.d.ts|
|Added|NA|Class name: ProfileUuids;<br>Method or attribute name: PROFILE_UUID_HID = '00001124-0000-1000-8000-00805F9B34FB'|@ohos.bluetoothManager.d.ts|
|Added|NA|Class name: ProfileUuids;<br>Method or attribute name: PROFILE_UUID_HOGP = '00001812-0000-1000-8000-00805F9B34FB'|@ohos.bluetoothManager.d.ts|
|Added|NA|Class name: connection;<br>Method or attribute name: function getDefaultHttpProxy(callback: AsyncCallback\<HttpProxy>): void;|@ohos.net.connection.d.ts|
|Added|NA|Class name: connection;<br>Method or attribute name: function getDefaultHttpProxy(): Promise\<HttpProxy>;|@ohos.net.connection.d.ts|
|Added|NA|Class name: ethernet;<br>Method or attribute name: type HttpProxy = connection.HttpProxy;|@ohos.net.ethernet.d.ts|
|Added|NA|Class name: InterfaceConfiguration;<br>Method or attribute name: httpProxy?: HttpProxy;|@ohos.net.ethernet.d.ts|
|Added|NA|Class name: DiscoveryService;<br>Method or attribute name: off(type: 'discoveryStart', callback?: Callback\<{ serviceInfo: LocalServiceInfo, errorCode?: MdnsError }>): void;|@ohos.net.mdns.d.ts|
|Added|NA|Class name: DiscoveryService;<br>Method or attribute name: off(type: 'discoveryStop', callback?: Callback\<{ serviceInfo: LocalServiceInfo, errorCode?: MdnsError }>): void;|@ohos.net.mdns.d.ts|
|Added|NA|Class name: DiscoveryService;<br>Method or attribute name: off(type: 'serviceFound', callback?: Callback\<LocalServiceInfo>): void;|@ohos.net.mdns.d.ts|
|Added|NA|Class name: DiscoveryService;<br>Method or attribute name: off(type: 'serviceLost', callback?: Callback\<LocalServiceInfo>): void;|@ohos.net.mdns.d.ts|
|Added|NA|Class name: policy;<br>Method or attribute name: type NetBearType = connection.NetBearType;|@ohos.net.policy.d.ts|
|Added|NA|Class name: policy;<br>Method or attribute name: function setBackgroundAllowed(isAllowed: boolean, callback: AsyncCallback\<void>): void;|@ohos.net.policy.d.ts|
|Added|NA|Class name: policy;<br>Method or attribute name: function setBackgroundAllowed(isAllowed: boolean): Promise\<void>;|@ohos.net.policy.d.ts|
|Added|NA|Class name: policy;<br>Method or attribute name: function isBackgroundAllowed(callback: AsyncCallback\<boolean>): void;|@ohos.net.policy.d.ts|
|Added|NA|Class name: policy;<br>Method or attribute name: function isBackgroundAllowed(): Promise\<boolean>;|@ohos.net.policy.d.ts|
|Added|NA|Class name: policy;<br>Method or attribute name: function getBackgroundPolicyByUid(uid: number, callback: AsyncCallback\<NetBackgroundPolicy>): void;|@ohos.net.policy.d.ts|
|Added|NA|Class name: policy;<br>Method or attribute name: function getBackgroundPolicyByUid(uid: number): Promise\<NetBackgroundPolicy>;|@ohos.net.policy.d.ts|
|Added|NA|Class name: policy;<br>Method or attribute name: function setPolicyByUid(uid: number, policy: NetUidPolicy, callback: AsyncCallback\<void>): void;|@ohos.net.policy.d.ts|
|Added|NA|Class name: policy;<br>Method or attribute name: function setPolicyByUid(uid: number, policy: NetUidPolicy): Promise\<void>;|@ohos.net.policy.d.ts|
|Added|NA|Class name: policy;<br>Method or attribute name: function getPolicyByUid(uid: number, callback: AsyncCallback\<NetUidPolicy>): void;|@ohos.net.policy.d.ts|
|Added|NA|Class name: policy;<br>Method or attribute name: function getPolicyByUid(uid: number): Promise\<NetUidPolicy>;|@ohos.net.policy.d.ts|
|Added|NA|Class name: policy;<br>Method or attribute name: function getUidsByPolicy(policy: NetUidPolicy, callback: AsyncCallback\<Array\<number>>): void;|@ohos.net.policy.d.ts|
|Added|NA|Class name: policy;<br>Method or attribute name: function getUidsByPolicy(policy: NetUidPolicy): Promise\<Array\<number>>;|@ohos.net.policy.d.ts|
|Added|NA|Class name: policy;<br>Method or attribute name: function isUidNetAllowed(uid: number, isMetered: boolean, callback: AsyncCallback\<boolean>): void;|@ohos.net.policy.d.ts|
|Added|NA|Class name: policy;<br>Method or attribute name: function isUidNetAllowed(uid: number, isMetered: boolean): Promise\<boolean>;|@ohos.net.policy.d.ts|
|Added|NA|Class name: policy;<br>Method or attribute name: function isUidNetAllowed(uid: number, iface: string, callback: AsyncCallback\<boolean>): void;|@ohos.net.policy.d.ts|
|Added|NA|Class name: policy;<br>Method or attribute name: function isUidNetAllowed(uid: number, iface: string): Promise\<boolean>;|@ohos.net.policy.d.ts|
|Added|NA|Class name: policy;<br>Method or attribute name: function setNetQuotaPolicies(quotaPolicies: Array\<NetQuotaPolicy>, callback: AsyncCallback\<void>): void;|@ohos.net.policy.d.ts|
|Added|NA|Class name: policy;<br>Method or attribute name: function setNetQuotaPolicies(quotaPolicies: Array\<NetQuotaPolicy>): Promise\<void>;|@ohos.net.policy.d.ts|
|Added|NA|Class name: policy;<br>Method or attribute name: function getNetQuotaPolicies(callback: AsyncCallback\<Array\<NetQuotaPolicy>>): void;|@ohos.net.policy.d.ts|
|Added|NA|Class name: policy;<br>Method or attribute name: function getNetQuotaPolicies(): Promise\<Array\<NetQuotaPolicy>>;|@ohos.net.policy.d.ts|
|Added|NA|Class name: policy;<br>Method or attribute name: function updateRemindPolicy(netType: NetBearType, simId: string, remindType: RemindType, callback: AsyncCallback\<void>): void;|@ohos.net.policy.d.ts|
|Added|NA|Class name: policy;<br>Method or attribute name: function updateRemindPolicy(netType: NetBearType, simId: string, remindType: RemindType): Promise\<void>;|@ohos.net.policy.d.ts|
|Added|NA|Class name: policy;<br>Method or attribute name: function setDeviceIdleTrustlist(uids: Array\<number>, isAllowed: boolean, callback: AsyncCallback\<void>): void;|@ohos.net.policy.d.ts|
|Added|NA|Class name: policy;<br>Method or attribute name: function setDeviceIdleTrustlist(uids: Array\<number>, isAllowed: boolean): Promise\<void>;|@ohos.net.policy.d.ts|
|Added|NA|Class name: policy;<br>Method or attribute name: function getDeviceIdleTrustlist(callback: AsyncCallback\<Array\<number>>): void;|@ohos.net.policy.d.ts|
|Added|NA|Class name: policy;<br>Method or attribute name: function getDeviceIdleTrustlist(): Promise\<Array\<number>>;|@ohos.net.policy.d.ts|
|Added|NA|Class name: policy;<br>Method or attribute name: function setPowerSaveTrustlist(uids: Array\<number>, isAllowed: boolean, callback: AsyncCallback\<void>): void;|@ohos.net.policy.d.ts|
|Added|NA|Class name: policy;<br>Method or attribute name: function setPowerSaveTrustlist(uids: Array\<number>, isAllowed: boolean): Promise\<void>;|@ohos.net.policy.d.ts|
|Added|NA|Class name: policy;<br>Method or attribute name: function getPowerSaveTrustlist(callback: AsyncCallback\<Array\<number>>): void;|@ohos.net.policy.d.ts|
|Added|NA|Class name: policy;<br>Method or attribute name: function getPowerSaveTrustlist(): Promise\<Array\<number>>;|@ohos.net.policy.d.ts|
|Added|NA|Class name: policy;<br>Method or attribute name: function resetPolicies(simId: string, callback: AsyncCallback\<void>): void;|@ohos.net.policy.d.ts|
|Added|NA|Class name: policy;<br>Method or attribute name: function resetPolicies(simId: string): Promise\<void>;|@ohos.net.policy.d.ts|
|Added|NA|Class name: policy;<br>Method or attribute name: function on(type: 'netUidPolicyChange', callback: Callback\<{ uid: number, policy: NetUidPolicy }>): void;|@ohos.net.policy.d.ts|
|Added|NA|Class name: policy;<br>Method or attribute name: function on(type: 'netUidRuleChange', callback: Callback\<{ uid: number, rule: NetUidRule }>): void;|@ohos.net.policy.d.ts|
|Added|NA|Class name: policy;<br>Method or attribute name: function on(type: 'netMeteredIfacesChange', callback: Callback\<Array\<string>>): void;|@ohos.net.policy.d.ts|
|Added|NA|Class name: policy;<br>Method or attribute name: function on(type: 'netQuotaPolicyChange', callback: Callback\<Array\<NetQuotaPolicy>>): void;|@ohos.net.policy.d.ts|
|Added|NA|Class name: policy;<br>Method or attribute name: function on(type: 'netBackgroundPolicyChange', callback: Callback\<boolean>): void;|@ohos.net.policy.d.ts|
|Added|NA|Class name: policy;<br>Method or attribute name: function off(type: 'netUidPolicyChange', callback?: Callback\<{ uid: number, policy: NetUidPolicy }>): void;|@ohos.net.policy.d.ts|
|Added|NA|Class name: policy;<br>Method or attribute name: function off(type: 'netUidRuleChange', callback?: Callback\<{ uid: number, rule: NetUidRule }>): void;|@ohos.net.policy.d.ts|
|Added|NA|Class name: policy;<br>Method or attribute name: function off(type: 'netMeteredIfacesChange', callback?: Callback\<Array\<string>>): void;|@ohos.net.policy.d.ts|
|Added|NA|Class name: policy;<br>Method or attribute name: function off(type: 'netQuotaPolicyChange', callback?: Callback\<Array\<NetQuotaPolicy>>): void;|@ohos.net.policy.d.ts|
|Added|NA|Class name: policy;<br>Method or attribute name: function off(type: 'netBackgroundPolicyChange', callback?: Callback\<boolean>): void;|@ohos.net.policy.d.ts|
|Added|NA|Class name: NetBackgroundPolicy;<br>Method or attribute name: NET_BACKGROUND_POLICY_NONE = 0|@ohos.net.policy.d.ts|
|Added|NA|Class name: NetBackgroundPolicy;<br>Method or attribute name: NET_BACKGROUND_POLICY_ENABLE = 1|@ohos.net.policy.d.ts|
|Added|NA|Class name: NetBackgroundPolicy;<br>Method or attribute name: NET_BACKGROUND_POLICY_DISABLE = 2|@ohos.net.policy.d.ts|
|Added|NA|Class name: NetBackgroundPolicy;<br>Method or attribute name: NET_BACKGROUND_POLICY_TRUSTLIST = 3|@ohos.net.policy.d.ts|
|Added|NA|Class name: NetQuotaPolicy;<br>Method or attribute name: networkMatchRule: NetworkMatchRule;|@ohos.net.policy.d.ts|
|Added|NA|Class name: NetQuotaPolicy;<br>Method or attribute name: quotaPolicy: QuotaPolicy;|@ohos.net.policy.d.ts|
|Added|NA|Class name: QuotaPolicy;<br>Method or attribute name: periodDuration: string;|@ohos.net.policy.d.ts|
|Added|NA|Class name: QuotaPolicy;<br>Method or attribute name: warningBytes: number;|@ohos.net.policy.d.ts|
|Added|NA|Class name: QuotaPolicy;<br>Method or attribute name: limitBytes: number;|@ohos.net.policy.d.ts|
|Added|NA|Class name: QuotaPolicy;<br>Method or attribute name: metered: boolean;|@ohos.net.policy.d.ts|
|Added|NA|Class name: QuotaPolicy;<br>Method or attribute name: limitAction: LimitAction;|@ohos.net.policy.d.ts|
|Added|NA|Class name: QuotaPolicy;<br>Method or attribute name: lastWarningRemind?: number;|@ohos.net.policy.d.ts|
|Added|NA|Class name: QuotaPolicy;<br>Method or attribute name: lastLimitRemind?: number;|@ohos.net.policy.d.ts|
|Added|NA|Class name: NetworkMatchRule;<br>Method or attribute name: netType: NetBearType;|@ohos.net.policy.d.ts|
|Added|NA|Class name: NetworkMatchRule;<br>Method or attribute name: identity: string;|@ohos.net.policy.d.ts|
|Added|NA|Class name: NetworkMatchRule;<br>Method or attribute name: simId: string;|@ohos.net.policy.d.ts|
|Added|NA|Class name: LimitAction;<br>Method or attribute name: LIMIT_ACTION_NONE = -1|@ohos.net.policy.d.ts|
|Added|NA|Class name: LimitAction;<br>Method or attribute name: LIMIT_ACTION_ACCESS_DISABLED = 0|@ohos.net.policy.d.ts|
|Added|NA|Class name: LimitAction;<br>Method or attribute name: LIMIT_ACTION_ALERT_ONLY = 1|@ohos.net.policy.d.ts|
|Added|NA|Class name: NetUidRule;<br>Method or attribute name: NET_RULE_NONE = 0|@ohos.net.policy.d.ts|
|Added|NA|Class name: NetUidRule;<br>Method or attribute name: NET_RULE_ALLOW_METERED_FOREGROUND = 1 \<\< 0|@ohos.net.policy.d.ts|
|Added|NA|Class name: NetUidRule;<br>Method or attribute name: NET_RULE_ALLOW_METERED = 1 \<\< 1|@ohos.net.policy.d.ts|
|Added|NA|Class name: NetUidRule;<br>Method or attribute name: NET_RULE_REJECT_METERED = 1 \<\< 2|@ohos.net.policy.d.ts|
|Added|NA|Class name: NetUidRule;<br>Method or attribute name: NET_RULE_ALLOW_ALL = 1 \<\< 5|@ohos.net.policy.d.ts|
|Added|NA|Class name: NetUidRule;<br>Method or attribute name: NET_RULE_REJECT_ALL = 1 \<\< 6|@ohos.net.policy.d.ts|
|Added|NA|Class name: RemindType;<br>Method or attribute name: REMIND_TYPE_WARNING = 1|@ohos.net.policy.d.ts|
|Added|NA|Class name: RemindType;<br>Method or attribute name: REMIND_TYPE_LIMIT = 2|@ohos.net.policy.d.ts|
|Added|NA|Class name: NetUidPolicy;<br>Method or attribute name: NET_POLICY_NONE = 0|@ohos.net.policy.d.ts|
|Added|NA|Class name: NetUidPolicy;<br>Method or attribute name: NET_POLICY_ALLOW_METERED_BACKGROUND = 1 \<\< 0|@ohos.net.policy.d.ts|
|Added|NA|Class name: NetUidPolicy;<br>Method or attribute name: NET_POLICY_REJECT_METERED_BACKGROUND = 1 \<\< 1|@ohos.net.policy.d.ts|
|Added|NA|Class name: socket;<br>Method or attribute name: function constructTCPSocketServerInstance(): TCPSocketServer;|@ohos.net.socket.d.ts|
|Added|NA|Class name: socket;<br>Method or attribute name: function constructTLSSocketServerInstance(): TLSSocketServer;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TCPSocket;<br>Method or attribute name: getSocketFd(callback: AsyncCallback\<number>): void;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TCPSocket;<br>Method or attribute name: getSocketFd(): Promise\<number>;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TCPSocketConnection;<br>Method or attribute name: clientId: number;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TLSSocketConnection;<br>Method or attribute name: clientId: number;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TCPSocketConnection;<br>Method or attribute name: send(options: TCPSendOptions, callback: AsyncCallback\<void>): void;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TCPSocketConnection;<br>Method or attribute name: close(callback: AsyncCallback\<void>): void;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TLSSocketConnection;<br>Method or attribute name: close(callback: AsyncCallback\<void>): void;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TCPSocketConnection;<br>Method or attribute name: getRemoteAddress(callback: AsyncCallback\<NetAddress>): void;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TLSSocketConnection;<br>Method or attribute name: getRemoteAddress(callback: AsyncCallback\<NetAddress>): void;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TCPSocketConnection;<br>Method or attribute name: on(type: 'message', callback: Callback\<{ message: ArrayBuffer, remoteInfo: SocketRemoteInfo }>): void;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TLSSocketConnection;<br>Method or attribute name: on(type: 'message', callback: Callback\<{ message: ArrayBuffer, remoteInfo: SocketRemoteInfo }>): void;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TCPSocketConnection;<br>Method or attribute name: on(type: 'close', callback: Callback\<void>): void;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TLSSocketConnection;<br>Method or attribute name: on(type: 'close', callback: Callback\<void>): void;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TCPSocketConnection;<br>Method or attribute name: on(type: 'error', callback: ErrorCallback): void;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TCPSocketServer;<br>Method or attribute name: on(type: 'error', callback: ErrorCallback): void;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TLSSocketConnection;<br>Method or attribute name: on(type: 'error', callback: ErrorCallback): void;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TLSSocketServer;<br>Method or attribute name: on(type: 'error', callback: ErrorCallback): void;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TCPSocketConnection;<br>Method or attribute name: off(type: 'message', callback?: Callback\<{ message: ArrayBuffer, remoteInfo: SocketRemoteInfo }>): void;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TLSSocketConnection;<br>Method or attribute name: off(type: 'message', callback?: Callback\<{ message: ArrayBuffer, remoteInfo: SocketRemoteInfo }>): void;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TCPSocketConnection;<br>Method or attribute name: off(type: 'close', callback?: Callback\<void>): void;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TLSSocketConnection;<br>Method or attribute name: off(type: 'close', callback?: Callback\<void>): void;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TCPSocketConnection;<br>Method or attribute name: off(type: 'error', callback?: ErrorCallback): void;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TCPSocketServer;<br>Method or attribute name: off(type: 'error', callback?: ErrorCallback): void;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TLSSocketConnection;<br>Method or attribute name: off(type: 'error', callback?: ErrorCallback): void;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TLSSocketServer;<br>Method or attribute name: off(type: 'error', callback?: ErrorCallback): void;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TCPSocketServer;<br>Method or attribute name: listen(address: NetAddress, callback: AsyncCallback\<void>): void;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TCPSocketServer;<br>Method or attribute name: listen(address: NetAddress): Promise\<void>;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TCPSocketServer;<br>Method or attribute name: getState(callback: AsyncCallback\<SocketStateBase>): void;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TLSSocketServer;<br>Method or attribute name: getState(callback: AsyncCallback\<SocketStateBase>): void;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TCPSocketServer;<br>Method or attribute name: setExtraOptions(options: TCPExtraOptions, callback: AsyncCallback\<void>): void;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TLSSocketServer;<br>Method or attribute name: setExtraOptions(options: TCPExtraOptions, callback: AsyncCallback\<void>): void;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TCPSocketServer;<br>Method or attribute name: on(type: 'connect', callback: Callback\<TCPSocketConnection>): void;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TCPSocketServer;<br>Method or attribute name: off(type: 'connect', callback?: Callback\<TCPSocketConnection>): void;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TLSSocketConnection;<br>Method or attribute name: send(data: string, callback: AsyncCallback\<void>): void;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TLSSocketConnection;<br>Method or attribute name: getRemoteCertificate(callback: AsyncCallback\<X509CertRawData>): void;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TLSSocketConnection;<br>Method or attribute name: getCipherSuite(callback: AsyncCallback\<Array\<string>>): void;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TLSSocketConnection;<br>Method or attribute name: getSignatureAlgorithms(callback: AsyncCallback\<Array\<string>>): void;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TLSSocketServer;<br>Method or attribute name: listen(options: TLSConnectOptions, callback: AsyncCallback\<void>): void;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TLSSocketServer;<br>Method or attribute name: listen(options: TLSConnectOptions): Promise\<void>;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TLSSocketServer;<br>Method or attribute name: getCertificate(callback: AsyncCallback\<X509CertRawData>): void;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TLSSocketServer;<br>Method or attribute name: getProtocol(callback: AsyncCallback\<string>): void;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TLSSocketServer;<br>Method or attribute name: on(type: 'connect', callback: Callback\<TLSSocketConnection>): void;|@ohos.net.socket.d.ts|
|Added|NA|Class name: TLSSocketServer;<br>Method or attribute name: off(type: 'connect', callback?: Callback\<TLSSocketConnection>): void;|@ohos.net.socket.d.ts|
|Added|NA|Class name: statistics;<br>Method or attribute name: function getIfaceRxBytes(nic: string, callback: AsyncCallback\<number>): void;|@ohos.net.statistics.d.ts|
|Added|NA|Class name: statistics;<br>Method or attribute name: function getIfaceRxBytes(nic: string): Promise\<number>;|@ohos.net.statistics.d.ts|
|Added|NA|Class name: statistics;<br>Method or attribute name: function getIfaceTxBytes(nic: string, callback: AsyncCallback\<number>): void;|@ohos.net.statistics.d.ts|
|Added|NA|Class name: statistics;<br>Method or attribute name: function getIfaceTxBytes(nic: string): Promise\<number>;|@ohos.net.statistics.d.ts|
|Added|NA|Class name: statistics;<br>Method or attribute name: function getCellularRxBytes(callback: AsyncCallback\<number>): void;|@ohos.net.statistics.d.ts|
|Added|NA|Class name: statistics;<br>Method or attribute name: function getCellularRxBytes(): Promise\<number>;|@ohos.net.statistics.d.ts|
|Added|NA|Class name: statistics;<br>Method or attribute name: function getCellularTxBytes(callback: AsyncCallback\<number>): void;|@ohos.net.statistics.d.ts|
|Added|NA|Class name: statistics;<br>Method or attribute name: function getCellularTxBytes(): Promise\<number>;|@ohos.net.statistics.d.ts|
|Added|NA|Class name: statistics;<br>Method or attribute name: function getAllRxBytes(callback: AsyncCallback\<number>): void;|@ohos.net.statistics.d.ts|
|Added|NA|Class name: statistics;<br>Method or attribute name: function getAllRxBytes(): Promise\<number>;|@ohos.net.statistics.d.ts|
|Added|NA|Class name: statistics;<br>Method or attribute name: function getAllTxBytes(callback: AsyncCallback\<number>): void;|@ohos.net.statistics.d.ts|
|Added|NA|Class name: statistics;<br>Method or attribute name: function getAllTxBytes(): Promise\<number>;|@ohos.net.statistics.d.ts|
|Added|NA|Class name: statistics;<br>Method or attribute name: function getUidRxBytes(uid: number, callback: AsyncCallback\<number>): void;|@ohos.net.statistics.d.ts|
|Added|NA|Class name: statistics;<br>Method or attribute name: function getUidRxBytes(uid: number): Promise\<number>;|@ohos.net.statistics.d.ts|
|Added|NA|Class name: statistics;<br>Method or attribute name: function getUidTxBytes(uid: number, callback: AsyncCallback\<number>): void;|@ohos.net.statistics.d.ts|
|Added|NA|Class name: statistics;<br>Method or attribute name: function getUidTxBytes(uid: number): Promise\<number>;|@ohos.net.statistics.d.ts|
|Added|NA|Class name: statistics;<br>Method or attribute name: function on(type: 'netStatsChange', callback: Callback\<{ iface: string, uid?: number }>): void;|@ohos.net.statistics.d.ts|
|Added|NA|Class name: statistics;<br>Method or attribute name: function off(type: 'netStatsChange', callback?: Callback\<{ iface: string, uid?: number }>): void;|@ohos.net.statistics.d.ts|
|Added|NA|Class name: statistics;<br>Method or attribute name: function getTrafficStatsByIface(ifaceInfo: IfaceInfo, callback: AsyncCallback\<NetStatsInfo>): void;|@ohos.net.statistics.d.ts|
|Added|NA|Class name: statistics;<br>Method or attribute name: function getTrafficStatsByIface(ifaceInfo: IfaceInfo): Promise\<NetStatsInfo>;|@ohos.net.statistics.d.ts|
|Added|NA|Class name: statistics;<br>Method or attribute name: function getTrafficStatsByUid(uidInfo: UidInfo, callback: AsyncCallback\<NetStatsInfo>): void;|@ohos.net.statistics.d.ts|
|Added|NA|Class name: statistics;<br>Method or attribute name: function getTrafficStatsByUid(uidInfo: UidInfo): Promise\<NetStatsInfo>;|@ohos.net.statistics.d.ts|
|Added|NA|Class name: IfaceInfo;<br>Method or attribute name: iface: string;|@ohos.net.statistics.d.ts|
|Added|NA|Class name: IfaceInfo;<br>Method or attribute name: startTime: number;|@ohos.net.statistics.d.ts|
|Added|NA|Class name: IfaceInfo;<br>Method or attribute name: endTime: number;|@ohos.net.statistics.d.ts|
|Added|NA|Class name: UidInfo;<br>Method or attribute name: ifaceInfo: IfaceInfo;|@ohos.net.statistics.d.ts|
|Added|NA|Class name: UidInfo;<br>Method or attribute name: uid: number;|@ohos.net.statistics.d.ts|
|Added|NA|Class name: NetStatsInfo;<br>Method or attribute name: rxBytes: number;|@ohos.net.statistics.d.ts|
|Added|NA|Class name: NetStatsInfo;<br>Method or attribute name: txBytes: number;|@ohos.net.statistics.d.ts|
|Added|NA|Class name: NetStatsInfo;<br>Method or attribute name: rxPackets: number;|@ohos.net.statistics.d.ts|
|Added|NA|Class name: NetStatsInfo;<br>Method or attribute name: txPackets: number;|@ohos.net.statistics.d.ts|
|Added|NA|Class name: vpn;<br>Method or attribute name: export type LinkAddress = connection.LinkAddress;|@ohos.net.vpn.d.ts|
|Added|NA|Class name: vpn;<br>Method or attribute name: export type RouteInfo = connection.RouteInfo;|@ohos.net.vpn.d.ts|
|Added|NA|Class name: vpn;<br>Method or attribute name: function createVpnConnection(context: AbilityContext): VpnConnection;|@ohos.net.vpn.d.ts|
|Added|NA|Class name: VpnConnection;<br>Method or attribute name: setUp(config: VpnConfig, callback: AsyncCallback\<number>): void;|@ohos.net.vpn.d.ts|
|Added|NA|Class name: VpnConnection;<br>Method or attribute name: setUp(config: VpnConfig): Promise\<number>;|@ohos.net.vpn.d.ts|
|Added|NA|Class name: VpnConnection;<br>Method or attribute name: protect(socketFd: number, callback: AsyncCallback\<void>): void;|@ohos.net.vpn.d.ts|
|Added|NA|Class name: VpnConnection;<br>Method or attribute name: protect(socketFd: number): Promise\<void>;|@ohos.net.vpn.d.ts|
|Added|NA|Class name: VpnConnection;<br>Method or attribute name: destroy(callback: AsyncCallback\<void>): void;|@ohos.net.vpn.d.ts|
|Added|NA|Class name: VpnConnection;<br>Method or attribute name: destroy(): Promise\<void>;|@ohos.net.vpn.d.ts|
|Added|NA|Class name: VpnConfig;<br>Method or attribute name: addresses: Array\<LinkAddress>;|@ohos.net.vpn.d.ts|
|Added|NA|Class name: VpnConfig;<br>Method or attribute name: routes?: Array\<RouteInfo>;|@ohos.net.vpn.d.ts|
|Added|NA|Class name: VpnConfig;<br>Method or attribute name: dnsAddresses?: Array\<string>;|@ohos.net.vpn.d.ts|
|Added|NA|Class name: VpnConfig;<br>Method or attribute name: searchDomains?: Array\<string>;|@ohos.net.vpn.d.ts|
|Added|NA|Class name: VpnConfig;<br>Method or attribute name: mtu?: number;|@ohos.net.vpn.d.ts|
|Added|NA|Class name: VpnConfig;<br>Method or attribute name: isIPv4Accepted?: boolean;|@ohos.net.vpn.d.ts|
|Added|NA|Class name: VpnConfig;<br>Method or attribute name: isIPv6Accepted?: boolean;|@ohos.net.vpn.d.ts|
|Added|NA|Class name: VpnConfig;<br>Method or attribute name: isLegacy?: boolean;|@ohos.net.vpn.d.ts|
|Added|NA|Class name: VpnConfig;<br>Method or attribute name: isBlocking?: boolean;|@ohos.net.vpn.d.ts|
|Added|NA|Class name: VpnConfig;<br>Method or attribute name: trustedApplications?: Array\<string>;|@ohos.net.vpn.d.ts|
|Added|NA|Class name: VpnConfig;<br>Method or attribute name: blockedApplications?: Array\<string>;|@ohos.net.vpn.d.ts|
|Added|NA|Class name: wifiManager;<br>Method or attribute name: function getScanResults(): Promise\<Array\<WifiScanInfo>>;|@ohos.wifiManager.d.ts|
|Added|NA|Class name: wifiManager;<br>Method or attribute name: function getScanResults(callback: AsyncCallback\<Array\<WifiScanInfo>>): void;|@ohos.wifiManager.d.ts|
|Added|NA|Class name: wifiManager;<br>Method or attribute name: function getScanResultsSync(): Array\<WifiScanInfo>;|@ohos.wifiManager.d.ts|
|Added|NA|Class name: wifiManager;<br>Method or attribute name: function setScanAlwaysAllowed(isScanAlwaysAllowed: boolean): void;|@ohos.wifiManager.d.ts|
|Added|NA|Class name: wifiManager;<br>Method or attribute name: function getScanAlwaysAllowed(): boolean;|@ohos.wifiManager.d.ts|
|Added|NA|Class name: wifiManager;<br>Method or attribute name: function updateNetwork(config: WifiDeviceConfig): number;|@ohos.wifiManager.d.ts|
|Added|NA|Class name: wifiManager;<br>Method or attribute name: function disableNetwork(netId: number): void;|@ohos.wifiManager.d.ts|
|Added|NA|Class name: wifiManager;<br>Method or attribute name: function removeAllNetwork(): void;|@ohos.wifiManager.d.ts|
|Added|NA|Class name: wifiManager;<br>Method or attribute name: function removeDevice(id: number): void;|@ohos.wifiManager.d.ts|
|Added|NA|Class name: wifiManager;<br>Method or attribute name: function getDisconnectedReason(): DisconnectedReason;|@ohos.wifiManager.d.ts|
|Added|NA|Class name: wifiManager;<br>Method or attribute name: function getStations(): Array\<StationInfo>;|@ohos.wifiManager.d.ts|
|Added|NA|Class name: wifiManager;<br>Method or attribute name: function createGroup(config: WifiP2PConfig): void;|@ohos.wifiManager.d.ts|
|Added|NA|Class name: wifiManager;<br>Method or attribute name: function removeGroup(): void;|@ohos.wifiManager.d.ts|
|Added|NA|Class name: wifiManager;<br>Method or attribute name: function startDiscoverDevices(): void;|@ohos.wifiManager.d.ts|
|Added|NA|Class name: wifiManager;<br>Method or attribute name: function stopDiscoverDevices(): void;|@ohos.wifiManager.d.ts|
|Added|NA|Class name: wifiManager;<br>Method or attribute name: function deletePersistentGroup(netId: number): void;|@ohos.wifiManager.d.ts|
|Added|NA|Class name: wifiManager;<br>Method or attribute name: function setDeviceName(devName: string): void;|@ohos.wifiManager.d.ts|
|Added|NA|Class name: DisconnectedReason;<br>Method or attribute name: DISC_REASON_DEFAULT = 0|@ohos.wifiManager.d.ts|
|Added|NA|Class name: DisconnectedReason;<br>Method or attribute name: DISC_REASON_WRONG_PWD = 1|@ohos.wifiManager.d.ts|
|Added|NA|Class name: DisconnectedReason;<br>Method or attribute name: DISC_REASON_CONNECTION_FULL = 2|@ohos.wifiManager.d.ts|
|Added|NA|Class name: ProxyMethod;<br>Method or attribute name: METHOD_NONE = 0|@ohos.wifiManager.d.ts|
|Added|NA|Class name: ProxyMethod;<br>Method or attribute name: METHOD_AUTO = 1|@ohos.wifiManager.d.ts|
|Added|NA|Class name: ProxyMethod;<br>Method or attribute name: METHOD_MANUAL = 2|@ohos.wifiManager.d.ts|
|Added|NA|Class name: WifiProxyConfig;<br>Method or attribute name: proxyMethod?: ProxyMethod;|@ohos.wifiManager.d.ts|
|Added|NA|Class name: WifiProxyConfig;<br>Method or attribute name: pacWebAddress?: string;|@ohos.wifiManager.d.ts|
|Added|NA|Class name: WifiProxyConfig;<br>Method or attribute name: serverHostName?: string;|@ohos.wifiManager.d.ts|
|Added|NA|Class name: WifiProxyConfig;<br>Method or attribute name: serverPort?: number;|@ohos.wifiManager.d.ts|
|Added|NA|Class name: WifiProxyConfig;<br>Method or attribute name: exclusionObjects?: string;|@ohos.wifiManager.d.ts|
|Added|NA|Class name: WifiDeviceConfig;<br>Method or attribute name: proxyConfig?: WifiProxyConfig;|@ohos.wifiManager.d.ts|
|Added|NA|Class name: HotspotConfig;<br>Method or attribute name: ipAddress?: string;|@ohos.wifiManager.d.ts|
|Error code added|Class name: GattClientDevice;<br>Method or attribute name: getDeviceName(): Promise\<string>;<br>Old version information: |Class name: GattClientDevice;<br>Method or attribute name: getDeviceName(): Promise\<string>;<br>New version information: 201,401,801,2900001,2900099|@ohos.bluetoothManager.d.ts|
|Error code added|Class name: GattClientDevice;<br>Method or attribute name: getServices(): Promise\<Array\<GattService>>;<br>Old version information: |Class name: GattClientDevice;<br>Method or attribute name: getServices(): Promise\<Array\<GattService>>;<br>New version information: 201,401,801,2900001,2900099|@ohos.bluetoothManager.d.ts|
|Error code added|Class name: GattClientDevice;<br>Method or attribute name: readCharacteristicValue(characteristic: BLECharacteristic): Promise\<BLECharacteristic>;<br>Old version information: |Class name: GattClientDevice;<br>Method or attribute name: readCharacteristicValue(characteristic: BLECharacteristic): Promise\<BLECharacteristic>;<br>New version information: 201,401,801,2900001,2901000,2900099|@ohos.bluetoothManager.d.ts|
|Error code added|Class name: GattClientDevice;<br>Method or attribute name: readDescriptorValue(descriptor: BLEDescriptor): Promise\<BLEDescriptor>;<br>Old version information: |Class name: GattClientDevice;<br>Method or attribute name: readDescriptorValue(descriptor: BLEDescriptor): Promise\<BLEDescriptor>;<br>New version information: 201,401,801,2900001,2901000,2900099|@ohos.bluetoothManager.d.ts|
|Error code added|Class name: GattClientDevice;<br>Method or attribute name: getRssiValue(): Promise\<number>;<br>Old version information: |Class name: GattClientDevice;<br>Method or attribute name: getRssiValue(): Promise\<number>;<br>New version information: 201,401,801,2900099|@ohos.bluetoothManager.d.ts|
|Error code added|Class name: connection;<br>Method or attribute name: function getDefaultNet(): Promise\<NetHandle>;<br>Old version information: |Class name: connection;<br>Method or attribute name: function getDefaultNet(): Promise\<NetHandle>;<br>New version information: 201,401,2100002,2100003|@ohos.net.connection.d.ts|
|Error code added|Class name: connection;<br>Method or attribute name: function getAllNets(): Promise\<Array\<NetHandle>>;<br>Old version information: |Class name: connection;<br>Method or attribute name: function getAllNets(): Promise\<Array\<NetHandle>>;<br>New version information: 201,401,2100002,2100003|@ohos.net.connection.d.ts|
|Error code added|Class name: connection;<br>Method or attribute name: function getConnectionProperties(netHandle: NetHandle): Promise\<ConnectionProperties>;<br>Old version information: |Class name: connection;<br>Method or attribute name: function getConnectionProperties(netHandle: NetHandle): Promise\<ConnectionProperties>;<br>New version information: 201,401,2100001,2100002,2100003|@ohos.net.connection.d.ts|
|Error code added|Class name: connection;<br>Method or attribute name: function getNetCapabilities(netHandle: NetHandle): Promise\<NetCapabilities>;<br>Old version information: |Class name: connection;<br>Method or attribute name: function getNetCapabilities(netHandle: NetHandle): Promise\<NetCapabilities>;<br>New version information: 201,401,2100001,2100002,2100003|@ohos.net.connection.d.ts|
|Error code added|Class name: connection;<br>Method or attribute name: function isDefaultNetMetered(): Promise\<boolean>;<br>Old version information: |Class name: connection;<br>Method or attribute name: function isDefaultNetMetered(): Promise\<boolean>;<br>New version information: 201,401,2100002,2100003|@ohos.net.connection.d.ts|
|Error code added|Class name: connection;<br>Method or attribute name: function hasDefaultNet(): Promise\<boolean>;<br>Old version information: |Class name: connection;<br>Method or attribute name: function hasDefaultNet(): Promise\<boolean>;<br>New version information: 201,401,2100002,2100003|@ohos.net.connection.d.ts|
|Error code added|Class name: connection;<br>Method or attribute name: function enableAirplaneMode(): Promise\<void>;<br>Old version information: |Class name: connection;<br>Method or attribute name: function enableAirplaneMode(): Promise\<void>;<br>New version information: 201,202,401,2100002,2100003|@ohos.net.connection.d.ts|
|Error code added|Class name: connection;<br>Method or attribute name: function disableAirplaneMode(): Promise\<void>;<br>Old version information: |Class name: connection;<br>Method or attribute name: function disableAirplaneMode(): Promise\<void>;<br>New version information: 201,202,401,2100002,2100003|@ohos.net.connection.d.ts|
|Error code added|Class name: connection;<br>Method or attribute name: function reportNetConnected(netHandle: NetHandle): Promise\<void>;<br>Old version information: |Class name: connection;<br>Method or attribute name: function reportNetConnected(netHandle: NetHandle): Promise\<void>;<br>New version information: 201,401,2100001,2100002,2100003|@ohos.net.connection.d.ts|
|Error code added|Class name: connection;<br>Method or attribute name: function reportNetDisconnected(netHandle: NetHandle): Promise\<void>;<br>Old version information: |Class name: connection;<br>Method or attribute name: function reportNetDisconnected(netHandle: NetHandle): Promise\<void>;<br>New version information: 201,401,2100001,2100002,2100003|@ohos.net.connection.d.ts|
|Error code added|Class name: connection;<br>Method or attribute name: function getAddressesByName(host: string): Promise\<Array\<NetAddress>>;<br>Old version information: |Class name: connection;<br>Method or attribute name: function getAddressesByName(host: string): Promise\<Array\<NetAddress>>;<br>New version information: 201,401,2100001,2100002,2100003|@ohos.net.connection.d.ts|
|Error code added|Class name: NetHandle;<br>Method or attribute name: bindSocket(socketParam: TCPSocket \| UDPSocket): Promise\<void>;<br>Old version information: |Class name: NetHandle;<br>Method or attribute name: bindSocket(socketParam: TCPSocket \| UDPSocket): Promise\<void>;<br>New version information: 401,2100001,2100002,2100003|@ohos.net.connection.d.ts|
|Error code added|Class name: NetHandle;<br>Method or attribute name: getAddressesByName(host: string): Promise\<Array\<NetAddress>>;<br>Old version information: |Class name: NetHandle;<br>Method or attribute name: getAddressesByName(host: string): Promise\<Array\<NetAddress>>;<br>New version information: 201,401,2100001,2100002,2100003|@ohos.net.connection.d.ts|
|Error code added|Class name: NetHandle;<br>Method or attribute name: getAddressByName(host: string): Promise\<NetAddress>;<br>Old version information: |Class name: NetHandle;<br>Method or attribute name: getAddressByName(host: string): Promise\<NetAddress>;<br>New version information: 201,401,2100001,2100002,2100003|@ohos.net.connection.d.ts|
|Error code added|Class name: ethernet;<br>Method or attribute name: function getIfaceConfig(iface: string): Promise\<InterfaceConfiguration>;<br>Old version information: |Class name: ethernet;<br>Method or attribute name: function getIfaceConfig(iface: string): Promise\<InterfaceConfiguration>;<br>New version information: 201,202,401,2200001,2200002,2200003,2201005|@ohos.net.ethernet.d.ts|
|Error code added|Class name: ethernet;<br>Method or attribute name: function setIfaceConfig(iface: string, ic: InterfaceConfiguration): Promise\<void>;<br>Old version information: |Class name: ethernet;<br>Method or attribute name: function setIfaceConfig(iface: string, ic: InterfaceConfiguration): Promise\<void>;<br>New version information: 201,202,401,2200001,2200002,2200003,2201004,2201005,2201006,2201007|@ohos.net.ethernet.d.ts|
|Error code added|Class name: ethernet;<br>Method or attribute name: function isIfaceActive(iface: string): Promise\<number>;<br>Old version information: |Class name: ethernet;<br>Method or attribute name: function isIfaceActive(iface: string): Promise\<number>;<br>New version information: 201,202,401,2200001,2200002,2200003,2201005|@ohos.net.ethernet.d.ts|
|Error code added|Class name: ethernet;<br>Method or attribute name: function getAllActiveIfaces(): Promise\<Array\<string>>;<br>Old version information: |Class name: ethernet;<br>Method or attribute name: function getAllActiveIfaces(): Promise\<Array\<string>>;<br>New version information: 201,202,2200002,2200003|@ohos.net.ethernet.d.ts|
|Error code added|Class name: HttpRequest;<br>Method or attribute name: request(url: string, options: HttpRequestOptions, callback: AsyncCallback\<HttpResponse>): void;<br>Old version information: |Class name: HttpRequest;<br>Method or attribute name: request(url: string, options: HttpRequestOptions, callback: AsyncCallback\<HttpResponse>): void;<br>New version information: 401,201,2300001,2300003,2300005,2300006,2300007,2300008,2300009,2300016,2300018,2300023,2300025,2300026,2300027,2300028,2300047,2300052,2300055,2300056,2300058,2300059,2300060,2300061,2300063,2300070,2300073,2300077,2300078,2300094,2300999|@ohos.net.http.d.ts|
|Error code added|Class name: HttpRequest;<br>Method or attribute name: request(url: string, options?: HttpRequestOptions): Promise\<HttpResponse>;<br>Old version information: |Class name: HttpRequest;<br>Method or attribute name: request(url: string, options?: HttpRequestOptions): Promise\<HttpResponse>;<br>New version information: 401,201,2300001,2300003,2300005,2300006,2300007,2300008,2300009,2300016,2300018,2300023,2300025,2300026,2300027,2300028,2300047,2300052,2300055,2300056,2300058,2300059,2300060,2300061,2300063,2300070,2300073,2300077,2300078,2300094,2300999|@ohos.net.http.d.ts|
|Error code added|Class name: sharing;<br>Method or attribute name: function isSharingSupported(): Promise\<boolean>;<br>Old version information: |Class name: sharing;<br>Method or attribute name: function isSharingSupported(): Promise\<boolean>;<br>New version information: 201,202,2200002,2200003,2202011|@ohos.net.sharing.d.ts|
|Error code added|Class name: sharing;<br>Method or attribute name: function isSharing(): Promise\<boolean>;<br>Old version information: |Class name: sharing;<br>Method or attribute name: function isSharing(): Promise\<boolean>;<br>New version information: 201,202,2200002,2200003,2202011|@ohos.net.sharing.d.ts|
|Error code added|Class name: sharing;<br>Method or attribute name: function startSharing(type: SharingIfaceType): Promise\<void>;<br>Old version information: |Class name: sharing;<br>Method or attribute name: function startSharing(type: SharingIfaceType): Promise\<void>;<br>New version information: 201,202,401,2200001,2200002,2200003,2202004,2202005,2202006,2202009,2202011|@ohos.net.sharing.d.ts|
|Error code added|Class name: sharing;<br>Method or attribute name: function stopSharing(type: SharingIfaceType): Promise\<void>;<br>Old version information: |Class name: sharing;<br>Method or attribute name: function stopSharing(type: SharingIfaceType): Promise\<void>;<br>New version information: 201,202,401,2200001,2200002,2200003,2202004,2202005,2202006,2202011|@ohos.net.sharing.d.ts|
|Error code added|Class name: sharing;<br>Method or attribute name: function getStatsRxBytes(): Promise\<number>;<br>Old version information: |Class name: sharing;<br>Method or attribute name: function getStatsRxBytes(): Promise\<number>;<br>New version information: 201,202,401,2200002,2200003|@ohos.net.sharing.d.ts|
|Error code added|Class name: sharing;<br>Method or attribute name: function getStatsTxBytes(): Promise\<number>;<br>Old version information: |Class name: sharing;<br>Method or attribute name: function getStatsTxBytes(): Promise\<number>;<br>New version information: 201,202,401,2200002,2200003|@ohos.net.sharing.d.ts|
|Error code added|Class name: sharing;<br>Method or attribute name: function getStatsTotalBytes(): Promise\<number>;<br>Old version information: |Class name: sharing;<br>Method or attribute name: function getStatsTotalBytes(): Promise\<number>;<br>New version information: 201,202,401,2200002,2200003|@ohos.net.sharing.d.ts|
|Error code added|Class name: sharing;<br>Method or attribute name: function getSharingIfaces(state: SharingIfaceState): Promise\<Array\<string>>;<br>Old version information: |Class name: sharing;<br>Method or attribute name: function getSharingIfaces(state: SharingIfaceState): Promise\<Array\<string>>;<br>New version information: 201,202,401,2200001,2200002,2200003|@ohos.net.sharing.d.ts|
|Error code added|Class name: sharing;<br>Method or attribute name: function getSharingState(type: SharingIfaceType): Promise\<SharingIfaceState>;<br>Old version information: |Class name: sharing;<br>Method or attribute name: function getSharingState(type: SharingIfaceType): Promise\<SharingIfaceState>;<br>New version information: 201,202,401,2200001,2200002,2200003|@ohos.net.sharing.d.ts|
|Error code added|Class name: sharing;<br>Method or attribute name: function getSharableRegexes(type: SharingIfaceType): Promise\<Array\<string>>;<br>Old version information: |Class name: sharing;<br>Method or attribute name: function getSharableRegexes(type: SharingIfaceType): Promise\<Array\<string>>;<br>New version information: 201,202,401,2200001,2200002,2200003|@ohos.net.sharing.d.ts|
|Error code added|Class name: UDPSocket;<br>Method or attribute name: bind(address: NetAddress): Promise\<void>;<br>Old version information: |Class name: UDPSocket;<br>Method or attribute name: bind(address: NetAddress): Promise\<void>;<br>New version information: 401,201|@ohos.net.socket.d.ts|
|Error code added|Class name: TCPSocket;<br>Method or attribute name: bind(address: NetAddress): Promise\<void>;<br>Old version information: |Class name: TCPSocket;<br>Method or attribute name: bind(address: NetAddress): Promise\<void>;<br>New version information: 401,201|@ohos.net.socket.d.ts|
|Error code added|Class name: TLSSocket;<br>Method or attribute name: bind(address: NetAddress): Promise\<void>;<br>Old version information: |Class name: TLSSocket;<br>Method or attribute name: bind(address: NetAddress): Promise\<void>;<br>New version information: 401,201,2303198,2300002|@ohos.net.socket.d.ts|
|Error code added|Class name: UDPSocket;<br>Method or attribute name: send(options: UDPSendOptions): Promise\<void>;<br>Old version information: |Class name: UDPSocket;<br>Method or attribute name: send(options: UDPSendOptions): Promise\<void>;<br>New version information: 401,201|@ohos.net.socket.d.ts|
|Error code added|Class name: UDPSocket;<br>Method or attribute name: close(): Promise\<void>;<br>Old version information: |Class name: UDPSocket;<br>Method or attribute name: close(): Promise\<void>;<br>New version information: 201|@ohos.net.socket.d.ts|
|Error code added|Class name: TCPSocket;<br>Method or attribute name: close(): Promise\<void>;<br>Old version information: |Class name: TCPSocket;<br>Method or attribute name: close(): Promise\<void>;<br>New version information: 201|@ohos.net.socket.d.ts|
|Error code added|Class name: TLSSocket;<br>Method or attribute name: close(): Promise\<void>;<br>Old version information: |Class name: TLSSocket;<br>Method or attribute name: close(): Promise\<void>;<br>New version information: 401,2303501,2303505,2303506,2300002|@ohos.net.socket.d.ts|
|Error code added|Class name: UDPSocket;<br>Method or attribute name: getState(): Promise\<SocketStateBase>;<br>Old version information: |Class name: UDPSocket;<br>Method or attribute name: getState(): Promise\<SocketStateBase>;<br>New version information: 201|@ohos.net.socket.d.ts|
|Error code added|Class name: TCPSocket;<br>Method or attribute name: getState(): Promise\<SocketStateBase>;<br>Old version information: |Class name: TCPSocket;<br>Method or attribute name: getState(): Promise\<SocketStateBase>;<br>New version information: 201|@ohos.net.socket.d.ts|
|Error code added|Class name: TLSSocket;<br>Method or attribute name: getState(): Promise\<SocketStateBase>;<br>Old version information: |Class name: TLSSocket;<br>Method or attribute name: getState(): Promise\<SocketStateBase>;<br>New version information: 2303188,2300002|@ohos.net.socket.d.ts|
|Error code added|Class name: UDPSocket;<br>Method or attribute name: setExtraOptions(options: UDPExtraOptions): Promise\<void>;<br>Old version information: |Class name: UDPSocket;<br>Method or attribute name: setExtraOptions(options: UDPExtraOptions): Promise\<void>;<br>New version information: 401,201|@ohos.net.socket.d.ts|
|Error code added|Class name: TCPSocket;<br>Method or attribute name: connect(options: TCPConnectOptions): Promise\<void>;<br>Old version information: |Class name: TCPSocket;<br>Method or attribute name: connect(options: TCPConnectOptions): Promise\<void>;<br>New version information: 401,201|@ohos.net.socket.d.ts|
|Error code added|Class name: TCPSocket;<br>Method or attribute name: send(options: TCPSendOptions): Promise\<void>;<br>Old version information: |Class name: TCPSocket;<br>Method or attribute name: send(options: TCPSendOptions): Promise\<void>;<br>New version information: 401,201|@ohos.net.socket.d.ts|
|Error code added|Class name: TCPSocket;<br>Method or attribute name: getRemoteAddress(): Promise\<NetAddress>;<br>Old version information: |Class name: TCPSocket;<br>Method or attribute name: getRemoteAddress(): Promise\<NetAddress>;<br>New version information: 201|@ohos.net.socket.d.ts|
|Error code added|Class name: TLSSocket;<br>Method or attribute name: getRemoteAddress(): Promise\<NetAddress>;<br>Old version information: |Class name: TLSSocket;<br>Method or attribute name: getRemoteAddress(): Promise\<NetAddress>;<br>New version information: 2303188,2300002|@ohos.net.socket.d.ts|
|Error code added|Class name: TCPSocket;<br>Method or attribute name: setExtraOptions(options: TCPExtraOptions): Promise\<void>;<br>Old version information: |Class name: TCPSocket;<br>Method or attribute name: setExtraOptions(options: TCPExtraOptions): Promise\<void>;<br>New version information: 401,201|@ohos.net.socket.d.ts|
|Error code added|Class name: TLSSocket;<br>Method or attribute name: setExtraOptions(options: TCPExtraOptions): Promise\<void>;<br>Old version information: |Class name: TLSSocket;<br>Method or attribute name: setExtraOptions(options: TCPExtraOptions): Promise\<void>;<br>New version information: 401,2303188,2300002|@ohos.net.socket.d.ts|
|Error code added|Class name: TLSSocket;<br>Method or attribute name: getCertificate(): Promise\<X509CertRawData>;<br>Old version information: |Class name: TLSSocket;<br>Method or attribute name: getCertificate(): Promise\<X509CertRawData>;<br>New version information: 2303501,2303504,2300002|@ohos.net.socket.d.ts|
|Error code added|Class name: TLSSocket;<br>Method or attribute name: getRemoteCertificate(): Promise\<X509CertRawData>;<br>Old version information: |Class name: TLSSocket;<br>Method or attribute name: getRemoteCertificate(): Promise\<X509CertRawData>;<br>New version information: 2303501,2300002|@ohos.net.socket.d.ts|
|Error code added|Class name: TLSSocket;<br>Method or attribute name: getProtocol(): Promise\<string>;<br>Old version information: |Class name: TLSSocket;<br>Method or attribute name: getProtocol(): Promise\<string>;<br>New version information: 2303501,2303505,2300002|@ohos.net.socket.d.ts|
|Error code added|Class name: TLSSocket;<br>Method or attribute name: getCipherSuite(): Promise\<Array\<string>>;<br>Old version information: |Class name: TLSSocket;<br>Method or attribute name: getCipherSuite(): Promise\<Array\<string>>;<br>New version information: 2303501,2303502,2303505,2300002|@ohos.net.socket.d.ts|
|Error code added|Class name: TLSSocket;<br>Method or attribute name: getSignatureAlgorithms(): Promise\<Array\<string>>;<br>Old version information: |Class name: TLSSocket;<br>Method or attribute name: getSignatureAlgorithms(): Promise\<Array\<string>>;<br>New version information: 2303501,2300002|@ohos.net.socket.d.ts|
|Error code added|Class name: TLSSocket;<br>Method or attribute name: connect(options: TLSConnectOptions): Promise\<void>;<br>Old version information: |Class name: TLSSocket;<br>Method or attribute name: connect(options: TLSConnectOptions): Promise\<void>;<br>New version information: 401,2303104,2303109,2303111,2303188,2303191,2303198,2303199,2303210,2303501,2303502,2303503,2303505,2303506,2300002|@ohos.net.socket.d.ts|
|Error code added|Class name: TLSSocket;<br>Method or attribute name: send(data: string): Promise\<void>;<br>Old version information: |Class name: TLSSocket;<br>Method or attribute name: send(data: string): Promise\<void>;<br>New version information: 401,2303501,2303503,2303505,2303506,2300002|@ohos.net.socket.d.ts|
|Error code added|Class name: WebSocket;<br>Method or attribute name: connect(url: string, options: WebSocketRequestOptions, callback: AsyncCallback\<boolean>): void;<br>Old version information: |Class name: WebSocket;<br>Method or attribute name: connect(url: string, options: WebSocketRequestOptions, callback: AsyncCallback\<boolean>): void;<br>New version information: 401,201|@ohos.net.webSocket.d.ts|
|Error code added|Class name: WebSocket;<br>Method or attribute name: connect(url: string, options?: WebSocketRequestOptions): Promise\<boolean>;<br>Old version information: |Class name: WebSocket;<br>Method or attribute name: connect(url: string, options?: WebSocketRequestOptions): Promise\<boolean>;<br>New version information: 401,201|@ohos.net.webSocket.d.ts|
|Error code added|Class name: WebSocket;<br>Method or attribute name: send(data: string \| ArrayBuffer): Promise\<boolean>;<br>Old version information: |Class name: WebSocket;<br>Method or attribute name: send(data: string \| ArrayBuffer): Promise\<boolean>;<br>New version information: 401,201|@ohos.net.webSocket.d.ts|
|Error code added|Class name: WebSocket;<br>Method or attribute name: close(options: WebSocketCloseOptions, callback: AsyncCallback\<boolean>): void;<br>Old version information: |Class name: WebSocket;<br>Method or attribute name: close(options: WebSocketCloseOptions, callback: AsyncCallback\<boolean>): void;<br>New version information: 401,201|@ohos.net.webSocket.d.ts|
|Error code added|Class name: WebSocket;<br>Method or attribute name: close(options?: WebSocketCloseOptions): Promise\<boolean>;<br>Old version information: |Class name: WebSocket;<br>Method or attribute name: close(options?: WebSocketCloseOptions): Promise\<boolean>;<br>New version information: 401,201|@ohos.net.webSocket.d.ts|
|Error code added|Class name: wifiManager;<br>Method or attribute name: function addDeviceConfig(config: WifiDeviceConfig, callback: AsyncCallback\<number>): void;<br>Old version information: |Class name: wifiManager;<br>Method or attribute name: function addDeviceConfig(config: WifiDeviceConfig, callback: AsyncCallback\<number>): void;<br>New version information: 201,202,401,801,2501000|@ohos.wifiManager.d.ts|
|Error code added|Class name: wifiManager;<br>Method or attribute name: function addCandidateConfig(config: WifiDeviceConfig, callback: AsyncCallback\<number>): void;<br>Old version information: |Class name: wifiManager;<br>Method or attribute name: function addCandidateConfig(config: WifiDeviceConfig, callback: AsyncCallback\<number>): void;<br>New version information: 201,401,801,2501000|@ohos.wifiManager.d.ts|
|Error code added|Class name: wifiManager;<br>Method or attribute name: function removeCandidateConfig(networkId: number, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: wifiManager;<br>Method or attribute name: function removeCandidateConfig(networkId: number, callback: AsyncCallback\<void>): void;<br>New version information: 201,401,801,2501000|@ohos.wifiManager.d.ts|
|Error code added|Class name: wifiManager;<br>Method or attribute name: function getLinkedInfo(callback: AsyncCallback\<WifiLinkedInfo>): void;<br>Old version information: |Class name: wifiManager;<br>Method or attribute name: function getLinkedInfo(callback: AsyncCallback\<WifiLinkedInfo>): void;<br>New version information: 201,202,801,2501000,2501001|@ohos.wifiManager.d.ts|
|Error code added|Class name: wifiManager;<br>Method or attribute name: function getP2pLinkedInfo(callback: AsyncCallback\<WifiP2pLinkedInfo>): void;<br>Old version information: |Class name: wifiManager;<br>Method or attribute name: function getP2pLinkedInfo(callback: AsyncCallback\<WifiP2pLinkedInfo>): void;<br>New version information: 201,801,2801000|@ohos.wifiManager.d.ts|
|Error code added|Class name: wifiManager;<br>Method or attribute name: function getCurrentP2pGroup(callback: AsyncCallback\<WifiP2pGroupInfo>): void;<br>Old version information: |Class name: wifiManager;<br>Method or attribute name: function getCurrentP2pGroup(callback: AsyncCallback\<WifiP2pGroupInfo>): void;<br>New version information: 201,801,2801000|@ohos.wifiManager.d.ts|
|Error code added|Class name: wifiManager;<br>Method or attribute name: function getP2pPeerDevices(callback: AsyncCallback\<WifiP2pDevice[]>): void;<br>Old version information: |Class name: wifiManager;<br>Method or attribute name: function getP2pPeerDevices(callback: AsyncCallback\<WifiP2pDevice[]>): void;<br>New version information: 201,801,2801000|@ohos.wifiManager.d.ts|
|Error code added|Class name: wifiManager;<br>Method or attribute name: function getP2pLocalDevice(callback: AsyncCallback\<WifiP2pDevice>): void;<br>Old version information: |Class name: wifiManager;<br>Method or attribute name: function getP2pLocalDevice(callback: AsyncCallback\<WifiP2pDevice>): void;<br>New version information: 201,801,2801000|@ohos.wifiManager.d.ts|
|Error code added|Class name: wifiManager;<br>Method or attribute name: function getP2pGroups(callback: AsyncCallback\<Array\<WifiP2pGroupInfo>>): void;<br>Old version information: |Class name: wifiManager;<br>Method or attribute name: function getP2pGroups(callback: AsyncCallback\<Array\<WifiP2pGroupInfo>>): void;<br>New version information: 201,202,801,2801000|@ohos.wifiManager.d.ts|
|Error code changed|Class name: connection;<br>Method or attribute name: function getDefaultNet(callback: AsyncCallback\<NetHandle>): void;<br>Old version information: 201,2100002,2100003|Class name: connection;<br>Method or attribute name: function getDefaultNet(callback: AsyncCallback\<NetHandle>): void;<br>New version information: 201,401,2100002,2100003|@ohos.net.connection.d.ts|
|Error code changed|Class name: connection;<br>Method or attribute name: function getDefaultNetSync(): NetHandle;<br>Old version information: 201,2100002,2100003|Class name: connection;<br>Method or attribute name: function getDefaultNetSync(): NetHandle;<br>New version information: 201,401,2100002,2100003|@ohos.net.connection.d.ts|
|Error code changed|Class name: connection;<br>Method or attribute name: function getAllNets(callback: AsyncCallback\<Array\<NetHandle>>): void;<br>Old version information: 201,2100002,2100003|Class name: connection;<br>Method or attribute name: function getAllNets(callback: AsyncCallback\<Array\<NetHandle>>): void;<br>New version information: 201,401,2100002,2100003|@ohos.net.connection.d.ts|
|Error code changed|Class name: connection;<br>Method or attribute name: function isDefaultNetMetered(callback: AsyncCallback\<boolean>): void;<br>Old version information: 201,2100002,2100003|Class name: connection;<br>Method or attribute name: function isDefaultNetMetered(callback: AsyncCallback\<boolean>): void;<br>New version information: 201,401,2100002,2100003|@ohos.net.connection.d.ts|
|Error code changed|Class name: connection;<br>Method or attribute name: function hasDefaultNet(callback: AsyncCallback\<boolean>): void;<br>Old version information: 201,2100002,2100003|Class name: connection;<br>Method or attribute name: function hasDefaultNet(callback: AsyncCallback\<boolean>): void;<br>New version information: 201,401,2100002,2100003|@ohos.net.connection.d.ts|
|Error code changed|Class name: connection;<br>Method or attribute name: function enableAirplaneMode(callback: AsyncCallback\<void>): void;<br>Old version information: 201,2100002,2100003|Class name: connection;<br>Method or attribute name: function enableAirplaneMode(callback: AsyncCallback\<void>): void;<br>New version information: 201,202,401,2100002,2100003|@ohos.net.connection.d.ts|
|Error code changed|Class name: connection;<br>Method or attribute name: function disableAirplaneMode(callback: AsyncCallback\<void>): void;<br>Old version information: 201,2100002,2100003|Class name: connection;<br>Method or attribute name: function disableAirplaneMode(callback: AsyncCallback\<void>): void;<br>New version information: 201,202,401,2100002,2100003|@ohos.net.connection.d.ts|
|Error code changed|Class name: connection;<br>Method or attribute name: function getAppNet(callback: AsyncCallback\<NetHandle>): void;<br>Old version information: 2100002,2100003|Class name: connection;<br>Method or attribute name: function getAppNet(callback: AsyncCallback\<NetHandle>): void;<br>New version information: 401,2100002,2100003|@ohos.net.connection.d.ts|
|Error code changed|Class name: connection;<br>Method or attribute name: function getAppNet(): Promise\<NetHandle>;<br>Old version information: 2100002,2100003|Class name: connection;<br>Method or attribute name: function getAppNet(): Promise\<NetHandle>;<br>New version information: 401,2100002,2100003|@ohos.net.connection.d.ts|
|Error code changed|Class name: connection;<br>Method or attribute name: function getGlobalHttpProxy(callback: AsyncCallback\<HttpProxy>): void;<br>Old version information: 2100002,2100003|Class name: connection;<br>Method or attribute name: function getGlobalHttpProxy(callback: AsyncCallback\<HttpProxy>): void;<br>New version information: 401,202,2100002,2100003|@ohos.net.connection.d.ts|
|Error code changed|Class name: connection;<br>Method or attribute name: function getGlobalHttpProxy(): Promise\<HttpProxy>;<br>Old version information: 2100002,2100003|Class name: connection;<br>Method or attribute name: function getGlobalHttpProxy(): Promise\<HttpProxy>;<br>New version information: 401,202,2100002,2100003|@ohos.net.connection.d.ts|
|Error code changed|Class name: connection;<br>Method or attribute name: function setGlobalHttpProxy(httpProxy: HttpProxy, callback: AsyncCallback\<void>): void;<br>Old version information: 201,401,2100001,2100002,2100003|Class name: connection;<br>Method or attribute name: function setGlobalHttpProxy(httpProxy: HttpProxy, callback: AsyncCallback\<void>): void;<br>New version information: 201,401,202,2100001,2100002,2100003|@ohos.net.connection.d.ts|
|Error code changed|Class name: connection;<br>Method or attribute name: function setGlobalHttpProxy(httpProxy: HttpProxy): Promise\<void>;<br>Old version information: 201,401,2100001,2100002,2100003|Class name: connection;<br>Method or attribute name: function setGlobalHttpProxy(httpProxy: HttpProxy): Promise\<void>;<br>New version information: 201,401,202,2100001,2100002,2100003|@ohos.net.connection.d.ts|
|Error code changed|Class name: NetConnection;<br>Method or attribute name: register(callback: AsyncCallback\<void>): void;<br>Old version information: 201,2100002,2100003,2101008,2101022|Class name: NetConnection;<br>Method or attribute name: register(callback: AsyncCallback\<void>): void;<br>New version information: 201,401,2100002,2100003,2101008,2101022|@ohos.net.connection.d.ts|
|Error code changed|Class name: NetConnection;<br>Method or attribute name: unregister(callback: AsyncCallback\<void>): void;<br>Old version information: 2100002,2100003,2101007|Class name: NetConnection;<br>Method or attribute name: unregister(callback: AsyncCallback\<void>): void;<br>New version information: 201,401,2100002,2100003,2101007|@ohos.net.connection.d.ts|
|Error code changed|Class name: ethernet;<br>Method or attribute name: function getIfaceConfig(iface: string, callback: AsyncCallback\<InterfaceConfiguration>): void;<br>Old version information: 201,401,2200001,2200002,2200003,2201005|Class name: ethernet;<br>Method or attribute name: function getIfaceConfig(iface: string, callback: AsyncCallback\<InterfaceConfiguration>): void;<br>New version information: 201,202,401,2200001,2200002,2200003,2201005|@ohos.net.ethernet.d.ts|
|Error code changed|Class name: ethernet;<br>Method or attribute name: function setIfaceConfig(iface: string, ic: InterfaceConfiguration, callback: AsyncCallback\<void>): void;<br>Old version information: 201,401,2200001,2200002,2200003,2201004,2201005,2201006,2201007|Class name: ethernet;<br>Method or attribute name: function setIfaceConfig(iface: string, ic: InterfaceConfiguration, callback: AsyncCallback\<void>): void;<br>New version information: 201,202,401,2200001,2200002,2200003,2201004,2201005,2201006,2201007|@ohos.net.ethernet.d.ts|
|Error code changed|Class name: ethernet;<br>Method or attribute name: function isIfaceActive(iface: string, callback: AsyncCallback\<number>): void;<br>Old version information: 201,401,2200001,2200002,2200003,2201005|Class name: ethernet;<br>Method or attribute name: function isIfaceActive(iface: string, callback: AsyncCallback\<number>): void;<br>New version information: 201,202,401,2200001,2200002,2200003,2201005|@ohos.net.ethernet.d.ts|
|Error code changed|Class name: ethernet;<br>Method or attribute name: function getAllActiveIfaces(callback: AsyncCallback\<Array\<string>>): void;<br>Old version information: 201,2200002,2200003|Class name: ethernet;<br>Method or attribute name: function getAllActiveIfaces(callback: AsyncCallback\<Array\<string>>): void;<br>New version information: 201,202,2200002,2200003|@ohos.net.ethernet.d.ts|
|Error code changed|Class name: sharing;<br>Method or attribute name: function isSharingSupported(callback: AsyncCallback\<boolean>): void;<br>Old version information: 201,2200002,2200003,2202011|Class name: sharing;<br>Method or attribute name: function isSharingSupported(callback: AsyncCallback\<boolean>): void;<br>New version information: 201,202,2200002,2200003,2202011|@ohos.net.sharing.d.ts|
|Error code changed|Class name: sharing;<br>Method or attribute name: function isSharing(callback: AsyncCallback\<boolean>): void;<br>Old version information: 201,2200002,2200003,2202011|Class name: sharing;<br>Method or attribute name: function isSharing(callback: AsyncCallback\<boolean>): void;<br>New version information: 201,202,2200002,2200003,2202011|@ohos.net.sharing.d.ts|
|Error code changed|Class name: sharing;<br>Method or attribute name: function startSharing(type: SharingIfaceType, callback: AsyncCallback\<void>): void;<br>Old version information: 201,401,2200001,2200002,2200003,2202004,2202005,2202006,2202009,2202011|Class name: sharing;<br>Method or attribute name: function startSharing(type: SharingIfaceType, callback: AsyncCallback\<void>): void;<br>New version information: 201,202,401,2200001,2200002,2200003,2202004,2202005,2202006,2202009,2202011|@ohos.net.sharing.d.ts|
|Error code changed|Class name: sharing;<br>Method or attribute name: function stopSharing(type: SharingIfaceType, callback: AsyncCallback\<void>): void;<br>Old version information: 201,401,2200001,2200002,2200003,2202004,2202005,2202006,2202011|Class name: sharing;<br>Method or attribute name: function stopSharing(type: SharingIfaceType, callback: AsyncCallback\<void>): void;<br>New version information: 201,202,401,2200001,2200002,2200003,2202004,2202005,2202006,2202011|@ohos.net.sharing.d.ts|
|Error code changed|Class name: sharing;<br>Method or attribute name: function getStatsRxBytes(callback: AsyncCallback\<number>): void;<br>Old version information: 201,2200002,2200003|Class name: sharing;<br>Method or attribute name: function getStatsRxBytes(callback: AsyncCallback\<number>): void;<br>New version information: 201,202,401,2200002,2200003|@ohos.net.sharing.d.ts|
|Error code changed|Class name: sharing;<br>Method or attribute name: function getStatsTxBytes(callback: AsyncCallback\<number>): void;<br>Old version information: 201,2200002,2200003|Class name: sharing;<br>Method or attribute name: function getStatsTxBytes(callback: AsyncCallback\<number>): void;<br>New version information: 201,202,401,2200002,2200003|@ohos.net.sharing.d.ts|
|Error code changed|Class name: sharing;<br>Method or attribute name: function getStatsTotalBytes(callback: AsyncCallback\<number>): void;<br>Old version information: 201,2200002,2200003|Class name: sharing;<br>Method or attribute name: function getStatsTotalBytes(callback: AsyncCallback\<number>): void;<br>New version information: 201,202,401,2200002,2200003|@ohos.net.sharing.d.ts|
|Error code changed|Class name: sharing;<br>Method or attribute name: function getSharingIfaces(state: SharingIfaceState, callback: AsyncCallback\<Array\<string>>): void;<br>Old version information: 201,401,2200001,2200002,2200003|Class name: sharing;<br>Method or attribute name: function getSharingIfaces(state: SharingIfaceState, callback: AsyncCallback\<Array\<string>>): void;<br>New version information: 201,202,401,2200001,2200002,2200003|@ohos.net.sharing.d.ts|
|Error code changed|Class name: sharing;<br>Method or attribute name: function getSharingState(type: SharingIfaceType, callback: AsyncCallback\<SharingIfaceState>): void;<br>Old version information: 201,401,2200001,2200002,2200003|Class name: sharing;<br>Method or attribute name: function getSharingState(type: SharingIfaceType, callback: AsyncCallback\<SharingIfaceState>): void;<br>New version information: 201,202,401,2200001,2200002,2200003|@ohos.net.sharing.d.ts|
|Error code changed|Class name: sharing;<br>Method or attribute name: function getSharableRegexes(type: SharingIfaceType, callback: AsyncCallback\<Array\<string>>): void;<br>Old version information: 201,401,2200001,2200002,2200003|Class name: sharing;<br>Method or attribute name: function getSharableRegexes(type: SharingIfaceType, callback: AsyncCallback\<Array\<string>>): void;<br>New version information: 201,202,401,2200001,2200002,2200003|@ohos.net.sharing.d.ts|
|Error code changed|Class name: sharing;<br>Method or attribute name: function on(type: 'sharingStateChange', callback: Callback\<boolean>): void;<br>Old version information: 201,401|Class name: sharing;<br>Method or attribute name: function on(type: 'sharingStateChange', callback: Callback\<boolean>): void;<br>New version information: 201,202,401|@ohos.net.sharing.d.ts|
|Error code changed|Class name: sharing;<br>Method or attribute name: function on(type: 'interfaceSharingStateChange', callback: Callback\<{ type: SharingIfaceType, iface: string, state: SharingIfaceState }>): void;<br>Old version information: 201,401|Class name: sharing;<br>Method or attribute name: function on(type: 'interfaceSharingStateChange', callback: Callback\<{ type: SharingIfaceType, iface: string, state: SharingIfaceState }>): void;<br>New version information: 201,202,401|@ohos.net.sharing.d.ts|
|Error code changed|Class name: sharing;<br>Method or attribute name: function on(type: 'sharingUpstreamChange', callback: Callback\<NetHandle>): void;<br>Old version information: 201,401|Class name: sharing;<br>Method or attribute name: function on(type: 'sharingUpstreamChange', callback: Callback\<NetHandle>): void;<br>New version information: 201,202,401|@ohos.net.sharing.d.ts|
|Error code changed|Class name: sharing;<br>Method or attribute name: function off(type: 'sharingStateChange', callback?: Callback\<boolean>): void;<br>Old version information: 201,401|Class name: sharing;<br>Method or attribute name: function off(type: 'sharingStateChange', callback?: Callback\<boolean>): void;<br>New version information: 201,202,401|@ohos.net.sharing.d.ts|
|Error code changed|Class name: sharing;<br>Method or attribute name: function off(type: 'interfaceSharingStateChange', callback?: Callback\<{ type: SharingIfaceType, iface: string, state: SharingIfaceState }>): void;<br>Old version information: 201,401|Class name: sharing;<br>Method or attribute name: function off(type: 'interfaceSharingStateChange', callback?: Callback\<{ type: SharingIfaceType, iface: string, state: SharingIfaceState }>): void;<br>New version information: 201,202,401|@ohos.net.sharing.d.ts|
|Error code changed|Class name: sharing;<br>Method or attribute name: function off(type: 'sharingUpstreamChange', callback?: Callback\<NetHandle>): void;<br>Old version information: 201,401|Class name: sharing;<br>Method or attribute name: function off(type: 'sharingUpstreamChange', callback?: Callback\<NetHandle>): void;<br>New version information: 201,202,401|@ohos.net.sharing.d.ts|
|Access level changed|Class name: connection;<br>Method or attribute name: function enableAirplaneMode(): Promise\<void>;<br>Old version information: |Class name: connection;<br>Method or attribute name: function enableAirplaneMode(): Promise\<void>;<br>New version information: systemapi|@ohos.net.connection.d.ts|
|Access level changed|Class name: connection;<br>Method or attribute name: function disableAirplaneMode(): Promise\<void>;<br>Old version information: |Class name: connection;<br>Method or attribute name: function disableAirplaneMode(): Promise\<void>;<br>New version information: systemapi|@ohos.net.connection.d.ts|
|Access level changed|Class name: ethernet;<br>Method or attribute name: function getIfaceConfig(iface: string): Promise\<InterfaceConfiguration>;<br>Old version information: |Class name: ethernet;<br>Method or attribute name: function getIfaceConfig(iface: string): Promise\<InterfaceConfiguration>;<br>New version information: systemapi|@ohos.net.ethernet.d.ts|
|Access level changed|Class name: ethernet;<br>Method or attribute name: function setIfaceConfig(iface: string, ic: InterfaceConfiguration): Promise\<void>;<br>Old version information: |Class name: ethernet;<br>Method or attribute name: function setIfaceConfig(iface: string, ic: InterfaceConfiguration): Promise\<void>;<br>New version information: systemapi|@ohos.net.ethernet.d.ts|
|Access level changed|Class name: ethernet;<br>Method or attribute name: function isIfaceActive(iface: string): Promise\<number>;<br>Old version information: |Class name: ethernet;<br>Method or attribute name: function isIfaceActive(iface: string): Promise\<number>;<br>New version information: systemapi|@ohos.net.ethernet.d.ts|
|Access level changed|Class name: ethernet;<br>Method or attribute name: function getAllActiveIfaces(): Promise\<Array\<string>>;<br>Old version information: |Class name: ethernet;<br>Method or attribute name: function getAllActiveIfaces(): Promise\<Array\<string>>;<br>New version information: systemapi|@ohos.net.ethernet.d.ts|
|Access level changed|Class name: InterfaceConfiguration;<br>Method or attribute name: mode: IPSetMode;<br>Old version information: |Class name: InterfaceConfiguration;<br>Method or attribute name: mode: IPSetMode;<br>New version information: systemapi|@ohos.net.ethernet.d.ts|
|Access level changed|Class name: InterfaceConfiguration;<br>Method or attribute name: ipAddr: string;<br>Old version information: |Class name: InterfaceConfiguration;<br>Method or attribute name: ipAddr: string;<br>New version information: systemapi|@ohos.net.ethernet.d.ts|
|Access level changed|Class name: InterfaceConfiguration;<br>Method or attribute name: route: string;<br>Old version information: |Class name: InterfaceConfiguration;<br>Method or attribute name: route: string;<br>New version information: systemapi|@ohos.net.ethernet.d.ts|
|Access level changed|Class name: InterfaceConfiguration;<br>Method or attribute name: gateway: string;<br>Old version information: |Class name: InterfaceConfiguration;<br>Method or attribute name: gateway: string;<br>New version information: systemapi|@ohos.net.ethernet.d.ts|
|Access level changed|Class name: InterfaceConfiguration;<br>Method or attribute name: netMask: string;<br>Old version information: |Class name: InterfaceConfiguration;<br>Method or attribute name: netMask: string;<br>New version information: systemapi|@ohos.net.ethernet.d.ts|
|Access level changed|Class name: InterfaceConfiguration;<br>Method or attribute name: dnsServers: string;<br>Old version information: |Class name: InterfaceConfiguration;<br>Method or attribute name: dnsServers: string;<br>New version information: systemapi|@ohos.net.ethernet.d.ts|
|Access level changed|Class name: IPSetMode;<br>Method or attribute name: STATIC = 0<br>Old version information: |Class name: IPSetMode;<br>Method or attribute name: STATIC = 0<br>New version information: systemapi|@ohos.net.ethernet.d.ts|
|Access level changed|Class name: IPSetMode;<br>Method or attribute name: DHCP = 1<br>Old version information: |Class name: IPSetMode;<br>Method or attribute name: DHCP = 1<br>New version information: systemapi|@ohos.net.ethernet.d.ts|
|Access level changed|Class name: sharing;<br>Method or attribute name: function isSharingSupported(): Promise\<boolean>;<br>Old version information: |Class name: sharing;<br>Method or attribute name: function isSharingSupported(): Promise\<boolean>;<br>New version information: systemapi|@ohos.net.sharing.d.ts|
|Access level changed|Class name: sharing;<br>Method or attribute name: function isSharing(): Promise\<boolean>;<br>Old version information: |Class name: sharing;<br>Method or attribute name: function isSharing(): Promise\<boolean>;<br>New version information: systemapi|@ohos.net.sharing.d.ts|
|Access level changed|Class name: sharing;<br>Method or attribute name: function startSharing(type: SharingIfaceType): Promise\<void>;<br>Old version information: |Class name: sharing;<br>Method or attribute name: function startSharing(type: SharingIfaceType): Promise\<void>;<br>New version information: systemapi|@ohos.net.sharing.d.ts|
|Access level changed|Class name: sharing;<br>Method or attribute name: function stopSharing(type: SharingIfaceType): Promise\<void>;<br>Old version information: |Class name: sharing;<br>Method or attribute name: function stopSharing(type: SharingIfaceType): Promise\<void>;<br>New version information: systemapi|@ohos.net.sharing.d.ts|
|Access level changed|Class name: sharing;<br>Method or attribute name: function getStatsRxBytes(): Promise\<number>;<br>Old version information: |Class name: sharing;<br>Method or attribute name: function getStatsRxBytes(): Promise\<number>;<br>New version information: systemapi|@ohos.net.sharing.d.ts|
|Access level changed|Class name: sharing;<br>Method or attribute name: function getStatsTxBytes(): Promise\<number>;<br>Old version information: |Class name: sharing;<br>Method or attribute name: function getStatsTxBytes(): Promise\<number>;<br>New version information: systemapi|@ohos.net.sharing.d.ts|
|Access level changed|Class name: sharing;<br>Method or attribute name: function getStatsTotalBytes(): Promise\<number>;<br>Old version information: |Class name: sharing;<br>Method or attribute name: function getStatsTotalBytes(): Promise\<number>;<br>New version information: systemapi|@ohos.net.sharing.d.ts|
|Access level changed|Class name: sharing;<br>Method or attribute name: function getSharingIfaces(state: SharingIfaceState): Promise\<Array\<string>>;<br>Old version information: |Class name: sharing;<br>Method or attribute name: function getSharingIfaces(state: SharingIfaceState): Promise\<Array\<string>>;<br>New version information: systemapi|@ohos.net.sharing.d.ts|
|Access level changed|Class name: sharing;<br>Method or attribute name: function getSharingState(type: SharingIfaceType): Promise\<SharingIfaceState>;<br>Old version information: |Class name: sharing;<br>Method or attribute name: function getSharingState(type: SharingIfaceType): Promise\<SharingIfaceState>;<br>New version information: systemapi|@ohos.net.sharing.d.ts|
|Access level changed|Class name: sharing;<br>Method or attribute name: function getSharableRegexes(type: SharingIfaceType): Promise\<Array\<string>>;<br>Old version information: |Class name: sharing;<br>Method or attribute name: function getSharableRegexes(type: SharingIfaceType): Promise\<Array\<string>>;<br>New version information: systemapi|@ohos.net.sharing.d.ts|
|Access level changed|Class name: SharingIfaceState;<br>Method or attribute name: SHARING_NIC_SERVING = 1<br>Old version information: |Class name: SharingIfaceState;<br>Method or attribute name: SHARING_NIC_SERVING = 1<br>New version information: systemapi|@ohos.net.sharing.d.ts|
|Access level changed|Class name: SharingIfaceState;<br>Method or attribute name: SHARING_NIC_CAN_SERVER = 2<br>Old version information: |Class name: SharingIfaceState;<br>Method or attribute name: SHARING_NIC_CAN_SERVER = 2<br>New version information: systemapi|@ohos.net.sharing.d.ts|
|Access level changed|Class name: SharingIfaceState;<br>Method or attribute name: SHARING_NIC_ERROR = 3<br>Old version information: |Class name: SharingIfaceState;<br>Method or attribute name: SHARING_NIC_ERROR = 3<br>New version information: systemapi|@ohos.net.sharing.d.ts|
|Access level changed|Class name: SharingIfaceType;<br>Method or attribute name: SHARING_WIFI = 0<br>Old version information: |Class name: SharingIfaceType;<br>Method or attribute name: SHARING_WIFI = 0<br>New version information: systemapi|@ohos.net.sharing.d.ts|
|Access level changed|Class name: SharingIfaceType;<br>Method or attribute name: SHARING_USB = 1<br>Old version information: |Class name: SharingIfaceType;<br>Method or attribute name: SHARING_USB = 1<br>New version information: systemapi|@ohos.net.sharing.d.ts|
|Access level changed|Class name: SharingIfaceType;<br>Method or attribute name: SHARING_BLUETOOTH = 2<br>Old version information: |Class name: SharingIfaceType;<br>Method or attribute name: SHARING_BLUETOOTH = 2<br>New version information: systemapi|@ohos.net.sharing.d.ts|
|Access level changed|Class name: wifiManager;<br>Method or attribute name: function addDeviceConfig(config: WifiDeviceConfig, callback: AsyncCallback\<number>): void;<br>Old version information: |Class name: wifiManager;<br>Method or attribute name: function addDeviceConfig(config: WifiDeviceConfig, callback: AsyncCallback\<number>): void;<br>New version information: systemapi|@ohos.wifiManager.d.ts|
|Access level changed|Class name: wifiManager;<br>Method or attribute name: function getP2pGroups(callback: AsyncCallback\<Array\<WifiP2pGroupInfo>>): void;<br>Old version information: |Class name: wifiManager;<br>Method or attribute name: function getP2pGroups(callback: AsyncCallback\<Array\<WifiP2pGroupInfo>>): void;<br>New version information: systemapi|@ohos.wifiManager.d.ts|
|Access level changed|Class name: EapMethod;<br>Method or attribute name: enum EapMethod<br>Old version information: systemapi|Class name: EapMethod;<br>Method or attribute name: enum EapMethod<br>New version information: |@ohos.wifiManager.d.ts|
|Access level changed|Class name: Phase2Method;<br>Method or attribute name: enum Phase2Method<br>Old version information: systemapi|Class name: Phase2Method;<br>Method or attribute name: enum Phase2Method<br>New version information: |@ohos.wifiManager.d.ts|
|Access level changed|Class name: WifiEapConfig;<br>Method or attribute name: interface WifiEapConfig<br>Old version information: systemapi|Class name: WifiEapConfig;<br>Method or attribute name: interface WifiEapConfig<br>New version information: |@ohos.wifiManager.d.ts|
|Access level changed|Class name: WifiDeviceConfig;<br>Method or attribute name: creatorUid?: number;<br>Old version information: |Class name: WifiDeviceConfig;<br>Method or attribute name: creatorUid?: number;<br>New version information: systemapi|@ohos.wifiManager.d.ts|
|Access level changed|Class name: WifiDeviceConfig;<br>Method or attribute name: disableReason?: number;<br>Old version information: |Class name: WifiDeviceConfig;<br>Method or attribute name: disableReason?: number;<br>New version information: systemapi|@ohos.wifiManager.d.ts|
|Access level changed|Class name: WifiDeviceConfig;<br>Method or attribute name: netId?: number;<br>Old version information: |Class name: WifiDeviceConfig;<br>Method or attribute name: netId?: number;<br>New version information: systemapi|@ohos.wifiManager.d.ts|
|Access level changed|Class name: WifiDeviceConfig;<br>Method or attribute name: randomMacType?: number;<br>Old version information: |Class name: WifiDeviceConfig;<br>Method or attribute name: randomMacType?: number;<br>New version information: systemapi|@ohos.wifiManager.d.ts|
|Access level changed|Class name: WifiDeviceConfig;<br>Method or attribute name: randomMacAddr?: string;<br>Old version information: |Class name: WifiDeviceConfig;<br>Method or attribute name: randomMacAddr?: string;<br>New version information: systemapi|@ohos.wifiManager.d.ts|
|Access level changed|Class name: WifiDeviceConfig;<br>Method or attribute name: ipType?: IpType;<br>Old version information: |Class name: WifiDeviceConfig;<br>Method or attribute name: ipType?: IpType;<br>New version information: systemapi|@ohos.wifiManager.d.ts|
|Access level changed|Class name: WifiDeviceConfig;<br>Method or attribute name: staticIp?: IpConfig;<br>Old version information: |Class name: WifiDeviceConfig;<br>Method or attribute name: staticIp?: IpConfig;<br>New version information: systemapi|@ohos.wifiManager.d.ts|
|Access level changed|Class name: WifiDeviceConfig;<br>Method or attribute name: eapConfig?: WifiEapConfig;<br>Old version information: systemapi|Class name: WifiDeviceConfig;<br>Method or attribute name: eapConfig?: WifiEapConfig;<br>New version information: |@ohos.wifiManager.d.ts|
|Access level changed|Class name: IpConfig;<br>Method or attribute name: ipAddress: number;<br>Old version information: |Class name: IpConfig;<br>Method or attribute name: ipAddress: number;<br>New version information: systemapi|@ohos.wifiManager.d.ts|
|Access level changed|Class name: IpConfig;<br>Method or attribute name: gateway: number;<br>Old version information: |Class name: IpConfig;<br>Method or attribute name: gateway: number;<br>New version information: systemapi|@ohos.wifiManager.d.ts|
|Access level changed|Class name: IpConfig;<br>Method or attribute name: prefixLength: number;<br>Old version information: |Class name: IpConfig;<br>Method or attribute name: prefixLength: number;<br>New version information: systemapi|@ohos.wifiManager.d.ts|
|Access level changed|Class name: IpConfig;<br>Method or attribute name: dnsServers: number[];<br>Old version information: |Class name: IpConfig;<br>Method or attribute name: dnsServers: number[];<br>New version information: systemapi|@ohos.wifiManager.d.ts|
|Access level changed|Class name: IpConfig;<br>Method or attribute name: domains: Array\<string>;<br>Old version information: |Class name: IpConfig;<br>Method or attribute name: domains: Array\<string>;<br>New version information: systemapi|@ohos.wifiManager.d.ts|
|Access level changed|Class name: WifiLinkedInfo;<br>Method or attribute name: networkId: number;<br>Old version information: |Class name: WifiLinkedInfo;<br>Method or attribute name: networkId: number;<br>New version information: systemapi|@ohos.wifiManager.d.ts|
|Access level changed|Class name: WifiLinkedInfo;<br>Method or attribute name: chload: number;<br>Old version information: |Class name: WifiLinkedInfo;<br>Method or attribute name: chload: number;<br>New version information: systemapi|@ohos.wifiManager.d.ts|
|Access level changed|Class name: WifiLinkedInfo;<br>Method or attribute name: snr: number;<br>Old version information: |Class name: WifiLinkedInfo;<br>Method or attribute name: snr: number;<br>New version information: systemapi|@ohos.wifiManager.d.ts|
|Access level changed|Class name: WifiLinkedInfo;<br>Method or attribute name: suppState: SuppState;<br>Old version information: |Class name: WifiLinkedInfo;<br>Method or attribute name: suppState: SuppState;<br>New version information: systemapi|@ohos.wifiManager.d.ts|
|Access level changed|Class name: HotspotConfig;<br>Method or attribute name: ssid: string;<br>Old version information: |Class name: HotspotConfig;<br>Method or attribute name: ssid: string;<br>New version information: systemapi|@ohos.wifiManager.d.ts|
|Access level changed|Class name: HotspotConfig;<br>Method or attribute name: securityType: WifiSecurityType;<br>Old version information: |Class name: HotspotConfig;<br>Method or attribute name: securityType: WifiSecurityType;<br>New version information: systemapi|@ohos.wifiManager.d.ts|
|Access level changed|Class name: HotspotConfig;<br>Method or attribute name: band: number;<br>Old version information: |Class name: HotspotConfig;<br>Method or attribute name: band: number;<br>New version information: systemapi|@ohos.wifiManager.d.ts|
|Access level changed|Class name: HotspotConfig;<br>Method or attribute name: channel?: number;<br>Old version information: |Class name: HotspotConfig;<br>Method or attribute name: channel?: number;<br>New version information: systemapi|@ohos.wifiManager.d.ts|
|Access level changed|Class name: HotspotConfig;<br>Method or attribute name: preSharedKey: string;<br>Old version information: |Class name: HotspotConfig;<br>Method or attribute name: preSharedKey: string;<br>New version information: systemapi|@ohos.wifiManager.d.ts|
|Access level changed|Class name: HotspotConfig;<br>Method or attribute name: maxConn: number;<br>Old version information: |Class name: HotspotConfig;<br>Method or attribute name: maxConn: number;<br>New version information: systemapi|@ohos.wifiManager.d.ts|
|Access level changed|Class name: StationInfo;<br>Method or attribute name: name: string;<br>Old version information: |Class name: StationInfo;<br>Method or attribute name: name: string;<br>New version information: systemapi|@ohos.wifiManager.d.ts|
|Access level changed|Class name: StationInfo;<br>Method or attribute name: macAddress: string;<br>Old version information: |Class name: StationInfo;<br>Method or attribute name: macAddress: string;<br>New version information: systemapi|@ohos.wifiManager.d.ts|
|Access level changed|Class name: StationInfo;<br>Method or attribute name: ipAddress: string;<br>Old version information: |Class name: StationInfo;<br>Method or attribute name: ipAddress: string;<br>New version information: systemapi|@ohos.wifiManager.d.ts|
|Access level changed|Class name: IpType;<br>Method or attribute name: STATIC<br>Old version information: |Class name: IpType;<br>Method or attribute name: STATIC<br>New version information: systemapi|@ohos.wifiManager.d.ts|
|Access level changed|Class name: IpType;<br>Method or attribute name: DHCP<br>Old version information: |Class name: IpType;<br>Method or attribute name: DHCP<br>New version information: systemapi|@ohos.wifiManager.d.ts|
|Access level changed|Class name: IpType;<br>Method or attribute name: UNKNOWN<br>Old version information: |Class name: IpType;<br>Method or attribute name: UNKNOWN<br>New version information: systemapi|@ohos.wifiManager.d.ts|
|Access level changed|Class name: SuppState;<br>Method or attribute name: DISCONNECTED<br>Old version information: |Class name: SuppState;<br>Method or attribute name: DISCONNECTED<br>New version information: systemapi|@ohos.wifiManager.d.ts|
|Access level changed|Class name: SuppState;<br>Method or attribute name: INTERFACE_DISABLED<br>Old version information: |Class name: SuppState;<br>Method or attribute name: INTERFACE_DISABLED<br>New version information: systemapi|@ohos.wifiManager.d.ts|
|Access level changed|Class name: SuppState;<br>Method or attribute name: INACTIVE<br>Old version information: |Class name: SuppState;<br>Method or attribute name: INACTIVE<br>New version information: systemapi|@ohos.wifiManager.d.ts|
|Access level changed|Class name: SuppState;<br>Method or attribute name: SCANNING<br>Old version information: |Class name: SuppState;<br>Method or attribute name: SCANNING<br>New version information: systemapi|@ohos.wifiManager.d.ts|
|Access level changed|Class name: SuppState;<br>Method or attribute name: AUTHENTICATING<br>Old version information: |Class name: SuppState;<br>Method or attribute name: AUTHENTICATING<br>New version information: systemapi|@ohos.wifiManager.d.ts|
|Access level changed|Class name: SuppState;<br>Method or attribute name: ASSOCIATING<br>Old version information: |Class name: SuppState;<br>Method or attribute name: ASSOCIATING<br>New version information: systemapi|@ohos.wifiManager.d.ts|
|Access level changed|Class name: SuppState;<br>Method or attribute name: ASSOCIATED<br>Old version information: |Class name: SuppState;<br>Method or attribute name: ASSOCIATED<br>New version information: systemapi|@ohos.wifiManager.d.ts|
|Access level changed|Class name: SuppState;<br>Method or attribute name: FOUR_WAY_HANDSHAKE<br>Old version information: |Class name: SuppState;<br>Method or attribute name: FOUR_WAY_HANDSHAKE<br>New version information: systemapi|@ohos.wifiManager.d.ts|
|Access level changed|Class name: SuppState;<br>Method or attribute name: GROUP_HANDSHAKE<br>Old version information: |Class name: SuppState;<br>Method or attribute name: GROUP_HANDSHAKE<br>New version information: systemapi|@ohos.wifiManager.d.ts|
|Access level changed|Class name: SuppState;<br>Method or attribute name: COMPLETED<br>Old version information: |Class name: SuppState;<br>Method or attribute name: COMPLETED<br>New version information: systemapi|@ohos.wifiManager.d.ts|
|Access level changed|Class name: SuppState;<br>Method or attribute name: UNINITIALIZED<br>Old version information: |Class name: SuppState;<br>Method or attribute name: UNINITIALIZED<br>New version information: systemapi|@ohos.wifiManager.d.ts|
|Access level changed|Class name: SuppState;<br>Method or attribute name: INVALID<br>Old version information: |Class name: SuppState;<br>Method or attribute name: INVALID<br>New version information: systemapi|@ohos.wifiManager.d.ts|
|Permission changed|Class name: GattClientDevice;<br>Method or attribute name: getDeviceName(): Promise\<string>;<br>Old version information: |Class name: GattClientDevice;<br>Method or attribute name: getDeviceName(): Promise\<string>;<br>New version information: ohos.permission.USE_BLUETOOTH|@ohos.bluetoothManager.d.ts|
|Permission changed|Class name: GattClientDevice;<br>Method or attribute name: getServices(): Promise\<Array\<GattService>>;<br>Old version information: |Class name: GattClientDevice;<br>Method or attribute name: getServices(): Promise\<Array\<GattService>>;<br>New version information: ohos.permission.USE_BLUETOOTH|@ohos.bluetoothManager.d.ts|
|Permission changed|Class name: GattClientDevice;<br>Method or attribute name: readCharacteristicValue(characteristic: BLECharacteristic): Promise\<BLECharacteristic>;<br>Old version information: |Class name: GattClientDevice;<br>Method or attribute name: readCharacteristicValue(characteristic: BLECharacteristic): Promise\<BLECharacteristic>;<br>New version information: ohos.permission.USE_BLUETOOTH|@ohos.bluetoothManager.d.ts|
|Permission changed|Class name: GattClientDevice;<br>Method or attribute name: readDescriptorValue(descriptor: BLEDescriptor): Promise\<BLEDescriptor>;<br>Old version information: |Class name: GattClientDevice;<br>Method or attribute name: readDescriptorValue(descriptor: BLEDescriptor): Promise\<BLEDescriptor>;<br>New version information: ohos.permission.USE_BLUETOOTH|@ohos.bluetoothManager.d.ts|
|Permission changed|Class name: GattClientDevice;<br>Method or attribute name: getRssiValue(): Promise\<number>;<br>Old version information: |Class name: GattClientDevice;<br>Method or attribute name: getRssiValue(): Promise\<number>;<br>New version information: ohos.permission.USE_BLUETOOTH|@ohos.bluetoothManager.d.ts|
|Permission changed|Class name: connection;<br>Method or attribute name: function getDefaultNet(): Promise\<NetHandle>;<br>Old version information: |Class name: connection;<br>Method or attribute name: function getDefaultNet(): Promise\<NetHandle>;<br>New version information: ohos.permission.GET_NETWORK_INFO|@ohos.net.connection.d.ts|
|Permission changed|Class name: connection;<br>Method or attribute name: function getAllNets(): Promise\<Array\<NetHandle>>;<br>Old version information: |Class name: connection;<br>Method or attribute name: function getAllNets(): Promise\<Array\<NetHandle>>;<br>New version information: ohos.permission.GET_NETWORK_INFO|@ohos.net.connection.d.ts|
|Permission changed|Class name: connection;<br>Method or attribute name: function getConnectionProperties(netHandle: NetHandle): Promise\<ConnectionProperties>;<br>Old version information: |Class name: connection;<br>Method or attribute name: function getConnectionProperties(netHandle: NetHandle): Promise\<ConnectionProperties>;<br>New version information: ohos.permission.GET_NETWORK_INFO|@ohos.net.connection.d.ts|
|Permission changed|Class name: connection;<br>Method or attribute name: function getNetCapabilities(netHandle: NetHandle): Promise\<NetCapabilities>;<br>Old version information: |Class name: connection;<br>Method or attribute name: function getNetCapabilities(netHandle: NetHandle): Promise\<NetCapabilities>;<br>New version information: ohos.permission.GET_NETWORK_INFO|@ohos.net.connection.d.ts|
|Permission changed|Class name: connection;<br>Method or attribute name: function isDefaultNetMetered(): Promise\<boolean>;<br>Old version information: |Class name: connection;<br>Method or attribute name: function isDefaultNetMetered(): Promise\<boolean>;<br>New version information: ohos.permission.GET_NETWORK_INFO|@ohos.net.connection.d.ts|
|Permission changed|Class name: connection;<br>Method or attribute name: function hasDefaultNet(): Promise\<boolean>;<br>Old version information: |Class name: connection;<br>Method or attribute name: function hasDefaultNet(): Promise\<boolean>;<br>New version information: ohos.permission.GET_NETWORK_INFO|@ohos.net.connection.d.ts|
|Permission changed|Class name: connection;<br>Method or attribute name: function enableAirplaneMode(): Promise\<void>;<br>Old version information: |Class name: connection;<br>Method or attribute name: function enableAirplaneMode(): Promise\<void>;<br>New version information: ohos.permission.CONNECTIVITY_INTERNAL|@ohos.net.connection.d.ts|
|Permission changed|Class name: connection;<br>Method or attribute name: function disableAirplaneMode(): Promise\<void>;<br>Old version information: |Class name: connection;<br>Method or attribute name: function disableAirplaneMode(): Promise\<void>;<br>New version information: ohos.permission.CONNECTIVITY_INTERNAL|@ohos.net.connection.d.ts|
|Permission changed|Class name: connection;<br>Method or attribute name: function reportNetConnected(netHandle: NetHandle): Promise\<void>;<br>Old version information: |Class name: connection;<br>Method or attribute name: function reportNetConnected(netHandle: NetHandle): Promise\<void>;<br>New version information: ohos.permission.GET_NETWORK_INFO,ohos.permission.INTERNET|@ohos.net.connection.d.ts|
|Permission changed|Class name: connection;<br>Method or attribute name: function reportNetDisconnected(netHandle: NetHandle): Promise\<void>;<br>Old version information: |Class name: connection;<br>Method or attribute name: function reportNetDisconnected(netHandle: NetHandle): Promise\<void>;<br>New version information: ohos.permission.GET_NETWORK_INFO,ohos.permission.INTERNET|@ohos.net.connection.d.ts|
|Permission changed|Class name: connection;<br>Method or attribute name: function getAddressesByName(host: string): Promise\<Array\<NetAddress>>;<br>Old version information: |Class name: connection;<br>Method or attribute name: function getAddressesByName(host: string): Promise\<Array\<NetAddress>>;<br>New version information: ohos.permission.INTERNET|@ohos.net.connection.d.ts|
|Permission changed|Class name: NetHandle;<br>Method or attribute name: getAddressesByName(host: string): Promise\<Array\<NetAddress>>;<br>Old version information: |Class name: NetHandle;<br>Method or attribute name: getAddressesByName(host: string): Promise\<Array\<NetAddress>>;<br>New version information: ohos.permission.INTERNET|@ohos.net.connection.d.ts|
|Permission changed|Class name: NetHandle;<br>Method or attribute name: getAddressByName(host: string): Promise\<NetAddress>;<br>Old version information: |Class name: NetHandle;<br>Method or attribute name: getAddressByName(host: string): Promise\<NetAddress>;<br>New version information: ohos.permission.INTERNET|@ohos.net.connection.d.ts|
|Permission changed|Class name: ethernet;<br>Method or attribute name: function getIfaceConfig(iface: string): Promise\<InterfaceConfiguration>;<br>Old version information: |Class name: ethernet;<br>Method or attribute name: function getIfaceConfig(iface: string): Promise\<InterfaceConfiguration>;<br>New version information: ohos.permission.GET_NETWORK_INFO|@ohos.net.ethernet.d.ts|
|Permission changed|Class name: ethernet;<br>Method or attribute name: function setIfaceConfig(iface: string, ic: InterfaceConfiguration): Promise\<void>;<br>Old version information: |Class name: ethernet;<br>Method or attribute name: function setIfaceConfig(iface: string, ic: InterfaceConfiguration): Promise\<void>;<br>New version information: ohos.permission.CONNECTIVITY_INTERNAL|@ohos.net.ethernet.d.ts|
|Permission changed|Class name: ethernet;<br>Method or attribute name: function isIfaceActive(iface: string): Promise\<number>;<br>Old version information: |Class name: ethernet;<br>Method or attribute name: function isIfaceActive(iface: string): Promise\<number>;<br>New version information: ohos.permission.GET_NETWORK_INFO|@ohos.net.ethernet.d.ts|
|Permission changed|Class name: ethernet;<br>Method or attribute name: function getAllActiveIfaces(): Promise\<Array\<string>>;<br>Old version information: |Class name: ethernet;<br>Method or attribute name: function getAllActiveIfaces(): Promise\<Array\<string>>;<br>New version information: ohos.permission.GET_NETWORK_INFO|@ohos.net.ethernet.d.ts|
|Permission changed|Class name: HttpRequest;<br>Method or attribute name: request(url: string, options: HttpRequestOptions, callback: AsyncCallback\<HttpResponse>): void;<br>Old version information: |Class name: HttpRequest;<br>Method or attribute name: request(url: string, options: HttpRequestOptions, callback: AsyncCallback\<HttpResponse>): void;<br>New version information: ohos.permission.INTERNET|@ohos.net.http.d.ts|
|Permission changed|Class name: HttpRequest;<br>Method or attribute name: request(url: string, options?: HttpRequestOptions): Promise\<HttpResponse>;<br>Old version information: |Class name: HttpRequest;<br>Method or attribute name: request(url: string, options?: HttpRequestOptions): Promise\<HttpResponse>;<br>New version information: ohos.permission.INTERNET|@ohos.net.http.d.ts|
|Permission changed|Class name: sharing;<br>Method or attribute name: function isSharingSupported(): Promise\<boolean>;<br>Old version information: |Class name: sharing;<br>Method or attribute name: function isSharingSupported(): Promise\<boolean>;<br>New version information: ohos.permission.CONNECTIVITY_INTERNAL|@ohos.net.sharing.d.ts|
|Permission changed|Class name: sharing;<br>Method or attribute name: function isSharing(): Promise\<boolean>;<br>Old version information: |Class name: sharing;<br>Method or attribute name: function isSharing(): Promise\<boolean>;<br>New version information: ohos.permission.CONNECTIVITY_INTERNAL|@ohos.net.sharing.d.ts|
|Permission changed|Class name: sharing;<br>Method or attribute name: function startSharing(type: SharingIfaceType): Promise\<void>;<br>Old version information: |Class name: sharing;<br>Method or attribute name: function startSharing(type: SharingIfaceType): Promise\<void>;<br>New version information: ohos.permission.CONNECTIVITY_INTERNAL|@ohos.net.sharing.d.ts|
|Permission changed|Class name: sharing;<br>Method or attribute name: function stopSharing(type: SharingIfaceType): Promise\<void>;<br>Old version information: |Class name: sharing;<br>Method or attribute name: function stopSharing(type: SharingIfaceType): Promise\<void>;<br>New version information: ohos.permission.CONNECTIVITY_INTERNAL|@ohos.net.sharing.d.ts|
|Permission changed|Class name: sharing;<br>Method or attribute name: function getStatsRxBytes(): Promise\<number>;<br>Old version information: |Class name: sharing;<br>Method or attribute name: function getStatsRxBytes(): Promise\<number>;<br>New version information: ohos.permission.CONNECTIVITY_INTERNAL|@ohos.net.sharing.d.ts|
|Permission changed|Class name: sharing;<br>Method or attribute name: function getStatsTxBytes(): Promise\<number>;<br>Old version information: |Class name: sharing;<br>Method or attribute name: function getStatsTxBytes(): Promise\<number>;<br>New version information: ohos.permission.CONNECTIVITY_INTERNAL|@ohos.net.sharing.d.ts|
|Permission changed|Class name: sharing;<br>Method or attribute name: function getStatsTotalBytes(): Promise\<number>;<br>Old version information: |Class name: sharing;<br>Method or attribute name: function getStatsTotalBytes(): Promise\<number>;<br>New version information: ohos.permission.CONNECTIVITY_INTERNAL|@ohos.net.sharing.d.ts|
|Permission changed|Class name: sharing;<br>Method or attribute name: function getSharingIfaces(state: SharingIfaceState): Promise\<Array\<string>>;<br>Old version information: |Class name: sharing;<br>Method or attribute name: function getSharingIfaces(state: SharingIfaceState): Promise\<Array\<string>>;<br>New version information: ohos.permission.CONNECTIVITY_INTERNAL|@ohos.net.sharing.d.ts|
|Permission changed|Class name: sharing;<br>Method or attribute name: function getSharingState(type: SharingIfaceType): Promise\<SharingIfaceState>;<br>Old version information: |Class name: sharing;<br>Method or attribute name: function getSharingState(type: SharingIfaceType): Promise\<SharingIfaceState>;<br>New version information: ohos.permission.CONNECTIVITY_INTERNAL|@ohos.net.sharing.d.ts|
|Permission changed|Class name: sharing;<br>Method or attribute name: function getSharableRegexes(type: SharingIfaceType): Promise\<Array\<string>>;<br>Old version information: |Class name: sharing;<br>Method or attribute name: function getSharableRegexes(type: SharingIfaceType): Promise\<Array\<string>>;<br>New version information: ohos.permission.CONNECTIVITY_INTERNAL|@ohos.net.sharing.d.ts|
|Permission changed|Class name: UDPSocket;<br>Method or attribute name: bind(address: NetAddress): Promise\<void>;<br>Old version information: |Class name: UDPSocket;<br>Method or attribute name: bind(address: NetAddress): Promise\<void>;<br>New version information: ohos.permission.INTERNET|@ohos.net.socket.d.ts|
|Permission changed|Class name: TCPSocket;<br>Method or attribute name: bind(address: NetAddress): Promise\<void>;<br>Old version information: |Class name: TCPSocket;<br>Method or attribute name: bind(address: NetAddress): Promise\<void>;<br>New version information: ohos.permission.INTERNET|@ohos.net.socket.d.ts|
|Permission changed|Class name: TLSSocket;<br>Method or attribute name: bind(address: NetAddress): Promise\<void>;<br>Old version information: |Class name: TLSSocket;<br>Method or attribute name: bind(address: NetAddress): Promise\<void>;<br>New version information: ohos.permission.INTERNET|@ohos.net.socket.d.ts|
|Permission changed|Class name: UDPSocket;<br>Method or attribute name: send(options: UDPSendOptions): Promise\<void>;<br>Old version information: |Class name: UDPSocket;<br>Method or attribute name: send(options: UDPSendOptions): Promise\<void>;<br>New version information: ohos.permission.INTERNET|@ohos.net.socket.d.ts|
|Permission changed|Class name: UDPSocket;<br>Method or attribute name: close(): Promise\<void>;<br>Old version information: |Class name: UDPSocket;<br>Method or attribute name: close(): Promise\<void>;<br>New version information: ohos.permission.INTERNET|@ohos.net.socket.d.ts|
|Permission changed|Class name: TCPSocket;<br>Method or attribute name: close(): Promise\<void>;<br>Old version information: |Class name: TCPSocket;<br>Method or attribute name: close(): Promise\<void>;<br>New version information: ohos.permission.INTERNET|@ohos.net.socket.d.ts|
|Permission changed|Class name: UDPSocket;<br>Method or attribute name: getState(): Promise\<SocketStateBase>;<br>Old version information: |Class name: UDPSocket;<br>Method or attribute name: getState(): Promise\<SocketStateBase>;<br>New version information: ohos.permission.INTERNET|@ohos.net.socket.d.ts|
|Permission changed|Class name: TCPSocket;<br>Method or attribute name: getState(): Promise\<SocketStateBase>;<br>Old version information: |Class name: TCPSocket;<br>Method or attribute name: getState(): Promise\<SocketStateBase>;<br>New version information: ohos.permission.INTERNET|@ohos.net.socket.d.ts|
|Permission changed|Class name: UDPSocket;<br>Method or attribute name: setExtraOptions(options: UDPExtraOptions): Promise\<void>;<br>Old version information: |Class name: UDPSocket;<br>Method or attribute name: setExtraOptions(options: UDPExtraOptions): Promise\<void>;<br>New version information: ohos.permission.INTERNET|@ohos.net.socket.d.ts|
|Permission changed|Class name: TCPSocket;<br>Method or attribute name: connect(options: TCPConnectOptions): Promise\<void>;<br>Old version information: |Class name: TCPSocket;<br>Method or attribute name: connect(options: TCPConnectOptions): Promise\<void>;<br>New version information: ohos.permission.INTERNET|@ohos.net.socket.d.ts|
|Permission changed|Class name: TCPSocket;<br>Method or attribute name: send(options: TCPSendOptions): Promise\<void>;<br>Old version information: |Class name: TCPSocket;<br>Method or attribute name: send(options: TCPSendOptions): Promise\<void>;<br>New version information: ohos.permission.INTERNET|@ohos.net.socket.d.ts|
|Permission changed|Class name: TCPSocket;<br>Method or attribute name: getRemoteAddress(): Promise\<NetAddress>;<br>Old version information: |Class name: TCPSocket;<br>Method or attribute name: getRemoteAddress(): Promise\<NetAddress>;<br>New version information: ohos.permission.INTERNET|@ohos.net.socket.d.ts|
|Permission changed|Class name: TCPSocket;<br>Method or attribute name: setExtraOptions(options: TCPExtraOptions): Promise\<void>;<br>Old version information: |Class name: TCPSocket;<br>Method or attribute name: setExtraOptions(options: TCPExtraOptions): Promise\<void>;<br>New version information: ohos.permission.INTERNET|@ohos.net.socket.d.ts|
|Permission changed|Class name: WebSocket;<br>Method or attribute name: connect(url: string, options: WebSocketRequestOptions, callback: AsyncCallback\<boolean>): void;<br>Old version information: |Class name: WebSocket;<br>Method or attribute name: connect(url: string, options: WebSocketRequestOptions, callback: AsyncCallback\<boolean>): void;<br>New version information: ohos.permission.INTERNET|@ohos.net.webSocket.d.ts|
|Permission changed|Class name: WebSocket;<br>Method or attribute name: connect(url: string, options?: WebSocketRequestOptions): Promise\<boolean>;<br>Old version information: |Class name: WebSocket;<br>Method or attribute name: connect(url: string, options?: WebSocketRequestOptions): Promise\<boolean>;<br>New version information: ohos.permission.INTERNET|@ohos.net.webSocket.d.ts|
|Permission changed|Class name: WebSocket;<br>Method or attribute name: send(data: string \| ArrayBuffer): Promise\<boolean>;<br>Old version information: |Class name: WebSocket;<br>Method or attribute name: send(data: string \| ArrayBuffer): Promise\<boolean>;<br>New version information: ohos.permission.INTERNET|@ohos.net.webSocket.d.ts|
|Permission changed|Class name: WebSocket;<br>Method or attribute name: close(options: WebSocketCloseOptions, callback: AsyncCallback\<boolean>): void;<br>Old version information: |Class name: WebSocket;<br>Method or attribute name: close(options: WebSocketCloseOptions, callback: AsyncCallback\<boolean>): void;<br>New version information: ohos.permission.INTERNET|@ohos.net.webSocket.d.ts|
|Permission changed|Class name: WebSocket;<br>Method or attribute name: close(options?: WebSocketCloseOptions): Promise\<boolean>;<br>Old version information: |Class name: WebSocket;<br>Method or attribute name: close(options?: WebSocketCloseOptions): Promise\<boolean>;<br>New version information: ohos.permission.INTERNET|@ohos.net.webSocket.d.ts|
|Permission changed|Class name: wifiManager;<br>Method or attribute name: function addDeviceConfig(config: WifiDeviceConfig, callback: AsyncCallback\<number>): void;<br>Old version information: |Class name: wifiManager;<br>Method or attribute name: function addDeviceConfig(config: WifiDeviceConfig, callback: AsyncCallback\<number>): void;<br>New version information: ohos.permission.SET_WIFI_INFO,ohos.permission.SET_WIFI_CONFIG|@ohos.wifiManager.d.ts|
|Permission changed|Class name: wifiManager;<br>Method or attribute name: function addCandidateConfig(config: WifiDeviceConfig, callback: AsyncCallback\<number>): void;<br>Old version information: |Class name: wifiManager;<br>Method or attribute name: function addCandidateConfig(config: WifiDeviceConfig, callback: AsyncCallback\<number>): void;<br>New version information: ohos.permission.SET_WIFI_INFO|@ohos.wifiManager.d.ts|
|Permission changed|Class name: wifiManager;<br>Method or attribute name: function removeCandidateConfig(networkId: number, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: wifiManager;<br>Method or attribute name: function removeCandidateConfig(networkId: number, callback: AsyncCallback\<void>): void;<br>New version information: ohos.permission.SET_WIFI_INFO|@ohos.wifiManager.d.ts|
|Permission changed|Class name: wifiManager;<br>Method or attribute name: function getLinkedInfo(callback: AsyncCallback\<WifiLinkedInfo>): void;<br>Old version information: |Class name: wifiManager;<br>Method or attribute name: function getLinkedInfo(callback: AsyncCallback\<WifiLinkedInfo>): void;<br>New version information: ohos.permission.GET_WIFI_INFO|@ohos.wifiManager.d.ts|
|Permission changed|Class name: wifiManager;<br>Method or attribute name: function getP2pLinkedInfo(callback: AsyncCallback\<WifiP2pLinkedInfo>): void;<br>Old version information: |Class name: wifiManager;<br>Method or attribute name: function getP2pLinkedInfo(callback: AsyncCallback\<WifiP2pLinkedInfo>): void;<br>New version information: ohos.permission.GET_WIFI_INFO|@ohos.wifiManager.d.ts|
|Permission changed|Class name: wifiManager;<br>Method or attribute name: function getCurrentP2pGroup(callback: AsyncCallback\<WifiP2pGroupInfo>): void;<br>Old version information: |Class name: wifiManager;<br>Method or attribute name: function getCurrentP2pGroup(callback: AsyncCallback\<WifiP2pGroupInfo>): void;<br>New version information: ohos.permission.GET_WIFI_INFO,ohos.permission.LOCATION,ohos.permission.APPROXIMATELY_LOCATION|@ohos.wifiManager.d.ts|
|Permission changed|Class name: wifiManager;<br>Method or attribute name: function getP2pPeerDevices(callback: AsyncCallback\<WifiP2pDevice[]>): void;<br>Old version information: |Class name: wifiManager;<br>Method or attribute name: function getP2pPeerDevices(callback: AsyncCallback\<WifiP2pDevice[]>): void;<br>New version information: ohos.permission.GET_WIFI_INFO,ohos.permission.LOCATION,ohos.permission.APPROXIMATELY_LOCATION|@ohos.wifiManager.d.ts|
|Permission changed|Class name: wifiManager;<br>Method or attribute name: function getP2pLocalDevice(callback: AsyncCallback\<WifiP2pDevice>): void;<br>Old version information: |Class name: wifiManager;<br>Method or attribute name: function getP2pLocalDevice(callback: AsyncCallback\<WifiP2pDevice>): void;<br>New version information: ohos.permission.GET_WIFI_INFO,ohos.permission.GET_WIFI_CONFIG|@ohos.wifiManager.d.ts|
|Permission changed|Class name: wifiManager;<br>Method or attribute name: function getP2pGroups(callback: AsyncCallback\<Array\<WifiP2pGroupInfo>>): void;<br>Old version information: |Class name: wifiManager;<br>Method or attribute name: function getP2pGroups(callback: AsyncCallback\<Array\<WifiP2pGroupInfo>>): void;<br>New version information: ohos.permission.GET_WIFI_INFO,ohos.permission.LOCATION,ohos.permission.APPROXIMATELY_LOCATION|@ohos.wifiManager.d.ts|
|Type changed|Class name: NetSpecifier;<br>Method or attribute name: netCapabilities: NetCapabilities;<br>Old version information: |Class name: NetSpecifier;<br>Method or attribute name: netCapabilities: NetCapabilities;<br>New version information: NetCapabilities|@ohos.net.connection.d.ts|
|Type changed|Class name: NetSpecifier;<br>Method or attribute name: bearerPrivateIdentifier?: string;<br>Old version information: |Class name: NetSpecifier;<br>Method or attribute name: bearerPrivateIdentifier?: string;<br>New version information: ?string|@ohos.net.connection.d.ts|
|Type changed|Class name: NetHandle;<br>Method or attribute name: netId: number;<br>Old version information: |Class name: NetHandle;<br>Method or attribute name: netId: number;<br>New version information: number|@ohos.net.connection.d.ts|
|Type changed|Class name: NetCapabilities;<br>Method or attribute name: linkUpBandwidthKbps?: number;<br>Old version information: |Class name: NetCapabilities;<br>Method or attribute name: linkUpBandwidthKbps?: number;<br>New version information: ?number|@ohos.net.connection.d.ts|
|Type changed|Class name: NetCapabilities;<br>Method or attribute name: linkDownBandwidthKbps?: number;<br>Old version information: |Class name: NetCapabilities;<br>Method or attribute name: linkDownBandwidthKbps?: number;<br>New version information: ?number|@ohos.net.connection.d.ts|
|Type changed|Class name: NetCapabilities;<br>Method or attribute name: networkCap?: Array\<NetCap>;<br>Old version information: |Class name: NetCapabilities;<br>Method or attribute name: networkCap?: Array\<NetCap>;<br>New version information: ?Array\<NetCap>|@ohos.net.connection.d.ts|
|Type changed|Class name: NetCapabilities;<br>Method or attribute name: bearerTypes: Array\<NetBearType>;<br>Old version information: |Class name: NetCapabilities;<br>Method or attribute name: bearerTypes: Array\<NetBearType>;<br>New version information: Array\<NetBearType>|@ohos.net.connection.d.ts|
|Type changed|Class name: ConnectionProperties;<br>Method or attribute name: interfaceName: string;<br>Old version information: |Class name: ConnectionProperties;<br>Method or attribute name: interfaceName: string;<br>New version information: string|@ohos.net.connection.d.ts|
|Type changed|Class name: ConnectionProperties;<br>Method or attribute name: domains: string;<br>Old version information: |Class name: ConnectionProperties;<br>Method or attribute name: domains: string;<br>New version information: string|@ohos.net.connection.d.ts|
|Type changed|Class name: ConnectionProperties;<br>Method or attribute name: linkAddresses: Array\<LinkAddress>;<br>Old version information: |Class name: ConnectionProperties;<br>Method or attribute name: linkAddresses: Array\<LinkAddress>;<br>New version information: Array\<LinkAddress>|@ohos.net.connection.d.ts|
|Type changed|Class name: ConnectionProperties;<br>Method or attribute name: dnses: Array\<NetAddress>;<br>Old version information: |Class name: ConnectionProperties;<br>Method or attribute name: dnses: Array\<NetAddress>;<br>New version information: Array\<NetAddress>|@ohos.net.connection.d.ts|
|Type changed|Class name: ConnectionProperties;<br>Method or attribute name: routes: Array\<RouteInfo>;<br>Old version information: |Class name: ConnectionProperties;<br>Method or attribute name: routes: Array\<RouteInfo>;<br>New version information: Array\<RouteInfo>|@ohos.net.connection.d.ts|
|Type changed|Class name: ConnectionProperties;<br>Method or attribute name: mtu: number;<br>Old version information: |Class name: ConnectionProperties;<br>Method or attribute name: mtu: number;<br>New version information: number|@ohos.net.connection.d.ts|
|Type changed|Class name: RouteInfo;<br>Method or attribute name: interface: string;<br>Old version information: |Class name: RouteInfo;<br>Method or attribute name: interface: string;<br>New version information: string|@ohos.net.connection.d.ts|
|Type changed|Class name: RouteInfo;<br>Method or attribute name: destination: LinkAddress;<br>Old version information: |Class name: RouteInfo;<br>Method or attribute name: destination: LinkAddress;<br>New version information: LinkAddress|@ohos.net.connection.d.ts|
|Type changed|Class name: RouteInfo;<br>Method or attribute name: gateway: NetAddress;<br>Old version information: |Class name: RouteInfo;<br>Method or attribute name: gateway: NetAddress;<br>New version information: NetAddress|@ohos.net.connection.d.ts|
|Type changed|Class name: RouteInfo;<br>Method or attribute name: hasGateway: boolean;<br>Old version information: |Class name: RouteInfo;<br>Method or attribute name: hasGateway: boolean;<br>New version information: boolean|@ohos.net.connection.d.ts|
|Type changed|Class name: RouteInfo;<br>Method or attribute name: isDefaultRoute: boolean;<br>Old version information: |Class name: RouteInfo;<br>Method or attribute name: isDefaultRoute: boolean;<br>New version information: boolean|@ohos.net.connection.d.ts|
|Type changed|Class name: LinkAddress;<br>Method or attribute name: address: NetAddress;<br>Old version information: |Class name: LinkAddress;<br>Method or attribute name: address: NetAddress;<br>New version information: NetAddress|@ohos.net.connection.d.ts|
|Type changed|Class name: LinkAddress;<br>Method or attribute name: prefixLength: number;<br>Old version information: |Class name: LinkAddress;<br>Method or attribute name: prefixLength: number;<br>New version information: number|@ohos.net.connection.d.ts|
|Type changed|Class name: NetAddress;<br>Method or attribute name: address: string;<br>Old version information: |Class name: NetAddress;<br>Method or attribute name: address: string;<br>New version information: string|@ohos.net.connection.d.ts|
|Type changed|Class name: NetAddress;<br>Method or attribute name: family?: number;<br>Old version information: |Class name: NetAddress;<br>Method or attribute name: family?: number;<br>New version information: ?number|@ohos.net.connection.d.ts|
|Type changed|Class name: NetAddress;<br>Method or attribute name: port?: number;<br>Old version information: |Class name: NetAddress;<br>Method or attribute name: port?: number;<br>New version information: ?number|@ohos.net.connection.d.ts|
|Type changed|Class name: HttpProxy;<br>Method or attribute name: host: string;<br>Old version information: |Class name: HttpProxy;<br>Method or attribute name: host: string;<br>New version information: string|@ohos.net.connection.d.ts|
|Type changed|Class name: HttpProxy;<br>Method or attribute name: port: number;<br>Old version information: |Class name: HttpProxy;<br>Method or attribute name: port: number;<br>New version information: number|@ohos.net.connection.d.ts|
|Type changed|Class name: HttpProxy;<br>Method or attribute name: exclusionList: Array\<string>;<br>Old version information: |Class name: HttpProxy;<br>Method or attribute name: exclusionList: Array\<string>;<br>New version information: Array\<string>|@ohos.net.connection.d.ts|
|Type changed|Class name: InterfaceConfiguration;<br>Method or attribute name: mode: IPSetMode;<br>Old version information: |Class name: InterfaceConfiguration;<br>Method or attribute name: mode: IPSetMode;<br>New version information: IPSetMode|@ohos.net.ethernet.d.ts|
|Type changed|Class name: InterfaceConfiguration;<br>Method or attribute name: ipAddr: string;<br>Old version information: |Class name: InterfaceConfiguration;<br>Method or attribute name: ipAddr: string;<br>New version information: string|@ohos.net.ethernet.d.ts|
|Type changed|Class name: InterfaceConfiguration;<br>Method or attribute name: route: string;<br>Old version information: |Class name: InterfaceConfiguration;<br>Method or attribute name: route: string;<br>New version information: string|@ohos.net.ethernet.d.ts|
|Type changed|Class name: InterfaceConfiguration;<br>Method or attribute name: gateway: string;<br>Old version information: |Class name: InterfaceConfiguration;<br>Method or attribute name: gateway: string;<br>New version information: string|@ohos.net.ethernet.d.ts|
|Type changed|Class name: InterfaceConfiguration;<br>Method or attribute name: netMask: string;<br>Old version information: |Class name: InterfaceConfiguration;<br>Method or attribute name: netMask: string;<br>New version information: string|@ohos.net.ethernet.d.ts|
|Type changed|Class name: InterfaceConfiguration;<br>Method or attribute name: dnsServers: string;<br>Old version information: |Class name: InterfaceConfiguration;<br>Method or attribute name: dnsServers: string;<br>New version information: string|@ohos.net.ethernet.d.ts|
|Type changed|Class name: HttpRequestOptions;<br>Method or attribute name: method?: RequestMethod;<br>Old version information: |Class name: HttpRequestOptions;<br>Method or attribute name: method?: RequestMethod;<br>New version information: ?RequestMethod|@ohos.net.http.d.ts|
|Type changed|Class name: HttpRequestOptions;<br>Method or attribute name: extraData?: string \| Object \| ArrayBuffer;<br>Old version information: |Class name: HttpRequestOptions;<br>Method or attribute name: extraData?: string \| Object \| ArrayBuffer;<br>New version information: ?string \| Object \| ArrayBuffer|@ohos.net.http.d.ts|
|Type changed|Class name: HttpRequestOptions;<br>Method or attribute name: expectDataType?: HttpDataType;<br>Old version information: |Class name: HttpRequestOptions;<br>Method or attribute name: expectDataType?: HttpDataType;<br>New version information: ?HttpDataType|@ohos.net.http.d.ts|
|Type changed|Class name: HttpRequestOptions;<br>Method or attribute name: usingCache?: boolean;<br>Old version information: |Class name: HttpRequestOptions;<br>Method or attribute name: usingCache?: boolean;<br>New version information: ?boolean|@ohos.net.http.d.ts|
|Type changed|Class name: HttpRequestOptions;<br>Method or attribute name: priority?: number;<br>Old version information: |Class name: HttpRequestOptions;<br>Method or attribute name: priority?: number;<br>New version information: ?number|@ohos.net.http.d.ts|
|Type changed|Class name: HttpRequestOptions;<br>Method or attribute name: header?: Object;<br>Old version information: |Class name: HttpRequestOptions;<br>Method or attribute name: header?: Object;<br>New version information: ?Object|@ohos.net.http.d.ts|
|Type changed|Class name: HttpRequestOptions;<br>Method or attribute name: readTimeout?: number;<br>Old version information: |Class name: HttpRequestOptions;<br>Method or attribute name: readTimeout?: number;<br>New version information: ?number|@ohos.net.http.d.ts|
|Type changed|Class name: HttpRequestOptions;<br>Method or attribute name: connectTimeout?: number;<br>Old version information: |Class name: HttpRequestOptions;<br>Method or attribute name: connectTimeout?: number;<br>New version information: ?number|@ohos.net.http.d.ts|
|Type changed|Class name: HttpRequestOptions;<br>Method or attribute name: usingProtocol?: HttpProtocol;<br>Old version information: |Class name: HttpRequestOptions;<br>Method or attribute name: usingProtocol?: HttpProtocol;<br>New version information: ?HttpProtocol|@ohos.net.http.d.ts|
|Type changed|Class name: HttpRequestOptions;<br>Method or attribute name: usingProxy?: boolean \| HttpProxy;<br>Old version information: |Class name: HttpRequestOptions;<br>Method or attribute name: usingProxy?: boolean \| HttpProxy;<br>New version information: ?boolean \| HttpProxy|@ohos.net.http.d.ts|
|Type changed|Class name: HttpRequestOptions;<br>Method or attribute name: caPath?: string;<br>Old version information: |Class name: HttpRequestOptions;<br>Method or attribute name: caPath?: string;<br>New version information: ?string|@ohos.net.http.d.ts|
|Type changed|Class name: HttpResponse;<br>Method or attribute name: result: string \| Object \| ArrayBuffer;<br>Old version information: |Class name: HttpResponse;<br>Method or attribute name: result: string \| Object \| ArrayBuffer;<br>New version information: string \| Object \| ArrayBuffer|@ohos.net.http.d.ts|
|Type changed|Class name: HttpResponse;<br>Method or attribute name: resultType: HttpDataType;<br>Old version information: |Class name: HttpResponse;<br>Method or attribute name: resultType: HttpDataType;<br>New version information: HttpDataType|@ohos.net.http.d.ts|
|Type changed|Class name: HttpResponse;<br>Method or attribute name: responseCode: ResponseCode \| number;<br>Old version information: |Class name: HttpResponse;<br>Method or attribute name: responseCode: ResponseCode \| number;<br>New version information: ResponseCode \| number|@ohos.net.http.d.ts|
|Type changed|Class name: HttpResponse;<br>Method or attribute name: header: Object;<br>Old version information: |Class name: HttpResponse;<br>Method or attribute name: header: Object;<br>New version information: Object|@ohos.net.http.d.ts|
|Type changed|Class name: HttpResponse;<br>Method or attribute name: cookies: string;<br>Old version information: |Class name: HttpResponse;<br>Method or attribute name: cookies: string;<br>New version information: string|@ohos.net.http.d.ts|
|Type changed|Class name: LocalServiceInfo;<br>Method or attribute name: serviceType: string;<br>Old version information: |Class name: LocalServiceInfo;<br>Method or attribute name: serviceType: string;<br>New version information: string|@ohos.net.mdns.d.ts|
|Type changed|Class name: LocalServiceInfo;<br>Method or attribute name: serviceName: string;<br>Old version information: |Class name: LocalServiceInfo;<br>Method or attribute name: serviceName: string;<br>New version information: string|@ohos.net.mdns.d.ts|
|Type changed|Class name: LocalServiceInfo;<br>Method or attribute name: port?: number;<br>Old version information: |Class name: LocalServiceInfo;<br>Method or attribute name: port?: number;<br>New version information: ?number|@ohos.net.mdns.d.ts|
|Type changed|Class name: LocalServiceInfo;<br>Method or attribute name: host?: NetAddress;<br>Old version information: |Class name: LocalServiceInfo;<br>Method or attribute name: host?: NetAddress;<br>New version information: ?NetAddress|@ohos.net.mdns.d.ts|
|Type changed|Class name: LocalServiceInfo;<br>Method or attribute name: serviceAttribute?: Array\<ServiceAttribute>;<br>Old version information: |Class name: LocalServiceInfo;<br>Method or attribute name: serviceAttribute?: Array\<ServiceAttribute>;<br>New version information: ?Array\<ServiceAttribute>|@ohos.net.mdns.d.ts|
|Type changed|Class name: ServiceAttribute;<br>Method or attribute name: key: string;<br>Old version information: |Class name: ServiceAttribute;<br>Method or attribute name: key: string;<br>New version information: string|@ohos.net.mdns.d.ts|
|Type changed|Class name: ServiceAttribute;<br>Method or attribute name: value: Array\<number>;<br>Old version information: |Class name: ServiceAttribute;<br>Method or attribute name: value: Array\<number>;<br>New version information: Array\<number>|@ohos.net.mdns.d.ts|
|Type changed|Class name: UDPSendOptions;<br>Method or attribute name: data: string \| ArrayBuffer;<br>Old version information: |Class name: UDPSendOptions;<br>Method or attribute name: data: string \| ArrayBuffer;<br>New version information: string \| ArrayBuffer|@ohos.net.socket.d.ts|
|Type changed|Class name: TCPSendOptions;<br>Method or attribute name: data: string \| ArrayBuffer;<br>Old version information: |Class name: TCPSendOptions;<br>Method or attribute name: data: string \| ArrayBuffer;<br>New version information: string \| ArrayBuffer|@ohos.net.socket.d.ts|
|Type changed|Class name: UDPSendOptions;<br>Method or attribute name: address: NetAddress;<br>Old version information: |Class name: UDPSendOptions;<br>Method or attribute name: address: NetAddress;<br>New version information: NetAddress|@ohos.net.socket.d.ts|
|Type changed|Class name: TCPConnectOptions;<br>Method or attribute name: address: NetAddress;<br>Old version information: |Class name: TCPConnectOptions;<br>Method or attribute name: address: NetAddress;<br>New version information: NetAddress|@ohos.net.socket.d.ts|
|Type changed|Class name: TLSConnectOptions;<br>Method or attribute name: address: NetAddress;<br>Old version information: |Class name: TLSConnectOptions;<br>Method or attribute name: address: NetAddress;<br>New version information: NetAddress|@ohos.net.socket.d.ts|
|Type changed|Class name: ExtraOptionsBase;<br>Method or attribute name: receiveBufferSize?: number;<br>Old version information: |Class name: ExtraOptionsBase;<br>Method or attribute name: receiveBufferSize?: number;<br>New version information: ?number|@ohos.net.socket.d.ts|
|Type changed|Class name: ExtraOptionsBase;<br>Method or attribute name: sendBufferSize?: number;<br>Old version information: |Class name: ExtraOptionsBase;<br>Method or attribute name: sendBufferSize?: number;<br>New version information: ?number|@ohos.net.socket.d.ts|
|Type changed|Class name: ExtraOptionsBase;<br>Method or attribute name: reuseAddress?: boolean;<br>Old version information: |Class name: ExtraOptionsBase;<br>Method or attribute name: reuseAddress?: boolean;<br>New version information: ?boolean|@ohos.net.socket.d.ts|
|Type changed|Class name: ExtraOptionsBase;<br>Method or attribute name: socketTimeout?: number;<br>Old version information: |Class name: ExtraOptionsBase;<br>Method or attribute name: socketTimeout?: number;<br>New version information: ?number|@ohos.net.socket.d.ts|
|Type changed|Class name: UDPExtraOptions;<br>Method or attribute name: broadcast?: boolean;<br>Old version information: |Class name: UDPExtraOptions;<br>Method or attribute name: broadcast?: boolean;<br>New version information: ?boolean|@ohos.net.socket.d.ts|
|Type changed|Class name: SocketStateBase;<br>Method or attribute name: isBound: boolean;<br>Old version information: |Class name: SocketStateBase;<br>Method or attribute name: isBound: boolean;<br>New version information: boolean|@ohos.net.socket.d.ts|
|Type changed|Class name: SocketStateBase;<br>Method or attribute name: isClose: boolean;<br>Old version information: |Class name: SocketStateBase;<br>Method or attribute name: isClose: boolean;<br>New version information: boolean|@ohos.net.socket.d.ts|
|Type changed|Class name: SocketStateBase;<br>Method or attribute name: isConnected: boolean;<br>Old version information: |Class name: SocketStateBase;<br>Method or attribute name: isConnected: boolean;<br>New version information: boolean|@ohos.net.socket.d.ts|
|Type changed|Class name: SocketRemoteInfo;<br>Method or attribute name: address: string;<br>Old version information: |Class name: SocketRemoteInfo;<br>Method or attribute name: address: string;<br>New version information: string|@ohos.net.socket.d.ts|
|Type changed|Class name: SocketRemoteInfo;<br>Method or attribute name: family: 'IPv4' \| 'IPv6';<br>Old version information: |Class name: SocketRemoteInfo;<br>Method or attribute name: family: 'IPv4' \| 'IPv6';<br>New version information: 'IPv4' \| 'IPv6'|@ohos.net.socket.d.ts|
|Type changed|Class name: SocketRemoteInfo;<br>Method or attribute name: port: number;<br>Old version information: |Class name: SocketRemoteInfo;<br>Method or attribute name: port: number;<br>New version information: number|@ohos.net.socket.d.ts|
|Type changed|Class name: SocketRemoteInfo;<br>Method or attribute name: size: number;<br>Old version information: |Class name: SocketRemoteInfo;<br>Method or attribute name: size: number;<br>New version information: number|@ohos.net.socket.d.ts|
|Type changed|Class name: TCPConnectOptions;<br>Method or attribute name: timeout?: number;<br>Old version information: |Class name: TCPConnectOptions;<br>Method or attribute name: timeout?: number;<br>New version information: ?number|@ohos.net.socket.d.ts|
|Type changed|Class name: TCPSendOptions;<br>Method or attribute name: encoding?: string;<br>Old version information: |Class name: TCPSendOptions;<br>Method or attribute name: encoding?: string;<br>New version information: ?string|@ohos.net.socket.d.ts|
|Type changed|Class name: TCPExtraOptions;<br>Method or attribute name: keepAlive?: boolean;<br>Old version information: |Class name: TCPExtraOptions;<br>Method or attribute name: keepAlive?: boolean;<br>New version information: ?boolean|@ohos.net.socket.d.ts|
|Type changed|Class name: TCPExtraOptions;<br>Method or attribute name: OOBInline?: boolean;<br>Old version information: |Class name: TCPExtraOptions;<br>Method or attribute name: OOBInline?: boolean;<br>New version information: ?boolean|@ohos.net.socket.d.ts|
|Type changed|Class name: TCPExtraOptions;<br>Method or attribute name: TCPNoDelay?: boolean;<br>Old version information: |Class name: TCPExtraOptions;<br>Method or attribute name: TCPNoDelay?: boolean;<br>New version information: ?boolean|@ohos.net.socket.d.ts|
|Type changed|Class name: TCPExtraOptions;<br>Method or attribute name: socketLinger?: { on: boolean, linger: number };<br>Old version information: |Class name: TCPExtraOptions;<br>Method or attribute name: socketLinger?: { on: boolean, linger: number };<br>New version information: ?object|@ohos.net.socket.d.ts|
|Type changed|Class name: TLSSecureOptions;<br>Method or attribute name: ca: string \| Array\<string>;<br>Old version information: |Class name: TLSSecureOptions;<br>Method or attribute name: ca: string \| Array\<string>;<br>New version information: string \| Array\<string>|@ohos.net.socket.d.ts|
|Type changed|Class name: TLSSecureOptions;<br>Method or attribute name: cert?: string;<br>Old version information: |Class name: TLSSecureOptions;<br>Method or attribute name: cert?: string;<br>New version information: ?string|@ohos.net.socket.d.ts|
|Type changed|Class name: TLSSecureOptions;<br>Method or attribute name: key?: string;<br>Old version information: |Class name: TLSSecureOptions;<br>Method or attribute name: key?: string;<br>New version information: ?string|@ohos.net.socket.d.ts|
|Type changed|Class name: TLSSecureOptions;<br>Method or attribute name: password?: string;<br>Old version information: |Class name: TLSSecureOptions;<br>Method or attribute name: password?: string;<br>New version information: ?string|@ohos.net.socket.d.ts|
|Type changed|Class name: TLSSecureOptions;<br>Method or attribute name: protocols?: Protocol \| Array\<Protocol>;<br>Old version information: |Class name: TLSSecureOptions;<br>Method or attribute name: protocols?: Protocol \| Array\<Protocol>;<br>New version information: ?Protocol \| Array\<Protocol>|@ohos.net.socket.d.ts|
|Type changed|Class name: TLSSecureOptions;<br>Method or attribute name: useRemoteCipherPrefer?: boolean;<br>Old version information: |Class name: TLSSecureOptions;<br>Method or attribute name: useRemoteCipherPrefer?: boolean;<br>New version information: ?boolean|@ohos.net.socket.d.ts|
|Type changed|Class name: TLSSecureOptions;<br>Method or attribute name: signatureAlgorithms?: string;<br>Old version information: |Class name: TLSSecureOptions;<br>Method or attribute name: signatureAlgorithms?: string;<br>New version information: ?string|@ohos.net.socket.d.ts|
|Type changed|Class name: TLSSecureOptions;<br>Method or attribute name: cipherSuite?: string;<br>Old version information: |Class name: TLSSecureOptions;<br>Method or attribute name: cipherSuite?: string;<br>New version information: ?string|@ohos.net.socket.d.ts|
|Type changed|Class name: TLSConnectOptions;<br>Method or attribute name: secureOptions: TLSSecureOptions;<br>Old version information: |Class name: TLSConnectOptions;<br>Method or attribute name: secureOptions: TLSSecureOptions;<br>New version information: TLSSecureOptions|@ohos.net.socket.d.ts|
|Type changed|Class name: TLSConnectOptions;<br>Method or attribute name: ALPNProtocols?: Array\<string>;<br>Old version information: |Class name: TLSConnectOptions;<br>Method or attribute name: ALPNProtocols?: Array\<string>;<br>New version information: ?Array\<string>|@ohos.net.socket.d.ts|
|Type changed|Class name: WebSocketRequestOptions;<br>Method or attribute name: header?: Object;<br>Old version information: |Class name: WebSocketRequestOptions;<br>Method or attribute name: header?: Object;<br>New version information: ?Object|@ohos.net.webSocket.d.ts|
|Type changed|Class name: WebSocketCloseOptions;<br>Method or attribute name: code?: number;<br>Old version information: |Class name: WebSocketCloseOptions;<br>Method or attribute name: code?: number;<br>New version information: ?number|@ohos.net.webSocket.d.ts|
|Type changed|Class name: WebSocketCloseOptions;<br>Method or attribute name: reason?: string;<br>Old version information: |Class name: WebSocketCloseOptions;<br>Method or attribute name: reason?: string;<br>New version information: ?string|@ohos.net.webSocket.d.ts|
|Type changed|Class name: WifiEapConfig;<br>Method or attribute name: caCertAliases: string;<br>Old version information: |Class name: WifiEapConfig;<br>Method or attribute name: caCertAliases: string;<br>New version information: string|@ohos.wifiManager.d.ts|
|Type changed|Class name: WifiEapConfig;<br>Method or attribute name: clientCertAliases: string;<br>Old version information: |Class name: WifiEapConfig;<br>Method or attribute name: clientCertAliases: string;<br>New version information: string|@ohos.wifiManager.d.ts|
|Type changed|Class name: WifiEapConfig;<br>Method or attribute name: eapSubId: number;<br>Old version information: |Class name: WifiEapConfig;<br>Method or attribute name: eapSubId: number;<br>New version information: number|@ohos.wifiManager.d.ts|
|Type changed|Class name: WifiDeviceConfig;<br>Method or attribute name: eapConfig?: WifiEapConfig;<br>Old version information: |Class name: WifiDeviceConfig;<br>Method or attribute name: eapConfig?: WifiEapConfig;<br>New version information: ?WifiEapConfig|@ohos.wifiManager.d.ts|
|Type changed|Class name: NetworkResponse;<br>Method or attribute name: type: string;<br>Old version information: |Class name: NetworkResponse;<br>Method or attribute name: type: string;<br>New version information: string|@system.network.d.ts|
|Type changed|Class name: NetworkResponse;<br>Method or attribute name: metered: boolean;<br>Old version information: |Class name: NetworkResponse;<br>Method or attribute name: metered: boolean;<br>New version information: boolean|@system.network.d.ts|
|Function changed|Class name: HotspotConfig;<br>Method or attribute name: channel: number;|Class name: HotspotConfig;<br>Method or attribute name: channel?: number;|@ohos.wifiManager.d.ts|
| Change Type | Old Version | New Version | d.ts File |
| ---- | ------ | ------ | -------- |
|Added|NA|Class name: ConditionType;<br>Method or attribute name: timeout?: number;|@ohos.process.d.ts|
|Added|NA|Class name: ConditionType;<br>Method or attribute name: killSignal?: number \| string;|@ohos.process.d.ts|
|Added|NA|Class name: ConditionType;<br>Method or attribute name: maxBuffer?: number;|@ohos.process.d.ts|
|Added|NA|Class name: taskpool;<br>Method or attribute name: function execute(group: TaskGroup, priority?: Priority): Promise\<unknown[]>;|@ohos.taskpool.d.ts|
|Added|NA|Class name: taskpool;<br>Method or attribute name: function cancel(group: TaskGroup): void;|@ohos.taskpool.d.ts|
|Added|NA|Class name: taskpool;<br>Method or attribute name: function getTaskPoolInfo(): TaskPoolInfo;|@ohos.taskpool.d.ts|
|Added|NA|Class name: Task;<br>Method or attribute name: static isCanceled(): boolean;|@ohos.taskpool.d.ts|
|Added|NA|Class name: Task;<br>Method or attribute name: setTransferList(transfer?: ArrayBuffer[]): void;|@ohos.taskpool.d.ts|
|Added|NA|Class name: TaskGroup;<br>Method or attribute name: constructor();|@ohos.taskpool.d.ts|
|Added|NA|Class name: TaskGroup;<br>Method or attribute name: addTask(func: Function, ...args: unknown[]): void;|@ohos.taskpool.d.ts|
|Added|NA|Class name: TaskGroup;<br>Method or attribute name: addTask(task: Task): void;|@ohos.taskpool.d.ts|
|Added|NA|Class name: State;<br>Method or attribute name: WAITING = 1|@ohos.taskpool.d.ts|
|Added|NA|Class name: State;<br>Method or attribute name: RUNNING = 2|@ohos.taskpool.d.ts|
|Added|NA|Class name: State;<br>Method or attribute name: CANCELED = 3|@ohos.taskpool.d.ts|
|Added|NA|Class name: TaskInfo;<br>Method or attribute name: taskId: number;|@ohos.taskpool.d.ts|
|Added|NA|Class name: TaskInfo;<br>Method or attribute name: state: State;|@ohos.taskpool.d.ts|
|Added|NA|Class name: TaskInfo;<br>Method or attribute name: duration?: number;|@ohos.taskpool.d.ts|
|Added|NA|Class name: ThreadInfo;<br>Method or attribute name: tid: number;|@ohos.taskpool.d.ts|
|Added|NA|Class name: ThreadInfo;<br>Method or attribute name: taskIds?: number[];|@ohos.taskpool.d.ts|
|Added|NA|Class name: ThreadInfo;<br>Method or attribute name: priority?: Priority;|@ohos.taskpool.d.ts|
|Added|NA|Class name: TaskPoolInfo;<br>Method or attribute name: threadInfos: ThreadInfo[];|@ohos.taskpool.d.ts|
|Added|NA|Class name: TaskPoolInfo;<br>Method or attribute name: taskInfos: TaskInfo[];|@ohos.taskpool.d.ts|
|Added|NA|Class name: Type;<br>Method or attribute name: BASIC|@ohos.util.d.ts|
|Added|NA|Class name: Type;<br>Method or attribute name: MIME|@ohos.util.d.ts|
|Error code added|Class name: WorkerEventListener;<br>Method or attribute name: (event: Event): void \| Promise\<void>;<br>Old version information: |Class name: WorkerEventListener;<br>Method or attribute name: (event: Event): void \| Promise\<void>;<br>New version information: 401,10200004,10200005|@ohos.worker.d.ts|
|Error code added|Class name: ThreadWorkerGlobalScope;<br>Method or attribute name: onmessage?: (this: ThreadWorkerGlobalScope, ev: MessageEvents) => void;<br>Old version information: |Class name: ThreadWorkerGlobalScope;<br>Method or attribute name: onmessage?: (this: ThreadWorkerGlobalScope, ev: MessageEvents) => void;<br>New version information: 401,10200004,10200005|@ohos.worker.d.ts|
|Error code added|Class name: ThreadWorkerGlobalScope;<br>Method or attribute name: onmessageerror?: (this: ThreadWorkerGlobalScope, ev: MessageEvents) => void;<br>Old version information: |Class name: ThreadWorkerGlobalScope;<br>Method or attribute name: onmessageerror?: (this: ThreadWorkerGlobalScope, ev: MessageEvents) => void;<br>New version information: 401,10200004,10200005|@ohos.worker.d.ts|
|Error code added|Class name: ThreadWorker;<br>Method or attribute name: onexit?: (code: number) => void;<br>Old version information: |Class name: ThreadWorker;<br>Method or attribute name: onexit?: (code: number) => void;<br>New version information: 401,10200004,10200005|@ohos.worker.d.ts|
|Error code added|Class name: ThreadWorker;<br>Method or attribute name: onerror?: (err: ErrorEvent) => void;<br>Old version information: |Class name: ThreadWorker;<br>Method or attribute name: onerror?: (err: ErrorEvent) => void;<br>New version information: 401,10200004,10200005|@ohos.worker.d.ts|
|Error code added|Class name: ThreadWorker;<br>Method or attribute name: onmessage?: (event: MessageEvents) => void;<br>Old version information: |Class name: ThreadWorker;<br>Method or attribute name: onmessage?: (event: MessageEvents) => void;<br>New version information: 401,10200004,10200005|@ohos.worker.d.ts|
|Error code added|Class name: ThreadWorker;<br>Method or attribute name: onmessageerror?: (event: MessageEvents) => void;<br>Old version information: |Class name: ThreadWorker;<br>Method or attribute name: onmessageerror?: (event: MessageEvents) => void;<br>New version information: 401,10200004,10200005|@ohos.worker.d.ts|
|Error code changed|Class name: taskpool;<br>Method or attribute name: function cancel(task: Task): void;<br>Old version information: 401,10200015,10200016|Class name: taskpool;<br>Method or attribute name: function cancel(task: Task): void;<br>New version information: 401,10200015|@ohos.taskpool.d.ts|
|Error code changed|Class name: Vector;<br>Method or attribute name: insert(element: T, index: number): void;<br>Old version information: If|Class name: Vector;<br>Method or attribute name: insert(element: T, index: number): void;<br>New version information: |@ohos.util.Vector.d.ts|
|Error code changed|Class name: Vector;<br>Method or attribute name: removeByRange(fromIndex: number, toIndex: number): void;<br>Old version information: If|Class name: Vector;<br>Method or attribute name: removeByRange(fromIndex: number, toIndex: number): void;<br>New version information: |@ohos.util.Vector.d.ts|
|Error code changed|Class name: Vector;<br>Method or attribute name: subVector(fromIndex: number, toIndex: number): Vector\<T>;<br>Old version information: If|Class name: Vector;<br>Method or attribute name: subVector(fromIndex: number, toIndex: number): Vector\<T>;<br>New version information: |@ohos.util.Vector.d.ts|
|Error code changed|Class name: WorkerEventTarget;<br>Method or attribute name: addEventListener(type: string, listener: WorkerEventListener): void;<br>Old version information: 401,10200004|Class name: WorkerEventTarget;<br>Method or attribute name: addEventListener(type: string, listener: WorkerEventListener): void;<br>New version information: 401,10200004,10200005|@ohos.worker.d.ts|
|Error code changed|Class name: ThreadWorker;<br>Method or attribute name: addEventListener(type: string, listener: WorkerEventListener): void;<br>Old version information: 401,10200004|Class name: ThreadWorker;<br>Method or attribute name: addEventListener(type: string, listener: WorkerEventListener): void;<br>New version information: 401,10200004,10200005|@ohos.worker.d.ts|
|Error code changed|Class name: ThreadWorker;<br>Method or attribute name: on(type: string, listener: WorkerEventListener): void;<br>Old version information: 401,10200004|Class name: ThreadWorker;<br>Method or attribute name: on(type: string, listener: WorkerEventListener): void;<br>New version information: 401,10200004,10200005|@ohos.worker.d.ts|
|Error code changed|Class name: ThreadWorker;<br>Method or attribute name: once(type: string, listener: WorkerEventListener): void;<br>Old version information: 401,10200004|Class name: ThreadWorker;<br>Method or attribute name: once(type: string, listener: WorkerEventListener): void;<br>New version information: 401,10200004,10200005|@ohos.worker.d.ts|
|Error code changed|Class name: ThreadWorker;<br>Method or attribute name: off(type: string, listener?: WorkerEventListener): void;<br>Old version information: 401,10200004|Class name: ThreadWorker;<br>Method or attribute name: off(type: string, listener?: WorkerEventListener): void;<br>New version information: 401,10200004,10200005|@ohos.worker.d.ts|
|Type changed|Class name: Task;<br>Method or attribute name: arguments?: unknown[];<br>Old version information: |Class name: Task;<br>Method or attribute name: arguments?: unknown[];<br>New version information: ?unknown[]|@ohos.taskpool.d.ts|
|Function changed|Class name: process;<br>Method or attribute name: function runCmd(command: string,<br><br> options?: { timeout?: number, killSignal?: number \| string, maxBuffer?: number }): ChildProcess;|Class name: process;<br>Method or attribute name: function runCmd(<br><br> command: string,<br><br> options?: ConditionType<br><br> ): ChildProcess;|@ohos.process.d.ts|
|Function changed|Class name: Priority;<br>Method or attribute name: HIGH|Class name: Priority;<br>Method or attribute name: HIGH = 0|@ohos.taskpool.d.ts|
|Function changed|Class name: Priority;<br>Method or attribute name: MEDIUM|Class name: Priority;<br>Method or attribute name: MEDIUM = 1|@ohos.taskpool.d.ts|
|Function changed|Class name: Priority;<br>Method or attribute name: LOW|Class name: Priority;<br>Method or attribute name: LOW = 2|@ohos.taskpool.d.ts|
|Function changed|Class name: Base64Helper;<br>Method or attribute name: encodeToStringSync(src: Uint8Array): string;|Class name: Base64Helper;<br>Method or attribute name: encodeToStringSync(src: Uint8Array, options?: Type): string;|@ohos.util.d.ts|
|Function changed|Class name: Base64Helper;<br>Method or attribute name: decodeSync(src: Uint8Array \| string): Uint8Array;|Class name: Base64Helper;<br>Method or attribute name: decodeSync(src: Uint8Array \| string, options?: Type): Uint8Array;|@ohos.util.d.ts|
|Function changed|Class name: Base64Helper;<br>Method or attribute name: encodeToString(src: Uint8Array): Promise\<string>;|Class name: Base64Helper;<br>Method or attribute name: encodeToString(src: Uint8Array, options?: Type): Promise\<string>;|@ohos.util.d.ts|
|Function changed|Class name: Base64Helper;<br>Method or attribute name: decode(src: Uint8Array \| string): Promise\<Uint8Array>;|Class name: Base64Helper;<br>Method or attribute name: decode(src: Uint8Array \| string, options?: Type): Promise\<Uint8Array>;|@ohos.util.d.ts|
| Change Type | Old Version | New Version | d.ts File |
| ---- | ------ | ------ | -------- |
|Added|NA|Class name: browser;<br>Method or attribute name: function setPolicies(admin: Want, appId: string, policies: string, callback: AsyncCallback\<void>): void;|@ohos.enterprise.browser.d.ts|
|Added|NA|Class name: browser;<br>Method or attribute name: function setPolicies(admin: Want, appId: string, policies: string): Promise\<void>;|@ohos.enterprise.browser.d.ts|
|Added|NA|Class name: browser;<br>Method or attribute name: function getPolicies(admin: Want, appId: string, callback: AsyncCallback\<string>): void;|@ohos.enterprise.browser.d.ts|
|Added|NA|Class name: browser;<br>Method or attribute name: function getPolicies(admin: Want, appId: string): Promise\<string>;|@ohos.enterprise.browser.d.ts|
|Added|NA|Class name: bundleManager;<br>Method or attribute name: function addDisallowedUninstallBundles(admin: Want, appIds: Array\<string>, callback: AsyncCallback\<void>): void;|@ohos.enterprise.bundleManager.d.ts|
|Added|NA|Class name: bundleManager;<br>Method or attribute name: function addDisallowedUninstallBundles(admin: Want, appIds: Array\<string>, userId: number, callback: AsyncCallback\<void>): void;|@ohos.enterprise.bundleManager.d.ts|
|Added|NA|Class name: bundleManager;<br>Method or attribute name: function addDisallowedUninstallBundles(admin: Want, appIds: Array\<string>, userId?: number): Promise\<void>;|@ohos.enterprise.bundleManager.d.ts|
|Added|NA|Class name: bundleManager;<br>Method or attribute name: function removeDisallowedUninstallBundles(admin: Want, appIds: Array\<string>, callback: AsyncCallback\<void>): void;|@ohos.enterprise.bundleManager.d.ts|
|Added|NA|Class name: bundleManager;<br>Method or attribute name: function removeDisallowedUninstallBundles(admin: Want, appIds: Array\<string>, userId: number, callback: AsyncCallback\<void>): void;|@ohos.enterprise.bundleManager.d.ts|
|Added|NA|Class name: bundleManager;<br>Method or attribute name: function removeDisallowedUninstallBundles(admin: Want, appIds: Array\<string>, userId?: number): Promise\<void>;|@ohos.enterprise.bundleManager.d.ts|
|Added|NA|Class name: bundleManager;<br>Method or attribute name: function getDisallowedUninstallBundles(admin: Want, callback: AsyncCallback\<Array\<string>>): void;|@ohos.enterprise.bundleManager.d.ts|
|Added|NA|Class name: bundleManager;<br>Method or attribute name: function getDisallowedUninstallBundles(admin: Want, userId: number, callback: AsyncCallback\<Array\<string>>): void;|@ohos.enterprise.bundleManager.d.ts|
|Added|NA|Class name: bundleManager;<br>Method or attribute name: function getDisallowedUninstallBundles(admin: Want, userId?: number): Promise\<Array\<string>>;|@ohos.enterprise.bundleManager.d.ts|
|Added|NA|Class name: bundleManager;<br>Method or attribute name: function uninstall(admin: Want, bundleName: string, callback: AsyncCallback\<void>): void;|@ohos.enterprise.bundleManager.d.ts|
|Added|NA|Class name: bundleManager;<br>Method or attribute name: function uninstall(admin: Want, bundleName: string, userId: number, callback: AsyncCallback\<void>): void;|@ohos.enterprise.bundleManager.d.ts|
|Added|NA|Class name: bundleManager;<br>Method or attribute name: function uninstall(admin: Want, bundleName: string, isKeepData: boolean, callback: AsyncCallback\<void>): void;|@ohos.enterprise.bundleManager.d.ts|
|Added|NA|Class name: bundleManager;<br>Method or attribute name: function uninstall(admin: Want, bundleName: string, userId: number, isKeepData: boolean, callback: AsyncCallback\<void>): void;|@ohos.enterprise.bundleManager.d.ts|
|Added|NA|Class name: bundleManager;<br>Method or attribute name: function uninstall(admin: Want, bundleName: string, userId?: number, isKeepData?: boolean): Promise\<void>;|@ohos.enterprise.bundleManager.d.ts|
|Added|NA|Class name: deviceSettings;<br>Method or attribute name: function getScreenOffTime(admin: Want, callback: AsyncCallback\<number>): void;|@ohos.enterprise.deviceSettings.d.ts|
|Added|NA|Class name: deviceSettings;<br>Method or attribute name: function getScreenOffTime(admin: Want): Promise\<number>;|@ohos.enterprise.deviceSettings.d.ts|
|Added|NA|Class name: networkManager;<br>Method or attribute name: function addIptablesFilterRule(admin: Want, filterRule: AddFilterRule, callback: AsyncCallback\<void>): void;|@ohos.enterprise.networkManager.d.ts|
|Added|NA|Class name: networkManager;<br>Method or attribute name: function addIptablesFilterRule(admin: Want, filterRule: AddFilterRule): Promise\<void>;|@ohos.enterprise.networkManager.d.ts|
|Added|NA|Class name: networkManager;<br>Method or attribute name: function removeIptablesFilterRule(admin: Want, filterRule: RemoveFilterRule, callback: AsyncCallback\<void>): void;|@ohos.enterprise.networkManager.d.ts|
|Added|NA|Class name: networkManager;<br>Method or attribute name: function removeIptablesFilterRule(admin: Want, filterRule: RemoveFilterRule): Promise\<void>;|@ohos.enterprise.networkManager.d.ts|
|Added|NA|Class name: networkManager;<br>Method or attribute name: function listIptablesFilterRules(admin: Want, callback: AsyncCallback\<string>): void;|@ohos.enterprise.networkManager.d.ts|
|Added|NA|Class name: networkManager;<br>Method or attribute name: function listIptablesFilterRules(admin: Want): Promise\<string>;|@ohos.enterprise.networkManager.d.ts|
|Added|NA|Class name: AddMethod;<br>Method or attribute name: APPEND = 0|@ohos.enterprise.networkManager.d.ts|
|Added|NA|Class name: AddMethod;<br>Method or attribute name: INSERT = 1|@ohos.enterprise.networkManager.d.ts|
|Added|NA|Class name: Direction;<br>Method or attribute name: INPUT = 0|@ohos.enterprise.networkManager.d.ts|
|Added|NA|Class name: Direction;<br>Method or attribute name: OUTPUT = 1|@ohos.enterprise.networkManager.d.ts|
|Added|NA|Class name: Action;<br>Method or attribute name: ALLOW = 0|@ohos.enterprise.networkManager.d.ts|
|Added|NA|Class name: Action;<br>Method or attribute name: DENY = 1|@ohos.enterprise.networkManager.d.ts|
|Added|NA|Class name: Protocol;<br>Method or attribute name: ALL = 0|@ohos.enterprise.networkManager.d.ts|
|Added|NA|Class name: Protocol;<br>Method or attribute name: TCP = 1|@ohos.enterprise.networkManager.d.ts|
|Added|NA|Class name: Protocol;<br>Method or attribute name: UDP = 2|@ohos.enterprise.networkManager.d.ts|
|Added|NA|Class name: Protocol;<br>Method or attribute name: ICMP = 3|@ohos.enterprise.networkManager.d.ts|
|Added|NA|Class name: AddFilterRule;<br>Method or attribute name: ruleNo?: number;|@ohos.enterprise.networkManager.d.ts|
|Added|NA|Class name: AddFilterRule;<br>Method or attribute name: srcAddr?: string;|@ohos.enterprise.networkManager.d.ts|
|Added|NA|Class name: RemoveFilterRule;<br>Method or attribute name: srcAddr?: string;|@ohos.enterprise.networkManager.d.ts|
|Added|NA|Class name: AddFilterRule;<br>Method or attribute name: destAddr?: string;|@ohos.enterprise.networkManager.d.ts|
|Added|NA|Class name: RemoveFilterRule;<br>Method or attribute name: destAddr?: string;|@ohos.enterprise.networkManager.d.ts|
|Added|NA|Class name: AddFilterRule;<br>Method or attribute name: srcPort?: string;|@ohos.enterprise.networkManager.d.ts|
|Added|NA|Class name: RemoveFilterRule;<br>Method or attribute name: srcPort?: string;|@ohos.enterprise.networkManager.d.ts|
|Added|NA|Class name: AddFilterRule;<br>Method or attribute name: destPort?: string;|@ohos.enterprise.networkManager.d.ts|
|Added|NA|Class name: RemoveFilterRule;<br>Method or attribute name: destPort?: string;|@ohos.enterprise.networkManager.d.ts|
|Added|NA|Class name: AddFilterRule;<br>Method or attribute name: uid?: string;|@ohos.enterprise.networkManager.d.ts|
|Added|NA|Class name: RemoveFilterRule;<br>Method or attribute name: uid?: string;|@ohos.enterprise.networkManager.d.ts|
|Added|NA|Class name: AddFilterRule;<br>Method or attribute name: method: AddMethod;|@ohos.enterprise.networkManager.d.ts|
|Added|NA|Class name: AddFilterRule;<br>Method or attribute name: direction: Direction;|@ohos.enterprise.networkManager.d.ts|
|Added|NA|Class name: RemoveFilterRule;<br>Method or attribute name: direction: Direction;|@ohos.enterprise.networkManager.d.ts|
|Added|NA|Class name: AddFilterRule;<br>Method or attribute name: action: Action;|@ohos.enterprise.networkManager.d.ts|
|Added|NA|Class name: AddFilterRule;<br>Method or attribute name: protocol?: Protocol;|@ohos.enterprise.networkManager.d.ts|
|Added|NA|Class name: RemoveFilterRule;<br>Method or attribute name: protocol?: Protocol;|@ohos.enterprise.networkManager.d.ts|
|Added|NA|Class name: RemoveFilterRule;<br>Method or attribute name: action?: Action;|@ohos.enterprise.networkManager.d.ts|
|Added|NA|Class name: restrictions;<br>Method or attribute name: function setPrinterDisabled(admin: Want, disabled: boolean, callback: AsyncCallback\<void>): void;|@ohos.enterprise.restrictions.d.ts|
|Added|NA|Class name: restrictions;<br>Method or attribute name: function setPrinterDisabled(admin: Want, disabled: boolean): Promise\<void>;|@ohos.enterprise.restrictions.d.ts|
|Added|NA|Class name: restrictions;<br>Method or attribute name: function isPrinterDisabled(admin: Want, callback: AsyncCallback\<boolean>): void;|@ohos.enterprise.restrictions.d.ts|
|Added|NA|Class name: restrictions;<br>Method or attribute name: function isPrinterDisabled(admin: Want): Promise\<boolean>;|@ohos.enterprise.restrictions.d.ts|
|Added|NA|Class name: restrictions;<br>Method or attribute name: function setHdcDisabled(admin: Want, disabled: boolean, callback: AsyncCallback\<void>): void;|@ohos.enterprise.restrictions.d.ts|
|Added|NA|Class name: restrictions;<br>Method or attribute name: function setHdcDisabled(admin: Want, disabled: boolean): Promise\<void>;|@ohos.enterprise.restrictions.d.ts|
|Added|NA|Class name: restrictions;<br>Method or attribute name: function isHdcDisabled(admin: Want, callback: AsyncCallback\<boolean>): void;|@ohos.enterprise.restrictions.d.ts|
|Added|NA|Class name: restrictions;<br>Method or attribute name: function isHdcDisabled(admin: Want): Promise\<boolean>;|@ohos.enterprise.restrictions.d.ts|
| Change Type | Old Version | New Version | d.ts File |
| ---- | ------ | ------ | -------- |
|Added|NA|Class name: hiSysEvent;<br>Method or attribute name: function exportSysEvents(queryArg: QueryArg, rules: QueryRule[]): number;|@ohos.hiSysEvent.d.ts|
|Added|NA|Class name: hiSysEvent;<br>Method or attribute name: function subscribe(rules: QueryRule[]): number;|@ohos.hiSysEvent.d.ts|
|Added|NA|Class name: hiSysEvent;<br>Method or attribute name: function unsubscribe(): void;|@ohos.hiSysEvent.d.ts|
|Added|NA|Class name: QueryArg;<br>Method or attribute name: fromSeq?: number;|@ohos.hiSysEvent.d.ts|
|Added|NA|Class name: QueryArg;<br>Method or attribute name: toSeq?: number;|@ohos.hiSysEvent.d.ts|
|Added|NA|Class name: QueryRule;<br>Method or attribute name: condition?: string;|@ohos.hiSysEvent.d.ts|
|Added|NA|Class name: logLibrary;<br>Method or attribute name: function list(logType: string): LogEntry[];|@ohos.logLibrary.d.ts|
|Added|NA|Class name: logLibrary;<br>Method or attribute name: function copy(logType: string, logName: string, dest: string): Promise\<void>;|@ohos.logLibrary.d.ts|
|Added|NA|Class name: logLibrary;<br>Method or attribute name: function copy(logType: string, logName: string, dest: string, callback: AsyncCallback\<void>): void;|@ohos.logLibrary.d.ts|
|Added|NA|Class name: logLibrary;<br>Method or attribute name: function move(logType: string, logName: string, dest: string): Promise\<void>;|@ohos.logLibrary.d.ts|
|Added|NA|Class name: logLibrary;<br>Method or attribute name: function move(logType: string, logName: string, dest: string, callback: AsyncCallback\<void>): void;|@ohos.logLibrary.d.ts|
|Added|NA|Class name: logLibrary;<br>Method or attribute name: function remove(logType: string, logName: string): void;|@ohos.logLibrary.d.ts|
|Added|NA|Class name: LogEntry;<br>Method or attribute name: name: string;|@ohos.logLibrary.d.ts|
|Added|NA|Class name: LogEntry;<br>Method or attribute name: mtime: number;|@ohos.logLibrary.d.ts|
|Added|NA|Class name: LogEntry;<br>Method or attribute name: size: number;|@ohos.logLibrary.d.ts|
|Error code added|Class name: hiSysEvent;<br>Method or attribute name: function write(info: SysEventInfo, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: hiSysEvent;<br>Method or attribute name: function write(info: SysEventInfo, callback: AsyncCallback\<void>): void;<br>New version information: 401,11200001,11200002,11200003,11200004,11200051,11200052,11200053,11200054|@ohos.hiSysEvent.d.ts|
|Error code added|Class name: hiAppEvent;<br>Method or attribute name: function write(info: AppEventInfo, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: hiAppEvent;<br>Method or attribute name: function write(info: AppEventInfo, callback: AsyncCallback\<void>): void;<br>New version information: 401,11100001,11101001,11101002,11101003,11101004,11101005,11101006|@ohos.hiviewdfx.hiAppEvent.d.ts|
|Error code changed|Class name: hiSysEvent;<br>Method or attribute name: function addWatcher(watcher: Watcher): void;<br>Old version information: 201,401,11200101,11200102|Class name: hiSysEvent;<br>Method or attribute name: function addWatcher(watcher: Watcher): void;<br>New version information: 201,202,401,11200101,11200102|@ohos.hiSysEvent.d.ts|
|Error code changed|Class name: hiSysEvent;<br>Method or attribute name: function removeWatcher(watcher: Watcher): void;<br>Old version information: 201,401,11200201|Class name: hiSysEvent;<br>Method or attribute name: function removeWatcher(watcher: Watcher): void;<br>New version information: 201,202,401,11200201|@ohos.hiSysEvent.d.ts|
|Error code changed|Class name: hiSysEvent;<br>Method or attribute name: function query(queryArg: QueryArg, rules: QueryRule[], querier: Querier): void;<br>Old version information: 201,401,11200301,11200302,11200303,11200304|Class name: hiSysEvent;<br>Method or attribute name: function query(queryArg: QueryArg, rules: QueryRule[], querier: Querier): void;<br>New version information: 201,202,401,11200301,11200302,11200303,11200304|@ohos.hiSysEvent.d.ts|
|Access level changed|Class name: hiSysEvent;<br>Method or attribute name: function write(info: SysEventInfo, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: hiSysEvent;<br>Method or attribute name: function write(info: SysEventInfo, callback: AsyncCallback\<void>): void;<br>New version information: systemapi|@ohos.hiSysEvent.d.ts|
|Access level changed|Class name: SysEventInfo;<br>Method or attribute name: domain: string;<br>Old version information: |Class name: SysEventInfo;<br>Method or attribute name: domain: string;<br>New version information: systemapi|@ohos.hiSysEvent.d.ts|
|Access level changed|Class name: WatchRule;<br>Method or attribute name: domain: string;<br>Old version information: |Class name: WatchRule;<br>Method or attribute name: domain: string;<br>New version information: systemapi|@ohos.hiSysEvent.d.ts|
|Access level changed|Class name: QueryRule;<br>Method or attribute name: domain: string;<br>Old version information: |Class name: QueryRule;<br>Method or attribute name: domain: string;<br>New version information: systemapi|@ohos.hiSysEvent.d.ts|
|Access level changed|Class name: SysEventInfo;<br>Method or attribute name: name: string;<br>Old version information: |Class name: SysEventInfo;<br>Method or attribute name: name: string;<br>New version information: systemapi|@ohos.hiSysEvent.d.ts|
|Access level changed|Class name: WatchRule;<br>Method or attribute name: name: string;<br>Old version information: |Class name: WatchRule;<br>Method or attribute name: name: string;<br>New version information: systemapi|@ohos.hiSysEvent.d.ts|
|Access level changed|Class name: SysEventInfo;<br>Method or attribute name: eventType: EventType;<br>Old version information: |Class name: SysEventInfo;<br>Method or attribute name: eventType: EventType;<br>New version information: systemapi|@ohos.hiSysEvent.d.ts|
|Access level changed|Class name: SysEventInfo;<br>Method or attribute name: params: object;<br>Old version information: |Class name: SysEventInfo;<br>Method or attribute name: params: object;<br>New version information: systemapi|@ohos.hiSysEvent.d.ts|
|Access level changed|Class name: WatchRule;<br>Method or attribute name: tag: string;<br>Old version information: |Class name: WatchRule;<br>Method or attribute name: tag: string;<br>New version information: systemapi|@ohos.hiSysEvent.d.ts|
|Access level changed|Class name: WatchRule;<br>Method or attribute name: ruleType: RuleType;<br>Old version information: |Class name: WatchRule;<br>Method or attribute name: ruleType: RuleType;<br>New version information: systemapi|@ohos.hiSysEvent.d.ts|
|Access level changed|Class name: Watcher;<br>Method or attribute name: rules: WatchRule[];<br>Old version information: |Class name: Watcher;<br>Method or attribute name: rules: WatchRule[];<br>New version information: systemapi|@ohos.hiSysEvent.d.ts|
|Access level changed|Class name: QueryArg;<br>Method or attribute name: beginTime: number;<br>Old version information: |Class name: QueryArg;<br>Method or attribute name: beginTime: number;<br>New version information: systemapi|@ohos.hiSysEvent.d.ts|
|Access level changed|Class name: QueryArg;<br>Method or attribute name: endTime: number;<br>Old version information: |Class name: QueryArg;<br>Method or attribute name: endTime: number;<br>New version information: systemapi|@ohos.hiSysEvent.d.ts|
|Access level changed|Class name: QueryArg;<br>Method or attribute name: maxEvents: number;<br>Old version information: |Class name: QueryArg;<br>Method or attribute name: maxEvents: number;<br>New version information: systemapi|@ohos.hiSysEvent.d.ts|
|Access level changed|Class name: QueryRule;<br>Method or attribute name: names: string[];<br>Old version information: |Class name: QueryRule;<br>Method or attribute name: names: string[];<br>New version information: systemapi|@ohos.hiSysEvent.d.ts|
|Type changed|Class name: SysEventInfo;<br>Method or attribute name: domain: string;<br>Old version information: |Class name: SysEventInfo;<br>Method or attribute name: domain: string;<br>New version information: string|@ohos.hiSysEvent.d.ts|
|Type changed|Class name: WatchRule;<br>Method or attribute name: domain: string;<br>Old version information: |Class name: WatchRule;<br>Method or attribute name: domain: string;<br>New version information: string|@ohos.hiSysEvent.d.ts|
|Type changed|Class name: QueryRule;<br>Method or attribute name: domain: string;<br>Old version information: |Class name: QueryRule;<br>Method or attribute name: domain: string;<br>New version information: string|@ohos.hiSysEvent.d.ts|
|Type changed|Class name: SysEventInfo;<br>Method or attribute name: name: string;<br>Old version information: |Class name: SysEventInfo;<br>Method or attribute name: name: string;<br>New version information: string|@ohos.hiSysEvent.d.ts|
|Type changed|Class name: WatchRule;<br>Method or attribute name: name: string;<br>Old version information: |Class name: WatchRule;<br>Method or attribute name: name: string;<br>New version information: string|@ohos.hiSysEvent.d.ts|
|Type changed|Class name: SysEventInfo;<br>Method or attribute name: eventType: EventType;<br>Old version information: |Class name: SysEventInfo;<br>Method or attribute name: eventType: EventType;<br>New version information: EventType|@ohos.hiSysEvent.d.ts|
|Type changed|Class name: SysEventInfo;<br>Method or attribute name: params: object;<br>Old version information: |Class name: SysEventInfo;<br>Method or attribute name: params: object;<br>New version information: object|@ohos.hiSysEvent.d.ts|
|Type changed|Class name: WatchRule;<br>Method or attribute name: tag: string;<br>Old version information: |Class name: WatchRule;<br>Method or attribute name: tag: string;<br>New version information: string|@ohos.hiSysEvent.d.ts|
|Type changed|Class name: WatchRule;<br>Method or attribute name: ruleType: RuleType;<br>Old version information: |Class name: WatchRule;<br>Method or attribute name: ruleType: RuleType;<br>New version information: RuleType|@ohos.hiSysEvent.d.ts|
|Type changed|Class name: QueryArg;<br>Method or attribute name: beginTime: number;<br>Old version information: |Class name: QueryArg;<br>Method or attribute name: beginTime: number;<br>New version information: number|@ohos.hiSysEvent.d.ts|
|Type changed|Class name: QueryArg;<br>Method or attribute name: endTime: number;<br>Old version information: |Class name: QueryArg;<br>Method or attribute name: endTime: number;<br>New version information: number|@ohos.hiSysEvent.d.ts|
|Type changed|Class name: QueryArg;<br>Method or attribute name: maxEvents: number;<br>Old version information: |Class name: QueryArg;<br>Method or attribute name: maxEvents: number;<br>New version information: number|@ohos.hiSysEvent.d.ts|
|Type changed|Class name: QueryRule;<br>Method or attribute name: names: string[];<br>Old version information: |Class name: QueryRule;<br>Method or attribute name: names: string[];<br>New version information: string[]|@ohos.hiSysEvent.d.ts|
|Type changed|Class name: HiTraceId;<br>Method or attribute name: chainId: bigint;<br>Old version information: |Class name: HiTraceId;<br>Method or attribute name: chainId: bigint;<br>New version information: bigint|@ohos.hiTraceChain.d.ts|
|Type changed|Class name: HiTraceId;<br>Method or attribute name: spanId?: number;<br>Old version information: |Class name: HiTraceId;<br>Method or attribute name: spanId?: number;<br>New version information: ?number|@ohos.hiTraceChain.d.ts|
|Type changed|Class name: HiTraceId;<br>Method or attribute name: parentSpanId?: number;<br>Old version information: |Class name: HiTraceId;<br>Method or attribute name: parentSpanId?: number;<br>New version information: ?number|@ohos.hiTraceChain.d.ts|
|Type changed|Class name: HiTraceId;<br>Method or attribute name: flags?: number;<br>Old version information: |Class name: HiTraceId;<br>Method or attribute name: flags?: number;<br>New version information: ?number|@ohos.hiTraceChain.d.ts|
| Change Type | Old Version | New Version | d.ts File |
| ---- | ------ | ------ | -------- |
|Deleted|Class name: Action;<br>Method or attribute name: CLEAR_CLOUD_INFO|NA|@ohos.data.cloudData.d.ts|
|Deleted|Class name: Action;<br>Method or attribute name: CLEAR_CLOUD_DATA_AND_INFO|NA|@ohos.data.cloudData.d.ts|
|Added|NA|Class name: ClearAction;<br>Method or attribute name: CLEAR_CLOUD_INFO|@ohos.data.cloudData.d.ts|
|Added|NA|Class name: ClearAction;<br>Method or attribute name: CLEAR_CLOUD_DATA_AND_INFO|@ohos.data.cloudData.d.ts|
|Added|NA|Class name: Config;<br>Method or attribute name: static clear(<br> accountId: string,<br> appActions: { [bundleName: string]: ClearAction },<br> callback: AsyncCallback\<void><br> ): void;|@ohos.data.cloudData.d.ts|
|Added|NA|Class name: Config;<br>Method or attribute name: static clear(accountId: string, appActions: { [bundleName: string]: ClearAction }): Promise\<void>;|@ohos.data.cloudData.d.ts|
|Added|NA|Class name: preferences;<br>Method or attribute name: function getPreferences(context: Context, options: Options, callback: AsyncCallback\<Preferences>): void;|@ohos.data.preferences.d.ts|
|Added|NA|Class name: preferences;<br>Method or attribute name: function getPreferences(context: Context, options: Options): Promise\<Preferences>;|@ohos.data.preferences.d.ts|
|Added|NA|Class name: preferences;<br>Method or attribute name: function deletePreferences(context: Context, options: Options, callback: AsyncCallback\<void>): void;|@ohos.data.preferences.d.ts|
|Added|NA|Class name: preferences;<br>Method or attribute name: function deletePreferences(context: Context, options: Options): Promise\<void>;|@ohos.data.preferences.d.ts|
|Added|NA|Class name: preferences;<br>Method or attribute name: function removePreferencesFromCache(context: Context, options: Options, callback: AsyncCallback\<void>): void;|@ohos.data.preferences.d.ts|
|Added|NA|Class name: preferences;<br>Method or attribute name: function removePreferencesFromCache(context: Context, options: Options): Promise\<void>;|@ohos.data.preferences.d.ts|
|Added|NA|Class name: preferences;<br>Method or attribute name: function removePreferencesFromCacheSync(context: Context, name: string): void;|@ohos.data.preferences.d.ts|
|Added|NA|Class name: Options;<br>Method or attribute name: name: string;|@ohos.data.preferences.d.ts|
|Added|NA|Class name: Options;<br>Method or attribute name: dataGroupId?: string;|@ohos.data.preferences.d.ts|
|Added|NA|Class name: Preferences;<br>Method or attribute name: getSync(key: string, defValue: ValueType): ValueType;|@ohos.data.preferences.d.ts|
|Added|NA|Class name: Preferences;<br>Method or attribute name: getAllSync(): Object;|@ohos.data.preferences.d.ts|
|Added|NA|Class name: Preferences;<br>Method or attribute name: hasSync(key: string): boolean;|@ohos.data.preferences.d.ts|
|Added|NA|Class name: Preferences;<br>Method or attribute name: putSync(key: string, value: ValueType): void;|@ohos.data.preferences.d.ts|
|Added|NA|Class name: Preferences;<br>Method or attribute name: deleteSync(key: string): void;|@ohos.data.preferences.d.ts|
|Added|NA|Class name: Preferences;<br>Method or attribute name: clearSync(): void;|@ohos.data.preferences.d.ts|
|Added|NA|Class name: Preferences;<br>Method or attribute name: on(type: 'multiProcessChange', callback: Callback\<{ key: string }>): void;|@ohos.data.preferences.d.ts|
|Added|NA|Class name: Preferences;<br>Method or attribute name: off(type: 'multiProcessChange', callback?: Callback\<{ key: string }>): void;|@ohos.data.preferences.d.ts|
|Added|NA|Class name: relationalStore;<br>Method or attribute name: type Assets = Asset[];|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: relationalStore;<br>Method or attribute name: type PRIKeyType = number \| string;|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: relationalStore;<br>Method or attribute name: type UTCTime = Date;|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: relationalStore;<br>Method or attribute name: type ModifyTime = Map\<PRIKeyType, UTCTime>;|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: relationalStore;<br>Method or attribute name: function deleteRdbStore(context: Context, config: StoreConfig, callback: AsyncCallback\<void>): void;|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: relationalStore;<br>Method or attribute name: function deleteRdbStore(context: Context, config: StoreConfig): Promise\<void>;|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: AssetStatus;<br>Method or attribute name: ASSET_NORMAL|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: AssetStatus;<br>Method or attribute name: ASSET_INSERT|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: AssetStatus;<br>Method or attribute name: ASSET_UPDATE|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: AssetStatus;<br>Method or attribute name: ASSET_DELETE|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: AssetStatus;<br>Method or attribute name: ASSET_ABNORMAL|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: AssetStatus;<br>Method or attribute name: ASSET_DOWNLOADING|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: Asset;<br>Method or attribute name: name: string;|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: Asset;<br>Method or attribute name: uri: string;|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: Asset;<br>Method or attribute name: path: string;|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: Asset;<br>Method or attribute name: createTime: string;|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: Asset;<br>Method or attribute name: modifyTime: string;|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: Asset;<br>Method or attribute name: size: string;|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: Asset;<br>Method or attribute name: status?: AssetStatus;|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: StoreConfig;<br>Method or attribute name: dataGroupId?: string;|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: Progress;<br>Method or attribute name: SYNC_BEGIN|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: Progress;<br>Method or attribute name: SYNC_IN_PROGRESS|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: Progress;<br>Method or attribute name: SYNC_FINISH|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: Statistic;<br>Method or attribute name: total: number;|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: Statistic;<br>Method or attribute name: successful: number;|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: Statistic;<br>Method or attribute name: failed: number;|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: Statistic;<br>Method or attribute name: remained: number;|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: TableDetails;<br>Method or attribute name: upload: Statistic;|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: TableDetails;<br>Method or attribute name: download: Statistic;|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: ProgressCode;<br>Method or attribute name: SUCCESS|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: ProgressCode;<br>Method or attribute name: UNKNOWN_ERROR|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: ProgressCode;<br>Method or attribute name: NETWORK_ERROR|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: ProgressCode;<br>Method or attribute name: CLOUD_DISABLED|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: ProgressCode;<br>Method or attribute name: LOCKED_BY_OTHERS|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: ProgressCode;<br>Method or attribute name: RECORD_LIMIT_EXCEEDED|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: ProgressCode;<br>Method or attribute name: NO_SPACE_FOR_ASSET|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: ProgressDetails;<br>Method or attribute name: schedule: Progress;|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: ProgressDetails;<br>Method or attribute name: code: ProgressCode;|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: ProgressDetails;<br>Method or attribute name: details: {<br> [table: string]: TableDetails;<br> };|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: SyncMode;<br>Method or attribute name: SYNC_MODE_TIME_FIRST|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: SyncMode;<br>Method or attribute name: SYNC_MODE_NATIVE_FIRST|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: SyncMode;<br>Method or attribute name: SYNC_MODE_CLOUD_FIRST|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: SubscribeType;<br>Method or attribute name: SUBSCRIBE_TYPE_CLOUD_DETAILS|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: ChangeType;<br>Method or attribute name: DATA_CHANGE|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: ChangeType;<br>Method or attribute name: ASSET_CHANGE|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: ChangeInfo;<br>Method or attribute name: table: string;|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: ChangeInfo;<br>Method or attribute name: type: ChangeType;|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: ChangeInfo;<br>Method or attribute name: inserted: Array\<string> \| Array\<number>;|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: ChangeInfo;<br>Method or attribute name: updated: Array\<string> \| Array\<number>;|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: ChangeInfo;<br>Method or attribute name: deleted: Array\<string> \| Array\<number>;|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: DistributedType;<br>Method or attribute name: DISTRIBUTED_DEVICE|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: DistributedType;<br>Method or attribute name: DISTRIBUTED_CLOUD|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: DistributedConfig;<br>Method or attribute name: autoSync: boolean;|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: ResultSet;<br>Method or attribute name: getAsset(columnIndex: number): Asset;|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: ResultSet;<br>Method or attribute name: getAssets(columnIndex: number): Assets;|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: RdbStore;<br>Method or attribute name: getModifyTime(table: string, columnName: string, primaryKeys: PRIKeyType[]): Promise\<ModifyTime>;|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: RdbStore;<br>Method or attribute name: getModifyTime(<br> table: string,<br> columnName: string,<br> primaryKeys: PRIKeyType[],<br> callback: AsyncCallback\<ModifyTime><br> ): void;|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: RdbStore;<br>Method or attribute name: setDistributedTables(tables: Array\<string>, type: DistributedType, callback: AsyncCallback\<void>): void;|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: RdbStore;<br>Method or attribute name: setDistributedTables(<br> tables: Array\<string>,<br> type: DistributedType,<br> config: DistributedConfig,<br> callback: AsyncCallback\<void><br> ): void;|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: RdbStore;<br>Method or attribute name: setDistributedTables(tables: Array\<string>, type?: DistributedType, config?: DistributedConfig): Promise\<void>;|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: RdbStore;<br>Method or attribute name: cloudSync(mode: SyncMode, progress: Callback\<ProgressDetails>, callback: AsyncCallback\<void>): void;|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: RdbStore;<br>Method or attribute name: cloudSync(mode: SyncMode, progress: Callback\<ProgressDetails>): Promise\<void>;|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: RdbStore;<br>Method or attribute name: cloudSync(<br> mode: SyncMode,<br> tables: string[],<br> progress: Callback\<ProgressDetails>,<br> callback: AsyncCallback\<void><br> ): void;|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: RdbStore;<br>Method or attribute name: cloudSync(mode: SyncMode, tables: string[], progress: Callback\<ProgressDetails>): Promise\<void>;|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: RdbStore;<br>Method or attribute name: on(event: 'dataChange', type: SubscribeType, observer: Callback\<Array\<string>> \| Callback\<Array\<ChangeInfo>>): void;|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: RdbStore;<br>Method or attribute name: on(event: string, interProcess: boolean, observer: Callback\<void>): void;|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: RdbStore;<br>Method or attribute name: off(<br> event: 'dataChange',<br> type: SubscribeType,<br> observer?: Callback\<Array\<string>> \| Callback\<Array\<ChangeInfo>><br> ): void;|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: RdbStore;<br>Method or attribute name: off(event: string, interProcess: boolean, observer?: Callback\<void>): void;|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: RdbStore;<br>Method or attribute name: emit(event: string): void;|@ohos.data.relationalStore.d.ts|
|Added|NA|Class name: UDMF;<br>Method or attribute name: type Options = {<br> /**<br> * indicates the target Intention<br> *<br> * @syscap SystemCapability.DistributedDataManager.UDMF.Core<br> * @since 10<br> */<br> intention?: Intention;<br><br> /**<br> * indicates the unique identifier of target UnifiedData<br> *<br> * @syscap SystemCapability.DistributedDataManager.UDMF.Core<br> * @since 10<br> */<br> key?: string;<br> };|@ohos.data.UDMF.d.ts|
|Added|NA|Class name: UDMF;<br>Method or attribute name: function insertData(options: Options, data: UnifiedData, callback: AsyncCallback\<string>): void;|@ohos.data.UDMF.d.ts|
|Added|NA|Class name: UDMF;<br>Method or attribute name: function insertData(options: Options, data: UnifiedData): Promise\<string>;|@ohos.data.UDMF.d.ts|
|Added|NA|Class name: UDMF;<br>Method or attribute name: function updateData(options: Options, data: UnifiedData, callback: AsyncCallback\<void>): void;|@ohos.data.UDMF.d.ts|
|Added|NA|Class name: UDMF;<br>Method or attribute name: function updateData(options: Options, data: UnifiedData): Promise\<void>;|@ohos.data.UDMF.d.ts|
|Added|NA|Class name: UDMF;<br>Method or attribute name: function queryData(options: Options, callback: AsyncCallback\<Array\<UnifiedData>>): void;|@ohos.data.UDMF.d.ts|
|Added|NA|Class name: UDMF;<br>Method or attribute name: function queryData(options: Options): Promise\<Array\<UnifiedData>>;|@ohos.data.UDMF.d.ts|
|Added|NA|Class name: UDMF;<br>Method or attribute name: function deleteData(options: Options, callback: AsyncCallback\<Array\<UnifiedData>>): void;|@ohos.data.UDMF.d.ts|
|Added|NA|Class name: UDMF;<br>Method or attribute name: function deleteData(options: Options): Promise\<Array\<UnifiedData>>;|@ohos.data.UDMF.d.ts|
|Added|NA|Class name: UnifiedDataType;<br>Method or attribute name: AUDIO = 'File.Media.Audio'|@ohos.data.UDMF.d.ts|
|Added|NA|Class name: Audio;<br>Method or attribute name: audioUri: string;|@ohos.data.UDMF.d.ts|
|Added|NA|Class name: Intention;<br>Method or attribute name: DATA_HUB = 'DataHub'|@ohos.data.UDMF.d.ts|
|Error code changed|Class name: DataAbilityPredicates;<br>Method or attribute name: limitAs(value: number): DataAbilityPredicates;<br>Old version information: IllegalPredicateException|Class name: DataAbilityPredicates;<br>Method or attribute name: limitAs(value: number): DataAbilityPredicates;<br>New version information: |@ohos.data.dataAbility.d.ts|
|Error code changed|Class name: relationalStore;<br>Method or attribute name: function getRdbStore(context: Context, config: StoreConfig, callback: AsyncCallback\<RdbStore>): void;<br>Old version information: 401,14800000,14800010,14800011|Class name: relationalStore;<br>Method or attribute name: function getRdbStore(context: Context, config: StoreConfig, callback: AsyncCallback\<RdbStore>): void;<br>New version information: 401,14800000,14800010,14800011,14801001,14801002|@ohos.data.relationalStore.d.ts|
|Error code changed|Class name: relationalStore;<br>Method or attribute name: function getRdbStore(context: Context, config: StoreConfig): Promise\<RdbStore>;<br>Old version information: 401,14800000,14800010,14800011|Class name: relationalStore;<br>Method or attribute name: function getRdbStore(context: Context, config: StoreConfig): Promise\<RdbStore>;<br>New version information: 401,14800000,14800010,14800011,14801001,14801002|@ohos.data.relationalStore.d.ts|
|Access level changed|Class name: dataSharePredicates;<br>Method or attribute name: declare dataSharePredicates<br>Old version information: systemapi|Class name: dataSharePredicates;<br>Method or attribute name: declare dataSharePredicates<br>New version information: |@ohos.data.dataSharePredicates.d.ts|
|Access level changed|Class name: DataSharePredicates;<br>Method or attribute name: class DataSharePredicates<br>Old version information: systemapi|Class name: DataSharePredicates;<br>Method or attribute name: class DataSharePredicates<br>New version information: |@ohos.data.dataSharePredicates.d.ts|
|Access level changed|Class name: DataSharePredicates;<br>Method or attribute name: equalTo(field: string, value: ValueType): DataSharePredicates;<br>Old version information: systemapi|Class name: DataSharePredicates;<br>Method or attribute name: equalTo(field: string, value: ValueType): DataSharePredicates;<br>New version information: |@ohos.data.dataSharePredicates.d.ts|
|Access level changed|Class name: DataSharePredicates;<br>Method or attribute name: and(): DataSharePredicates;<br>Old version information: systemapi|Class name: DataSharePredicates;<br>Method or attribute name: and(): DataSharePredicates;<br>New version information: |@ohos.data.dataSharePredicates.d.ts|
|Access level changed|Class name: DataSharePredicates;<br>Method or attribute name: orderByAsc(field: string): DataSharePredicates;<br>Old version information: systemapi|Class name: DataSharePredicates;<br>Method or attribute name: orderByAsc(field: string): DataSharePredicates;<br>New version information: |@ohos.data.dataSharePredicates.d.ts|
|Access level changed|Class name: DataSharePredicates;<br>Method or attribute name: orderByDesc(field: string): DataSharePredicates;<br>Old version information: systemapi|Class name: DataSharePredicates;<br>Method or attribute name: orderByDesc(field: string): DataSharePredicates;<br>New version information: |@ohos.data.dataSharePredicates.d.ts|
|Access level changed|Class name: DataSharePredicates;<br>Method or attribute name: limit(total: number, offset: number): DataSharePredicates;<br>Old version information: systemapi|Class name: DataSharePredicates;<br>Method or attribute name: limit(total: number, offset: number): DataSharePredicates;<br>New version information: |@ohos.data.dataSharePredicates.d.ts|
|Access level changed|Class name: DataSharePredicates;<br>Method or attribute name: in(field: string, value: Array\<ValueType>): DataSharePredicates;<br>Old version information: systemapi|Class name: DataSharePredicates;<br>Method or attribute name: in(field: string, value: Array\<ValueType>): DataSharePredicates;<br>New version information: |@ohos.data.dataSharePredicates.d.ts|
|Access level changed|Class name: sourcefile;<br>Method or attribute name: export type ValueType = number \| string \| boolean;<br>Old version information: systemapi|Class name: sourcefile;<br>Method or attribute name: export type ValueType = number \| string \| boolean;<br>New version information: |@ohos.data.ValuesBucket.d.ts|
|Access level changed|Class name: sourcefile;<br>Method or attribute name: export type ValuesBucket = {<br><br> [key: string]: ValueType \| Uint8Array \| null;<br><br>};<br>Old version information: systemapi|Class name: sourcefile;<br>Method or attribute name: export type ValuesBucket = {<br><br> [key: string]: ValueType \| Uint8Array \| null;<br><br>};<br>New version information: |@ohos.data.ValuesBucket.d.ts|
|Type changed|Class name: DataShareExtensionAbility;<br>Method or attribute name: context: ExtensionContext;<br>Old version information: |Class name: DataShareExtensionAbility;<br>Method or attribute name: context: ExtensionContext;<br>New version information: ExtensionContext|@ohos.application.DataShareExtensionAbility.d.ts|
|Function changed|Class name: DataShareExtensionAbility;<br>Method or attribute name: context?: ExtensionContext;|Class name: DataShareExtensionAbility;<br>Method or attribute name: context: ExtensionContext;|@ohos.application.DataShareExtensionAbility.d.ts|
|Function changed|Class name: PublishedItem;<br>Method or attribute name: data: string \| Ashmem;|Class name: PublishedItem;<br>Method or attribute name: data: string \| ArrayBuffer;|@ohos.data.dataShare.d.ts|
|Function changed|Class name: relationalStore;<br>Method or attribute name: type ValueType = null \| number \| string \| boolean \| Uint8Array;|Class name: relationalStore;<br>Method or attribute name: type ValueType = null \| number \| string \| boolean \| Uint8Array \| Asset \| Assets;|@ohos.data.relationalStore.d.ts|
| Change Type | Old Version | New Version | d.ts File |
| ---- | ------ | ------ | -------- |
|Added|NA|Class name: distributedDeviceManager;<br>Method or attribute name: function createDeviceManager(bundleName: string): DeviceManager;|@ohos.distributedDeviceManager.d.ts|
|Added|NA|Class name: distributedDeviceManager;<br>Method or attribute name: function releaseDeviceManager(deviceManager: DeviceManager): void;|@ohos.distributedDeviceManager.d.ts|
|Added|NA|Class name: DeviceBasicInfo;<br>Method or attribute name: deviceId: string;|@ohos.distributedDeviceManager.d.ts|
|Added|NA|Class name: DeviceBasicInfo;<br>Method or attribute name: deviceName: string;|@ohos.distributedDeviceManager.d.ts|
|Added|NA|Class name: DeviceBasicInfo;<br>Method or attribute name: deviceType: number;|@ohos.distributedDeviceManager.d.ts|
|Added|NA|Class name: DeviceBasicInfo;<br>Method or attribute name: networkId?: string;|@ohos.distributedDeviceManager.d.ts|
|Added|NA|Class name: DeviceStateChange;<br>Method or attribute name: UNKNOWN = 0|@ohos.distributedDeviceManager.d.ts|
|Added|NA|Class name: DeviceStateChange;<br>Method or attribute name: AVAILABLE = 1|@ohos.distributedDeviceManager.d.ts|
|Added|NA|Class name: DeviceStateChange;<br>Method or attribute name: UNAVAILABLE = 2|@ohos.distributedDeviceManager.d.ts|
|Added|NA|Class name: DeviceManager;<br>Method or attribute name: getAvailableDeviceListSync(): Array\<DeviceBasicInfo>;|@ohos.distributedDeviceManager.d.ts|
|Added|NA|Class name: DeviceManager;<br>Method or attribute name: getAvailableDeviceList(callback: AsyncCallback\<Array\<DeviceBasicInfo>>): void;|@ohos.distributedDeviceManager.d.ts|
|Added|NA|Class name: DeviceManager;<br>Method or attribute name: getAvailableDeviceList(): Promise\<Array\<DeviceBasicInfo>>;|@ohos.distributedDeviceManager.d.ts|
|Added|NA|Class name: DeviceManager;<br>Method or attribute name: getLocalDeviceNetworkId(): string;|@ohos.distributedDeviceManager.d.ts|
|Added|NA|Class name: DeviceManager;<br>Method or attribute name: getLocalDeviceName(): string;|@ohos.distributedDeviceManager.d.ts|
|Added|NA|Class name: DeviceManager;<br>Method or attribute name: getLocalDeviceType(): number;|@ohos.distributedDeviceManager.d.ts|
|Added|NA|Class name: DeviceManager;<br>Method or attribute name: getLocalDeviceId(): string;|@ohos.distributedDeviceManager.d.ts|
|Added|NA|Class name: DeviceManager;<br>Method or attribute name: getDeviceName(networkId: string): string;|@ohos.distributedDeviceManager.d.ts|
|Added|NA|Class name: DeviceManager;<br>Method or attribute name: getDeviceType(networkId: string): number;|@ohos.distributedDeviceManager.d.ts|
|Added|NA|Class name: DeviceManager;<br>Method or attribute name: startDiscovering(discoverParam: { [key: string]: Object }, filterOptions?: { [key: string]: Object }): void;|@ohos.distributedDeviceManager.d.ts|
|Added|NA|Class name: DeviceManager;<br>Method or attribute name: stopDiscovering(): void;|@ohos.distributedDeviceManager.d.ts|
|Added|NA|Class name: DeviceManager;<br>Method or attribute name: bindTarget(deviceId: string, bindParam: { [key: string]: Object }, callback: AsyncCallback\<{deviceId: string}>): void;|@ohos.distributedDeviceManager.d.ts|
|Added|NA|Class name: DeviceManager;<br>Method or attribute name: unbindTarget(deviceId: string): void;|@ohos.distributedDeviceManager.d.ts|
|Added|NA|Class name: DeviceManager;<br>Method or attribute name: replyUiAction(action: number, actionResult: string): void;|@ohos.distributedDeviceManager.d.ts|
|Added|NA|Class name: DeviceManager;<br>Method or attribute name: on(type: 'deviceStateChange', callback: Callback\<{ action: DeviceStateChange, device: DeviceBasicInfo }>): void;|@ohos.distributedDeviceManager.d.ts|
|Added|NA|Class name: DeviceManager;<br>Method or attribute name: on(type: 'discoverSuccess', callback: Callback\<{ device: DeviceBasicInfo }>): void;|@ohos.distributedDeviceManager.d.ts|
|Added|NA|Class name: DeviceManager;<br>Method or attribute name: on(type: 'deviceNameChange', callback: Callback\<{ deviceName: string }>): void;|@ohos.distributedDeviceManager.d.ts|
|Added|NA|Class name: DeviceManager;<br>Method or attribute name: on(type: 'discoverFailure', callback: Callback\<{ reason: number }>): void;|@ohos.distributedDeviceManager.d.ts|
|Added|NA|Class name: DeviceManager;<br>Method or attribute name: on(type: 'serviceDie', callback?: Callback\<{}>): void;|@ohos.distributedDeviceManager.d.ts|
|Added|NA|Class name: DeviceManager;<br>Method or attribute name: on(type: 'replyResult', callback: Callback\<{ param: string }>): void;|@ohos.distributedDeviceManager.d.ts|
|Added|NA|Class name: DeviceManager;<br>Method or attribute name: off(type: 'deviceStateChange', callback?: Callback\<{ action: DeviceStateChange, device: DeviceBasicInfo }>): void;|@ohos.distributedDeviceManager.d.ts|
|Added|NA|Class name: DeviceManager;<br>Method or attribute name: off(type: 'discoverSuccess', callback?: Callback\<{ device: DeviceBasicInfo }>): void;|@ohos.distributedDeviceManager.d.ts|
|Added|NA|Class name: DeviceManager;<br>Method or attribute name: off(type: 'deviceNameChange', callback?: Callback\<{ deviceName: string }>): void;|@ohos.distributedDeviceManager.d.ts|
|Added|NA|Class name: DeviceManager;<br>Method or attribute name: off(type: 'discoverFailure', callback?: Callback\<{ reason: number }>): void;|@ohos.distributedDeviceManager.d.ts|
|Added|NA|Class name: DeviceManager;<br>Method or attribute name: off(type: 'serviceDie', callback?: Callback\<{}>): void;|@ohos.distributedDeviceManager.d.ts|
|Added|NA|Class name: DeviceManager;<br>Method or attribute name: off(type: 'replyResult', callback?: Callback\<{ param: string }>): void;|@ohos.distributedDeviceManager.d.ts|
|Added|NA|Class name: DeviceManager;<br>Method or attribute name: getTrustedDeviceListSync(isRefresh: boolean): Array\<DeviceInfo>;|@ohos.distributedHardware.deviceManager.d.ts|
|Error code added|Class name: DeviceManager;<br>Method or attribute name: getTrustedDeviceList(): Promise\<Array\<DeviceInfo>>;<br>Old version information: |Class name: DeviceManager;<br>Method or attribute name: getTrustedDeviceList(): Promise\<Array\<DeviceInfo>>;<br>New version information: 202|@ohos.distributedHardware.deviceManager.d.ts|
|Error code added|Class name: DeviceManager;<br>Method or attribute name: getLocalDeviceInfo(): Promise\<DeviceInfo>;<br>Old version information: |Class name: DeviceManager;<br>Method or attribute name: getLocalDeviceInfo(): Promise\<DeviceInfo>;<br>New version information: 202|@ohos.distributedHardware.deviceManager.d.ts|
|Error code changed|Class name: deviceManager;<br>Method or attribute name: function createDeviceManager(bundleName: string, callback: AsyncCallback\<DeviceManager>): void;<br>Old version information: 401|Class name: deviceManager;<br>Method or attribute name: function createDeviceManager(bundleName: string, callback: AsyncCallback\<DeviceManager>): void;<br>New version information: 401,202|@ohos.distributedHardware.deviceManager.d.ts|
|Error code changed|Class name: DeviceManager;<br>Method or attribute name: release(): void;<br>Old version information: 11600101|Class name: DeviceManager;<br>Method or attribute name: release(): void;<br>New version information: 202,201,11600101|@ohos.distributedHardware.deviceManager.d.ts|
|Error code changed|Class name: DeviceManager;<br>Method or attribute name: getTrustedDeviceListSync(): Array\<DeviceInfo>;<br>Old version information: 11600101|Class name: DeviceManager;<br>Method or attribute name: getTrustedDeviceListSync(): Array\<DeviceInfo>;<br>New version information: 202,201,11600101|@ohos.distributedHardware.deviceManager.d.ts|
|Error code changed|Class name: DeviceManager;<br>Method or attribute name: getTrustedDeviceList(callback: AsyncCallback\<Array\<DeviceInfo>>): void;<br>Old version information: 401|Class name: DeviceManager;<br>Method or attribute name: getTrustedDeviceList(callback: AsyncCallback\<Array\<DeviceInfo>>): void;<br>New version information: 202,401|@ohos.distributedHardware.deviceManager.d.ts|
|Error code changed|Class name: DeviceManager;<br>Method or attribute name: getLocalDeviceInfoSync(): DeviceInfo;<br>Old version information: 11600101|Class name: DeviceManager;<br>Method or attribute name: getLocalDeviceInfoSync(): DeviceInfo;<br>New version information: 202,201,11600101|@ohos.distributedHardware.deviceManager.d.ts|
|Error code changed|Class name: DeviceManager;<br>Method or attribute name: getLocalDeviceInfo(callback: AsyncCallback\<DeviceInfo>): void;<br>Old version information: 401|Class name: DeviceManager;<br>Method or attribute name: getLocalDeviceInfo(callback: AsyncCallback\<DeviceInfo>): void;<br>New version information: 401,202|@ohos.distributedHardware.deviceManager.d.ts|
|Error code changed|Class name: DeviceManager;<br>Method or attribute name: getDeviceInfo(networkId: string, callback: AsyncCallback\<DeviceInfo>): void;<br>Old version information: 401|Class name: DeviceManager;<br>Method or attribute name: getDeviceInfo(networkId: string, callback: AsyncCallback\<DeviceInfo>): void;<br>New version information: 401,202|@ohos.distributedHardware.deviceManager.d.ts|
|Error code changed|Class name: DeviceManager;<br>Method or attribute name: getDeviceInfo(networkId: string): Promise\<DeviceInfo>;<br>Old version information: 401|Class name: DeviceManager;<br>Method or attribute name: getDeviceInfo(networkId: string): Promise\<DeviceInfo>;<br>New version information: 401,202|@ohos.distributedHardware.deviceManager.d.ts|
|Error code changed|Class name: DeviceManager;<br>Method or attribute name: startDeviceDiscovery(subscribeInfo: SubscribeInfo): void;<br>Old version information: 401,201,11600104,11600101|Class name: DeviceManager;<br>Method or attribute name: startDeviceDiscovery(subscribeInfo: SubscribeInfo): void;<br>New version information: 401,202,201,11600104,11600101|@ohos.distributedHardware.deviceManager.d.ts|
|Error code changed|Class name: DeviceManager;<br>Method or attribute name: startDeviceDiscovery(subscribeInfo: SubscribeInfo, filterOptions?: string): void;<br>Old version information: 401,201,11600104,11600101|Class name: DeviceManager;<br>Method or attribute name: startDeviceDiscovery(subscribeInfo: SubscribeInfo, filterOptions?: string): void;<br>New version information: 401,202,201,11600104,11600101|@ohos.distributedHardware.deviceManager.d.ts|
|Error code changed|Class name: DeviceManager;<br>Method or attribute name: stopDeviceDiscovery(subscribeId: number): void;<br>Old version information: 401,201,11600101|Class name: DeviceManager;<br>Method or attribute name: stopDeviceDiscovery(subscribeId: number): void;<br>New version information: 401,202,201,11600101|@ohos.distributedHardware.deviceManager.d.ts|
|Error code changed|Class name: DeviceManager;<br>Method or attribute name: publishDeviceDiscovery(publishInfo: PublishInfo): void;<br>Old version information: 401,201,11600105,11600101|Class name: DeviceManager;<br>Method or attribute name: publishDeviceDiscovery(publishInfo: PublishInfo): void;<br>New version information: 401,202,201,11600105,11600101|@ohos.distributedHardware.deviceManager.d.ts|
|Error code changed|Class name: DeviceManager;<br>Method or attribute name: unPublishDeviceDiscovery(publishId: number): void;<br>Old version information: 401,201,11600101|Class name: DeviceManager;<br>Method or attribute name: unPublishDeviceDiscovery(publishId: number): void;<br>New version information: 401,202,201,11600101|@ohos.distributedHardware.deviceManager.d.ts|
|Error code changed|Class name: DeviceManager;<br>Method or attribute name: authenticateDevice(<br> deviceInfo: DeviceInfo,<br> authParam: AuthParam,<br> callback: AsyncCallback\<{ deviceId: string, pinToken?: number }><br> ): void;<br>Old version information: 401|Class name: DeviceManager;<br>Method or attribute name: authenticateDevice(<br> deviceInfo: DeviceInfo,<br> authParam: AuthParam,<br> callback: AsyncCallback\<{ deviceId: string, pinToken?: number }><br> ): void;<br>New version information: 401,202|@ohos.distributedHardware.deviceManager.d.ts|
|Error code changed|Class name: DeviceManager;<br>Method or attribute name: unAuthenticateDevice(deviceInfo: DeviceInfo): void;<br>Old version information: 401,201,11600101|Class name: DeviceManager;<br>Method or attribute name: unAuthenticateDevice(deviceInfo: DeviceInfo): void;<br>New version information: 401,202,201,11600101|@ohos.distributedHardware.deviceManager.d.ts|
|Error code changed|Class name: DeviceManager;<br>Method or attribute name: verifyAuthInfo(authInfo: AuthInfo, callback: AsyncCallback\<{ deviceId: string, level: number }>): void;<br>Old version information: 401|Class name: DeviceManager;<br>Method or attribute name: verifyAuthInfo(authInfo: AuthInfo, callback: AsyncCallback\<{ deviceId: string, level: number }>): void;<br>New version information: 401,202|@ohos.distributedHardware.deviceManager.d.ts|
|Error code changed|Class name: DeviceManager;<br>Method or attribute name: setUserOperation(operateAction: number, params: string): void;<br>Old version information: 401|Class name: DeviceManager;<br>Method or attribute name: setUserOperation(operateAction: number, params: string): void;<br>New version information: 401,202,201|@ohos.distributedHardware.deviceManager.d.ts|
|Error code changed|Class name: DeviceManager;<br>Method or attribute name: requestCredentialRegisterInfo(requestInfo: string, callback: AsyncCallback\<{ registerInfo: string }>): void;<br>Old version information: 401|Class name: DeviceManager;<br>Method or attribute name: requestCredentialRegisterInfo(requestInfo: string, callback: AsyncCallback\<{ registerInfo: string }>): void;<br>New version information: 401,202|@ohos.distributedHardware.deviceManager.d.ts|
|Error code changed|Class name: DeviceManager;<br>Method or attribute name: importCredential(credentialInfo: string, callback: AsyncCallback\<{ resultInfo: string }>): void;<br>Old version information: 401|Class name: DeviceManager;<br>Method or attribute name: importCredential(credentialInfo: string, callback: AsyncCallback\<{ resultInfo: string }>): void;<br>New version information: 401,202|@ohos.distributedHardware.deviceManager.d.ts|
|Error code changed|Class name: DeviceManager;<br>Method or attribute name: deleteCredential(queryInfo: string, callback: AsyncCallback\<{ resultInfo: string }>): void;<br>Old version information: 401|Class name: DeviceManager;<br>Method or attribute name: deleteCredential(queryInfo: string, callback: AsyncCallback\<{ resultInfo: string }>): void;<br>New version information: 401,202|@ohos.distributedHardware.deviceManager.d.ts|
|Error code changed|Class name: DeviceManager;<br>Method or attribute name: on(type: 'uiStateChange', callback: Callback\<{ param: string }>): void;<br>Old version information: 401|Class name: DeviceManager;<br>Method or attribute name: on(type: 'uiStateChange', callback: Callback\<{ param: string }>): void;<br>New version information: 401,202|@ohos.distributedHardware.deviceManager.d.ts|
|Error code changed|Class name: DeviceManager;<br>Method or attribute name: on(type: 'deviceStateChange', callback: Callback\<{ action: DeviceStateChangeAction, device: DeviceInfo }>): void;<br>Old version information: 401|Class name: DeviceManager;<br>Method or attribute name: on(type: 'deviceStateChange', callback: Callback\<{ action: DeviceStateChangeAction, device: DeviceInfo }>): void;<br>New version information: 401,202|@ohos.distributedHardware.deviceManager.d.ts|
|Error code changed|Class name: DeviceManager;<br>Method or attribute name: on(type: 'deviceFound', callback: Callback\<{ subscribeId: number, device: DeviceInfo }>): void;<br>Old version information: 401|Class name: DeviceManager;<br>Method or attribute name: on(type: 'deviceFound', callback: Callback\<{ subscribeId: number, device: DeviceInfo }>): void;<br>New version information: 401,202|@ohos.distributedHardware.deviceManager.d.ts|
|Error code changed|Class name: DeviceManager;<br>Method or attribute name: on(type: 'discoverFail', callback: Callback\<{ subscribeId: number, reason: number }>): void;<br>Old version information: 401|Class name: DeviceManager;<br>Method or attribute name: on(type: 'discoverFail', callback: Callback\<{ subscribeId: number, reason: number }>): void;<br>New version information: 401,202|@ohos.distributedHardware.deviceManager.d.ts|
|Error code changed|Class name: DeviceManager;<br>Method or attribute name: on(type: 'publishSuccess', callback: Callback\<{ publishId: number }>): void;<br>Old version information: 401|Class name: DeviceManager;<br>Method or attribute name: on(type: 'publishSuccess', callback: Callback\<{ publishId: number }>): void;<br>New version information: 401,202|@ohos.distributedHardware.deviceManager.d.ts|
|Error code changed|Class name: DeviceManager;<br>Method or attribute name: on(type: 'publishFail', callback: Callback\<{ publishId: number, reason: number }>): void;<br>Old version information: 401|Class name: DeviceManager;<br>Method or attribute name: on(type: 'publishFail', callback: Callback\<{ publishId: number, reason: number }>): void;<br>New version information: 401,202|@ohos.distributedHardware.deviceManager.d.ts|
|Error code changed|Class name: DeviceManager;<br>Method or attribute name: on(type: 'serviceDie', callback: () => void): void;<br>Old version information: 401|Class name: DeviceManager;<br>Method or attribute name: on(type: 'serviceDie', callback: () => void): void;<br>New version information: 401,202|@ohos.distributedHardware.deviceManager.d.ts|
|Error code changed|Class name: DeviceManager;<br>Method or attribute name: off(type: 'uiStateChange', callback?: Callback\<{ param: string }>): void;<br>Old version information: 401|Class name: DeviceManager;<br>Method or attribute name: off(type: 'uiStateChange', callback?: Callback\<{ param: string }>): void;<br>New version information: 401,202|@ohos.distributedHardware.deviceManager.d.ts|
|Error code changed|Class name: DeviceManager;<br>Method or attribute name: off(type: 'deviceStateChange', callback?: Callback\<{ action: DeviceStateChangeAction, device: DeviceInfo }>): void;<br>Old version information: 401|Class name: DeviceManager;<br>Method or attribute name: off(type: 'deviceStateChange', callback?: Callback\<{ action: DeviceStateChangeAction, device: DeviceInfo }>): void;<br>New version information: 401,202|@ohos.distributedHardware.deviceManager.d.ts|
|Error code changed|Class name: DeviceManager;<br>Method or attribute name: off(type: 'deviceFound', callback?: Callback\<{ subscribeId: number, device: DeviceInfo }>): void;<br>Old version information: 401|Class name: DeviceManager;<br>Method or attribute name: off(type: 'deviceFound', callback?: Callback\<{ subscribeId: number, device: DeviceInfo }>): void;<br>New version information: 401,202|@ohos.distributedHardware.deviceManager.d.ts|
|Error code changed|Class name: DeviceManager;<br>Method or attribute name: off(type: 'discoverFail', callback?: Callback\<{ subscribeId: number, reason: number }>): void;<br>Old version information: 401|Class name: DeviceManager;<br>Method or attribute name: off(type: 'discoverFail', callback?: Callback\<{ subscribeId: number, reason: number }>): void;<br>New version information: 401,202|@ohos.distributedHardware.deviceManager.d.ts|
|Error code changed|Class name: DeviceManager;<br>Method or attribute name: off(type: 'publishSuccess', callback?: Callback\<{ publishId: number }>): void;<br>Old version information: 401|Class name: DeviceManager;<br>Method or attribute name: off(type: 'publishSuccess', callback?: Callback\<{ publishId: number }>): void;<br>New version information: 401,202|@ohos.distributedHardware.deviceManager.d.ts|
|Error code changed|Class name: DeviceManager;<br>Method or attribute name: off(type: 'publishFail', callback?: Callback\<{ publishId: number, reason: number }>): void;<br>Old version information: 401|Class name: DeviceManager;<br>Method or attribute name: off(type: 'publishFail', callback?: Callback\<{ publishId: number, reason: number }>): void;<br>New version information: 401,202|@ohos.distributedHardware.deviceManager.d.ts|
|Error code changed|Class name: DeviceManager;<br>Method or attribute name: off(type: 'serviceDie', callback?: () => void): void;<br>Old version information: 401|Class name: DeviceManager;<br>Method or attribute name: off(type: 'serviceDie', callback?: () => void): void;<br>New version information: 401,202|@ohos.distributedHardware.deviceManager.d.ts|
|Access level changed|Class name: DeviceInfo;<br>Method or attribute name: deviceId: string;<br>Old version information: |Class name: DeviceInfo;<br>Method or attribute name: deviceId: string;<br>New version information: systemapi|@ohos.distributedHardware.deviceManager.d.ts|
|Access level changed|Class name: DeviceInfo;<br>Method or attribute name: deviceName: string;<br>Old version information: |Class name: DeviceInfo;<br>Method or attribute name: deviceName: string;<br>New version information: systemapi|@ohos.distributedHardware.deviceManager.d.ts|
|Access level changed|Class name: DeviceInfo;<br>Method or attribute name: deviceType: DeviceType;<br>Old version information: |Class name: DeviceInfo;<br>Method or attribute name: deviceType: DeviceType;<br>New version information: systemapi|@ohos.distributedHardware.deviceManager.d.ts|
|Access level changed|Class name: DeviceInfo;<br>Method or attribute name: networkId: string;<br>Old version information: |Class name: DeviceInfo;<br>Method or attribute name: networkId: string;<br>New version information: systemapi|@ohos.distributedHardware.deviceManager.d.ts|
|Access level changed|Class name: DeviceInfo;<br>Method or attribute name: range: number;<br>Old version information: |Class name: DeviceInfo;<br>Method or attribute name: range: number;<br>New version information: systemapi|@ohos.distributedHardware.deviceManager.d.ts|
|Access level changed|Class name: DeviceInfo;<br>Method or attribute name: authForm: AuthForm;<br>Old version information: |Class name: DeviceInfo;<br>Method or attribute name: authForm: AuthForm;<br>New version information: systemapi|@ohos.distributedHardware.deviceManager.d.ts|
|Access level changed|Class name: AuthForm;<br>Method or attribute name: INVALID_TYPE = -1<br>Old version information: |Class name: AuthForm;<br>Method or attribute name: INVALID_TYPE = -1<br>New version information: systemapi|@ohos.distributedHardware.deviceManager.d.ts|
|Access level changed|Class name: AuthForm;<br>Method or attribute name: PEER_TO_PEER = 0<br>Old version information: |Class name: AuthForm;<br>Method or attribute name: PEER_TO_PEER = 0<br>New version information: systemapi|@ohos.distributedHardware.deviceManager.d.ts|
|Access level changed|Class name: AuthForm;<br>Method or attribute name: IDENTICAL_ACCOUNT = 1<br>Old version information: |Class name: AuthForm;<br>Method or attribute name: IDENTICAL_ACCOUNT = 1<br>New version information: systemapi|@ohos.distributedHardware.deviceManager.d.ts|
|Access level changed|Class name: AuthForm;<br>Method or attribute name: ACROSS_ACCOUNT = 2<br>Old version information: |Class name: AuthForm;<br>Method or attribute name: ACROSS_ACCOUNT = 2<br>New version information: systemapi|@ohos.distributedHardware.deviceManager.d.ts|
|Access level changed|Class name: DeviceType;<br>Method or attribute name: UNKNOWN_TYPE = 0<br>Old version information: |Class name: DeviceType;<br>Method or attribute name: UNKNOWN_TYPE = 0<br>New version information: systemapi|@ohos.distributedHardware.deviceManager.d.ts|
|Access level changed|Class name: DeviceType;<br>Method or attribute name: SPEAKER = 0x0A<br>Old version information: |Class name: DeviceType;<br>Method or attribute name: SPEAKER = 0x0A<br>New version information: systemapi|@ohos.distributedHardware.deviceManager.d.ts|
|Access level changed|Class name: DeviceType;<br>Method or attribute name: PHONE = 0x0E<br>Old version information: |Class name: DeviceType;<br>Method or attribute name: PHONE = 0x0E<br>New version information: systemapi|@ohos.distributedHardware.deviceManager.d.ts|
|Access level changed|Class name: DeviceType;<br>Method or attribute name: TABLET = 0x11<br>Old version information: |Class name: DeviceType;<br>Method or attribute name: TABLET = 0x11<br>New version information: systemapi|@ohos.distributedHardware.deviceManager.d.ts|
|Access level changed|Class name: DeviceType;<br>Method or attribute name: WEARABLE = 0x6D<br>Old version information: |Class name: DeviceType;<br>Method or attribute name: WEARABLE = 0x6D<br>New version information: systemapi|@ohos.distributedHardware.deviceManager.d.ts|
|Access level changed|Class name: DeviceType;<br>Method or attribute name: CAR = 0x83<br>Old version information: |Class name: DeviceType;<br>Method or attribute name: CAR = 0x83<br>New version information: systemapi|@ohos.distributedHardware.deviceManager.d.ts|
|Access level changed|Class name: DeviceType;<br>Method or attribute name: TV = 0x9C<br>Old version information: |Class name: DeviceType;<br>Method or attribute name: TV = 0x9C<br>New version information: systemapi|@ohos.distributedHardware.deviceManager.d.ts|
|Access level changed|Class name: DeviceStateChangeAction;<br>Method or attribute name: ONLINE = 0<br>Old version information: |Class name: DeviceStateChangeAction;<br>Method or attribute name: ONLINE = 0<br>New version information: systemapi|@ohos.distributedHardware.deviceManager.d.ts|
|Access level changed|Class name: DeviceStateChangeAction;<br>Method or attribute name: READY = 1<br>Old version information: |Class name: DeviceStateChangeAction;<br>Method or attribute name: READY = 1<br>New version information: systemapi|@ohos.distributedHardware.deviceManager.d.ts|
|Access level changed|Class name: DeviceStateChangeAction;<br>Method or attribute name: OFFLINE = 2<br>Old version information: |Class name: DeviceStateChangeAction;<br>Method or attribute name: OFFLINE = 2<br>New version information: systemapi|@ohos.distributedHardware.deviceManager.d.ts|
|Access level changed|Class name: DeviceStateChangeAction;<br>Method or attribute name: CHANGE = 3<br>Old version information: |Class name: DeviceStateChangeAction;<br>Method or attribute name: CHANGE = 3<br>New version information: systemapi|@ohos.distributedHardware.deviceManager.d.ts|
|Access level changed|Class name: SubscribeInfo;<br>Method or attribute name: subscribeId: number;<br>Old version information: |Class name: SubscribeInfo;<br>Method or attribute name: subscribeId: number;<br>New version information: systemapi|@ohos.distributedHardware.deviceManager.d.ts|
|Access level changed|Class name: SubscribeInfo;<br>Method or attribute name: mode: DiscoverMode;<br>Old version information: |Class name: SubscribeInfo;<br>Method or attribute name: mode: DiscoverMode;<br>New version information: systemapi|@ohos.distributedHardware.deviceManager.d.ts|
|Access level changed|Class name: PublishInfo;<br>Method or attribute name: mode: DiscoverMode;<br>Old version information: |Class name: PublishInfo;<br>Method or attribute name: mode: DiscoverMode;<br>New version information: systemapi|@ohos.distributedHardware.deviceManager.d.ts|
|Access level changed|Class name: SubscribeInfo;<br>Method or attribute name: medium: ExchangeMedium;<br>Old version information: |Class name: SubscribeInfo;<br>Method or attribute name: medium: ExchangeMedium;<br>New version information: systemapi|@ohos.distributedHardware.deviceManager.d.ts|
|Access level changed|Class name: SubscribeInfo;<br>Method or attribute name: freq: ExchangeFreq;<br>Old version information: |Class name: SubscribeInfo;<br>Method or attribute name: freq: ExchangeFreq;<br>New version information: systemapi|@ohos.distributedHardware.deviceManager.d.ts|
|Access level changed|Class name: PublishInfo;<br>Method or attribute name: freq: ExchangeFreq;<br>Old version information: |Class name: PublishInfo;<br>Method or attribute name: freq: ExchangeFreq;<br>New version information: systemapi|@ohos.distributedHardware.deviceManager.d.ts|
|Access level changed|Class name: SubscribeInfo;<br>Method or attribute name: isSameAccount: boolean;<br>Old version information: |Class name: SubscribeInfo;<br>Method or attribute name: isSameAccount: boolean;<br>New version information: systemapi|@ohos.distributedHardware.deviceManager.d.ts|
|Access level changed|Class name: SubscribeInfo;<br>Method or attribute name: isWakeRemote: boolean;<br>Old version information: |Class name: SubscribeInfo;<br>Method or attribute name: isWakeRemote: boolean;<br>New version information: systemapi|@ohos.distributedHardware.deviceManager.d.ts|
|Access level changed|Class name: SubscribeInfo;<br>Method or attribute name: capability: SubscribeCap;<br>Old version information: |Class name: SubscribeInfo;<br>Method or attribute name: capability: SubscribeCap;<br>New version information: systemapi|@ohos.distributedHardware.deviceManager.d.ts|
|Access level changed|Class name: PublishInfo;<br>Method or attribute name: publishId: number;<br>Old version information: |Class name: PublishInfo;<br>Method or attribute name: publishId: number;<br>New version information: systemapi|@ohos.distributedHardware.deviceManager.d.ts|
|Access level changed|Class name: PublishInfo;<br>Method or attribute name: ranging: boolean;<br>Old version information: |Class name: PublishInfo;<br>Method or attribute name: ranging: boolean;<br>New version information: systemapi|@ohos.distributedHardware.deviceManager.d.ts|
|Access level changed|Class name: DiscoverMode;<br>Method or attribute name: DISCOVER_MODE_PASSIVE = 0x55<br>Old version information: |Class name: DiscoverMode;<br>Method or attribute name: DISCOVER_MODE_PASSIVE = 0x55<br>New version information: systemapi|@ohos.distributedHardware.deviceManager.d.ts|
|Access level changed|Class name: DiscoverMode;<br>Method or attribute name: DISCOVER_MODE_ACTIVE = 0xAA<br>Old version information: |Class name: DiscoverMode;<br>Method or attribute name: DISCOVER_MODE_ACTIVE = 0xAA<br>New version information: systemapi|@ohos.distributedHardware.deviceManager.d.ts|
|Access level changed|Class name: ExchangeMedium;<br>Method or attribute name: AUTO = 0<br>Old version information: |Class name: ExchangeMedium;<br>Method or attribute name: AUTO = 0<br>New version information: systemapi|@ohos.distributedHardware.deviceManager.d.ts|
|Access level changed|Class name: ExchangeMedium;<br>Method or attribute name: BLE = 1<br>Old version information: |Class name: ExchangeMedium;<br>Method or attribute name: BLE = 1<br>New version information: systemapi|@ohos.distributedHardware.deviceManager.d.ts|
|Access level changed|Class name: ExchangeMedium;<br>Method or attribute name: COAP = 2<br>Old version information: |Class name: ExchangeMedium;<br>Method or attribute name: COAP = 2<br>New version information: systemapi|@ohos.distributedHardware.deviceManager.d.ts|
|Access level changed|Class name: ExchangeMedium;<br>Method or attribute name: USB = 3<br>Old version information: |Class name: ExchangeMedium;<br>Method or attribute name: USB = 3<br>New version information: systemapi|@ohos.distributedHardware.deviceManager.d.ts|
|Access level changed|Class name: ExchangeFreq;<br>Method or attribute name: LOW = 0<br>Old version information: |Class name: ExchangeFreq;<br>Method or attribute name: LOW = 0<br>New version information: systemapi|@ohos.distributedHardware.deviceManager.d.ts|
|Access level changed|Class name: ExchangeFreq;<br>Method or attribute name: MID = 1<br>Old version information: |Class name: ExchangeFreq;<br>Method or attribute name: MID = 1<br>New version information: systemapi|@ohos.distributedHardware.deviceManager.d.ts|
|Access level changed|Class name: ExchangeFreq;<br>Method or attribute name: HIGH = 2<br>Old version information: |Class name: ExchangeFreq;<br>Method or attribute name: HIGH = 2<br>New version information: systemapi|@ohos.distributedHardware.deviceManager.d.ts|
|Access level changed|Class name: ExchangeFreq;<br>Method or attribute name: SUPER_HIGH = 3<br>Old version information: |Class name: ExchangeFreq;<br>Method or attribute name: SUPER_HIGH = 3<br>New version information: systemapi|@ohos.distributedHardware.deviceManager.d.ts|
|Access level changed|Class name: SubscribeCap;<br>Method or attribute name: SUBSCRIBE_CAPABILITY_DDMP = 0<br>Old version information: |Class name: SubscribeCap;<br>Method or attribute name: SUBSCRIBE_CAPABILITY_DDMP = 0<br>New version information: systemapi|@ohos.distributedHardware.deviceManager.d.ts|
|Access level changed|Class name: SubscribeCap;<br>Method or attribute name: SUBSCRIBE_CAPABILITY_OSD = 1<br>Old version information: |Class name: SubscribeCap;<br>Method or attribute name: SUBSCRIBE_CAPABILITY_OSD = 1<br>New version information: systemapi|@ohos.distributedHardware.deviceManager.d.ts|
|Access level changed|Class name: AuthParam;<br>Method or attribute name: authType: number;<br>Old version information: |Class name: AuthParam;<br>Method or attribute name: authType: number;<br>New version information: systemapi|@ohos.distributedHardware.deviceManager.d.ts|
|Access level changed|Class name: AuthInfo;<br>Method or attribute name: authType: number;<br>Old version information: |Class name: AuthInfo;<br>Method or attribute name: authType: number;<br>New version information: systemapi|@ohos.distributedHardware.deviceManager.d.ts|
|Access level changed|Class name: AuthParam;<br>Method or attribute name: extraInfo: { [key: string]: any };<br>Old version information: |Class name: AuthParam;<br>Method or attribute name: extraInfo: { [key: string]: any };<br>New version information: systemapi|@ohos.distributedHardware.deviceManager.d.ts|
|Access level changed|Class name: AuthInfo;<br>Method or attribute name: extraInfo: { [key: string]: any };<br>Old version information: |Class name: AuthInfo;<br>Method or attribute name: extraInfo: { [key: string]: any };<br>New version information: systemapi|@ohos.distributedHardware.deviceManager.d.ts|
|Access level changed|Class name: AuthInfo;<br>Method or attribute name: token: number;<br>Old version information: |Class name: AuthInfo;<br>Method or attribute name: token: number;<br>New version information: systemapi|@ohos.distributedHardware.deviceManager.d.ts|
|Permission changed|Class name: DeviceManager;<br>Method or attribute name: release(): void;<br>Old version information: |Class name: DeviceManager;<br>Method or attribute name: release(): void;<br>New version information: ohos.permission.ACCESS_SERVICE_DM|@ohos.distributedHardware.deviceManager.d.ts|
|Permission changed|Class name: DeviceManager;<br>Method or attribute name: getTrustedDeviceListSync(): Array\<DeviceInfo>;<br>Old version information: |Class name: DeviceManager;<br>Method or attribute name: getTrustedDeviceListSync(): Array\<DeviceInfo>;<br>New version information: ohos.permission.ACCESS_SERVICE_DM|@ohos.distributedHardware.deviceManager.d.ts|
|Permission changed|Class name: DeviceManager;<br>Method or attribute name: getTrustedDeviceList(callback: AsyncCallback\<Array\<DeviceInfo>>): void;<br>Old version information: |Class name: DeviceManager;<br>Method or attribute name: getTrustedDeviceList(callback: AsyncCallback\<Array\<DeviceInfo>>): void;<br>New version information: ohos.permission.ACCESS_SERVICE_DM|@ohos.distributedHardware.deviceManager.d.ts|
|Permission changed|Class name: DeviceManager;<br>Method or attribute name: getTrustedDeviceList(): Promise\<Array\<DeviceInfo>>;<br>Old version information: |Class name: DeviceManager;<br>Method or attribute name: getTrustedDeviceList(): Promise\<Array\<DeviceInfo>>;<br>New version information: ohos.permission.ACCESS_SERVICE_DM|@ohos.distributedHardware.deviceManager.d.ts|
|Permission changed|Class name: DeviceManager;<br>Method or attribute name: getLocalDeviceInfoSync(): DeviceInfo;<br>Old version information: |Class name: DeviceManager;<br>Method or attribute name: getLocalDeviceInfoSync(): DeviceInfo;<br>New version information: ohos.permission.ACCESS_SERVICE_DM|@ohos.distributedHardware.deviceManager.d.ts|
|Permission changed|Class name: DeviceManager;<br>Method or attribute name: getLocalDeviceInfo(callback: AsyncCallback\<DeviceInfo>): void;<br>Old version information: |Class name: DeviceManager;<br>Method or attribute name: getLocalDeviceInfo(callback: AsyncCallback\<DeviceInfo>): void;<br>New version information: ohos.permission.ACCESS_SERVICE_DM|@ohos.distributedHardware.deviceManager.d.ts|
|Permission changed|Class name: DeviceManager;<br>Method or attribute name: getLocalDeviceInfo(): Promise\<DeviceInfo>;<br>Old version information: |Class name: DeviceManager;<br>Method or attribute name: getLocalDeviceInfo(): Promise\<DeviceInfo>;<br>New version information: ohos.permission.ACCESS_SERVICE_DM|@ohos.distributedHardware.deviceManager.d.ts|
|Permission changed|Class name: DeviceManager;<br>Method or attribute name: getDeviceInfo(networkId: string, callback: AsyncCallback\<DeviceInfo>): void;<br>Old version information: |Class name: DeviceManager;<br>Method or attribute name: getDeviceInfo(networkId: string, callback: AsyncCallback\<DeviceInfo>): void;<br>New version information: ohos.permission.ACCESS_SERVICE_DM|@ohos.distributedHardware.deviceManager.d.ts|
|Permission changed|Class name: DeviceManager;<br>Method or attribute name: getDeviceInfo(networkId: string): Promise\<DeviceInfo>;<br>Old version information: |Class name: DeviceManager;<br>Method or attribute name: getDeviceInfo(networkId: string): Promise\<DeviceInfo>;<br>New version information: ohos.permission.ACCESS_SERVICE_DM|@ohos.distributedHardware.deviceManager.d.ts|
|Permission changed|Class name: DeviceManager;<br>Method or attribute name: startDeviceDiscovery(subscribeInfo: SubscribeInfo): void;<br>Old version information: |Class name: DeviceManager;<br>Method or attribute name: startDeviceDiscovery(subscribeInfo: SubscribeInfo): void;<br>New version information: ohos.permission.ACCESS_SERVICE_DM|@ohos.distributedHardware.deviceManager.d.ts|
|Permission changed|Class name: DeviceManager;<br>Method or attribute name: startDeviceDiscovery(subscribeInfo: SubscribeInfo, filterOptions?: string): void;<br>Old version information: |Class name: DeviceManager;<br>Method or attribute name: startDeviceDiscovery(subscribeInfo: SubscribeInfo, filterOptions?: string): void;<br>New version information: ohos.permission.ACCESS_SERVICE_DM|@ohos.distributedHardware.deviceManager.d.ts|
|Permission changed|Class name: DeviceManager;<br>Method or attribute name: stopDeviceDiscovery(subscribeId: number): void;<br>Old version information: |Class name: DeviceManager;<br>Method or attribute name: stopDeviceDiscovery(subscribeId: number): void;<br>New version information: ohos.permission.ACCESS_SERVICE_DM|@ohos.distributedHardware.deviceManager.d.ts|
|Permission changed|Class name: DeviceManager;<br>Method or attribute name: publishDeviceDiscovery(publishInfo: PublishInfo): void;<br>Old version information: |Class name: DeviceManager;<br>Method or attribute name: publishDeviceDiscovery(publishInfo: PublishInfo): void;<br>New version information: ohos.permission.ACCESS_SERVICE_DM|@ohos.distributedHardware.deviceManager.d.ts|
|Permission changed|Class name: DeviceManager;<br>Method or attribute name: unPublishDeviceDiscovery(publishId: number): void;<br>Old version information: |Class name: DeviceManager;<br>Method or attribute name: unPublishDeviceDiscovery(publishId: number): void;<br>New version information: ohos.permission.ACCESS_SERVICE_DM|@ohos.distributedHardware.deviceManager.d.ts|
|Permission changed|Class name: DeviceManager;<br>Method or attribute name: authenticateDevice(<br> deviceInfo: DeviceInfo,<br> authParam: AuthParam,<br> callback: AsyncCallback\<{ deviceId: string, pinToken?: number }><br> ): void;<br>Old version information: |Class name: DeviceManager;<br>Method or attribute name: authenticateDevice(<br> deviceInfo: DeviceInfo,<br> authParam: AuthParam,<br> callback: AsyncCallback\<{ deviceId: string, pinToken?: number }><br> ): void;<br>New version information: ohos.permission.ACCESS_SERVICE_DM|@ohos.distributedHardware.deviceManager.d.ts|
|Permission changed|Class name: DeviceManager;<br>Method or attribute name: unAuthenticateDevice(deviceInfo: DeviceInfo): void;<br>Old version information: |Class name: DeviceManager;<br>Method or attribute name: unAuthenticateDevice(deviceInfo: DeviceInfo): void;<br>New version information: ohos.permission.ACCESS_SERVICE_DM|@ohos.distributedHardware.deviceManager.d.ts|
|Permission changed|Class name: DeviceManager;<br>Method or attribute name: verifyAuthInfo(authInfo: AuthInfo, callback: AsyncCallback\<{ deviceId: string, level: number }>): void;<br>Old version information: |Class name: DeviceManager;<br>Method or attribute name: verifyAuthInfo(authInfo: AuthInfo, callback: AsyncCallback\<{ deviceId: string, level: number }>): void;<br>New version information: ohos.permission.ACCESS_SERVICE_DM|@ohos.distributedHardware.deviceManager.d.ts|
|Permission changed|Class name: DeviceManager;<br>Method or attribute name: setUserOperation(operateAction: number, params: string): void;<br>Old version information: |Class name: DeviceManager;<br>Method or attribute name: setUserOperation(operateAction: number, params: string): void;<br>New version information: ohos.permission.ACCESS_SERVICE_DM|@ohos.distributedHardware.deviceManager.d.ts|
|Permission changed|Class name: DeviceManager;<br>Method or attribute name: requestCredentialRegisterInfo(requestInfo: string, callback: AsyncCallback\<{ registerInfo: string }>): void;<br>Old version information: |Class name: DeviceManager;<br>Method or attribute name: requestCredentialRegisterInfo(requestInfo: string, callback: AsyncCallback\<{ registerInfo: string }>): void;<br>New version information: ohos.permission.ACCESS_SERVICE_DM|@ohos.distributedHardware.deviceManager.d.ts|
|Permission changed|Class name: DeviceManager;<br>Method or attribute name: importCredential(credentialInfo: string, callback: AsyncCallback\<{ resultInfo: string }>): void;<br>Old version information: |Class name: DeviceManager;<br>Method or attribute name: importCredential(credentialInfo: string, callback: AsyncCallback\<{ resultInfo: string }>): void;<br>New version information: ohos.permission.ACCESS_SERVICE_DM|@ohos.distributedHardware.deviceManager.d.ts|
|Permission changed|Class name: DeviceManager;<br>Method or attribute name: deleteCredential(queryInfo: string, callback: AsyncCallback\<{ resultInfo: string }>): void;<br>Old version information: |Class name: DeviceManager;<br>Method or attribute name: deleteCredential(queryInfo: string, callback: AsyncCallback\<{ resultInfo: string }>): void;<br>New version information: ohos.permission.ACCESS_SERVICE_DM|@ohos.distributedHardware.deviceManager.d.ts|
|Permission changed|Class name: DeviceManager;<br>Method or attribute name: on(type: 'uiStateChange', callback: Callback\<{ param: string }>): void;<br>Old version information: |Class name: DeviceManager;<br>Method or attribute name: on(type: 'uiStateChange', callback: Callback\<{ param: string }>): void;<br>New version information: ohos.permission.ACCESS_SERVICE_DM|@ohos.distributedHardware.deviceManager.d.ts|
|Permission changed|Class name: DeviceManager;<br>Method or attribute name: on(type: 'deviceStateChange', callback: Callback\<{ action: DeviceStateChangeAction, device: DeviceInfo }>): void;<br>Old version information: |Class name: DeviceManager;<br>Method or attribute name: on(type: 'deviceStateChange', callback: Callback\<{ action: DeviceStateChangeAction, device: DeviceInfo }>): void;<br>New version information: ohos.permission.ACCESS_SERVICE_DM|@ohos.distributedHardware.deviceManager.d.ts|
|Permission changed|Class name: DeviceManager;<br>Method or attribute name: on(type: 'deviceFound', callback: Callback\<{ subscribeId: number, device: DeviceInfo }>): void;<br>Old version information: |Class name: DeviceManager;<br>Method or attribute name: on(type: 'deviceFound', callback: Callback\<{ subscribeId: number, device: DeviceInfo }>): void;<br>New version information: ohos.permission.ACCESS_SERVICE_DM|@ohos.distributedHardware.deviceManager.d.ts|
|Permission changed|Class name: DeviceManager;<br>Method or attribute name: on(type: 'discoverFail', callback: Callback\<{ subscribeId: number, reason: number }>): void;<br>Old version information: |Class name: DeviceManager;<br>Method or attribute name: on(type: 'discoverFail', callback: Callback\<{ subscribeId: number, reason: number }>): void;<br>New version information: ohos.permission.ACCESS_SERVICE_DM|@ohos.distributedHardware.deviceManager.d.ts|
|Permission changed|Class name: DeviceManager;<br>Method or attribute name: on(type: 'publishSuccess', callback: Callback\<{ publishId: number }>): void;<br>Old version information: |Class name: DeviceManager;<br>Method or attribute name: on(type: 'publishSuccess', callback: Callback\<{ publishId: number }>): void;<br>New version information: ohos.permission.ACCESS_SERVICE_DM|@ohos.distributedHardware.deviceManager.d.ts|
|Permission changed|Class name: DeviceManager;<br>Method or attribute name: on(type: 'publishFail', callback: Callback\<{ publishId: number, reason: number }>): void;<br>Old version information: |Class name: DeviceManager;<br>Method or attribute name: on(type: 'publishFail', callback: Callback\<{ publishId: number, reason: number }>): void;<br>New version information: ohos.permission.ACCESS_SERVICE_DM|@ohos.distributedHardware.deviceManager.d.ts|
|Permission changed|Class name: DeviceManager;<br>Method or attribute name: on(type: 'serviceDie', callback: () => void): void;<br>Old version information: |Class name: DeviceManager;<br>Method or attribute name: on(type: 'serviceDie', callback: () => void): void;<br>New version information: ohos.permission.ACCESS_SERVICE_DM|@ohos.distributedHardware.deviceManager.d.ts|
|Permission changed|Class name: DeviceManager;<br>Method or attribute name: off(type: 'uiStateChange', callback?: Callback\<{ param: string }>): void;<br>Old version information: |Class name: DeviceManager;<br>Method or attribute name: off(type: 'uiStateChange', callback?: Callback\<{ param: string }>): void;<br>New version information: ohos.permission.ACCESS_SERVICE_DM|@ohos.distributedHardware.deviceManager.d.ts|
|Permission changed|Class name: DeviceManager;<br>Method or attribute name: off(type: 'deviceStateChange', callback?: Callback\<{ action: DeviceStateChangeAction, device: DeviceInfo }>): void;<br>Old version information: |Class name: DeviceManager;<br>Method or attribute name: off(type: 'deviceStateChange', callback?: Callback\<{ action: DeviceStateChangeAction, device: DeviceInfo }>): void;<br>New version information: ohos.permission.ACCESS_SERVICE_DM|@ohos.distributedHardware.deviceManager.d.ts|
|Permission changed|Class name: DeviceManager;<br>Method or attribute name: off(type: 'deviceFound', callback?: Callback\<{ subscribeId: number, device: DeviceInfo }>): void;<br>Old version information: |Class name: DeviceManager;<br>Method or attribute name: off(type: 'deviceFound', callback?: Callback\<{ subscribeId: number, device: DeviceInfo }>): void;<br>New version information: ohos.permission.ACCESS_SERVICE_DM|@ohos.distributedHardware.deviceManager.d.ts|
|Permission changed|Class name: DeviceManager;<br>Method or attribute name: off(type: 'discoverFail', callback?: Callback\<{ subscribeId: number, reason: number }>): void;<br>Old version information: |Class name: DeviceManager;<br>Method or attribute name: off(type: 'discoverFail', callback?: Callback\<{ subscribeId: number, reason: number }>): void;<br>New version information: ohos.permission.ACCESS_SERVICE_DM|@ohos.distributedHardware.deviceManager.d.ts|
|Permission changed|Class name: DeviceManager;<br>Method or attribute name: off(type: 'publishSuccess', callback?: Callback\<{ publishId: number }>): void;<br>Old version information: |Class name: DeviceManager;<br>Method or attribute name: off(type: 'publishSuccess', callback?: Callback\<{ publishId: number }>): void;<br>New version information: ohos.permission.ACCESS_SERVICE_DM|@ohos.distributedHardware.deviceManager.d.ts|
|Permission changed|Class name: DeviceManager;<br>Method or attribute name: off(type: 'publishFail', callback?: Callback\<{ publishId: number, reason: number }>): void;<br>Old version information: |Class name: DeviceManager;<br>Method or attribute name: off(type: 'publishFail', callback?: Callback\<{ publishId: number, reason: number }>): void;<br>New version information: ohos.permission.ACCESS_SERVICE_DM|@ohos.distributedHardware.deviceManager.d.ts|
|Permission changed|Class name: DeviceManager;<br>Method or attribute name: off(type: 'serviceDie', callback?: () => void): void;<br>Old version information: |Class name: DeviceManager;<br>Method or attribute name: off(type: 'serviceDie', callback?: () => void): void;<br>New version information: ohos.permission.ACCESS_SERVICE_DM|@ohos.distributedHardware.deviceManager.d.ts|
| Change Type | Old Version | New Version | d.ts File |
| ---- | ------ | ------ | -------- |
|Added|NA|Class name: agent;<br>Method or attribute name: function create(context: BaseContext, config: Config, callback: AsyncCallback\<Task>): void;|@ohos.request.d.ts|
|Added|NA|Class name: agent;<br>Method or attribute name: function create(context: BaseContext, config: Config): Promise\<Task>;|@ohos.request.d.ts|
|Added|NA|Class name: agent;<br>Method or attribute name: function remove(id: string, callback: AsyncCallback\<void>): void;|@ohos.request.d.ts|
|Added|NA|Class name: agent;<br>Method or attribute name: function remove(id: string): Promise\<void>;|@ohos.request.d.ts|
|Added|NA|Class name: agent;<br>Method or attribute name: function show(id: string, callback: AsyncCallback\<TaskInfo>): void;|@ohos.request.d.ts|
|Added|NA|Class name: agent;<br>Method or attribute name: function show(id: string): Promise\<TaskInfo>;|@ohos.request.d.ts|
|Added|NA|Class name: agent;<br>Method or attribute name: function touch(id: string, token: string, callback: AsyncCallback\<TaskInfo>): void;|@ohos.request.d.ts|
|Added|NA|Class name: agent;<br>Method or attribute name: function touch(id: string, token: string): Promise\<TaskInfo>;|@ohos.request.d.ts|
|Added|NA|Class name: agent;<br>Method or attribute name: function search(filter: Filter, callback: AsyncCallback\<Array\<string>>): void;|@ohos.request.d.ts|
|Added|NA|Class name: agent;<br>Method or attribute name: function search(filter: Filter): Promise\<Array\<string>>;|@ohos.request.d.ts|
|Added|NA|Class name: agent;<br>Method or attribute name: function query(id: string, callback: AsyncCallback\<TaskInfo>): void;|@ohos.request.d.ts|
|Added|NA|Class name: agent;<br>Method or attribute name: function query(id: string): Promise\<TaskInfo>;|@ohos.request.d.ts|
|Added|NA|Class name: Action;<br>Method or attribute name: DOWNLOAD|@ohos.request.d.ts|
|Added|NA|Class name: Action;<br>Method or attribute name: UPLOAD|@ohos.request.d.ts|
|Added|NA|Class name: Mode;<br>Method or attribute name: BACKGROUND|@ohos.request.d.ts|
|Added|NA|Class name: Mode;<br>Method or attribute name: FOREGROUND|@ohos.request.d.ts|
|Added|NA|Class name: Network;<br>Method or attribute name: ANY|@ohos.request.d.ts|
|Added|NA|Class name: Network;<br>Method or attribute name: WIFI|@ohos.request.d.ts|
|Added|NA|Class name: Network;<br>Method or attribute name: CELLULAR|@ohos.request.d.ts|
|Added|NA|Class name: FileSpec;<br>Method or attribute name: path: string;|@ohos.request.d.ts|
|Added|NA|Class name: FileSpec;<br>Method or attribute name: mimeType?: string;|@ohos.request.d.ts|
|Added|NA|Class name: FileSpec;<br>Method or attribute name: filename?: string;|@ohos.request.d.ts|
|Added|NA|Class name: FileSpec;<br>Method or attribute name: extras?: object;|@ohos.request.d.ts|
|Added|NA|Class name: Config;<br>Method or attribute name: extras?: object;|@ohos.request.d.ts|
|Added|NA|Class name: FormItem;<br>Method or attribute name: name: string;|@ohos.request.d.ts|
|Added|NA|Class name: FormItem;<br>Method or attribute name: value: string \| FileSpec \| Array\<FileSpec>;|@ohos.request.d.ts|
|Added|NA|Class name: Config;<br>Method or attribute name: action: Action;|@ohos.request.d.ts|
|Added|NA|Class name: Config;<br>Method or attribute name: url: string;|@ohos.request.d.ts|
|Added|NA|Class name: Config;<br>Method or attribute name: title?: string;|@ohos.request.d.ts|
|Added|NA|Class name: Config;<br>Method or attribute name: description?: string;|@ohos.request.d.ts|
|Added|NA|Class name: Config;<br>Method or attribute name: mode?: Mode;|@ohos.request.d.ts|
|Added|NA|Class name: Filter;<br>Method or attribute name: mode?: Mode;|@ohos.request.d.ts|
|Added|NA|Class name: Config;<br>Method or attribute name: overwrite?: boolean;|@ohos.request.d.ts|
|Added|NA|Class name: Config;<br>Method or attribute name: method?: string;|@ohos.request.d.ts|
|Added|NA|Class name: Config;<br>Method or attribute name: headers?: object;|@ohos.request.d.ts|
|Added|NA|Class name: Config;<br>Method or attribute name: data?: string \| Array\<FormItem>;|@ohos.request.d.ts|
|Added|NA|Class name: Config;<br>Method or attribute name: saveas?: string;|@ohos.request.d.ts|
|Added|NA|Class name: Config;<br>Method or attribute name: network?: Network;|@ohos.request.d.ts|
|Added|NA|Class name: Config;<br>Method or attribute name: metered?: boolean;|@ohos.request.d.ts|
|Added|NA|Class name: Config;<br>Method or attribute name: roaming?: boolean;|@ohos.request.d.ts|
|Added|NA|Class name: Config;<br>Method or attribute name: retry?: boolean;|@ohos.request.d.ts|
|Added|NA|Class name: Config;<br>Method or attribute name: redirect?: boolean;|@ohos.request.d.ts|
|Added|NA|Class name: Config;<br>Method or attribute name: index?: number;|@ohos.request.d.ts|
|Added|NA|Class name: Config;<br>Method or attribute name: begins?: number;|@ohos.request.d.ts|
|Added|NA|Class name: Config;<br>Method or attribute name: ends?: number;|@ohos.request.d.ts|
|Added|NA|Class name: Config;<br>Method or attribute name: gauge?: boolean;|@ohos.request.d.ts|
|Added|NA|Class name: Config;<br>Method or attribute name: precise?: boolean;|@ohos.request.d.ts|
|Added|NA|Class name: Config;<br>Method or attribute name: token?: string;|@ohos.request.d.ts|
|Added|NA|Class name: State;<br>Method or attribute name: INITIALIZED = 0x00|@ohos.request.d.ts|
|Added|NA|Class name: State;<br>Method or attribute name: WAITING = 0x10|@ohos.request.d.ts|
|Added|NA|Class name: State;<br>Method or attribute name: RUNNING = 0x20|@ohos.request.d.ts|
|Added|NA|Class name: State;<br>Method or attribute name: RETRYING = 0x21|@ohos.request.d.ts|
|Added|NA|Class name: State;<br>Method or attribute name: PAUSED = 0x30|@ohos.request.d.ts|
|Added|NA|Class name: State;<br>Method or attribute name: STOPPED = 0x31|@ohos.request.d.ts|
|Added|NA|Class name: State;<br>Method or attribute name: COMPLETED = 0x40|@ohos.request.d.ts|
|Added|NA|Class name: State;<br>Method or attribute name: FAILED = 0x41|@ohos.request.d.ts|
|Added|NA|Class name: State;<br>Method or attribute name: REMOVED = 0x50|@ohos.request.d.ts|
|Added|NA|Class name: Progress;<br>Method or attribute name: readonly state: State;|@ohos.request.d.ts|
|Added|NA|Class name: Progress;<br>Method or attribute name: readonly index: number;|@ohos.request.d.ts|
|Added|NA|Class name: Progress;<br>Method or attribute name: readonly processed: number;|@ohos.request.d.ts|
|Added|NA|Class name: Progress;<br>Method or attribute name: readonly sizes: Array\<number>;|@ohos.request.d.ts|
|Added|NA|Class name: Progress;<br>Method or attribute name: readonly extras?: object;|@ohos.request.d.ts|
|Added|NA|Class name: TaskInfo;<br>Method or attribute name: readonly extras?: object;|@ohos.request.d.ts|
|Added|NA|Class name: Faults;<br>Method or attribute name: OTHERS = 0xFF|@ohos.request.d.ts|
|Added|NA|Class name: Faults;<br>Method or attribute name: DISCONNECTED = 0x00|@ohos.request.d.ts|
|Added|NA|Class name: Faults;<br>Method or attribute name: TIMEOUT = 0x10|@ohos.request.d.ts|
|Added|NA|Class name: Faults;<br>Method or attribute name: PROTOCOL = 0x20|@ohos.request.d.ts|
|Added|NA|Class name: Faults;<br>Method or attribute name: FSIO = 0x40|@ohos.request.d.ts|
|Added|NA|Class name: Filter;<br>Method or attribute name: bundle?: string;|@ohos.request.d.ts|
|Added|NA|Class name: Filter;<br>Method or attribute name: before?: number;|@ohos.request.d.ts|
|Added|NA|Class name: Filter;<br>Method or attribute name: after?: number;|@ohos.request.d.ts|
|Added|NA|Class name: Filter;<br>Method or attribute name: state?: State;|@ohos.request.d.ts|
|Added|NA|Class name: Filter;<br>Method or attribute name: action?: Action;|@ohos.request.d.ts|
|Added|NA|Class name: TaskInfo;<br>Method or attribute name: readonly uid?: string;|@ohos.request.d.ts|
|Added|NA|Class name: TaskInfo;<br>Method or attribute name: readonly bundle?: string;|@ohos.request.d.ts|
|Added|NA|Class name: TaskInfo;<br>Method or attribute name: readonly saveas?: string;|@ohos.request.d.ts|
|Added|NA|Class name: TaskInfo;<br>Method or attribute name: readonly url?: string;|@ohos.request.d.ts|
|Added|NA|Class name: TaskInfo;<br>Method or attribute name: readonly data?: string \| Array\<FormItem>;|@ohos.request.d.ts|
|Added|NA|Class name: TaskInfo;<br>Method or attribute name: readonly tid: string;|@ohos.request.d.ts|
|Added|NA|Class name: Task;<br>Method or attribute name: readonly tid: string;|@ohos.request.d.ts|
|Added|NA|Class name: TaskInfo;<br>Method or attribute name: readonly title: string;|@ohos.request.d.ts|
|Added|NA|Class name: TaskInfo;<br>Method or attribute name: readonly description: string;|@ohos.request.d.ts|
|Added|NA|Class name: TaskInfo;<br>Method or attribute name: readonly action: Action;|@ohos.request.d.ts|
|Added|NA|Class name: TaskInfo;<br>Method or attribute name: readonly mode: Mode;|@ohos.request.d.ts|
|Added|NA|Class name: TaskInfo;<br>Method or attribute name: readonly mimeType: string;|@ohos.request.d.ts|
|Added|NA|Class name: TaskInfo;<br>Method or attribute name: readonly progress: Progress;|@ohos.request.d.ts|
|Added|NA|Class name: TaskInfo;<br>Method or attribute name: readonly gauge: boolean;|@ohos.request.d.ts|
|Added|NA|Class name: TaskInfo;<br>Method or attribute name: readonly ctime: number;|@ohos.request.d.ts|
|Added|NA|Class name: TaskInfo;<br>Method or attribute name: readonly mtime: number;|@ohos.request.d.ts|
|Added|NA|Class name: TaskInfo;<br>Method or attribute name: readonly retry: boolean;|@ohos.request.d.ts|
|Added|NA|Class name: TaskInfo;<br>Method or attribute name: readonly tries: number;|@ohos.request.d.ts|
|Added|NA|Class name: TaskInfo;<br>Method or attribute name: readonly faults: Faults;|@ohos.request.d.ts|
|Added|NA|Class name: TaskInfo;<br>Method or attribute name: readonly reason: string;|@ohos.request.d.ts|
|Added|NA|Class name: Task;<br>Method or attribute name: config: Config;|@ohos.request.d.ts|
|Added|NA|Class name: Task;<br>Method or attribute name: on(event: 'progress', callback: (progress: Progress) => void): void;|@ohos.request.d.ts|
|Added|NA|Class name: Task;<br>Method or attribute name: on(event: 'completed', callback: (progress: Progress) => void): void;|@ohos.request.d.ts|
|Added|NA|Class name: Task;<br>Method or attribute name: on(event: 'failed', callback: (progress: Progress) => void): void;|@ohos.request.d.ts|
|Added|NA|Class name: Task;<br>Method or attribute name: off(event: 'progress', callback?: (progress: Progress) => void): void;|@ohos.request.d.ts|
|Added|NA|Class name: Task;<br>Method or attribute name: off(event: 'completed', callback?: (progress: Progress) => void): void;|@ohos.request.d.ts|
|Added|NA|Class name: Task;<br>Method or attribute name: off(event: 'failed', callback?: (progress: Progress) => void): void;|@ohos.request.d.ts|
|Added|NA|Class name: Task;<br>Method or attribute name: start(callback: AsyncCallback\<void>): void;|@ohos.request.d.ts|
|Added|NA|Class name: Task;<br>Method or attribute name: start(): Promise\<void>;|@ohos.request.d.ts|
|Added|NA|Class name: Task;<br>Method or attribute name: pause(callback: AsyncCallback\<void>): void;|@ohos.request.d.ts|
|Added|NA|Class name: Task;<br>Method or attribute name: pause(): Promise\<void>;|@ohos.request.d.ts|
|Added|NA|Class name: Task;<br>Method or attribute name: resume(callback: AsyncCallback\<void>): void;|@ohos.request.d.ts|
|Added|NA|Class name: Task;<br>Method or attribute name: resume(): Promise\<void>;|@ohos.request.d.ts|
|Added|NA|Class name: Task;<br>Method or attribute name: stop(callback: AsyncCallback\<void>): void;|@ohos.request.d.ts|
|Added|NA|Class name: Task;<br>Method or attribute name: stop(): Promise\<void>;|@ohos.request.d.ts|
|Permission changed|Class name: request;<br>Method or attribute name: declare request<br>Old version information: ohos.permission.INTERNET|Class name: request;<br>Method or attribute name: declare request<br>New version information: |@ohos.request.d.ts|
| Change Type | Old Version | New Version | d.ts File |
| ---- | ------ | ------ | -------- |
|Added|NA|Class name: DriverExtensionAbility;<br>Method or attribute name: context: DriverExtensionContext;|@ohos.app.ability.DriverExtensionAbility.d.ts|
|Added|NA|Class name: DriverExtensionAbility;<br>Method or attribute name: onInit(want: Want): void;|@ohos.app.ability.DriverExtensionAbility.d.ts|
|Added|NA|Class name: DriverExtensionAbility;<br>Method or attribute name: onRelease(): void;|@ohos.app.ability.DriverExtensionAbility.d.ts|
|Added|NA|Class name: DriverExtensionAbility;<br>Method or attribute name: onConnect(want: Want): rpc.RemoteObject \| Promise\<rpc.RemoteObject>;|@ohos.app.ability.DriverExtensionAbility.d.ts|
|Added|NA|Class name: DriverExtensionAbility;<br>Method or attribute name: onDisconnect(want: Want): void \| Promise\<void>;|@ohos.app.ability.DriverExtensionAbility.d.ts|
|Added|NA|Class name: DriverExtensionAbility;<br>Method or attribute name: onDump(params: Array\<string>): Array\<string>;|@ohos.app.ability.DriverExtensionAbility.d.ts|
|Added|NA|Class name: deviceManager;<br>Method or attribute name: function queryDevices(busType?: number): Array\<Readonly\<Device>>;|@ohos.driver.deviceManager.d.ts|
|Added|NA|Class name: deviceManager;<br>Method or attribute name: function bindDevice(deviceId: number, onDisconnect: AsyncCallback\<number>,<br><br> callback: AsyncCallback\<{deviceId: number, remote: rpc.IRemoteObject}>): void;|@ohos.driver.deviceManager.d.ts|
|Added|NA|Class name: deviceManager;<br>Method or attribute name: function bindDevice(deviceId: number, onDisconnect: AsyncCallback\<number>): Promise\<{deviceId: number,<br><br> remote: rpc.IRemoteObject}>;|@ohos.driver.deviceManager.d.ts|
|Added|NA|Class name: deviceManager;<br>Method or attribute name: function unbindDevice(deviceId: number, callback: AsyncCallback\<number>): void;|@ohos.driver.deviceManager.d.ts|
|Added|NA|Class name: deviceManager;<br>Method or attribute name: function unbindDevice(deviceId: number): Promise\<number>;|@ohos.driver.deviceManager.d.ts|
|Added|NA|Class name: BusType;<br>Method or attribute name: USB = 1|@ohos.driver.deviceManager.d.ts|
|Added|NA|Class name: Device;<br>Method or attribute name: busType: BusType;|@ohos.driver.deviceManager.d.ts|
|Added|NA|Class name: Device;<br>Method or attribute name: deviceId: number;|@ohos.driver.deviceManager.d.ts|
|Added|NA|Class name: Device;<br>Method or attribute name: description: string;|@ohos.driver.deviceManager.d.ts|
|Added|NA|Class name: USBDevice;<br>Method or attribute name: vendorId: number;|@ohos.driver.deviceManager.d.ts|
|Added|NA|Class name: USBDevice;<br>Method or attribute name: productId: number;|@ohos.driver.deviceManager.d.ts|
|Added|NA|Class name: DriverExtensionContext;<br>Method or attribute name: updateDriverState(): void;|DriverExtensionContext.d.ts|
| Change Type | Old Version | New Version | d.ts File |
| ---- | ------ | ------ | -------- |
|Added|NA|Class name: SyncState;<br>Method or attribute name: UPLOADING|@ohos.file.cloudSync.d.ts|
|Added|NA|Class name: SyncState;<br>Method or attribute name: UPLOAD_FAILED|@ohos.file.cloudSync.d.ts|
|Added|NA|Class name: SyncState;<br>Method or attribute name: DOWNLOADING|@ohos.file.cloudSync.d.ts|
|Added|NA|Class name: SyncState;<br>Method or attribute name: DOWNLOAD_FAILED|@ohos.file.cloudSync.d.ts|
|Added|NA|Class name: SyncState;<br>Method or attribute name: COMPLETED|@ohos.file.cloudSync.d.ts|
|Added|NA|Class name: State;<br>Method or attribute name: COMPLETED|@ohos.file.cloudSync.d.ts|
|Added|NA|Class name: SyncState;<br>Method or attribute name: STOPPED|@ohos.file.cloudSync.d.ts|
|Added|NA|Class name: State;<br>Method or attribute name: STOPPED|@ohos.file.cloudSync.d.ts|
|Added|NA|Class name: ErrorType;<br>Method or attribute name: NO_ERROR|@ohos.file.cloudSync.d.ts|
|Added|NA|Class name: ErrorType;<br>Method or attribute name: NETWORK_UNAVAILABLE|@ohos.file.cloudSync.d.ts|
|Added|NA|Class name: ErrorType;<br>Method or attribute name: WIFI_UNAVAILABLE|@ohos.file.cloudSync.d.ts|
|Added|NA|Class name: ErrorType;<br>Method or attribute name: BATTERY_LEVEL_LOW|@ohos.file.cloudSync.d.ts|
|Added|NA|Class name: ErrorType;<br>Method or attribute name: BATTERY_LEVEL_WARNING|@ohos.file.cloudSync.d.ts|
|Added|NA|Class name: ErrorType;<br>Method or attribute name: CLOUD_STORAGE_FULL|@ohos.file.cloudSync.d.ts|
|Added|NA|Class name: ErrorType;<br>Method or attribute name: LOCAL_STORAGE_FULL|@ohos.file.cloudSync.d.ts|
|Added|NA|Class name: SyncProgress;<br>Method or attribute name: state: SyncState;|@ohos.file.cloudSync.d.ts|
|Added|NA|Class name: SyncProgress;<br>Method or attribute name: error: ErrorType;|@ohos.file.cloudSync.d.ts|
|Added|NA|Class name: GallerySync;<br>Method or attribute name: constructor();|@ohos.file.cloudSync.d.ts|
|Added|NA|Class name: Download;<br>Method or attribute name: constructor();|@ohos.file.cloudSync.d.ts|
|Added|NA|Class name: GallerySync;<br>Method or attribute name: on(evt: 'progress', callback: (pg: SyncProgress) => void): void;|@ohos.file.cloudSync.d.ts|
|Added|NA|Class name: GallerySync;<br>Method or attribute name: off(evt: 'progress'): void;|@ohos.file.cloudSync.d.ts|
|Added|NA|Class name: Download;<br>Method or attribute name: off(evt: 'progress'): void;|@ohos.file.cloudSync.d.ts|
|Added|NA|Class name: GallerySync;<br>Method or attribute name: start(): Promise\<void>;|@ohos.file.cloudSync.d.ts|
|Added|NA|Class name: GallerySync;<br>Method or attribute name: start(callback: AsyncCallback\<void>): void;|@ohos.file.cloudSync.d.ts|
|Added|NA|Class name: GallerySync;<br>Method or attribute name: stop(): Promise\<void>;|@ohos.file.cloudSync.d.ts|
|Added|NA|Class name: GallerySync;<br>Method or attribute name: stop(callback: AsyncCallback\<void>): void;|@ohos.file.cloudSync.d.ts|
|Added|NA|Class name: State;<br>Method or attribute name: RUNNING|@ohos.file.cloudSync.d.ts|
|Added|NA|Class name: State;<br>Method or attribute name: FAILED|@ohos.file.cloudSync.d.ts|
|Added|NA|Class name: DownloadProgress;<br>Method or attribute name: state: State;|@ohos.file.cloudSync.d.ts|
|Added|NA|Class name: DownloadProgress;<br>Method or attribute name: processed: number;|@ohos.file.cloudSync.d.ts|
|Added|NA|Class name: DownloadProgress;<br>Method or attribute name: size: number;|@ohos.file.cloudSync.d.ts|
|Added|NA|Class name: DownloadProgress;<br>Method or attribute name: uri: string;|@ohos.file.cloudSync.d.ts|
|Added|NA|Class name: Download;<br>Method or attribute name: on(evt: 'progress', callback: (pg: DownloadProgress) => void): void;|@ohos.file.cloudSync.d.ts|
|Added|NA|Class name: Download;<br>Method or attribute name: start(uri: string): Promise\<void>;|@ohos.file.cloudSync.d.ts|
|Added|NA|Class name: Download;<br>Method or attribute name: start(uri: string, callback: AsyncCallback\<void>): void;|@ohos.file.cloudSync.d.ts|
|Added|NA|Class name: Download;<br>Method or attribute name: stop(uri: string): Promise\<void>;|@ohos.file.cloudSync.d.ts|
|Added|NA|Class name: Download;<br>Method or attribute name: stop(uri: string, callback: AsyncCallback\<void>): void;|@ohos.file.cloudSync.d.ts|
|Added|NA|Class name: cloudSyncManager;<br>Method or attribute name: function enableCloud(accountId: string, switches: { [bundleName: string]: boolean }): Promise\<void>;|@ohos.file.cloudSyncManager.d.ts|
|Added|NA|Class name: cloudSyncManager;<br>Method or attribute name: function enableCloud(<br> accountId: string,<br> switches: { [bundleName: string]: boolean },<br> callback: AsyncCallback\<void><br> ): void;|@ohos.file.cloudSyncManager.d.ts|
|Added|NA|Class name: cloudSyncManager;<br>Method or attribute name: function disableCloud(accountId: string): Promise\<void>;|@ohos.file.cloudSyncManager.d.ts|
|Added|NA|Class name: cloudSyncManager;<br>Method or attribute name: function disableCloud(accountId: string, callback: AsyncCallback\<void>): void;|@ohos.file.cloudSyncManager.d.ts|
|Added|NA|Class name: cloudSyncManager;<br>Method or attribute name: function clean(accountId: string, appActions: { [bundleName: string]: Action }): Promise\<void>;|@ohos.file.cloudSyncManager.d.ts|
|Added|NA|Class name: cloudSyncManager;<br>Method or attribute name: function clean(accountId: string, appActions: { [bundleName: string]: Action }, callback: AsyncCallback\<void>): void;|@ohos.file.cloudSyncManager.d.ts|
|Added|NA|Class name: Action;<br>Method or attribute name: RETAIN_DATA|@ohos.file.cloudSyncManager.d.ts|
|Added|NA|Class name: Action;<br>Method or attribute name: CLEAR_DATA|@ohos.file.cloudSyncManager.d.ts|
|Added|NA|Class name: sourcefile;<br>Method or attribute name: declare function createRandomAccessFile(file: string \| File, mode?: number): Promise\<RandomAccessFile>;|@ohos.file.fs.d.ts|
|Added|NA|Class name: sourcefile;<br>Method or attribute name: declare function createRandomAccessFile(file: string \| File, callback: AsyncCallback\<RandomAccessFile>): void;|@ohos.file.fs.d.ts|
|Added|NA|Class name: sourcefile;<br>Method or attribute name: declare function createRandomAccessFile(file: string \| File, mode: number, callback: AsyncCallback\<RandomAccessFile>): void;|@ohos.file.fs.d.ts|
|Added|NA|Class name: sourcefile;<br>Method or attribute name: declare function createRandomAccessFileSync(file: string \| File, mode?: number): RandomAccessFile;|@ohos.file.fs.d.ts|
|Added|NA|Class name: RandomAccessFile;<br>Method or attribute name: readonly fd: number;|@ohos.file.fs.d.ts|
|Added|NA|Class name: RandomAccessFile;<br>Method or attribute name: readonly filePointer: number;|@ohos.file.fs.d.ts|
|Added|NA|Class name: RandomAccessFile;<br>Method or attribute name: setFilePointer(filePointer: number): void;|@ohos.file.fs.d.ts|
|Added|NA|Class name: RandomAccessFile;<br>Method or attribute name: close(): void;|@ohos.file.fs.d.ts|
|Added|NA|Class name: RandomAccessFile;<br>Method or attribute name: write(<br> buffer: ArrayBuffer \| string,<br> options?: {<br> offset?: number;<br> length?: number;<br> encoding?: string;<br> }<br> ): Promise\<number>;|@ohos.file.fs.d.ts|
|Added|NA|Class name: RandomAccessFile;<br>Method or attribute name: write(buffer: ArrayBuffer \| string, callback: AsyncCallback\<number>): void;|@ohos.file.fs.d.ts|
|Added|NA|Class name: RandomAccessFile;<br>Method or attribute name: write(<br> buffer: ArrayBuffer \| string,<br> options: {<br> offset?: number;<br> length?: number;<br> encoding?: string;<br> },<br> callback: AsyncCallback\<number><br> ): void;|@ohos.file.fs.d.ts|
|Added|NA|Class name: RandomAccessFile;<br>Method or attribute name: writeSync(<br> buffer: ArrayBuffer \| string,<br> options?: {<br> offset?: number;<br> length?: number;<br> encoding?: string;<br> }<br> ): number;|@ohos.file.fs.d.ts|
|Added|NA|Class name: RandomAccessFile;<br>Method or attribute name: read(<br> buffer: ArrayBuffer,<br> options?: {<br> offset?: number;<br> length?: number;<br> }<br> ): Promise\<number>;|@ohos.file.fs.d.ts|
|Added|NA|Class name: RandomAccessFile;<br>Method or attribute name: read(buffer: ArrayBuffer, callback: AsyncCallback\<number>): void;|@ohos.file.fs.d.ts|
|Added|NA|Class name: RandomAccessFile;<br>Method or attribute name: read(<br> buffer: ArrayBuffer,<br> options: {<br> offset?: number;<br> length?: number;<br> },<br> callback: AsyncCallback\<number><br> ): void;|@ohos.file.fs.d.ts|
|Added|NA|Class name: RandomAccessFile;<br>Method or attribute name: readSync(<br> buffer: ArrayBuffer,<br> options?: {<br> offset?: number;<br> length?: number;<br> }<br> ): number;|@ohos.file.fs.d.ts|
|Added|NA|Class name: photoAccessHelper;<br>Method or attribute name: function getPhotoAccessHelper(context: Context): PhotoAccessHelper;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: photoAccessHelper;<br>Method or attribute name: type MemberType = number \| string \| boolean;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoType;<br>Method or attribute name: IMAGE = 1|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoType;<br>Method or attribute name: VIDEO|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: AlbumSubtype;<br>Method or attribute name: VIDEO|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoSubtype;<br>Method or attribute name: DEFAULT|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoSubtype;<br>Method or attribute name: SCREENSHOT|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: AlbumSubtype;<br>Method or attribute name: SCREENSHOT|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PositionType;<br>Method or attribute name: LOCAL = 1 \<\< 0|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PositionType;<br>Method or attribute name: CLOUD = 1 \<\< 1|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoAsset;<br>Method or attribute name: readonly uri: string;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoAsset;<br>Method or attribute name: readonly photoType: PhotoType;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoAsset;<br>Method or attribute name: readonly displayName: string;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoAsset;<br>Method or attribute name: get(member: string): MemberType;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoAsset;<br>Method or attribute name: set(member: string, value: string): void;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoAsset;<br>Method or attribute name: commitModify(callback: AsyncCallback\<void>): void;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: Album;<br>Method or attribute name: commitModify(callback: AsyncCallback\<void>): void;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoAsset;<br>Method or attribute name: commitModify(): Promise\<void>;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: Album;<br>Method or attribute name: commitModify(): Promise\<void>;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoAsset;<br>Method or attribute name: open(mode: string, callback: AsyncCallback\<number>): void;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoAsset;<br>Method or attribute name: open(mode: string): Promise\<number>;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoAsset;<br>Method or attribute name: getReadOnlyFd(callback: AsyncCallback\<number>): void;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoAsset;<br>Method or attribute name: getReadOnlyFd(): Promise\<number>;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoAsset;<br>Method or attribute name: close(fd: number, callback: AsyncCallback\<void>): void;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoAsset;<br>Method or attribute name: close(fd: number): Promise\<void>;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoAsset;<br>Method or attribute name: getThumbnail(callback: AsyncCallback\<image.PixelMap>): void;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoAsset;<br>Method or attribute name: getThumbnail(size: image.Size, callback: AsyncCallback\<image.PixelMap>): void;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoAsset;<br>Method or attribute name: getThumbnail(size?: image.Size): Promise\<image.PixelMap>;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoAsset;<br>Method or attribute name: setFavorite(favoriteState: boolean, callback: AsyncCallback\<void>): void;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoAsset;<br>Method or attribute name: setFavorite(favoriteState: boolean): Promise\<void>;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoAsset;<br>Method or attribute name: setHidden(hiddenState: boolean, callback: AsyncCallback\<void>): void;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoAsset;<br>Method or attribute name: setHidden(hiddenState: boolean): Promise\<void>;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoKeys;<br>Method or attribute name: URI = 'uri'|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: AlbumKeys;<br>Method or attribute name: URI = 'uri'|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoKeys;<br>Method or attribute name: PHOTO_TYPE = 'media_type'|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoKeys;<br>Method or attribute name: DISPLAY_NAME = 'display_name'|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoKeys;<br>Method or attribute name: SIZE = 'size'|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoKeys;<br>Method or attribute name: DATE_ADDED = 'date_added'|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoKeys;<br>Method or attribute name: DATE_MODIFIED = 'date_modified'|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoKeys;<br>Method or attribute name: DURATION = 'duration'|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoKeys;<br>Method or attribute name: WIDTH = 'width'|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoKeys;<br>Method or attribute name: HEIGHT = 'height'|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoKeys;<br>Method or attribute name: DATE_TAKEN = 'date_taken'|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoKeys;<br>Method or attribute name: ORIENTATION = 'orientation'|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoKeys;<br>Method or attribute name: FAVORITE = 'is_favorite'|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoKeys;<br>Method or attribute name: TITLE = 'title'|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoKeys;<br>Method or attribute name: POSITION = 'position'|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoKeys;<br>Method or attribute name: DATE_TRASHED = 'date_trashed'|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoKeys;<br>Method or attribute name: HIDDEN = 'hidden'|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: AlbumKeys;<br>Method or attribute name: ALBUM_NAME = 'album_name'|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: FetchOptions;<br>Method or attribute name: fetchColumns: Array\<string>;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: FetchOptions;<br>Method or attribute name: predicates: dataSharePredicates.DataSharePredicates;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoCreateOptions;<br>Method or attribute name: subtype?: PhotoSubtype;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: CreateOptions;<br>Method or attribute name: title?: string;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: FetchResult;<br>Method or attribute name: getCount(): number;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: FetchResult;<br>Method or attribute name: isAfterLast(): boolean;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: FetchResult;<br>Method or attribute name: getFirstObject(callback: AsyncCallback\<T>): void;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: FetchResult;<br>Method or attribute name: getFirstObject(): Promise\<T>;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: FetchResult;<br>Method or attribute name: getNextObject(callback: AsyncCallback\<T>): void;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: FetchResult;<br>Method or attribute name: getNextObject(): Promise\<T>;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: FetchResult;<br>Method or attribute name: getLastObject(callback: AsyncCallback\<T>): void;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: FetchResult;<br>Method or attribute name: getLastObject(): Promise\<T>;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: FetchResult;<br>Method or attribute name: getObjectByPosition(index: number, callback: AsyncCallback\<T>): void;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: FetchResult;<br>Method or attribute name: getObjectByPosition(index: number): Promise\<T>;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: FetchResult;<br>Method or attribute name: getAllObjects(callback: AsyncCallback\<Array\<T>>): void;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: FetchResult;<br>Method or attribute name: getAllObjects(): Promise\<Array\<T>>;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: FetchResult;<br>Method or attribute name: close(): void;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: AlbumType;<br>Method or attribute name: USER = 0|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: AlbumType;<br>Method or attribute name: SYSTEM = 1024|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: AlbumSubtype;<br>Method or attribute name: USER_GENERIC = 1|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: AlbumSubtype;<br>Method or attribute name: FAVORITE = 1025|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: AlbumSubtype;<br>Method or attribute name: HIDDEN|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: AlbumSubtype;<br>Method or attribute name: TRASH|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: AlbumSubtype;<br>Method or attribute name: CAMERA|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: AlbumSubtype;<br>Method or attribute name: ANY = 2147483647|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: AbsAlbum;<br>Method or attribute name: readonly albumType: AlbumType;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: AbsAlbum;<br>Method or attribute name: readonly albumSubtype: AlbumSubtype;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: AbsAlbum;<br>Method or attribute name: albumName: string;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: AbsAlbum;<br>Method or attribute name: readonly albumUri: string;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: AbsAlbum;<br>Method or attribute name: readonly count: number;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: AbsAlbum;<br>Method or attribute name: readonly coverUri: string;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: AbsAlbum;<br>Method or attribute name: getAssets(options: FetchOptions, callback: AsyncCallback\<FetchResult\<PhotoAsset>>): void;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoAccessHelper;<br>Method or attribute name: getAssets(options: FetchOptions, callback: AsyncCallback\<FetchResult\<PhotoAsset>>): void;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: AbsAlbum;<br>Method or attribute name: getAssets(options: FetchOptions): Promise\<FetchResult\<PhotoAsset>>;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoAccessHelper;<br>Method or attribute name: getAssets(options: FetchOptions): Promise\<FetchResult\<PhotoAsset>>;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: Album;<br>Method or attribute name: addAssets(assets: Array\<PhotoAsset>, callback: AsyncCallback\<void>): void;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: Album;<br>Method or attribute name: addAssets(assets: Array\<PhotoAsset>): Promise\<void>;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: Album;<br>Method or attribute name: removeAssets(assets: Array\<PhotoAsset>, callback: AsyncCallback\<void>): void;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: Album;<br>Method or attribute name: removeAssets(assets: Array\<PhotoAsset>): Promise\<void>;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: Album;<br>Method or attribute name: recoverAssets(assets: Array\<PhotoAsset>, callback: AsyncCallback\<void>): void;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: Album;<br>Method or attribute name: recoverAssets(assets: Array\<PhotoAsset>): Promise\<void>;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: Album;<br>Method or attribute name: deleteAssets(assets: Array\<PhotoAsset>, callback: AsyncCallback\<void>): void;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: Album;<br>Method or attribute name: deleteAssets(assets: Array\<PhotoAsset>): Promise\<void>;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: Album;<br>Method or attribute name: setCoverUri(uri: string, callback: AsyncCallback\<void>): void;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: Album;<br>Method or attribute name: setCoverUri(uri: string): Promise\<void>;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoAccessHelper;<br>Method or attribute name: createAsset(displayName: string, callback: AsyncCallback\<PhotoAsset>): void;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoAccessHelper;<br>Method or attribute name: createAsset(displayName: string): Promise\<PhotoAsset>;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoAccessHelper;<br>Method or attribute name: createAsset(displayName: string, options: PhotoCreateOptions): Promise\<PhotoAsset>;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoAccessHelper;<br>Method or attribute name: createAsset(displayName: string, options: PhotoCreateOptions, callback: AsyncCallback\<PhotoAsset>): void;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoAccessHelper;<br>Method or attribute name: createAsset(photoType: PhotoType, extension: string, options: CreateOptions, callback: AsyncCallback\<string>): void;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoAccessHelper;<br>Method or attribute name: createAsset(photoType: PhotoType, extension: string, callback: AsyncCallback\<string>): void;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoAccessHelper;<br>Method or attribute name: createAsset(photoType: PhotoType, extension: string, options?: CreateOptions): Promise\<string>;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoAccessHelper;<br>Method or attribute name: createAlbum(name: string, callback: AsyncCallback\<Album>): void;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoAccessHelper;<br>Method or attribute name: createAlbum(name: string): Promise\<Album>;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoAccessHelper;<br>Method or attribute name: deleteAlbums(albums: Array\<Album>, callback: AsyncCallback\<void>): void;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoAccessHelper;<br>Method or attribute name: deleteAlbums(albums: Array\<Album>): Promise\<void>;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoAccessHelper;<br>Method or attribute name: getAlbums(<br> type: AlbumType,<br> subtype: AlbumSubtype,<br> options: FetchOptions,<br> callback: AsyncCallback\<FetchResult\<Album>><br> ): void;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoAccessHelper;<br>Method or attribute name: getAlbums(type: AlbumType, subtype: AlbumSubtype, callback: AsyncCallback\<FetchResult\<Album>>): void;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoAccessHelper;<br>Method or attribute name: getAlbums(type: AlbumType, subtype: AlbumSubtype, options?: FetchOptions): Promise\<FetchResult\<Album>>;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoAccessHelper;<br>Method or attribute name: deleteAssets(uriList: Array\<string>, callback: AsyncCallback\<void>): void;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoAccessHelper;<br>Method or attribute name: deleteAssets(uriList: Array\<string>): Promise\<void>;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoAccessHelper;<br>Method or attribute name: registerChange(uri: string, forChildUris: boolean, callback: Callback\<ChangeData>): void;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoAccessHelper;<br>Method or attribute name: unRegisterChange(uri: string, callback?: Callback\<ChangeData>): void;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoAccessHelper;<br>Method or attribute name: release(callback: AsyncCallback\<void>): void;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: PhotoAccessHelper;<br>Method or attribute name: release(): Promise\<void>;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: NotifyType;<br>Method or attribute name: NOTIFY_ADD|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: NotifyType;<br>Method or attribute name: NOTIFY_UPDATE|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: NotifyType;<br>Method or attribute name: NOTIFY_REMOVE|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: NotifyType;<br>Method or attribute name: NOTIFY_ALBUM_ADD_ASSET|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: NotifyType;<br>Method or attribute name: NOTIFY_ALBUM_REMOVE_ASSET|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: DefaultChangeUri;<br>Method or attribute name: DEFAULT_PHOTO_URI = 'file://media/Photo'|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: DefaultChangeUri;<br>Method or attribute name: DEFAULT_ALBUM_URI = 'file://media/PhotoAlbum'|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: ChangeData;<br>Method or attribute name: type: NotifyType;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: ChangeData;<br>Method or attribute name: uris: Array\<string>;|@ohos.file.photoAccessHelper.d.ts|
|Added|NA|Class name: ChangeData;<br>Method or attribute name: extraUris: Array\<string>;|@ohos.file.photoAccessHelper.d.ts|
|Deprecated version changed|Class name: sourcefile;<br>Method or attribute name: declare function choose(callback: AsyncCallback\<string>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function choose(callback: AsyncCallback\<string>): void;<br>New version information: 9<br>Substitute API: |@ohos.document.d.ts|
|Deprecated version changed|Class name: sourcefile;<br>Method or attribute name: declare function choose(types: string[], callback: AsyncCallback\<string>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function choose(types: string[], callback: AsyncCallback\<string>): void;<br>New version information: 9<br>Substitute API: |@ohos.document.d.ts|
|Deprecated version changed|Class name: sourcefile;<br>Method or attribute name: declare function show(uri: string, type: string, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function show(uri: string, type: string, callback: AsyncCallback\<void>): void;<br>New version information: 9<br>Substitute API: |@ohos.document.d.ts|
|Deprecated version changed|Class name: document;<br>Method or attribute name: declare document<br>Old version information: |Class name: document;<br>Method or attribute name: declare document<br>New version information: 9<br>Substitute API: |@ohos.document.d.ts|
|Deprecated version changed|Class name: sourcefile;<br>Method or attribute name: declare function access(path: string, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function access(path: string, callback: AsyncCallback\<void>): void;<br>New version information: 9<br>Substitute API: ohos.file.fs.access|@ohos.fileio.d.ts|
|Deprecated version changed|Class name: sourcefile;<br>Method or attribute name: declare function access(path: string, mode: number, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function access(path: string, mode: number, callback: AsyncCallback\<void>): void;<br>New version information: 9<br>Substitute API: ohos.file.fs.access|@ohos.fileio.d.ts|
|Deprecated version changed|Class name: sourcefile;<br>Method or attribute name: declare function close(fd: number, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function close(fd: number, callback: AsyncCallback\<void>): void;<br>New version information: 9<br>Substitute API: ohos.file.fs.close|@ohos.fileio.d.ts|
|Deprecated version changed|Class name: sourcefile;<br>Method or attribute name: declare function copyFile(src: string \| number, dest: string \| number, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function copyFile(src: string \| number, dest: string \| number, callback: AsyncCallback\<void>): void;<br>New version information: 9<br>Substitute API: ohos.file.fs.copyFile|@ohos.fileio.d.ts|
|Deprecated version changed|Class name: sourcefile;<br>Method or attribute name: declare function copyFile(<br> src: string \| number,<br> dest: string \| number,<br> mode: number,<br> callback: AsyncCallback\<void><br>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function copyFile(<br> src: string \| number,<br> dest: string \| number,<br> mode: number,<br> callback: AsyncCallback\<void><br>): void;<br>New version information: 9<br>Substitute API: ohos.file.fs.copyFile|@ohos.fileio.d.ts|
|Deprecated version changed|Class name: sourcefile;<br>Method or attribute name: declare function createStream(path: string, mode: string, callback: AsyncCallback\<Stream>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function createStream(path: string, mode: string, callback: AsyncCallback\<Stream>): void;<br>New version information: 9<br>Substitute API: ohos.file.fs.createStream|@ohos.fileio.d.ts|
|Deprecated version changed|Class name: sourcefile;<br>Method or attribute name: declare function chown(path: string, uid: number, gid: number, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function chown(path: string, uid: number, gid: number, callback: AsyncCallback\<void>): void;<br>New version information: 9<br>Substitute API: |@ohos.fileio.d.ts|
|Deprecated version changed|Class name: sourcefile;<br>Method or attribute name: declare function chmod(path: string, mode: number, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function chmod(path: string, mode: number, callback: AsyncCallback\<void>): void;<br>New version information: 9<br>Substitute API: |@ohos.fileio.d.ts|
|Deprecated version changed|Class name: sourcefile;<br>Method or attribute name: declare function ftruncate(fd: number, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function ftruncate(fd: number, callback: AsyncCallback\<void>): void;<br>New version information: 9<br>Substitute API: ohos.file.fs.truncate|@ohos.fileio.d.ts|
|Deprecated version changed|Class name: sourcefile;<br>Method or attribute name: declare function ftruncate(fd: number, len: number, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function ftruncate(fd: number, len: number, callback: AsyncCallback\<void>): void;<br>New version information: 9<br>Substitute API: ohos.file.fs.truncate|@ohos.fileio.d.ts|
|Deprecated version changed|Class name: sourcefile;<br>Method or attribute name: declare function fsync(fd: number, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function fsync(fd: number, callback: AsyncCallback\<void>): void;<br>New version information: 9<br>Substitute API: ohos.file.fs.fsync|@ohos.fileio.d.ts|
|Deprecated version changed|Class name: sourcefile;<br>Method or attribute name: declare function fstat(fd: number, callback: AsyncCallback\<Stat>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function fstat(fd: number, callback: AsyncCallback\<Stat>): void;<br>New version information: 9<br>Substitute API: ohos.file.fs.stat|@ohos.fileio.d.ts|
|Deprecated version changed|Class name: sourcefile;<br>Method or attribute name: declare function fdatasync(fd: number, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function fdatasync(fd: number, callback: AsyncCallback\<void>): void;<br>New version information: 9<br>Substitute API: ohos.file.fs.fdatasync|@ohos.fileio.d.ts|
|Deprecated version changed|Class name: sourcefile;<br>Method or attribute name: declare function fchown(fd: number, uid: number, gid: number, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function fchown(fd: number, uid: number, gid: number, callback: AsyncCallback\<void>): void;<br>New version information: 9<br>Substitute API: |@ohos.fileio.d.ts|
|Deprecated version changed|Class name: sourcefile;<br>Method or attribute name: declare function fchmod(fd: number, mode: number, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function fchmod(fd: number, mode: number, callback: AsyncCallback\<void>): void;<br>New version information: 9<br>Substitute API: |@ohos.fileio.d.ts|
|Deprecated version changed|Class name: sourcefile;<br>Method or attribute name: declare function fdopenStream(fd: number, mode: string, callback: AsyncCallback\<Stream>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function fdopenStream(fd: number, mode: string, callback: AsyncCallback\<Stream>): void;<br>New version information: 9<br>Substitute API: ohos.file.fs.fdopenStream|@ohos.fileio.d.ts|
|Deprecated version changed|Class name: sourcefile;<br>Method or attribute name: declare function hash(path: string, algorithm: string, callback: AsyncCallback\<string>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function hash(path: string, algorithm: string, callback: AsyncCallback\<string>): void;<br>New version information: 9<br>Substitute API: ohos.file.hash.hash|@ohos.fileio.d.ts|
|Deprecated version changed|Class name: sourcefile;<br>Method or attribute name: declare function lchown(path: string, uid: number, gid: number, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function lchown(path: string, uid: number, gid: number, callback: AsyncCallback\<void>): void;<br>New version information: 9<br>Substitute API: |@ohos.fileio.d.ts|
|Deprecated version changed|Class name: sourcefile;<br>Method or attribute name: declare function lstat(path: string, callback: AsyncCallback\<Stat>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function lstat(path: string, callback: AsyncCallback\<Stat>): void;<br>New version information: 9<br>Substitute API: ohos.file.fs.lstat|@ohos.fileio.d.ts|
|Deprecated version changed|Class name: sourcefile;<br>Method or attribute name: declare function mkdir(path: string, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function mkdir(path: string, callback: AsyncCallback\<void>): void;<br>New version information: 9<br>Substitute API: ohos.file.fs.mkdir|@ohos.fileio.d.ts|
|Deprecated version changed|Class name: sourcefile;<br>Method or attribute name: declare function mkdir(path: string, mode: number, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function mkdir(path: string, mode: number, callback: AsyncCallback\<void>): void;<br>New version information: 9<br>Substitute API: ohos.file.fs.mkdir|@ohos.fileio.d.ts|
|Deprecated version changed|Class name: sourcefile;<br>Method or attribute name: declare function mkdtemp(prefix: string, callback: AsyncCallback\<string>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function mkdtemp(prefix: string, callback: AsyncCallback\<string>): void;<br>New version information: 9<br>Substitute API: ohos.file.fs.mkdtemp|@ohos.fileio.d.ts|
|Deprecated version changed|Class name: sourcefile;<br>Method or attribute name: declare function open(path: string, callback: AsyncCallback\<number>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function open(path: string, callback: AsyncCallback\<number>): void;<br>New version information: 9<br>Substitute API: ohos.file.fs.open|@ohos.fileio.d.ts|
|Deprecated version changed|Class name: sourcefile;<br>Method or attribute name: declare function open(path: string, flags: number, callback: AsyncCallback\<number>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function open(path: string, flags: number, callback: AsyncCallback\<number>): void;<br>New version information: 9<br>Substitute API: ohos.file.fs.open|@ohos.fileio.d.ts|
|Deprecated version changed|Class name: sourcefile;<br>Method or attribute name: declare function open(path: string, flags: number, mode: number, callback: AsyncCallback\<number>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function open(path: string, flags: number, mode: number, callback: AsyncCallback\<number>): void;<br>New version information: 9<br>Substitute API: ohos.file.fs.open|@ohos.fileio.d.ts|
|Deprecated version changed|Class name: sourcefile;<br>Method or attribute name: declare function opendir(path: string, callback: AsyncCallback\<Dir>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function opendir(path: string, callback: AsyncCallback\<Dir>): void;<br>New version information: 9<br>Substitute API: ohos.file.fs.listFile|@ohos.fileio.d.ts|
|Deprecated version changed|Class name: sourcefile;<br>Method or attribute name: declare function readText(<br> filePath: string,<br> options: {<br> position?: number;<br> length?: number;<br> encoding?: string;<br> },<br> callback: AsyncCallback\<string><br>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function readText(<br> filePath: string,<br> options: {<br> position?: number;<br> length?: number;<br> encoding?: string;<br> },<br> callback: AsyncCallback\<string><br>): void;<br>New version information: 9<br>Substitute API: ohos.file.fs.readText|@ohos.fileio.d.ts|
|Deprecated version changed|Class name: sourcefile;<br>Method or attribute name: declare function read(fd: number, buffer: ArrayBuffer, callback: AsyncCallback\<ReadOut>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function read(fd: number, buffer: ArrayBuffer, callback: AsyncCallback\<ReadOut>): void;<br>New version information: 9<br>Substitute API: ohos.file.fs.read|@ohos.fileio.d.ts|
|Deprecated version changed|Class name: sourcefile;<br>Method or attribute name: declare function read(<br> fd: number,<br> buffer: ArrayBuffer,<br> options: {<br> offset?: number;<br> length?: number;<br> position?: number;<br> },<br> callback: AsyncCallback\<ReadOut><br>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function read(<br> fd: number,<br> buffer: ArrayBuffer,<br> options: {<br> offset?: number;<br> length?: number;<br> position?: number;<br> },<br> callback: AsyncCallback\<ReadOut><br>): void;<br>New version information: 9<br>Substitute API: ohos.file.fs.read|@ohos.fileio.d.ts|
|Deprecated version changed|Class name: sourcefile;<br>Method or attribute name: declare function rename(oldPath: string, newPath: string, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function rename(oldPath: string, newPath: string, callback: AsyncCallback\<void>): void;<br>New version information: 9<br>Substitute API: ohos.file.fs.rename|@ohos.fileio.d.ts|
|Deprecated version changed|Class name: sourcefile;<br>Method or attribute name: declare function rmdir(path: string, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function rmdir(path: string, callback: AsyncCallback\<void>): void;<br>New version information: 9<br>Substitute API: ohos.file.fs.rmdir|@ohos.fileio.d.ts|
|Deprecated version changed|Class name: sourcefile;<br>Method or attribute name: declare function stat(path: string, callback: AsyncCallback\<Stat>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function stat(path: string, callback: AsyncCallback\<Stat>): void;<br>New version information: 9<br>Substitute API: ohos.file.fs.stat|@ohos.fileio.d.ts|
|Deprecated version changed|Class name: sourcefile;<br>Method or attribute name: declare function symlink(target: string, srcPath: string, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function symlink(target: string, srcPath: string, callback: AsyncCallback\<void>): void;<br>New version information: 9<br>Substitute API: ohos.file.fs.symlink|@ohos.fileio.d.ts|
|Deprecated version changed|Class name: sourcefile;<br>Method or attribute name: declare function truncate(path: string, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function truncate(path: string, callback: AsyncCallback\<void>): void;<br>New version information: 9<br>Substitute API: ohos.file.fs.truncate|@ohos.fileio.d.ts|
|Deprecated version changed|Class name: sourcefile;<br>Method or attribute name: declare function truncate(path: string, len: number, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function truncate(path: string, len: number, callback: AsyncCallback\<void>): void;<br>New version information: 9<br>Substitute API: ohos.file.fs.truncate|@ohos.fileio.d.ts|
|Deprecated version changed|Class name: sourcefile;<br>Method or attribute name: declare function unlink(path: string, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function unlink(path: string, callback: AsyncCallback\<void>): void;<br>New version information: 9<br>Substitute API: ohos.file.fs.unlink|@ohos.fileio.d.ts|
|Deprecated version changed|Class name: sourcefile;<br>Method or attribute name: declare function write(fd: number, buffer: ArrayBuffer \| string, callback: AsyncCallback\<number>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function write(fd: number, buffer: ArrayBuffer \| string, callback: AsyncCallback\<number>): void;<br>New version information: 9<br>Substitute API: ohos.file.fs.write|@ohos.fileio.d.ts|
|Deprecated version changed|Class name: sourcefile;<br>Method or attribute name: declare function write(<br> fd: number,<br> buffer: ArrayBuffer \| string,<br> options: {<br> offset?: number;<br> length?: number;<br> position?: number;<br> encoding?: string;<br> },<br> callback: AsyncCallback\<number><br>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function write(<br> fd: number,<br> buffer: ArrayBuffer \| string,<br> options: {<br> offset?: number;<br> length?: number;<br> position?: number;<br> encoding?: string;<br> },<br> callback: AsyncCallback\<number><br>): void;<br>New version information: 9<br>Substitute API: ohos.file.fs.write|@ohos.fileio.d.ts|
|Deprecated version changed|Class name: sourcefile;<br>Method or attribute name: declare function createWatcher(filename: string, events: number, callback: AsyncCallback\<number>): Watcher;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function createWatcher(filename: string, events: number, callback: AsyncCallback\<number>): Watcher;<br>New version information: 10<br>Substitute API: ohos.file.fs.createWatcher|@ohos.fileio.d.ts|
|Deprecated version changed|Class name: Dir;<br>Method or attribute name: declare interface Dir<br>Old version information: |Class name: Dir;<br>Method or attribute name: declare interface Dir<br>New version information: 9<br>Substitute API: ohos.file.fs.listFile|@ohos.fileio.d.ts|
|Deprecated version changed|Class name: Dir;<br>Method or attribute name: read(callback: AsyncCallback\<Dirent>): void;<br>Old version information: |Class name: Dir;<br>Method or attribute name: read(callback: AsyncCallback\<Dirent>): void;<br>New version information: 9<br>Substitute API: ohos.file.fs.listFile|@ohos.fileio.d.ts|
|Deprecated version changed|Class name: Dir;<br>Method or attribute name: close(callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: Dir;<br>Method or attribute name: close(callback: AsyncCallback\<void>): void;<br>New version information: 9<br>Substitute API: ohos.file.fs.listFile|@ohos.fileio.d.ts|
|Deprecated version changed|Class name: Watcher;<br>Method or attribute name: declare interface Watcher<br>Old version information: |Class name: Watcher;<br>Method or attribute name: declare interface Watcher<br>New version information: 10<br>Substitute API: ohos.file.fs.Watcher|@ohos.fileio.d.ts|
|Deprecated version changed|Class name: Watcher;<br>Method or attribute name: stop(): Promise\<void>;<br>Old version information: |Class name: Watcher;<br>Method or attribute name: stop(): Promise\<void>;<br>New version information: 10<br>Substitute API: ohos.file.fs.Watcher.stop|@ohos.fileio.d.ts|
|Deprecated version changed|Class name: Watcher;<br>Method or attribute name: stop(callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: Watcher;<br>Method or attribute name: stop(callback: AsyncCallback\<void>): void;<br>New version information: 10<br>Substitute API: ohos.file.fs.Watcher.stop|@ohos.fileio.d.ts|
|Deprecated version changed|Class name: Statfs;<br>Method or attribute name: declare Statfs<br>Old version information: |Class name: Statfs;<br>Method or attribute name: declare Statfs<br>New version information: 9<br>Substitute API: ohos.file.statvfs.statfs|@ohos.statfs.d.ts|
|Deprecated version changed|Class name: Statfs;<br>Method or attribute name: function getFreeBytes(path: string): Promise\<number>;<br>Old version information: |Class name: Statfs;<br>Method or attribute name: function getFreeBytes(path: string): Promise\<number>;<br>New version information: 9<br>Substitute API: ohos.file.statvfs.getFreeSize|@ohos.statfs.d.ts|
|Deprecated version changed|Class name: Statfs;<br>Method or attribute name: function getTotalBytes(path: string): Promise\<number>;<br>Old version information: |Class name: Statfs;<br>Method or attribute name: function getTotalBytes(path: string): Promise\<number>;<br>New version information: 9<br>Substitute API: ohos.file.statvfs.getTotalSize|@ohos.statfs.d.ts|
|Deprecated version changed|Class name: FileResponse;<br>Method or attribute name: export interface FileResponse<br>Old version information: |Class name: FileResponse;<br>Method or attribute name: export interface FileResponse<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileResponse;<br>Method or attribute name: uri: string;<br>Old version information: |Class name: FileResponse;<br>Method or attribute name: uri: string;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileListOption;<br>Method or attribute name: uri: string;<br>Old version information: |Class name: FileListOption;<br>Method or attribute name: uri: string;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileGetOption;<br>Method or attribute name: uri: string;<br>Old version information: |Class name: FileGetOption;<br>Method or attribute name: uri: string;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileDeleteOption;<br>Method or attribute name: uri: string;<br>Old version information: |Class name: FileDeleteOption;<br>Method or attribute name: uri: string;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileWriteTextOption;<br>Method or attribute name: uri: string;<br>Old version information: |Class name: FileWriteTextOption;<br>Method or attribute name: uri: string;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileReadTextOption;<br>Method or attribute name: uri: string;<br>Old version information: |Class name: FileReadTextOption;<br>Method or attribute name: uri: string;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileWriteArrayBufferOption;<br>Method or attribute name: uri: string;<br>Old version information: |Class name: FileWriteArrayBufferOption;<br>Method or attribute name: uri: string;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileReadArrayBufferOption;<br>Method or attribute name: uri: string;<br>Old version information: |Class name: FileReadArrayBufferOption;<br>Method or attribute name: uri: string;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileAccessOption;<br>Method or attribute name: uri: string;<br>Old version information: |Class name: FileAccessOption;<br>Method or attribute name: uri: string;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileMkdirOption;<br>Method or attribute name: uri: string;<br>Old version information: |Class name: FileMkdirOption;<br>Method or attribute name: uri: string;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileRmdirOption;<br>Method or attribute name: uri: string;<br>Old version information: |Class name: FileRmdirOption;<br>Method or attribute name: uri: string;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileResponse;<br>Method or attribute name: length: number;<br>Old version information: |Class name: FileResponse;<br>Method or attribute name: length: number;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileResponse;<br>Method or attribute name: lastModifiedTime: number;<br>Old version information: |Class name: FileResponse;<br>Method or attribute name: lastModifiedTime: number;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileResponse;<br>Method or attribute name: type: 'dir' \| 'file';<br>Old version information: |Class name: FileResponse;<br>Method or attribute name: type: 'dir' \| 'file';<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileResponse;<br>Method or attribute name: subFiles?: Array\<FileResponse>;<br>Old version information: |Class name: FileResponse;<br>Method or attribute name: subFiles?: Array\<FileResponse>;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileMoveOption;<br>Method or attribute name: export interface FileMoveOption<br>Old version information: |Class name: FileMoveOption;<br>Method or attribute name: export interface FileMoveOption<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileMoveOption;<br>Method or attribute name: srcUri: string;<br>Old version information: |Class name: FileMoveOption;<br>Method or attribute name: srcUri: string;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileCopyOption;<br>Method or attribute name: srcUri: string;<br>Old version information: |Class name: FileCopyOption;<br>Method or attribute name: srcUri: string;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileMoveOption;<br>Method or attribute name: dstUri: string;<br>Old version information: |Class name: FileMoveOption;<br>Method or attribute name: dstUri: string;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileCopyOption;<br>Method or attribute name: dstUri: string;<br>Old version information: |Class name: FileCopyOption;<br>Method or attribute name: dstUri: string;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileMoveOption;<br>Method or attribute name: success?: (uri: string) => void;<br>Old version information: |Class name: FileMoveOption;<br>Method or attribute name: success?: (uri: string) => void;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileCopyOption;<br>Method or attribute name: success?: (uri: string) => void;<br>Old version information: |Class name: FileCopyOption;<br>Method or attribute name: success?: (uri: string) => void;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileMoveOption;<br>Method or attribute name: fail?: (data: string, code: number) => void;<br>Old version information: |Class name: FileMoveOption;<br>Method or attribute name: fail?: (data: string, code: number) => void;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileListOption;<br>Method or attribute name: fail?: (data: string, code: number) => void;<br>Old version information: |Class name: FileListOption;<br>Method or attribute name: fail?: (data: string, code: number) => void;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileCopyOption;<br>Method or attribute name: fail?: (data: string, code: number) => void;<br>Old version information: |Class name: FileCopyOption;<br>Method or attribute name: fail?: (data: string, code: number) => void;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileGetOption;<br>Method or attribute name: fail?: (data: string, code: number) => void;<br>Old version information: |Class name: FileGetOption;<br>Method or attribute name: fail?: (data: string, code: number) => void;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileDeleteOption;<br>Method or attribute name: fail?: (data: string, code: number) => void;<br>Old version information: |Class name: FileDeleteOption;<br>Method or attribute name: fail?: (data: string, code: number) => void;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileWriteTextOption;<br>Method or attribute name: fail?: (data: string, code: number) => void;<br>Old version information: |Class name: FileWriteTextOption;<br>Method or attribute name: fail?: (data: string, code: number) => void;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileReadTextOption;<br>Method or attribute name: fail?: (data: string, code: number) => void;<br>Old version information: |Class name: FileReadTextOption;<br>Method or attribute name: fail?: (data: string, code: number) => void;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileWriteArrayBufferOption;<br>Method or attribute name: fail?: (data: string, code: number) => void;<br>Old version information: |Class name: FileWriteArrayBufferOption;<br>Method or attribute name: fail?: (data: string, code: number) => void;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileReadArrayBufferOption;<br>Method or attribute name: fail?: (data: string, code: number) => void;<br>Old version information: |Class name: FileReadArrayBufferOption;<br>Method or attribute name: fail?: (data: string, code: number) => void;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileAccessOption;<br>Method or attribute name: fail?: (data: string, code: number) => void;<br>Old version information: |Class name: FileAccessOption;<br>Method or attribute name: fail?: (data: string, code: number) => void;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileMkdirOption;<br>Method or attribute name: fail?: (data: string, code: number) => void;<br>Old version information: |Class name: FileMkdirOption;<br>Method or attribute name: fail?: (data: string, code: number) => void;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileRmdirOption;<br>Method or attribute name: fail?: (data: string, code: number) => void;<br>Old version information: |Class name: FileRmdirOption;<br>Method or attribute name: fail?: (data: string, code: number) => void;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileMoveOption;<br>Method or attribute name: complete?: () => void;<br>Old version information: |Class name: FileMoveOption;<br>Method or attribute name: complete?: () => void;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileListOption;<br>Method or attribute name: complete?: () => void;<br>Old version information: |Class name: FileListOption;<br>Method or attribute name: complete?: () => void;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileCopyOption;<br>Method or attribute name: complete?: () => void;<br>Old version information: |Class name: FileCopyOption;<br>Method or attribute name: complete?: () => void;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileGetOption;<br>Method or attribute name: complete?: () => void;<br>Old version information: |Class name: FileGetOption;<br>Method or attribute name: complete?: () => void;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileDeleteOption;<br>Method or attribute name: complete?: () => void;<br>Old version information: |Class name: FileDeleteOption;<br>Method or attribute name: complete?: () => void;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileWriteTextOption;<br>Method or attribute name: complete?: () => void;<br>Old version information: |Class name: FileWriteTextOption;<br>Method or attribute name: complete?: () => void;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileReadTextOption;<br>Method or attribute name: complete?: () => void;<br>Old version information: |Class name: FileReadTextOption;<br>Method or attribute name: complete?: () => void;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileWriteArrayBufferOption;<br>Method or attribute name: complete?: () => void;<br>Old version information: |Class name: FileWriteArrayBufferOption;<br>Method or attribute name: complete?: () => void;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileReadArrayBufferOption;<br>Method or attribute name: complete?: () => void;<br>Old version information: |Class name: FileReadArrayBufferOption;<br>Method or attribute name: complete?: () => void;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileAccessOption;<br>Method or attribute name: complete?: () => void;<br>Old version information: |Class name: FileAccessOption;<br>Method or attribute name: complete?: () => void;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileMkdirOption;<br>Method or attribute name: complete?: () => void;<br>Old version information: |Class name: FileMkdirOption;<br>Method or attribute name: complete?: () => void;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileRmdirOption;<br>Method or attribute name: complete?: () => void;<br>Old version information: |Class name: FileRmdirOption;<br>Method or attribute name: complete?: () => void;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileListResponse;<br>Method or attribute name: export interface FileListResponse<br>Old version information: |Class name: FileListResponse;<br>Method or attribute name: export interface FileListResponse<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileListResponse;<br>Method or attribute name: fileList: Array\<FileResponse>;<br>Old version information: |Class name: FileListResponse;<br>Method or attribute name: fileList: Array\<FileResponse>;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileListOption;<br>Method or attribute name: export interface FileListOption<br>Old version information: |Class name: FileListOption;<br>Method or attribute name: export interface FileListOption<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileListOption;<br>Method or attribute name: success?: (data: FileListResponse) => void;<br>Old version information: |Class name: FileListOption;<br>Method or attribute name: success?: (data: FileListResponse) => void;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileCopyOption;<br>Method or attribute name: export interface FileCopyOption<br>Old version information: |Class name: FileCopyOption;<br>Method or attribute name: export interface FileCopyOption<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileGetOption;<br>Method or attribute name: export interface FileGetOption<br>Old version information: |Class name: FileGetOption;<br>Method or attribute name: export interface FileGetOption<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileGetOption;<br>Method or attribute name: recursive?: boolean;<br>Old version information: |Class name: FileGetOption;<br>Method or attribute name: recursive?: boolean;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileMkdirOption;<br>Method or attribute name: recursive?: boolean;<br>Old version information: |Class name: FileMkdirOption;<br>Method or attribute name: recursive?: boolean;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileRmdirOption;<br>Method or attribute name: recursive?: boolean;<br>Old version information: |Class name: FileRmdirOption;<br>Method or attribute name: recursive?: boolean;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileGetOption;<br>Method or attribute name: success?: (file: FileResponse) => void;<br>Old version information: |Class name: FileGetOption;<br>Method or attribute name: success?: (file: FileResponse) => void;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileDeleteOption;<br>Method or attribute name: export interface FileDeleteOption<br>Old version information: |Class name: FileDeleteOption;<br>Method or attribute name: export interface FileDeleteOption<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileDeleteOption;<br>Method or attribute name: success?: () => void;<br>Old version information: |Class name: FileDeleteOption;<br>Method or attribute name: success?: () => void;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileWriteTextOption;<br>Method or attribute name: success?: () => void;<br>Old version information: |Class name: FileWriteTextOption;<br>Method or attribute name: success?: () => void;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileWriteArrayBufferOption;<br>Method or attribute name: success?: () => void;<br>Old version information: |Class name: FileWriteArrayBufferOption;<br>Method or attribute name: success?: () => void;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileAccessOption;<br>Method or attribute name: success?: () => void;<br>Old version information: |Class name: FileAccessOption;<br>Method or attribute name: success?: () => void;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileMkdirOption;<br>Method or attribute name: success?: () => void;<br>Old version information: |Class name: FileMkdirOption;<br>Method or attribute name: success?: () => void;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileRmdirOption;<br>Method or attribute name: success?: () => void;<br>Old version information: |Class name: FileRmdirOption;<br>Method or attribute name: success?: () => void;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileWriteTextOption;<br>Method or attribute name: export interface FileWriteTextOption<br>Old version information: |Class name: FileWriteTextOption;<br>Method or attribute name: export interface FileWriteTextOption<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileWriteTextOption;<br>Method or attribute name: text: string;<br>Old version information: |Class name: FileWriteTextOption;<br>Method or attribute name: text: string;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileReadTextResponse;<br>Method or attribute name: text: string;<br>Old version information: |Class name: FileReadTextResponse;<br>Method or attribute name: text: string;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileWriteTextOption;<br>Method or attribute name: encoding?: string;<br>Old version information: |Class name: FileWriteTextOption;<br>Method or attribute name: encoding?: string;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileReadTextOption;<br>Method or attribute name: encoding?: string;<br>Old version information: |Class name: FileReadTextOption;<br>Method or attribute name: encoding?: string;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileWriteTextOption;<br>Method or attribute name: append?: boolean;<br>Old version information: |Class name: FileWriteTextOption;<br>Method or attribute name: append?: boolean;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileWriteArrayBufferOption;<br>Method or attribute name: append?: boolean;<br>Old version information: |Class name: FileWriteArrayBufferOption;<br>Method or attribute name: append?: boolean;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileReadTextResponse;<br>Method or attribute name: export interface FileReadTextResponse<br>Old version information: |Class name: FileReadTextResponse;<br>Method or attribute name: export interface FileReadTextResponse<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileReadTextOption;<br>Method or attribute name: export interface FileReadTextOption<br>Old version information: |Class name: FileReadTextOption;<br>Method or attribute name: export interface FileReadTextOption<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileReadTextOption;<br>Method or attribute name: position?: number;<br>Old version information: |Class name: FileReadTextOption;<br>Method or attribute name: position?: number;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileWriteArrayBufferOption;<br>Method or attribute name: position?: number;<br>Old version information: |Class name: FileWriteArrayBufferOption;<br>Method or attribute name: position?: number;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileReadArrayBufferOption;<br>Method or attribute name: position?: number;<br>Old version information: |Class name: FileReadArrayBufferOption;<br>Method or attribute name: position?: number;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileReadTextOption;<br>Method or attribute name: length?: number;<br>Old version information: |Class name: FileReadTextOption;<br>Method or attribute name: length?: number;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileReadArrayBufferOption;<br>Method or attribute name: length?: number;<br>Old version information: |Class name: FileReadArrayBufferOption;<br>Method or attribute name: length?: number;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileReadTextOption;<br>Method or attribute name: success?: (data: FileReadTextResponse) => void;<br>Old version information: |Class name: FileReadTextOption;<br>Method or attribute name: success?: (data: FileReadTextResponse) => void;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileWriteArrayBufferOption;<br>Method or attribute name: export interface FileWriteArrayBufferOption<br>Old version information: |Class name: FileWriteArrayBufferOption;<br>Method or attribute name: export interface FileWriteArrayBufferOption<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileWriteArrayBufferOption;<br>Method or attribute name: buffer: Uint8Array;<br>Old version information: |Class name: FileWriteArrayBufferOption;<br>Method or attribute name: buffer: Uint8Array;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileReadArrayBufferResponse;<br>Method or attribute name: buffer: Uint8Array;<br>Old version information: |Class name: FileReadArrayBufferResponse;<br>Method or attribute name: buffer: Uint8Array;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileReadArrayBufferResponse;<br>Method or attribute name: export interface FileReadArrayBufferResponse<br>Old version information: |Class name: FileReadArrayBufferResponse;<br>Method or attribute name: export interface FileReadArrayBufferResponse<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileReadArrayBufferOption;<br>Method or attribute name: export interface FileReadArrayBufferOption<br>Old version information: |Class name: FileReadArrayBufferOption;<br>Method or attribute name: export interface FileReadArrayBufferOption<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileReadArrayBufferOption;<br>Method or attribute name: success?: (data: FileReadArrayBufferResponse) => void;<br>Old version information: |Class name: FileReadArrayBufferOption;<br>Method or attribute name: success?: (data: FileReadArrayBufferResponse) => void;<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileAccessOption;<br>Method or attribute name: export interface FileAccessOption<br>Old version information: |Class name: FileAccessOption;<br>Method or attribute name: export interface FileAccessOption<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileMkdirOption;<br>Method or attribute name: export interface FileMkdirOption<br>Old version information: |Class name: FileMkdirOption;<br>Method or attribute name: export interface FileMkdirOption<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: FileRmdirOption;<br>Method or attribute name: export interface FileRmdirOption<br>Old version information: |Class name: FileRmdirOption;<br>Method or attribute name: export interface FileRmdirOption<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: File;<br>Method or attribute name: export default class File<br>Old version information: |Class name: File;<br>Method or attribute name: export default class File<br>New version information: 10<br>Substitute API: |@system.file.d.ts|
|Deprecated version changed|Class name: File;<br>Method or attribute name: static move(options: FileMoveOption): void;<br>Old version information: |Class name: File;<br>Method or attribute name: static move(options: FileMoveOption): void;<br>New version information: 10<br>Substitute API: ohos.file.fs.moveFile|@system.file.d.ts|
|Deprecated version changed|Class name: File;<br>Method or attribute name: static copy(options: FileCopyOption): void;<br>Old version information: |Class name: File;<br>Method or attribute name: static copy(options: FileCopyOption): void;<br>New version information: 10<br>Substitute API: ohos.file.fs.copyFile|@system.file.d.ts|
|Deprecated version changed|Class name: File;<br>Method or attribute name: static list(options: FileListOption): void;<br>Old version information: |Class name: File;<br>Method or attribute name: static list(options: FileListOption): void;<br>New version information: 10<br>Substitute API: ohos.file.fs.listFile|@system.file.d.ts|
|Deprecated version changed|Class name: File;<br>Method or attribute name: static get(options: FileGetOption): void;<br>Old version information: |Class name: File;<br>Method or attribute name: static get(options: FileGetOption): void;<br>New version information: 10<br>Substitute API: ohos.file.fs.stat|@system.file.d.ts|
|Deprecated version changed|Class name: File;<br>Method or attribute name: static delete(options: FileDeleteOption): void;<br>Old version information: |Class name: File;<br>Method or attribute name: static delete(options: FileDeleteOption): void;<br>New version information: 10<br>Substitute API: ohos.file.fs.unlink|@system.file.d.ts|
|Deprecated version changed|Class name: File;<br>Method or attribute name: static writeText(options: FileWriteTextOption): void;<br>Old version information: |Class name: File;<br>Method or attribute name: static writeText(options: FileWriteTextOption): void;<br>New version information: 10<br>Substitute API: ohos.file.fs.write|@system.file.d.ts|
|Deprecated version changed|Class name: File;<br>Method or attribute name: static readText(options: FileReadTextOption): void;<br>Old version information: |Class name: File;<br>Method or attribute name: static readText(options: FileReadTextOption): void;<br>New version information: 10<br>Substitute API: ohos.file.fs.readText|@system.file.d.ts|
|Deprecated version changed|Class name: File;<br>Method or attribute name: static writeArrayBuffer(options: FileWriteArrayBufferOption): void;<br>Old version information: |Class name: File;<br>Method or attribute name: static writeArrayBuffer(options: FileWriteArrayBufferOption): void;<br>New version information: 10<br>Substitute API: ohos.file.fs.write|@system.file.d.ts|
|Deprecated version changed|Class name: File;<br>Method or attribute name: static readArrayBuffer(options: FileReadArrayBufferOption): void;<br>Old version information: |Class name: File;<br>Method or attribute name: static readArrayBuffer(options: FileReadArrayBufferOption): void;<br>New version information: 10<br>Substitute API: ohos.file.fs.read|@system.file.d.ts|
|Deprecated version changed|Class name: File;<br>Method or attribute name: static access(options: FileAccessOption): void;<br>Old version information: |Class name: File;<br>Method or attribute name: static access(options: FileAccessOption): void;<br>New version information: 10<br>Substitute API: ohos.file.fs.access|@system.file.d.ts|
|Deprecated version changed|Class name: File;<br>Method or attribute name: static mkdir(options: FileMkdirOption): void;<br>Old version information: |Class name: File;<br>Method or attribute name: static mkdir(options: FileMkdirOption): void;<br>New version information: 10<br>Substitute API: ohos.file.fs.mkdir|@system.file.d.ts|
|Deprecated version changed|Class name: File;<br>Method or attribute name: static rmdir(options: FileRmdirOption): void;<br>Old version information: |Class name: File;<br>Method or attribute name: static rmdir(options: FileRmdirOption): void;<br>New version information: 10<br>Substitute API: ohos.file.fs.rmdir|@system.file.d.ts|
|Error code added|Class name: sourcefile;<br>Method or attribute name: declare function choose(callback: AsyncCallback\<string>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function choose(callback: AsyncCallback\<string>): void;<br>New version information: Parameter|@ohos.document.d.ts|
|Error code added|Class name: sourcefile;<br>Method or attribute name: declare function choose(types: string[], callback: AsyncCallback\<string>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function choose(types: string[], callback: AsyncCallback\<string>): void;<br>New version information: Parameter|@ohos.document.d.ts|
|Error code added|Class name: sourcefile;<br>Method or attribute name: declare function show(uri: string, type: string, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function show(uri: string, type: string, callback: AsyncCallback\<void>): void;<br>New version information: Parameter|@ohos.document.d.ts|
|Error code added|Class name: storageStatistics;<br>Method or attribute name: function getTotalSizeOfVolume(volumeUuid: string): Promise\<number>;<br>Old version information: |Class name: storageStatistics;<br>Method or attribute name: function getTotalSizeOfVolume(volumeUuid: string): Promise\<number>;<br>New version information: 201,202,401,13600001,13600008,13900032|@ohos.file.storageStatistics.d.ts|
|Error code added|Class name: storageStatistics;<br>Method or attribute name: function getFreeSizeOfVolume(volumeUuid: string): Promise\<number>;<br>Old version information: |Class name: storageStatistics;<br>Method or attribute name: function getFreeSizeOfVolume(volumeUuid: string): Promise\<number>;<br>New version information: 201,202,401,13600001,13600008,13900032|@ohos.file.storageStatistics.d.ts|
|Error code added|Class name: storageStatistics;<br>Method or attribute name: function getBundleStats(packageName: string): Promise\<BundleStats>;<br>Old version information: |Class name: storageStatistics;<br>Method or attribute name: function getBundleStats(packageName: string): Promise\<BundleStats>;<br>New version information: 201,202,401,13600001,13600008,13900032|@ohos.file.storageStatistics.d.ts|
|Error code added|Class name: storageStatistics;<br>Method or attribute name: function getCurrentBundleStats(): Promise\<BundleStats>;<br>Old version information: |Class name: storageStatistics;<br>Method or attribute name: function getCurrentBundleStats(): Promise\<BundleStats>;<br>New version information: 401,13600001,13900032|@ohos.file.storageStatistics.d.ts|
|Error code added|Class name: storageStatistics;<br>Method or attribute name: function getSystemSize(): Promise\<number>;<br>Old version information: |Class name: storageStatistics;<br>Method or attribute name: function getSystemSize(): Promise\<number>;<br>New version information: 201,202,401,13600001,13900032|@ohos.file.storageStatistics.d.ts|
|Error code added|Class name: storageStatistics;<br>Method or attribute name: function getUserStorageStats(callback: AsyncCallback\<StorageStats>): void;<br>Old version information: |Class name: storageStatistics;<br>Method or attribute name: function getUserStorageStats(callback: AsyncCallback\<StorageStats>): void;<br>New version information: 201,202,401,13600001,13900032|@ohos.file.storageStatistics.d.ts|
|Error code added|Class name: storageStatistics;<br>Method or attribute name: function getUserStorageStats(userId: number, callback: AsyncCallback\<StorageStats>): void;<br>Old version information: |Class name: storageStatistics;<br>Method or attribute name: function getUserStorageStats(userId: number, callback: AsyncCallback\<StorageStats>): void;<br>New version information: 201,202,401,13600001,13600009,13900032|@ohos.file.storageStatistics.d.ts|
|Error code added|Class name: storageStatistics;<br>Method or attribute name: function getTotalSize(): Promise\<number>;<br>Old version information: |Class name: storageStatistics;<br>Method or attribute name: function getTotalSize(): Promise\<number>;<br>New version information: 201,202,401,13600001,13900032|@ohos.file.storageStatistics.d.ts|
|Error code added|Class name: storageStatistics;<br>Method or attribute name: function getFreeSize(): Promise\<number>;<br>Old version information: |Class name: storageStatistics;<br>Method or attribute name: function getFreeSize(): Promise\<number>;<br>New version information: 201,202,401,13600001,13900032|@ohos.file.storageStatistics.d.ts|
|Error code added|Class name: volumeManager;<br>Method or attribute name: function getAllVolumes(): Promise\<Array\<Volume>>;<br>Old version information: |Class name: volumeManager;<br>Method or attribute name: function getAllVolumes(): Promise\<Array\<Volume>>;<br>New version information: 201,202,401,13600001,13900032|@ohos.file.volumeManager.d.ts|
|Error code added|Class name: volumeManager;<br>Method or attribute name: function mount(volumeId: string): Promise\<void>;<br>Old version information: |Class name: volumeManager;<br>Method or attribute name: function mount(volumeId: string): Promise\<void>;<br>New version information: 201,202,401,13600001,13600002,13600003,13600005,13600008,13900032|@ohos.file.volumeManager.d.ts|
|Error code added|Class name: volumeManager;<br>Method or attribute name: function unmount(volumeId: string): Promise\<void>;<br>Old version information: |Class name: volumeManager;<br>Method or attribute name: function unmount(volumeId: string): Promise\<void>;<br>New version information: 201,202,401,13600001,13600002,13600004,13600005,13600008,13900032|@ohos.file.volumeManager.d.ts|
|Error code added|Class name: volumeManager;<br>Method or attribute name: function getVolumeByUuid(uuid: string): Promise\<Volume>;<br>Old version information: |Class name: volumeManager;<br>Method or attribute name: function getVolumeByUuid(uuid: string): Promise\<Volume>;<br>New version information: 201,202,401,13600001,13600008,13900032|@ohos.file.volumeManager.d.ts|
|Error code added|Class name: volumeManager;<br>Method or attribute name: function getVolumeById(volumeId: string): Promise\<Volume>;<br>Old version information: |Class name: volumeManager;<br>Method or attribute name: function getVolumeById(volumeId: string): Promise\<Volume>;<br>New version information: 201,202,401,13600001,13600008,13900032|@ohos.file.volumeManager.d.ts|
|Error code added|Class name: volumeManager;<br>Method or attribute name: function setVolumeDescription(uuid: string, description: string): Promise\<void>;<br>Old version information: |Class name: volumeManager;<br>Method or attribute name: function setVolumeDescription(uuid: string, description: string): Promise\<void>;<br>New version information: 201,202,401,13600001,13600002,13600005,13600008,13900032|@ohos.file.volumeManager.d.ts|
|Error code added|Class name: volumeManager;<br>Method or attribute name: function format(volumeId: string, fsType: string): Promise\<void>;<br>Old version information: |Class name: volumeManager;<br>Method or attribute name: function format(volumeId: string, fsType: string): Promise\<void>;<br>New version information: 201,202,401,13600001,13600002,13600005,13600008,13900032|@ohos.file.volumeManager.d.ts|
|Error code added|Class name: volumeManager;<br>Method or attribute name: function partition(diskId: string, type: number): Promise\<void>;<br>Old version information: |Class name: volumeManager;<br>Method or attribute name: function partition(diskId: string, type: number): Promise\<void>;<br>New version information: 201,202,401,13600001,13600008,13900032|@ohos.file.volumeManager.d.ts|
|Error code added|Class name: sourcefile;<br>Method or attribute name: declare function access(path: string, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function access(path: string, callback: AsyncCallback\<void>): void;<br>New version information: Parameter|@ohos.fileio.d.ts|
|Error code added|Class name: sourcefile;<br>Method or attribute name: declare function access(path: string, mode: number, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function access(path: string, mode: number, callback: AsyncCallback\<void>): void;<br>New version information: Parameter|@ohos.fileio.d.ts|
|Error code added|Class name: sourcefile;<br>Method or attribute name: declare function close(fd: number, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function close(fd: number, callback: AsyncCallback\<void>): void;<br>New version information: Parameter|@ohos.fileio.d.ts|
|Error code added|Class name: sourcefile;<br>Method or attribute name: declare function copyFile(src: string \| number, dest: string \| number, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function copyFile(src: string \| number, dest: string \| number, callback: AsyncCallback\<void>): void;<br>New version information: Parameter|@ohos.fileio.d.ts|
|Error code added|Class name: sourcefile;<br>Method or attribute name: declare function copyFile(<br> src: string \| number,<br> dest: string \| number,<br> mode: number,<br> callback: AsyncCallback\<void><br>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function copyFile(<br> src: string \| number,<br> dest: string \| number,<br> mode: number,<br> callback: AsyncCallback\<void><br>): void;<br>New version information: Parameter|@ohos.fileio.d.ts|
|Error code added|Class name: sourcefile;<br>Method or attribute name: declare function createStream(path: string, mode: string, callback: AsyncCallback\<Stream>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function createStream(path: string, mode: string, callback: AsyncCallback\<Stream>): void;<br>New version information: Parameter|@ohos.fileio.d.ts|
|Error code added|Class name: sourcefile;<br>Method or attribute name: declare function chown(path: string, uid: number, gid: number, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function chown(path: string, uid: number, gid: number, callback: AsyncCallback\<void>): void;<br>New version information: Parameter|@ohos.fileio.d.ts|
|Error code added|Class name: sourcefile;<br>Method or attribute name: declare function chmod(path: string, mode: number, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function chmod(path: string, mode: number, callback: AsyncCallback\<void>): void;<br>New version information: Parameter|@ohos.fileio.d.ts|
|Error code added|Class name: sourcefile;<br>Method or attribute name: declare function ftruncate(fd: number, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function ftruncate(fd: number, callback: AsyncCallback\<void>): void;<br>New version information: Parameter|@ohos.fileio.d.ts|
|Error code added|Class name: sourcefile;<br>Method or attribute name: declare function ftruncate(fd: number, len: number, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function ftruncate(fd: number, len: number, callback: AsyncCallback\<void>): void;<br>New version information: Parameter|@ohos.fileio.d.ts|
|Error code added|Class name: sourcefile;<br>Method or attribute name: declare function fsync(fd: number, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function fsync(fd: number, callback: AsyncCallback\<void>): void;<br>New version information: Parameter|@ohos.fileio.d.ts|
|Error code added|Class name: sourcefile;<br>Method or attribute name: declare function fstat(fd: number, callback: AsyncCallback\<Stat>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function fstat(fd: number, callback: AsyncCallback\<Stat>): void;<br>New version information: fstat|@ohos.fileio.d.ts|
|Error code added|Class name: sourcefile;<br>Method or attribute name: declare function fdatasync(fd: number, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function fdatasync(fd: number, callback: AsyncCallback\<void>): void;<br>New version information: Parameter|@ohos.fileio.d.ts|
|Error code added|Class name: sourcefile;<br>Method or attribute name: declare function fchown(fd: number, uid: number, gid: number, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function fchown(fd: number, uid: number, gid: number, callback: AsyncCallback\<void>): void;<br>New version information: Parameter|@ohos.fileio.d.ts|
|Error code added|Class name: sourcefile;<br>Method or attribute name: declare function fchmod(fd: number, mode: number, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function fchmod(fd: number, mode: number, callback: AsyncCallback\<void>): void;<br>New version information: Parameter|@ohos.fileio.d.ts|
|Error code added|Class name: sourcefile;<br>Method or attribute name: declare function fdopenStream(fd: number, mode: string, callback: AsyncCallback\<Stream>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function fdopenStream(fd: number, mode: string, callback: AsyncCallback\<Stream>): void;<br>New version information: Parameter|@ohos.fileio.d.ts|
|Error code added|Class name: sourcefile;<br>Method or attribute name: declare function hash(path: string, algorithm: string, callback: AsyncCallback\<string>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function hash(path: string, algorithm: string, callback: AsyncCallback\<string>): void;<br>New version information: Parameter|@ohos.fileio.d.ts|
|Error code added|Class name: sourcefile;<br>Method or attribute name: declare function lchown(path: string, uid: number, gid: number, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function lchown(path: string, uid: number, gid: number, callback: AsyncCallback\<void>): void;<br>New version information: Parameter|@ohos.fileio.d.ts|
|Error code added|Class name: sourcefile;<br>Method or attribute name: declare function lstat(path: string, callback: AsyncCallback\<Stat>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function lstat(path: string, callback: AsyncCallback\<Stat>): void;<br>New version information: Parameter|@ohos.fileio.d.ts|
|Error code added|Class name: sourcefile;<br>Method or attribute name: declare function mkdir(path: string, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function mkdir(path: string, callback: AsyncCallback\<void>): void;<br>New version information: Parameter|@ohos.fileio.d.ts|
|Error code added|Class name: sourcefile;<br>Method or attribute name: declare function mkdir(path: string, mode: number, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function mkdir(path: string, mode: number, callback: AsyncCallback\<void>): void;<br>New version information: Parameter|@ohos.fileio.d.ts|
|Error code added|Class name: sourcefile;<br>Method or attribute name: declare function mkdtemp(prefix: string, callback: AsyncCallback\<string>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function mkdtemp(prefix: string, callback: AsyncCallback\<string>): void;<br>New version information: Parameter|@ohos.fileio.d.ts|
|Error code added|Class name: sourcefile;<br>Method or attribute name: declare function open(path: string, callback: AsyncCallback\<number>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function open(path: string, callback: AsyncCallback\<number>): void;<br>New version information: Parameter|@ohos.fileio.d.ts|
|Error code added|Class name: sourcefile;<br>Method or attribute name: declare function open(path: string, flags: number, callback: AsyncCallback\<number>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function open(path: string, flags: number, callback: AsyncCallback\<number>): void;<br>New version information: Parameter|@ohos.fileio.d.ts|
|Error code added|Class name: sourcefile;<br>Method or attribute name: declare function open(path: string, flags: number, mode: number, callback: AsyncCallback\<number>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function open(path: string, flags: number, mode: number, callback: AsyncCallback\<number>): void;<br>New version information: Parameter|@ohos.fileio.d.ts|
|Error code added|Class name: sourcefile;<br>Method or attribute name: declare function opendir(path: string, callback: AsyncCallback\<Dir>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function opendir(path: string, callback: AsyncCallback\<Dir>): void;<br>New version information: Parameter|@ohos.fileio.d.ts|
|Error code added|Class name: sourcefile;<br>Method or attribute name: declare function readText(<br> filePath: string,<br> options: {<br> position?: number;<br> length?: number;<br> encoding?: string;<br> },<br> callback: AsyncCallback\<string><br>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function readText(<br> filePath: string,<br> options: {<br> position?: number;<br> length?: number;<br> encoding?: string;<br> },<br> callback: AsyncCallback\<string><br>): void;<br>New version information: Parameter|@ohos.fileio.d.ts|
|Error code added|Class name: sourcefile;<br>Method or attribute name: declare function read(fd: number, buffer: ArrayBuffer, callback: AsyncCallback\<ReadOut>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function read(fd: number, buffer: ArrayBuffer, callback: AsyncCallback\<ReadOut>): void;<br>New version information: Parameter|@ohos.fileio.d.ts|
|Error code added|Class name: sourcefile;<br>Method or attribute name: declare function read(<br> fd: number,<br> buffer: ArrayBuffer,<br> options: {<br> offset?: number;<br> length?: number;<br> position?: number;<br> },<br> callback: AsyncCallback\<ReadOut><br>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function read(<br> fd: number,<br> buffer: ArrayBuffer,<br> options: {<br> offset?: number;<br> length?: number;<br> position?: number;<br> },<br> callback: AsyncCallback\<ReadOut><br>): void;<br>New version information: Parameter|@ohos.fileio.d.ts|
|Error code added|Class name: sourcefile;<br>Method or attribute name: declare function rename(oldPath: string, newPath: string, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function rename(oldPath: string, newPath: string, callback: AsyncCallback\<void>): void;<br>New version information: Parameter|@ohos.fileio.d.ts|
|Error code added|Class name: sourcefile;<br>Method or attribute name: declare function rmdir(path: string, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function rmdir(path: string, callback: AsyncCallback\<void>): void;<br>New version information: Parameter|@ohos.fileio.d.ts|
|Error code added|Class name: sourcefile;<br>Method or attribute name: declare function stat(path: string, callback: AsyncCallback\<Stat>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function stat(path: string, callback: AsyncCallback\<Stat>): void;<br>New version information: Parameter|@ohos.fileio.d.ts|
|Error code added|Class name: sourcefile;<br>Method or attribute name: declare function symlink(target: string, srcPath: string, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function symlink(target: string, srcPath: string, callback: AsyncCallback\<void>): void;<br>New version information: Parameter|@ohos.fileio.d.ts|
|Error code added|Class name: sourcefile;<br>Method or attribute name: declare function truncate(path: string, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function truncate(path: string, callback: AsyncCallback\<void>): void;<br>New version information: Parameter|@ohos.fileio.d.ts|
|Error code added|Class name: sourcefile;<br>Method or attribute name: declare function truncate(path: string, len: number, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function truncate(path: string, len: number, callback: AsyncCallback\<void>): void;<br>New version information: Parameter|@ohos.fileio.d.ts|
|Error code added|Class name: sourcefile;<br>Method or attribute name: declare function unlink(path: string, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function unlink(path: string, callback: AsyncCallback\<void>): void;<br>New version information: Parameter|@ohos.fileio.d.ts|
|Error code added|Class name: sourcefile;<br>Method or attribute name: declare function write(fd: number, buffer: ArrayBuffer \| string, callback: AsyncCallback\<number>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function write(fd: number, buffer: ArrayBuffer \| string, callback: AsyncCallback\<number>): void;<br>New version information: Parameter|@ohos.fileio.d.ts|
|Error code added|Class name: sourcefile;<br>Method or attribute name: declare function write(<br> fd: number,<br> buffer: ArrayBuffer \| string,<br> options: {<br> offset?: number;<br> length?: number;<br> position?: number;<br> encoding?: string;<br> },<br> callback: AsyncCallback\<number><br>): void;<br>Old version information: |Class name: sourcefile;<br>Method or attribute name: declare function write(<br> fd: number,<br> buffer: ArrayBuffer \| string,<br> options: {<br> offset?: number;<br> length?: number;<br> position?: number;<br> encoding?: string;<br> },<br> callback: AsyncCallback\<number><br>): void;<br>New version information: Parameter|@ohos.fileio.d.ts|
|Error code added|Class name: Dir;<br>Method or attribute name: read(callback: AsyncCallback\<Dirent>): void;<br>Old version information: |Class name: Dir;<br>Method or attribute name: read(callback: AsyncCallback\<Dirent>): void;<br>New version information: Parameter|@ohos.fileio.d.ts|
|Error code added|Class name: Dir;<br>Method or attribute name: close(callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: Dir;<br>Method or attribute name: close(callback: AsyncCallback\<void>): void;<br>New version information: close|@ohos.fileio.d.ts|
|Error code added|Class name: Stream;<br>Method or attribute name: close(callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: Stream;<br>Method or attribute name: close(callback: AsyncCallback\<void>): void;<br>New version information: close|@ohos.fileio.d.ts|
|Error code added|Class name: Stream;<br>Method or attribute name: flush(callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: Stream;<br>Method or attribute name: flush(callback: AsyncCallback\<void>): void;<br>New version information: Parameter|@ohos.fileio.d.ts|
|Error code added|Class name: Stream;<br>Method or attribute name: write(buffer: ArrayBuffer \| string, callback: AsyncCallback\<number>): void;<br>Old version information: |Class name: Stream;<br>Method or attribute name: write(buffer: ArrayBuffer \| string, callback: AsyncCallback\<number>): void;<br>New version information: Parameter|@ohos.fileio.d.ts|
|Error code added|Class name: Stream;<br>Method or attribute name: write(<br> buffer: ArrayBuffer \| string,<br> options: {<br> offset?: number;<br> length?: number;<br> position?: number;<br> encoding?: string;<br> },<br> callback: AsyncCallback\<number><br> ): void;<br>Old version information: |Class name: Stream;<br>Method or attribute name: write(<br> buffer: ArrayBuffer \| string,<br> options: {<br> offset?: number;<br> length?: number;<br> position?: number;<br> encoding?: string;<br> },<br> callback: AsyncCallback\<number><br> ): void;<br>New version information: Parameter|@ohos.fileio.d.ts|
|Error code added|Class name: Stream;<br>Method or attribute name: read(buffer: ArrayBuffer, callback: AsyncCallback\<ReadOut>): void;<br>Old version information: |Class name: Stream;<br>Method or attribute name: read(buffer: ArrayBuffer, callback: AsyncCallback\<ReadOut>): void;<br>New version information: Parameter|@ohos.fileio.d.ts|
|Error code added|Class name: Stream;<br>Method or attribute name: read(<br> buffer: ArrayBuffer,<br> options: {<br> position?: number;<br> offset?: number;<br> length?: number;<br> },<br> callback: AsyncCallback\<ReadOut><br> ): void;<br>Old version information: |Class name: Stream;<br>Method or attribute name: read(<br> buffer: ArrayBuffer,<br> options: {<br> position?: number;<br> offset?: number;<br> length?: number;<br> },<br> callback: AsyncCallback\<ReadOut><br> ): void;<br>New version information: Parameter|@ohos.fileio.d.ts|
|Error code added|Class name: Watcher;<br>Method or attribute name: stop(callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: Watcher;<br>Method or attribute name: stop(callback: AsyncCallback\<void>): void;<br>New version information: stop|@ohos.fileio.d.ts|
|Access level changed|Class name: storageStatistics;<br>Method or attribute name: function getTotalSizeOfVolume(volumeUuid: string): Promise\<number>;<br>Old version information: |Class name: storageStatistics;<br>Method or attribute name: function getTotalSizeOfVolume(volumeUuid: string): Promise\<number>;<br>New version information: systemapi|@ohos.file.storageStatistics.d.ts|
|Access level changed|Class name: storageStatistics;<br>Method or attribute name: function getFreeSizeOfVolume(volumeUuid: string): Promise\<number>;<br>Old version information: |Class name: storageStatistics;<br>Method or attribute name: function getFreeSizeOfVolume(volumeUuid: string): Promise\<number>;<br>New version information: systemapi|@ohos.file.storageStatistics.d.ts|
|Access level changed|Class name: storageStatistics;<br>Method or attribute name: function getBundleStats(packageName: string): Promise\<BundleStats>;<br>Old version information: |Class name: storageStatistics;<br>Method or attribute name: function getBundleStats(packageName: string): Promise\<BundleStats>;<br>New version information: systemapi|@ohos.file.storageStatistics.d.ts|
|Access level changed|Class name: storageStatistics;<br>Method or attribute name: function getSystemSize(): Promise\<number>;<br>Old version information: |Class name: storageStatistics;<br>Method or attribute name: function getSystemSize(): Promise\<number>;<br>New version information: systemapi|@ohos.file.storageStatistics.d.ts|
|Access level changed|Class name: storageStatistics;<br>Method or attribute name: function getUserStorageStats(callback: AsyncCallback\<StorageStats>): void;<br>Old version information: |Class name: storageStatistics;<br>Method or attribute name: function getUserStorageStats(callback: AsyncCallback\<StorageStats>): void;<br>New version information: systemapi|@ohos.file.storageStatistics.d.ts|
|Access level changed|Class name: storageStatistics;<br>Method or attribute name: function getUserStorageStats(userId: number, callback: AsyncCallback\<StorageStats>): void;<br>Old version information: |Class name: storageStatistics;<br>Method or attribute name: function getUserStorageStats(userId: number, callback: AsyncCallback\<StorageStats>): void;<br>New version information: systemapi|@ohos.file.storageStatistics.d.ts|
|Access level changed|Class name: storageStatistics;<br>Method or attribute name: function getTotalSize(): Promise\<number>;<br>Old version information: |Class name: storageStatistics;<br>Method or attribute name: function getTotalSize(): Promise\<number>;<br>New version information: systemapi|@ohos.file.storageStatistics.d.ts|
|Access level changed|Class name: storageStatistics;<br>Method or attribute name: function getFreeSize(): Promise\<number>;<br>Old version information: |Class name: storageStatistics;<br>Method or attribute name: function getFreeSize(): Promise\<number>;<br>New version information: systemapi|@ohos.file.storageStatistics.d.ts|
|Access level changed|Class name: volumeManager;<br>Method or attribute name: function getAllVolumes(): Promise\<Array\<Volume>>;<br>Old version information: |Class name: volumeManager;<br>Method or attribute name: function getAllVolumes(): Promise\<Array\<Volume>>;<br>New version information: systemapi|@ohos.file.volumeManager.d.ts|
|Access level changed|Class name: volumeManager;<br>Method or attribute name: function mount(volumeId: string): Promise\<void>;<br>Old version information: |Class name: volumeManager;<br>Method or attribute name: function mount(volumeId: string): Promise\<void>;<br>New version information: systemapi|@ohos.file.volumeManager.d.ts|
|Access level changed|Class name: volumeManager;<br>Method or attribute name: function unmount(volumeId: string): Promise\<void>;<br>Old version information: |Class name: volumeManager;<br>Method or attribute name: function unmount(volumeId: string): Promise\<void>;<br>New version information: systemapi|@ohos.file.volumeManager.d.ts|
|Access level changed|Class name: volumeManager;<br>Method or attribute name: function getVolumeByUuid(uuid: string): Promise\<Volume>;<br>Old version information: |Class name: volumeManager;<br>Method or attribute name: function getVolumeByUuid(uuid: string): Promise\<Volume>;<br>New version information: systemapi|@ohos.file.volumeManager.d.ts|
|Access level changed|Class name: volumeManager;<br>Method or attribute name: function getVolumeById(volumeId: string): Promise\<Volume>;<br>Old version information: |Class name: volumeManager;<br>Method or attribute name: function getVolumeById(volumeId: string): Promise\<Volume>;<br>New version information: systemapi|@ohos.file.volumeManager.d.ts|
|Access level changed|Class name: volumeManager;<br>Method or attribute name: function setVolumeDescription(uuid: string, description: string): Promise\<void>;<br>Old version information: |Class name: volumeManager;<br>Method or attribute name: function setVolumeDescription(uuid: string, description: string): Promise\<void>;<br>New version information: systemapi|@ohos.file.volumeManager.d.ts|
|Access level changed|Class name: volumeManager;<br>Method or attribute name: function format(volumeId: string, fsType: string): Promise\<void>;<br>Old version information: |Class name: volumeManager;<br>Method or attribute name: function format(volumeId: string, fsType: string): Promise\<void>;<br>New version information: systemapi|@ohos.file.volumeManager.d.ts|
|Access level changed|Class name: volumeManager;<br>Method or attribute name: function partition(diskId: string, type: number): Promise\<void>;<br>Old version information: |Class name: volumeManager;<br>Method or attribute name: function partition(diskId: string, type: number): Promise\<void>;<br>New version information: systemapi|@ohos.file.volumeManager.d.ts|
|Access level changed|Class name: Volume;<br>Method or attribute name: path: string;<br>Old version information: |Class name: Volume;<br>Method or attribute name: path: string;<br>New version information: systemapi|@ohos.file.volumeManager.d.ts|
|Permission changed|Class name: storageStatistics;<br>Method or attribute name: function getTotalSizeOfVolume(volumeUuid: string): Promise\<number>;<br>Old version information: |Class name: storageStatistics;<br>Method or attribute name: function getTotalSizeOfVolume(volumeUuid: string): Promise\<number>;<br>New version information: ohos.permission.STORAGE_MANAGER|@ohos.file.storageStatistics.d.ts|
|Permission changed|Class name: storageStatistics;<br>Method or attribute name: function getFreeSizeOfVolume(volumeUuid: string): Promise\<number>;<br>Old version information: |Class name: storageStatistics;<br>Method or attribute name: function getFreeSizeOfVolume(volumeUuid: string): Promise\<number>;<br>New version information: ohos.permission.STORAGE_MANAGER|@ohos.file.storageStatistics.d.ts|
|Permission changed|Class name: storageStatistics;<br>Method or attribute name: function getBundleStats(packageName: string): Promise\<BundleStats>;<br>Old version information: |Class name: storageStatistics;<br>Method or attribute name: function getBundleStats(packageName: string): Promise\<BundleStats>;<br>New version information: ohos.permission.STORAGE_MANAGER|@ohos.file.storageStatistics.d.ts|
|Permission changed|Class name: storageStatistics;<br>Method or attribute name: function getSystemSize(): Promise\<number>;<br>Old version information: |Class name: storageStatistics;<br>Method or attribute name: function getSystemSize(): Promise\<number>;<br>New version information: ohos.permission.STORAGE_MANAGER|@ohos.file.storageStatistics.d.ts|
|Permission changed|Class name: storageStatistics;<br>Method or attribute name: function getUserStorageStats(callback: AsyncCallback\<StorageStats>): void;<br>Old version information: |Class name: storageStatistics;<br>Method or attribute name: function getUserStorageStats(callback: AsyncCallback\<StorageStats>): void;<br>New version information: ohos.permission.STORAGE_MANAGER|@ohos.file.storageStatistics.d.ts|
|Permission changed|Class name: storageStatistics;<br>Method or attribute name: function getUserStorageStats(userId: number, callback: AsyncCallback\<StorageStats>): void;<br>Old version information: |Class name: storageStatistics;<br>Method or attribute name: function getUserStorageStats(userId: number, callback: AsyncCallback\<StorageStats>): void;<br>New version information: ohos.permission.STORAGE_MANAGER|@ohos.file.storageStatistics.d.ts|
|Permission changed|Class name: storageStatistics;<br>Method or attribute name: function getTotalSize(): Promise\<number>;<br>Old version information: |Class name: storageStatistics;<br>Method or attribute name: function getTotalSize(): Promise\<number>;<br>New version information: ohos.permission.STORAGE_MANAGER|@ohos.file.storageStatistics.d.ts|
|Permission changed|Class name: storageStatistics;<br>Method or attribute name: function getFreeSize(): Promise\<number>;<br>Old version information: |Class name: storageStatistics;<br>Method or attribute name: function getFreeSize(): Promise\<number>;<br>New version information: ohos.permission.STORAGE_MANAGER|@ohos.file.storageStatistics.d.ts|
|Permission changed|Class name: volumeManager;<br>Method or attribute name: function getAllVolumes(): Promise\<Array\<Volume>>;<br>Old version information: |Class name: volumeManager;<br>Method or attribute name: function getAllVolumes(): Promise\<Array\<Volume>>;<br>New version information: ohos.permission.STORAGE_MANAGER|@ohos.file.volumeManager.d.ts|
|Permission changed|Class name: volumeManager;<br>Method or attribute name: function mount(volumeId: string): Promise\<void>;<br>Old version information: |Class name: volumeManager;<br>Method or attribute name: function mount(volumeId: string): Promise\<void>;<br>New version information: ohos.permission.MOUNT_UNMOUNT_MANAGER|@ohos.file.volumeManager.d.ts|
|Permission changed|Class name: volumeManager;<br>Method or attribute name: function unmount(volumeId: string): Promise\<void>;<br>Old version information: |Class name: volumeManager;<br>Method or attribute name: function unmount(volumeId: string): Promise\<void>;<br>New version information: ohos.permission.MOUNT_UNMOUNT_MANAGER|@ohos.file.volumeManager.d.ts|
|Permission changed|Class name: volumeManager;<br>Method or attribute name: function getVolumeByUuid(uuid: string): Promise\<Volume>;<br>Old version information: |Class name: volumeManager;<br>Method or attribute name: function getVolumeByUuid(uuid: string): Promise\<Volume>;<br>New version information: ohos.permission.STORAGE_MANAGER|@ohos.file.volumeManager.d.ts|
|Permission changed|Class name: volumeManager;<br>Method or attribute name: function getVolumeById(volumeId: string): Promise\<Volume>;<br>Old version information: |Class name: volumeManager;<br>Method or attribute name: function getVolumeById(volumeId: string): Promise\<Volume>;<br>New version information: ohos.permission.STORAGE_MANAGER|@ohos.file.volumeManager.d.ts|
|Permission changed|Class name: volumeManager;<br>Method or attribute name: function setVolumeDescription(uuid: string, description: string): Promise\<void>;<br>Old version information: |Class name: volumeManager;<br>Method or attribute name: function setVolumeDescription(uuid: string, description: string): Promise\<void>;<br>New version information: ohos.permission.MOUNT_UNMOUNT_MANAGER|@ohos.file.volumeManager.d.ts|
|Permission changed|Class name: volumeManager;<br>Method or attribute name: function format(volumeId: string, fsType: string): Promise\<void>;<br>Old version information: |Class name: volumeManager;<br>Method or attribute name: function format(volumeId: string, fsType: string): Promise\<void>;<br>New version information: ohos.permission.MOUNT_FORMAT_MANAGER|@ohos.file.volumeManager.d.ts|
|Permission changed|Class name: volumeManager;<br>Method or attribute name: function partition(diskId: string, type: number): Promise\<void>;<br>Old version information: |Class name: volumeManager;<br>Method or attribute name: function partition(diskId: string, type: number): Promise\<void>;<br>New version information: ohos.permission.MOUNT_FORMAT_MANAGER|@ohos.file.volumeManager.d.ts|
|Permission changed|Class name: fileShare;<br>Method or attribute name: function grantUriPermission(<br> uri: string,<br> bundleName: string,<br> flag: wantConstant.Flags,<br> callback: AsyncCallback\<void><br> ): void;<br>Old version information: |Class name: fileShare;<br>Method or attribute name: function grantUriPermission(<br> uri: string,<br> bundleName: string,<br> flag: wantConstant.Flags,<br> callback: AsyncCallback\<void><br> ): void;<br>New version information: ohos.permission.WRITE_MEDIA|@ohos.fileshare.d.ts|
|Permission changed|Class name: fileShare;<br>Method or attribute name: function grantUriPermission(uri: string, bundleName: string, flag: wantConstant.Flags): Promise\<void>;<br>Old version information: |Class name: fileShare;<br>Method or attribute name: function grantUriPermission(uri: string, bundleName: string, flag: wantConstant.Flags): Promise\<void>;<br>New version information: ohos.permission.WRITE_MEDIA|@ohos.fileshare.d.ts|
|Type changed|Class name: PhotoSelectOptions;<br>Method or attribute name: MIMEType?: PhotoViewMIMETypes;<br>Old version information: PhotoViewMIMETypes|Class name: PhotoSelectOptions;<br>Method or attribute name: MIMEType?: PhotoViewMIMETypes;<br>New version information: ?PhotoViewMIMETypes|@ohos.file.picker.d.ts|
|Type changed|Class name: PhotoSelectOptions;<br>Method or attribute name: maxSelectNumber?: number;<br>Old version information: number|Class name: PhotoSelectOptions;<br>Method or attribute name: maxSelectNumber?: number;<br>New version information: ?number|@ohos.file.picker.d.ts|
|Type changed|Class name: PhotoSaveOptions;<br>Method or attribute name: newFileNames?: Array\<string>;<br>Old version information: Array\<string>|Class name: PhotoSaveOptions;<br>Method or attribute name: newFileNames?: Array\<string>;<br>New version information: ?Array\<string>|@ohos.file.picker.d.ts|
|Type changed|Class name: DocumentSaveOptions;<br>Method or attribute name: newFileNames?: Array\<string>;<br>Old version information: Array\<string>|Class name: DocumentSaveOptions;<br>Method or attribute name: newFileNames?: Array\<string>;<br>New version information: ?Array\<string>|@ohos.file.picker.d.ts|
|Type changed|Class name: AudioSaveOptions;<br>Method or attribute name: newFileNames?: Array\<string>;<br>Old version information: Array\<string>|Class name: AudioSaveOptions;<br>Method or attribute name: newFileNames?: Array\<string>;<br>New version information: ?Array\<string>|@ohos.file.picker.d.ts|
| Change Type | Old Version | New Version | d.ts File |
| ---- | ------ | ------ | -------- |
|Added|NA|Class name: geoLocationManager;<br>Method or attribute name: function on(type: 'locatingRequiredDataChange', config: LocatingRequiredDataConfig, callback: Callback\<Array\<LocatingRequiredData>>): void;|@ohos.geoLocationManager.d.ts|
|Added|NA|Class name: geoLocationManager;<br>Method or attribute name: function off(type: 'locatingRequiredDataChange', callback?: Callback\<Array\<LocatingRequiredData>>): void;|@ohos.geoLocationManager.d.ts|
|Added|NA|Class name: geoLocationManager;<br>Method or attribute name: function getLocatingRequiredData(config: LocatingRequiredDataConfig): Promise\<Array\<LocatingRequiredData>>;|@ohos.geoLocationManager.d.ts|
|Added|NA|Class name: LocatingRequiredDataConfig;<br>Method or attribute name: type: LocatingRequiredDataType;|@ohos.geoLocationManager.d.ts|
|Added|NA|Class name: LocatingRequiredDataConfig;<br>Method or attribute name: needStartScan: boolean;|@ohos.geoLocationManager.d.ts|
|Added|NA|Class name: LocatingRequiredDataConfig;<br>Method or attribute name: scanInterval?: number;|@ohos.geoLocationManager.d.ts|
|Added|NA|Class name: LocatingRequiredDataConfig;<br>Method or attribute name: scanTimeout?: number;|@ohos.geoLocationManager.d.ts|
|Added|NA|Class name: LocatingRequiredData;<br>Method or attribute name: wifiData?: WifiScanInfo;|@ohos.geoLocationManager.d.ts|
|Added|NA|Class name: LocatingRequiredData;<br>Method or attribute name: bluetoothData?: BluetoothScanInfo;|@ohos.geoLocationManager.d.ts|
|Added|NA|Class name: WifiScanInfo;<br>Method or attribute name: ssid: string;|@ohos.geoLocationManager.d.ts|
|Added|NA|Class name: WifiScanInfo;<br>Method or attribute name: bssid: string;|@ohos.geoLocationManager.d.ts|
|Added|NA|Class name: WifiScanInfo;<br>Method or attribute name: rssi: number;|@ohos.geoLocationManager.d.ts|
|Added|NA|Class name: BluetoothScanInfo;<br>Method or attribute name: rssi: number;|@ohos.geoLocationManager.d.ts|
|Added|NA|Class name: WifiScanInfo;<br>Method or attribute name: frequency: number;|@ohos.geoLocationManager.d.ts|
|Added|NA|Class name: WifiScanInfo;<br>Method or attribute name: timestamp: number;|@ohos.geoLocationManager.d.ts|
|Added|NA|Class name: BluetoothScanInfo;<br>Method or attribute name: timestamp: number;|@ohos.geoLocationManager.d.ts|
|Added|NA|Class name: BluetoothScanInfo;<br>Method or attribute name: deviceName: string;|@ohos.geoLocationManager.d.ts|
|Added|NA|Class name: BluetoothScanInfo;<br>Method or attribute name: macAddress: string;|@ohos.geoLocationManager.d.ts|
|Added|NA|Class name: LocatingRequiredDataType;<br>Method or attribute name: WIFI = 1|@ohos.geoLocationManager.d.ts|
|Added|NA|Class name: LocatingRequiredDataType;<br>Method or attribute name: BLUETOOTH|@ohos.geoLocationManager.d.ts|
| Change Type | Old Version | New Version | d.ts File |
| ---- | ------ | ------ | -------- |
|Added|NA|Class name: SuggestionType;<br>Method or attribute name: SUGGESTION_TYPE_NONE = 0|@ohos.i18n.d.ts|
|Added|NA|Class name: SuggestionType;<br>Method or attribute name: SUGGESTION_TYPE_RELATED = 1|@ohos.i18n.d.ts|
|Added|NA|Class name: SuggestionType;<br>Method or attribute name: SUGGESTION_TYPE_SIM = 2|@ohos.i18n.d.ts|
|Added|NA|Class name: SortOptions;<br>Method or attribute name: locale?: string;|@ohos.i18n.d.ts|
|Added|NA|Class name: SortOptions;<br>Method or attribute name: isUseLocalName?: boolean;|@ohos.i18n.d.ts|
|Added|NA|Class name: SortOptions;<br>Method or attribute name: isSuggestedFirst?: boolean;|@ohos.i18n.d.ts|
|Added|NA|Class name: LocaleItem;<br>Method or attribute name: id: string;|@ohos.i18n.d.ts|
|Added|NA|Class name: LocaleItem;<br>Method or attribute name: suggestionType: SuggestionType;|@ohos.i18n.d.ts|
|Added|NA|Class name: LocaleItem;<br>Method or attribute name: displayName: string;|@ohos.i18n.d.ts|
|Added|NA|Class name: LocaleItem;<br>Method or attribute name: localName?: string;|@ohos.i18n.d.ts|
|Added|NA|Class name: TimeZoneCityItem;<br>Method or attribute name: zoneId: string;|@ohos.i18n.d.ts|
|Added|NA|Class name: TimeZoneCityItem;<br>Method or attribute name: cityId: string;|@ohos.i18n.d.ts|
|Added|NA|Class name: TimeZoneCityItem;<br>Method or attribute name: cityDisplayName: string;|@ohos.i18n.d.ts|
|Added|NA|Class name: TimeZoneCityItem;<br>Method or attribute name: offset: number;|@ohos.i18n.d.ts|
|Added|NA|Class name: TimeZoneCityItem;<br>Method or attribute name: zoneDisplayName: string;|@ohos.i18n.d.ts|
|Added|NA|Class name: TimeZoneCityItem;<br>Method or attribute name: rawOffset?: number;|@ohos.i18n.d.ts|
|Added|NA|Class name: SystemLocaleManager;<br>Method or attribute name: constructor();|@ohos.i18n.d.ts|
|Added|NA|Class name: SystemLocaleManager;<br>Method or attribute name: getLanguageInfoArray(languages: Array\<string>, options?: SortOptions): Array\<LocaleItem>;|@ohos.i18n.d.ts|
|Added|NA|Class name: SystemLocaleManager;<br>Method or attribute name: getRegionInfoArray(regions: Array\<string>, options?: SortOptions): Array\<LocaleItem>;|@ohos.i18n.d.ts|
|Added|NA|Class name: SystemLocaleManager;<br>Method or attribute name: static getTimeZoneCityItemArray(): Array\<TimeZoneCityItem>;|@ohos.i18n.d.ts|
|Added|NA|Class name: resourceManager;<br>Method or attribute name: export function getSystemResourceManager(): ResourceManager;|@ohos.resourceManager.d.ts|
|Added|NA|Class name: ResourceManager;<br>Method or attribute name: getColor(resId: number, callback: _AsyncCallback\<number>): void;|@ohos.resourceManager.d.ts|
|Added|NA|Class name: ResourceManager;<br>Method or attribute name: getColor(resId: number): Promise\<number>;|@ohos.resourceManager.d.ts|
|Added|NA|Class name: ResourceManager;<br>Method or attribute name: getColor(resource: Resource, callback: _AsyncCallback\<number>): void;|@ohos.resourceManager.d.ts|
|Added|NA|Class name: ResourceManager;<br>Method or attribute name: getColor(resource: Resource): Promise\<number>;|@ohos.resourceManager.d.ts|
|Added|NA|Class name: ResourceManager;<br>Method or attribute name: getColorByName(resName: string, callback: _AsyncCallback\<number>): void;|@ohos.resourceManager.d.ts|
|Added|NA|Class name: ResourceManager;<br>Method or attribute name: getColorByName(resName: string): Promise\<number>;|@ohos.resourceManager.d.ts|
|Added|NA|Class name: ResourceManager;<br>Method or attribute name: getColorSync(resId: number) : number;|@ohos.resourceManager.d.ts|
|Added|NA|Class name: ResourceManager;<br>Method or attribute name: getColorSync(resource: Resource) : number;|@ohos.resourceManager.d.ts|
|Added|NA|Class name: ResourceManager;<br>Method or attribute name: getColorByNameSync(resName: string) : number;|@ohos.resourceManager.d.ts|
|Added|NA|Class name: ResourceManager;<br>Method or attribute name: addResource(path: string) : void;|@ohos.resourceManager.d.ts|
|Added|NA|Class name: ResourceManager;<br>Method or attribute name: removeResource(path: string) : void;|@ohos.resourceManager.d.ts|
| Change Type | Old Version | New Version | d.ts File |
| ---- | ------ | ------ | -------- |
|Deleted|Class name: InputMethodSetting;<br>Method or attribute name: on(type: 'imeShow' \| 'imeHide', callback: (info: Array\<InputWindowInfo>) => void): void;|NA|@ohos.inputMethod.d.ts|
|Deleted|Class name: InputMethodSetting;<br>Method or attribute name: off(type: 'imeShow' \| 'imeHide', callback?: (info: Array\<InputWindowInfo>) => void): void;|NA|@ohos.inputMethod.d.ts|
|Deleted|Class name: InputMethodController;<br>Method or attribute name: on(type: 'deleteLeft' \| 'deleteRight', callback: (length: number) => void): void;|NA|@ohos.inputMethod.d.ts|
|Deleted|Class name: InputMethodController;<br>Method or attribute name: on(type: 'sendKeyboardStatus', callback: (keyBoardStatus: KeyboardStatus) => void): void;|NA|@ohos.inputMethod.d.ts|
|Deleted|Class name: InputMethodController;<br>Method or attribute name: off(type: 'selectByRange'): void;|NA|@ohos.inputMethod.d.ts|
|Deleted|Class name: InputMethodController;<br>Method or attribute name: off(type: 'selectByMovement'): void;|NA|@ohos.inputMethod.d.ts|
|Deleted|Class name: InputMethodController;<br>Method or attribute name: off(type: 'insertText'): void;|NA|@ohos.inputMethod.d.ts|
|Deleted|Class name: InputMethodController;<br>Method or attribute name: off(type: 'deleteLeft' \| 'deleteRight'): void;|NA|@ohos.inputMethod.d.ts|
|Deleted|Class name: InputMethodController;<br>Method or attribute name: off(type: 'sendKeyboardStatus'): void;|NA|@ohos.inputMethod.d.ts|
|Deleted|Class name: InputMethodController;<br>Method or attribute name: off(type: 'sendFunctionKey'): void;|NA|@ohos.inputMethod.d.ts|
|Deleted|Class name: InputMethodController;<br>Method or attribute name: off(type: 'moveCursor'): void;|NA|@ohos.inputMethod.d.ts|
|Deleted|Class name: InputMethodController;<br>Method or attribute name: off(type: 'handleExtendAction'): void;|NA|@ohos.inputMethod.d.ts|
|Added|NA|Class name: InputMethodSetting;<br>Method or attribute name: on(type: 'imeShow', callback: (info: Array\<InputWindowInfo>) => void): void;|@ohos.inputMethod.d.ts|
|Added|NA|Class name: InputMethodSetting;<br>Method or attribute name: on(type: 'imeHide', callback: (info: Array\<InputWindowInfo>) => void): void;|@ohos.inputMethod.d.ts|
|Added|NA|Class name: InputMethodSetting;<br>Method or attribute name: off(type: 'imeShow', callback?: (info: Array\<InputWindowInfo>) => void): void;|@ohos.inputMethod.d.ts|
|Added|NA|Class name: InputMethodSetting;<br>Method or attribute name: off(type: 'imeHide', callback?: (info: Array\<InputWindowInfo>) => void): void;|@ohos.inputMethod.d.ts|
|Added|NA|Class name: InputMethodController;<br>Method or attribute name: on(type: 'deleteLeft', callback: (length: number) => void): void;|@ohos.inputMethod.d.ts|
|Added|NA|Class name: InputMethodController;<br>Method or attribute name: on(type: 'deleteRight', callback: (length: number) => void): void;|@ohos.inputMethod.d.ts|
|Added|NA|Class name: InputMethodController;<br>Method or attribute name: on(type: 'sendKeyboardStatus', callback: (keyboardStatus: KeyboardStatus) => void): void;|@ohos.inputMethod.d.ts|
|Added|NA|Class name: InputMethodController;<br>Method or attribute name: on(type: 'getLeftTextOfCursor', callback: (length: number) => string): void;|@ohos.inputMethod.d.ts|
|Added|NA|Class name: InputMethodController;<br>Method or attribute name: on(type: 'getRightTextOfCursor', callback: (length: number) => string): void;|@ohos.inputMethod.d.ts|
|Added|NA|Class name: InputMethodController;<br>Method or attribute name: on(type: 'getTextIndexAtCursor', callback: () => number): void;|@ohos.inputMethod.d.ts|
|Added|NA|Class name: InputMethodController;<br>Method or attribute name: off(type: 'selectByRange', callback?: Callback\<Range>): void;|@ohos.inputMethod.d.ts|
|Added|NA|Class name: InputMethodController;<br>Method or attribute name: off(type: 'selectByMovement', callback?: Callback\<Movement>): void;|@ohos.inputMethod.d.ts|
|Added|NA|Class name: InputMethodController;<br>Method or attribute name: off(type: 'insertText', callback?: (text: string) => void): void;|@ohos.inputMethod.d.ts|
|Added|NA|Class name: InputMethodController;<br>Method or attribute name: off(type: 'deleteLeft', callback?: (length: number) => void): void;|@ohos.inputMethod.d.ts|
|Added|NA|Class name: InputMethodController;<br>Method or attribute name: off(type: 'deleteRight', callback?: (length: number) => void): void;|@ohos.inputMethod.d.ts|
|Added|NA|Class name: InputMethodController;<br>Method or attribute name: off(type: 'sendKeyboardStatus', callback?: (keyboardStatus: KeyboardStatus) => void): void;|@ohos.inputMethod.d.ts|
|Added|NA|Class name: InputMethodController;<br>Method or attribute name: off(type: 'sendFunctionKey', callback?: (functionKey: FunctionKey) => void): void;|@ohos.inputMethod.d.ts|
|Added|NA|Class name: InputMethodController;<br>Method or attribute name: off(type: 'moveCursor', callback?: (direction: Direction) => void): void;|@ohos.inputMethod.d.ts|
|Added|NA|Class name: InputMethodController;<br>Method or attribute name: off(type: 'handleExtendAction', callback?: (action: ExtendAction) => void): void;|@ohos.inputMethod.d.ts|
|Added|NA|Class name: InputMethodController;<br>Method or attribute name: off(type: 'getLeftTextOfCursor', callback?: (length: number) => string): void;|@ohos.inputMethod.d.ts|
|Added|NA|Class name: InputMethodController;<br>Method or attribute name: off(type: 'getRightTextOfCursor', callback?: (length: number) => string): void;|@ohos.inputMethod.d.ts|
|Added|NA|Class name: InputMethodController;<br>Method or attribute name: off(type: 'getTextIndexAtCursor', callback?: () => number): void;|@ohos.inputMethod.d.ts|
|Added|NA|Class name: TextConfig;<br>Method or attribute name: cursorInfo?: CursorInfo;|@ohos.inputMethod.d.ts|
|Added|NA|Class name: TextConfig;<br>Method or attribute name: selection?: Range;|@ohos.inputMethod.d.ts|
|Added|NA|Class name: TextConfig;<br>Method or attribute name: windowId?: number;|@ohos.inputMethod.d.ts|
|Added|NA|Class name: KeyboardDelegate;<br>Method or attribute name: on(type: 'keyEvent', callback: (event: InputKeyEvent) => boolean): void;|@ohos.inputMethodEngine.d.ts|
|Added|NA|Class name: KeyboardDelegate;<br>Method or attribute name: on(type: 'editorAttributeChanged', callback: (attr: EditorAttribute) => void): void;|@ohos.inputMethodEngine.d.ts|
|Added|NA|Class name: KeyboardDelegate;<br>Method or attribute name: off(type: 'keyEvent', callback?: (event: InputKeyEvent) => boolean): void;|@ohos.inputMethodEngine.d.ts|
|Added|NA|Class name: KeyboardDelegate;<br>Method or attribute name: off(type: 'editorAttributeChanged', callback?: (attr: EditorAttribute) => void): void;|@ohos.inputMethodEngine.d.ts|
|Added|NA|Class name: wallpaper;<br>Method or attribute name: function setCustomWallpaper(source: string, wallpaperType: WallpaperType, callback: AsyncCallback\<void>): void;|@ohos.wallpaper.d.ts|
|Added|NA|Class name: wallpaper;<br>Method or attribute name: function setCustomWallpaper(source: string, wallpaperType: WallpaperType): Promise\<void>;|@ohos.wallpaper.d.ts|
|Added|NA|Class name: WallpaperExtensionAbility;<br>Method or attribute name: onCreate(want: object): void;|@ohos.WallpaperExtensionAbility.d.ts|
|Added|NA|Class name: WallpaperExtensionAbility;<br>Method or attribute name: onWallpaperChange(wallpaperType: number): void;|@ohos.WallpaperExtensionAbility.d.ts|
|Added|NA|Class name: WallpaperExtensionAbility;<br>Method or attribute name: onDestroy(): void;|@ohos.WallpaperExtensionAbility.d.ts|
|Error code changed|Class name: wallpaper;<br>Method or attribute name: function off(<br><br> type: 'wallpaperChange',<br><br> callback?: (wallpaperType: WallpaperType, resourceType: WallpaperResourceType, uri?: string) => void<br><br> ): void;<br>Old version information: 202|Class name: wallpaper;<br>Method or attribute name: function off(<br><br> type: 'wallpaperChange',<br><br> callback?: (wallpaperType: WallpaperType, resourceType: WallpaperResourceType, uri?: string) => void<br><br> ): void;<br>New version information: 401,202|@ohos.wallpaper.d.ts|
|Type changed|Class name: InputMethodProperty;<br>Method or attribute name: readonly labelId?: number;<br>Old version information: |Class name: InputMethodProperty;<br>Method or attribute name: readonly labelId?: number;<br>New version information: ?number|@ohos.inputMethod.d.ts|
|Type changed|Class name: InputMethodProperty;<br>Method or attribute name: readonly iconId?: number;<br>Old version information: |Class name: InputMethodProperty;<br>Method or attribute name: readonly iconId?: number;<br>New version information: ?number|@ohos.inputMethod.d.ts|
|Type changed|Class name: Movement;<br>Method or attribute name: direction: Direction;<br>Old version information: number|Class name: Movement;<br>Method or attribute name: direction: Direction;<br>New version information: Direction|@ohos.inputMethod.d.ts|
|Type changed|Class name: TextConfig;<br>Method or attribute name: inputAttribute: InputAttribute;<br>Old version information: |Class name: TextConfig;<br>Method or attribute name: inputAttribute: InputAttribute;<br>New version information: InputAttribute|@ohos.inputMethod.d.ts|
|Type changed|Class name: Movement;<br>Method or attribute name: direction: Direction;<br>Old version information: number|Class name: Movement;<br>Method or attribute name: direction: Direction;<br>New version information: Direction|@ohos.inputMethodEngine.d.ts|
|Type changed|Class name: InputMethodSubtype;<br>Method or attribute name: readonly labelId?: number;<br>Old version information: |Class name: InputMethodSubtype;<br>Method or attribute name: readonly labelId?: number;<br>New version information: ?number|@ohos.InputMethodSubtype.d.ts|
|Function changed|Class name: Panel;<br>Method or attribute name: on(type: 'show' \| 'hide', callback: () => void): void;|Class name: Panel;<br>Method or attribute name: on(type: 'show', callback: () => void): void;|@ohos.inputMethodEngine.d.ts|
|Function changed|Class name: Panel;<br>Method or attribute name: on(type: 'show' \| 'hide', callback: () => void): void;|Class name: Panel;<br>Method or attribute name: on(type: 'hide', callback: () => void): void;|@ohos.inputMethodEngine.d.ts|
|Function changed|Class name: Panel;<br>Method or attribute name: off(type: 'show' \| 'hide', callback?: () => void): void;|Class name: Panel;<br>Method or attribute name: off(type: 'show', callback?: () => void): void;|@ohos.inputMethodEngine.d.ts|
|Function changed|Class name: Panel;<br>Method or attribute name: off(type: 'show' \| 'hide', callback?: () => void): void;|Class name: Panel;<br>Method or attribute name: off(type: 'hide', callback?: () => void): void;|@ohos.inputMethodEngine.d.ts|
|Function changed|Class name: wallpaper;<br>Method or attribute name: function on(<br><br> type: 'wallpaperChange',<br><br> callback: (wallpaperType: WallpaperType, resourceType: WallpaperResourceType) => void<br><br> ): void;|Class name: wallpaper;<br>Method or attribute name: function on(<br><br> type: 'wallpaperChange',<br><br> callback: (wallpaperType: WallpaperType, resourceType: WallpaperResourceType, uri?: string) => void<br><br> ): void;|@ohos.wallpaper.d.ts|
|Function changed|Class name: wallpaper;<br>Method or attribute name: function off(<br><br> type: 'wallpaperChange',<br><br> callback?: (wallpaperType: WallpaperType, resourceType: WallpaperResourceType) => void<br><br> ): void;|Class name: wallpaper;<br>Method or attribute name: function off(<br><br> type: 'wallpaperChange',<br><br> callback?: (wallpaperType: WallpaperType, resourceType: WallpaperResourceType, uri?: string) => void<br><br> ): void;|@ohos.wallpaper.d.ts|
| Change Type | Old Version | New Version | d.ts File |
| ---- | ------ | ------ | -------- |
|Added|NA|Class name: CooperateMsg;<br>Method or attribute name: COOPERATE_SESSION_DISCONNECTED = 7|@ohos.cooperate.d.ts|
|Added|NA|Class name: dragInteraction;<br>Method or attribute name: function on(type: 'drag', callback: Callback\<DragState>): void;|@ohos.deviceStatus.dragInteraction.d.ts|
|Added|NA|Class name: dragInteraction;<br>Method or attribute name: function off(type: 'drag', callback?: Callback\<DragState>): void;|@ohos.deviceStatus.dragInteraction.d.ts|
|Added|NA|Class name: DragState;<br>Method or attribute name: MSG_DRAG_STATE_START = 1|@ohos.deviceStatus.dragInteraction.d.ts|
|Added|NA|Class name: DragState;<br>Method or attribute name: MSG_DRAG_STATE_STOP = 2|@ohos.deviceStatus.dragInteraction.d.ts|
|Added|NA|Class name: DragState;<br>Method or attribute name: MSG_DRAG_STATE_CANCEL = 3|@ohos.deviceStatus.dragInteraction.d.ts|
|Function changed|Class name: CooperateMsg;<br>Method or attribute name: COOPERATE_PREPARE|Class name: CooperateMsg;<br>Method or attribute name: COOPERATE_PREPARE = 0|@ohos.cooperate.d.ts|
|Function changed|Class name: CooperateMsg;<br>Method or attribute name: COOPERATE_UNPREPARE|Class name: CooperateMsg;<br>Method or attribute name: COOPERATE_UNPREPARE = 1|@ohos.cooperate.d.ts|
|Function changed|Class name: CooperateMsg;<br>Method or attribute name: COOPERATE_ACTIVATE|Class name: CooperateMsg;<br>Method or attribute name: COOPERATE_ACTIVATE = 2|@ohos.cooperate.d.ts|
|Function changed|Class name: CooperateMsg;<br>Method or attribute name: COOPERATE_ACTIVATE_SUCCESS|Class name: CooperateMsg;<br>Method or attribute name: COOPERATE_ACTIVATE_SUCCESS = 3|@ohos.cooperate.d.ts|
|Function changed|Class name: CooperateMsg;<br>Method or attribute name: COOPERATE_ACTIVATE_FAIL|Class name: CooperateMsg;<br>Method or attribute name: COOPERATE_ACTIVATE_FAIL = 4|@ohos.cooperate.d.ts|
|Function changed|Class name: CooperateMsg;<br>Method or attribute name: COOPERATE_DEACTIVATE_SUCCESS|Class name: CooperateMsg;<br>Method or attribute name: COOPERATE_DEACTIVATE_SUCCESS = 5|@ohos.cooperate.d.ts|
|Function changed|Class name: CooperateMsg;<br>Method or attribute name: COOPERATE_DEACTIVATE_FAIL|Class name: CooperateMsg;<br>Method or attribute name: COOPERATE_DEACTIVATE_FAIL = 6|@ohos.cooperate.d.ts|
| Change Type | Old Version | New Version | d.ts File |
| ---- | ------ | ------ | -------- |
|Added|NA|Class name: Pinch;<br>Method or attribute name: type: ActionType;|@ohos.multimodalInput.gestureEvent.d.ts|
|Added|NA|Class name: ThreeFingersSwipe;<br>Method or attribute name: type: ActionType;|@ohos.multimodalInput.gestureEvent.d.ts|
|Added|NA|Class name: FourFingersSwipe;<br>Method or attribute name: type: ActionType;|@ohos.multimodalInput.gestureEvent.d.ts|
|Added|NA|Class name: Pinch;<br>Method or attribute name: scale: number;|@ohos.multimodalInput.gestureEvent.d.ts|
|Added|NA|Class name: ThreeFingersSwipe;<br>Method or attribute name: x: number;|@ohos.multimodalInput.gestureEvent.d.ts|
|Added|NA|Class name: FourFingersSwipe;<br>Method or attribute name: x: number;|@ohos.multimodalInput.gestureEvent.d.ts|
|Added|NA|Class name: ThreeFingersSwipe;<br>Method or attribute name: y: number;|@ohos.multimodalInput.gestureEvent.d.ts|
|Added|NA|Class name: FourFingersSwipe;<br>Method or attribute name: y: number;|@ohos.multimodalInput.gestureEvent.d.ts|
|Added|NA|Class name: ActionType;<br>Method or attribute name: CANCEL = 0|@ohos.multimodalInput.gestureEvent.d.ts|
|Added|NA|Class name: ActionType;<br>Method or attribute name: BEGIN = 1|@ohos.multimodalInput.gestureEvent.d.ts|
|Added|NA|Class name: ActionType;<br>Method or attribute name: UPDATE = 2|@ohos.multimodalInput.gestureEvent.d.ts|
|Added|NA|Class name: ActionType;<br>Method or attribute name: END = 3|@ohos.multimodalInput.gestureEvent.d.ts|
|Added|NA|Class name: inputDevice;<br>Method or attribute name: function setKeyboardRepeatDelay(delay: number, callback: AsyncCallback\<void>): void;|@ohos.multimodalInput.inputDevice.d.ts|
|Added|NA|Class name: inputDevice;<br>Method or attribute name: function setKeyboardRepeatDelay(delay: number): Promise\<void>;|@ohos.multimodalInput.inputDevice.d.ts|
|Added|NA|Class name: inputDevice;<br>Method or attribute name: function getKeyboardRepeatDelay(callback: AsyncCallback\<number>): void;|@ohos.multimodalInput.inputDevice.d.ts|
|Added|NA|Class name: inputDevice;<br>Method or attribute name: function getKeyboardRepeatDelay(): Promise\<number>;|@ohos.multimodalInput.inputDevice.d.ts|
|Added|NA|Class name: inputDevice;<br>Method or attribute name: function setKeyboardRepeatRate(rate: number, callback: AsyncCallback\<void>): void;|@ohos.multimodalInput.inputDevice.d.ts|
|Added|NA|Class name: inputDevice;<br>Method or attribute name: function setKeyboardRepeatRate(rate: number): Promise\<void>;|@ohos.multimodalInput.inputDevice.d.ts|
|Added|NA|Class name: inputDevice;<br>Method or attribute name: function getKeyboardRepeatRate(callback: AsyncCallback\<number>): void;|@ohos.multimodalInput.inputDevice.d.ts|
|Added|NA|Class name: inputDevice;<br>Method or attribute name: function getKeyboardRepeatRate(): Promise\<number>;|@ohos.multimodalInput.inputDevice.d.ts|
|Added|NA|Class name: inputMonitor;<br>Method or attribute name: function on(type: 'pinch', receiver: Callback\<Pinch>): void;|@ohos.multimodalInput.inputMonitor.d.ts|
|Added|NA|Class name: inputMonitor;<br>Method or attribute name: function on(type: 'threeFingersSwipe', receiver: Callback\<ThreeFingersSwipe>): void;|@ohos.multimodalInput.inputMonitor.d.ts|
|Added|NA|Class name: inputMonitor;<br>Method or attribute name: function on(type: 'fourFingersSwipe', receiver: Callback\<FourFingersSwipe>): void;|@ohos.multimodalInput.inputMonitor.d.ts|
|Added|NA|Class name: inputMonitor;<br>Method or attribute name: function off(type: 'pinch', receiver?: Callback\<Pinch>): void;|@ohos.multimodalInput.inputMonitor.d.ts|
|Added|NA|Class name: inputMonitor;<br>Method or attribute name: function off(type: 'threeFingersSwipe', receiver?: Callback\<ThreeFingersSwipe>): void;|@ohos.multimodalInput.inputMonitor.d.ts|
|Added|NA|Class name: inputMonitor;<br>Method or attribute name: function off(type: 'fourFingersSwipe', receiver?: Callback\<FourFingersSwipe>): void;|@ohos.multimodalInput.inputMonitor.d.ts|
|Added|NA|Class name: IntentionCode;<br>Method or attribute name: INTENTION_UNKNOWN = -1|@ohos.multimodalInput.intentionCode.d.ts|
|Added|NA|Class name: IntentionCode;<br>Method or attribute name: INTENTION_UP = 1|@ohos.multimodalInput.intentionCode.d.ts|
|Added|NA|Class name: IntentionCode;<br>Method or attribute name: INTENTION_DOWN = 2|@ohos.multimodalInput.intentionCode.d.ts|
|Added|NA|Class name: IntentionCode;<br>Method or attribute name: INTENTION_LEFT = 3|@ohos.multimodalInput.intentionCode.d.ts|
|Added|NA|Class name: IntentionCode;<br>Method or attribute name: INTENTION_RIGHT = 4|@ohos.multimodalInput.intentionCode.d.ts|
|Added|NA|Class name: IntentionCode;<br>Method or attribute name: INTENTION_SELECT = 5|@ohos.multimodalInput.intentionCode.d.ts|
|Added|NA|Class name: IntentionCode;<br>Method or attribute name: INTENTION_ESCAPE = 6|@ohos.multimodalInput.intentionCode.d.ts|
|Added|NA|Class name: IntentionCode;<br>Method or attribute name: INTENTION_BACK = 7|@ohos.multimodalInput.intentionCode.d.ts|
|Added|NA|Class name: IntentionCode;<br>Method or attribute name: INTENTION_FORWARD = 8|@ohos.multimodalInput.intentionCode.d.ts|
|Added|NA|Class name: IntentionCode;<br>Method or attribute name: INTENTION_MENU = 9|@ohos.multimodalInput.intentionCode.d.ts|
|Added|NA|Class name: IntentionCode;<br>Method or attribute name: INTENTION_PAGE_UP = 11|@ohos.multimodalInput.intentionCode.d.ts|
|Added|NA|Class name: IntentionCode;<br>Method or attribute name: INTENTION_PAGE_DOWN = 12|@ohos.multimodalInput.intentionCode.d.ts|
|Added|NA|Class name: IntentionCode;<br>Method or attribute name: INTENTION_ZOOM_OUT = 13|@ohos.multimodalInput.intentionCode.d.ts|
|Added|NA|Class name: IntentionCode;<br>Method or attribute name: INTENTION_ZOOM_IN = 14|@ohos.multimodalInput.intentionCode.d.ts|
|Added|NA|Class name: pointer;<br>Method or attribute name: function setTouchpadScrollSwitch(state: boolean, callback: AsyncCallback\<void>): void;|@ohos.multimodalInput.pointer.d.ts|
|Added|NA|Class name: pointer;<br>Method or attribute name: function setTouchpadScrollSwitch(state: boolean): Promise\<void>;|@ohos.multimodalInput.pointer.d.ts|
|Added|NA|Class name: pointer;<br>Method or attribute name: function getTouchpadScrollSwitch(callback: AsyncCallback\<boolean>): void;|@ohos.multimodalInput.pointer.d.ts|
|Added|NA|Class name: pointer;<br>Method or attribute name: function getTouchpadScrollSwitch(): Promise\<boolean>;|@ohos.multimodalInput.pointer.d.ts|
|Added|NA|Class name: pointer;<br>Method or attribute name: function setTouchpadScrollDirection(state: boolean, callback: AsyncCallback\<void>): void;|@ohos.multimodalInput.pointer.d.ts|
|Added|NA|Class name: pointer;<br>Method or attribute name: function setTouchpadScrollDirection(state: boolean): Promise\<void>;|@ohos.multimodalInput.pointer.d.ts|
|Added|NA|Class name: pointer;<br>Method or attribute name: function getTouchpadScrollDirection(callback: AsyncCallback\<boolean>): void;|@ohos.multimodalInput.pointer.d.ts|
|Added|NA|Class name: pointer;<br>Method or attribute name: function getTouchpadScrollDirection(): Promise\<boolean>;|@ohos.multimodalInput.pointer.d.ts|
|Added|NA|Class name: pointer;<br>Method or attribute name: function setTouchpadTapSwitch(state: boolean, callback: AsyncCallback\<void>): void;|@ohos.multimodalInput.pointer.d.ts|
|Added|NA|Class name: pointer;<br>Method or attribute name: function setTouchpadTapSwitch(state: boolean): Promise\<void>;|@ohos.multimodalInput.pointer.d.ts|
|Added|NA|Class name: pointer;<br>Method or attribute name: function getTouchpadTapSwitch(callback: AsyncCallback\<boolean>): void;|@ohos.multimodalInput.pointer.d.ts|
|Added|NA|Class name: pointer;<br>Method or attribute name: function getTouchpadTapSwitch(): Promise\<boolean>;|@ohos.multimodalInput.pointer.d.ts|
|Added|NA|Class name: pointer;<br>Method or attribute name: function setTouchpadPointerSpeed(speed: number, callback: AsyncCallback\<void>): void;|@ohos.multimodalInput.pointer.d.ts|
|Added|NA|Class name: pointer;<br>Method or attribute name: function setTouchpadPointerSpeed(speed: number): Promise\<void>;|@ohos.multimodalInput.pointer.d.ts|
|Added|NA|Class name: pointer;<br>Method or attribute name: function getTouchpadPointerSpeed(callback: AsyncCallback\<number>): void;|@ohos.multimodalInput.pointer.d.ts|
|Added|NA|Class name: pointer;<br>Method or attribute name: function getTouchpadPointerSpeed(): Promise\<number>;|@ohos.multimodalInput.pointer.d.ts|
|Added|NA|Class name: pointer;<br>Method or attribute name: function setTouchpadPinchSwitch(state: boolean, callback: AsyncCallback\<void>): void;|@ohos.multimodalInput.pointer.d.ts|
|Added|NA|Class name: pointer;<br>Method or attribute name: function setTouchpadPinchSwitch(state: boolean): Promise\<void>;|@ohos.multimodalInput.pointer.d.ts|
|Added|NA|Class name: pointer;<br>Method or attribute name: function getTouchpadPinchSwitch(callback: AsyncCallback\<boolean>): void;|@ohos.multimodalInput.pointer.d.ts|
|Added|NA|Class name: pointer;<br>Method or attribute name: function getTouchpadPinchSwitch(): Promise\<boolean>;|@ohos.multimodalInput.pointer.d.ts|
|Added|NA|Class name: pointer;<br>Method or attribute name: function setTouchpadSwipeSwitch(state: boolean, callback: AsyncCallback\<void>): void;|@ohos.multimodalInput.pointer.d.ts|
|Added|NA|Class name: pointer;<br>Method or attribute name: function setTouchpadSwipeSwitch(state: boolean): Promise\<void>;|@ohos.multimodalInput.pointer.d.ts|
|Added|NA|Class name: pointer;<br>Method or attribute name: function getTouchpadSwipeSwitch(callback: AsyncCallback\<boolean>): void;|@ohos.multimodalInput.pointer.d.ts|
|Added|NA|Class name: pointer;<br>Method or attribute name: function getTouchpadSwipeSwitch(): Promise\<boolean>;|@ohos.multimodalInput.pointer.d.ts|
|Added|NA|Class name: pointer;<br>Method or attribute name: function setTouchpadRightClickType(type: RightClickType, callback: AsyncCallback\<void>): void;|@ohos.multimodalInput.pointer.d.ts|
|Added|NA|Class name: pointer;<br>Method or attribute name: function setTouchpadRightClickType(type: RightClickType): Promise\<void>;|@ohos.multimodalInput.pointer.d.ts|
|Added|NA|Class name: pointer;<br>Method or attribute name: function getTouchpadRightClickType(callback: AsyncCallback\<RightClickType>): void;|@ohos.multimodalInput.pointer.d.ts|
|Added|NA|Class name: pointer;<br>Method or attribute name: function getTouchpadRightClickType(): Promise\<RightClickType>;|@ohos.multimodalInput.pointer.d.ts|
|Added|NA|Class name: PointerStyle;<br>Method or attribute name: HORIZONTAL_TEXT_CURSOR|@ohos.multimodalInput.pointer.d.ts|
|Added|NA|Class name: PointerStyle;<br>Method or attribute name: CURSOR_CROSS|@ohos.multimodalInput.pointer.d.ts|
|Added|NA|Class name: PointerStyle;<br>Method or attribute name: CURSOR_CIRCLE|@ohos.multimodalInput.pointer.d.ts|
|Added|NA|Class name: RightClickType;<br>Method or attribute name: TOUCHPAD_RIGHT_BUTTON = 1|@ohos.multimodalInput.pointer.d.ts|
|Added|NA|Class name: RightClickType;<br>Method or attribute name: TOUCHPAD_LEFT_BUTTON = 2|@ohos.multimodalInput.pointer.d.ts|
|Added|NA|Class name: RightClickType;<br>Method or attribute name: TOUCHPAD_TWO_FINGER_TAP = 3|@ohos.multimodalInput.pointer.d.ts|
|Error code changed|Class name: pointer;<br>Method or attribute name: function setMousePrimaryButton(primary: PrimaryButton, callback: AsyncCallback\<void>): void;<br>Old version information: 401|Class name: pointer;<br>Method or attribute name: function setMousePrimaryButton(primary: PrimaryButton, callback: AsyncCallback\<void>): void;<br>New version information: 202,401|@ohos.multimodalInput.pointer.d.ts|
|Error code changed|Class name: pointer;<br>Method or attribute name: function setMousePrimaryButton(primary: PrimaryButton): Promise\<void>;<br>Old version information: 401|Class name: pointer;<br>Method or attribute name: function setMousePrimaryButton(primary: PrimaryButton): Promise\<void>;<br>New version information: 202,401|@ohos.multimodalInput.pointer.d.ts|
|Error code changed|Class name: pointer;<br>Method or attribute name: function getMousePrimaryButton(callback: AsyncCallback\<PrimaryButton>): void;<br>Old version information: 401|Class name: pointer;<br>Method or attribute name: function getMousePrimaryButton(callback: AsyncCallback\<PrimaryButton>): void;<br>New version information: 202,401|@ohos.multimodalInput.pointer.d.ts|
|Error code changed|Class name: pointer;<br>Method or attribute name: function getMousePrimaryButton(): Promise\<PrimaryButton>;<br>Old version information: 401|Class name: pointer;<br>Method or attribute name: function getMousePrimaryButton(): Promise\<PrimaryButton>;<br>New version information: 202,401|@ohos.multimodalInput.pointer.d.ts|
|Error code changed|Class name: pointer;<br>Method or attribute name: function setHoverScrollState(state: boolean, callback: AsyncCallback\<void>): void;<br>Old version information: 401|Class name: pointer;<br>Method or attribute name: function setHoverScrollState(state: boolean, callback: AsyncCallback\<void>): void;<br>New version information: 202,401|@ohos.multimodalInput.pointer.d.ts|
|Error code changed|Class name: pointer;<br>Method or attribute name: function setHoverScrollState(state: boolean): Promise\<void>;<br>Old version information: 401|Class name: pointer;<br>Method or attribute name: function setHoverScrollState(state: boolean): Promise\<void>;<br>New version information: 202,401|@ohos.multimodalInput.pointer.d.ts|
|Error code changed|Class name: pointer;<br>Method or attribute name: function getHoverScrollState(callback: AsyncCallback\<boolean>): void;<br>Old version information: 401|Class name: pointer;<br>Method or attribute name: function getHoverScrollState(callback: AsyncCallback\<boolean>): void;<br>New version information: 202,401|@ohos.multimodalInput.pointer.d.ts|
|Error code changed|Class name: pointer;<br>Method or attribute name: function getHoverScrollState(): Promise\<boolean>;<br>Old version information: 401|Class name: pointer;<br>Method or attribute name: function getHoverScrollState(): Promise\<boolean>;<br>New version information: 202,401|@ohos.multimodalInput.pointer.d.ts|
|Error code changed|Class name: pointer;<br>Method or attribute name: function setMouseScrollRows(rows: number, callback: AsyncCallback\<void>): void;<br>Old version information: 401|Class name: pointer;<br>Method or attribute name: function setMouseScrollRows(rows: number, callback: AsyncCallback\<void>): void;<br>New version information: 202,401|@ohos.multimodalInput.pointer.d.ts|
|Error code changed|Class name: pointer;<br>Method or attribute name: function setMouseScrollRows(rows: number): Promise\<void>;<br>Old version information: 401|Class name: pointer;<br>Method or attribute name: function setMouseScrollRows(rows: number): Promise\<void>;<br>New version information: 202,401|@ohos.multimodalInput.pointer.d.ts|
|Error code changed|Class name: pointer;<br>Method or attribute name: function getMouseScrollRows(callback: AsyncCallback\<number>): void;<br>Old version information: 401|Class name: pointer;<br>Method or attribute name: function getMouseScrollRows(callback: AsyncCallback\<number>): void;<br>New version information: 202,401|@ohos.multimodalInput.pointer.d.ts|
|Error code changed|Class name: pointer;<br>Method or attribute name: function getMouseScrollRows(): Promise\<number>;<br>Old version information: 401|Class name: pointer;<br>Method or attribute name: function getMouseScrollRows(): Promise\<number>;<br>New version information: 202,401|@ohos.multimodalInput.pointer.d.ts|
|Error code changed|Class name: shortKey;<br>Method or attribute name: function setKeyDownDuration(businessKey: string, delay: number, callback: AsyncCallback\<void>): void;<br>Old version information: 401|Class name: shortKey;<br>Method or attribute name: function setKeyDownDuration(businessKey: string, delay: number, callback: AsyncCallback\<void>): void;<br>New version information: 202,401|@ohos.multimodalInput.shortKey.d.ts|
|Error code changed|Class name: shortKey;<br>Method or attribute name: function setKeyDownDuration(businessKey: string, delay: number): Promise\<void>;<br>Old version information: 401|Class name: shortKey;<br>Method or attribute name: function setKeyDownDuration(businessKey: string, delay: number): Promise\<void>;<br>New version information: 202,401|@ohos.multimodalInput.shortKey.d.ts|
| Change Type | Old Version | New Version | d.ts File |
| ---- | ------ | ------ | -------- |
|Deleted|Class name: avSession;<br>Method or attribute name: function on(type: 'sessionCreate' \| 'sessionDestroy' \| 'topSessionChange', callback: (session: AVSessionDescriptor) => void): void;|NA|@ohos.multimedia.avsession.d.ts|
|Deleted|Class name: avSession;<br>Method or attribute name: function off(type: 'sessionCreate' \| 'sessionDestroy' \| 'topSessionChange', callback?: (session: AVSessionDescriptor) => void): void;|NA|@ohos.multimedia.avsession.d.ts|
|Deleted|Class name: AVSession;<br>Method or attribute name: on(type: 'play' \| 'pause' \| 'stop' \| 'playNext' \| 'playPrevious' \| 'fastForward' \| 'rewind', callback: () => void): void;|NA|@ohos.multimedia.avsession.d.ts|
|Deleted|Class name: AVSession;<br>Method or attribute name: on(type: 'outputDeviceChange', callback: (device: OutputDeviceInfo) => void): void;|NA|@ohos.multimedia.avsession.d.ts|
|Deleted|Class name: AVSessionController;<br>Method or attribute name: on(type: 'outputDeviceChange', callback: (device: OutputDeviceInfo) => void): void;|NA|@ohos.multimedia.avsession.d.ts|
|Deleted|Class name: AVSession;<br>Method or attribute name: off(type: 'play' \| 'pause' \| 'stop' \| 'playNext' \| 'playPrevious' \| 'fastForward' \| 'rewind', callback?: () => void): void;|NA|@ohos.multimedia.avsession.d.ts|
|Deleted|Class name: AVSession;<br>Method or attribute name: off(type: 'outputDeviceChange', callback?: (device: OutputDeviceInfo) => void): void;|NA|@ohos.multimedia.avsession.d.ts|
|Deleted|Class name: AVSessionController;<br>Method or attribute name: off(type: 'outputDeviceChange', callback?: (device: OutputDeviceInfo) => void): void;|NA|@ohos.multimedia.avsession.d.ts|
|Deleted|Class name: OutputDeviceInfo;<br>Method or attribute name: isRemote: boolean;|NA|@ohos.multimedia.avsession.d.ts|
|Deleted|Class name: OutputDeviceInfo;<br>Method or attribute name: audioDeviceId: Array\<number>;|NA|@ohos.multimedia.avsession.d.ts|
|Deleted|Class name: OutputDeviceInfo;<br>Method or attribute name: deviceName: Array\<string>;|NA|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: effectKit;<br>Method or attribute name: function createColorPicker(source:image.PixelMap,region:Array\<number>):Promise\<ColorPicker>;|@ohos.effectKit.d.ts|
|Added|NA|Class name: effectKit;<br>Method or attribute name: function createColorPicker(source:image.PixelMap,region:Array\<number>,callback:AsyncCallback\<ColorPicker>):void;|@ohos.effectKit.d.ts|
|Added|NA|Class name: AVMediaDescription;<br>Method or attribute name: artist?: string;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVMediaDescription;<br>Method or attribute name: duration?: number;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVCastController;<br>Method or attribute name: getAVPlaybackState(callback: AsyncCallback\<AVPlaybackState>): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVCastController;<br>Method or attribute name: getAVPlaybackState(): Promise\<AVPlaybackState>;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: audio;<br>Method or attribute name: type AudioEffectInfoArray = Array\<Readonly\<AudioEffectMode>>;|@ohos.multimedia.audio.d.ts|
|Added|NA|Class name: StreamUsage;<br>Method or attribute name: STREAM_USAGE_MUSIC = 1|@ohos.multimedia.audio.d.ts|
|Added|NA|Class name: StreamUsage;<br>Method or attribute name: STREAM_USAGE_VOICE_MESSAGE = 5|@ohos.multimedia.audio.d.ts|
|Added|NA|Class name: StreamUsage;<br>Method or attribute name: STREAM_USAGE_RINGTONE = 6|@ohos.multimedia.audio.d.ts|
|Added|NA|Class name: StreamUsage;<br>Method or attribute name: STREAM_USAGE_NOTIFICATION = 7|@ohos.multimedia.audio.d.ts|
|Added|NA|Class name: StreamUsage;<br>Method or attribute name: STREAM_USAGE_MOVIE = 10|@ohos.multimedia.audio.d.ts|
|Added|NA|Class name: StreamUsage;<br>Method or attribute name: STREAM_USAGE_GAME = 11|@ohos.multimedia.audio.d.ts|
|Added|NA|Class name: StreamUsage;<br>Method or attribute name: STREAM_USAGE_AUDIOBOOK = 12|@ohos.multimedia.audio.d.ts|
|Added|NA|Class name: StreamUsage;<br>Method or attribute name: STREAM_USAGE_NAVIGATION = 13|@ohos.multimedia.audio.d.ts|
|Added|NA|Class name: StreamUsage;<br>Method or attribute name: STREAM_USAGE_DTMF = 14|@ohos.multimedia.audio.d.ts|
|Added|NA|Class name: StreamUsage;<br>Method or attribute name: STREAM_USAGE_ENFORCED_TONE = 15|@ohos.multimedia.audio.d.ts|
|Added|NA|Class name: StreamUsage;<br>Method or attribute name: STREAM_USAGE_ULTRASONIC = 16|@ohos.multimedia.audio.d.ts|
|Added|NA|Class name: AudioRendererOptions;<br>Method or attribute name: privacyType?: AudioPrivacyType;|@ohos.multimedia.audio.d.ts|
|Added|NA|Class name: AudioPrivacyType;<br>Method or attribute name: PRIVACY_TYPE_PUBLIC = 0|@ohos.multimedia.audio.d.ts|
|Added|NA|Class name: AudioPrivacyType;<br>Method or attribute name: PRIVACY_TYPE_PRIVATE = 1|@ohos.multimedia.audio.d.ts|
|Added|NA|Class name: VolumeAdjustType;<br>Method or attribute name: VOLUME_UP = 0|@ohos.multimedia.audio.d.ts|
|Added|NA|Class name: VolumeAdjustType;<br>Method or attribute name: VOLUME_DOWN = 1|@ohos.multimedia.audio.d.ts|
|Added|NA|Class name: AudioStreamManager;<br>Method or attribute name: getAudioEffectInfoArray(usage: StreamUsage, callback: AsyncCallback\<AudioEffectInfoArray>): void;|@ohos.multimedia.audio.d.ts|
|Added|NA|Class name: AudioStreamManager;<br>Method or attribute name: getAudioEffectInfoArray(usage: StreamUsage): Promise\<AudioEffectInfoArray>;|@ohos.multimedia.audio.d.ts|
|Added|NA|Class name: AudioVolumeGroupManager;<br>Method or attribute name: isVolumeUnadjustable(): boolean;|@ohos.multimedia.audio.d.ts|
|Added|NA|Class name: AudioVolumeGroupManager;<br>Method or attribute name: adjustVolumeByStep(adjustType: VolumeAdjustType, callback: AsyncCallback\<void>): void;|@ohos.multimedia.audio.d.ts|
|Added|NA|Class name: AudioVolumeGroupManager;<br>Method or attribute name: adjustVolumeByStep(adjustType: VolumeAdjustType): Promise\<void>;|@ohos.multimedia.audio.d.ts|
|Added|NA|Class name: AudioVolumeGroupManager;<br>Method or attribute name: adjustSystemVolumeByStep(volumeType: AudioVolumeType, adjustType: VolumeAdjustType, callback: AsyncCallback\<void>): void;|@ohos.multimedia.audio.d.ts|
|Added|NA|Class name: AudioVolumeGroupManager;<br>Method or attribute name: adjustSystemVolumeByStep(volumeType: AudioVolumeType, adjustType: VolumeAdjustType): Promise\<void>;|@ohos.multimedia.audio.d.ts|
|Added|NA|Class name: AudioVolumeGroupManager;<br>Method or attribute name: getSystemVolumeInDb(volumeType: AudioVolumeType, volumeLevel: number, device: DeviceType, callback: AsyncCallback\<number>): void;|@ohos.multimedia.audio.d.ts|
|Added|NA|Class name: AudioVolumeGroupManager;<br>Method or attribute name: getSystemVolumeInDb(volumeType: AudioVolumeType, volumeLevel: number, device: DeviceType): Promise\<number>;|@ohos.multimedia.audio.d.ts|
|Added|NA|Class name: AudioRenderer;<br>Method or attribute name: getAudioEffectMode(callback: AsyncCallback\<AudioEffectMode>): void;|@ohos.multimedia.audio.d.ts|
|Added|NA|Class name: AudioRenderer;<br>Method or attribute name: getAudioEffectMode(): Promise\<AudioEffectMode>;|@ohos.multimedia.audio.d.ts|
|Added|NA|Class name: AudioRenderer;<br>Method or attribute name: setAudioEffectMode(mode: AudioEffectMode, callback: AsyncCallback\<void>): void;|@ohos.multimedia.audio.d.ts|
|Added|NA|Class name: AudioRenderer;<br>Method or attribute name: setAudioEffectMode(mode: AudioEffectMode): Promise\<void>;|@ohos.multimedia.audio.d.ts|
|Added|NA|Class name: AudioRenderer;<br>Method or attribute name: getMinStreamVolume(callback: AsyncCallback\<number>): void;|@ohos.multimedia.audio.d.ts|
|Added|NA|Class name: AudioRenderer;<br>Method or attribute name: getMinStreamVolume(): Promise\<number>;|@ohos.multimedia.audio.d.ts|
|Added|NA|Class name: AudioRenderer;<br>Method or attribute name: getMaxStreamVolume(callback: AsyncCallback\<number>): void;|@ohos.multimedia.audio.d.ts|
|Added|NA|Class name: AudioRenderer;<br>Method or attribute name: getMaxStreamVolume(): Promise\<number>;|@ohos.multimedia.audio.d.ts|
|Added|NA|Class name: AudioRenderer;<br>Method or attribute name: getUnderflowCount(callback: AsyncCallback\<number>): void;|@ohos.multimedia.audio.d.ts|
|Added|NA|Class name: AudioRenderer;<br>Method or attribute name: getUnderflowCount(): Promise\<number>;|@ohos.multimedia.audio.d.ts|
|Added|NA|Class name: AudioRenderer;<br>Method or attribute name: getCurrentOutputDevices(callback: AsyncCallback\<AudioDeviceDescriptors>): void;|@ohos.multimedia.audio.d.ts|
|Added|NA|Class name: AudioRenderer;<br>Method or attribute name: getCurrentOutputDevices(): Promise\<AudioDeviceDescriptors>;|@ohos.multimedia.audio.d.ts|
|Added|NA|Class name: AudioRenderer;<br>Method or attribute name: on(type: 'outputDeviceChange', callback: Callback\<AudioDeviceDescriptors>): void;|@ohos.multimedia.audio.d.ts|
|Added|NA|Class name: AudioRenderer;<br>Method or attribute name: off(type: 'outputDeviceChange', callback?: Callback\<AudioDeviceDescriptors>): void;|@ohos.multimedia.audio.d.ts|
|Added|NA|Class name: SourceType;<br>Method or attribute name: SOURCE_TYPE_PLAYBACK_CAPTURE = 2|@ohos.multimedia.audio.d.ts|
|Added|NA|Class name: AudioCapturerOptions;<br>Method or attribute name: playbackCaptureConfig?: AudioPlaybackCaptureConfig;|@ohos.multimedia.audio.d.ts|
|Added|NA|Class name: CaptureFilterOptions;<br>Method or attribute name: usages: Array\<StreamUsage>;|@ohos.multimedia.audio.d.ts|
|Added|NA|Class name: AudioPlaybackCaptureConfig;<br>Method or attribute name: filterOptions: CaptureFilterOptions;|@ohos.multimedia.audio.d.ts|
|Added|NA|Class name: AudioCapturer;<br>Method or attribute name: off(type: 'audioInterrupt'): void;|@ohos.multimedia.audio.d.ts|
|Added|NA|Class name: AudioEffectMode;<br>Method or attribute name: EFFECT_NONE = 0|@ohos.multimedia.audio.d.ts|
|Added|NA|Class name: AudioEffectMode;<br>Method or attribute name: EFFECT_DEFAULT = 1|@ohos.multimedia.audio.d.ts|
|Added|NA|Class name: avSession;<br>Method or attribute name: function on(type: 'sessionCreate', callback: (session: AVSessionDescriptor) => void): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: avSession;<br>Method or attribute name: function on(type: 'sessionDestroy', callback: (session: AVSessionDescriptor) => void): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: avSession;<br>Method or attribute name: function on(type: 'topSessionChange', callback: (session: AVSessionDescriptor) => void): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: avSession;<br>Method or attribute name: function on(type: 'deviceAvailable', callback: (device: OutputDeviceInfo) => void): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: avSession;<br>Method or attribute name: function off(type: 'sessionCreate', callback?: (session: AVSessionDescriptor) => void): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: avSession;<br>Method or attribute name: function off(type: 'sessionDestroy', callback?: (session: AVSessionDescriptor) => void): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: avSession;<br>Method or attribute name: function off(type: 'topSessionChange', callback?: (session: AVSessionDescriptor) => void): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: avSession;<br>Method or attribute name: function off(type: 'deviceAvailable', callback?: (device: OutputDeviceInfo) => void): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: avSession;<br>Method or attribute name: function startCastDeviceDiscovery(callback: AsyncCallback\<void>): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: avSession;<br>Method or attribute name: function startCastDeviceDiscovery(filter: number, callback: AsyncCallback\<void>): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: avSession;<br>Method or attribute name: function startCastDeviceDiscovery(filter?: number): Promise\<void>;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: avSession;<br>Method or attribute name: function stopCastDeviceDiscovery(callback: AsyncCallback\<void>): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: avSession;<br>Method or attribute name: function stopCastDeviceDiscovery(): Promise\<void>;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: avSession;<br>Method or attribute name: function setDiscoverable(enable: boolean, callback: AsyncCallback\<void>): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: avSession;<br>Method or attribute name: function setDiscoverable(enable: boolean): Promise\<void>;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: avSession;<br>Method or attribute name: function getAVCastController(sessionId: string, callback: AsyncCallback\<AVCastController>): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: avSession;<br>Method or attribute name: function getAVCastController(sessionId: string): Promise\<AVCastController>;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: avSession;<br>Method or attribute name: function startCasting(session: SessionToken, device: OutputDeviceInfo, callback: AsyncCallback\<void>): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: avSession;<br>Method or attribute name: function startCasting(session: SessionToken, device: OutputDeviceInfo): Promise\<void>;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: avSession;<br>Method or attribute name: function stopCasting(session: SessionToken, callback: AsyncCallback\<void>): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: avSession;<br>Method or attribute name: function stopCasting(session: SessionToken): Promise\<void>;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: avSession;<br>Method or attribute name: type AVCastControlCommandType = 'play' \| 'pause' \| 'stop' \| 'playNext' \| 'playPrevious' \| 'fastForward' \| 'rewind' \|<br> 'seek' \| 'setVolume' \| 'setSpeed' \| 'setLoopMode' \| 'toggleFavorite';|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: ProtocolType;<br>Method or attribute name: TYPE_LOCAL = 0|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: ProtocolType;<br>Method or attribute name: TYPE_CAST_PLUS_MIRROR = 1|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: ProtocolType;<br>Method or attribute name: TYPE_CAST_PLUS_STREAM = 2|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVSession;<br>Method or attribute name: readonly sessionType: AVSessionType;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVSession;<br>Method or attribute name: getAVCastController(callback: AsyncCallback\<AVCastController>): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVSession;<br>Method or attribute name: getAVCastController(): Promise\<AVCastController>;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVSession;<br>Method or attribute name: on(type: 'play', callback: () => void): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVSession;<br>Method or attribute name: on(type: 'pause', callback: () => void): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVSession;<br>Method or attribute name: on(type: 'stop', callback: () => void): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVSession;<br>Method or attribute name: on(type: 'playNext', callback: () => void): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVSession;<br>Method or attribute name: on(type: 'playPrevious', callback: () => void): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVSession;<br>Method or attribute name: on(type: 'fastForward', callback: () => void): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVSession;<br>Method or attribute name: on(type: 'rewind', callback: () => void): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVSession;<br>Method or attribute name: on(type: 'outputDeviceChange', callback: (state: ConnectionState, device: OutputDeviceInfo) => void): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVSessionController;<br>Method or attribute name: on(type: 'outputDeviceChange', callback: (state: ConnectionState, device: OutputDeviceInfo) => void): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVSession;<br>Method or attribute name: off(type: 'play', callback?: () => void): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVSession;<br>Method or attribute name: off(type: 'pause', callback?: () => void): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVSession;<br>Method or attribute name: off(type: 'stop', callback?: () => void): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVSession;<br>Method or attribute name: off(type: 'playNext', callback?: () => void): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVSession;<br>Method or attribute name: off(type: 'playPrevious', callback?: () => void): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVSession;<br>Method or attribute name: off(type: 'fastForward', callback?: () => void): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVSession;<br>Method or attribute name: off(type: 'rewind', callback?: () => void): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVSession;<br>Method or attribute name: off(type: 'outputDeviceChange', callback?: (state: ConnectionState, device: OutputDeviceInfo) => void): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVSessionController;<br>Method or attribute name: off(type: 'outputDeviceChange', callback?: (state: ConnectionState, device: OutputDeviceInfo) => void): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVSession;<br>Method or attribute name: stopCasting(callback: AsyncCallback\<void>): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVSession;<br>Method or attribute name: stopCasting(): Promise\<void>;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVCastControlCommand;<br>Method or attribute name: command: AVCastControlCommandType;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVCastControlCommand;<br>Method or attribute name: parameter?: media.PlaybackSpeed \| number;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVCastController;<br>Method or attribute name: setDisplaySurface(surfaceId: string, callback: AsyncCallback\<void>): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVCastController;<br>Method or attribute name: setDisplaySurface(surfaceId: string): Promise\<void>;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVCastController;<br>Method or attribute name: sendControlCommand(command: AVCastControlCommand, callback: AsyncCallback\<void>): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVCastController;<br>Method or attribute name: sendControlCommand(command: AVCastControlCommand): Promise\<void>;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVCastController;<br>Method or attribute name: start(item: AVQueueItem, callback: AsyncCallback\<void>): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVCastController;<br>Method or attribute name: start(item: AVQueueItem): Promise\<void>;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVCastController;<br>Method or attribute name: prepare(item: AVQueueItem, callback: AsyncCallback\<void>): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVCastController;<br>Method or attribute name: prepare(item: AVQueueItem): Promise\<void>;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVCastController;<br>Method or attribute name: getCurrentItem(callback: AsyncCallback\<AVQueueItem>): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVCastController;<br>Method or attribute name: getCurrentItem(): Promise\<AVQueueItem>;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVCastController;<br>Method or attribute name: on(type: 'playbackStateChange', filter: Array\<keyof AVPlaybackState> \| 'all', callback: (state: AVPlaybackState) => void): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVCastController;<br>Method or attribute name: on(type: 'mediaItemChange', callback: Callback\<AVQueueItem>): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVCastController;<br>Method or attribute name: on(type: 'playNext', callback: Callback\<void>): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVCastController;<br>Method or attribute name: on(type: 'playPrevious', callback: Callback\<void>): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVCastController;<br>Method or attribute name: on(type: 'seekDone', callback: Callback\<number>): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVCastController;<br>Method or attribute name: on(type: 'videoSizeChange', callback: (width: number, height: number) => void): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVCastController;<br>Method or attribute name: on(type: 'error', callback: ErrorCallback): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVCastController;<br>Method or attribute name: off(type: 'playbackStateChange', callback?: (state: AVPlaybackState) => void): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVCastController;<br>Method or attribute name: off(type: 'mediaItemChange'): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVCastController;<br>Method or attribute name: off(type: 'playNext'): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVCastController;<br>Method or attribute name: off(type: 'playPrevious'): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVCastController;<br>Method or attribute name: off(type: 'seekDone'): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVCastController;<br>Method or attribute name: off(type: 'videoSizeChange'): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVCastController;<br>Method or attribute name: off(type: 'error'): void;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: ConnectionState;<br>Method or attribute name: STATE_CONNECTING = 0|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: ConnectionState;<br>Method or attribute name: STATE_CONNECTED = 1|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: ConnectionState;<br>Method or attribute name: STATE_DISCONNECTED = 6|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVMediaDescription;<br>Method or attribute name: mediaType?: string;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVMediaDescription;<br>Method or attribute name: mediaSize?: number;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVMediaDescription;<br>Method or attribute name: albumTitle?: string;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVMediaDescription;<br>Method or attribute name: albumCoverUri?: string;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVMediaDescription;<br>Method or attribute name: lyricContent?: string;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVMediaDescription;<br>Method or attribute name: lyricUri?: string;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVMediaDescription;<br>Method or attribute name: fdSrc?: media.AVFileDescriptor;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVMediaDescription;<br>Method or attribute name: startPosition?: number;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVMediaDescription;<br>Method or attribute name: creditsPosition?: number;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVMediaDescription;<br>Method or attribute name: appName?: string;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVPlaybackState;<br>Method or attribute name: volume?: number;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVCastCategory;<br>Method or attribute name: CATEGORY_LOCAL = 0|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVCastCategory;<br>Method or attribute name: CATEGORY_REMOTE = 1|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: DeviceType;<br>Method or attribute name: DEVICE_TYPE_LOCAL = 0|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: DeviceType;<br>Method or attribute name: DEVICE_TYPE_TV = 2|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: DeviceType;<br>Method or attribute name: DEVICE_TYPE_SMART_SPEAKER = 3|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: DeviceType;<br>Method or attribute name: DEVICE_TYPE_BLUETOOTH = 10|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: DeviceInfo;<br>Method or attribute name: castCategory: number;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: DeviceInfo;<br>Method or attribute name: deviceId: string;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: DeviceInfo;<br>Method or attribute name: deviceName: string;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: DeviceInfo;<br>Method or attribute name: deviceType: DeviceType;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: DeviceInfo;<br>Method or attribute name: ipAddress?: string;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: DeviceInfo;<br>Method or attribute name: providerId?: number;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: OutputDeviceInfo;<br>Method or attribute name: devices: Array\<DeviceInfo>;|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: PlaybackState;<br>Method or attribute name: PLAYBACK_STATE_COMPLETED = 7|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: PlaybackState;<br>Method or attribute name: PLAYBACK_STATE_RELEASED = 8|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: PlaybackState;<br>Method or attribute name: PLAYBACK_STATE_ERROR = 9|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVSessionErrorCode;<br>Method or attribute name: ERR_CODE_DEVICE_CONNECTION_FAILED = 6600108|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: AVSessionErrorCode;<br>Method or attribute name: ERR_CODE_REMOTE_CONNECTION_NOT_EXIST = 6600109|@ohos.multimedia.avsession.d.ts|
|Added|NA|Class name: PrelaunchConfig;<br>Method or attribute name: cameraDevice: CameraDevice;|@ohos.multimedia.camera.d.ts|
|Added|NA|Class name: CameraManager;<br>Method or attribute name: isPrelaunchSupported(camera: CameraDevice): boolean;|@ohos.multimedia.camera.d.ts|
|Added|NA|Class name: CameraManager;<br>Method or attribute name: setPrelaunchConfig(prelaunchConfig: PrelaunchConfig): void;|@ohos.multimedia.camera.d.ts|
|Added|NA|Class name: CameraManager;<br>Method or attribute name: prelaunch(): void;|@ohos.multimedia.camera.d.ts|
|Added|NA|Class name: CameraManager;<br>Method or attribute name: createDeferredPreviewOutput(profile: Profile): PreviewOutput;|@ohos.multimedia.camera.d.ts|
|Added|NA|Class name: PreviewOutput;<br>Method or attribute name: addDeferredSurface(surfaceId: string): void;|@ohos.multimedia.camera.d.ts|
|Added|NA|Class name: PhotoOutput;<br>Method or attribute name: on(type: 'quickThumbnail', callback: AsyncCallback\<image.PixelMap>): void;|@ohos.multimedia.camera.d.ts|
|Added|NA|Class name: PhotoOutput;<br>Method or attribute name: isQuickThumbnailSupported(): boolean;|@ohos.multimedia.camera.d.ts|
|Added|NA|Class name: PhotoOutput;<br>Method or attribute name: enableQuickThumbnail(enabled: boolean): void;|@ohos.multimedia.camera.d.ts|
|Added|NA|Class name: PropertyKey;<br>Method or attribute name: DATE_TIME = 'DateTime'|@ohos.multimedia.image.d.ts|
|Added|NA|Class name: PropertyKey;<br>Method or attribute name: GPS_TIME_STAMP = 'GPSTimeStamp'|@ohos.multimedia.image.d.ts|
|Added|NA|Class name: PropertyKey;<br>Method or attribute name: GPS_DATE_STAMP = 'GPSDateStamp'|@ohos.multimedia.image.d.ts|
|Added|NA|Class name: PropertyKey;<br>Method or attribute name: IMAGE_DESCRIPTION = 'ImageDescription'|@ohos.multimedia.image.d.ts|
|Added|NA|Class name: PropertyKey;<br>Method or attribute name: MAKE = 'Make'|@ohos.multimedia.image.d.ts|
|Added|NA|Class name: PropertyKey;<br>Method or attribute name: MODEL = 'Model'|@ohos.multimedia.image.d.ts|
|Added|NA|Class name: PropertyKey;<br>Method or attribute name: PHOTO_MODE = 'PhotoMode'|@ohos.multimedia.image.d.ts|
|Added|NA|Class name: PropertyKey;<br>Method or attribute name: SENSITIVITY_TYPE = 'SensitivityType'|@ohos.multimedia.image.d.ts|
|Added|NA|Class name: PropertyKey;<br>Method or attribute name: STANDARD_OUTPUT_SENSITIVITY = 'StandardOutputSensitivity'|@ohos.multimedia.image.d.ts|
|Added|NA|Class name: PropertyKey;<br>Method or attribute name: RECOMMENDED_EXPOSURE_INDEX = 'RecommendedExposureIndex'|@ohos.multimedia.image.d.ts|
|Added|NA|Class name: PropertyKey;<br>Method or attribute name: ISO_SPEED = 'ISOSpeedRatings'|@ohos.multimedia.image.d.ts|
|Added|NA|Class name: PropertyKey;<br>Method or attribute name: APERTURE_VALUE = 'ApertureValue'|@ohos.multimedia.image.d.ts|
|Added|NA|Class name: PropertyKey;<br>Method or attribute name: EXPOSURE_BIAS_VALUE = 'ExposureBiasValue'|@ohos.multimedia.image.d.ts|
|Added|NA|Class name: PropertyKey;<br>Method or attribute name: METERING_MODE = 'MeteringMode'|@ohos.multimedia.image.d.ts|
|Added|NA|Class name: PropertyKey;<br>Method or attribute name: LIGHT_SOURCE = 'LightSource'|@ohos.multimedia.image.d.ts|
|Added|NA|Class name: PropertyKey;<br>Method or attribute name: FLASH = 'Flash'|@ohos.multimedia.image.d.ts|
|Added|NA|Class name: PropertyKey;<br>Method or attribute name: FOCAL_LENGTH = 'FocalLength'|@ohos.multimedia.image.d.ts|
|Added|NA|Class name: PropertyKey;<br>Method or attribute name: USER_COMMENT = 'UserComment'|@ohos.multimedia.image.d.ts|
|Added|NA|Class name: PropertyKey;<br>Method or attribute name: PIXEL_X_DIMENSION = 'PixelXDimension'|@ohos.multimedia.image.d.ts|
|Added|NA|Class name: PropertyKey;<br>Method or attribute name: PIXEL_Y_DIMENSION = 'PixelYDimension'|@ohos.multimedia.image.d.ts|
|Added|NA|Class name: PropertyKey;<br>Method or attribute name: WHITE_BALANCE = 'WhiteBalance'|@ohos.multimedia.image.d.ts|
|Added|NA|Class name: PropertyKey;<br>Method or attribute name: FOCAL_LENGTH_IN_35_MM_FILM = 'FocalLengthIn35mmFilm'|@ohos.multimedia.image.d.ts|
|Added|NA|Class name: PropertyKey;<br>Method or attribute name: CAPTURE_MODE = 'HwMnoteCaptureMode'|@ohos.multimedia.image.d.ts|
|Added|NA|Class name: PropertyKey;<br>Method or attribute name: PHYSICAL_APERTURE = 'HwMnotePhysicalAperture'|@ohos.multimedia.image.d.ts|
|Added|NA|Class name: PixelMap;<br>Method or attribute name: getColorSpace(): colorSpaceManager.ColorSpaceManager;|@ohos.multimedia.image.d.ts|
|Added|NA|Class name: PixelMap;<br>Method or attribute name: marshalling(sequence: rpc.MessageSequence): void;|@ohos.multimedia.image.d.ts|
|Added|NA|Class name: PixelMap;<br>Method or attribute name: unmarshalling(sequence: rpc.MessageSequence): Promise\<PixelMap>;|@ohos.multimedia.image.d.ts|
|Added|NA|Class name: PixelMap;<br>Method or attribute name: setColorSpace(colorSpace: colorSpaceManager.ColorSpaceManager): void;|@ohos.multimedia.image.d.ts|
|Added|NA|Class name: AVPlayer;<br>Method or attribute name: audioEffectMode ?: audio.AudioEffectMode;|@ohos.multimedia.media.d.ts|
|Error code added|Class name: effectKit;<br>Method or attribute name: function createColorPicker(source:image.PixelMap): Promise\<ColorPicker>;<br>Old version information: |Class name: effectKit;<br>Method or attribute name: function createColorPicker(source:image.PixelMap): Promise\<ColorPicker>;<br>New version information: 401|@ohos.effectKit.d.ts|
|Error code added|Class name: effectKit;<br>Method or attribute name: function createColorPicker(source:image.PixelMap,callback:AsyncCallback\<ColorPicker>):void;<br>Old version information: |Class name: effectKit;<br>Method or attribute name: function createColorPicker(source:image.PixelMap,callback:AsyncCallback\<ColorPicker>):void;<br>New version information: 401|@ohos.effectKit.d.ts|
|Error code added|Class name: avSession;<br>Method or attribute name: function createAVSession(context: Context, tag: string, type: AVSessionType): Promise\<AVSession>;<br>Old version information: |Class name: avSession;<br>Method or attribute name: function createAVSession(context: Context, tag: string, type: AVSessionType): Promise\<AVSession>;<br>New version information: 401,6600101|@ohos.multimedia.avsession.d.ts|
|Error code added|Class name: avSession;<br>Method or attribute name: function getAllSessionDescriptors(): Promise\<Array\<Readonly\<AVSessionDescriptor>>>;<br>Old version information: |Class name: avSession;<br>Method or attribute name: function getAllSessionDescriptors(): Promise\<Array\<Readonly\<AVSessionDescriptor>>>;<br>New version information: 201,6600101|@ohos.multimedia.avsession.d.ts|
|Error code added|Class name: avSession;<br>Method or attribute name: function createController(sessionId: string): Promise\<AVSessionController>;<br>Old version information: |Class name: avSession;<br>Method or attribute name: function createController(sessionId: string): Promise\<AVSessionController>;<br>New version information: 201,401,6600101,6600102|@ohos.multimedia.avsession.d.ts|
|Error code added|Class name: avSession;<br>Method or attribute name: function castAudio(session: SessionToken \| 'all', audioDevices: Array\<audio.AudioDeviceDescriptor>): Promise\<void>;<br>Old version information: |Class name: avSession;<br>Method or attribute name: function castAudio(session: SessionToken \| 'all', audioDevices: Array\<audio.AudioDeviceDescriptor>): Promise\<void>;<br>New version information: 201,401,6600101,6600102,6600104|@ohos.multimedia.avsession.d.ts|
|Error code added|Class name: avSession;<br>Method or attribute name: function sendSystemAVKeyEvent(event: KeyEvent): Promise\<void>;<br>Old version information: |Class name: avSession;<br>Method or attribute name: function sendSystemAVKeyEvent(event: KeyEvent): Promise\<void>;<br>New version information: 201,401,6600101,6600105|@ohos.multimedia.avsession.d.ts|
|Error code added|Class name: avSession;<br>Method or attribute name: function sendSystemControlCommand(command: AVControlCommand): Promise\<void>;<br>Old version information: |Class name: avSession;<br>Method or attribute name: function sendSystemControlCommand(command: AVControlCommand): Promise\<void>;<br>New version information: 201,401,6600101,6600105,6600107|@ohos.multimedia.avsession.d.ts|
|Error code added|Class name: AVSession;<br>Method or attribute name: setAVMetadata(data: AVMetadata): Promise\<void>;<br>Old version information: |Class name: AVSession;<br>Method or attribute name: setAVMetadata(data: AVMetadata): Promise\<void>;<br>New version information: 401,6600101,6600102|@ohos.multimedia.avsession.d.ts|
|Error code added|Class name: AVSession;<br>Method or attribute name: setAVPlaybackState(state: AVPlaybackState): Promise\<void>;<br>Old version information: |Class name: AVSession;<br>Method or attribute name: setAVPlaybackState(state: AVPlaybackState): Promise\<void>;<br>New version information: 401,6600101,6600102|@ohos.multimedia.avsession.d.ts|
|Error code added|Class name: AVSession;<br>Method or attribute name: setLaunchAbility(ability: WantAgent): Promise\<void>;<br>Old version information: |Class name: AVSession;<br>Method or attribute name: setLaunchAbility(ability: WantAgent): Promise\<void>;<br>New version information: 401,6600101,6600102|@ohos.multimedia.avsession.d.ts|
|Error code added|Class name: AVSession;<br>Method or attribute name: getController(): Promise\<AVSessionController>;<br>Old version information: |Class name: AVSession;<br>Method or attribute name: getController(): Promise\<AVSessionController>;<br>New version information: 6600101,6600102|@ohos.multimedia.avsession.d.ts|
|Error code added|Class name: AVSession;<br>Method or attribute name: getOutputDevice(): Promise\<OutputDeviceInfo>;<br>Old version information: |Class name: AVSession;<br>Method or attribute name: getOutputDevice(): Promise\<OutputDeviceInfo>;<br>New version information: 6600101,6600102|@ohos.multimedia.avsession.d.ts|
|Error code added|Class name: AVSessionController;<br>Method or attribute name: getOutputDevice(): Promise\<OutputDeviceInfo>;<br>Old version information: |Class name: AVSessionController;<br>Method or attribute name: getOutputDevice(): Promise\<OutputDeviceInfo>;<br>New version information: 600101,600103|@ohos.multimedia.avsession.d.ts|
|Error code added|Class name: AVSession;<br>Method or attribute name: activate(): Promise\<void>;<br>Old version information: |Class name: AVSession;<br>Method or attribute name: activate(): Promise\<void>;<br>New version information: 6600101,6600102|@ohos.multimedia.avsession.d.ts|
|Error code added|Class name: AVSession;<br>Method or attribute name: deactivate(): Promise\<void>;<br>Old version information: |Class name: AVSession;<br>Method or attribute name: deactivate(): Promise\<void>;<br>New version information: 6600101,6600102|@ohos.multimedia.avsession.d.ts|
|Error code added|Class name: AVSession;<br>Method or attribute name: destroy(): Promise\<void>;<br>Old version information: |Class name: AVSession;<br>Method or attribute name: destroy(): Promise\<void>;<br>New version information: 6600101,6600102|@ohos.multimedia.avsession.d.ts|
|Error code added|Class name: AVSessionController;<br>Method or attribute name: destroy(): Promise\<void>;<br>Old version information: |Class name: AVSessionController;<br>Method or attribute name: destroy(): Promise\<void>;<br>New version information: 6600101,6600103|@ohos.multimedia.avsession.d.ts|
|Error code added|Class name: AVSessionController;<br>Method or attribute name: getAVPlaybackState(): Promise\<AVPlaybackState>;<br>Old version information: |Class name: AVSessionController;<br>Method or attribute name: getAVPlaybackState(): Promise\<AVPlaybackState>;<br>New version information: 6600101,6600102,6600103|@ohos.multimedia.avsession.d.ts|
|Error code added|Class name: AVSessionController;<br>Method or attribute name: getAVMetadata(): Promise\<AVMetadata>;<br>Old version information: |Class name: AVSessionController;<br>Method or attribute name: getAVMetadata(): Promise\<AVMetadata>;<br>New version information: 6600101,6600102,6600103|@ohos.multimedia.avsession.d.ts|
|Error code added|Class name: AVSessionController;<br>Method or attribute name: sendAVKeyEvent(event: KeyEvent): Promise\<void>;<br>Old version information: |Class name: AVSessionController;<br>Method or attribute name: sendAVKeyEvent(event: KeyEvent): Promise\<void>;<br>New version information: 401,600101,600102,600103,600105,600106|@ohos.multimedia.avsession.d.ts|
|Error code added|Class name: AVSessionController;<br>Method or attribute name: getLaunchAbility(): Promise\<WantAgent>;<br>Old version information: |Class name: AVSessionController;<br>Method or attribute name: getLaunchAbility(): Promise\<WantAgent>;<br>New version information: 6600101,6600102,6600103|@ohos.multimedia.avsession.d.ts|
|Error code added|Class name: AVSessionController;<br>Method or attribute name: isActive(): Promise\<boolean>;<br>Old version information: |Class name: AVSessionController;<br>Method or attribute name: isActive(): Promise\<boolean>;<br>New version information: 6600101,6600102,6600103|@ohos.multimedia.avsession.d.ts|
|Error code added|Class name: AVSessionController;<br>Method or attribute name: getValidCommands(): Promise\<Array\<AVControlCommandType>>;<br>Old version information: |Class name: AVSessionController;<br>Method or attribute name: getValidCommands(): Promise\<Array\<AVControlCommandType>>;<br>New version information: 6600101,6600102,6600103|@ohos.multimedia.avsession.d.ts|
|Error code added|Class name: AVSessionController;<br>Method or attribute name: sendControlCommand(command: AVControlCommand): Promise\<void>;<br>Old version information: |Class name: AVSessionController;<br>Method or attribute name: sendControlCommand(command: AVControlCommand): Promise\<void>;<br>New version information: 401,6600101,6600102,6600103,6600105,6600106,6600107|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: avSession;<br>Method or attribute name: function createAVSession(context: Context, tag: string, type: AVSessionType, callback: AsyncCallback\<AVSession>): void;<br>Old version information: 401,{@link|Class name: avSession;<br>Method or attribute name: function createAVSession(context: Context, tag: string, type: AVSessionType, callback: AsyncCallback\<AVSession>): void;<br>New version information: 401,6600101|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: avSession;<br>Method or attribute name: function getAllSessionDescriptors(callback: AsyncCallback\<Array\<Readonly\<AVSessionDescriptor>>>): void;<br>Old version information: 201,{@link|Class name: avSession;<br>Method or attribute name: function getAllSessionDescriptors(callback: AsyncCallback\<Array\<Readonly\<AVSessionDescriptor>>>): void;<br>New version information: 201,6600101|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: avSession;<br>Method or attribute name: function createController(sessionId: string, callback: AsyncCallback\<AVSessionController>): void;<br>Old version information: 201,401,{@link,{@link|Class name: avSession;<br>Method or attribute name: function createController(sessionId: string, callback: AsyncCallback\<AVSessionController>): void;<br>New version information: 201,401,6600101,6600102|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: avSession;<br>Method or attribute name: function castAudio(session: SessionToken \| 'all', audioDevices: Array\<audio.AudioDeviceDescriptor>, callback: AsyncCallback\<void>): void;<br>Old version information: 201,401,{@link,{@link,{@link|Class name: avSession;<br>Method or attribute name: function castAudio(session: SessionToken \| 'all', audioDevices: Array\<audio.AudioDeviceDescriptor>, callback: AsyncCallback\<void>): void;<br>New version information: 201,401,6600101,6600102,6600104|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: avSession;<br>Method or attribute name: function on(type: 'sessionServiceDie', callback: () => void): void;<br>Old version information: 201,401,{@link|Class name: avSession;<br>Method or attribute name: function on(type: 'sessionServiceDie', callback: () => void): void;<br>New version information: 201,401,6600101|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: avSession;<br>Method or attribute name: function off(type: 'sessionServiceDie', callback?: () => void): void;<br>Old version information: 201,401,{@link|Class name: avSession;<br>Method or attribute name: function off(type: 'sessionServiceDie', callback?: () => void): void;<br>New version information: 201,401,6600101|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: avSession;<br>Method or attribute name: function sendSystemAVKeyEvent(event: KeyEvent, callback: AsyncCallback\<void>): void;<br>Old version information: 201,401,{@link,{@link|Class name: avSession;<br>Method or attribute name: function sendSystemAVKeyEvent(event: KeyEvent, callback: AsyncCallback\<void>): void;<br>New version information: 201,401,6600101,6600105|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: avSession;<br>Method or attribute name: function sendSystemControlCommand(command: AVControlCommand, callback: AsyncCallback\<void>): void;<br>Old version information: 201,401,{@link,{@link,{@link|Class name: avSession;<br>Method or attribute name: function sendSystemControlCommand(command: AVControlCommand, callback: AsyncCallback\<void>): void;<br>New version information: 201,401,6600101,6600105,6600107|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: AVSession;<br>Method or attribute name: setAVMetadata(data: AVMetadata, callback: AsyncCallback\<void>): void;<br>Old version information: 401,{@link,{@link|Class name: AVSession;<br>Method or attribute name: setAVMetadata(data: AVMetadata, callback: AsyncCallback\<void>): void;<br>New version information: 401,6600101,6600102|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: AVSession;<br>Method or attribute name: setAVPlaybackState(state: AVPlaybackState, callback: AsyncCallback\<void>): void;<br>Old version information: 401,{@link,{@link|Class name: AVSession;<br>Method or attribute name: setAVPlaybackState(state: AVPlaybackState, callback: AsyncCallback\<void>): void;<br>New version information: 401,6600101,6600102|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: AVSession;<br>Method or attribute name: setLaunchAbility(ability: WantAgent, callback: AsyncCallback\<void>): void;<br>Old version information: 401,{@link,{@link|Class name: AVSession;<br>Method or attribute name: setLaunchAbility(ability: WantAgent, callback: AsyncCallback\<void>): void;<br>New version information: 401,6600101,6600102|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: AVSession;<br>Method or attribute name: dispatchSessionEvent(event: string, args: {[key: string]: Object}, callback: AsyncCallback\<void>): void;<br>Old version information: 401,{@link,{@link|Class name: AVSession;<br>Method or attribute name: dispatchSessionEvent(event: string, args: {[key: string]: Object}, callback: AsyncCallback\<void>): void;<br>New version information: 401,6600101,6600102|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: AVSession;<br>Method or attribute name: dispatchSessionEvent(event: string, args: {[key: string]: Object}): Promise\<void>;<br>Old version information: 401,{@link,{@link|Class name: AVSession;<br>Method or attribute name: dispatchSessionEvent(event: string, args: {[key: string]: Object}): Promise\<void>;<br>New version information: 401,6600101,6600102|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: AVSession;<br>Method or attribute name: setExtras(extras: {[key: string]: Object}, callback: AsyncCallback\<void>): void;<br>Old version information: 401,{@link,{@link|Class name: AVSession;<br>Method or attribute name: setExtras(extras: {[key: string]: Object}, callback: AsyncCallback\<void>): void;<br>New version information: 401,6600101,6600102|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: AVSession;<br>Method or attribute name: setExtras(extras: {[key: string]: Object}): Promise\<void>;<br>Old version information: 401,{@link,{@link|Class name: AVSession;<br>Method or attribute name: setExtras(extras: {[key: string]: Object}): Promise\<void>;<br>New version information: 401,6600101,6600102|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: AVSession;<br>Method or attribute name: getController(callback: AsyncCallback\<AVSessionController>): void;<br>Old version information: {@link,{@link|Class name: AVSession;<br>Method or attribute name: getController(callback: AsyncCallback\<AVSessionController>): void;<br>New version information: 6600101,6600102|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: AVSession;<br>Method or attribute name: getOutputDevice(callback: AsyncCallback\<OutputDeviceInfo>): void;<br>Old version information: {@link,{@link|Class name: AVSession;<br>Method or attribute name: getOutputDevice(callback: AsyncCallback\<OutputDeviceInfo>): void;<br>New version information: 6600101,6600102|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: AVSessionController;<br>Method or attribute name: getOutputDevice(callback: AsyncCallback\<OutputDeviceInfo>): void;<br>Old version information: {@link,{@link|Class name: AVSessionController;<br>Method or attribute name: getOutputDevice(callback: AsyncCallback\<OutputDeviceInfo>): void;<br>New version information: 600101,600103|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: AVSession;<br>Method or attribute name: on(type: 'seek', callback: (time: number) => void): void;<br>Old version information: 401,{@link,{@link|Class name: AVSession;<br>Method or attribute name: on(type: 'seek', callback: (time: number) => void): void;<br>New version information: 401,6600101,6600102|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: AVSession;<br>Method or attribute name: on(type: 'setSpeed', callback: (speed: number) => void): void;<br>Old version information: 401,{@link,{@link|Class name: AVSession;<br>Method or attribute name: on(type: 'setSpeed', callback: (speed: number) => void): void;<br>New version information: 401,6600101,6600102|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: AVSession;<br>Method or attribute name: on(type: 'setLoopMode', callback: (mode: LoopMode) => void): void;<br>Old version information: 401,{@link,{@link|Class name: AVSession;<br>Method or attribute name: on(type: 'setLoopMode', callback: (mode: LoopMode) => void): void;<br>New version information: 401,6600101,6600102|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: AVSession;<br>Method or attribute name: on(type: 'toggleFavorite', callback: (assetId: string) => void): void;<br>Old version information: 401,{@link,{@link|Class name: AVSession;<br>Method or attribute name: on(type: 'toggleFavorite', callback: (assetId: string) => void): void;<br>New version information: 401,6600101,6600102|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: AVSession;<br>Method or attribute name: on(type: 'handleKeyEvent', callback: (event: KeyEvent) => void): void;<br>Old version information: 401,{@link,{@link|Class name: AVSession;<br>Method or attribute name: on(type: 'handleKeyEvent', callback: (event: KeyEvent) => void): void;<br>New version information: 401,6600101,6600102|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: AVSession;<br>Method or attribute name: off(type: 'seek', callback?: (time: number) => void): void;<br>Old version information: 401,{@link,{@link|Class name: AVSession;<br>Method or attribute name: off(type: 'seek', callback?: (time: number) => void): void;<br>New version information: 401,6600101,6600102|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: AVSession;<br>Method or attribute name: off(type: 'setSpeed', callback?: (speed: number) => void): void;<br>Old version information: 401,{@link,{@link|Class name: AVSession;<br>Method or attribute name: off(type: 'setSpeed', callback?: (speed: number) => void): void;<br>New version information: 401,6600101,6600102|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: AVSession;<br>Method or attribute name: off(type: 'setLoopMode', callback?: (mode: LoopMode) => void): void;<br>Old version information: 401,{@link,{@link|Class name: AVSession;<br>Method or attribute name: off(type: 'setLoopMode', callback?: (mode: LoopMode) => void): void;<br>New version information: 401,6600101,6600102|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: AVSession;<br>Method or attribute name: off(type: 'toggleFavorite', callback?: (assetId: string) => void): void;<br>Old version information: 401,{@link,{@link|Class name: AVSession;<br>Method or attribute name: off(type: 'toggleFavorite', callback?: (assetId: string) => void): void;<br>New version information: 401,6600101,6600102|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: AVSession;<br>Method or attribute name: off(type: 'handleKeyEvent', callback?: (event: KeyEvent) => void): void;<br>Old version information: 401,{@link,{@link|Class name: AVSession;<br>Method or attribute name: off(type: 'handleKeyEvent', callback?: (event: KeyEvent) => void): void;<br>New version information: 401,6600101,6600102|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: AVSession;<br>Method or attribute name: activate(callback: AsyncCallback\<void>): void;<br>Old version information: {@link,{@link|Class name: AVSession;<br>Method or attribute name: activate(callback: AsyncCallback\<void>): void;<br>New version information: 6600101,6600102|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: AVSession;<br>Method or attribute name: deactivate(callback: AsyncCallback\<void>): void;<br>Old version information: {@link,{@link|Class name: AVSession;<br>Method or attribute name: deactivate(callback: AsyncCallback\<void>): void;<br>New version information: 6600101,6600102|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: AVSession;<br>Method or attribute name: destroy(callback: AsyncCallback\<void>): void;<br>Old version information: {@link,{@link|Class name: AVSession;<br>Method or attribute name: destroy(callback: AsyncCallback\<void>): void;<br>New version information: 6600101,6600102|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: AVSessionController;<br>Method or attribute name: destroy(callback: AsyncCallback\<void>): void;<br>Old version information: {@link,{@link|Class name: AVSessionController;<br>Method or attribute name: destroy(callback: AsyncCallback\<void>): void;<br>New version information: 6600101,6600103|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: AVSessionController;<br>Method or attribute name: getAVPlaybackState(callback: AsyncCallback\<AVPlaybackState>): void;<br>Old version information: {@link,{@link,{@link|Class name: AVSessionController;<br>Method or attribute name: getAVPlaybackState(callback: AsyncCallback\<AVPlaybackState>): void;<br>New version information: 6600101,6600102,6600103|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: AVSessionController;<br>Method or attribute name: getAVMetadata(callback: AsyncCallback\<AVMetadata>): void;<br>Old version information: {@link,{@link,{@link|Class name: AVSessionController;<br>Method or attribute name: getAVMetadata(callback: AsyncCallback\<AVMetadata>): void;<br>New version information: 6600101,6600102,6600103|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: AVSessionController;<br>Method or attribute name: sendAVKeyEvent(event: KeyEvent, callback: AsyncCallback\<void>): void;<br>Old version information: 401,{@link,{@link,{@link,{@link,{@link|Class name: AVSessionController;<br>Method or attribute name: sendAVKeyEvent(event: KeyEvent, callback: AsyncCallback\<void>): void;<br>New version information: 401,600101,600102,600103,600105,600106|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: AVSessionController;<br>Method or attribute name: getLaunchAbility(callback: AsyncCallback\<WantAgent>): void;<br>Old version information: {@link,{@link,{@link|Class name: AVSessionController;<br>Method or attribute name: getLaunchAbility(callback: AsyncCallback\<WantAgent>): void;<br>New version information: 6600101,6600102,6600103|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: AVSessionController;<br>Method or attribute name: getRealPlaybackPositionSync(): number;<br>Old version information: {@link,{@link|Class name: AVSessionController;<br>Method or attribute name: getRealPlaybackPositionSync(): number;<br>New version information: 6600101,6600103|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: AVSessionController;<br>Method or attribute name: isActive(callback: AsyncCallback\<boolean>): void;<br>Old version information: {@link,{@link,{@link|Class name: AVSessionController;<br>Method or attribute name: isActive(callback: AsyncCallback\<boolean>): void;<br>New version information: 6600101,6600102,6600103|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: AVSessionController;<br>Method or attribute name: getValidCommands(callback: AsyncCallback\<Array\<AVControlCommandType>>): void;<br>Old version information: {@link,{@link,{@link|Class name: AVSessionController;<br>Method or attribute name: getValidCommands(callback: AsyncCallback\<Array\<AVControlCommandType>>): void;<br>New version information: 6600101,6600102,6600103|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: AVSessionController;<br>Method or attribute name: sendControlCommand(command: AVControlCommand, callback: AsyncCallback\<void>): void;<br>Old version information: 401,{@link,{@link,{@link,{@link,{@link,{@link|Class name: AVSessionController;<br>Method or attribute name: sendControlCommand(command: AVControlCommand, callback: AsyncCallback\<void>): void;<br>New version information: 401,6600101,6600102,6600103,6600105,6600106,6600107|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: AVSessionController;<br>Method or attribute name: on(type: 'metadataChange', filter: Array\<keyof AVMetadata> \| 'all', callback: (data: AVMetadata) => void);<br>Old version information: 401,{@link,{@link|Class name: AVSessionController;<br>Method or attribute name: on(type: 'metadataChange', filter: Array\<keyof AVMetadata> \| 'all', callback: (data: AVMetadata) => void);<br>New version information: 401,6600101,6600103|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: AVSessionController;<br>Method or attribute name: on(type: 'playbackStateChange', filter: Array\<keyof AVPlaybackState> \| 'all', callback: (state: AVPlaybackState) => void);<br>Old version information: 401,{@link,{@link|Class name: AVSessionController;<br>Method or attribute name: on(type: 'playbackStateChange', filter: Array\<keyof AVPlaybackState> \| 'all', callback: (state: AVPlaybackState) => void);<br>New version information: 401,6600101,6600103|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: AVSessionController;<br>Method or attribute name: on(type: 'sessionDestroy', callback: () => void);<br>Old version information: 401,{@link,{@link|Class name: AVSessionController;<br>Method or attribute name: on(type: 'sessionDestroy', callback: () => void);<br>New version information: 401,6600101,6600103|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: AVSessionController;<br>Method or attribute name: on(type: 'activeStateChange', callback: (isActive: boolean) => void);<br>Old version information: 401,{@link,{@link|Class name: AVSessionController;<br>Method or attribute name: on(type: 'activeStateChange', callback: (isActive: boolean) => void);<br>New version information: 401,6600101,6600103|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: AVSessionController;<br>Method or attribute name: on(type: 'validCommandChange', callback: (commands: Array\<AVControlCommandType>) => void);<br>Old version information: 401,{@link,{@link|Class name: AVSessionController;<br>Method or attribute name: on(type: 'validCommandChange', callback: (commands: Array\<AVControlCommandType>) => void);<br>New version information: 401,6600101,6600103|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: AVSessionController;<br>Method or attribute name: on(type: 'sessionEvent', callback: (sessionEvent: string, args: {[key: string]: Object}) => void): void;<br>Old version information: 401,{@link,{@link|Class name: AVSessionController;<br>Method or attribute name: on(type: 'sessionEvent', callback: (sessionEvent: string, args: {[key: string]: Object}) => void): void;<br>New version information: 401,6600101,6600103|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: AVSessionController;<br>Method or attribute name: on(type: 'extrasChange', callback: (extras: {[key: string]: Object}) => void): void;<br>Old version information: 401,{@link,{@link|Class name: AVSessionController;<br>Method or attribute name: on(type: 'extrasChange', callback: (extras: {[key: string]: Object}) => void): void;<br>New version information: 401,6600101,6600103|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: AVSessionController;<br>Method or attribute name: off(type: 'metadataChange', callback?: (data: AVMetadata) => void);<br>Old version information: 401,{@link,{@link|Class name: AVSessionController;<br>Method or attribute name: off(type: 'metadataChange', callback?: (data: AVMetadata) => void);<br>New version information: 401,6600101,6600103|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: AVSessionController;<br>Method or attribute name: off(type: 'playbackStateChange', callback?: (state: AVPlaybackState) => void);<br>Old version information: 401,{@link,{@link|Class name: AVSessionController;<br>Method or attribute name: off(type: 'playbackStateChange', callback?: (state: AVPlaybackState) => void);<br>New version information: 401,6600101,6600103|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: AVSessionController;<br>Method or attribute name: off(type: 'sessionDestroy', callback?: () => void);<br>Old version information: 401,{@link,{@link|Class name: AVSessionController;<br>Method or attribute name: off(type: 'sessionDestroy', callback?: () => void);<br>New version information: 401,6600101,6600103|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: AVSessionController;<br>Method or attribute name: off(type: 'activeStateChange', callback?: (isActive: boolean) => void);<br>Old version information: 401,{@link,{@link|Class name: AVSessionController;<br>Method or attribute name: off(type: 'activeStateChange', callback?: (isActive: boolean) => void);<br>New version information: 401,6600101,6600103|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: AVSessionController;<br>Method or attribute name: off(type: 'validCommandChange', callback?: (commands: Array\<AVControlCommandType>) => void);<br>Old version information: 401,{@link,{@link|Class name: AVSessionController;<br>Method or attribute name: off(type: 'validCommandChange', callback?: (commands: Array\<AVControlCommandType>) => void);<br>New version information: 401,6600101,6600103|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: AVSessionController;<br>Method or attribute name: off(type: 'sessionEvent', callback?: (sessionEvent: string, args: {[key: string]: Object}) => void): void;<br>Old version information: 401,{@link,{@link|Class name: AVSessionController;<br>Method or attribute name: off(type: 'sessionEvent', callback?: (sessionEvent: string, args: {[key: string]: Object}) => void): void;<br>New version information: 401,6600101,6600103|@ohos.multimedia.avsession.d.ts|
|Error code changed|Class name: AVSessionController;<br>Method or attribute name: off(type: 'extrasChange', callback?: (extras: {[key: string]: Object}) => void): void;<br>Old version information: 401,{@link,{@link|Class name: AVSessionController;<br>Method or attribute name: off(type: 'extrasChange', callback?: (extras: {[key: string]: Object}) => void): void;<br>New version information: 401,6600101,6600103|@ohos.multimedia.avsession.d.ts|
|Access level changed|Class name: ConnectType;<br>Method or attribute name: CONNECT_TYPE_LOCAL = 1<br>Old version information: |Class name: ConnectType;<br>Method or attribute name: CONNECT_TYPE_LOCAL = 1<br>New version information: systemapi|@ohos.multimedia.audio.d.ts|
|Access level changed|Class name: ConnectType;<br>Method or attribute name: CONNECT_TYPE_DISTRIBUTED = 2<br>Old version information: |Class name: ConnectType;<br>Method or attribute name: CONNECT_TYPE_DISTRIBUTED = 2<br>New version information: systemapi|@ohos.multimedia.audio.d.ts|
|Access level changed|Class name: VolumeGroupInfo;<br>Method or attribute name: readonly groupId: number;<br>Old version information: |Class name: VolumeGroupInfo;<br>Method or attribute name: readonly groupId: number;<br>New version information: systemapi|@ohos.multimedia.audio.d.ts|
|Access level changed|Class name: VolumeGroupInfo;<br>Method or attribute name: readonly mappingId: number;<br>Old version information: |Class name: VolumeGroupInfo;<br>Method or attribute name: readonly mappingId: number;<br>New version information: systemapi|@ohos.multimedia.audio.d.ts|
|Access level changed|Class name: VolumeGroupInfo;<br>Method or attribute name: readonly groupName: string;<br>Old version information: |Class name: VolumeGroupInfo;<br>Method or attribute name: readonly groupName: string;<br>New version information: systemapi|@ohos.multimedia.audio.d.ts|
|Access level changed|Class name: VolumeGroupInfo;<br>Method or attribute name: readonly type: ConnectType;<br>Old version information: |Class name: VolumeGroupInfo;<br>Method or attribute name: readonly type: ConnectType;<br>New version information: systemapi|@ohos.multimedia.audio.d.ts|
|Access level changed|Class name: VolumeEvent;<br>Method or attribute name: interface VolumeEvent<br>Old version information: systemapi|Class name: VolumeEvent;<br>Method or attribute name: interface VolumeEvent<br>New version information: |@ohos.multimedia.audio.d.ts|
|Access level changed|Class name: VolumeEvent;<br>Method or attribute name: volumeGroupId: number;<br>Old version information: |Class name: VolumeEvent;<br>Method or attribute name: volumeGroupId: number;<br>New version information: systemapi|@ohos.multimedia.audio.d.ts|
|Access level changed|Class name: VolumeEvent;<br>Method or attribute name: networkId: string;<br>Old version information: |Class name: VolumeEvent;<br>Method or attribute name: networkId: string;<br>New version information: systemapi|@ohos.multimedia.audio.d.ts|
|Access level changed|Class name: ToneType;<br>Method or attribute name: TONE_TYPE_DIAL_0 = 0<br>Old version information: |Class name: ToneType;<br>Method or attribute name: TONE_TYPE_DIAL_0 = 0<br>New version information: systemapi|@ohos.multimedia.audio.d.ts|
|Access level changed|Class name: ToneType;<br>Method or attribute name: TONE_TYPE_DIAL_1 = 1<br>Old version information: |Class name: ToneType;<br>Method or attribute name: TONE_TYPE_DIAL_1 = 1<br>New version information: systemapi|@ohos.multimedia.audio.d.ts|
|Access level changed|Class name: ToneType;<br>Method or attribute name: TONE_TYPE_DIAL_2 = 2<br>Old version information: |Class name: ToneType;<br>Method or attribute name: TONE_TYPE_DIAL_2 = 2<br>New version information: systemapi|@ohos.multimedia.audio.d.ts|
|Access level changed|Class name: ToneType;<br>Method or attribute name: TONE_TYPE_DIAL_3 = 3<br>Old version information: |Class name: ToneType;<br>Method or attribute name: TONE_TYPE_DIAL_3 = 3<br>New version information: systemapi|@ohos.multimedia.audio.d.ts|
|Access level changed|Class name: ToneType;<br>Method or attribute name: TONE_TYPE_DIAL_4 = 4<br>Old version information: |Class name: ToneType;<br>Method or attribute name: TONE_TYPE_DIAL_4 = 4<br>New version information: systemapi|@ohos.multimedia.audio.d.ts|
|Access level changed|Class name: ToneType;<br>Method or attribute name: TONE_TYPE_DIAL_5 = 5<br>Old version information: |Class name: ToneType;<br>Method or attribute name: TONE_TYPE_DIAL_5 = 5<br>New version information: systemapi|@ohos.multimedia.audio.d.ts|
|Access level changed|Class name: ToneType;<br>Method or attribute name: TONE_TYPE_DIAL_6 = 6<br>Old version information: |Class name: ToneType;<br>Method or attribute name: TONE_TYPE_DIAL_6 = 6<br>New version information: systemapi|@ohos.multimedia.audio.d.ts|
|Access level changed|Class name: ToneType;<br>Method or attribute name: TONE_TYPE_DIAL_7 = 7<br>Old version information: |Class name: ToneType;<br>Method or attribute name: TONE_TYPE_DIAL_7 = 7<br>New version information: systemapi|@ohos.multimedia.audio.d.ts|
|Access level changed|Class name: ToneType;<br>Method or attribute name: TONE_TYPE_DIAL_8 = 8<br>Old version information: |Class name: ToneType;<br>Method or attribute name: TONE_TYPE_DIAL_8 = 8<br>New version information: systemapi|@ohos.multimedia.audio.d.ts|
|Access level changed|Class name: ToneType;<br>Method or attribute name: TONE_TYPE_DIAL_9 = 9<br>Old version information: |Class name: ToneType;<br>Method or attribute name: TONE_TYPE_DIAL_9 = 9<br>New version information: systemapi|@ohos.multimedia.audio.d.ts|
|Access level changed|Class name: ToneType;<br>Method or attribute name: TONE_TYPE_DIAL_S = 10<br>Old version information: |Class name: ToneType;<br>Method or attribute name: TONE_TYPE_DIAL_S = 10<br>New version information: systemapi|@ohos.multimedia.audio.d.ts|
|Access level changed|Class name: ToneType;<br>Method or attribute name: TONE_TYPE_DIAL_P = 11<br>Old version information: |Class name: ToneType;<br>Method or attribute name: TONE_TYPE_DIAL_P = 11<br>New version information: systemapi|@ohos.multimedia.audio.d.ts|
|Access level changed|Class name: ToneType;<br>Method or attribute name: TONE_TYPE_DIAL_A = 12<br>Old version information: |Class name: ToneType;<br>Method or attribute name: TONE_TYPE_DIAL_A = 12<br>New version information: systemapi|@ohos.multimedia.audio.d.ts|
|Access level changed|Class name: ToneType;<br>Method or attribute name: TONE_TYPE_DIAL_B = 13<br>Old version information: |Class name: ToneType;<br>Method or attribute name: TONE_TYPE_DIAL_B = 13<br>New version information: systemapi|@ohos.multimedia.audio.d.ts|
|Access level changed|Class name: ToneType;<br>Method or attribute name: TONE_TYPE_DIAL_C = 14<br>Old version information: |Class name: ToneType;<br>Method or attribute name: TONE_TYPE_DIAL_C = 14<br>New version information: systemapi|@ohos.multimedia.audio.d.ts|
|Access level changed|Class name: ToneType;<br>Method or attribute name: TONE_TYPE_DIAL_D = 15<br>Old version information: |Class name: ToneType;<br>Method or attribute name: TONE_TYPE_DIAL_D = 15<br>New version information: systemapi|@ohos.multimedia.audio.d.ts|
|Access level changed|Class name: ToneType;<br>Method or attribute name: TONE_TYPE_COMMON_SUPERVISORY_DIAL = 100<br>Old version information: |Class name: ToneType;<br>Method or attribute name: TONE_TYPE_COMMON_SUPERVISORY_DIAL = 100<br>New version information: systemapi|@ohos.multimedia.audio.d.ts|
|Access level changed|Class name: ToneType;<br>Method or attribute name: TONE_TYPE_COMMON_SUPERVISORY_BUSY = 101<br>Old version information: |Class name: ToneType;<br>Method or attribute name: TONE_TYPE_COMMON_SUPERVISORY_BUSY = 101<br>New version information: systemapi|@ohos.multimedia.audio.d.ts|
|Access level changed|Class name: ToneType;<br>Method or attribute name: TONE_TYPE_COMMON_SUPERVISORY_CONGESTION = 102<br>Old version information: |Class name: ToneType;<br>Method or attribute name: TONE_TYPE_COMMON_SUPERVISORY_CONGESTION = 102<br>New version information: systemapi|@ohos.multimedia.audio.d.ts|
|Access level changed|Class name: ToneType;<br>Method or attribute name: TONE_TYPE_COMMON_SUPERVISORY_RADIO_ACK = 103<br>Old version information: |Class name: ToneType;<br>Method or attribute name: TONE_TYPE_COMMON_SUPERVISORY_RADIO_ACK = 103<br>New version information: systemapi|@ohos.multimedia.audio.d.ts|
|Access level changed|Class name: ToneType;<br>Method or attribute name: TONE_TYPE_COMMON_SUPERVISORY_RADIO_NOT_AVAILABLE = 104<br>Old version information: |Class name: ToneType;<br>Method or attribute name: TONE_TYPE_COMMON_SUPERVISORY_RADIO_NOT_AVAILABLE = 104<br>New version information: systemapi|@ohos.multimedia.audio.d.ts|
|Access level changed|Class name: ToneType;<br>Method or attribute name: TONE_TYPE_COMMON_SUPERVISORY_CALL_WAITING = 106<br>Old version information: |Class name: ToneType;<br>Method or attribute name: TONE_TYPE_COMMON_SUPERVISORY_CALL_WAITING = 106<br>New version information: systemapi|@ohos.multimedia.audio.d.ts|
|Access level changed|Class name: ToneType;<br>Method or attribute name: TONE_TYPE_COMMON_SUPERVISORY_RINGTONE = 107<br>Old version information: |Class name: ToneType;<br>Method or attribute name: TONE_TYPE_COMMON_SUPERVISORY_RINGTONE = 107<br>New version information: systemapi|@ohos.multimedia.audio.d.ts|
|Access level changed|Class name: ToneType;<br>Method or attribute name: TONE_TYPE_COMMON_PROPRIETARY_BEEP = 200<br>Old version information: |Class name: ToneType;<br>Method or attribute name: TONE_TYPE_COMMON_PROPRIETARY_BEEP = 200<br>New version information: systemapi|@ohos.multimedia.audio.d.ts|
|Access level changed|Class name: ToneType;<br>Method or attribute name: TONE_TYPE_COMMON_PROPRIETARY_ACK = 201<br>Old version information: |Class name: ToneType;<br>Method or attribute name: TONE_TYPE_COMMON_PROPRIETARY_ACK = 201<br>New version information: systemapi|@ohos.multimedia.audio.d.ts|
|Access level changed|Class name: ToneType;<br>Method or attribute name: TONE_TYPE_COMMON_PROPRIETARY_PROMPT = 203<br>Old version information: |Class name: ToneType;<br>Method or attribute name: TONE_TYPE_COMMON_PROPRIETARY_PROMPT = 203<br>New version information: systemapi|@ohos.multimedia.audio.d.ts|
|Access level changed|Class name: ToneType;<br>Method or attribute name: TONE_TYPE_COMMON_PROPRIETARY_DOUBLE_BEEP = 204<br>Old version information: |Class name: ToneType;<br>Method or attribute name: TONE_TYPE_COMMON_PROPRIETARY_DOUBLE_BEEP = 204<br>New version information: systemapi|@ohos.multimedia.audio.d.ts|
|Access level changed|Class name: TonePlayer;<br>Method or attribute name: load(type: ToneType, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: TonePlayer;<br>Method or attribute name: load(type: ToneType, callback: AsyncCallback\<void>): void;<br>New version information: systemapi|@ohos.multimedia.audio.d.ts|
|Access level changed|Class name: TonePlayer;<br>Method or attribute name: load(type: ToneType): Promise\<void>;<br>Old version information: |Class name: TonePlayer;<br>Method or attribute name: load(type: ToneType): Promise\<void>;<br>New version information: systemapi|@ohos.multimedia.audio.d.ts|
|Access level changed|Class name: TonePlayer;<br>Method or attribute name: start(callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: TonePlayer;<br>Method or attribute name: start(callback: AsyncCallback\<void>): void;<br>New version information: systemapi|@ohos.multimedia.audio.d.ts|
|Access level changed|Class name: TonePlayer;<br>Method or attribute name: start(): Promise\<void>;<br>Old version information: |Class name: TonePlayer;<br>Method or attribute name: start(): Promise\<void>;<br>New version information: systemapi|@ohos.multimedia.audio.d.ts|
|Access level changed|Class name: TonePlayer;<br>Method or attribute name: stop(callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: TonePlayer;<br>Method or attribute name: stop(callback: AsyncCallback\<void>): void;<br>New version information: systemapi|@ohos.multimedia.audio.d.ts|
|Access level changed|Class name: TonePlayer;<br>Method or attribute name: stop(): Promise\<void>;<br>Old version information: |Class name: TonePlayer;<br>Method or attribute name: stop(): Promise\<void>;<br>New version information: systemapi|@ohos.multimedia.audio.d.ts|
|Access level changed|Class name: TonePlayer;<br>Method or attribute name: release(callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: TonePlayer;<br>Method or attribute name: release(callback: AsyncCallback\<void>): void;<br>New version information: systemapi|@ohos.multimedia.audio.d.ts|
|Access level changed|Class name: TonePlayer;<br>Method or attribute name: release(): Promise\<void>;<br>Old version information: |Class name: TonePlayer;<br>Method or attribute name: release(): Promise\<void>;<br>New version information: systemapi|@ohos.multimedia.audio.d.ts|
|Access level changed|Class name: avSession;<br>Method or attribute name: function getAllSessionDescriptors(): Promise\<Array\<Readonly\<AVSessionDescriptor>>>;<br>Old version information: |Class name: avSession;<br>Method or attribute name: function getAllSessionDescriptors(): Promise\<Array\<Readonly\<AVSessionDescriptor>>>;<br>New version information: systemapi|@ohos.multimedia.avsession.d.ts|
|Access level changed|Class name: avSession;<br>Method or attribute name: function createController(sessionId: string): Promise\<AVSessionController>;<br>Old version information: |Class name: avSession;<br>Method or attribute name: function createController(sessionId: string): Promise\<AVSessionController>;<br>New version information: systemapi|@ohos.multimedia.avsession.d.ts|
|Access level changed|Class name: avSession;<br>Method or attribute name: function castAudio(session: SessionToken \| 'all', audioDevices: Array\<audio.AudioDeviceDescriptor>): Promise\<void>;<br>Old version information: |Class name: avSession;<br>Method or attribute name: function castAudio(session: SessionToken \| 'all', audioDevices: Array\<audio.AudioDeviceDescriptor>): Promise\<void>;<br>New version information: systemapi|@ohos.multimedia.avsession.d.ts|
|Access level changed|Class name: avSession;<br>Method or attribute name: function sendSystemAVKeyEvent(event: KeyEvent): Promise\<void>;<br>Old version information: |Class name: avSession;<br>Method or attribute name: function sendSystemAVKeyEvent(event: KeyEvent): Promise\<void>;<br>New version information: systemapi|@ohos.multimedia.avsession.d.ts|
|Access level changed|Class name: avSession;<br>Method or attribute name: function sendSystemControlCommand(command: AVControlCommand): Promise\<void>;<br>Old version information: |Class name: avSession;<br>Method or attribute name: function sendSystemControlCommand(command: AVControlCommand): Promise\<void>;<br>New version information: systemapi|@ohos.multimedia.avsession.d.ts|
|Access level changed|Class name: SessionToken;<br>Method or attribute name: sessionId: string;<br>Old version information: |Class name: SessionToken;<br>Method or attribute name: sessionId: string;<br>New version information: systemapi|@ohos.multimedia.avsession.d.ts|
|Access level changed|Class name: AVSessionDescriptor;<br>Method or attribute name: sessionId: string;<br>Old version information: |Class name: AVSessionDescriptor;<br>Method or attribute name: sessionId: string;<br>New version information: systemapi|@ohos.multimedia.avsession.d.ts|
|Access level changed|Class name: SessionToken;<br>Method or attribute name: pid?: number;<br>Old version information: |Class name: SessionToken;<br>Method or attribute name: pid?: number;<br>New version information: systemapi|@ohos.multimedia.avsession.d.ts|
|Access level changed|Class name: SessionToken;<br>Method or attribute name: uid?: number;<br>Old version information: |Class name: SessionToken;<br>Method or attribute name: uid?: number;<br>New version information: systemapi|@ohos.multimedia.avsession.d.ts|
|Access level changed|Class name: AVSessionDescriptor;<br>Method or attribute name: type: AVSessionType;<br>Old version information: |Class name: AVSessionDescriptor;<br>Method or attribute name: type: AVSessionType;<br>New version information: systemapi|@ohos.multimedia.avsession.d.ts|
|Access level changed|Class name: AVSessionDescriptor;<br>Method or attribute name: sessionTag: string;<br>Old version information: |Class name: AVSessionDescriptor;<br>Method or attribute name: sessionTag: string;<br>New version information: systemapi|@ohos.multimedia.avsession.d.ts|
|Access level changed|Class name: AVSessionDescriptor;<br>Method or attribute name: elementName: ElementName;<br>Old version information: |Class name: AVSessionDescriptor;<br>Method or attribute name: elementName: ElementName;<br>New version information: systemapi|@ohos.multimedia.avsession.d.ts|
|Access level changed|Class name: AVSessionDescriptor;<br>Method or attribute name: isActive: boolean;<br>Old version information: |Class name: AVSessionDescriptor;<br>Method or attribute name: isActive: boolean;<br>New version information: systemapi|@ohos.multimedia.avsession.d.ts|
|Access level changed|Class name: AVSessionDescriptor;<br>Method or attribute name: isTopSession: boolean;<br>Old version information: |Class name: AVSessionDescriptor;<br>Method or attribute name: isTopSession: boolean;<br>New version information: systemapi|@ohos.multimedia.avsession.d.ts|
|Access level changed|Class name: AVSessionDescriptor;<br>Method or attribute name: outputDevice: OutputDeviceInfo;<br>Old version information: |Class name: AVSessionDescriptor;<br>Method or attribute name: outputDevice: OutputDeviceInfo;<br>New version information: systemapi|@ohos.multimedia.avsession.d.ts|
|Permission changed|Class name: avSession;<br>Method or attribute name: function getAllSessionDescriptors(): Promise\<Array\<Readonly\<AVSessionDescriptor>>>;<br>Old version information: |Class name: avSession;<br>Method or attribute name: function getAllSessionDescriptors(): Promise\<Array\<Readonly\<AVSessionDescriptor>>>;<br>New version information: ohos.permission.MANAGE_MEDIA_RESOURCES|@ohos.multimedia.avsession.d.ts|
|Permission changed|Class name: avSession;<br>Method or attribute name: function createController(sessionId: string): Promise\<AVSessionController>;<br>Old version information: |Class name: avSession;<br>Method or attribute name: function createController(sessionId: string): Promise\<AVSessionController>;<br>New version information: ohos.permission.MANAGE_MEDIA_RESOURCES|@ohos.multimedia.avsession.d.ts|
|Permission changed|Class name: avSession;<br>Method or attribute name: function castAudio(session: SessionToken \| 'all', audioDevices: Array\<audio.AudioDeviceDescriptor>): Promise\<void>;<br>Old version information: |Class name: avSession;<br>Method or attribute name: function castAudio(session: SessionToken \| 'all', audioDevices: Array\<audio.AudioDeviceDescriptor>): Promise\<void>;<br>New version information: ohos.permission.MANAGE_MEDIA_RESOURCES|@ohos.multimedia.avsession.d.ts|
|Permission changed|Class name: avSession;<br>Method or attribute name: function sendSystemAVKeyEvent(event: KeyEvent): Promise\<void>;<br>Old version information: |Class name: avSession;<br>Method or attribute name: function sendSystemAVKeyEvent(event: KeyEvent): Promise\<void>;<br>New version information: ohos.permission.MANAGE_MEDIA_RESOURCES|@ohos.multimedia.avsession.d.ts|
|Permission changed|Class name: avSession;<br>Method or attribute name: function sendSystemControlCommand(command: AVControlCommand): Promise\<void>;<br>Old version information: |Class name: avSession;<br>Method or attribute name: function sendSystemControlCommand(command: AVControlCommand): Promise\<void>;<br>New version information: ohos.permission.MANAGE_MEDIA_RESOURCES|@ohos.multimedia.avsession.d.ts|
|Permission changed|Class name: SessionToken;<br>Method or attribute name: sessionId: string;<br>Old version information: |Class name: SessionToken;<br>Method or attribute name: sessionId: string;<br>New version information: ohos.permission.MANAGE_MEDIA_RESOURCES|@ohos.multimedia.avsession.d.ts|
|Permission changed|Class name: SessionToken;<br>Method or attribute name: pid?: number;<br>Old version information: |Class name: SessionToken;<br>Method or attribute name: pid?: number;<br>New version information: ohos.permission.MANAGE_MEDIA_RESOURCES|@ohos.multimedia.avsession.d.ts|
|Permission changed|Class name: SessionToken;<br>Method or attribute name: uid?: number;<br>Old version information: |Class name: SessionToken;<br>Method or attribute name: uid?: number;<br>New version information: ohos.permission.MANAGE_MEDIA_RESOURCES|@ohos.multimedia.avsession.d.ts|
|Type changed|Class name: AudioRendererInfo;<br>Method or attribute name: content?: ContentType;<br>Old version information: |Class name: AudioRendererInfo;<br>Method or attribute name: content?: ContentType;<br>New version information: ?ContentType|@ohos.multimedia.audio.d.ts|
|Type changed|Class name: SessionToken;<br>Method or attribute name: sessionId: string;<br>Old version information: |Class name: SessionToken;<br>Method or attribute name: sessionId: string;<br>New version information: string|@ohos.multimedia.avsession.d.ts|
|Type changed|Class name: AVSessionDescriptor;<br>Method or attribute name: sessionId: string;<br>Old version information: |Class name: AVSessionDescriptor;<br>Method or attribute name: sessionId: string;<br>New version information: string|@ohos.multimedia.avsession.d.ts|
|Type changed|Class name: SessionToken;<br>Method or attribute name: pid?: number;<br>Old version information: |Class name: SessionToken;<br>Method or attribute name: pid?: number;<br>New version information: ?number|@ohos.multimedia.avsession.d.ts|
|Type changed|Class name: SessionToken;<br>Method or attribute name: uid?: number;<br>Old version information: |Class name: SessionToken;<br>Method or attribute name: uid?: number;<br>New version information: ?number|@ohos.multimedia.avsession.d.ts|
|Type changed|Class name: AVMetadata;<br>Method or attribute name: assetId: string;<br>Old version information: |Class name: AVMetadata;<br>Method or attribute name: assetId: string;<br>New version information: string|@ohos.multimedia.avsession.d.ts|
|Type changed|Class name: AVMetadata;<br>Method or attribute name: title?: string;<br>Old version information: |Class name: AVMetadata;<br>Method or attribute name: title?: string;<br>New version information: ?string|@ohos.multimedia.avsession.d.ts|
|Type changed|Class name: AVMediaDescription;<br>Method or attribute name: title?: string;<br>Old version information: |Class name: AVMediaDescription;<br>Method or attribute name: title?: string;<br>New version information: ?string|@ohos.multimedia.avsession.d.ts|
|Type changed|Class name: AVMetadata;<br>Method or attribute name: artist?: string;<br>Old version information: |Class name: AVMetadata;<br>Method or attribute name: artist?: string;<br>New version information: ?string|@ohos.multimedia.avsession.d.ts|
|Type changed|Class name: AVMetadata;<br>Method or attribute name: author?: string;<br>Old version information: |Class name: AVMetadata;<br>Method or attribute name: author?: string;<br>New version information: ?string|@ohos.multimedia.avsession.d.ts|
|Type changed|Class name: AVMetadata;<br>Method or attribute name: album?: string;<br>Old version information: |Class name: AVMetadata;<br>Method or attribute name: album?: string;<br>New version information: ?string|@ohos.multimedia.avsession.d.ts|
|Type changed|Class name: AVMetadata;<br>Method or attribute name: writer?: string;<br>Old version information: |Class name: AVMetadata;<br>Method or attribute name: writer?: string;<br>New version information: ?string|@ohos.multimedia.avsession.d.ts|
|Type changed|Class name: AVMetadata;<br>Method or attribute name: composer?: string;<br>Old version information: |Class name: AVMetadata;<br>Method or attribute name: composer?: string;<br>New version information: ?string|@ohos.multimedia.avsession.d.ts|
|Type changed|Class name: AVMetadata;<br>Method or attribute name: duration?: number;<br>Old version information: |Class name: AVMetadata;<br>Method or attribute name: duration?: number;<br>New version information: ?number|@ohos.multimedia.avsession.d.ts|
|Type changed|Class name: AVMetadata;<br>Method or attribute name: publishDate?: Date;<br>Old version information: |Class name: AVMetadata;<br>Method or attribute name: publishDate?: Date;<br>New version information: ?Date|@ohos.multimedia.avsession.d.ts|
|Type changed|Class name: AVMetadata;<br>Method or attribute name: subtitle?: string;<br>Old version information: |Class name: AVMetadata;<br>Method or attribute name: subtitle?: string;<br>New version information: ?string|@ohos.multimedia.avsession.d.ts|
|Type changed|Class name: AVMediaDescription;<br>Method or attribute name: subtitle?: string;<br>Old version information: |Class name: AVMediaDescription;<br>Method or attribute name: subtitle?: string;<br>New version information: ?string|@ohos.multimedia.avsession.d.ts|
|Type changed|Class name: AVMetadata;<br>Method or attribute name: description?: string;<br>Old version information: |Class name: AVMetadata;<br>Method or attribute name: description?: string;<br>New version information: ?string|@ohos.multimedia.avsession.d.ts|
|Type changed|Class name: AVMediaDescription;<br>Method or attribute name: description?: string;<br>Old version information: |Class name: AVMediaDescription;<br>Method or attribute name: description?: string;<br>New version information: ?string|@ohos.multimedia.avsession.d.ts|
|Type changed|Class name: AVMetadata;<br>Method or attribute name: lyric?: string;<br>Old version information: |Class name: AVMetadata;<br>Method or attribute name: lyric?: string;<br>New version information: ?string|@ohos.multimedia.avsession.d.ts|
|Type changed|Class name: AVMetadata;<br>Method or attribute name: previousAssetId?: string;<br>Old version information: |Class name: AVMetadata;<br>Method or attribute name: previousAssetId?: string;<br>New version information: ?string|@ohos.multimedia.avsession.d.ts|
|Type changed|Class name: AVMetadata;<br>Method or attribute name: nextAssetId?: string;<br>Old version information: |Class name: AVMetadata;<br>Method or attribute name: nextAssetId?: string;<br>New version information: ?string|@ohos.multimedia.avsession.d.ts|
|Type changed|Class name: AVMediaDescription;<br>Method or attribute name: mediaId: string;<br>Old version information: |Class name: AVMediaDescription;<br>Method or attribute name: mediaId: string;<br>New version information: string|@ohos.multimedia.avsession.d.ts|
|Type changed|Class name: AVMediaDescription;<br>Method or attribute name: iconUri?: string;<br>Old version information: |Class name: AVMediaDescription;<br>Method or attribute name: iconUri?: string;<br>New version information: ?string|@ohos.multimedia.avsession.d.ts|
|Type changed|Class name: AVMediaDescription;<br>Method or attribute name: mediaUri?: string;<br>Old version information: |Class name: AVMediaDescription;<br>Method or attribute name: mediaUri?: string;<br>New version information: ?string|@ohos.multimedia.avsession.d.ts|
|Type changed|Class name: AVQueueItem;<br>Method or attribute name: itemId: number;<br>Old version information: |Class name: AVQueueItem;<br>Method or attribute name: itemId: number;<br>New version information: number|@ohos.multimedia.avsession.d.ts|
|Type changed|Class name: AVPlaybackState;<br>Method or attribute name: speed?: number;<br>Old version information: |Class name: AVPlaybackState;<br>Method or attribute name: speed?: number;<br>New version information: ?number|@ohos.multimedia.avsession.d.ts|
|Type changed|Class name: AVPlaybackState;<br>Method or attribute name: bufferedTime?: number;<br>Old version information: |Class name: AVPlaybackState;<br>Method or attribute name: bufferedTime?: number;<br>New version information: ?number|@ohos.multimedia.avsession.d.ts|
|Type changed|Class name: AVPlaybackState;<br>Method or attribute name: isFavorite?: boolean;<br>Old version information: |Class name: AVPlaybackState;<br>Method or attribute name: isFavorite?: boolean;<br>New version information: ?boolean|@ohos.multimedia.avsession.d.ts|
|Type changed|Class name: AVPlaybackState;<br>Method or attribute name: activeItemId?: number;<br>Old version information: |Class name: AVPlaybackState;<br>Method or attribute name: activeItemId?: number;<br>New version information: ?number|@ohos.multimedia.avsession.d.ts|
|Type changed|Class name: PlaybackPosition;<br>Method or attribute name: elapsedTime: number;<br>Old version information: |Class name: PlaybackPosition;<br>Method or attribute name: elapsedTime: number;<br>New version information: number|@ohos.multimedia.avsession.d.ts|
|Type changed|Class name: PlaybackPosition;<br>Method or attribute name: updateTime: number;<br>Old version information: |Class name: PlaybackPosition;<br>Method or attribute name: updateTime: number;<br>New version information: number|@ohos.multimedia.avsession.d.ts|
|Type changed|Class name: AVSessionDescriptor;<br>Method or attribute name: sessionTag: string;<br>Old version information: |Class name: AVSessionDescriptor;<br>Method or attribute name: sessionTag: string;<br>New version information: string|@ohos.multimedia.avsession.d.ts|
|Type changed|Class name: AVSessionDescriptor;<br>Method or attribute name: isActive: boolean;<br>Old version information: |Class name: AVSessionDescriptor;<br>Method or attribute name: isActive: boolean;<br>New version information: boolean|@ohos.multimedia.avsession.d.ts|
|Type changed|Class name: AVSessionDescriptor;<br>Method or attribute name: isTopSession: boolean;<br>Old version information: |Class name: AVSessionDescriptor;<br>Method or attribute name: isTopSession: boolean;<br>New version information: boolean|@ohos.multimedia.avsession.d.ts|
|Function changed|Class name: AudioRendererInfo;<br>Method or attribute name: content: ContentType;|Class name: AudioRendererInfo;<br>Method or attribute name: content?: ContentType;|@ohos.multimedia.audio.d.ts|
|Function changed|Class name: SessionToken;<br>Method or attribute name: pid: number;|Class name: SessionToken;<br>Method or attribute name: pid?: number;|@ohos.multimedia.avsession.d.ts|
|Function changed|Class name: SessionToken;<br>Method or attribute name: uid: number;|Class name: SessionToken;<br>Method or attribute name: uid?: number;|@ohos.multimedia.avsession.d.ts|
|Function changed|Class name: AVMediaDescription;<br>Method or attribute name: icon?: image.PixelMap \| string;|Class name: AVMediaDescription;<br>Method or attribute name: icon?: image.PixelMap;|@ohos.multimedia.avsession.d.ts|
|Function changed|Class name: CameraInput;<br>Method or attribute name: on(type: 'error', camera: CameraDevice, callback: ErrorCallback\<BusinessError>): void;|Class name: CameraInput;<br>Method or attribute name: on(type: 'error', camera: CameraDevice, callback: ErrorCallback): void;|@ohos.multimedia.camera.d.ts|
|Function changed|Class name: CaptureSession;<br>Method or attribute name: on(type: 'error', callback: ErrorCallback\<BusinessError>): void;|Class name: CaptureSession;<br>Method or attribute name: on(type: 'error', callback: ErrorCallback): void;|@ohos.multimedia.camera.d.ts|
|Function changed|Class name: PreviewOutput;<br>Method or attribute name: on(type: 'error', callback: ErrorCallback\<BusinessError>): void;|Class name: PreviewOutput;<br>Method or attribute name: on(type: 'error', callback: ErrorCallback): void;|@ohos.multimedia.camera.d.ts|
|Function changed|Class name: PhotoOutput;<br>Method or attribute name: on(type: 'error', callback: ErrorCallback\<BusinessError>): void;|Class name: PhotoOutput;<br>Method or attribute name: on(type: 'error', callback: ErrorCallback): void;|@ohos.multimedia.camera.d.ts|
|Function changed|Class name: VideoOutput;<br>Method or attribute name: on(type: 'error', callback: ErrorCallback\<BusinessError>): void;|Class name: VideoOutput;<br>Method or attribute name: on(type: 'error', callback: ErrorCallback): void;|@ohos.multimedia.camera.d.ts|
|Function changed|Class name: MetadataOutput;<br>Method or attribute name: on(type: 'error', callback: ErrorCallback\<BusinessError>): void;|Class name: MetadataOutput;<br>Method or attribute name: on(type: 'error', callback: ErrorCallback): void;|@ohos.multimedia.camera.d.ts|
| Change Type | Old Version | New Version | d.ts File |
| ---- | ------ | ------ | -------- |
|Added|NA|Class name: Support;<br>Method or attribute name: COMMON_EVENT_CHARGE_IDLE_MODE_CHANGED = 'usual.event.CHARGE_IDLE_MODE_CHANGED'|@ohos.commonEventManager.d.ts|
|Added|NA|Class name: emitter;<br>Method or attribute name: function off(eventId: number, callback: Callback\<EventData>): void;|@ohos.events.emitter.d.ts|
|Added|NA|Class name: notificationSubscribe;<br>Method or attribute name: function remove(hashCodes: Array\<String>, reason: RemoveReason, callback: AsyncCallback\<void>): void;|@ohos.notificationSubscribe.d.ts|
|Added|NA|Class name: notificationSubscribe;<br>Method or attribute name: function remove(hashCodes: Array\<String>, reason: RemoveReason): Promise\<void>;|@ohos.notificationSubscribe.d.ts|
|Error code changed|Class name: reminderAgentManager;<br>Method or attribute name: function publishReminder(reminderReq: ReminderRequest, callback: AsyncCallback\<number>): void;<br>Old version information: 401|Class name: reminderAgentManager;<br>Method or attribute name: function publishReminder(reminderReq: ReminderRequest, callback: AsyncCallback\<number>): void;<br>New version information: 401,1700001,1700002|@ohos.reminderAgentManager.d.ts|
|Error code changed|Class name: reminderAgentManager;<br>Method or attribute name: function publishReminder(reminderReq: ReminderRequest): Promise\<number>;<br>Old version information: 401|Class name: reminderAgentManager;<br>Method or attribute name: function publishReminder(reminderReq: ReminderRequest): Promise\<number>;<br>New version information: 401,1700001,1700002|@ohos.reminderAgentManager.d.ts|
|Error code changed|Class name: reminderAgentManager;<br>Method or attribute name: function cancelReminder(reminderId: number, callback: AsyncCallback\<void>): void;<br>Old version information: 401|Class name: reminderAgentManager;<br>Method or attribute name: function cancelReminder(reminderId: number, callback: AsyncCallback\<void>): void;<br>New version information: 401,1700003,1700004|@ohos.reminderAgentManager.d.ts|
|Error code changed|Class name: reminderAgentManager;<br>Method or attribute name: function cancelReminder(reminderId: number): Promise\<void>;<br>Old version information: 401|Class name: reminderAgentManager;<br>Method or attribute name: function cancelReminder(reminderId: number): Promise\<void>;<br>New version information: 401,1700003,1700004|@ohos.reminderAgentManager.d.ts|
|Error code changed|Class name: reminderAgentManager;<br>Method or attribute name: function getValidReminders(callback: AsyncCallback\<Array\<ReminderRequest>>): void;<br>Old version information: 401|Class name: reminderAgentManager;<br>Method or attribute name: function getValidReminders(callback: AsyncCallback\<Array\<ReminderRequest>>): void;<br>New version information: 401,1700004|@ohos.reminderAgentManager.d.ts|
|Error code changed|Class name: reminderAgentManager;<br>Method or attribute name: function getValidReminders(): Promise\<Array\<ReminderRequest>>;<br>Old version information: 401|Class name: reminderAgentManager;<br>Method or attribute name: function getValidReminders(): Promise\<Array\<ReminderRequest>>;<br>New version information: 401,1700004|@ohos.reminderAgentManager.d.ts|
|Error code changed|Class name: reminderAgentManager;<br>Method or attribute name: function cancelAllReminders(callback: AsyncCallback\<void>): void;<br>Old version information: 401|Class name: reminderAgentManager;<br>Method or attribute name: function cancelAllReminders(callback: AsyncCallback\<void>): void;<br>New version information: 401,1700004|@ohos.reminderAgentManager.d.ts|
|Error code changed|Class name: reminderAgentManager;<br>Method or attribute name: function cancelAllReminders(): Promise\<void>;<br>Old version information: 401|Class name: reminderAgentManager;<br>Method or attribute name: function cancelAllReminders(): Promise\<void>;<br>New version information: 401,1700004|@ohos.reminderAgentManager.d.ts|
|Access level changed|Class name: notification;<br>Method or attribute name: function publish(request: NotificationRequest, userId: number): Promise\<void>;<br>Old version information: |Class name: notification;<br>Method or attribute name: function publish(request: NotificationRequest, userId: number): Promise\<void>;<br>New version information: systemapi|@ohos.notification.d.ts|
|Access level changed|Class name: notification;<br>Method or attribute name: function isNotificationEnabled(userId: number): Promise\<boolean>;<br>Old version information: |Class name: notification;<br>Method or attribute name: function isNotificationEnabled(userId: number): Promise\<boolean>;<br>New version information: systemapi|@ohos.notification.d.ts|
|Access level changed|Class name: notification;<br>Method or attribute name: function removeAll(userId: number): Promise\<void>;<br>Old version information: |Class name: notification;<br>Method or attribute name: function removeAll(userId: number): Promise\<void>;<br>New version information: systemapi|@ohos.notification.d.ts|
|Access level changed|Class name: notification;<br>Method or attribute name: function removeGroupByBundle(bundle: BundleOption, groupName: string): Promise\<void>;<br>Old version information: |Class name: notification;<br>Method or attribute name: function removeGroupByBundle(bundle: BundleOption, groupName: string): Promise\<void>;<br>New version information: systemapi|@ohos.notification.d.ts|
|Access level changed|Class name: notification;<br>Method or attribute name: function setDoNotDisturbDate(date: DoNotDisturbDate): Promise\<void>;<br>Old version information: |Class name: notification;<br>Method or attribute name: function setDoNotDisturbDate(date: DoNotDisturbDate): Promise\<void>;<br>New version information: systemapi|@ohos.notification.d.ts|
|Access level changed|Class name: notification;<br>Method or attribute name: function setDoNotDisturbDate(date: DoNotDisturbDate, userId: number): Promise\<void>;<br>Old version information: |Class name: notification;<br>Method or attribute name: function setDoNotDisturbDate(date: DoNotDisturbDate, userId: number): Promise\<void>;<br>New version information: systemapi|@ohos.notification.d.ts|
|Access level changed|Class name: notification;<br>Method or attribute name: function getDoNotDisturbDate(): Promise\<DoNotDisturbDate>;<br>Old version information: |Class name: notification;<br>Method or attribute name: function getDoNotDisturbDate(): Promise\<DoNotDisturbDate>;<br>New version information: systemapi|@ohos.notification.d.ts|
|Access level changed|Class name: notification;<br>Method or attribute name: function getDoNotDisturbDate(userId: number): Promise\<DoNotDisturbDate>;<br>Old version information: |Class name: notification;<br>Method or attribute name: function getDoNotDisturbDate(userId: number): Promise\<DoNotDisturbDate>;<br>New version information: systemapi|@ohos.notification.d.ts|
|Access level changed|Class name: notification;<br>Method or attribute name: function supportDoNotDisturbMode(): Promise\<boolean>;<br>Old version information: |Class name: notification;<br>Method or attribute name: function supportDoNotDisturbMode(): Promise\<boolean>;<br>New version information: systemapi|@ohos.notification.d.ts|
|Access level changed|Class name: notification;<br>Method or attribute name: function enableDistributed(enable: boolean): Promise\<void>;<br>Old version information: |Class name: notification;<br>Method or attribute name: function enableDistributed(enable: boolean): Promise\<void>;<br>New version information: systemapi|@ohos.notification.d.ts|
|Access level changed|Class name: notification;<br>Method or attribute name: function enableDistributedByBundle(bundle: BundleOption, enable: boolean): Promise\<void>;<br>Old version information: |Class name: notification;<br>Method or attribute name: function enableDistributedByBundle(bundle: BundleOption, enable: boolean): Promise\<void>;<br>New version information: systemapi|@ohos.notification.d.ts|
|Access level changed|Class name: notification;<br>Method or attribute name: function isDistributedEnabledByBundle(bundle: BundleOption): Promise\<boolean>;<br>Old version information: |Class name: notification;<br>Method or attribute name: function isDistributedEnabledByBundle(bundle: BundleOption): Promise\<boolean>;<br>New version information: systemapi|@ohos.notification.d.ts|
|Access level changed|Class name: notification;<br>Method or attribute name: function getDeviceRemindType(): Promise\<DeviceRemindType>;<br>Old version information: |Class name: notification;<br>Method or attribute name: function getDeviceRemindType(): Promise\<DeviceRemindType>;<br>New version information: systemapi|@ohos.notification.d.ts|
|Access level changed|Class name: DoNotDisturbType;<br>Method or attribute name: TYPE_NONE = 0<br>Old version information: |Class name: DoNotDisturbType;<br>Method or attribute name: TYPE_NONE = 0<br>New version information: systemapi|@ohos.notification.d.ts|
|Access level changed|Class name: DoNotDisturbType;<br>Method or attribute name: TYPE_ONCE = 1<br>Old version information: |Class name: DoNotDisturbType;<br>Method or attribute name: TYPE_ONCE = 1<br>New version information: systemapi|@ohos.notification.d.ts|
|Access level changed|Class name: DoNotDisturbType;<br>Method or attribute name: TYPE_DAILY = 2<br>Old version information: |Class name: DoNotDisturbType;<br>Method or attribute name: TYPE_DAILY = 2<br>New version information: systemapi|@ohos.notification.d.ts|
|Access level changed|Class name: DoNotDisturbType;<br>Method or attribute name: TYPE_CLEARLY = 3<br>Old version information: |Class name: DoNotDisturbType;<br>Method or attribute name: TYPE_CLEARLY = 3<br>New version information: systemapi|@ohos.notification.d.ts|
|Access level changed|Class name: DoNotDisturbDate;<br>Method or attribute name: type: DoNotDisturbType;<br>Old version information: |Class name: DoNotDisturbDate;<br>Method or attribute name: type: DoNotDisturbType;<br>New version information: systemapi|@ohos.notification.d.ts|
|Access level changed|Class name: DoNotDisturbDate;<br>Method or attribute name: begin: Date;<br>Old version information: |Class name: DoNotDisturbDate;<br>Method or attribute name: begin: Date;<br>New version information: systemapi|@ohos.notification.d.ts|
|Access level changed|Class name: DoNotDisturbDate;<br>Method or attribute name: end: Date;<br>Old version information: |Class name: DoNotDisturbDate;<br>Method or attribute name: end: Date;<br>New version information: systemapi|@ohos.notification.d.ts|
|Access level changed|Class name: DeviceRemindType;<br>Method or attribute name: IDLE_DONOT_REMIND = 0<br>Old version information: |Class name: DeviceRemindType;<br>Method or attribute name: IDLE_DONOT_REMIND = 0<br>New version information: systemapi|@ohos.notification.d.ts|
|Access level changed|Class name: DeviceRemindType;<br>Method or attribute name: IDLE_REMIND = 1<br>Old version information: |Class name: DeviceRemindType;<br>Method or attribute name: IDLE_REMIND = 1<br>New version information: systemapi|@ohos.notification.d.ts|
|Access level changed|Class name: DeviceRemindType;<br>Method or attribute name: ACTIVE_DONOT_REMIND = 2<br>Old version information: |Class name: DeviceRemindType;<br>Method or attribute name: ACTIVE_DONOT_REMIND = 2<br>New version information: systemapi|@ohos.notification.d.ts|
|Access level changed|Class name: DeviceRemindType;<br>Method or attribute name: ACTIVE_REMIND = 3<br>Old version information: |Class name: DeviceRemindType;<br>Method or attribute name: ACTIVE_REMIND = 3<br>New version information: systemapi|@ohos.notification.d.ts|
|Access level changed|Class name: SourceType;<br>Method or attribute name: TYPE_NORMAL = 0<br>Old version information: |Class name: SourceType;<br>Method or attribute name: TYPE_NORMAL = 0<br>New version information: systemapi|@ohos.notification.d.ts|
|Access level changed|Class name: SourceType;<br>Method or attribute name: TYPE_CONTINUOUS = 1<br>Old version information: |Class name: SourceType;<br>Method or attribute name: TYPE_CONTINUOUS = 1<br>New version information: systemapi|@ohos.notification.d.ts|
|Access level changed|Class name: SourceType;<br>Method or attribute name: TYPE_TIMER = 2<br>Old version information: |Class name: SourceType;<br>Method or attribute name: TYPE_TIMER = 2<br>New version information: systemapi|@ohos.notification.d.ts|
|Access level changed|Class name: RemoveReason;<br>Method or attribute name: CLICK_REASON_REMOVE = 1<br>Old version information: |Class name: RemoveReason;<br>Method or attribute name: CLICK_REASON_REMOVE = 1<br>New version information: systemapi|@ohos.notification.d.ts|
|Access level changed|Class name: RemoveReason;<br>Method or attribute name: CANCEL_REASON_REMOVE = 2<br>Old version information: |Class name: RemoveReason;<br>Method or attribute name: CANCEL_REASON_REMOVE = 2<br>New version information: systemapi|@ohos.notification.d.ts|
|Access level changed|Class name: NotificationCheckInfo;<br>Method or attribute name: bundleName: string;<br>Old version information: |Class name: NotificationCheckInfo;<br>Method or attribute name: bundleName: string;<br>New version information: systemapi|@ohos.notificationManager.d.ts|
|Access level changed|Class name: NotificationCheckInfo;<br>Method or attribute name: notificationId: number;<br>Old version information: |Class name: NotificationCheckInfo;<br>Method or attribute name: notificationId: number;<br>New version information: systemapi|@ohos.notificationManager.d.ts|
|Access level changed|Class name: NotificationCheckInfo;<br>Method or attribute name: contentType: ContentType;<br>Old version information: |Class name: NotificationCheckInfo;<br>Method or attribute name: contentType: ContentType;<br>New version information: systemapi|@ohos.notificationManager.d.ts|
|Access level changed|Class name: NotificationCheckResult;<br>Method or attribute name: code: number;<br>Old version information: |Class name: NotificationCheckResult;<br>Method or attribute name: code: number;<br>New version information: systemapi|@ohos.notificationManager.d.ts|
|Access level changed|Class name: NotificationCheckResult;<br>Method or attribute name: message: string;<br>Old version information: |Class name: NotificationCheckResult;<br>Method or attribute name: message: string;<br>New version information: systemapi|@ohos.notificationManager.d.ts|
|Access level changed|Class name: DoNotDisturbType;<br>Method or attribute name: TYPE_NONE = 0<br>Old version information: |Class name: DoNotDisturbType;<br>Method or attribute name: TYPE_NONE = 0<br>New version information: systemapi|@ohos.notificationManager.d.ts|
|Access level changed|Class name: DoNotDisturbType;<br>Method or attribute name: TYPE_ONCE = 1<br>Old version information: |Class name: DoNotDisturbType;<br>Method or attribute name: TYPE_ONCE = 1<br>New version information: systemapi|@ohos.notificationManager.d.ts|
|Access level changed|Class name: DoNotDisturbType;<br>Method or attribute name: TYPE_DAILY = 2<br>Old version information: |Class name: DoNotDisturbType;<br>Method or attribute name: TYPE_DAILY = 2<br>New version information: systemapi|@ohos.notificationManager.d.ts|
|Access level changed|Class name: DoNotDisturbType;<br>Method or attribute name: TYPE_CLEARLY = 3<br>Old version information: |Class name: DoNotDisturbType;<br>Method or attribute name: TYPE_CLEARLY = 3<br>New version information: systemapi|@ohos.notificationManager.d.ts|
|Access level changed|Class name: DoNotDisturbDate;<br>Method or attribute name: type: DoNotDisturbType;<br>Old version information: |Class name: DoNotDisturbDate;<br>Method or attribute name: type: DoNotDisturbType;<br>New version information: systemapi|@ohos.notificationManager.d.ts|
|Access level changed|Class name: DoNotDisturbDate;<br>Method or attribute name: begin: Date;<br>Old version information: |Class name: DoNotDisturbDate;<br>Method or attribute name: begin: Date;<br>New version information: systemapi|@ohos.notificationManager.d.ts|
|Access level changed|Class name: DoNotDisturbDate;<br>Method or attribute name: end: Date;<br>Old version information: |Class name: DoNotDisturbDate;<br>Method or attribute name: end: Date;<br>New version information: systemapi|@ohos.notificationManager.d.ts|
|Access level changed|Class name: DeviceRemindType;<br>Method or attribute name: IDLE_DONOT_REMIND = 0<br>Old version information: |Class name: DeviceRemindType;<br>Method or attribute name: IDLE_DONOT_REMIND = 0<br>New version information: systemapi|@ohos.notificationManager.d.ts|
|Access level changed|Class name: DeviceRemindType;<br>Method or attribute name: IDLE_REMIND = 1<br>Old version information: |Class name: DeviceRemindType;<br>Method or attribute name: IDLE_REMIND = 1<br>New version information: systemapi|@ohos.notificationManager.d.ts|
|Access level changed|Class name: DeviceRemindType;<br>Method or attribute name: ACTIVE_DONOT_REMIND = 2<br>Old version information: |Class name: DeviceRemindType;<br>Method or attribute name: ACTIVE_DONOT_REMIND = 2<br>New version information: systemapi|@ohos.notificationManager.d.ts|
|Access level changed|Class name: DeviceRemindType;<br>Method or attribute name: ACTIVE_REMIND = 3<br>Old version information: |Class name: DeviceRemindType;<br>Method or attribute name: ACTIVE_REMIND = 3<br>New version information: systemapi|@ohos.notificationManager.d.ts|
|Access level changed|Class name: SourceType;<br>Method or attribute name: TYPE_NORMAL = 0<br>Old version information: |Class name: SourceType;<br>Method or attribute name: TYPE_NORMAL = 0<br>New version information: systemapi|@ohos.notificationManager.d.ts|
|Access level changed|Class name: SourceType;<br>Method or attribute name: TYPE_CONTINUOUS = 1<br>Old version information: |Class name: SourceType;<br>Method or attribute name: TYPE_CONTINUOUS = 1<br>New version information: systemapi|@ohos.notificationManager.d.ts|
|Access level changed|Class name: SourceType;<br>Method or attribute name: TYPE_TIMER = 2<br>Old version information: |Class name: SourceType;<br>Method or attribute name: TYPE_TIMER = 2<br>New version information: systemapi|@ohos.notificationManager.d.ts|
|Access level changed|Class name: notificationSubscribe;<br>Method or attribute name: export type BundleOption = _BundleOption;<br>Old version information: |Class name: notificationSubscribe;<br>Method or attribute name: export type BundleOption = _BundleOption;<br>New version information: systemapi|@ohos.notificationSubscribe.d.ts|
|Access level changed|Class name: NotificationKey;<br>Method or attribute name: id: number;<br>Old version information: |Class name: NotificationKey;<br>Method or attribute name: id: number;<br>New version information: systemapi|@ohos.notificationSubscribe.d.ts|
|Access level changed|Class name: NotificationKey;<br>Method or attribute name: label?: string;<br>Old version information: |Class name: NotificationKey;<br>Method or attribute name: label?: string;<br>New version information: systemapi|@ohos.notificationSubscribe.d.ts|
|Access level changed|Class name: RemoveReason;<br>Method or attribute name: CLICK_REASON_REMOVE = 1<br>Old version information: |Class name: RemoveReason;<br>Method or attribute name: CLICK_REASON_REMOVE = 1<br>New version information: systemapi|@ohos.notificationSubscribe.d.ts|
|Access level changed|Class name: RemoveReason;<br>Method or attribute name: CANCEL_REASON_REMOVE = 2<br>Old version information: |Class name: RemoveReason;<br>Method or attribute name: CANCEL_REASON_REMOVE = 2<br>New version information: systemapi|@ohos.notificationSubscribe.d.ts|
|Access level changed|Class name: NotificationSorting;<br>Method or attribute name: readonly slot: NotificationSlot;<br>Old version information: |Class name: NotificationSorting;<br>Method or attribute name: readonly slot: NotificationSlot;<br>New version information: systemapi|notificationSorting.d.ts|
|Access level changed|Class name: NotificationSorting;<br>Method or attribute name: readonly hashCode: string;<br>Old version information: |Class name: NotificationSorting;<br>Method or attribute name: readonly hashCode: string;<br>New version information: systemapi|notificationSorting.d.ts|
|Access level changed|Class name: NotificationSorting;<br>Method or attribute name: readonly ranking: number;<br>Old version information: |Class name: NotificationSorting;<br>Method or attribute name: readonly ranking: number;<br>New version information: systemapi|notificationSorting.d.ts|
|Access level changed|Class name: NotificationSortingMap;<br>Method or attribute name: readonly sortings: { [key: string]: NotificationSorting };<br>Old version information: |Class name: NotificationSortingMap;<br>Method or attribute name: readonly sortings: { [key: string]: NotificationSorting };<br>New version information: systemapi|notificationSortingMap.d.ts|
|Access level changed|Class name: NotificationSortingMap;<br>Method or attribute name: readonly sortedHashCode: Array\<string>;<br>Old version information: |Class name: NotificationSortingMap;<br>Method or attribute name: readonly sortedHashCode: Array\<string>;<br>New version information: systemapi|notificationSortingMap.d.ts|
|Access level changed|Class name: NotificationSubscribeInfo;<br>Method or attribute name: bundleNames?: Array\<string>;<br>Old version information: |Class name: NotificationSubscribeInfo;<br>Method or attribute name: bundleNames?: Array\<string>;<br>New version information: systemapi|notificationSubscribeInfo.d.ts|
|Access level changed|Class name: NotificationSubscribeInfo;<br>Method or attribute name: userId?: number;<br>Old version information: |Class name: NotificationSubscribeInfo;<br>Method or attribute name: userId?: number;<br>New version information: systemapi|notificationSubscribeInfo.d.ts|
|Access level changed|Class name: NotificationSubscriber;<br>Method or attribute name: onConsume?: (data: SubscribeCallbackData) => void;<br>Old version information: |Class name: NotificationSubscriber;<br>Method or attribute name: onConsume?: (data: SubscribeCallbackData) => void;<br>New version information: systemapi|notificationSubscriber.d.ts|
|Access level changed|Class name: NotificationSubscriber;<br>Method or attribute name: onCancel?: (data: SubscribeCallbackData) => void;<br>Old version information: |Class name: NotificationSubscriber;<br>Method or attribute name: onCancel?: (data: SubscribeCallbackData) => void;<br>New version information: systemapi|notificationSubscriber.d.ts|
|Access level changed|Class name: NotificationSubscriber;<br>Method or attribute name: onUpdate?: (data: NotificationSortingMap) => void;<br>Old version information: |Class name: NotificationSubscriber;<br>Method or attribute name: onUpdate?: (data: NotificationSortingMap) => void;<br>New version information: systemapi|notificationSubscriber.d.ts|
|Access level changed|Class name: NotificationSubscriber;<br>Method or attribute name: onConnect?: () => void;<br>Old version information: |Class name: NotificationSubscriber;<br>Method or attribute name: onConnect?: () => void;<br>New version information: systemapi|notificationSubscriber.d.ts|
|Access level changed|Class name: NotificationSubscriber;<br>Method or attribute name: onDisconnect?: () => void;<br>Old version information: |Class name: NotificationSubscriber;<br>Method or attribute name: onDisconnect?: () => void;<br>New version information: systemapi|notificationSubscriber.d.ts|
|Access level changed|Class name: NotificationSubscriber;<br>Method or attribute name: onDestroy?: () => void;<br>Old version information: |Class name: NotificationSubscriber;<br>Method or attribute name: onDestroy?: () => void;<br>New version information: systemapi|notificationSubscriber.d.ts|
|Access level changed|Class name: NotificationSubscriber;<br>Method or attribute name: onDoNotDisturbDateChange?: (mode: notification.DoNotDisturbDate) => void;<br>Old version information: |Class name: NotificationSubscriber;<br>Method or attribute name: onDoNotDisturbDateChange?: (mode: notification.DoNotDisturbDate) => void;<br>New version information: systemapi|notificationSubscriber.d.ts|
|Access level changed|Class name: NotificationSubscriber;<br>Method or attribute name: onEnabledNotificationChanged?: (callbackData: EnabledNotificationCallbackData) => void;<br>Old version information: |Class name: NotificationSubscriber;<br>Method or attribute name: onEnabledNotificationChanged?: (callbackData: EnabledNotificationCallbackData) => void;<br>New version information: systemapi|notificationSubscriber.d.ts|
|Access level changed|Class name: NotificationSubscriber;<br>Method or attribute name: onBadgeChanged?: (data: BadgeNumberCallbackData) => void;<br>Old version information: |Class name: NotificationSubscriber;<br>Method or attribute name: onBadgeChanged?: (data: BadgeNumberCallbackData) => void;<br>New version information: systemapi|notificationSubscriber.d.ts|
|Access level changed|Class name: SubscribeCallbackData;<br>Method or attribute name: readonly request: NotificationRequest;<br>Old version information: |Class name: SubscribeCallbackData;<br>Method or attribute name: readonly request: NotificationRequest;<br>New version information: systemapi|notificationSubscriber.d.ts|
|Access level changed|Class name: SubscribeCallbackData;<br>Method or attribute name: readonly sortingMap?: NotificationSortingMap;<br>Old version information: |Class name: SubscribeCallbackData;<br>Method or attribute name: readonly sortingMap?: NotificationSortingMap;<br>New version information: systemapi|notificationSubscriber.d.ts|
|Access level changed|Class name: SubscribeCallbackData;<br>Method or attribute name: readonly reason?: number;<br>Old version information: |Class name: SubscribeCallbackData;<br>Method or attribute name: readonly reason?: number;<br>New version information: systemapi|notificationSubscriber.d.ts|
|Access level changed|Class name: SubscribeCallbackData;<br>Method or attribute name: readonly sound?: string;<br>Old version information: |Class name: SubscribeCallbackData;<br>Method or attribute name: readonly sound?: string;<br>New version information: systemapi|notificationSubscriber.d.ts|
|Access level changed|Class name: SubscribeCallbackData;<br>Method or attribute name: readonly vibrationValues?: Array\<number>;<br>Old version information: |Class name: SubscribeCallbackData;<br>Method or attribute name: readonly vibrationValues?: Array\<number>;<br>New version information: systemapi|notificationSubscriber.d.ts|
|Access level changed|Class name: EnabledNotificationCallbackData;<br>Method or attribute name: readonly bundle: string;<br>Old version information: |Class name: EnabledNotificationCallbackData;<br>Method or attribute name: readonly bundle: string;<br>New version information: systemapi|notificationSubscriber.d.ts|
|Access level changed|Class name: BadgeNumberCallbackData;<br>Method or attribute name: readonly bundle: string;<br>Old version information: |Class name: BadgeNumberCallbackData;<br>Method or attribute name: readonly bundle: string;<br>New version information: systemapi|notificationSubscriber.d.ts|
|Access level changed|Class name: EnabledNotificationCallbackData;<br>Method or attribute name: readonly uid: number;<br>Old version information: |Class name: EnabledNotificationCallbackData;<br>Method or attribute name: readonly uid: number;<br>New version information: systemapi|notificationSubscriber.d.ts|
|Access level changed|Class name: BadgeNumberCallbackData;<br>Method or attribute name: readonly uid: number;<br>Old version information: |Class name: BadgeNumberCallbackData;<br>Method or attribute name: readonly uid: number;<br>New version information: systemapi|notificationSubscriber.d.ts|
|Access level changed|Class name: EnabledNotificationCallbackData;<br>Method or attribute name: readonly enable: boolean;<br>Old version information: |Class name: EnabledNotificationCallbackData;<br>Method or attribute name: readonly enable: boolean;<br>New version information: systemapi|notificationSubscriber.d.ts|
|Access level changed|Class name: BadgeNumberCallbackData;<br>Method or attribute name: readonly badgeNumber: number;<br>Old version information: |Class name: BadgeNumberCallbackData;<br>Method or attribute name: readonly badgeNumber: number;<br>New version information: systemapi|notificationSubscriber.d.ts|
|Permission changed|Class name: notification;<br>Method or attribute name: function publish(request: NotificationRequest, userId: number): Promise\<void>;<br>Old version information: |Class name: notification;<br>Method or attribute name: function publish(request: NotificationRequest, userId: number): Promise\<void>;<br>New version information: ohos.permission.NOTIFICATION_CONTROLLER|@ohos.notification.d.ts|
|Permission changed|Class name: notification;<br>Method or attribute name: function isNotificationEnabled(userId: number): Promise\<boolean>;<br>Old version information: |Class name: notification;<br>Method or attribute name: function isNotificationEnabled(userId: number): Promise\<boolean>;<br>New version information: ohos.permission.NOTIFICATION_CONTROLLER|@ohos.notification.d.ts|
|Permission changed|Class name: notification;<br>Method or attribute name: function removeAll(userId: number): Promise\<void>;<br>Old version information: |Class name: notification;<br>Method or attribute name: function removeAll(userId: number): Promise\<void>;<br>New version information: ohos.permission.NOTIFICATION_CONTROLLER|@ohos.notification.d.ts|
|Permission changed|Class name: notification;<br>Method or attribute name: function removeGroupByBundle(bundle: BundleOption, groupName: string): Promise\<void>;<br>Old version information: |Class name: notification;<br>Method or attribute name: function removeGroupByBundle(bundle: BundleOption, groupName: string): Promise\<void>;<br>New version information: ohos.permission.NOTIFICATION_CONTROLLER|@ohos.notification.d.ts|
|Permission changed|Class name: notification;<br>Method or attribute name: function setDoNotDisturbDate(date: DoNotDisturbDate): Promise\<void>;<br>Old version information: |Class name: notification;<br>Method or attribute name: function setDoNotDisturbDate(date: DoNotDisturbDate): Promise\<void>;<br>New version information: ohos.permission.NOTIFICATION_CONTROLLER|@ohos.notification.d.ts|
|Permission changed|Class name: notification;<br>Method or attribute name: function setDoNotDisturbDate(date: DoNotDisturbDate, userId: number): Promise\<void>;<br>Old version information: |Class name: notification;<br>Method or attribute name: function setDoNotDisturbDate(date: DoNotDisturbDate, userId: number): Promise\<void>;<br>New version information: ohos.permission.NOTIFICATION_CONTROLLER|@ohos.notification.d.ts|
|Permission changed|Class name: notification;<br>Method or attribute name: function getDoNotDisturbDate(): Promise\<DoNotDisturbDate>;<br>Old version information: |Class name: notification;<br>Method or attribute name: function getDoNotDisturbDate(): Promise\<DoNotDisturbDate>;<br>New version information: ohos.permission.NOTIFICATION_CONTROLLER|@ohos.notification.d.ts|
|Permission changed|Class name: notification;<br>Method or attribute name: function getDoNotDisturbDate(userId: number): Promise\<DoNotDisturbDate>;<br>Old version information: |Class name: notification;<br>Method or attribute name: function getDoNotDisturbDate(userId: number): Promise\<DoNotDisturbDate>;<br>New version information: ohos.permission.NOTIFICATION_CONTROLLER|@ohos.notification.d.ts|
|Permission changed|Class name: notification;<br>Method or attribute name: function supportDoNotDisturbMode(): Promise\<boolean>;<br>Old version information: |Class name: notification;<br>Method or attribute name: function supportDoNotDisturbMode(): Promise\<boolean>;<br>New version information: ohos.permission.NOTIFICATION_CONTROLLER|@ohos.notification.d.ts|
|Permission changed|Class name: notification;<br>Method or attribute name: function enableDistributed(enable: boolean): Promise\<void>;<br>Old version information: |Class name: notification;<br>Method or attribute name: function enableDistributed(enable: boolean): Promise\<void>;<br>New version information: ohos.permission.NOTIFICATION_CONTROLLER|@ohos.notification.d.ts|
|Permission changed|Class name: notification;<br>Method or attribute name: function enableDistributedByBundle(bundle: BundleOption, enable: boolean): Promise\<void>;<br>Old version information: |Class name: notification;<br>Method or attribute name: function enableDistributedByBundle(bundle: BundleOption, enable: boolean): Promise\<void>;<br>New version information: ohos.permission.NOTIFICATION_CONTROLLER|@ohos.notification.d.ts|
|Permission changed|Class name: notification;<br>Method or attribute name: function isDistributedEnabledByBundle(bundle: BundleOption): Promise\<boolean>;<br>Old version information: |Class name: notification;<br>Method or attribute name: function isDistributedEnabledByBundle(bundle: BundleOption): Promise\<boolean>;<br>New version information: ohos.permission.NOTIFICATION_CONTROLLER|@ohos.notification.d.ts|
|Permission changed|Class name: notification;<br>Method or attribute name: function getDeviceRemindType(): Promise\<DeviceRemindType>;<br>Old version information: |Class name: notification;<br>Method or attribute name: function getDeviceRemindType(): Promise\<DeviceRemindType>;<br>New version information: ohos.permission.NOTIFICATION_CONTROLLER|@ohos.notification.d.ts|
|Permission changed|Class name: NotificationCheckInfo;<br>Method or attribute name: bundleName: string;<br>Old version information: |Class name: NotificationCheckInfo;<br>Method or attribute name: bundleName: string;<br>New version information: ohos.permission.NOTIFICATION_CONTROLLER,ohos.permission.NOTIFICATION_AGENT_CONTROLLER|@ohos.notificationManager.d.ts|
|Permission changed|Class name: NotificationCheckInfo;<br>Method or attribute name: notificationId: number;<br>Old version information: |Class name: NotificationCheckInfo;<br>Method or attribute name: notificationId: number;<br>New version information: ohos.permission.NOTIFICATION_CONTROLLER,ohos.permission.NOTIFICATION_AGENT_CONTROLLER|@ohos.notificationManager.d.ts|
|Permission changed|Class name: NotificationCheckInfo;<br>Method or attribute name: contentType: ContentType;<br>Old version information: |Class name: NotificationCheckInfo;<br>Method or attribute name: contentType: ContentType;<br>New version information: ohos.permission.NOTIFICATION_CONTROLLER,ohos.permission.NOTIFICATION_AGENT_CONTROLLER|@ohos.notificationManager.d.ts|
|Permission changed|Class name: NotificationCheckResult;<br>Method or attribute name: code: number;<br>Old version information: |Class name: NotificationCheckResult;<br>Method or attribute name: code: number;<br>New version information: ohos.permission.NOTIFICATION_CONTROLLER,ohos.permission.NOTIFICATION_AGENT_CONTROLLER|@ohos.notificationManager.d.ts|
|Permission changed|Class name: NotificationCheckResult;<br>Method or attribute name: message: string;<br>Old version information: |Class name: NotificationCheckResult;<br>Method or attribute name: message: string;<br>New version information: ohos.permission.NOTIFICATION_CONTROLLER,ohos.permission.NOTIFICATION_AGENT_CONTROLLER|@ohos.notificationManager.d.ts|
|Type changed|Class name: EventData;<br>Method or attribute name: data?: { [key: string]: any };<br>Old version information: |Class name: EventData;<br>Method or attribute name: data?: { [key: string]: any };<br>New version information: ?object|@ohos.events.emitter.d.ts|
|Type changed|Class name: InnerEvent;<br>Method or attribute name: eventId: number;<br>Old version information: |Class name: InnerEvent;<br>Method or attribute name: eventId: number;<br>New version information: number|@ohos.events.emitter.d.ts|
|Type changed|Class name: InnerEvent;<br>Method or attribute name: priority?: EventPriority;<br>Old version information: |Class name: InnerEvent;<br>Method or attribute name: priority?: EventPriority;<br>New version information: ?EventPriority|@ohos.events.emitter.d.ts|
|Type changed|Class name: BundleOption;<br>Method or attribute name: bundle: string;<br>Old version information: |Class name: BundleOption;<br>Method or attribute name: bundle: string;<br>New version information: string|@ohos.notification.d.ts|
|Type changed|Class name: BundleOption;<br>Method or attribute name: uid?: number;<br>Old version information: |Class name: BundleOption;<br>Method or attribute name: uid?: number;<br>New version information: ?number|@ohos.notification.d.ts|
|Type changed|Class name: NotificationKey;<br>Method or attribute name: id: number;<br>Old version information: |Class name: NotificationKey;<br>Method or attribute name: id: number;<br>New version information: number|@ohos.notification.d.ts|
|Type changed|Class name: NotificationKey;<br>Method or attribute name: label?: string;<br>Old version information: |Class name: NotificationKey;<br>Method or attribute name: label?: string;<br>New version information: ?string|@ohos.notification.d.ts|
|Type changed|Class name: NotificationCheckInfo;<br>Method or attribute name: bundleName: string;<br>Old version information: |Class name: NotificationCheckInfo;<br>Method or attribute name: bundleName: string;<br>New version information: string|@ohos.notificationManager.d.ts|
|Type changed|Class name: NotificationCheckInfo;<br>Method or attribute name: notificationId: number;<br>Old version information: |Class name: NotificationCheckInfo;<br>Method or attribute name: notificationId: number;<br>New version information: number|@ohos.notificationManager.d.ts|
|Type changed|Class name: NotificationCheckInfo;<br>Method or attribute name: contentType: ContentType;<br>Old version information: |Class name: NotificationCheckInfo;<br>Method or attribute name: contentType: ContentType;<br>New version information: ContentType|@ohos.notificationManager.d.ts|
|Type changed|Class name: NotificationCheckResult;<br>Method or attribute name: code: number;<br>Old version information: |Class name: NotificationCheckResult;<br>Method or attribute name: code: number;<br>New version information: number|@ohos.notificationManager.d.ts|
|Type changed|Class name: NotificationCheckResult;<br>Method or attribute name: message: string;<br>Old version information: |Class name: NotificationCheckResult;<br>Method or attribute name: message: string;<br>New version information: string|@ohos.notificationManager.d.ts|
|Type changed|Class name: DoNotDisturbDate;<br>Method or attribute name: type: DoNotDisturbType;<br>Old version information: |Class name: DoNotDisturbDate;<br>Method or attribute name: type: DoNotDisturbType;<br>New version information: DoNotDisturbType|@ohos.notificationManager.d.ts|
|Type changed|Class name: DoNotDisturbDate;<br>Method or attribute name: begin: Date;<br>Old version information: |Class name: DoNotDisturbDate;<br>Method or attribute name: begin: Date;<br>New version information: Date|@ohos.notificationManager.d.ts|
|Type changed|Class name: DoNotDisturbDate;<br>Method or attribute name: end: Date;<br>Old version information: |Class name: DoNotDisturbDate;<br>Method or attribute name: end: Date;<br>New version information: Date|@ohos.notificationManager.d.ts|
|Type changed|Class name: NotificationKey;<br>Method or attribute name: id: number;<br>Old version information: |Class name: NotificationKey;<br>Method or attribute name: id: number;<br>New version information: number|@ohos.notificationSubscribe.d.ts|
|Type changed|Class name: NotificationKey;<br>Method or attribute name: label?: string;<br>Old version information: |Class name: NotificationKey;<br>Method or attribute name: label?: string;<br>New version information: ?string|@ohos.notificationSubscribe.d.ts|
|Type changed|Class name: ActionResult;<br>Method or attribute name: bundleName: string;<br>Old version information: |Class name: ActionResult;<br>Method or attribute name: bundleName: string;<br>New version information: string|@system.notification.d.ts|
|Type changed|Class name: ActionResult;<br>Method or attribute name: abilityName: string;<br>Old version information: |Class name: ActionResult;<br>Method or attribute name: abilityName: string;<br>New version information: string|@system.notification.d.ts|
|Type changed|Class name: ActionResult;<br>Method or attribute name: uri: string;<br>Old version information: |Class name: ActionResult;<br>Method or attribute name: uri: string;<br>New version information: string|@system.notification.d.ts|
|Type changed|Class name: ShowNotificationOptions;<br>Method or attribute name: contentTitle?: string;<br>Old version information: |Class name: ShowNotificationOptions;<br>Method or attribute name: contentTitle?: string;<br>New version information: ?string|@system.notification.d.ts|
|Type changed|Class name: ShowNotificationOptions;<br>Method or attribute name: contentText?: string;<br>Old version information: |Class name: ShowNotificationOptions;<br>Method or attribute name: contentText?: string;<br>New version information: ?string|@system.notification.d.ts|
|Type changed|Class name: ShowNotificationOptions;<br>Method or attribute name: clickAction?: ActionResult;<br>Old version information: |Class name: ShowNotificationOptions;<br>Method or attribute name: clickAction?: ActionResult;<br>New version information: ?ActionResult|@system.notification.d.ts|
|Type changed|Class name: CommonEventData;<br>Method or attribute name: event: string;<br>Old version information: |Class name: CommonEventData;<br>Method or attribute name: event: string;<br>New version information: string|commonEventData.d.ts|
|Type changed|Class name: CommonEventData;<br>Method or attribute name: bundleName?: string;<br>Old version information: |Class name: CommonEventData;<br>Method or attribute name: bundleName?: string;<br>New version information: ?string|commonEventData.d.ts|
|Type changed|Class name: CommonEventData;<br>Method or attribute name: code?: number;<br>Old version information: |Class name: CommonEventData;<br>Method or attribute name: code?: number;<br>New version information: ?number|commonEventData.d.ts|
|Type changed|Class name: CommonEventData;<br>Method or attribute name: data?: string;<br>Old version information: |Class name: CommonEventData;<br>Method or attribute name: data?: string;<br>New version information: ?string|commonEventData.d.ts|
|Type changed|Class name: CommonEventData;<br>Method or attribute name: parameters?: { [key: string]: any };<br>Old version information: |Class name: CommonEventData;<br>Method or attribute name: parameters?: { [key: string]: any };<br>New version information: ?object|commonEventData.d.ts|
|Type changed|Class name: CommonEventPublishData;<br>Method or attribute name: bundleName?: string;<br>Old version information: |Class name: CommonEventPublishData;<br>Method or attribute name: bundleName?: string;<br>New version information: ?string|commonEventPublishData.d.ts|
|Type changed|Class name: CommonEventPublishData;<br>Method or attribute name: code?: number;<br>Old version information: |Class name: CommonEventPublishData;<br>Method or attribute name: code?: number;<br>New version information: ?number|commonEventPublishData.d.ts|
|Type changed|Class name: CommonEventPublishData;<br>Method or attribute name: data?: string;<br>Old version information: |Class name: CommonEventPublishData;<br>Method or attribute name: data?: string;<br>New version information: ?string|commonEventPublishData.d.ts|
|Type changed|Class name: CommonEventPublishData;<br>Method or attribute name: subscriberPermissions?: Array\<string>;<br>Old version information: |Class name: CommonEventPublishData;<br>Method or attribute name: subscriberPermissions?: Array\<string>;<br>New version information: ?Array\<string>|commonEventPublishData.d.ts|
|Type changed|Class name: CommonEventPublishData;<br>Method or attribute name: isOrdered?: boolean;<br>Old version information: |Class name: CommonEventPublishData;<br>Method or attribute name: isOrdered?: boolean;<br>New version information: ?boolean|commonEventPublishData.d.ts|
|Type changed|Class name: CommonEventPublishData;<br>Method or attribute name: isSticky?: boolean;<br>Old version information: |Class name: CommonEventPublishData;<br>Method or attribute name: isSticky?: boolean;<br>New version information: ?boolean|commonEventPublishData.d.ts|
|Type changed|Class name: CommonEventPublishData;<br>Method or attribute name: parameters?: { [key: string]: any };<br>Old version information: |Class name: CommonEventPublishData;<br>Method or attribute name: parameters?: { [key: string]: any };<br>New version information: ?object|commonEventPublishData.d.ts|
|Type changed|Class name: CommonEventSubscribeInfo;<br>Method or attribute name: events: Array\<string>;<br>Old version information: |Class name: CommonEventSubscribeInfo;<br>Method or attribute name: events: Array\<string>;<br>New version information: Array\<string>|commonEventSubscribeInfo.d.ts|
|Type changed|Class name: CommonEventSubscribeInfo;<br>Method or attribute name: publisherPermission?: string;<br>Old version information: |Class name: CommonEventSubscribeInfo;<br>Method or attribute name: publisherPermission?: string;<br>New version information: ?string|commonEventSubscribeInfo.d.ts|
|Type changed|Class name: CommonEventSubscribeInfo;<br>Method or attribute name: publisherDeviceId?: string;<br>Old version information: |Class name: CommonEventSubscribeInfo;<br>Method or attribute name: publisherDeviceId?: string;<br>New version information: ?string|commonEventSubscribeInfo.d.ts|
|Type changed|Class name: CommonEventSubscribeInfo;<br>Method or attribute name: userId?: number;<br>Old version information: |Class name: CommonEventSubscribeInfo;<br>Method or attribute name: userId?: number;<br>New version information: ?number|commonEventSubscribeInfo.d.ts|
|Type changed|Class name: CommonEventSubscribeInfo;<br>Method or attribute name: priority?: number;<br>Old version information: |Class name: CommonEventSubscribeInfo;<br>Method or attribute name: priority?: number;<br>New version information: ?number|commonEventSubscribeInfo.d.ts|
|Type changed|Class name: NotificationActionButton;<br>Method or attribute name: title: string;<br>Old version information: |Class name: NotificationActionButton;<br>Method or attribute name: title: string;<br>New version information: string|notificationActionButton.d.ts|
|Type changed|Class name: NotificationActionButton;<br>Method or attribute name: wantAgent: WantAgent;<br>Old version information: |Class name: NotificationActionButton;<br>Method or attribute name: wantAgent: WantAgent;<br>New version information: WantAgent|notificationActionButton.d.ts|
|Type changed|Class name: NotificationActionButton;<br>Method or attribute name: extras?: { [key: string]: any };<br>Old version information: |Class name: NotificationActionButton;<br>Method or attribute name: extras?: { [key: string]: any };<br>New version information: ?object|notificationActionButton.d.ts|
|Type changed|Class name: NotificationActionButton;<br>Method or attribute name: userInput?: NotificationUserInput;<br>Old version information: |Class name: NotificationActionButton;<br>Method or attribute name: userInput?: NotificationUserInput;<br>New version information: ?NotificationUserInput|notificationActionButton.d.ts|
|Type changed|Class name: BundleOption;<br>Method or attribute name: bundle: string;<br>Old version information: |Class name: BundleOption;<br>Method or attribute name: bundle: string;<br>New version information: string|NotificationCommonDef.d.ts|
|Type changed|Class name: BundleOption;<br>Method or attribute name: uid?: number;<br>Old version information: |Class name: BundleOption;<br>Method or attribute name: uid?: number;<br>New version information: ?number|NotificationCommonDef.d.ts|
|Type changed|Class name: NotificationBasicContent;<br>Method or attribute name: title: string;<br>Old version information: |Class name: NotificationBasicContent;<br>Method or attribute name: title: string;<br>New version information: string|notificationContent.d.ts|
|Type changed|Class name: NotificationBasicContent;<br>Method or attribute name: text: string;<br>Old version information: |Class name: NotificationBasicContent;<br>Method or attribute name: text: string;<br>New version information: string|notificationContent.d.ts|
|Type changed|Class name: NotificationBasicContent;<br>Method or attribute name: additionalText?: string;<br>Old version information: |Class name: NotificationBasicContent;<br>Method or attribute name: additionalText?: string;<br>New version information: ?string|notificationContent.d.ts|
|Type changed|Class name: NotificationLongTextContent;<br>Method or attribute name: longText: string;<br>Old version information: |Class name: NotificationLongTextContent;<br>Method or attribute name: longText: string;<br>New version information: string|notificationContent.d.ts|
|Type changed|Class name: NotificationLongTextContent;<br>Method or attribute name: briefText: string;<br>Old version information: |Class name: NotificationLongTextContent;<br>Method or attribute name: briefText: string;<br>New version information: string|notificationContent.d.ts|
|Type changed|Class name: NotificationMultiLineContent;<br>Method or attribute name: briefText: string;<br>Old version information: |Class name: NotificationMultiLineContent;<br>Method or attribute name: briefText: string;<br>New version information: string|notificationContent.d.ts|
|Type changed|Class name: NotificationPictureContent;<br>Method or attribute name: briefText: string;<br>Old version information: |Class name: NotificationPictureContent;<br>Method or attribute name: briefText: string;<br>New version information: string|notificationContent.d.ts|
|Type changed|Class name: NotificationLongTextContent;<br>Method or attribute name: expandedTitle: string;<br>Old version information: |Class name: NotificationLongTextContent;<br>Method or attribute name: expandedTitle: string;<br>New version information: string|notificationContent.d.ts|
|Type changed|Class name: NotificationPictureContent;<br>Method or attribute name: expandedTitle: string;<br>Old version information: |Class name: NotificationPictureContent;<br>Method or attribute name: expandedTitle: string;<br>New version information: string|notificationContent.d.ts|
|Type changed|Class name: NotificationMultiLineContent;<br>Method or attribute name: longTitle: string;<br>Old version information: |Class name: NotificationMultiLineContent;<br>Method or attribute name: longTitle: string;<br>New version information: string|notificationContent.d.ts|
|Type changed|Class name: NotificationMultiLineContent;<br>Method or attribute name: lines: Array\<string>;<br>Old version information: |Class name: NotificationMultiLineContent;<br>Method or attribute name: lines: Array\<string>;<br>New version information: Array\<string>|notificationContent.d.ts|
|Type changed|Class name: NotificationPictureContent;<br>Method or attribute name: picture: image.PixelMap;<br>Old version information: |Class name: NotificationPictureContent;<br>Method or attribute name: picture: image.PixelMap;<br>New version information: image.PixelMap|notificationContent.d.ts|
|Type changed|Class name: NotificationContent;<br>Method or attribute name: contentType: notification.ContentType;<br>Old version information: |Class name: NotificationContent;<br>Method or attribute name: contentType: notification.ContentType;<br>New version information: notification.ContentType|notificationContent.d.ts|
|Type changed|Class name: NotificationContent;<br>Method or attribute name: normal?: NotificationBasicContent;<br>Old version information: |Class name: NotificationContent;<br>Method or attribute name: normal?: NotificationBasicContent;<br>New version information: ?NotificationBasicContent|notificationContent.d.ts|
|Type changed|Class name: NotificationContent;<br>Method or attribute name: longText?: NotificationLongTextContent;<br>Old version information: |Class name: NotificationContent;<br>Method or attribute name: longText?: NotificationLongTextContent;<br>New version information: ?NotificationLongTextContent|notificationContent.d.ts|
|Type changed|Class name: NotificationContent;<br>Method or attribute name: multiLine?: NotificationMultiLineContent;<br>Old version information: |Class name: NotificationContent;<br>Method or attribute name: multiLine?: NotificationMultiLineContent;<br>New version information: ?NotificationMultiLineContent|notificationContent.d.ts|
|Type changed|Class name: NotificationContent;<br>Method or attribute name: picture?: NotificationPictureContent;<br>Old version information: |Class name: NotificationContent;<br>Method or attribute name: picture?: NotificationPictureContent;<br>New version information: ?NotificationPictureContent|notificationContent.d.ts|
|Type changed|Class name: NotificationRequest;<br>Method or attribute name: content: NotificationContent;<br>Old version information: |Class name: NotificationRequest;<br>Method or attribute name: content: NotificationContent;<br>New version information: NotificationContent|notificationRequest.d.ts|
|Type changed|Class name: NotificationRequest;<br>Method or attribute name: id?: number;<br>Old version information: |Class name: NotificationRequest;<br>Method or attribute name: id?: number;<br>New version information: ?number|notificationRequest.d.ts|
|Type changed|Class name: NotificationRequest;<br>Method or attribute name: slotType?: notification.SlotType;<br>Old version information: |Class name: NotificationRequest;<br>Method or attribute name: slotType?: notification.SlotType;<br>New version information: ?notification.SlotType|notificationRequest.d.ts|
|Type changed|Class name: NotificationRequest;<br>Method or attribute name: isOngoing?: boolean;<br>Old version information: |Class name: NotificationRequest;<br>Method or attribute name: isOngoing?: boolean;<br>New version information: ?boolean|notificationRequest.d.ts|
|Type changed|Class name: NotificationRequest;<br>Method or attribute name: isUnremovable?: boolean;<br>Old version information: |Class name: NotificationRequest;<br>Method or attribute name: isUnremovable?: boolean;<br>New version information: ?boolean|notificationRequest.d.ts|
|Type changed|Class name: NotificationRequest;<br>Method or attribute name: deliveryTime?: number;<br>Old version information: |Class name: NotificationRequest;<br>Method or attribute name: deliveryTime?: number;<br>New version information: ?number|notificationRequest.d.ts|
|Type changed|Class name: NotificationRequest;<br>Method or attribute name: tapDismissed?: boolean;<br>Old version information: |Class name: NotificationRequest;<br>Method or attribute name: tapDismissed?: boolean;<br>New version information: ?boolean|notificationRequest.d.ts|
|Type changed|Class name: NotificationRequest;<br>Method or attribute name: autoDeletedTime?: number;<br>Old version information: |Class name: NotificationRequest;<br>Method or attribute name: autoDeletedTime?: number;<br>New version information: ?number|notificationRequest.d.ts|
|Type changed|Class name: NotificationRequest;<br>Method or attribute name: wantAgent?: WantAgent;<br>Old version information: |Class name: NotificationRequest;<br>Method or attribute name: wantAgent?: WantAgent;<br>New version information: ?WantAgent|notificationRequest.d.ts|
|Type changed|Class name: NotificationRequest;<br>Method or attribute name: extraInfo?: { [key: string]: any };<br>Old version information: |Class name: NotificationRequest;<br>Method or attribute name: extraInfo?: { [key: string]: any };<br>New version information: ?object|notificationRequest.d.ts|
|Type changed|Class name: NotificationRequest;<br>Method or attribute name: color?: number;<br>Old version information: |Class name: NotificationRequest;<br>Method or attribute name: color?: number;<br>New version information: ?number|notificationRequest.d.ts|
|Type changed|Class name: NotificationRequest;<br>Method or attribute name: colorEnabled?: boolean;<br>Old version information: |Class name: NotificationRequest;<br>Method or attribute name: colorEnabled?: boolean;<br>New version information: ?boolean|notificationRequest.d.ts|
|Type changed|Class name: NotificationRequest;<br>Method or attribute name: isAlertOnce?: boolean;<br>Old version information: |Class name: NotificationRequest;<br>Method or attribute name: isAlertOnce?: boolean;<br>New version information: ?boolean|notificationRequest.d.ts|
|Type changed|Class name: NotificationRequest;<br>Method or attribute name: isStopwatch?: boolean;<br>Old version information: |Class name: NotificationRequest;<br>Method or attribute name: isStopwatch?: boolean;<br>New version information: ?boolean|notificationRequest.d.ts|
|Type changed|Class name: NotificationRequest;<br>Method or attribute name: isCountDown?: boolean;<br>Old version information: |Class name: NotificationRequest;<br>Method or attribute name: isCountDown?: boolean;<br>New version information: ?boolean|notificationRequest.d.ts|
|Type changed|Class name: NotificationRequest;<br>Method or attribute name: isFloatingIcon?: boolean;<br>Old version information: |Class name: NotificationRequest;<br>Method or attribute name: isFloatingIcon?: boolean;<br>New version information: ?boolean|notificationRequest.d.ts|
|Type changed|Class name: NotificationRequest;<br>Method or attribute name: label?: string;<br>Old version information: |Class name: NotificationRequest;<br>Method or attribute name: label?: string;<br>New version information: ?string|notificationRequest.d.ts|
|Type changed|Class name: NotificationRequest;<br>Method or attribute name: badgeIconStyle?: number;<br>Old version information: |Class name: NotificationRequest;<br>Method or attribute name: badgeIconStyle?: number;<br>New version information: ?number|notificationRequest.d.ts|
|Type changed|Class name: NotificationRequest;<br>Method or attribute name: showDeliveryTime?: boolean;<br>Old version information: |Class name: NotificationRequest;<br>Method or attribute name: showDeliveryTime?: boolean;<br>New version information: ?boolean|notificationRequest.d.ts|
|Type changed|Class name: NotificationRequest;<br>Method or attribute name: actionButtons?: Array\<NotificationActionButton>;<br>Old version information: |Class name: NotificationRequest;<br>Method or attribute name: actionButtons?: Array\<NotificationActionButton>;<br>New version information: ?Array\<NotificationActionButton>|notificationRequest.d.ts|
|Type changed|Class name: NotificationRequest;<br>Method or attribute name: smallIcon?: image.PixelMap;<br>Old version information: |Class name: NotificationRequest;<br>Method or attribute name: smallIcon?: image.PixelMap;<br>New version information: ?image.PixelMap|notificationRequest.d.ts|
|Type changed|Class name: NotificationRequest;<br>Method or attribute name: largeIcon?: image.PixelMap;<br>Old version information: |Class name: NotificationRequest;<br>Method or attribute name: largeIcon?: image.PixelMap;<br>New version information: ?image.PixelMap|notificationRequest.d.ts|
|Type changed|Class name: NotificationRequest;<br>Method or attribute name: groupName?: string;<br>Old version information: |Class name: NotificationRequest;<br>Method or attribute name: groupName?: string;<br>New version information: ?string|notificationRequest.d.ts|
|Type changed|Class name: NotificationRequest;<br>Method or attribute name: readonly creatorBundleName?: string;<br>Old version information: |Class name: NotificationRequest;<br>Method or attribute name: readonly creatorBundleName?: string;<br>New version information: ?string|notificationRequest.d.ts|
|Type changed|Class name: NotificationRequest;<br>Method or attribute name: readonly creatorUid?: number;<br>Old version information: |Class name: NotificationRequest;<br>Method or attribute name: readonly creatorUid?: number;<br>New version information: ?number|notificationRequest.d.ts|
|Type changed|Class name: NotificationRequest;<br>Method or attribute name: readonly creatorPid?: number;<br>Old version information: |Class name: NotificationRequest;<br>Method or attribute name: readonly creatorPid?: number;<br>New version information: ?number|notificationRequest.d.ts|
|Type changed|Class name: NotificationRequest;<br>Method or attribute name: readonly creatorUserId?: number;<br>Old version information: |Class name: NotificationRequest;<br>Method or attribute name: readonly creatorUserId?: number;<br>New version information: ?number|notificationRequest.d.ts|
|Type changed|Class name: NotificationRequest;<br>Method or attribute name: classification?: string;<br>Old version information: |Class name: NotificationRequest;<br>Method or attribute name: classification?: string;<br>New version information: ?string|notificationRequest.d.ts|
|Type changed|Class name: NotificationRequest;<br>Method or attribute name: readonly hashCode?: string;<br>Old version information: |Class name: NotificationRequest;<br>Method or attribute name: readonly hashCode?: string;<br>New version information: ?string|notificationRequest.d.ts|
|Type changed|Class name: NotificationRequest;<br>Method or attribute name: isRemoveAllowed?: boolean;<br>Old version information: |Class name: NotificationRequest;<br>Method or attribute name: isRemoveAllowed?: boolean;<br>New version information: ?boolean|notificationRequest.d.ts|
|Type changed|Class name: NotificationRequest;<br>Method or attribute name: readonly source?: number;<br>Old version information: |Class name: NotificationRequest;<br>Method or attribute name: readonly source?: number;<br>New version information: ?number|notificationRequest.d.ts|
|Type changed|Class name: NotificationRequest;<br>Method or attribute name: template?: NotificationTemplate;<br>Old version information: |Class name: NotificationRequest;<br>Method or attribute name: template?: NotificationTemplate;<br>New version information: ?NotificationTemplate|notificationRequest.d.ts|
|Type changed|Class name: NotificationRequest;<br>Method or attribute name: distributedOption?: DistributedOptions;<br>Old version information: |Class name: NotificationRequest;<br>Method or attribute name: distributedOption?: DistributedOptions;<br>New version information: ?DistributedOptions|notificationRequest.d.ts|
|Type changed|Class name: NotificationRequest;<br>Method or attribute name: readonly deviceId?: string;<br>Old version information: |Class name: NotificationRequest;<br>Method or attribute name: readonly deviceId?: string;<br>New version information: ?string|notificationRequest.d.ts|
|Type changed|Class name: NotificationRequest;<br>Method or attribute name: readonly notificationFlags?: NotificationFlags;<br>Old version information: |Class name: NotificationRequest;<br>Method or attribute name: readonly notificationFlags?: NotificationFlags;<br>New version information: ?NotificationFlags|notificationRequest.d.ts|
|Type changed|Class name: NotificationRequest;<br>Method or attribute name: removalWantAgent?: WantAgent;<br>Old version information: |Class name: NotificationRequest;<br>Method or attribute name: removalWantAgent?: WantAgent;<br>New version information: ?WantAgent|notificationRequest.d.ts|
|Type changed|Class name: NotificationRequest;<br>Method or attribute name: badgeNumber?: number;<br>Old version information: |Class name: NotificationRequest;<br>Method or attribute name: badgeNumber?: number;<br>New version information: ?number|notificationRequest.d.ts|
|Type changed|Class name: DistributedOptions;<br>Method or attribute name: isDistributed?: boolean;<br>Old version information: |Class name: DistributedOptions;<br>Method or attribute name: isDistributed?: boolean;<br>New version information: ?boolean|notificationRequest.d.ts|
|Type changed|Class name: DistributedOptions;<br>Method or attribute name: supportDisplayDevices?: Array\<string>;<br>Old version information: |Class name: DistributedOptions;<br>Method or attribute name: supportDisplayDevices?: Array\<string>;<br>New version information: ?Array\<string>|notificationRequest.d.ts|
|Type changed|Class name: DistributedOptions;<br>Method or attribute name: supportOperateDevices?: Array\<string>;<br>Old version information: |Class name: DistributedOptions;<br>Method or attribute name: supportOperateDevices?: Array\<string>;<br>New version information: ?Array\<string>|notificationRequest.d.ts|
|Type changed|Class name: DistributedOptions;<br>Method or attribute name: readonly remindType?: number;<br>Old version information: |Class name: DistributedOptions;<br>Method or attribute name: readonly remindType?: number;<br>New version information: ?number|notificationRequest.d.ts|
|Type changed|Class name: NotificationSlot;<br>Method or attribute name: type: notification.SlotType;<br>Old version information: |Class name: NotificationSlot;<br>Method or attribute name: type: notification.SlotType;<br>New version information: notification.SlotType|notificationSlot.d.ts|
|Type changed|Class name: NotificationSlot;<br>Method or attribute name: level?: notification.SlotLevel;<br>Old version information: |Class name: NotificationSlot;<br>Method or attribute name: level?: notification.SlotLevel;<br>New version information: ?notification.SlotLevel|notificationSlot.d.ts|
|Type changed|Class name: NotificationSlot;<br>Method or attribute name: desc?: string;<br>Old version information: |Class name: NotificationSlot;<br>Method or attribute name: desc?: string;<br>New version information: ?string|notificationSlot.d.ts|
|Type changed|Class name: NotificationSlot;<br>Method or attribute name: badgeFlag?: boolean;<br>Old version information: |Class name: NotificationSlot;<br>Method or attribute name: badgeFlag?: boolean;<br>New version information: ?boolean|notificationSlot.d.ts|
|Type changed|Class name: NotificationSlot;<br>Method or attribute name: bypassDnd?: boolean;<br>Old version information: |Class name: NotificationSlot;<br>Method or attribute name: bypassDnd?: boolean;<br>New version information: ?boolean|notificationSlot.d.ts|
|Type changed|Class name: NotificationSlot;<br>Method or attribute name: lockscreenVisibility?: number;<br>Old version information: |Class name: NotificationSlot;<br>Method or attribute name: lockscreenVisibility?: number;<br>New version information: ?number|notificationSlot.d.ts|
|Type changed|Class name: NotificationSlot;<br>Method or attribute name: vibrationEnabled?: boolean;<br>Old version information: |Class name: NotificationSlot;<br>Method or attribute name: vibrationEnabled?: boolean;<br>New version information: ?boolean|notificationSlot.d.ts|
|Type changed|Class name: NotificationSlot;<br>Method or attribute name: sound?: string;<br>Old version information: |Class name: NotificationSlot;<br>Method or attribute name: sound?: string;<br>New version information: ?string|notificationSlot.d.ts|
|Type changed|Class name: NotificationSlot;<br>Method or attribute name: lightEnabled?: boolean;<br>Old version information: |Class name: NotificationSlot;<br>Method or attribute name: lightEnabled?: boolean;<br>New version information: ?boolean|notificationSlot.d.ts|
|Type changed|Class name: NotificationSlot;<br>Method or attribute name: lightColor?: number;<br>Old version information: |Class name: NotificationSlot;<br>Method or attribute name: lightColor?: number;<br>New version information: ?number|notificationSlot.d.ts|
|Type changed|Class name: NotificationSlot;<br>Method or attribute name: vibrationValues?: Array\<number>;<br>Old version information: |Class name: NotificationSlot;<br>Method or attribute name: vibrationValues?: Array\<number>;<br>New version information: ?Array\<number>|notificationSlot.d.ts|
|Type changed|Class name: NotificationSlot;<br>Method or attribute name: readonly enabled?: boolean;<br>Old version information: |Class name: NotificationSlot;<br>Method or attribute name: readonly enabled?: boolean;<br>New version information: ?boolean|notificationSlot.d.ts|
|Type changed|Class name: NotificationSorting;<br>Method or attribute name: readonly slot: NotificationSlot;<br>Old version information: |Class name: NotificationSorting;<br>Method or attribute name: readonly slot: NotificationSlot;<br>New version information: NotificationSlot|notificationSorting.d.ts|
|Type changed|Class name: NotificationSorting;<br>Method or attribute name: readonly hashCode: string;<br>Old version information: |Class name: NotificationSorting;<br>Method or attribute name: readonly hashCode: string;<br>New version information: string|notificationSorting.d.ts|
|Type changed|Class name: NotificationSorting;<br>Method or attribute name: readonly ranking: number;<br>Old version information: |Class name: NotificationSorting;<br>Method or attribute name: readonly ranking: number;<br>New version information: number|notificationSorting.d.ts|
|Type changed|Class name: NotificationSortingMap;<br>Method or attribute name: readonly sortings: { [key: string]: NotificationSorting };<br>Old version information: |Class name: NotificationSortingMap;<br>Method or attribute name: readonly sortings: { [key: string]: NotificationSorting };<br>New version information: object|notificationSortingMap.d.ts|
|Type changed|Class name: NotificationSortingMap;<br>Method or attribute name: readonly sortedHashCode: Array\<string>;<br>Old version information: |Class name: NotificationSortingMap;<br>Method or attribute name: readonly sortedHashCode: Array\<string>;<br>New version information: Array\<string>|notificationSortingMap.d.ts|
|Type changed|Class name: NotificationSubscribeInfo;<br>Method or attribute name: bundleNames?: Array\<string>;<br>Old version information: |Class name: NotificationSubscribeInfo;<br>Method or attribute name: bundleNames?: Array\<string>;<br>New version information: ?Array\<string>|notificationSubscribeInfo.d.ts|
|Type changed|Class name: NotificationSubscribeInfo;<br>Method or attribute name: userId?: number;<br>Old version information: |Class name: NotificationSubscribeInfo;<br>Method or attribute name: userId?: number;<br>New version information: ?number|notificationSubscribeInfo.d.ts|
|Type changed|Class name: SubscribeCallbackData;<br>Method or attribute name: readonly request: NotificationRequest;<br>Old version information: |Class name: SubscribeCallbackData;<br>Method or attribute name: readonly request: NotificationRequest;<br>New version information: NotificationRequest|notificationSubscriber.d.ts|
|Type changed|Class name: SubscribeCallbackData;<br>Method or attribute name: readonly sortingMap?: NotificationSortingMap;<br>Old version information: |Class name: SubscribeCallbackData;<br>Method or attribute name: readonly sortingMap?: NotificationSortingMap;<br>New version information: ?NotificationSortingMap|notificationSubscriber.d.ts|
|Type changed|Class name: SubscribeCallbackData;<br>Method or attribute name: readonly reason?: number;<br>Old version information: |Class name: SubscribeCallbackData;<br>Method or attribute name: readonly reason?: number;<br>New version information: ?number|notificationSubscriber.d.ts|
|Type changed|Class name: SubscribeCallbackData;<br>Method or attribute name: readonly sound?: string;<br>Old version information: |Class name: SubscribeCallbackData;<br>Method or attribute name: readonly sound?: string;<br>New version information: ?string|notificationSubscriber.d.ts|
|Type changed|Class name: SubscribeCallbackData;<br>Method or attribute name: readonly vibrationValues?: Array\<number>;<br>Old version information: |Class name: SubscribeCallbackData;<br>Method or attribute name: readonly vibrationValues?: Array\<number>;<br>New version information: ?Array\<number>|notificationSubscriber.d.ts|
|Type changed|Class name: EnabledNotificationCallbackData;<br>Method or attribute name: readonly bundle: string;<br>Old version information: |Class name: EnabledNotificationCallbackData;<br>Method or attribute name: readonly bundle: string;<br>New version information: string|notificationSubscriber.d.ts|
|Type changed|Class name: BadgeNumberCallbackData;<br>Method or attribute name: readonly bundle: string;<br>Old version information: |Class name: BadgeNumberCallbackData;<br>Method or attribute name: readonly bundle: string;<br>New version information: string|notificationSubscriber.d.ts|
|Type changed|Class name: EnabledNotificationCallbackData;<br>Method or attribute name: readonly uid: number;<br>Old version information: |Class name: EnabledNotificationCallbackData;<br>Method or attribute name: readonly uid: number;<br>New version information: number|notificationSubscriber.d.ts|
|Type changed|Class name: BadgeNumberCallbackData;<br>Method or attribute name: readonly uid: number;<br>Old version information: |Class name: BadgeNumberCallbackData;<br>Method or attribute name: readonly uid: number;<br>New version information: number|notificationSubscriber.d.ts|
|Type changed|Class name: EnabledNotificationCallbackData;<br>Method or attribute name: readonly enable: boolean;<br>Old version information: |Class name: EnabledNotificationCallbackData;<br>Method or attribute name: readonly enable: boolean;<br>New version information: boolean|notificationSubscriber.d.ts|
|Type changed|Class name: BadgeNumberCallbackData;<br>Method or attribute name: readonly badgeNumber: number;<br>Old version information: |Class name: BadgeNumberCallbackData;<br>Method or attribute name: readonly badgeNumber: number;<br>New version information: number|notificationSubscriber.d.ts|
|Type changed|Class name: NotificationTemplate;<br>Method or attribute name: name: string;<br>Old version information: |Class name: NotificationTemplate;<br>Method or attribute name: name: string;<br>New version information: string|notificationTemplate.d.ts|
|Type changed|Class name: NotificationTemplate;<br>Method or attribute name: data: { [key: string]: Object };<br>Old version information: |Class name: NotificationTemplate;<br>Method or attribute name: data: { [key: string]: Object };<br>New version information: object|notificationTemplate.d.ts|
|Type changed|Class name: NotificationUserInput;<br>Method or attribute name: inputKey: string;<br>Old version information: |Class name: NotificationUserInput;<br>Method or attribute name: inputKey: string;<br>New version information: string|notificationUserInput.d.ts|
|Function changed|Class name: NotificationRequest;<br>Method or attribute name: readonly isRemoveAllowed?: boolean;|Class name: NotificationRequest;<br>Method or attribute name: isRemoveAllowed?: boolean;|notificationRequest.d.ts|
| Change Type | Old Version | New Version | d.ts File |
| ---- | ------ | ------ | -------- |
|Added|NA|Class name: ResourceType;<br>Method or attribute name: RUNNING_LOCK = 1 \<\< 7|@ohos.resourceschedule.backgroundTaskManager.d.ts|
|Added|NA|Class name: ResourceType;<br>Method or attribute name: SENSOR = 1 \<\< 8|@ohos.resourceschedule.backgroundTaskManager.d.ts|
|Deprecated version changed|Class name: particleAbility;<br>Method or attribute name: function startBackgroundRunning(id: number, request: NotificationRequest): Promise\<void>;<br>Old version information: |Class name: particleAbility;<br>Method or attribute name: function startBackgroundRunning(id: number, request: NotificationRequest): Promise\<void>;<br>New version information: 9<br>Substitute API: ohos.resourceschedule.backgroundTaskManager/backgroundTaskManager#startBackgroundRunning|@ohos.ability.particleAbility.d.ts|
|Deprecated version changed|Class name: particleAbility;<br>Method or attribute name: function cancelBackgroundRunning(): Promise\<void>;<br>Old version information: |Class name: particleAbility;<br>Method or attribute name: function cancelBackgroundRunning(): Promise\<void>;<br>New version information: 9<br>Substitute API: ohos.resourceschedule.backgroundTaskManager/backgroundTaskManager#stopBackgroundRunning|@ohos.ability.particleAbility.d.ts|
|Permission changed|Class name: particleAbility;<br>Method or attribute name: function startBackgroundRunning(id: number, request: NotificationRequest): Promise\<void>;<br>Old version information: |Class name: particleAbility;<br>Method or attribute name: function startBackgroundRunning(id: number, request: NotificationRequest): Promise\<void>;<br>New version information: ohos.permission.KEEP_BACKGROUND_RUNNING|@ohos.ability.particleAbility.d.ts|
|Model changed|Class name: particleAbility;<br>Method or attribute name: function startBackgroundRunning(id: number, request: NotificationRequest): Promise\<void>;<br>Old version information: |Class name: particleAbility;<br>Method or attribute name: function startBackgroundRunning(id: number, request: NotificationRequest): Promise\<void>;<br>New version information: FAModelOnly|@ohos.ability.particleAbility.d.ts|
|Model changed|Class name: particleAbility;<br>Method or attribute name: function cancelBackgroundRunning(): Promise\<void>;<br>Old version information: |Class name: particleAbility;<br>Method or attribute name: function cancelBackgroundRunning(): Promise\<void>;<br>New version information: FAModelOnly|@ohos.ability.particleAbility.d.ts|
| Change Type | Old Version | New Version | d.ts File |
| ---- | ------ | ------ | -------- |
|Added|NA|Class name: AsyKeyGeneratorBySpec;<br>Method or attribute name: generateKeyPair(callback: AsyncCallback\<KeyPair>): void;|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: AsyKeyGeneratorBySpec;<br>Method or attribute name: generateKeyPair(): Promise\<KeyPair>;|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: cert;<br>Method or attribute name: function createCertExtension(inStream: EncodingBlob, callback: AsyncCallback\<CertExtension>): void;|@ohos.security.cert.d.ts|
|Added|NA|Class name: cert;<br>Method or attribute name: function createCertExtension(inStream: EncodingBlob): Promise\<CertExtension>;|@ohos.security.cert.d.ts|
|Added|NA|Class name: CertItemType;<br>Method or attribute name: CERT_ITEM_TYPE_TBS = 0|@ohos.security.cert.d.ts|
|Added|NA|Class name: CertItemType;<br>Method or attribute name: CERT_ITEM_TYPE_PUBLIC_KEY = 1|@ohos.security.cert.d.ts|
|Added|NA|Class name: CertItemType;<br>Method or attribute name: CERT_ITEM_TYPE_ISSUER_UNIQUE_ID = 2|@ohos.security.cert.d.ts|
|Added|NA|Class name: CertItemType;<br>Method or attribute name: CERT_ITEM_TYPE_SUBJECT_UNIQUE_ID = 3|@ohos.security.cert.d.ts|
|Added|NA|Class name: CertItemType;<br>Method or attribute name: CERT_ITEM_TYPE_EXTENSIONS = 4|@ohos.security.cert.d.ts|
|Added|NA|Class name: ExtensionOidType;<br>Method or attribute name: EXTENSION_OID_TYPE_ALL = 0|@ohos.security.cert.d.ts|
|Added|NA|Class name: ExtensionOidType;<br>Method or attribute name: EXTENSION_OID_TYPE_CRITICAL = 1|@ohos.security.cert.d.ts|
|Added|NA|Class name: ExtensionOidType;<br>Method or attribute name: EXTENSION_OID_TYPE_UNCRITICAL = 2|@ohos.security.cert.d.ts|
|Added|NA|Class name: ExtensionEntryType;<br>Method or attribute name: EXTENSION_ENTRY_TYPE_ENTRY = 0|@ohos.security.cert.d.ts|
|Added|NA|Class name: ExtensionEntryType;<br>Method or attribute name: EXTENSION_ENTRY_TYPE_ENTRY_CRITICAL = 1|@ohos.security.cert.d.ts|
|Added|NA|Class name: ExtensionEntryType;<br>Method or attribute name: EXTENSION_ENTRY_TYPE_ENTRY_VALUE = 2|@ohos.security.cert.d.ts|
|Added|NA|Class name: X509Cert;<br>Method or attribute name: getCertSerialNumber(): bigint;|@ohos.security.cert.d.ts|
|Added|NA|Class name: X509Cert;<br>Method or attribute name: getItem(itemType: CertItemType): DataBlob;|@ohos.security.cert.d.ts|
|Added|NA|Class name: CertExtension;<br>Method or attribute name: getEncoded(): EncodingBlob;|@ohos.security.cert.d.ts|
|Added|NA|Class name: CertExtension;<br>Method or attribute name: getOidList(valueType: ExtensionOidType): DataArray;|@ohos.security.cert.d.ts|
|Added|NA|Class name: CertExtension;<br>Method or attribute name: getEntry(valueType: ExtensionEntryType, oid: DataBlob): DataBlob;|@ohos.security.cert.d.ts|
|Added|NA|Class name: CertExtension;<br>Method or attribute name: checkCA(): number;|@ohos.security.cert.d.ts|
|Added|NA|Class name: cryptoFramework;<br>Method or attribute name: function createAsyKeyGeneratorBySpec(asyKeySpec: AsyKeySpec): AsyKeyGeneratorBySpec;|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: PriKey;<br>Method or attribute name: getAsyKeySpec(itemType: AsyKeySpecItem): bigint \| string \| number;|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: PubKey;<br>Method or attribute name: getAsyKeySpec(itemType: AsyKeySpecItem): bigint \| string \| number;|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: Random;<br>Method or attribute name: generateRandomSync(len: number): DataBlob;|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: Random;<br>Method or attribute name: readonly algName: string;|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: AsyKeyGeneratorBySpec;<br>Method or attribute name: readonly algName: string;|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: CipherSpecItem;<br>Method or attribute name: OAEP_MD_NAME_STR = 100|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: CipherSpecItem;<br>Method or attribute name: OAEP_MGF_NAME_STR = 101|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: CipherSpecItem;<br>Method or attribute name: OAEP_MGF1_MD_STR = 102|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: CipherSpecItem;<br>Method or attribute name: OAEP_MGF1_PSRC_UINT8ARR = 103|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: SignSpecItem;<br>Method or attribute name: PSS_MD_NAME_STR = 100|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: SignSpecItem;<br>Method or attribute name: PSS_MGF_NAME_STR = 101|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: SignSpecItem;<br>Method or attribute name: PSS_MGF1_MD_STR = 102|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: SignSpecItem;<br>Method or attribute name: PSS_SALT_LEN_NUM = 103|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: SignSpecItem;<br>Method or attribute name: PSS_TRAILER_FIELD_NUM = 104|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: Cipher;<br>Method or attribute name: setCipherSpec(itemType: CipherSpecItem, itemValue: Uint8Array): void;|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: Cipher;<br>Method or attribute name: getCipherSpec(itemType: CipherSpecItem): string \| Uint8Array;|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: Sign;<br>Method or attribute name: setSignSpec(itemType: SignSpecItem, itemValue: number): void;|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: Sign;<br>Method or attribute name: getSignSpec(itemType: SignSpecItem): string \| number;|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: Verify;<br>Method or attribute name: setVerifySpec(itemType: SignSpecItem, itemValue: number): void;|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: Verify;<br>Method or attribute name: getVerifySpec(itemType: SignSpecItem): string \| number;|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: AsyKeySpecItem;<br>Method or attribute name: DSA_P_BN = 101|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: AsyKeySpecItem;<br>Method or attribute name: DSA_Q_BN = 102|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: AsyKeySpecItem;<br>Method or attribute name: DSA_G_BN = 103|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: AsyKeySpecItem;<br>Method or attribute name: DSA_SK_BN = 104|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: AsyKeySpecItem;<br>Method or attribute name: DSA_PK_BN = 105|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: AsyKeySpecItem;<br>Method or attribute name: ECC_FP_P_BN = 201|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: AsyKeySpecItem;<br>Method or attribute name: ECC_A_BN = 202|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: AsyKeySpecItem;<br>Method or attribute name: ECC_B_BN = 203|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: AsyKeySpecItem;<br>Method or attribute name: ECC_G_X_BN = 204|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: AsyKeySpecItem;<br>Method or attribute name: ECC_G_Y_BN = 205|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: AsyKeySpecItem;<br>Method or attribute name: ECC_N_BN = 206|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: AsyKeySpecItem;<br>Method or attribute name: ECC_H_NUM = 207|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: AsyKeySpecItem;<br>Method or attribute name: ECC_SK_BN = 208|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: AsyKeySpecItem;<br>Method or attribute name: ECC_PK_X_BN = 209|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: AsyKeySpecItem;<br>Method or attribute name: ECC_PK_Y_BN = 210|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: AsyKeySpecItem;<br>Method or attribute name: ECC_FIELD_TYPE_STR = 211|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: AsyKeySpecItem;<br>Method or attribute name: ECC_FIELD_SIZE_NUM = 212|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: AsyKeySpecItem;<br>Method or attribute name: ECC_CURVE_NAME_STR = 213|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: AsyKeySpecItem;<br>Method or attribute name: RSA_N_BN = 301|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: AsyKeySpecItem;<br>Method or attribute name: RSA_SK_BN = 302|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: AsyKeySpecItem;<br>Method or attribute name: RSA_PK_BN = 303|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: AsyKeySpecType;<br>Method or attribute name: COMMON_PARAMS_SPEC = 0|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: AsyKeySpecType;<br>Method or attribute name: PRIVATE_KEY_SPEC = 1|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: AsyKeySpecType;<br>Method or attribute name: PUBLIC_KEY_SPEC = 2|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: AsyKeySpecType;<br>Method or attribute name: KEY_PAIR_SPEC = 3|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: AsyKeySpec;<br>Method or attribute name: algName: string;|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: AsyKeySpec;<br>Method or attribute name: specType: AsyKeySpecType;|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: DSACommonParamsSpec;<br>Method or attribute name: p: bigint;|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: ECFieldFp;<br>Method or attribute name: p: bigint;|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: DSACommonParamsSpec;<br>Method or attribute name: q: bigint;|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: DSACommonParamsSpec;<br>Method or attribute name: g: bigint;|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: DSAPubKeySpec;<br>Method or attribute name: params: DSACommonParamsSpec;|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: DSAKeyPairSpec;<br>Method or attribute name: params: DSACommonParamsSpec;|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: DSAPubKeySpec;<br>Method or attribute name: pk: bigint;|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: DSAKeyPairSpec;<br>Method or attribute name: pk: bigint;|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: RSAPubKeySpec;<br>Method or attribute name: pk: bigint;|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: RSAKeyPairSpec;<br>Method or attribute name: pk: bigint;|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: DSAKeyPairSpec;<br>Method or attribute name: sk: bigint;|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: ECCPriKeySpec;<br>Method or attribute name: sk: bigint;|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: ECCKeyPairSpec;<br>Method or attribute name: sk: bigint;|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: RSAKeyPairSpec;<br>Method or attribute name: sk: bigint;|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: ECField;<br>Method or attribute name: fieldType: string;|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: Point;<br>Method or attribute name: x: bigint;|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: Point;<br>Method or attribute name: y: bigint;|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: ECCCommonParamsSpec;<br>Method or attribute name: field: ECField;|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: ECCCommonParamsSpec;<br>Method or attribute name: a: bigint;|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: ECCCommonParamsSpec;<br>Method or attribute name: b: bigint;|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: ECCCommonParamsSpec;<br>Method or attribute name: g: Point;|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: ECCCommonParamsSpec;<br>Method or attribute name: n: bigint;|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: RSACommonParamsSpec;<br>Method or attribute name: n: bigint;|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: ECCCommonParamsSpec;<br>Method or attribute name: h: number;|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: ECCPriKeySpec;<br>Method or attribute name: params: ECCCommonParamsSpec;|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: ECCPubKeySpec;<br>Method or attribute name: params: ECCCommonParamsSpec;|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: ECCKeyPairSpec;<br>Method or attribute name: params: ECCCommonParamsSpec;|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: ECCPubKeySpec;<br>Method or attribute name: pk: Point;|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: ECCKeyPairSpec;<br>Method or attribute name: pk: Point;|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: RSAPubKeySpec;<br>Method or attribute name: params: RSACommonParamsSpec;|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: RSAKeyPairSpec;<br>Method or attribute name: params: RSACommonParamsSpec;|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: AsyKeyGeneratorBySpec;<br>Method or attribute name: generatePriKey(callback: AsyncCallback\<PriKey>): void;|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: AsyKeyGeneratorBySpec;<br>Method or attribute name: generatePriKey(): Promise\<PriKey>;|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: AsyKeyGeneratorBySpec;<br>Method or attribute name: generatePubKey(callback: AsyncCallback\<PubKey>): void;|@ohos.security.cryptoFramework.d.ts|
|Added|NA|Class name: AsyKeyGeneratorBySpec;<br>Method or attribute name: generatePubKey(): Promise\<PubKey>;|@ohos.security.cryptoFramework.d.ts|
|Deprecated version changed|Class name: X509Cert;<br>Method or attribute name: getSerialNumber(): number;<br>Old version information: |Class name: X509Cert;<br>Method or attribute name: getSerialNumber(): number;<br>New version information: 10<br>Substitute API: ohos.security.cert.X509Cert.getCertSerialNumber|@ohos.security.cert.d.ts|
|Error code added|Class name: Key;<br>Method or attribute name: getEncoded(): DataBlob;<br>Old version information: |Class name: Key;<br>Method or attribute name: getEncoded(): DataBlob;<br>New version information: 801,17620001,17630001|@ohos.security.cryptoFramework.d.ts|
|Error code changed|Class name: cryptoFramework;<br>Method or attribute name: function createAsyKeyGenerator(algName: string): AsyKeyGenerator;<br>Old version information: 401|Class name: cryptoFramework;<br>Method or attribute name: function createAsyKeyGenerator(algName: string): AsyKeyGenerator;<br>New version information: 401,801,17620001|@ohos.security.cryptoFramework.d.ts|
|Error code changed|Class name: cryptoFramework;<br>Method or attribute name: function createCipher(transformation: string): Cipher;<br>Old version information: 401,801|Class name: cryptoFramework;<br>Method or attribute name: function createCipher(transformation: string): Cipher;<br>New version information: 401,801,17620001|@ohos.security.cryptoFramework.d.ts|
|Error code changed|Class name: cryptoFramework;<br>Method or attribute name: function createSign(algName: string): Sign;<br>Old version information: 401|Class name: cryptoFramework;<br>Method or attribute name: function createSign(algName: string): Sign;<br>New version information: 401,801,17620001|@ohos.security.cryptoFramework.d.ts|
|Error code changed|Class name: cryptoFramework;<br>Method or attribute name: function createVerify(algName: string): Verify;<br>Old version information: 401|Class name: cryptoFramework;<br>Method or attribute name: function createVerify(algName: string): Verify;<br>New version information: 401,801,17620001|@ohos.security.cryptoFramework.d.ts|
|Error code changed|Class name: cryptoFramework;<br>Method or attribute name: function createKeyAgreement(algName: string): KeyAgreement;<br>Old version information: 401|Class name: cryptoFramework;<br>Method or attribute name: function createKeyAgreement(algName: string): KeyAgreement;<br>New version information: 401,801,17620001|@ohos.security.cryptoFramework.d.ts|
|Error code changed|Class name: AsyKeyGenerator;<br>Method or attribute name: generateKeyPair(callback: AsyncCallback\<KeyPair>): void;<br>Old version information: 401,17620001|Class name: AsyKeyGenerator;<br>Method or attribute name: generateKeyPair(callback: AsyncCallback\<KeyPair>): void;<br>New version information: 401,17620001,17630001|@ohos.security.cryptoFramework.d.ts|
|Error code changed|Class name: AsyKeyGenerator;<br>Method or attribute name: generateKeyPair(): Promise\<KeyPair>;<br>Old version information: 401,17620001|Class name: AsyKeyGenerator;<br>Method or attribute name: generateKeyPair(): Promise\<KeyPair>;<br>New version information: 401,17620001,17630001|@ohos.security.cryptoFramework.d.ts|
|Error code changed|Class name: AsyKeyGenerator;<br>Method or attribute name: convertKey(pubKey: DataBlob, priKey: DataBlob, callback: AsyncCallback\<KeyPair>): void;<br>Old version information: 401,17620001|Class name: AsyKeyGenerator;<br>Method or attribute name: convertKey(pubKey: DataBlob, priKey: DataBlob, callback: AsyncCallback\<KeyPair>): void;<br>New version information: 401,17620001,17630001|@ohos.security.cryptoFramework.d.ts|
|Error code changed|Class name: AsyKeyGenerator;<br>Method or attribute name: convertKey(pubKey: DataBlob, priKey: DataBlob): Promise\<KeyPair>;<br>Old version information: 401,17620001|Class name: AsyKeyGenerator;<br>Method or attribute name: convertKey(pubKey: DataBlob, priKey: DataBlob): Promise\<KeyPair>;<br>New version information: 401,17620001,17630001|@ohos.security.cryptoFramework.d.ts|
|Type changed|Class name: PermissionUsedRequest;<br>Method or attribute name: tokenId?: number;<br>Old version information: number|Class name: PermissionUsedRequest;<br>Method or attribute name: tokenId?: number;<br>New version information: ?number|@ohos.privacyManager.d.ts|
|Type changed|Class name: PermissionUsedRequest;<br>Method or attribute name: isRemote?: boolean;<br>Old version information: boolean|Class name: PermissionUsedRequest;<br>Method or attribute name: isRemote?: boolean;<br>New version information: ?boolean|@ohos.privacyManager.d.ts|
|Type changed|Class name: PermissionUsedRequest;<br>Method or attribute name: deviceId?: string;<br>Old version information: string|Class name: PermissionUsedRequest;<br>Method or attribute name: deviceId?: string;<br>New version information: ?string|@ohos.privacyManager.d.ts|
|Type changed|Class name: PermissionUsedRequest;<br>Method or attribute name: bundleName?: string;<br>Old version information: string|Class name: PermissionUsedRequest;<br>Method or attribute name: bundleName?: string;<br>New version information: ?string|@ohos.privacyManager.d.ts|
|Type changed|Class name: PermissionUsedRequest;<br>Method or attribute name: permissionNames?: Array\<Permissions>;<br>Old version information: Array\<Permissions>|Class name: PermissionUsedRequest;<br>Method or attribute name: permissionNames?: Array\<Permissions>;<br>New version information: ?Array\<Permissions>|@ohos.privacyManager.d.ts|
|Type changed|Class name: PermissionUsedRequest;<br>Method or attribute name: beginTime?: number;<br>Old version information: number|Class name: PermissionUsedRequest;<br>Method or attribute name: beginTime?: number;<br>New version information: ?number|@ohos.privacyManager.d.ts|
|Type changed|Class name: PermissionUsedRequest;<br>Method or attribute name: endTime?: number;<br>Old version information: number|Class name: PermissionUsedRequest;<br>Method or attribute name: endTime?: number;<br>New version information: ?number|@ohos.privacyManager.d.ts|
|Function changed|Class name: PermissionUsedRequest;<br>Method or attribute name: tokenId: number;|Class name: PermissionUsedRequest;<br>Method or attribute name: tokenId?: number;|@ohos.privacyManager.d.ts|
|Function changed|Class name: PermissionUsedRequest;<br>Method or attribute name: isRemote: boolean;|Class name: PermissionUsedRequest;<br>Method or attribute name: isRemote?: boolean;|@ohos.privacyManager.d.ts|
|Function changed|Class name: PermissionUsedRequest;<br>Method or attribute name: deviceId: string;|Class name: PermissionUsedRequest;<br>Method or attribute name: deviceId?: string;|@ohos.privacyManager.d.ts|
|Function changed|Class name: PermissionUsedRequest;<br>Method or attribute name: bundleName: string;|Class name: PermissionUsedRequest;<br>Method or attribute name: bundleName?: string;|@ohos.privacyManager.d.ts|
|Function changed|Class name: PermissionUsedRequest;<br>Method or attribute name: permissionNames: Array\<Permissions>;|Class name: PermissionUsedRequest;<br>Method or attribute name: permissionNames?: Array\<Permissions>;|@ohos.privacyManager.d.ts|
|Function changed|Class name: PermissionUsedRequest;<br>Method or attribute name: beginTime: number;|Class name: PermissionUsedRequest;<br>Method or attribute name: beginTime?: number;|@ohos.privacyManager.d.ts|
|Function changed|Class name: PermissionUsedRequest;<br>Method or attribute name: endTime: number;|Class name: PermissionUsedRequest;<br>Method or attribute name: endTime?: number;|@ohos.privacyManager.d.ts|
| Change Type | Old Version | New Version | d.ts File |
| ---- | ------ | ------ | -------- |
|Added|NA|Class name: sensor;<br>Method or attribute name: function on(type: SensorId.COLOR, callback: Callback\<ColorResponse>, options?: Options): void;|@ohos.sensor.d.ts|
|Added|NA|Class name: sensor;<br>Method or attribute name: function on(type: SensorId.SAR, callback: Callback\<SarResponse>, options?: Options): void;|@ohos.sensor.d.ts|
|Added|NA|Class name: sensor;<br>Method or attribute name: function off(type: SensorId.COLOR, callback?: Callback\<ColorResponse>): void;|@ohos.sensor.d.ts|
|Added|NA|Class name: sensor;<br>Method or attribute name: function off(type: SensorId.SAR, callback?: Callback\<SarResponse>): void;|@ohos.sensor.d.ts|
|Added|NA|Class name: SensorId;<br>Method or attribute name: COLOR = 14|@ohos.sensor.d.ts|
|Added|NA|Class name: SensorId;<br>Method or attribute name: SAR = 15|@ohos.sensor.d.ts|
|Added|NA|Class name: ColorResponse;<br>Method or attribute name: lightIntensity: number;|@ohos.sensor.d.ts|
|Added|NA|Class name: ColorResponse;<br>Method or attribute name: colorTemperature: number;|@ohos.sensor.d.ts|
|Added|NA|Class name: SarResponse;<br>Method or attribute name: absorptionRatio: number;|@ohos.sensor.d.ts|
|Added|NA|Class name: VibrateFromFile;<br>Method or attribute name: type: 'file';|@ohos.vibrator.d.ts|
|Added|NA|Class name: VibrateFromFile;<br>Method or attribute name: hapticFd: HapticFileDescriptor;|@ohos.vibrator.d.ts|
|Added|NA|Class name: HapticFileDescriptor;<br>Method or attribute name: fd: number;|@ohos.vibrator.d.ts|
|Added|NA|Class name: HapticFileDescriptor;<br>Method or attribute name: offset?: number;|@ohos.vibrator.d.ts|
|Added|NA|Class name: HapticFileDescriptor;<br>Method or attribute name: length?: number;|@ohos.vibrator.d.ts|
|Deprecated version changed|Class name: vibrator;<br>Method or attribute name: function vibrate(duration: number): Promise\<void>;<br>Old version information: |Class name: vibrator;<br>Method or attribute name: function vibrate(duration: number): Promise\<void>;<br>New version information: 9<br>Substitute API: vibrator#startVibration|@ohos.vibrator.d.ts|
|Deprecated version changed|Class name: vibrator;<br>Method or attribute name: function vibrate(effectId: EffectId, callback?: AsyncCallback\<void>): void;<br>Old version information: |Class name: vibrator;<br>Method or attribute name: function vibrate(effectId: EffectId, callback?: AsyncCallback\<void>): void;<br>New version information: 9<br>Substitute API: vibrator#startVibration|@ohos.vibrator.d.ts|
|Deprecated version changed|Class name: vibrator;<br>Method or attribute name: function stop(stopMode: VibratorStopMode, callback?: AsyncCallback\<void>): void;<br>Old version information: |Class name: vibrator;<br>Method or attribute name: function stop(stopMode: VibratorStopMode, callback?: AsyncCallback\<void>): void;<br>New version information: 9<br>Substitute API: vibrator#stopVibration|@ohos.vibrator.d.ts|
|Error code changed|Class name: vibrator;<br>Method or attribute name: function startVibration(effect: VibrateEffect, attribute: VibrateAttribute, callback: AsyncCallback\<void>): void;<br>Old version information: 201,401,14600101|Class name: vibrator;<br>Method or attribute name: function startVibration(effect: VibrateEffect, attribute: VibrateAttribute, callback: AsyncCallback\<void>): void;<br>New version information: 201,401,801,14600101|@ohos.vibrator.d.ts|
|Error code changed|Class name: vibrator;<br>Method or attribute name: function startVibration(effect: VibrateEffect, attribute: VibrateAttribute): Promise\<void>;<br>Old version information: 201,401,14600101|Class name: vibrator;<br>Method or attribute name: function startVibration(effect: VibrateEffect, attribute: VibrateAttribute): Promise\<void>;<br>New version information: 201,401,801,14600101|@ohos.vibrator.d.ts|
|Permission changed|Class name: vibrator;<br>Method or attribute name: function vibrate(duration: number): Promise\<void>;<br>Old version information: |Class name: vibrator;<br>Method or attribute name: function vibrate(duration: number): Promise\<void>;<br>New version information: ohos.permission.VIBRATE|@ohos.vibrator.d.ts|
|Permission changed|Class name: vibrator;<br>Method or attribute name: function vibrate(effectId: EffectId, callback?: AsyncCallback\<void>): void;<br>Old version information: |Class name: vibrator;<br>Method or attribute name: function vibrate(effectId: EffectId, callback?: AsyncCallback\<void>): void;<br>New version information: ohos.permission.VIBRATE|@ohos.vibrator.d.ts|
|Permission changed|Class name: vibrator;<br>Method or attribute name: function stop(stopMode: VibratorStopMode, callback?: AsyncCallback\<void>): void;<br>Old version information: |Class name: vibrator;<br>Method or attribute name: function stop(stopMode: VibratorStopMode, callback?: AsyncCallback\<void>): void;<br>New version information: ohos.permission.VIBRATE|@ohos.vibrator.d.ts|
|Permission changed|Class name: VibrateOptions;<br>Method or attribute name: mode?: 'long' \| 'short';<br>Old version information: |Class name: VibrateOptions;<br>Method or attribute name: mode?: 'long' \| 'short';<br>New version information: ohos.permission.VIBRATE|@system.vibrator.d.ts|
|Permission changed|Class name: VibrateOptions;<br>Method or attribute name: success: () => void;<br>Old version information: |Class name: VibrateOptions;<br>Method or attribute name: success: () => void;<br>New version information: ohos.permission.VIBRATE|@system.vibrator.d.ts|
|Permission changed|Class name: VibrateOptions;<br>Method or attribute name: fail?: (data: string, code: number) => void;<br>Old version information: |Class name: VibrateOptions;<br>Method or attribute name: fail?: (data: string, code: number) => void;<br>New version information: ohos.permission.VIBRATE|@system.vibrator.d.ts|
|Permission changed|Class name: VibrateOptions;<br>Method or attribute name: complete?: () => void;<br>Old version information: |Class name: VibrateOptions;<br>Method or attribute name: complete?: () => void;<br>New version information: ohos.permission.VIBRATE|@system.vibrator.d.ts|
|Type changed|Class name: vibrator;<br>Method or attribute name: type VibrateEffect = VibrateTime \| VibratePreset \| VibrateFromFile;<br>Old version information: |Class name: vibrator;<br>Method or attribute name: type VibrateEffect = VibrateTime \| VibratePreset \| VibrateFromFile;<br>New version information: VibrateTime \| VibratePreset \| VibrateFromFile|@ohos.vibrator.d.ts|
|Function changed|Class name: vibrator;<br>Method or attribute name: type VibrateEffect = VibrateTime \| VibratePreset;|Class name: vibrator;<br>Method or attribute name: type VibrateEffect = VibrateTime \| VibratePreset \| VibrateFromFile;|@ohos.vibrator.d.ts|
| Change Type | Old Version | New Version | d.ts File |
| ---- | ------ | ------ | -------- |
|Deprecated version changed|Class name: systemParameter;<br>Method or attribute name: function getSync(key: string, def?: string): string;<br>Old version information: |Class name: systemParameter;<br>Method or attribute name: function getSync(key: string, def?: string): string;<br>New version information: 9<br>Substitute API: |@ohos.systemparameter.d.ts|
|Deprecated version changed|Class name: systemParameter;<br>Method or attribute name: function get(key: string, callback: AsyncCallback\<string>): void;<br>Old version information: |Class name: systemParameter;<br>Method or attribute name: function get(key: string, callback: AsyncCallback\<string>): void;<br>New version information: 9<br>Substitute API: |@ohos.systemparameter.d.ts|
|Deprecated version changed|Class name: systemParameter;<br>Method or attribute name: function get(key: string, def: string, callback: AsyncCallback\<string>): void;<br>Old version information: |Class name: systemParameter;<br>Method or attribute name: function get(key: string, def: string, callback: AsyncCallback\<string>): void;<br>New version information: 9<br>Substitute API: |@ohos.systemparameter.d.ts|
|Deprecated version changed|Class name: systemParameter;<br>Method or attribute name: function get(key: string, def?: string): Promise\<string>;<br>Old version information: |Class name: systemParameter;<br>Method or attribute name: function get(key: string, def?: string): Promise\<string>;<br>New version information: 9<br>Substitute API: |@ohos.systemparameter.d.ts|
|Deprecated version changed|Class name: systemParameter;<br>Method or attribute name: function set(key: string, value: string, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: systemParameter;<br>Method or attribute name: function set(key: string, value: string, callback: AsyncCallback\<void>): void;<br>New version information: 9<br>Substitute API: |@ohos.systemparameter.d.ts|
|Deprecated version changed|Class name: systemParameter;<br>Method or attribute name: function set(key: string, value: string): Promise\<void>;<br>Old version information: |Class name: systemParameter;<br>Method or attribute name: function set(key: string, value: string): Promise\<void>;<br>New version information: 9<br>Substitute API: |@ohos.systemparameter.d.ts|
|Access level changed|Class name: systemParameter;<br>Method or attribute name: function getSync(key: string, def?: string): string;<br>Old version information: |Class name: systemParameter;<br>Method or attribute name: function getSync(key: string, def?: string): string;<br>New version information: systemapi|@ohos.systemparameter.d.ts|
|Access level changed|Class name: systemParameter;<br>Method or attribute name: function get(key: string, callback: AsyncCallback\<string>): void;<br>Old version information: |Class name: systemParameter;<br>Method or attribute name: function get(key: string, callback: AsyncCallback\<string>): void;<br>New version information: systemapi|@ohos.systemparameter.d.ts|
|Access level changed|Class name: systemParameter;<br>Method or attribute name: function get(key: string, def: string, callback: AsyncCallback\<string>): void;<br>Old version information: |Class name: systemParameter;<br>Method or attribute name: function get(key: string, def: string, callback: AsyncCallback\<string>): void;<br>New version information: systemapi|@ohos.systemparameter.d.ts|
|Access level changed|Class name: systemParameter;<br>Method or attribute name: function get(key: string, def?: string): Promise\<string>;<br>Old version information: |Class name: systemParameter;<br>Method or attribute name: function get(key: string, def?: string): Promise\<string>;<br>New version information: systemapi|@ohos.systemparameter.d.ts|
|Access level changed|Class name: systemParameter;<br>Method or attribute name: function setSync(key: string, value: string): void;<br>Old version information: |Class name: systemParameter;<br>Method or attribute name: function setSync(key: string, value: string): void;<br>New version information: systemapi|@ohos.systemparameter.d.ts|
|Access level changed|Class name: systemParameter;<br>Method or attribute name: function set(key: string, value: string, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: systemParameter;<br>Method or attribute name: function set(key: string, value: string, callback: AsyncCallback\<void>): void;<br>New version information: systemapi|@ohos.systemparameter.d.ts|
|Access level changed|Class name: systemParameter;<br>Method or attribute name: function set(key: string, value: string): Promise\<void>;<br>Old version information: |Class name: systemParameter;<br>Method or attribute name: function set(key: string, value: string): Promise\<void>;<br>New version information: systemapi|@ohos.systemparameter.d.ts|
|Access level changed|Class name: systemParameterEnhance;<br>Method or attribute name: function getSync(key: string, def?: string): string;<br>Old version information: |Class name: systemParameterEnhance;<br>Method or attribute name: function getSync(key: string, def?: string): string;<br>New version information: systemapi|@ohos.systemParameterEnhance.d.ts|
|Access level changed|Class name: systemParameterEnhance;<br>Method or attribute name: function get(key: string, callback: AsyncCallback\<string>): void;<br>Old version information: |Class name: systemParameterEnhance;<br>Method or attribute name: function get(key: string, callback: AsyncCallback\<string>): void;<br>New version information: systemapi|@ohos.systemParameterEnhance.d.ts|
|Access level changed|Class name: systemParameterEnhance;<br>Method or attribute name: function get(key: string, def: string, callback: AsyncCallback\<string>): void;<br>Old version information: |Class name: systemParameterEnhance;<br>Method or attribute name: function get(key: string, def: string, callback: AsyncCallback\<string>): void;<br>New version information: systemapi|@ohos.systemParameterEnhance.d.ts|
|Access level changed|Class name: systemParameterEnhance;<br>Method or attribute name: function get(key: string, def?: string): Promise\<string>;<br>Old version information: |Class name: systemParameterEnhance;<br>Method or attribute name: function get(key: string, def?: string): Promise\<string>;<br>New version information: systemapi|@ohos.systemParameterEnhance.d.ts|
|Access level changed|Class name: systemParameterEnhance;<br>Method or attribute name: function setSync(key: string, value: string): void;<br>Old version information: |Class name: systemParameterEnhance;<br>Method or attribute name: function setSync(key: string, value: string): void;<br>New version information: systemapi|@ohos.systemParameterEnhance.d.ts|
|Access level changed|Class name: systemParameterEnhance;<br>Method or attribute name: function set(key: string, value: string, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: systemParameterEnhance;<br>Method or attribute name: function set(key: string, value: string, callback: AsyncCallback\<void>): void;<br>New version information: systemapi|@ohos.systemParameterEnhance.d.ts|
|Access level changed|Class name: systemParameterEnhance;<br>Method or attribute name: function set(key: string, value: string): Promise\<void>;<br>Old version information: |Class name: systemParameterEnhance;<br>Method or attribute name: function set(key: string, value: string): Promise\<void>;<br>New version information: systemapi|@ohos.systemParameterEnhance.d.ts|
|Type changed|Class name: DeviceResponse;<br>Method or attribute name: brand: string;<br>Old version information: |Class name: DeviceResponse;<br>Method or attribute name: brand: string;<br>New version information: string|@system.device.d.ts|
|Type changed|Class name: DeviceResponse;<br>Method or attribute name: manufacturer: string;<br>Old version information: |Class name: DeviceResponse;<br>Method or attribute name: manufacturer: string;<br>New version information: string|@system.device.d.ts|
|Type changed|Class name: DeviceResponse;<br>Method or attribute name: model: string;<br>Old version information: |Class name: DeviceResponse;<br>Method or attribute name: model: string;<br>New version information: string|@system.device.d.ts|
|Type changed|Class name: DeviceResponse;<br>Method or attribute name: product: string;<br>Old version information: |Class name: DeviceResponse;<br>Method or attribute name: product: string;<br>New version information: string|@system.device.d.ts|
|Type changed|Class name: DeviceResponse;<br>Method or attribute name: language: string;<br>Old version information: |Class name: DeviceResponse;<br>Method or attribute name: language: string;<br>New version information: string|@system.device.d.ts|
|Type changed|Class name: DeviceResponse;<br>Method or attribute name: region: string;<br>Old version information: |Class name: DeviceResponse;<br>Method or attribute name: region: string;<br>New version information: string|@system.device.d.ts|
|Type changed|Class name: DeviceResponse;<br>Method or attribute name: windowWidth: number;<br>Old version information: |Class name: DeviceResponse;<br>Method or attribute name: windowWidth: number;<br>New version information: number|@system.device.d.ts|
|Type changed|Class name: DeviceResponse;<br>Method or attribute name: windowHeight: number;<br>Old version information: |Class name: DeviceResponse;<br>Method or attribute name: windowHeight: number;<br>New version information: number|@system.device.d.ts|
|Type changed|Class name: DeviceResponse;<br>Method or attribute name: screenDensity: number;<br>Old version information: |Class name: DeviceResponse;<br>Method or attribute name: screenDensity: number;<br>New version information: number|@system.device.d.ts|
|Type changed|Class name: DeviceResponse;<br>Method or attribute name: screenShape: 'rect' \| 'circle';<br>Old version information: |Class name: DeviceResponse;<br>Method or attribute name: screenShape: 'rect' \| 'circle';<br>New version information: 'rect' \| 'circle'|@system.device.d.ts|
|Type changed|Class name: DeviceResponse;<br>Method or attribute name: apiVersion: number;<br>Old version information: |Class name: DeviceResponse;<br>Method or attribute name: apiVersion: number;<br>New version information: number|@system.device.d.ts|
|Type changed|Class name: DeviceResponse;<br>Method or attribute name: deviceType: string;<br>Old version information: |Class name: DeviceResponse;<br>Method or attribute name: deviceType: string;<br>New version information: string|@system.device.d.ts|
因为 它太大了无法显示 source diff 。你可以改为 查看blob
| Change Type | Old Version | New Version | d.ts File |
| ---- | ------ | ------ | -------- |
|Added|NA|Class name: UIElementInfo;<br>Method or attribute name: readonly bundleName: string;|@ohos.UiTest.d.ts|
|Added|NA|Class name: UIElementInfo;<br>Method or attribute name: readonly type: string;|@ohos.UiTest.d.ts|
|Added|NA|Class name: UIElementInfo;<br>Method or attribute name: readonly text: string;|@ohos.UiTest.d.ts|
|Added|NA|Class name: UIEventObserver;<br>Method or attribute name: once(type: 'toastShow', callback: Callback\<UIElementInfo>): void;|@ohos.UiTest.d.ts|
|Added|NA|Class name: UIEventObserver;<br>Method or attribute name: once(type: 'dialogShow', callback: Callback\<UIElementInfo>): void;|@ohos.UiTest.d.ts|
|Added|NA|Class name: Driver;<br>Method or attribute name: createUIEventObserver(): UIEventObserver;|@ohos.UiTest.d.ts|
|Type changed|Class name: WindowFilter;<br>Method or attribute name: bundleName?: string;<br>Old version information: string?|Class name: WindowFilter;<br>Method or attribute name: bundleName?: string;<br>New version information: ?string|@ohos.UiTest.d.ts|
|Type changed|Class name: WindowFilter;<br>Method or attribute name: title?: string;<br>Old version information: string?|Class name: WindowFilter;<br>Method or attribute name: title?: string;<br>New version information: ?string|@ohos.UiTest.d.ts|
|Type changed|Class name: WindowFilter;<br>Method or attribute name: focused?: boolean;<br>Old version information: boolean?|Class name: WindowFilter;<br>Method or attribute name: focused?: boolean;<br>New version information: ?boolean|@ohos.UiTest.d.ts|
|Type changed|Class name: WindowFilter;<br>Method or attribute name: actived?: boolean;<br>Old version information: boolean?|Class name: WindowFilter;<br>Method or attribute name: actived?: boolean;<br>New version information: ?boolean|@ohos.UiTest.d.ts|
| Change Type | Old Version | New Version | d.ts File |
| ---- | ------ | ------ | -------- |
|Error code changed|Class name: usbManager;<br>Method or attribute name: function setCurrentFunctions(funcs: FunctionType): Promise\<void>;<br>Old version information: 401|Class name: usbManager;<br>Method or attribute name: function setCurrentFunctions(funcs: FunctionType): Promise\<void>;<br>New version information: 401,14400002|@ohos.usbManager.d.ts|
| Change Type | Old Version | New Version | d.ts File |
| ---- | ------ | ------ | -------- |
|Added|NA|Class name: SecureDnsMode;<br>Method or attribute name: OFF = 0|@ohos.web.webview.d.ts|
|Added|NA|Class name: SecureDnsMode;<br>Method or attribute name: AUTO = 1|@ohos.web.webview.d.ts|
|Added|NA|Class name: SecureDnsMode;<br>Method or attribute name: SECURE_ONLY = 2|@ohos.web.webview.d.ts|
|Added|NA|Class name: WebviewController;<br>Method or attribute name: prefetchPage(url: string, additionalHeaders?: Array\<WebHeader>): void;|@ohos.web.webview.d.ts|
|Added|NA|Class name: WebviewController;<br>Method or attribute name: static prepareForPageLoad(url: string, preconnectable: boolean, numSockets: number): void;|@ohos.web.webview.d.ts|
|Deprecated version changed|Class name: SecureDnsMode;<br>Method or attribute name: Off = 0<br>Old version information: |Class name: SecureDnsMode;<br>Method or attribute name: Off = 0<br>New version information: 10<br>Substitute API: SecureDnsMode#OFF|@ohos.web.webview.d.ts|
|Deprecated version changed|Class name: SecureDnsMode;<br>Method or attribute name: Auto = 1<br>Old version information: |Class name: SecureDnsMode;<br>Method or attribute name: Auto = 1<br>New version information: 10<br>Substitute API: SecureDnsMode#AUTO|@ohos.web.webview.d.ts|
|Deprecated version changed|Class name: SecureDnsMode;<br>Method or attribute name: SecureOnly = 2<br>Old version information: |Class name: SecureDnsMode;<br>Method or attribute name: SecureOnly = 2<br>New version information: 10<br>Substitute API: SecureDnsMode#SECURE_ONLY|@ohos.web.webview.d.ts|
|Error code added|Class name: WebStorage;<br>Method or attribute name: static getOrigins(callback: AsyncCallback\<Array\<WebStorageOrigin>>): void;<br>Old version information: |Class name: WebStorage;<br>Method or attribute name: static getOrigins(callback: AsyncCallback\<Array\<WebStorageOrigin>>): void;<br>New version information: 401,17100012|@ohos.web.webview.d.ts|
|Error code added|Class name: WebStorage;<br>Method or attribute name: static getOriginQuota(origin: string, callback: AsyncCallback\<number>): void;<br>Old version information: |Class name: WebStorage;<br>Method or attribute name: static getOriginQuota(origin: string, callback: AsyncCallback\<number>): void;<br>New version information: 401,17100011|@ohos.web.webview.d.ts|
|Error code added|Class name: WebStorage;<br>Method or attribute name: static getOriginUsage(origin: string, callback: AsyncCallback\<number>): void;<br>Old version information: |Class name: WebStorage;<br>Method or attribute name: static getOriginUsage(origin: string, callback: AsyncCallback\<number>): void;<br>New version information: 401,17100011|@ohos.web.webview.d.ts|
|Error code added|Class name: GeolocationPermissions;<br>Method or attribute name: static getAccessibleGeolocation(origin: string, callback: AsyncCallback\<boolean>): void;<br>Old version information: |Class name: GeolocationPermissions;<br>Method or attribute name: static getAccessibleGeolocation(origin: string, callback: AsyncCallback\<boolean>): void;<br>New version information: 401,17100011|@ohos.web.webview.d.ts|
|Error code added|Class name: GeolocationPermissions;<br>Method or attribute name: static getStoredGeolocation(callback: AsyncCallback\<Array\<string>>): void;<br>Old version information: |Class name: GeolocationPermissions;<br>Method or attribute name: static getStoredGeolocation(callback: AsyncCallback\<Array\<string>>): void;<br>New version information: 401|@ohos.web.webview.d.ts|
|Error code added|Class name: WebCookieManager;<br>Method or attribute name: static saveCookieAsync(callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: WebCookieManager;<br>Method or attribute name: static saveCookieAsync(callback: AsyncCallback\<void>): void;<br>New version information: 401|@ohos.web.webview.d.ts|
|Error code added|Class name: WebviewController;<br>Method or attribute name: storeWebArchive(baseName: string, autoName: boolean, callback: AsyncCallback\<string>): void;<br>Old version information: |Class name: WebviewController;<br>Method or attribute name: storeWebArchive(baseName: string, autoName: boolean, callback: AsyncCallback\<string>): void;<br>New version information: 401,17100001,17100003|@ohos.web.webview.d.ts|
|Error code added|Class name: WebviewController;<br>Method or attribute name: runJavaScript(script: string, callback: AsyncCallback\<string>): void;<br>Old version information: |Class name: WebviewController;<br>Method or attribute name: runJavaScript(script: string, callback: AsyncCallback\<string>): void;<br>New version information: 401,17100001|@ohos.web.webview.d.ts|
|Error code added|Class name: WebviewController;<br>Method or attribute name: runJavaScriptExt(script: string, callback: AsyncCallback\<JsMessageExt>): void;<br>Old version information: |Class name: WebviewController;<br>Method or attribute name: runJavaScriptExt(script: string, callback: AsyncCallback\<JsMessageExt>): void;<br>New version information: 401,17100001|@ohos.web.webview.d.ts|
| Change Type | Old Version | New Version | d.ts File |
| ---- | ------ | ------ | -------- |
|Added|NA|Class name: Window;<br>Method or attribute name: getUIContext() : UIContext;|@ohos.window.d.ts|
|Error code added|Class name: screen;<br>Method or attribute name: function getAllScreens(): Promise\<Array\<Screen>>;<br>Old version information: |Class name: screen;<br>Method or attribute name: function getAllScreens(): Promise\<Array\<Screen>>;<br>New version information: 1400001|@ohos.screen.d.ts|
|Error code added|Class name: screen;<br>Method or attribute name: function makeExpand(options: Array\<ExpandOption>): Promise\<number>;<br>Old version information: |Class name: screen;<br>Method or attribute name: function makeExpand(options: Array\<ExpandOption>): Promise\<number>;<br>New version information: 401,1400001|@ohos.screen.d.ts|
|Error code added|Class name: screen;<br>Method or attribute name: function makeMirror(mainScreen: number, mirrorScreen: Array\<number>): Promise\<number>;<br>Old version information: |Class name: screen;<br>Method or attribute name: function makeMirror(mainScreen: number, mirrorScreen: Array\<number>): Promise\<number>;<br>New version information: 401,1400001|@ohos.screen.d.ts|
|Error code added|Class name: screen;<br>Method or attribute name: function createVirtualScreen(options: VirtualScreenOption): Promise\<Screen>;<br>Old version information: |Class name: screen;<br>Method or attribute name: function createVirtualScreen(options: VirtualScreenOption): Promise\<Screen>;<br>New version information: 201,401,1400001|@ohos.screen.d.ts|
|Error code added|Class name: screen;<br>Method or attribute name: function destroyVirtualScreen(screenId: number): Promise\<void>;<br>Old version information: |Class name: screen;<br>Method or attribute name: function destroyVirtualScreen(screenId: number): Promise\<void>;<br>New version information: 401,1400002|@ohos.screen.d.ts|
|Error code added|Class name: screen;<br>Method or attribute name: function setVirtualScreenSurface(screenId: number, surfaceId: string): Promise\<void>;<br>Old version information: |Class name: screen;<br>Method or attribute name: function setVirtualScreenSurface(screenId: number, surfaceId: string): Promise\<void>;<br>New version information: 201,401,1400001|@ohos.screen.d.ts|
|Error code added|Class name: screen;<br>Method or attribute name: function setScreenRotationLocked(isLocked: boolean): Promise\<void>;<br>Old version information: |Class name: screen;<br>Method or attribute name: function setScreenRotationLocked(isLocked: boolean): Promise\<void>;<br>New version information: 401|@ohos.screen.d.ts|
|Error code added|Class name: Screen;<br>Method or attribute name: setOrientation(orientation: Orientation): Promise\<void>;<br>Old version information: |Class name: Screen;<br>Method or attribute name: setOrientation(orientation: Orientation): Promise\<void>;<br>New version information: 401,1400003|@ohos.screen.d.ts|
|Error code added|Class name: Screen;<br>Method or attribute name: setScreenActiveMode(modeIndex: number): Promise\<void>;<br>Old version information: |Class name: Screen;<br>Method or attribute name: setScreenActiveMode(modeIndex: number): Promise\<void>;<br>New version information: 401,1400003|@ohos.screen.d.ts|
|Error code added|Class name: Screen;<br>Method or attribute name: setDensityDpi(densityDpi: number): Promise\<void>;<br>Old version information: |Class name: Screen;<br>Method or attribute name: setDensityDpi(densityDpi: number): Promise\<void>;<br>New version information: 401,1400003|@ohos.screen.d.ts|
|Access level changed|Class name: screen;<br>Method or attribute name: function getAllScreens(callback: AsyncCallback\<Array\<Screen>>): void;<br>Old version information: |Class name: screen;<br>Method or attribute name: function getAllScreens(callback: AsyncCallback\<Array\<Screen>>): void;<br>New version information: systemapi|@ohos.screen.d.ts|
|Access level changed|Class name: screen;<br>Method or attribute name: function getAllScreens(): Promise\<Array\<Screen>>;<br>Old version information: |Class name: screen;<br>Method or attribute name: function getAllScreens(): Promise\<Array\<Screen>>;<br>New version information: systemapi|@ohos.screen.d.ts|
|Access level changed|Class name: screen;<br>Method or attribute name: function on(eventType: 'connect' \| 'disconnect' \| 'change', callback: Callback\<number>): void;<br>Old version information: |Class name: screen;<br>Method or attribute name: function on(eventType: 'connect' \| 'disconnect' \| 'change', callback: Callback\<number>): void;<br>New version information: systemapi|@ohos.screen.d.ts|
|Access level changed|Class name: screen;<br>Method or attribute name: function off(eventType: 'connect' \| 'disconnect' \| 'change', callback?: Callback\<number>): void;<br>Old version information: |Class name: screen;<br>Method or attribute name: function off(eventType: 'connect' \| 'disconnect' \| 'change', callback?: Callback\<number>): void;<br>New version information: systemapi|@ohos.screen.d.ts|
|Access level changed|Class name: screen;<br>Method or attribute name: function makeExpand(options: Array\<ExpandOption>, callback: AsyncCallback\<number>): void;<br>Old version information: |Class name: screen;<br>Method or attribute name: function makeExpand(options: Array\<ExpandOption>, callback: AsyncCallback\<number>): void;<br>New version information: systemapi|@ohos.screen.d.ts|
|Access level changed|Class name: screen;<br>Method or attribute name: function makeExpand(options: Array\<ExpandOption>): Promise\<number>;<br>Old version information: |Class name: screen;<br>Method or attribute name: function makeExpand(options: Array\<ExpandOption>): Promise\<number>;<br>New version information: systemapi|@ohos.screen.d.ts|
|Access level changed|Class name: screen;<br>Method or attribute name: function makeMirror(mainScreen: number, mirrorScreen: Array\<number>, callback: AsyncCallback\<number>): void;<br>Old version information: |Class name: screen;<br>Method or attribute name: function makeMirror(mainScreen: number, mirrorScreen: Array\<number>, callback: AsyncCallback\<number>): void;<br>New version information: systemapi|@ohos.screen.d.ts|
|Access level changed|Class name: screen;<br>Method or attribute name: function makeMirror(mainScreen: number, mirrorScreen: Array\<number>): Promise\<number>;<br>Old version information: |Class name: screen;<br>Method or attribute name: function makeMirror(mainScreen: number, mirrorScreen: Array\<number>): Promise\<number>;<br>New version information: systemapi|@ohos.screen.d.ts|
|Access level changed|Class name: screen;<br>Method or attribute name: function createVirtualScreen(options: VirtualScreenOption, callback: AsyncCallback\<Screen>): void;<br>Old version information: |Class name: screen;<br>Method or attribute name: function createVirtualScreen(options: VirtualScreenOption, callback: AsyncCallback\<Screen>): void;<br>New version information: systemapi|@ohos.screen.d.ts|
|Access level changed|Class name: screen;<br>Method or attribute name: function createVirtualScreen(options: VirtualScreenOption): Promise\<Screen>;<br>Old version information: |Class name: screen;<br>Method or attribute name: function createVirtualScreen(options: VirtualScreenOption): Promise\<Screen>;<br>New version information: systemapi|@ohos.screen.d.ts|
|Access level changed|Class name: screen;<br>Method or attribute name: function destroyVirtualScreen(screenId: number, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: screen;<br>Method or attribute name: function destroyVirtualScreen(screenId: number, callback: AsyncCallback\<void>): void;<br>New version information: systemapi|@ohos.screen.d.ts|
|Access level changed|Class name: screen;<br>Method or attribute name: function destroyVirtualScreen(screenId: number): Promise\<void>;<br>Old version information: |Class name: screen;<br>Method or attribute name: function destroyVirtualScreen(screenId: number): Promise\<void>;<br>New version information: systemapi|@ohos.screen.d.ts|
|Access level changed|Class name: screen;<br>Method or attribute name: function setVirtualScreenSurface(screenId: number, surfaceId: string, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: screen;<br>Method or attribute name: function setVirtualScreenSurface(screenId: number, surfaceId: string, callback: AsyncCallback\<void>): void;<br>New version information: systemapi|@ohos.screen.d.ts|
|Access level changed|Class name: screen;<br>Method or attribute name: function setVirtualScreenSurface(screenId: number, surfaceId: string): Promise\<void>;<br>Old version information: |Class name: screen;<br>Method or attribute name: function setVirtualScreenSurface(screenId: number, surfaceId: string): Promise\<void>;<br>New version information: systemapi|@ohos.screen.d.ts|
|Access level changed|Class name: screen;<br>Method or attribute name: function isScreenRotationLocked(callback: AsyncCallback\<boolean>): void;<br>Old version information: |Class name: screen;<br>Method or attribute name: function isScreenRotationLocked(callback: AsyncCallback\<boolean>): void;<br>New version information: systemapi|@ohos.screen.d.ts|
|Access level changed|Class name: screen;<br>Method or attribute name: function isScreenRotationLocked(): Promise\<boolean>;<br>Old version information: |Class name: screen;<br>Method or attribute name: function isScreenRotationLocked(): Promise\<boolean>;<br>New version information: systemapi|@ohos.screen.d.ts|
|Access level changed|Class name: screen;<br>Method or attribute name: function setScreenRotationLocked(isLocked: boolean, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: screen;<br>Method or attribute name: function setScreenRotationLocked(isLocked: boolean, callback: AsyncCallback\<void>): void;<br>New version information: systemapi|@ohos.screen.d.ts|
|Access level changed|Class name: screen;<br>Method or attribute name: function setScreenRotationLocked(isLocked: boolean): Promise\<void>;<br>Old version information: |Class name: screen;<br>Method or attribute name: function setScreenRotationLocked(isLocked: boolean): Promise\<void>;<br>New version information: systemapi|@ohos.screen.d.ts|
|Access level changed|Class name: ExpandOption;<br>Method or attribute name: interface ExpandOption<br>Old version information: |Class name: ExpandOption;<br>Method or attribute name: interface ExpandOption<br>New version information: systemapi|@ohos.screen.d.ts|
|Access level changed|Class name: ExpandOption;<br>Method or attribute name: screenId: number;<br>Old version information: |Class name: ExpandOption;<br>Method or attribute name: screenId: number;<br>New version information: systemapi|@ohos.screen.d.ts|
|Access level changed|Class name: ExpandOption;<br>Method or attribute name: startX: number;<br>Old version information: |Class name: ExpandOption;<br>Method or attribute name: startX: number;<br>New version information: systemapi|@ohos.screen.d.ts|
|Access level changed|Class name: ExpandOption;<br>Method or attribute name: startY: number;<br>Old version information: |Class name: ExpandOption;<br>Method or attribute name: startY: number;<br>New version information: systemapi|@ohos.screen.d.ts|
|Access level changed|Class name: VirtualScreenOption;<br>Method or attribute name: interface VirtualScreenOption<br>Old version information: |Class name: VirtualScreenOption;<br>Method or attribute name: interface VirtualScreenOption<br>New version information: systemapi|@ohos.screen.d.ts|
|Access level changed|Class name: VirtualScreenOption;<br>Method or attribute name: name: string;<br>Old version information: |Class name: VirtualScreenOption;<br>Method or attribute name: name: string;<br>New version information: systemapi|@ohos.screen.d.ts|
|Access level changed|Class name: VirtualScreenOption;<br>Method or attribute name: width: number;<br>Old version information: |Class name: VirtualScreenOption;<br>Method or attribute name: width: number;<br>New version information: systemapi|@ohos.screen.d.ts|
|Access level changed|Class name: VirtualScreenOption;<br>Method or attribute name: height: number;<br>Old version information: |Class name: VirtualScreenOption;<br>Method or attribute name: height: number;<br>New version information: systemapi|@ohos.screen.d.ts|
|Access level changed|Class name: VirtualScreenOption;<br>Method or attribute name: density: number;<br>Old version information: |Class name: VirtualScreenOption;<br>Method or attribute name: density: number;<br>New version information: systemapi|@ohos.screen.d.ts|
|Access level changed|Class name: VirtualScreenOption;<br>Method or attribute name: surfaceId: string;<br>Old version information: |Class name: VirtualScreenOption;<br>Method or attribute name: surfaceId: string;<br>New version information: systemapi|@ohos.screen.d.ts|
|Access level changed|Class name: ScreenSourceMode;<br>Method or attribute name: enum ScreenSourceMode<br>Old version information: |Class name: ScreenSourceMode;<br>Method or attribute name: enum ScreenSourceMode<br>New version information: systemapi|@ohos.screen.d.ts|
|Access level changed|Class name: ScreenSourceMode;<br>Method or attribute name: SCREEN_MAIN = 0<br>Old version information: |Class name: ScreenSourceMode;<br>Method or attribute name: SCREEN_MAIN = 0<br>New version information: systemapi|@ohos.screen.d.ts|
|Access level changed|Class name: ScreenSourceMode;<br>Method or attribute name: SCREEN_MIRROR = 1<br>Old version information: |Class name: ScreenSourceMode;<br>Method or attribute name: SCREEN_MIRROR = 1<br>New version information: systemapi|@ohos.screen.d.ts|
|Access level changed|Class name: ScreenSourceMode;<br>Method or attribute name: SCREEN_EXTEND = 2<br>Old version information: |Class name: ScreenSourceMode;<br>Method or attribute name: SCREEN_EXTEND = 2<br>New version information: systemapi|@ohos.screen.d.ts|
|Access level changed|Class name: ScreenSourceMode;<br>Method or attribute name: SCREEN_ALONE = 3<br>Old version information: |Class name: ScreenSourceMode;<br>Method or attribute name: SCREEN_ALONE = 3<br>New version information: systemapi|@ohos.screen.d.ts|
|Access level changed|Class name: Screen;<br>Method or attribute name: interface Screen<br>Old version information: |Class name: Screen;<br>Method or attribute name: interface Screen<br>New version information: systemapi|@ohos.screen.d.ts|
|Access level changed|Class name: Screen;<br>Method or attribute name: readonly id: number;<br>Old version information: |Class name: Screen;<br>Method or attribute name: readonly id: number;<br>New version information: systemapi|@ohos.screen.d.ts|
|Access level changed|Class name: Screen;<br>Method or attribute name: readonly parent: number;<br>Old version information: |Class name: Screen;<br>Method or attribute name: readonly parent: number;<br>New version information: systemapi|@ohos.screen.d.ts|
|Access level changed|Class name: Screen;<br>Method or attribute name: readonly supportedModeInfo: Array\<ScreenModeInfo>;<br>Old version information: |Class name: Screen;<br>Method or attribute name: readonly supportedModeInfo: Array\<ScreenModeInfo>;<br>New version information: systemapi|@ohos.screen.d.ts|
|Access level changed|Class name: Screen;<br>Method or attribute name: readonly activeModeIndex: number;<br>Old version information: |Class name: Screen;<br>Method or attribute name: readonly activeModeIndex: number;<br>New version information: systemapi|@ohos.screen.d.ts|
|Access level changed|Class name: Screen;<br>Method or attribute name: readonly orientation: Orientation;<br>Old version information: |Class name: Screen;<br>Method or attribute name: readonly orientation: Orientation;<br>New version information: systemapi|@ohos.screen.d.ts|
|Access level changed|Class name: Screen;<br>Method or attribute name: readonly sourceMode: ScreenSourceMode;<br>Old version information: |Class name: Screen;<br>Method or attribute name: readonly sourceMode: ScreenSourceMode;<br>New version information: systemapi|@ohos.screen.d.ts|
|Access level changed|Class name: Screen;<br>Method or attribute name: setOrientation(orientation: Orientation, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: Screen;<br>Method or attribute name: setOrientation(orientation: Orientation, callback: AsyncCallback\<void>): void;<br>New version information: systemapi|@ohos.screen.d.ts|
|Access level changed|Class name: Screen;<br>Method or attribute name: setOrientation(orientation: Orientation): Promise\<void>;<br>Old version information: |Class name: Screen;<br>Method or attribute name: setOrientation(orientation: Orientation): Promise\<void>;<br>New version information: systemapi|@ohos.screen.d.ts|
|Access level changed|Class name: Screen;<br>Method or attribute name: setScreenActiveMode(modeIndex: number, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: Screen;<br>Method or attribute name: setScreenActiveMode(modeIndex: number, callback: AsyncCallback\<void>): void;<br>New version information: systemapi|@ohos.screen.d.ts|
|Access level changed|Class name: Screen;<br>Method or attribute name: setScreenActiveMode(modeIndex: number): Promise\<void>;<br>Old version information: |Class name: Screen;<br>Method or attribute name: setScreenActiveMode(modeIndex: number): Promise\<void>;<br>New version information: systemapi|@ohos.screen.d.ts|
|Access level changed|Class name: Screen;<br>Method or attribute name: setDensityDpi(densityDpi: number, callback: AsyncCallback\<void>): void;<br>Old version information: |Class name: Screen;<br>Method or attribute name: setDensityDpi(densityDpi: number, callback: AsyncCallback\<void>): void;<br>New version information: systemapi|@ohos.screen.d.ts|
|Access level changed|Class name: Screen;<br>Method or attribute name: setDensityDpi(densityDpi: number): Promise\<void>;<br>Old version information: |Class name: Screen;<br>Method or attribute name: setDensityDpi(densityDpi: number): Promise\<void>;<br>New version information: systemapi|@ohos.screen.d.ts|
|Access level changed|Class name: Orientation;<br>Method or attribute name: enum Orientation<br>Old version information: |Class name: Orientation;<br>Method or attribute name: enum Orientation<br>New version information: systemapi|@ohos.screen.d.ts|
|Access level changed|Class name: ScreenModeInfo;<br>Method or attribute name: interface ScreenModeInfo<br>Old version information: |Class name: ScreenModeInfo;<br>Method or attribute name: interface ScreenModeInfo<br>New version information: systemapi|@ohos.screen.d.ts|
|Permission changed|Class name: screen;<br>Method or attribute name: function createVirtualScreen(options: VirtualScreenOption): Promise\<Screen>;<br>Old version information: |Class name: screen;<br>Method or attribute name: function createVirtualScreen(options: VirtualScreenOption): Promise\<Screen>;<br>New version information: ohos.permission.CAPTURE_SCREEN|@ohos.screen.d.ts|
|Permission changed|Class name: screen;<br>Method or attribute name: function setVirtualScreenSurface(screenId: number, surfaceId: string): Promise\<void>;<br>Old version information: |Class name: screen;<br>Method or attribute name: function setVirtualScreenSurface(screenId: number, surfaceId: string): Promise\<void>;<br>New version information: ohos.permission.CAPTURE_SCREEN|@ohos.screen.d.ts|
|Function changed|Class name: Window;<br>Method or attribute name: off(type: 'windowEvent',callback:Callback\<WindowEventType>):void;|Class name: Window;<br>Method or attribute name: off(type:'windowEvent',callback?: Callback\<WindowEventType):void;|@ohos.window.d.ts|
# ArkUI Subsystem LocalStorage Class ChangeLog
## cl.LocalStorage.1 Return Type Change of the get API
Changed the return type from **get\<T>(propName: string): T** to **get\<T>(propName: string): T | undefined**.
**Change Impact**
None
## cl.LocalStorage.2 Mandatory/Optional Change of the newValue Parameter in setOrCreate
**Change Impact**
API declaration before change:
```js
setOrCreate<T>(propName: string, newValue?: T): boolean
```
API declaration after change:
```js
setOrCreate<T>(propName: string, newValue: T): boolean
```
The **newValue** parameter becomes mandatory.
If it is not specified when an application calls the API, the build will fail after the SDK is replaced.
**Adaptation Guide**
```js
let storage = new LocalStorage();
storage.setOrCreate('propA', 'hello');
```
## cl.LocalStorage.3 link Parameter and Return Type Changes
**Change Impact**
API declaration before change:
```js
link<T>(propName: string, linkUser?: T, subscribersName?: string): T
```
API declaration after change:
```js
link<T>(propName: string): SubscribedAbstractProperty<T>
```
1. The second and third parameters of the **link** API are reserved for internal use by the framework. Therefore, the API is changed to contain only one parameter.
2. The return type **T** is changed to **SubscribedAbstractProperty**.
**Adaptation Guide**
```js
let storage = new LocalStorage({"PropA": "47"});
let linA = storage.link("PropA");
linA.set(50);
```
## cl.LocalStorage.4 setAndLink Parameter and Return Type Changes
**Change Impact**
API declaration before change:
```js
setAndLink<T>(propName: string, defaultValue: T, linkUser?: T, subscribersName?: string): T
```
API declaration after change:
```js
setAndLink<T>(propName: string, defaultValue: T): SubscribedAbstractProperty<T>
```
1. The third and fourth parameters of the **setAndLink** API are reserved for internal use by the framework. Therefore, the API is changed to contain two parameters.
2. The return type **T** is changed to **SubscribedAbstractProperty**.
**Adaptation Guide**
```js
let storage = new LocalStorage({"PropA": "47"});
let linA = storage.setAndLink("PropA", "48")
linA.set(50);
```
## cl.LocalStorage.5 prop Parameter and Return Type Changes
**Change Impact**
API declaration before change:
```js
prop<T>(propName: string, propUser?: T, subscribersName?: string): T
```
API declaration after change:
```js
prop<S>(propName: string): SubscribedAbstractProperty<S>
```
1. The second and third parameters of the **prop** API are reserved for internal use by the framework. Therefore, the API is changed to contain only one parameter.
2. The return type **T** is changed to **SubscribedAbstractProperty**.
**Adaptation Guide**
```js
let storage = new LocalStorage({"PropA": "47"});
let propA = storage.prop("PropA");
propA.set(51); // one-way sync
```
## cl.LocalStorage.6 setAndProp Parameter and Return Type Changes
**Change Impact**
API declaration before change:
```js
setAndProp<T>(propName: string, defaultValue: T, propUser?: T, subscribersName?: string): T
```
API declaration after change:
```js
setAndProp<S>(propName: string, defaultValue: S): SubscribedAbstractProperty<S>
```
1. The third and fourth parameters of the **setAndProp** API are reserved for internal use by the framework. Therefore, the API is changed to contain two parameters.
2. The return type **T** is changed to **SubscribedAbstractProperty**.
**Adaptation Guide**
```js
let storage = new LocalStorage({"PropA": "47"});
let propA = storage.setAndProp("PropA", "48");
propA.set(51); // one-way sync
```
# Security Subsystem ChangeLog
## cl.security.1 Change of the setSeed API of Random from Asynchronous to Synchronous
**Change Impacts**
Behavior of released JavaScript APIs will be changed.
The application needs to adapt these APIs so that it can be properly compiled in the SDK environment of the new version.
**Key API/Component Changes**
API prototype before the change:
setSeed(seed : DataBlob, callback : AsyncCallback\<void>) : void;
setSeed(seed : DataBlob) : Promise\<void>;
API prototype after the change:
setSeed(seed : DataBlob) : void;
**Adaptation Guide**
See the API adaptation guide of **setSeed** in the API reference:
[Crypto Framework - API Reference](https://gitee.com/openharmony/docs/blob/master/en/application-dev/reference/apis/js-apis-cryptoFramework.md)
## cl.security.2 Migration of interface DataArray from @ohos.security.cryptoFramework.d.ts to @ohos.security.cert.d.ts
**Change Impacts**
Behavior of released JavaScript APIs will be changed.
The application needs to adapt these APIs so that it can be properly compiled in the SDK environment of the new version.
**Key API/Component Changes**
Migrated **interface DataArray** from **@ohos.security.cryptoFramework.d.ts** to **@ohos.security.cert.d.ts**.
**Adaptation Guide**
Import and use the new .d.ts file:
import cryptoCert from '@ohos.security.cert';
See the corresponding API adaptation guide in the API reference:
[Certificate - API Reference](https://gitee.com/openharmony/docs/blob/master/en/application-dev/reference/apis/js-apis-cert.md)
## cl.security.3 Migration of interface EncodingFormat from @ohos.security.cryptoFramework.d.ts to @ohos.security.cert.d.ts
**Change Impacts**
Behavior of released JavaScript APIs will be changed.
The application needs to adapt these APIs so that it can be properly compiled in the SDK environment of the new version.
**Key API/Component Changes**
Migrated **interface EncodingFormat** from **@ohos.security.cryptoFramework.d.ts** to **@ohos.security.cert.d.ts**.
**Adaptation Guide**
Import and use the new .d.ts file:
import cryptoCert from '@ohos.security.cert';
See the corresponding API adaptation guide in the API reference:
[Certificate - API Reference](https://gitee.com/openharmony/docs/blob/master/en/application-dev/reference/apis/js-apis-cert.md)
## cl.security.4 Migration of interface EncodingBlob from @ohos.security.cryptoFramework.d.ts to @ohos.security.cert.d.ts
**Change Impacts**
Behavior of released JavaScript APIs will be changed.
The application needs to adapt these APIs so that it can be properly compiled in the SDK environment of the new version.
**Key API/Component Changes**
Migrated **interface EncodingBlob** from **@ohos.security.cryptoFramework.d.ts** to **@ohos.security.cert.d.ts**.
**Adaptation Guide**
Import and use the new .d.ts file:
import cryptoCert from '@ohos.security.cert';
See the corresponding API adaptation guide in the API reference:
[Certificate - API Reference](https://gitee.com/openharmony/docs/blob/master/en/application-dev/reference/apis/js-apis-cert.md)
## cl.security.5 Migration of interface CertChainData from @ohos.security.cryptoFramework.d.ts to @ohos.security.cert.d.ts
**Change Impacts**
Behavior of released JavaScript APIs will be changed.
The application needs to adapt these APIs so that it can be properly compiled in the SDK environment of the new version.
**Key API/Component Changes**
Migrated **interface CertChainData** from **@ohos.security.cryptoFramework.d.ts** to **@ohos.security.cert.d.ts**.
**Adaptation Guide**
Import and use the new .d.ts file:
import cryptoCert from '@ohos.security.cert';
See the corresponding API adaptation guide in the API reference:
[Certificate - API Reference](https://gitee.com/openharmony/docs/blob/master/en/application-dev/reference/apis/js-apis-cert.md)
## cl.security.6 Migration of interface X509Cert from @ohos.security.cryptoFramework.d.ts to @ohos.security.cert.d.ts
**Change Impacts**
Behavior of released JavaScript APIs will be changed.
The application needs to adapt these APIs so that it can be properly compiled in the SDK environment of the new version.
**Key API/Component Changes**
Migrated **interface X509Cert** from **@ohos.security.cryptoFramework.d.ts** to **@ohos.security.cert.d.ts**.
**Adaptation Guide**
Import and use the new .d.ts file:
import cryptoCert from '@ohos.security.cert';
See the corresponding API adaptation guide in the API reference:
[Certificate - API Reference](https://gitee.com/openharmony/docs/blob/master/en/application-dev/reference/apis/js-apis-cert.md)
## cl.security.7 Migration of function createX509Cert from @ohos.security.cryptoFramework.d.ts to @ohos.security.cert.d.ts
**Change Impacts**
Behavior of released JavaScript APIs will be changed.
The application needs to adapt these APIs so that it can be properly compiled in the SDK environment of the new version.
**Key API/Component Changes**
Migrated **function createX509Cert** from **@ohos.security.cryptoFramework.d.ts** to **@ohos.security.cert.d.ts**.
**Adaptation Guide**
Import and use the new .d.ts file:
import cryptoCert from '@ohos.security.cert';
See the corresponding API adaptation guide in the API reference:
[Certificate - API Reference](https://gitee.com/openharmony/docs/blob/master/en/application-dev/reference/apis/js-apis-cert.md)
## cl.security.8 Migration of interface X509CrlEntry from @ohos.security.cryptoFramework.d.ts to @ohos.security.cert.d.ts.
**Change Impacts**
Behavior of released JavaScript APIs will be changed.
The application needs to adapt these APIs so that it can be properly compiled in the SDK environment of the new version.
**Key API/Component Changes**
Migrated **interface X509CrlEntry** from **@ohos.security.cryptoFramework.d.ts** to **@ohos.security.cert.d.ts**.
**Adaptation Guide**
Import and use the new .d.ts file:
import cryptoCert from '@ohos.security.cert';
See the corresponding API adaptation guide in the API reference:
[Certificate - API Reference](https://gitee.com/openharmony/docs/blob/master/en/application-dev/reference/apis/js-apis-cert.md)
## cl.security.9 Migration of interface X509Crl from @ohos.security.cryptoFramework.d.ts to @ohos.security.cert.d.ts
**Change Impacts**
Behavior of released JavaScript APIs will be changed.
The application needs to adapt these APIs so that it can be properly compiled in the SDK environment of the new version.
**Key API/Component Changes**
Migrated **interface X509Crl** from **@ohos.security.cryptoFramework.d.ts** to **@ohos.security.cert.d.ts**.
**Adaptation Guide**
Import and use the new .d.ts file:
import cryptoCert from '@ohos.security.cert';
See the corresponding API adaptation guide in the API reference:
[Certificate - API Reference](https://gitee.com/openharmony/docs/blob/master/en/application-dev/reference/apis/js-apis-cert.md)
## cl.security.10 Migration of function createX509Crl from @ohos.security.cryptoFramework.d.ts to @ohos.security.cert.d.ts
**Change Impacts**
Behavior of released JavaScript APIs will be changed.
The application needs to adapt these APIs so that it can be properly compiled in the SDK environment of the new version.
**Key API/Component Changes**
Migrated **function createX509Crl** from **@ohos.security.cryptoFramework.d.ts** to **@ohos.security.cert.d.ts**.
**Adaptation Guide**
Import and use the new .d.ts file:
import cryptoCert from '@ohos.security.cert';
See the corresponding API adaptation guide in the API reference:
[Certificate - API Reference](https://gitee.com/openharmony/docs/blob/master/en/application-dev/reference/apis/js-apis-cert.md)
## cl.security.11 Migration of interface CertChainValidator from @ohos.security.cryptoFramework.d.ts to @ohos.security.cert.d.ts
**Change Impacts**
Behavior of released JavaScript APIs will be changed.
The application needs to adapt these APIs so that it can be properly compiled in the SDK environment of the new version.
**Key API/Component Changes**
Migrated **interface CertChainValidator** from **@ohos.security.cryptoFramework.d.ts** to **@ohos.security.cert.d.ts**.
**Adaptation Guide**
Import and use the new .d.ts file:
import cryptoCert from '@ohos.security.cert';
See the corresponding API adaptation guide in the API reference:
[Certificate - API Reference](https://gitee.com/openharmony/docs/blob/master/en/application-dev/reference/apis/js-apis-cert.md)
## cl.security.12 Migration of function createCertChainValidator from @ohos.security.cryptoFramework.d.ts to @ohos.security.cert.d.ts
**Change Impacts**
Behavior of released JavaScript APIs will be changed.
The application needs to adapt these APIs so that it can be properly compiled in the SDK environment of the new version.
**Key API/Component Changes**
Migrated **function createCertChainValidator** from **@ohos.security.cryptoFramework.d.ts** to **@ohos.security.cert.d.ts**.
**Adaptation Guide**
Import and use the new .d.ts file:
import cryptoCert from '@ohos.security.cert';
See the corresponding API adaptation guide in the API reference:
[Certificate - API Reference](https://gitee.com/openharmony/docs/blob/master/en/application-dev/reference/apis/js-apis-cert.md)
## cl.security.13 Change of the getPublicKey API of X509Cert from Asynchronous to Synchronous
**Change Impacts**
Behavior of released JavaScript APIs will be changed.
The application needs to adapt these APIs so that it can be properly compiled in the SDK environment of the new version.
**Key API/Component Changes**
API prototype before the change:
getPublicKey(callback : AsyncCallback\<PubKey>) : void;
getPublicKey() : Promise\<PubKey>;
API prototype after the change:
getPublicKey() : cryptoFramework.PubKey;
**Adaptation Guide**
See the corresponding API adaptation guide in the API reference:
[Certificate - API Reference](https://gitee.com/openharmony/docs/blob/master/en/application-dev/reference/apis/js-apis-cert.md)
## cl.security.14 Change of the checkValidityWithDate API of X509Cert from Asynchronous to Synchronous
**Change Impacts**
Behavior of released JavaScript APIs will be changed.
The application needs to adapt these APIs so that it can be properly compiled in the SDK environment of the new version.
**Key API/Component Changes**
API prototype before the change:
checkValidityWithDate(date: string, callback : AsyncCallback\<void>) : void;
checkValidityWithDate(date: string) : Promise\<void>;
API prototype after the change:
checkValidityWithDate(date: string) : void;
**Adaptation Guide**
See the corresponding API adaptation guide in the API reference:
[Certificate - API Reference](https://gitee.com/openharmony/docs/blob/master/en/application-dev/reference/apis/js-apis-cert.md)
## cl.security.15 Change of the getCertIssuer API of X509CrlEntry from Asynchronous to Synchronous
**Change Impacts**
Behavior of released JavaScript APIs will be changed.
The application needs to adapt these APIs so that it can be properly compiled in the SDK environment of the new version.
**Key API/Component Changes**
API prototype before the change:
getCertIssuer(callback : AsyncCallback\<DataBlob>) : void;
getCertIssuer() : Promise\<DataBlob>;
API prototype after the change:
getCertIssuer() : DataBlob;
**Adaptation Guide**
See the corresponding API adaptation guide in the API reference:
[Certificate - API Reference](https://gitee.com/openharmony/docs/blob/master/en/application-dev/reference/apis/js-apis-cert.md)
## cl.security.16 Change of the getRevocationDate API of X509CrlEntry from Asynchronous to Synchronous
**Change Impacts**
Behavior of released JavaScript APIs will be changed.
The application needs to adapt these APIs so that it can be properly compiled in the SDK environment of the new version.
**Key API/Component Changes**
API prototype before the change:
getRevocationDate(callback : AsyncCallback\<string>) : void;
getRevocationDate() : Promise\<string>;
API prototype after the change:
getRevocationDate() : string;
**Adaptation Guide**
See the corresponding API adaptation guide in the API reference:
[Certificate - API Reference](https://gitee.com/openharmony/docs/blob/master/en/application-dev/reference/apis/js-apis-cert.md)
## cl.security.17 Change of the isRevoked API of X509Crl from Asynchronous to Synchronous
**Change Impacts**
Behavior of released JavaScript APIs will be changed.
The application needs to adapt these APIs so that it can be properly compiled in the SDK environment of the new version.
**Key API/Component Changes**
API prototype before the change:
isRevoked(cert : X509Cert, callback : AsyncCallback\<boolean>) : void;
isRevoked(cert : X509Cert) : Promise\<boolean>;
API prototype after the change:
isRevoked(cert : X509Cert) : boolean;
**Adaptation Guide**
See the corresponding API adaptation guide in the API reference:
[Certificate - API Reference](https://gitee.com/openharmony/docs/blob/master/en/application-dev/reference/apis/js-apis-cert.md)
## cl.security.18 Change of the getRevokedCert API of X509Crl from Asynchronous to Synchronous
**Change Impacts**
Behavior of released JavaScript APIs will be changed.
The application needs to adapt these APIs so that it can be properly compiled in the SDK environment of the new version.
**Key API/Component Changes**
API prototype before the change:
getRevokedCert(serialNumber : number, callback : AsyncCallback\<X509CrlEntry>) : void;
getRevokedCert(serialNumber : number) : Promise\<X509CrlEntry>;
API prototype after the change:
getRevokedCert(serialNumber : number) : X509CrlEntry;
**Adaptation Guide**
See the corresponding API adaptation guide in the API reference:
[Certificate - API Reference](https://gitee.com/openharmony/docs/blob/master/en/application-dev/reference/apis/js-apis-cert.md)
## cl.security.19 Change of the getRevokedCertWithCert API of X509Crl from Asynchronous to Synchronous
**Change Impacts**
Behavior of released JavaScript APIs will be changed.
The application needs to adapt these APIs so that it can be properly compiled in the SDK environment of the new version.
**Key API/Component Changes**
API prototype before the change:
getRevokedCertWithCert(cert : X509Cert, callback : AsyncCallback\<X509CrlEntry>) : void;
getRevokedCertWithCert(cert : X509Cert) : Promise\<X509CrlEntry>;
API prototype after the change:
getRevokedCertWithCert(cert : X509Cert) : X509CrlEntry;
**Adaptation Guide**
See the corresponding API adaptation guide in the API reference:
[Certificate - API Reference](https://gitee.com/openharmony/docs/blob/master/en/application-dev/reference/apis/js-apis-cert.md)
## cl.security.20 Change of the getTbsInfo API of X509Crl from Asynchronous to Synchronous
**Change Impacts**
Behavior of released JavaScript APIs will be changed.
The application needs to adapt these APIs so that it can be properly compiled in the SDK environment of the new version.
**Key API/Component Changes**
API prototype before the change:
getTbsInfo(callback : AsyncCallback\<DataBlob>) : void;
getTbsInfo() : Promise\<DataBlob>;
API prototype after the change:
getTbsInfo() : DataBlob;
**Adaptation Guide**
See the corresponding API adaptation guide in the API reference:
[Certificate - API Reference](https://gitee.com/openharmony/docs/blob/master/en/application-dev/reference/apis/js-apis-cert.md)
## cl.security.21 Support of No-Hash Signing Mode for HUKS
Before the change, the application passes **huks.HuksTag.HUKS_TAG_DIGEST = huks.HuksKeyDigest.HUKS_DIGEST_NONE** and HUKS uses **huks.HuksKeyDigest.HUKS_DIGEST_SHA256** for processing by default. After the change, the application passes **huks.HuksTag.HUKS_TAG_DIGEST = huks.HuksKeyDigest.HUKS_DIGEST_NONE** and HUKS does not perform digest processing by default. In this case, the service needs to perform the hash operation on the original data and then pass the hashed digest to HUKS for signing or signature verification.
**Change Impacts**
Behavior of released JavaScript APIs will be changed.
The application needs to adapt these APIs so that the signing or signature verification result can be passed before and after the change.
**Key API/Component Changes**
Released JavaScript APIs remain unchanged, but parameter sets passed to the APIs are changed.
The service uses the No-Hash signing mode, and needs to hash the original data and then pass the hashed digest to the signing or signature verification API of HUKS. In addition, the **huks.HuksTag.HUKS_TAG_DIGEST** parameter is set to **huks.HuksKeyDigest.HUKS_DIGEST_NONE**.
**Adaptation Guide**
Take signing as an example. The sample code is as follows:
```js
import huks from '@ohos.security.huks';
let keyAlias = 'rsa_Key';
/* Digest value after SHA-256 encryption */
let inDataAfterSha256 = new Uint8Array(
0x4B, 0x1E, 0x22, 0x64, 0xA9, 0x89, 0x60, 0x1D, 0xEC, 0x78, 0xC0, 0x5D, 0xBE, 0x46, 0xAD, 0xCF,
0x1C, 0x35, 0x16, 0x11, 0x34, 0x01, 0x4E, 0x9B, 0x7C, 0x00, 0x66, 0x0E, 0xCA, 0x09, 0xC0, 0xF3,
);
/* Signing parameters */
let signProperties = new Array();
signProperties[0] = {
tag: huks.HuksTag.HUKS_TAG_ALGORITHM,
value: huks.HuksKeyAlg.HUKS_ALG_RSA,
}
signProperties[1] = {
tag: huks.HuksTag.HUKS_TAG_PURPOSE,
value:
huks.HuksKeyPurpose.HUKS_KEY_PURPOSE_SIGN
}
signProperties[2] = {
tag: huks.HuksTag.HUKS_TAG_KEY_SIZE,
value: huks.HuksKeySize.HUKS_RSA_KEY_SIZE_2048,
}
signProperties[3] = {
tag: huks.HuksTag.HUKS_TAG_DIGEST,
value: huks.HuksKeyDigest.HUKS_DIGEST_NONE, // Set digest-none.
}
let signOptions = {
properties: signProperties,
inData: inDataAfterSha256 // Set the value after hashing.
}
huks.initSession(keyAlias, signOptions);
```
For sample codes of other APIs, see [HUKS guidelines](../../../application-dev/security/huks-guidelines.md) and [HUKS APIs](../../../application-dev/reference/apis/js-apis-huks.md).
## cl.security.22 Support of Key Calculation Parameter Specification for HUKS During Key Usage
Before the change, all parameters for key calculation must be specified when the application generates a key. After the change, only mandatory parameters need to be specified when the application generates a key, and other parameters can be specified when the key is used. The application can specify key calculation parameters more flexibly.
**Change Impacts**
Behavior of released JavaScript APIs will be changed.
The application can specify only mandatory parameters when creating a key and specify other optional parameters when using the key.
**Key API/Component Changes**
Released JavaScript APIs remain unchanged, but parameter sets passed to the APIs are changed and parameters are classified into mandatory parameters and optional parameters. For details, see [HUKS guidelines](../../../application-dev/security/huks-guidelines.md).
huks.generateKeyItem
huks.importKeyItem
huks.importWrappedKeyItem
huks.initSession
huks.updateSession
huks.finishSession
**Adaptation Guide**
Take key generation as an example. The sample code is as follows:
```js
let keyAlias = 'keyAlias';
let properties = new Array();
// Mandatory parameter.
properties[0] = {
tag: huks.HuksTag.HUKS_TAG_ALGORITHM,
value: huks.HuksKeyAlg.HUKS_ALG_RSA
};
// Mandatory parameter.
properties[1] = {
tag: huks.HuksTag.HUKS_TAG_KEY_SIZE,
value: huks.HuksKeySize.HUKS_RSA_KEY_SIZE_2048
};
// Mandatory parameter.
properties[2] = {
tag: huks.HuksTag.HUKS_TAG_PURPOSE,
value:
huks.HuksKeyPurpose.HUKS_KEY_PURPOSE_SIGN |
huks.HuksKeyPurpose.HUKS_KEY_PURPOSE_VERIFY
};
// Optional parameter. If this parameter is not specified when a key is generated, it must be specified when the key is used.
properties[3] = {
tag: huks.HuksTag.HUKS_TAG_DIGEST,
value: huks.HuksKeyDigest.HUKS_DIGEST_SHA256
};
let options = {
properties: properties
};
try {
huks.generateKeyItem(keyAlias, options, function (error, data) {
if (error) {
console.error(`callback: generateKeyItem failed, code: ${error.code}, msg: ${error.message}`);
} else {
console.info(`callback: generateKeyItem key success`);
}
});
} catch (error) {
console.error(`callback: generateKeyItem input arg invalid, code: ${error.code}, msg: ${error.message}`);
}
```
For sample codes of other APIs, see [HUKS guidelines](../../../application-dev/security/huks-guidelines.md) and [HUKS APIs](../../../application-dev/reference/apis/js-apis-huks.md).
# Ability Subsystem Changelog
Compared with OpenHarmony 3.2 Beta4, OpenHarmony 3.2.10.1(MR) has the following API changes in the ability subsystem:
## cl.ability.1 API Migration
The **requestPermissionsFromUser** API of **UIAbilityContext** is migrated from the ability subsystem to the security subsystem.
Previously, the permission popup was implemented based on **UIAbility**, which used the **startAbilityForResult** API of **UIAbilityContext** to return the permission authorization result to the caller. Therefore, **requestPermissionsFromUser** was temporarily placed in **UIAbilityContext**. The permission popup is now implemented based on **ServiceExtensionAbility**, which no longer requires **startAbilityForResult** of **UIAbilityContext**. Therefore, **requestPermissionsFromUser** is migrated to the security subsystem.
You need to adapt your application.
**Change Impact**
JS APIs in API version 9 are affected. Your application needs to adapt these APIs so that it can properly implement features in the SDK environment of the new version.
**Key API/Component Changes**
| Module | Class | Method/Attribute/Enum/Constant | Change Type|
| ------------------------- | ------------------- | ------------------------------------------------------------ | -------- |
| application/UIAbilityContext | UIAbilityContext | requestPermissionsFromUser(permissions: Array<string>, requestCallback: AsyncCallback<PermissionRequestResult>): void; | Deleted |
| application/UIAbilityContext | UIAbilityContext | requestPermissionsFromUser(permissions: Array<string>): Promise<PermissionRequestResult>; | Deleted |
| @ohos.abilityAccessCtrl | AtManager | requestPermissionsFromUser(context: Context, permissions: Array<Permissions>, requestCallback: AsyncCallback<PermissionRequestResult>) : void; | Added |
| @ohos.abilityAccessCtrl | AtManager | requestPermissionsFromUser(context: Context, permissions: Array<Permissions>) : Promise<PermissionRequestResult>; | Added |
**Adaptation Guide**
The following illustrates how **requestPermissionsFromUser** is called to show a permission popup.
Stage model:
```ts
import abilityAccessCtrl from '@ohos.abilityAccessCtrl.d.ts';
// onWindowStageCreate lifecycle of UIAbility.
onWindowStageCreate() {
let AtManager = abilityAccessCtrl.createAtManager();
// requestPermissionsFromUser determines whether to display a popup based on the permission authorization status.
AtManager.requestPermissionsFromUser(this.context, ["ohos.permission.MANAGE_DISPOSED_APP_STATUS"]).then((data) => {
console.log("data type:" + typeof(data));
console.log("data:" + data);
console.log("data permissions:" + data.permissions);
console.log("data result:" + data.authResults);
}).catch((err) => {
console.error('Failed to start ability', err.code);
})
}
```
## cl.ability.2 Deletion of Deprecated APIs in API Version 9
In the [Ability Exception Rectification](../OpenHarmony_3.2.8.3/changelogs-ability.md) document, some APIs in API version 9 have been marked as deprecated. According to API specifications of OpenHarmony, these APIs should be deleted.
**Change Impact**
The application developed based on earlier versions needs to use new APIs to replace the deleted ones. Otherwise, the application compilation will be affected.
**Key API/Component Changes**
API files are deleted.
| Deleted API | New API |
| ----------------------------------------------- | ----------------------------------------------- |
| @ohos.application.Ability.d.ts | @ohos.app.ability.UIAbility.d.ts |
| @ohos.application.AbilityConstant.d.ts | @ohos.app.ability.AbilityConstant.d.ts |
| @ohos.application.AbilityLifecycleCallback.d.ts | @ohos.app.ability.AbilityLifecycleCallback.d.ts |
| @ohos.application.AbilityStage.d.ts | @ohos.app.ability.AbilityStage.d.ts |
| @ohos.application.EnvironmentCallback.d.ts | @ohos.app.ability.EnvironmentCallback.d.ts |
| @ohos.application.ExtensionAbility.d.ts | @ohos.app.ability.ExtensionAbility.d.ts |
| @ohos.application.FormExtension.d.ts | @ohos.app.form.FormExtensionAbility.d.ts |
| @ohos.application.ServiceExtensionAbility.d.ts | @ohos.app.ability.ServiceExtensionAbility.d.ts |
| @ohos.application.StartOptions.d.ts | @ohos.app.ability.StartOptions.d.ts |
| @ohos.application.context.d.ts | @ohos.app.ability.common.d.ts |
| @ohos.application.errorManager.d.ts | @ohos.app.ability.errorManager.d.ts |
APIs or attributes are deleted:
- @ohos.application.Configuration.d.ts
- **direction**, **screenDensity**, **displayId**, and **hasPointerDevice** of **Configuration** are deleted. Use **Configuration** of **@ohos.app.ability.Configuration.d.ts**.
- @ohos.application.ConfigurationConstant.d.ts
- **Direction** and **ScreenDensity** are deleted. Use **Direction** and **ScreenDensity** of **@ohos.app.ability.ConfigurationConstant.d.ts**.
- @ohos.application.abilityManager.d.ts
- **getExtensionRunningInfos** and **getTopAbility** are deleted. Use the APIs with the same name in **@ohos.app.ability.abilityManager.d.ts**.
- @ohos.application.appManager.d.ts
- **ApplicationState** and **ProcessState** are deleted. Use **ApplicationState** and **ProcessState** of **@ohos.app.ability.appManager.d.ts**.
- **registerApplicationStateObserver** and **getProcessRunningInformation** are deleted. Use the APIs with the same name in **@ohos.app.ability.appManager.d.ts**.
- @ohos.application.formHost.d.ts
- **shareForm** and **notifyFormsPrivacyProtected** are deleted. Use the APIs with the same name in **@ohos.app.form.formHost.d.ts**.
- @ohos.application.formInfo.d.ts
- **eTS** of **FormType** is deleted. Use **eTS** of **FormType** in **@ohos.app.form.formInfo.d.ts**.
- **IDENTITY_KEY**, **BUNDLE_NAME_KEY**, **ABILITY_NAME_KEY**, and **DEVICE_ID_KEY** of **FormParam** are deleted. Use the enums with the same name in **@ohos.app.form.formInfo.d.ts**.
- **FormInfoFilter** is deleted. Use **FormInfoFilter** of **@ohos.app.form.formInfo.d.ts**.
- **FormDimension** is deleted. Use **FormDimension** of **@ohos.app.form.formInfo.d.ts**.
- **VisibilityType** is deleted. Use **VisibilityType** of **@ohos.app.form.formInfo.d.ts**.
- @ohos.wantAgent.d.ts
- **trigger** and **getOperationType** are deleted. Use the APIs with the same name in **@ohos.app.ability.wantAgent.d.ts**.
- application/ApplicationContext.d.ts
- **registerAbilityLifecycleCallback**, **unregisterAbilityLifecycleCallback**, **registerEnvironmentCallback**, and **unregisterEnvironmentCallback** are deleted. Use **on** and **off**.
- application/ServiceExtensionContext.d.ts
- **connectAbility**, **connectAbilityWithAccount**, and **disconnectAbility** are deleted. Use **connectServiceExtensionAbility**, **connectServiceExtensionAbilityWithAccount**, and **disconnectServiceExtensionAbility**.
- @ohos.application.FormExtension.d.ts
- **onCreate**, **onCastToNormal**, **onUpdate**, **onVisibilityChange**, **onEvent**, **onDestroy**, **onAcquireFormState**, and **onShare** are deleted. Use the following lifecycle methods of **@ohos.app.form.FormExtensionAbility.d.ts**: **onAddForm**, **onCastToNormalForm**, **onUpdateForm**, **onChangeFormVisibility**, **onFormEvent**, **onRemoveForm**, **onAcquireFormState**, and **onShareForm**.
- @ohos.application.abilityDelegatorRegistry.d.ts
- **AbilityDelegator**, **AbilityDelegatorArgs**, **AbilityMonitor**, and **ShellCmdResult** are deleted. Use the classes with the same name in **@ohos.app.ability.abilityDelegatorRegistry.d.ts**.
- @ohos.application.abilityManager.d.ts
- **AbilityRunningInfo** and **ExtensionRunningInfo** are deleted. Use the classes with the same name in **@ohos.app.ability.abilityManager.d.ts**.
- @ohos.application.appManager.d.ts
- **AbilityStateData**, **AppStateData**, **ApplicationStateObserver**, **ProcessRunningInfo**, and **ProcessRunningInformation** are deleted. Use the classes with the same name in **@ohos.app.ability.appManager.d.ts**.
- @ohos.application.missionManager.d.ts
- **MissionInfo**, **MissionListener**, and **MissionSnapshot** are deleted. Use the classes with the same name in **@ohos.app.ability.missionManager.d.ts**.
- @ohos.wantAgent.d.ts
- **TriggerInfo** and **WantAgentInfo** are deleted. Use the classes with the same name in **@ohos.app.ability.wantAgent.d.ts**.
**Adaptation Guide**
As mentioned above, only several APIs have their names changed in terms of, for example, the registration callbacks (**registerAbilityLifecycleCallback**, **unregisterAbilityLifecycleCallback**, **registerEnvironmentCallback**, and **unregisterEnvironmentCallback**) and connection and disconnection **ServiceExtensionAbility** (**connectAbility**, **connectAbilityWithAccount**, and **disconnectAbility**). For such APIs, replace their names with those of their corresponding new APIs in the lifecycle callbacks.
Most APIs are moved to the new namespace. Therefore, you can modify **import** for adaptation.
For example, the original API uses **@ohos.application.Ability**:
```js
import Ability from '@ohos.application.Ability';
```
You can directly modify **import** to switch to the new namespace:
```js
import Ability from '@ohos.app.ability.UIAbility';
```
In addition, exception handling is needed. For details, see the API reference for the new APIs.
# ChangeLog of JS API Changes in the commonlibrary Subsystem
Compared with OpenHarmony 3.2 Beta4, OpenHarmony 3.2.10.1(Mr) has the following API changes in the commonlibrary subsystem.
## cl.commonlibrary.1 Error Code and Information Change
Changed error codes and information returned by APIs of the **ArrayList**, **List**, **LinkedList**, **Stack**, **Queue**, **Deque**, **PlainArray**, **LightWeightMap**, **LightWeightSet**, **HashMap**, **HashSet**, **TreeMap**, and **TreeSet** classes in the commonlibrary subsystem.
For details about the changed error codes, see [error codes of language basic class libraries](../../../application-dev/reference/errorcodes/errorcode-utils.md).
No adaptation is required for applications developed using these APIs.
**Key API/Component Changes**
Error code information is redefined for APIs in these classes and marked using **'@throws'** in the `*.d.ts` file of the corresponding module.
The sample code is as follows:
**ArrayList** class before the change:
constructor();
**ArrayList** class after the change:
@throws { BusinessError } 10200012 - The ArrayList's constructor cannot be directly invoked.
constructor();
**Change Impacts**
None
# ChangeLog of JS API Changes of the Distributed Data Management Subsystem
Compared with OpenHarmony 3.2 Beta4, OpenHarmony 3.2.10.1(Mr) has the following API changes in the distributed data management subsystem:
## cl.distributeddatamgr.1 API Change
APIs in the **kv_store** component of the distributed data management subsystem are changed:
**createKVManager** is changed from asynchronous to synchronous, because the execution duration is fixed and short and there is no need to asynchronously wait for the execution result. Therefore, the original APIs **function createKVManager(config: KVManagerConfig): Promise\<KVManager\>;** and **function createKVManager(config: KVManagerConfig, callback: AsyncCallback<KVManager>): void;** are changed to **function createKVManager(config: KVManagerConfig): KVManager;**.
You need to adapt your applications based on the following information:
**Change Impacts**
JS APIs in API version 9 are affected. The application needs to adapt these APIs so that it can properly implement functions in the SDK environment of the new version.
**Key API/Component Changes**
| Module | Class | Method/Attribute/Enumeration/Constant | Change Type|
| ------------------------ | ------------------ | ------------------------------------------------------------ | -------- |
| @ohos.distributedKVStore | distributedKVStore | function createKVManager(config: KVManagerConfig): Promise\<KVManager\>; | Deleted |
| @ohos.distributedKVStore | distributedKVStore | function createKVManager(config: KVManagerConfig): KVManager; | Changed |
**Adaptation Guide**
The following illustrates how to call **createKVManager** to create a **KVManager** object.
Stage model:
```ts
import AbilityStage from '@ohos.application.Ability'
let kvManager;
export default class MyAbilityStage extends AbilityStage {
onCreate() {
console.log("MyAbilityStage onCreate")
let context = this.context
const kvManagerConfig = {
context: context,
bundleName: 'com.example.datamanagertest',
}
try {
kvManager = distributedKVStore.createKVManager(kvManagerConfig);
} catch (e) {
console.error(`Failed to create KVManager.code is ${e.code},message is ${e.message}`);
}
}
}
```
FA model:
```ts
import featureAbility from '@ohos.ability.featureAbility'
let kvManager;
let context = featureAbility.getContext()
const kvManagerConfig = {
context: context,
bundleName: 'com.example.datamanagertest',
}
try {
kvManager = distributedKVStore.createKVManager(kvManagerConfig);
} catch (e) {
console.error(`Failed to create KVManager.code is ${e.code},message is ${e.message}`);
}
```
## cl.distributeddatamgr.2 Migration of function getRdbStoreV9 from @ohos.data.rdb.d.ts to @ohos.data.relationalStore.d.ts.
**Change Impacts**
The application needs to adapt these APIs so that it can be properly compiled in the SDK environment of the new version.
**Key API/Component Changes**
APIs:
```ts
function getRdbStoreV9(context: Context, config: StoreConfigV9, version: number, callback: AsyncCallback<RdbStoreV9>): void;
function getRdbStoreV9(context: Context, config: StoreConfigV9, version: number): Promise<RdbStoreV9>;
```
The APIs are migrated from **@ohos.data.rdb.d.ts** to **@ohos.data.relationalStore.d.ts**.
```
function getRdbStore(context: Context, config: StoreConfig, callback: AsyncCallback<RdbStore>): void;
function getRdbStore(context: Context, config: StoreConfig): Promise<RdbStore>;
```
**Adaptation Guide**
* `import rdb from "@ohos.data.rdb"` is changed to `import rdb from "@ohos.data.relationalStore"`.
* The names of relevant methods should be changed according to the preceding changes.
## cl.distributeddatamgr.3 Migration of function deleteRdbStoreV9 from @ohos.data.rdb.d.ts to @ohos.data.relationalStore.d.ts
**Change Impacts**
The application needs to adapt these APIs so that it can be properly compiled in the SDK environment of the new version.
**Key API/Component Changes**
APIs:
```ts
function deleteRdbStoreV9(context: Context, name: string, callback: AsyncCallback<void>): void;
function deleteRdbStoreV9(context: Context, name: string): Promise<void>;
```
The APIs are migrated from **@ohos.data.rdb.d.ts** to **@ohos.data.relationalStore.d.ts**.
```
function deleteRdbStoreV9(context: Context, name: string, callback: AsyncCallback<void>): void;
function deleteRdbStoreV9(context: Context, name: string): Promise<void>;
```
**Adaptation Guide**
* `import rdb from "@ohos.data.rdb"` is changed to `import rdb from "@ohos.data.relationalStore"`.
* The names of relevant methods should be changed according to the preceding changes.
## cl.distributeddatamgr.4 Migration of interface StoreConfigV9 from @ohos.data.rdb.d.ts to @ohos.data.relationalStore.d.ts
**Change Impacts**
The application needs to adapt these APIs so that it can be properly compiled in the SDK environment of the new version.
**Key API/Component Changes**
**interface StoreConfigV9** is migrated from **@ohos.data.rdb.d.ts** to **@ohos.data.relationalStore.d.ts** and is renamed as **interface StoreConfig**.
**Adaptation Guide**
* `import rdb from "@ohos.data.rdb"` is changed to `import rdb from "@ohos.data.relationalStore"`.
* The names of relevant APIs should be changed according to the preceding changes.
## cl.distributeddatamgr.5 Migration of enum SecurityLevel from @ohos.data.rdb.d.ts to @ohos.data.relationalStore.d.ts
**Change Impacts**
The application needs to adapt these APIs so that it can be properly compiled in the SDK environment of the new version.
**Key API/Component Changes**
**enum SecurityLevel** is migrated from **ohos.data.rdb.d.ts** to **@ohos.data.relationalStore.d.ts**.
**Adaptation Guide**
* `import rdb from "@ohos.data.rdb"` is changed to `import rdb from "@ohos.data.relationalStore"`.
* The names of relevant APIs should be changed according to the preceding changes.
## cl.distributeddatamgr.6 Migration of interface RdbStoreV9 from @ohos.data.rdb.d.ts to @ohos.data.relationalStore.d.ts
**Change Impacts**
The application needs to adapt these APIs so that it can be properly compiled in the SDK environment of the new version.
**Key API/Component Changes**
**interface RdbStoreV9** is migrated from **@ohos.data.rdb.d.ts** to **@ohos.data.relationalStore.d.ts** and is renamed as **interface RdbStore**.
**Adaptation Guide**
* `import rdb from "@ohos.data.rdb"` is changed to `import rdb from "@ohos.data.relationalStore"`.
* The names of relevant APIs should be changed according to the preceding changes.
## cl.distributeddatamgr.7 Migration of class RdbPredicatesV9 from ohos.data.rdb.d.ts to @ohos.data.relationalStore.d.ts
**Change Impacts**
The application needs to adapt these APIs so that it can be properly compiled in the SDK environment of the new version.
**Key API/Component Changes**
**class RdbPredicatesV9** is migrated from **ohos.data.rdb.d.ts** to **@ohos.data.relationalStore.d.ts** and is renamed as **interface RdbPredicates**.
**Adaptation Guide**
* `import rdb from "@ohos.data.rdb"` is changed to `import rdb from "@ohos.data.relationalStore"`.
* The names of relevant APIs should be changed according to the preceding changes.
## cl.distributeddatamgr.8 Migration of interface ResultSetV9 from api/@ohos.data.relationalStore.d.ts to @ohos.data.relationalStore.d.ts
**Change Impacts**
The application needs to adapt these APIs so that it can be properly compiled in the SDK environment of the new version.
**Key API/Component Changes**
**interface ResultSetV9** is migrated from **api/data/rdb/resultSet.d.ts** to **@ohos.data.relationalStore.d.ts** and is renamed as **interface ResultSet**.
**Adaptation Guide**
* `import rdb from "@ohos.data.rdb"` is changed to `import rdb from "@ohos.data.relationalStore"`.
* The **ResultSetV9** instance is obtained only via **getRdbStoreV9**. After modifications are made according to cl.distributeddatamgr.2, the code can automatically adapt to **ResultSet**.
## cl.multimedia.av_session.001 Change of All av_session APIs to System APIs
All av_session APIs are changed to system APIs.
**Change Impacts**
Non-system applications and applications without system API permission cannot call system APIs.
**Key API/Component Changes**
All APIs are changed to system APIs. The table below describes the APIs.
| API, Enumeration, or Variable| Type| Is System API|
| -------- | -------- | ------- |
| SessionToken | interface | Yes|
| AVMetadata | interface | Yes|
| AVPlaybackState | interface | Yes|
| PlaybackPosition | interface | Yes|
| OutputDeviceInfo | interface | Yes|
| AVSessionDescriptor | interface | Yes|
| AVSessionController | interface | Yes|
| AVControlCommand | interface | Yes|
| createAVSession | function | Yes|
| getAllSessionDescriptors | function | Yes|
| createController | function | Yes|
| castAudio | function | Yes|
| on | function | Yes|
| off | function | Yes|
| sendSystemAVKeyEvent | function | Yes|
| sendSystemControlCommand | function | Yes|
| sessionId | variable | Yes|
| setAVMetadata | function | Yes|
| setAVPlaybackState | function | Yes|
| setLaunchAbility | function | Yes|
| getController | function | Yes|
| getOutputDevice | function | Yes|
| activate | function | Yes|
| deactivate | function | Yes|
| destroy | function | Yes|
| getAVPlaybackState | function | Yes|
| getAVMetadata | function | Yes|
| getOutputDevice | function | Yes|
| sendAVKeyEvent | function | Yes|
| getLaunchAbility | function | Yes|
| getRealPlaybackPositionSync | function | Yes|
| isActive | function | Yes|
| getValidCommands | function | Yes|
| sendControlCommand | function | Yes|
| AVSessionType | type | Yes|
| AVControlCommandType | type | Yes|
| LoopMode | enum | Yes|
| PlaybackState | enum | Yes|
| AVSessionErrorCode | enum | Yes|
# Common Event and Notification Subsystem ChangeLog
## cl.notification.1 Deleting Deprecated APIs (Version 9)
In the [event notification exception handling rectification](../OpenHarmony_3.2.8.3/changelogs-notification.md), some APIs in API version 9 are marked as deprecated, and these APIs need to be deleted, according to OpenHarmony API specifications.
**Change Impacts**
The application developed based on earlier versions needs to use new APIs to replace the deleted ones. Otherwise, the application compilation will be affected.
**Key API/Component Changes**
Deprecated APIs in API version 9 will be deleted, and they will be replaced with new ones with same names.
| Original API | New API |
| ----------------------- | -------------------------------- |
| @ohos.commonEvent.d.ts | @ohos.commonEventManager.d.ts |
| @ohos.notification.d.ts | @ohos.notificationManager.d.ts |
| @ohos.notification.d.ts | @ohos.notificationSubscribe.d.ts |
APIs or attributes are deleted:
- @ohos.notification.d.ts
- The **publishAsBundle**, **cancelAsBundle**, **isNotificationSlotEnabled**, **setSyncNotificationEnabledWithoutApp**, and **getSyncNotificationEnabledWithoutApp** APIs are deleted. Replace them with APIs with same names in **api/@ohos.notificationManager.d.ts**.
- The **enableNotificationSlot** API is deleted. Replace it with **setNotificationEnableSlot** in **api/@ohos.notificationManager.d.ts**.
- The export classes **NotificationActionButton**, **NotificationBasicContent**, **NotificationContent**, **NotificationLongTextContent**, **NotificationMultiLineContent**, **NotificationPictureContent**, **NotificationFlags**, **NotificationFlagStatus**, **NotificationRequest**, **DistributedOptions**, **NotificationSlot**, **NotificationSorting**, **NotificationTemplate**, and **NotificationUserInput** are deleted. Replace them with the export classes with the same names in **api/@ohos.notificationManager.d.ts**.
- The export classes **NotificationSubscribeInfo**, **NotificationSubscriber**, **SubscribeCallbackData**, and **EnabledNotificationCallbackData** are deleted. Replace them with the export classes with the same names in **api/@ohos.notificationSubscribe.d.ts**.
**Adaptation Guide**
The original APIs are only migrated to the new namespace. Therefore, you can modify **import** to solve the adaptation problem.
If the original API uses **@ohos.commonEvent**:
```js
import commonEvent from '@ohos.commonEvent';
```
You can directly modify **import** to switch to the new namespace:
```js
import commonEvent from '@ohos.commonEventManager';
```
**@ohos.notification** is split into two namespaces. You need to select a new namespace for adaptation.
In addition, exception handling is needed. For details, see the API reference for the new APIs.
# Time Subsystem ChangeLog
## cl.time.1 API Error Change
Errors thrown by timer APIs of the time subsystem: **202** (non-system application) and **401** (invalid parameters).
**Change Impacts**
The API change is forward compatible. Applications developed based on earlier versions can still use the APIs, and corresponding error handling is added. The original functions are not affected.
**Key API/Component Changes**
Before change:
- The API throws an error message without an error code.
After change:
- The API throws an error message with an error code. Error code **202** indicates that the application is not a system application, and error code **401** indicates that the parameters are invalid.
| Module | Class | Method/Attribute/Enumeration/Constant | Change Type|
| ----------------- | ----------- | ------------------------------------------------------------ | -------- |
| @ohos.systemTimer | systemTimer | function createTimer(options: TimerOptions, callback: AsyncCallback\<number>): void | Changed |
| @ohos.systemTimer | systemTimer | function createTimer(options: TimerOptions): Promise\<number> | Changed |
| @ohos.systemTimer | systemTimer | function startTimer(timer: number, triggerTime: number, callback: AsyncCallback\<void>): void | Changed |
| @ohos.systemTimer | systemTimer | function startTimer(timer: number, triggerTime: number): Promise\<void> | Changed |
| @ohos.systemTimer | systemTimer | function stopTimer(timer: number, callback: AsyncCallback\<void>): void | Changed |
| @ohos.systemTimer | systemTimer | function stopTimer(timer: number): Promise\<void> | Changed |
| @ohos.systemTimer | systemTimer | function destroyTimer(timer: number, callback: AsyncCallback\<void>): void | Changed |
| @ohos.systemTimer | systemTimer | function destroyTimer(timer: number): Promise\<void> | Changed |
**Adaptation Guide**
Refer to the code below to capture errors when **systemTimer** APIs are called in applications.
createTimer callback mode:
**Example**
```js
export default {
systemTimer () {
let options = {
type: systemTimer.TIMER_TYPE_REALTIME,
repeat: false
};
try {
systemTimer.createTimer(options, (error, timerId) => {
if (error) {
// Capture the permission denial error.
console.info(`Failed to create timer. message: ${error.message}, code: ${error.code}`);
}
console.info(`Succeeded in creating timer. timerId: ${timerId}`);
});
} catch(e) {
// Capture the parameter verification error.
console.info(`Failed to create timer. message: ${e.message}, code: ${e.code}`);
}
}
}
```
createTimer promise mode:
**Example**
```js
export default {
systemTimer () {
let options = {
type: systemTimer.TIMER_TYPE_REALTIME,
repeat: false
};
try {
systemTimer.createTimer(options).then((timerId) => {
console.info(`Succeeded in creating timer. timerId: ${timerId}`);
}).catch((error) => {
// Capture the permission denial error.
console.info(`Failed to create timer. message: ${error.message}, code: ${error.code}`);
});
} catch(e) {
// Capture the parameter verification error.
console.info(`Failed to create timer. message: ${e.message}, code: ${e.code}`);
}
}
}
```
startTimer callback mode:
**Example**
```js
export default {
async systemTimer () {
let options = {
type: systemTimer.TIMER_TYPE_REALTIME,
repeat:false
}
let timerId = await systemTimer.createTimer(options);
let triggerTime = new Date().getTime();
triggerTime += 3000;
try {
systemTimer.startTimer(timerId, triggerTime, (error) => {
if (error) {
// Capture the permission denial error.
console.error(`Failed to start timer. message: ${error.message}, code: ${error.code}`);
}
});
} catch (e) {
// Capture the parameter verification error.
console.info(`Failed to start timer. message: ${e.message}, code: ${e.code}`);
}
}
}
```
startTimer promise mode:
**Example**
```js
export default {
async systemTimer (){
let options = {
type: systemTimer.TIMER_TYPE_REALTIME,
repeat:false
}
let timerId = await systemTimer.createTimer(options);
let triggerTime = new Date().getTime();
triggerTime += 3000;
try {
systemTimer.startTimer(timerId, triggerTime).then((data) => {
console.log(`Succeeded in startting timer. Data:` + data);
}).catch((error) => {
// Capture the permission denial error.
console.info(`Failed to start timer. message: ${error.message}, code: ${error.code}`);
});
} catch (e) {
// Capture the parameter verification error.
console.info(`Failed to start timer. message: ${e.message}, code: ${e.code}`);
}
}
}
```
stopTimer callback mode:
**Example**
```js
export default {
async systemTimer () {
let options = {
type: systemTimer.TIMER_TYPE_REALTIME,
repeat:false
}
let timerId = await systemTimer.createTimer(options);
let triggerTime = new Date().getTime();
triggerTime += 3000;
systemTimer.startTimer(timerId, triggerTime);
try {
systemTimer.stopTimer(timerId, triggerTime, (error) => {
if (error) {
// Capture the permission denial error.
console.error(`Failed to stop timer. message: ${error.message}, code: ${error.code}`);
}
});
} catch (e) {
// Capture the parameter verification error.
console.info(`Failed to stop timer. message: ${e.message}, code: ${e.code}`);
}
}
}git
```
stopTimer promise mode:
**Example**
```js
export default {
async systemTimer (){
let options = {
type: systemTimer.TIMER_TYPE_REALTIME,
repeat:false
}
let timerId = await systemTimer.createTimer(options);
let triggerTime = new Date().getTime();
triggerTime += 3000;
systemTimer.startTimer(timerId, triggerTime);
try {
systemTimer.stopTimer(timerId, triggerTime).then((data) => {
console.log(`Succeeded in stop timer. Data:` + data);
}).catch((error) => {
// Capture the permission denial error.
console.info(`Failed to stop timer. message: ${error.message}, code: ${error.code}`);
});
} catch (e) {
// Capture the parameter verification error.
console.info(`Failed to stop timer. message: ${e.message}, code: ${e.code}`);
}
}
}
```
destroyTimer callback mode:
**Example**
```js
export default {
async systemTimer () {
let options = {
type: systemTimer.TIMER_TYPE_REALTIME,
repeat:false
}
let timerId = await systemTimer.createTimer(options);
let triggerTime = new Date().getTime();
triggerTime += 3000;
systemTimer.startTimer(timerId, triggerTime);
systemTimer.stopTimer(timerId);
try {
systemTimer.destroyTimer(timerId, triggerTime, (error) => {
if (error) {
// Capture the permission denial error.
console.error(`Failed to destroy timer. message: ${error.message}, code: ${error.code}`);
}
});
} catch (e) {
// Capture the parameter verification error.
console.info(`Failed to destroy timer. message: ${e.message}, code: ${e.code}`);
}
}
}
```
destroyTimer promise mode:
**Example**
```js
export default {
async systemTimer (){
let options = {
type: systemTimer.TIMER_TYPE_REALTIME,
repeat:false
}
let timerId = await systemTimer.createTimer(options);
let triggerTime = new Date().getTime();
triggerTime += 3000;
systemTimer.startTimer(timerId, triggerTime);
systemTimer.stopTimer(timerId);
try {
systemTimer.destroyTimer(timerId, triggerTime).then((data) => {
console.log(`Succeeded in destroy timer. Data:` + data);
}).catch((error) => {
// Capture the permission denial error.
console.info(`Failed to destroy timer. message: ${error.message}, code: ${error.code}`);
});
} catch (e) {
// Capture the parameter verification error.
console.info(`Failed to destroy timer. message: ${e.message}, code: ${e.code}`);
}
}
}
```
## cl.time.2 API Error Change
Errors thrown by timer APIs of the time subsystem: **201** (permission denied), **202** (non-system application), and **401** (invalid parameters).
**Change Impacts**
Applications developed based on earlier versions can still use the APIs. When new APIs are used, errors must be captured and processed.
**Key API/Component Changes**
Before change:
- The API throws an error message with error code **-1**.
After change:
- The API throws an error message with an error code. Error code **201** indicates that the permission is denied, error code **202** indicates that the application is not a system application, and error code **401** indicates that the parameters are invalid.
Deprecated APIs can be replaced with new ones with same names.
| Original API | New API |
| ---------------- | -------------------- |
| @ohos.systemTime | @ohos.systemDateTime |
**Adaptation Guide**
Refer to the code below to capture errors when **systemTime** APIs are called in applications. In the examples, the **setTime** API is invoked.
In callback mode:
**Example**
```js
import systemDateTime from @ohos.systemDateTime
// Set the system time to 2021-01-20 02:36:25.
let time = 1611081385000;
try {
systemDateTime.setTime(time, (error) => {
// Capture permission denial and non-system-application errors.
if (error) {
console.info(`Failed to setting time. message: ${error.message}, code: ${error.code}`);
return;
}
console.info(`Succeeded in setting time.`);
})
} catch(e) {
// Capture the parameter verification error.
console.info(`Failed to set time. message: ${e.message}, code: ${e.code}`);
}
```
In promise mode:
**Example**
```js
import systemDateTime from @ohos.systemDateTime
// Set the system time to 2021-01-20 02:36:25.
let time = 1611081385000;
try {
systemDateTime.setTime(time).then(() => {
console.info(`Succeeded in setting time.`);
}).catch((error) => {
// Capture permission denial and non-system-application errors.
console.info(`Failed to setting time. message: ${error.message}, code: ${error.code}`);
});
} catch(e) {
// Capture the parameter verification error.
console.info(`Failed to set time. message: ${e.message}, code: ${e.code}`);
}
```
# Common Library Subsystem Changelog
Compared with OpenHarmony 3.2 Beta4, OpenHarmony 3.2.10.1(MR) has the following API changes in the URL module of the common library subsystem.
## cl.commonlibrary.1 URLParams Class Changes
The constructor function of the **URLParams** class in the URL module of the common library subsystem is changed.
Specifically, **constructor(init?: string[][] | Record<string, string> | string | URLSearchParams)** is changed to **constructor(init?: string[][] | Record<string, string> | string | URLParams)**, and the parameter type is changed from **URLSearchParams** to **URLParams**.
You need to adapt your application.
**Change Impacts**
JS APIs in API version 9 are affected. Your application needs to adapt these APIs so that it can properly implement features in the SDK environment of the new version.
**Key API/Component Changes**
| Module | Class | Method/Attribute/Enum/Constant | Change Type|
| :------------------------ | ------------------- | ------------------------------------------------------------ | -------- |
| @ohos.url | URLParams | constructor(string[][] \| Record&lt;string, string&gt; \| string \| URLSearchParams) | Deleted |
| @ohos.url | URLParams | constructor(string[][] \| Record&lt;string, string&gt; \| string \| URLParams)| Changed
**Adaptation Guide**
The following illustrates how to create a **URLParams** object in your application.
Example:
```ts
import url from '@ohos.url'
try {
let params1 = new Url.URLParams('?user=abc&query=xyz')
let params2 = new Url.URLParams(params1)
var result= params2.toString()
console.log(result) //"user=abc&query=xyz"
} catch (err) {
console.error(`Fail to ceate URLParams.codeis${err.code},message is ${err.message}`);
}
```
## cl.commonlibrary.2 URL Attribute Changes of URLParams Class APIs
The URL attributes of the URL module in the common library subsystem are changed.
Specifically, the **searchParams: URLSearchParams** attribute is deprecated, and the **params: URLParams** attribute is added.
You need to adapt your application.
**Change Impacts**
JS APIs in API version 9 are affected. Your application needs to adapt these APIs so that it can properly implement features in the SDK environment of the new version.
**Key API/Component Changes**
| Module | Class | Method/Attribute/Enum/Constant | Change Type|
| :------------------------ | ------------------- | ------------------------------------------------------------ | -------- |
| @ohos.url | URL | searchParams: URLSearchParams; |Deprecated (in API version 9)<br> |
| @ohos.url | URL | params: URLParams; | Added |
**Adaptation Guide**
The following illustrates how to create a **URLParams** object in your application.
Example:
```ts
import url from '@ohos.url'
let that = new Url.URL('http://username:password@host:8080/directory/file?Hello=china#qwer=da')
let params = that.URLParams
var result = params.toString()
console.log(result) //%E4%BD%A0%E5%A5%BD=china
```
# Bundle Manager Subsystem Changelog
## cl.bundlemanager.1 Deleted the atomicService Tag from the app.json File
The **atomicService** tag is deleted from the **app.json** file.
**Change Impact**<br>
If this tag is used, an error is reported during compilation on DevEco Studio.
**Adaptation Guide**<br>
Delete the **atomicService** tag from your code.
## cl.bundlemanager.2 Added the bundleType Tag to the app.json File
The **bundleType** tag is added to the **app.json** file.
**Change Impact**<br>
For an existing ability with [installationFree](../../../application-dev/quick-start/module-configuration-file.md) set to **true**, **bundleType** must be set to **atomicService** in the **app.json** file. Otherwise, the packaging fails.
**Adaptation Guide**<br>
Add the [bundleType](../../../application-dev/quick-start/app-configuration-file.md) tag. This tag can be left blank. The default value is **app**. The setting of this tag and the [installationFree](../../../application-dev/quick-start/module-configuration-file.md) field in the **module.json** file must meet the following rules:
- If **bundleType** is **app**, **installationFree** must be set to **false**.
- If **bundleType** is **atomicService**, **installationFree** must be set to **true**.
## cl.bundlemanager.3 Deleted the split Field from the ApplicationInfo Struct
The **split** field is deleted from the [ApplicationInfo](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/ApplicationInfo.d.ts) struct.
**Change Impact**<br>
If the **split** field is used in your code, the compilation fails.
**Key API/Component Changes**<br>
The **split** field is deleted from the [ApplicationInfo](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/ApplicationInfo.d.ts) struct.
**Adaptation Guide**<br>
Delete the **split** field from the **ApplicationInfo** struct of your code. The stage model always forcibly splits bundles.
## cl.bundlemanager.4 Deleted the atomicServiceModuleType Field from the HapModuleInfo Struct
The **atomicServiceModuleType** field is deleted from the [HapModuleInfo](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/HapModuleInfo.d.ts) struct.
**Change Impact**<br>
If the **atomicServiceModuleType** field is used in your code, the compilation fails.
**Key API/Component Changes**<br>
The **atomicServiceModuleType** field is deleted from the [HapModuleInfo](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/HapModuleInfo.d.ts) struct.
**Adaptation Guide**<br>
Record the setting of the **atomicServiceModuleType** field, delete it from the [HapModuleInfo](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/HapModuleInfo.d.ts) struct, and set the **moduleType** field in the [HapModuleInfo](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/HapModuleInfo.d.ts) struct to the recorded value.
## cl.bundlemanager.5 Deleted the AtomicServiceModuleType Enumerated Value
The **atomicServiceModuleType** field is deleted from the [HapModuleInfo](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/HapModuleInfo.d.ts) struct.
**Change Impact**<br>
If the **atomicServiceModuleType** field is used in your code, the compilation fails.
**Key API/Component Changes**<br>
The **atomicServiceModuleType** field is deleted from the [HapModuleInfo](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/HapModuleInfo.d.ts) struct.
**Adaptation Guide**<br>
Record the setting of the **atomicServiceModuleType** field, delete it from the [HapModuleInfo](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/HapModuleInfo.d.ts) struct, and set the **moduleType** field in the [HapModuleInfo](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/HapModuleInfo.d.ts) struct to the recorded value.
# Input Method Framework Subsystem – Input Method Framework Service Changelog
## @ohos.InputMethodSubtype Change of name, label, and id
Changed the **name**, **label**, and **id** attributes since API version 9.
**Change Impact**
Applications must be adapted to the following changes.
| Name| Before Change| After Change|
| -------- | -------- | -------- |
| label | (1) Value: ID of the input method subtype.| (1) Value: Label of the input method subtype.|
| name | (1) Description: Name of the input method subtype. (2) Value: Label of the input method subtype.| (1) Description: Bundle name of the input method; (2) Value: Bundle name of the input method.|
| id | (1) Value: Bundle name of the input method.| (1) Value: ID of the input method subtype.|
**Adaptation Guide**
Update the code to adapt to the preceding changes.
# Theme Framework Subsystem – Screenlock Management Service Changelog
## cl.screenlock.1 Permission Change of isLocked and unlock
Changed the **isLocked** and **unlock** APIs to system APIs since API version 9.
You need to adapt your application based on the following information.
**Change Impact**
The JS API needs to be adapted for applications developed based on earlier versions. Otherwise, relevant functions will be affected.
- Involved APIs:
```js
function isLocked(): boolean;
function unlock(callback: AsyncCallback<boolean>): void;
function unlock():Promise<boolean>;
```
- Before change:
```js
* Checks whether the screen is currently locked.
*
* @returns Returns {@code true} if the screen is currently locked; returns {@code false} otherwise.
* @syscap SystemCapability.MiscServices.ScreenLock
* @since 9
*/
function isLocked(): boolean;
/**
* Unlock the screen.
*
* @returns Returns {@code true} if the screen is unlocked successfully; returns {@code false} otherwise.
* @throws {BusinessError} 401 - parameter error.
* @throws {BusinessError} 202 - permission verification failed, application which is not a system application uses system API.
* @throws {BusinessError} 13200002 - the screenlock management service is abnormal.
* @syscap SystemCapability.MiscServices.ScreenLock
* @systemapi Hide this for inner system use.
* @since 9
*/
function unlock(callback: AsyncCallback<boolean>): void;
/**
* Unlock the screen.
*
* @returns Returns {@code true} if the screen is unlocked successfully; returns {@code false} otherwise.
* @throws {BusinessError} 401 - parameter error.
* @throws {BusinessError} 202 - permission verification failed, application which is not a system application uses system API.
* @throws {BusinessError} 13200002 - the screenlock management service is abnormal.
* @syscap SystemCapability.MiscServices.ScreenLock
* @systemapi Hide this for inner system use.
* @since 9
*/
function unlock():Promise<boolean>;
```
- After change:
```js
* Checks whether the screen is currently locked.
*
* @returns Returns {@code true} if the screen is currently locked; returns {@code false} otherwise.
* @throws {BusinessError} 202 - permission verification failed, application which is not a system application uses system API.
* @syscap SystemCapability.MiscServices.ScreenLock
* @systemapi Hide this for inner system use.
* @since 9
*/
function isLocked(): boolean;
/**
* Unlock the screen.
*
* @returns Returns {@code true} if the screen is unlocked successfully; returns {@code false} otherwise.
* @throws {BusinessError} 401 - parameter error.
* @throws {BusinessError} 13200002 - the screenlock management service is abnormal.
* @syscap SystemCapability.MiscServices.ScreenLock
* @since 9
*/
function unlock(callback: AsyncCallback<boolean>): void;
/**
* Unlock the screen.
*
* @returns Returns {@code true} if the screen is unlocked successfully; returns {@code false} otherwise.
* @throws {BusinessError} 13200002 - the screenlock management service is abnormal.
* @syscap SystemCapability.MiscServices.ScreenLock
* @since 9
*/
function unlock():Promise<boolean>;
```
**Adaptation Guide**
Make sure the APIs are only invoked by system applications.
The code snippet is as follows:
```js
try {
let ret = screenLock.isLocked();
console.error(`Obtain whether the screen is locked successfully , ret is: ${ret}`);
} catch (error) {
console.error(`Failed to obtain whether the screen is locked, error is : ${error.code}, ${error.message}`);
}
```
```js
screenlock.unlock((err, data) => {
if (err) {
console.error(`Failed to unlock the screen, because: ${err.message}`);
return;
}
console.info(`unlock the screen successfully. result: ${data}`);
});
```
```js
screenlock.unlock().then((data) => {
console.info(`unlock the screen successfully. result: ${data}`);
}).catch((err) => {
console.error(`Failed to unlock the screen, because: ${err.message}`);
});
```
## cl.screenlock.2 Deprecation of isSecure
Deprecated the **isSecure** API since API version 9.
You need to adapt your application based on the following information.
**Change Impact**
The API can no longer be used after being deleted.
- Involved APIs:
```js
function isSecure(): boolean;
```
- Before change:
```js
function isSecure(): boolean;
```
- After change:
The API is deleted.
**Adaptation Guide**
Update the code so that the deprecated API is not used.
# Theme Framework Subsystem – Wallpaper Management Service Changelog
## cl.wallpaper.1 Permission Change of getColorsSync, getMinHeightSync, getMinWidthSync, restore, and setImage
Changed the **getColorsSync**, **getMinHeightSync**, **getMinWidthSync**, restore, and **setImage** APIs to system APIs since API version 9.
You need to adapt your application based on the following information.
**Change Impact**
The JS API needs to be adapted for applications developed based on earlier versions. Otherwise, relevant functions will be affected.
- Involved APIs:
```js
function getColorsSync(wallpaperType: WallpaperType): Array<RgbaColor>;
function getMinHeightSync(): number;
function getMinWidthSync(): number;
function restore(wallpaperType: WallpaperType, callback: AsyncCallback<void>): void;
function restore(wallpaperType: WallpaperType): Promise<void>;
function setImage(source: string | image.PixelMap, wallpaperType: WallpaperType, callback: AsyncCallback<void>): void;
function setImage(source: string | image.PixelMap, wallpaperType: WallpaperType): Promise<void>;
```
- Before change:
```js
/**
* Obtains the wallpaper colors for the wallpaper of the specified type. Returns rgbaColor type of array callback function.
* @param wallpaperType Indicates the wallpaper type.
* @returns { Array<RgbaColor> } the Array<RgbaColor> returned by the function.
* @throws {BusinessError} 401 - parameter error.
* @throws {BusinessError} 202 - permission verification failed, application which is not a system application uses system API.
* @syscap SystemCapability.MiscServices.Wallpaper
* @systemapi Hide this for inner system use.
* @since 9
*/
function getColorsSync(wallpaperType: WallpaperType): Array<RgbaColor>;
/**
* Obtains the minimum height of the wallpaper. in pixels. returns 0 if no wallpaper has been set.
* @returns { number } the number returned by the function.
* @throws {BusinessError} 202 - permission verification failed, application which is not a system application uses system API.
* @syscap SystemCapability.MiscServices.Wallpaper
* @systemapi Hide this for inner system use.
* @since 9
*/
function getMinHeightSync(): number;
/**
* Obtains the minimum width of the wallpaper. in pixels. returns 0 if no wallpaper has been set.
* @returns { number } the number returned by the function.
* @throws {BusinessError} 202 - permission verification failed, application which is not a system application uses system API.
* @syscap SystemCapability.MiscServices.Wallpaper
* @systemapi Hide this for inner system use.
* @since 9
*/
function getMinWidthSync(): number;
/**
* Removes a wallpaper of the specified type and restores the default one.
* @param wallpaperType Indicates the wallpaper type.
* @throws {BusinessError} 401 - parameter error.
* @throws {BusinessError} 201 - permission denied.
* @throws {BusinessError} 202 - permission verification failed, application which is not a system application uses system API.
* @permission ohos.permission.SET_WALLPAPER
* @syscap SystemCapability.MiscServices.Wallpaper
* @systemapi Hide this for inner system use.
* @since 9
*/
function restore(wallpaperType: WallpaperType, callback: AsyncCallback<void>): void;
/**
* Removes a wallpaper of the specified type and restores the default one.
* @param wallpaperType Indicates the wallpaper type.
* @throws {BusinessError} 401 - parameter error.
* @throws {BusinessError} 201 - permission denied.
* @throws {BusinessError} 202 - permission verification failed, application which is not a system application uses system API.
* @permission ohos.permission.SET_WALLPAPER
* @syscap SystemCapability.MiscServices.Wallpaper
* @systemapi Hide this for inner system use.
* @since 9
*/
function restore(wallpaperType: WallpaperType): Promise<void>;
/**
* Sets a wallpaper of the specified type based on the uri path from a JPEG or PNG file or the pixel map of a PNG file.
* @param source Indicates the uri path from a JPEG or PNG file or the pixel map of the PNG file.
* @param wallpaperType Indicates the wallpaper type.
* @throws {BusinessError} 401 - parameter error.
* @throws {BusinessError} 201 - permission denied.
* @throws {BusinessError} 202 - permission verification failed, application which is not a system application uses system API.
* @permission ohos.permission.SET_WALLPAPER
* @syscap SystemCapability.MiscServices.Wallpaper
* @systemapi Hide this for inner system use.
* @since 9
*/
function setImage(source: string | image.PixelMap, wallpaperType: WallpaperType, callback: AsyncCallback<void>): void;
/**
* Sets a wallpaper of the specified type based on the uri path from a JPEG or PNG file or the pixel map of a PNG file.
* @param source Indicates the uri path from a JPEG or PNG file or the pixel map of the PNG file.
* @param wallpaperType Indicates the wallpaper type.
* @throws {BusinessError} 401 - parameter error.
* @throws {BusinessError} 201 - permission denied.
* @throws {BusinessError} 202 - permission verification failed, application which is not a system application uses system API.
* @permission ohos.permission.SET_WALLPAPER
* @syscap SystemCapability.MiscServices.Wallpaper
* @systemapi Hide this for inner system use.
* @since 9
*/
function setImage(source: string | image.PixelMap, wallpaperType: WallpaperType): Promise<void>;
```
- After change:
```js
/**
* Obtains the wallpaper colors for the wallpaper of the specified type. Returns rgbaColor type of array callback function.
* @param wallpaperType Indicates the wallpaper type.
* @returns { Array<RgbaColor> } the Array<RgbaColor> returned by the function.
* @throws {BusinessError} 401 - parameter error.
* @syscap SystemCapability.MiscServices.Wallpaper
* @since 9
*/
function getColorsSync(wallpaperType: WallpaperType): Array<RgbaColor>;
/**
* Obtains the minimum height of the wallpaper. in pixels. returns 0 if no wallpaper has been set.
* @returns { number } the number returned by the function.
* @syscap SystemCapability.MiscServices.Wallpaper
* @since 9
*/
function getMinHeightSync(): number;
/**
* Obtains the minimum width of the wallpaper. in pixels. returns 0 if no wallpaper has been set.
* @returns { number } the number returned by the function.
* @syscap SystemCapability.MiscServices.Wallpaper
* @since 9
*/
function getMinWidthSync(): number;
/**
* Removes a wallpaper of the specified type and restores the default one.
* @param wallpaperType Indicates the wallpaper type.
* @throws {BusinessError} 401 - parameter error.
* @throws {BusinessError} 201 - permission denied.
* @permission ohos.permission.SET_WALLPAPER
* @syscap SystemCapability.MiscServices.Wallpaper
* @since 9
*/
function restore(wallpaperType: WallpaperType, callback: AsyncCallback<void>): void;
/**
* Removes a wallpaper of the specified type and restores the default one.
* @param wallpaperType Indicates the wallpaper type.
* @throws {BusinessError} 401 - parameter error.
* @throws {BusinessError} 201 - permission denied.
* @permission ohos.permission.SET_WALLPAPER
* @syscap SystemCapability.MiscServices.Wallpaper
* @since 9
*/
function restore(wallpaperType: WallpaperType): Promise<void>;
/**
* Sets a wallpaper of the specified type based on the uri path from a JPEG or PNG file or the pixel map of a PNG file.
* @param source Indicates the uri path from a JPEG or PNG file or the pixel map of the PNG file.
* @param wallpaperType Indicates the wallpaper type.
* @throws {BusinessError} 401 - parameter error.
* @throws {BusinessError} 201 - permission denied.
* @permission ohos.permission.SET_WALLPAPER
* @syscap SystemCapability.MiscServices.Wallpaper
* @since 9
*/
function setImage(source: string | image.PixelMap, wallpaperType: WallpaperType, callback: AsyncCallback<void>): void;
/**
* Sets a wallpaper of the specified type based on the uri path from a JPEG or PNG file or the pixel map of a PNG file.
* @param source Indicates the uri path from a JPEG or PNG file or the pixel map of the PNG file.
* @param wallpaperType Indicates the wallpaper type.
* @throws {BusinessError} 401 - parameter error.
* @throws {BusinessError} 201 - permission denied.
* @permission ohos.permission.SET_WALLPAPER
* @syscap SystemCapability.MiscServices.Wallpaper
* @since 9
*/
function setImage(source: string | image.PixelMap, wallpaperType: WallpaperType): Promise<void>;
```
**Adaptation Guide**
Make sure the APIs are only invoked by system applications.
The code snippet is as follows:
```js
try {
let colors = wallpaper.getColorsSync(wallpaper.WallpaperType.WALLPAPER_SYSTEM);
console.log(`success to getColorsSync: ${JSON.stringify(colors)}`);
} catch (error) {
console.error(`failed to getColorsSync because: ${JSON.stringify(error)}`);
}
```
```js
let minHeight = wallpaper.getMinHeightSync();
```
```js
let minWidth = wallpaper.getMinWidthSync();
```
```js
wallpaper.restore(wallpaper.WallpaperType.WALLPAPER_SYSTEM, (error) => {
if (error) {
console.error(`failed to restore because: ${JSON.stringify(error)}`);
return;
}
console.log(`success to restore.`);
});
```
```js
wallpaper.restore(wallpaper.WallpaperType.WALLPAPER_SYSTEM).then(() => {
console.log(`success to restore.`);
}).catch((error) => {
console.error(`failed to restore because: ${JSON.stringify(error)}`);
});
```
```js
// The source type is string.
let wallpaperPath = "/data/data/ohos.acts.aafwk.plrdtest.form/files/Cup_ic.jpg";
wallpaper.setImage(wallpaperPath, wallpaper.WallpaperType.WALLPAPER_SYSTEM, (error) => {
if (error) {
console.error(`failed to setImage because: ${JSON.stringify(error)}`);
return;
}
console.log(`success to setImage.`);
});
```
```js
// The source type is string.
let wallpaperPath = "/data/data/ohos.acts.aafwk.plrdtest.form/files/Cup_ic.jpg";
wallpaper.setImage(wallpaperPath, wallpaper.WallpaperType.WALLPAPER_SYSTEM).then(() => {
console.log(`success to setImage.`);
}).catch((error) => {
console.error(`failed to setImage because: ${JSON.stringify(error)}`);
});
```
## cl.wallpaper.2 Deprecation of getIdSync, getFileSync, isChangeAllowed, isUserChangeAllowed, on, off, and RgbaColor
Deprecated the **getIdSync**, **getFileSync**, **isChangeAllowed**, **isUserChangeAllowed**, **on**, **off**, and **RgbaColor** APIs since API version 9.
You need to adapt your application based on the following information.
**Change Impact**
The APIs can no longer be used after being deleted.
- Involved APIs:
```js
function getIdSync(wallpaperType: WallpaperType): number;
function getFileSync(wallpaperType: WallpaperType): number;
function isChangeAllowed(): boolean;
function isUserChangeAllowed(): boolean;
function on(type: 'colorChange', callback: (colors: Array<RgbaColor>, wallpaperType: WallpaperType) => void): void;
function off(type: 'colorChange', callback?: (colors: Array<RgbaColor>, wallpaperType: WallpaperType) => void): void;
interface RgbaColor {
red: number;
green: number;
blue: number;
alpha: number;
}
```
- Before change:
```js
function getIdSync(wallpaperType: WallpaperType): number;
function getFileSync(wallpaperType: WallpaperType): number;
function isChangeAllowed(): boolean;
function isUserChangeAllowed(): boolean;
function on(type: 'colorChange', callback: (colors: Array<RgbaColor>, wallpaperType: WallpaperType) => void): void;
function off(type: 'colorChange', callback?: (colors: Array<RgbaColor>, wallpaperType: WallpaperType) => void): void;
interface RgbaColor {
red: number;
green: number;
blue: number;
alpha: number;
}
```
- After change:
The APIs are deleted.
**Adaptation Guide**
Update the code so that the deprecated APIs are not used.
# Bundle Manager Subsystem Changelog
## cl.bundlemanager.1 Field Change of the ApplicationInfo Struct in API Version 9
The **ApplicationInfo** struct [bundleManager/applicationInfo.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/ApplicationInfo.d.ts) in API version 9 has field changes, with the **systemApp** field being added and the **entryDir** field being deleted.
**Change Impact**<br>
There is no impact on applications that use the APIs of versions earlier than 9. The applications that use the APIs of version 9 need to adapt new modules and APIs.
**Key API/Component Changes**<br>
The following table describes the changed fields in the **ApplicationInfo** struct.
| Deleted Field| Added or Changed Field in API Version 9| Type|
| --- | --- | --- |
| N/A| systemApp | boolean |
| entryDir | N/A | string |
**Adaptation Guide**<br>
Import the bundle manager query module and use the **systemApp** field in the **ApplicationInfo** struct of API version 9. If the **entryDir** field is used, change the field because it is redundant in features where HAP decompression is not required.
## cl.bundlemanager.2 Field Change of the HapModuleInfo Struct in API Version 9
The **moduleSourceDir** field is deleted from the **HapModuleInfo** struct [bundleManager/hapModuleInfo.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/HapModuleInfo.d.ts) in API version 9.
**Change Impact**<br>
There is no impact on applications that use the APIs of versions earlier than 9. The applications that use the APIs of version 9 need to adapt new modules and APIs.
**Key API/Component Changes**<br>
The following table describes the changed fields in the **HapModuleInfo** struct.
| Deleted Field| Added or Changed Field in API Version 9| Type|
| --- | --- | --- |
| moduleSourceDir | N/A | string |
**Adaptation Guide**<br>
Import the bundle manager query module and do not use the **moduleSourceDir** field in the **HapModuleInfo** struct of API version 9. If the **moduleSourceDir** field is used, change the field because it is redundant in features where HAP decompression is not required.
# Account Subsystem Changelog
## cl.account_os_account.1 createOsAccountForDomain Error Code Change
Changed the error code returned when the domain account created by **createOsAccountForDomain()** already exists from **12300001** to **12300004**.
Changed the error information from "common system error" to "The account already exists".
**Change Impact**
The application developed based on earlier versions needs to adapt the new error code. Otherwise, the original service logic will be affected.
**Key API/Component Changes**
- AccountManager
- createOsAccountForDomain(type: OsAccountType, domainInfo: DomainAccountInfo, callback: AsyncCallback&lt;OsAccountInfo&gt;);
- createOsAccountForDomain(type: OsAccountType, domainInfo: DomainAccountInfo): Promise&lt;OsAccountInfo&gt;;
**Adaptation Guide**
The sample code is as follows:
```ts
import account_osAccount from "@ohos.account.osAccount"
let accountMgr = account_osAccount.getAccountManager();
let domainInfo = {
accountName: "zhangsan",
domain: "china.example.com"
};
try {
await accountMgr.createOsAccountForDomain(account_osAccount.OsAccountType.NORMAL, domainInfo);
await accountMgr.createOsAccountForDomain(account_osAccount.OsAccountType.NORMAL, domainInfo);
} catch (err) {
console.log("activateOsAccount err: " + JSON.stringify(err)); // error.code = 12300004;
}
```
## cl.account_os_account.2 Application Account getAllAccounts() Permission Change
Removed the **ohos.permission.GET_ALL_APP_ACCOUNTS** permission that is originally required for an application to call **getAllAccounts()** to obtain accessible accounts.
**Change Impact**
From this version, applications do not need the **ohos.permission.GET_ALL_APP_ACCOUNTS** permission when calling **getAllAccounts()**.
**Key API/Component Changes**
- AccountManager
- getAllAccounts(callback: AsyncCallback&lt;Array&lt;AppAccountInfo&gt;&gt;): void;
- getAllAccounts(): Promise&lt;Array&lt;AppAccountInfo&gt;&gt;;
**Adaptation Guide**
The following is the sample code for an application to obtain the accessible accounts without the **ohos.permission.GET_ALL_APP_ACCOUNTS** permission:
```ts
import account_appAccount from "@ohos.account.appAccount"
let accountMgr = account_appAccount.createAppAccountManager();
try {
await accountMgr.addAccount("accessibleAccount_promise_nopermission");
var data = await accountMgr.getAllAccounts();
if (data[0].name == "accessibleAccount_promise_nopermission") {
console.log("getAllAccounts successfully");
}
} catch (err) {
console.log("getAllAccounts err: " + JSON.stringify(err));
}
```
## cl.account_os_account.3 Application Account getAccountsByOwner() Permission Change
Removed the **ohos.permission.GET_ALL_APP_ACCOUNTS** permission that is originally required for an application to call **getAccountsByOwner()** to obtain the accessible accounts based on the account owner .
**Change Impact**
From this version, applications do not need the **ohos.permission.GET_ALL_APP_ACCOUNTS** permission when calling **getAccountsByOwner()**.
**Key API/Component Changes**
- AccountManager
- getAccountsByOwner(owner: string, callback: AsyncCallback&lt;Array&lt;AppAccountInfo&gt;&gt;): void;
- getAccountsByOwner(owner: string): Promise&lt;Array&lt;AppAccountInfo&gt;&gt;;
**Adaptation Guide**
The following is the sample code for an application to obtain the accessible accounts based on the account owner without the **ohos.permission.GET_ALL_APP_ACCOUNTS** permission:
```ts
import account_appAccount from "@ohos.account.appAccount"
let accountMgr = account_appAccount.createAppAccountManager();
try {
var ownerName = "com.example.owner";
var data = await accountMgr.getAllAccounts(ownerName);
} catch (err) {
console.log("getAllAccounts err: " + JSON.stringify(err));
}
```
# Bundle Manager Subsystem ChangeLog
## cl.bundlemanager.1 Name Change of the Bundle Manager Distributed Query Module
The name of the bundle manager distributed query module in API version 9 is changed from **ohos.bundle.distributedBundle** to **[ohos.bundle.distributedBundleManager](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/@ohos.bundle.distributedBundleManager.d.ts)**. The APIs remain unchanged.
**Change Impacts**
There is no impact on applications that use the APIs of versions earlier than 9. The applications that use the APIs of version 9 need to adapt the new module.
**Key API/Component Changes**
The name of the bundle manager distributed query module is changed from **ohos.bundle.distributedBundle** to **ohos.bundle.distributedBundleManager**. The APIs remain unchanged.
**Adaptation Guide**
Change the module to import from **@ohos.bundle.distributedBundle** to **@ohos.bundle.distributedBundleManager**.
```ts
import distributedBundle form '@ohos.bundle.distributedBundleManager';
```
# Multimedia Subsystem ChangeLog
Compared with OpenHarmony 3.2 Beta4, OpenHarmony3.2.10.3 has the following changes in APIs of the camera component in the multimedia subsystem.
## cl.subsystemname.1 Camera API Changed
1. All the APIs of the camera component are changed to system APIs in the API version 9.
2. Some functional APIs are added and some others are deprecated to:
- Improve the usability of camera APIs.
- Help you quickly understand camera APIs and use them for development.
- Facilitate expansion of framework functions in later versions, and reduce coupling between framework modules.
You need to refer to the following change description to adapt your application.
**Change Impacts**
JS APIs in API version 9 are affected. Your application needs to adapt these APIs so that it can properly implement features in the SDK environment of the new version.
**Key API/Component Changes**
| Module | Class | Method/Attribute/Enum/Constant | Is System API| Change Type|
| ---------------------- | ----------------------- | ------------------------------------------------------------ | --------------- | -------- |
| ohos.multimedia.camera | camera | function getCameraManager(context: Context): CameraManager; | Yes | Added |
| ohos.multimedia.camera | camera | function getCameraManager(context: Context, callback: AsyncCallback<CameraManager>): void;<br>function getCameraManager(context: Context): Promise<CameraManager>; | Yes | Deprecated |
| ohos.multimedia.camera | CameraErrorCode | INVALID_ARGUMENT = 7400101,<br>OPERATION_NOT_ALLOWED = 7400102,<br>SESSION_NOT_CONFIG = 7400103,<br>SESSION_NOT_RUNNING = 7400104,<br>SESSION_CONFIG_LOCKED = 7400105,<br>DEVICE_SETTING_LOCKED = 7400106,<br>CONFILICT_CAMERA = 7400107,<br>DEVICE_DISABLED = 7400108,<br>SERVICE_FATAL_ERROR = 7400201 | Yes | Added |
| ohos.multimedia.camera | CameraManager | getSupportedCameras(): Array<CameraDevice>;<br>getSupportedOutputCapability(camera: CameraDevice): CameraOutputCapability;<br>createCameraInput(camera: CameraDevice): CameraInput;<br>createCameraInput(position: CameraPosition, type: CameraType): CameraInput;<br>createPreviewOutput(profile: Profile, surfaceId: string): PreviewOutput;<br>createPhotoOutput(profile: Profile, surfaceId: string): PhotoOutput;<br>createVideoOutput(profile: VideoProfile, surfaceId: string): VideoOutput;<br>createMetadataOutput(metadataObjectTypes: Array<MetadataObjectType>): MetadataOutput;<br>createCaptureSession(): CaptureSession; | Yes | Added |
| ohos.multimedia.camera | CameraManager | getSupportedCameras(callback: AsyncCallback<Array<CameraDevice>>): void;<br>getSupportedCameras(): Promise<Array<CameraDevice>>;<br>getSupportedOutputCapability(camera: CameraDevice, callback: AsyncCallback<CameraOutputCapability>): void;<br>getSupportedOutputCapability(camera: CameraDevice): Promise<CameraOutputCapability>;<br>createCameraInput(camera: CameraDevice, callback: AsyncCallback<CameraInput>): void;<br>createCameraInput(camera: CameraDevice): Promise<CameraInput>;<br>createCameraInput(position: CameraPosition, type: CameraType, callback: AsyncCallback<CameraInput>): void;<br>createCameraInput(position: CameraPosition, type: CameraType): Promise<CameraInput>;<br>createPreviewOutput(profile: Profile, surfaceId: string, callback: AsyncCallback<PreviewOutput>): void;<br>createPreviewOutput(profile: Profile, surfaceId: string): Promise<PreviewOutput>;<br>createPhotoOutput(profile: Profile, surfaceId: string, callback: AsyncCallback<PhotoOutput>): void;<br>createPhotoOutput(profile: Profile, surfaceId: string): Promise<PhotoOutput>;<br>createVideoOutput(profile: VideoProfile, surfaceId: string, callback: AsyncCallback<VideoOutput>): void;<br>createVideoOutput(profile: VideoProfile, surfaceId: string): Promise<VideoOutput>;<br>createMetadataOutput(metadataObjectTypes: Array<MetadataObjectType>, callback: AsyncCallback<MetadataOutput>): void;<br>createMetadataOutput(metadataObjectTypes: Array<MetadataObjectType>): Promise<MetadataOutput>;<br>createCaptureSession(callback: AsyncCallback<CaptureSession>): void;<br>createCaptureSession(): Promise<CaptureSession>; | Yes | Deprecated |
| ohos.multimedia.camera | CameraType | CAMERA_TYPE_DEFAULT = 0 | Yes | Added |
| ohos.multimedia.camera | CameraType | CAMERA_TYPE_UNSPECIFIED = 0 | Yes | Deprecated |
| ohos.multimedia.camera | CameraInput | on(type: 'error', camera: CameraDevice, callback: ErrorCallback<BusinessError>): void; | Yes | Added |
| ohos.multimedia.camera | CameraInput | release(callback: AsyncCallback<void>): void;<br>release(): Promise<void>;<br>on(type: 'error', camera: CameraDevice, callback: ErrorCallback<CameraInputError>): void; | Yes | Deprecated |
| ohos.multimedia.camera | CameraInputErrorCode | ERROR_UNKNOWN = -1<br>ERROR_NO_PERMISSION = 0<br>ERROR_DEVICE_PREEMPTED = 1<br>ERROR_DEVICE_DISCONNECTED = 2<br>ERROR_DEVICE_IN_USE = 3<br>ERROR_DRIVER_ERROR = 4 | Yes | Deprecated |
| ohos.multimedia.camera | CameraInputError | code: CameraInputErrorCode | Yes | Deprecated |
| ohos.multimedia.camera | CaptureSession | beginConfig(): void;<br>addInput(cameraInput: CameraInput): void;<br>removeInput(cameraInput: CameraInput): void;<br>addOutput(cameraOutput: CameraOutput): void;<br>removeOutput(cameraOutput: CameraOutput): void;<br>hasFlash(): boolean;<br>isFlashModeSupported(flashMode: FlashMode): boolean;<br>getFlashMode(): FlashMode;<br>setFlashMode(flashMode: FlashMode): void;<br>isExposureModeSupported(aeMode: ExposureMode): boolean;<br>getExposureMode(): ExposureMode;<br>setExposureMode(aeMode: ExposureMode): void;<br>getMeteringPoint(): Point;<br>setMeteringPoint(point: Point): void;<br>getExposureBiasRange(): Array<number>;<br>setExposureBias(exposureBias: number): void;<br>getExposureValue(): number;<br>isFocusModeSupported(afMode: FocusMode): boolean;<br>getFocusMode(): FocusMode;<br>setFocusMode(afMode: FocusMode): void;<br>setFocusPoint(point: Point): void;<br>getFocusPoint(): Point;<br>getFocalLength(): number;<br>getZoomRatioRange(): Array<number>;<br>getZoomRatio(): number;<br>setZoomRatio(zoomRatio: number): void;<br>isVideoStabilizationModeSupported(vsMode: VideoStabilizationMode): boolean;<br>getActiveVideoStabilizationMode(): VideoStabilizationMode;<br>setVideoStabilizationMode(mode: VideoStabilizationMode): void;<br>on(type: 'error', callback: ErrorCallback<BusinessError>): void; | Yes | Added |
| ohos.multimedia.camera | CaptureSession | beginConfig(callback: AsyncCallback<void>): void;<br>beginConfig(): Promise<void>;<br>addInput(cameraInput: CameraInput, callback: AsyncCallback<void>): void;<br>addInput(cameraInput: CameraInput): Promise<void>;<br>removeInput(cameraInput: CameraInput, callback: AsyncCallback<void>): void;<br>removeInput(cameraInput: CameraInput): Promise<void>;<br>addOutput(cameraOutput: CameraOutput, callback: AsyncCallback<void>): void;<br>addOutput(cameraOutput: CameraOutput): Promise<void>;<br>removeOutput(cameraOutput: CameraOutput, callback: AsyncCallback<void>): void;<br>removeOutput(cameraOutput: CameraOutput): Promise<void>;<br>hasFlash(callback: AsyncCallback<boolean>): void;<br>hasFlash(): Promise<boolean>;<br>isFlashModeSupported(flashMode: FlashMode, callback: AsyncCallback<boolean>): void;<br>isFlashModeSupported(flashMode: FlashMode): Promise<boolean>;<br>getFlashMode(callback: AsyncCallback<FlashMode>): void;<br>getFlashMode(): Promise<FlashMode>;<br>setFlashMode(flashMode: FlashMode, callback: AsyncCallback<void>): void;<br>setFlashMode(flashMode: FlashMode): Promise<void>;<br>isExposureModeSupported(aeMode: ExposureMode, callback: AsyncCallback<boolean>): void;<br>isExposureModeSupported(aeMode: ExposureMode): Promise<boolean>;<br>getExposureMode(callback: AsyncCallback<ExposureMode>): void;<br>getExposureMode(): Promise<ExposureMode>;<br>setExposureMode(aeMode: ExposureMode, callback: AsyncCallback<void>): void;<br>setExposureMode(aeMode: ExposureMode): Promise<void>;<br>getMeteringPoint(callback: AsyncCallback<Point>): void;<br>getMeteringPoint(): Promise<Point>;<br>setMeteringPoint(point: Point, callback: AsyncCallback<void>): void;<br>setMeteringPoint(point: Point): Promise<void>;<br>getExposureBiasRange(callback: AsyncCallback<Array<number>>): void;<br>getExposureBiasRange(): Promise<Array<number>>;<br>setExposureBias(exposureBias: number, callback: AsyncCallback<void>): void;<br>setExposureBias(exposureBias: number): Promise<void>;<br>getExposureValue(callback: AsyncCallback<number>): void;<br>getExposureValue(): Promise<number>;<br>isFocusModeSupported(afMode: FocusMode, callback: AsyncCallback<boolean>): void;<br>isFocusModeSupported(afMode: FocusMode): Promise<boolean>;<br>getFocusMode(callback: AsyncCallback<FocusMode>): void;<br>getFocusMode(): Promise<FocusMode>;<br>setFocusMode(afMode: FocusMode, callback: AsyncCallback<void>): void;<br>setFocusMode(afMode: FocusMode): Promise<void>;<br>setFocusPoint(point: Point, callback: AsyncCallback<void>): void;<br>setFocusPoint(point: Point): Promise<void>;<br>getFocusPoint(callback: AsyncCallback<Point>): void;<br>getFocusPoint(): Promise<Point>;<br>getFocalLength(callback: AsyncCallback<number>): void;<br>getFocalLength(): Promise<number>;<br>getZoomRatioRange(callback: AsyncCallback<Array<number>>): void;<br>getZoomRatioRange(): Promise<Array<number>>;<br>getZoomRatio(callback: AsyncCallback<number>): void;<br>getZoomRatio(): Promise<number>;<br>setZoomRatio(zoomRatio: number, callback: AsyncCallback<void>): void;<br>setZoomRatio(zoomRatio: number): Promise<void>;<br>isVideoStabilizationModeSupported(vsMode: VideoStabilizationMode, callback: AsyncCallback<boolean>): void;<br>isVideoStabilizationModeSupported(vsMode: VideoStabilizationMode): Promise<boolean>;<br>getActiveVideoStabilizationMode(callback: AsyncCallback<VideoStabilizationMode>): void;<br>getActiveVideoStabilizationMode(): Promise<VideoStabilizationMode>;<br>setVideoStabilizationMode(mode: VideoStabilizationMode, callback: AsyncCallback<void>): void;<br>setVideoStabilizationMode(mode: VideoStabilizationMode): Promise<void>;<br>on(type: 'error', callback: ErrorCallback<CaptureSessionError>): void; | Yes | Deprecated |
| ohos.multimedia.camera | CaptureSessionErrorCode | ERROR_UNKNOWN = -1<br>ERROR_INSUFFICIENT_RESOURCES = 0<br>ERROR_TIMEOUT = 1 | Yes | Deprecated |
| ohos.multimedia.camera | CaptureSessionError | code: CaptureSessionErrorCode | Yes | Deprecated |
| ohos.multimedia.camera | PreviewOutput | on(type: 'error', callback: ErrorCallback<BusinessError>): void; | Yes | Added |
| ohos.multimedia.camera | PreviewOutput | on(type: 'error', callback: ErrorCallback<PreviewOutputError>): void; | Yes | Deprecated |
| ohos.multimedia.camera | PreviewOutputErrorCode | ERROR_UNKNOWN = -1 | Yes | Deprecated |
| ohos.multimedia.camera | PreviewOutputError | code: PreviewOutputErrorCode | Yes | Deprecated |
| ohos.multimedia.camera | PhotoOutput | capture(): Promise<void>;<br>isMirrorSupported(): boolean;<br>on(type: 'error', callback: ErrorCallback<BusinessError>): void; | Yes | Added |
| ohos.multimedia.camera | PhotoOutput | isMirrorSupported(callback: AsyncCallback<boolean>): void;<br>isMirrorSupported(): Promise<boolean>;<br>on(type: 'error', callback: ErrorCallback<PhotoOutputError>): void; | Yes | Deprecated |
| ohos.multimedia.camera | PhotoOutputErrorCode | ERROR_UNKNOWN = -1<br>ERROR_DRIVER_ERROR = 0<br>ERROR_INSUFFICIENT_RESOURCES = 1<br>ERROR_TIMEOUT = 2 | Yes | Deprecated |
| ohos.multimedia.camera | PhotoOutputError | code: PhotoOutputErrorCode | Yes | Deprecated |
| ohos.multimedia.camera | VideoOutput | on(type: 'error', callback: ErrorCallback<BusinessError>): void; | Yes | Added |
| ohos.multimedia.camera | VideoOutput | on(type: 'error', callback: ErrorCallback<VideoOutputError>): void; | Yes | Deprecated |
| ohos.multimedia.camera | VideoOutputErrorCode | ERROR_UNKNOWN = -1<br>ERROR_DRIVER_ERROR = 0 | Yes | Deprecated |
| ohos.multimedia.camera | VideoOutputError | code: VideoOutputErrorCode | Yes | Deprecated |
| ohos.multimedia.camera | MetadataObject | readonly type: MetadataObjectType;<br>readonly timestamp: number; | Yes | Added |
| ohos.multimedia.camera | MetadataObject | getType(callback: AsyncCallback<MetadataObjectType>): void;<br>getType(): Promise<MetadataObjectType>;<br>getTimestamp(callback: AsyncCallback<number>): void;<br>getTimestamp(): Promise<number>;<br>getBoundingBox(callback: AsyncCallback<Rect>): void;<br>getBoundingBox(): Promise<Rect>; | Yes | Deprecated |
| ohos.multimedia.camera | MetadataFaceObject | readonly boundingBox: Rect | Yes | Added |
| ohos.multimedia.camera | MetadataOutput | on(type: 'error', callback: ErrorCallback<BusinessError>): void; | Yes | Added |
| ohos.multimedia.camera | MetadataOutput | on(type: 'error', callback: ErrorCallback<BusinessError>): void; | Yes | Deprecated |
| ohos.multimedia.camera | MetadataOutputErrorCode | ERROR_UNKNOWN = -1<br>ERROR_INSUFFICIENT_RESOURCES = 0 | Yes | Deprecated |
| ohos.multimedia.camera | MetadataOutputError | code: MetadataOutputErrorCode | Yes | Deprecated |
**Adaptation Guide**
In addition to the new APIs and deprecated APIs, you need to adapt your application to the changed APIs.
In Beta4 and later versions, the following APIs are changed.
**New APIs**
1. **CameraErrorCode** enums
Enum: INVALID_ARGUMENT; value: 7400101
Enum: OPERATION_NOT_ALLOWED; value: 7400102
Enum: SESSION_NOT_CONFIG; value: 7400103
Enum: SESSION_NOT_RUNNING; value: 7400104
Enum: SESSION_CONFIG_LOCKED; value: 7400105
Enum: DEVICE_SETTING_LOCKED; value: 7400106
Enum: CONFILICT_CAMERA; value: 7400107
Enum: DEVICE_DISABLED; value: 7400108
Enum: SERVICE_FATAL_ERROR; value: 7400201
2. Added **capture(): Promise<void>** to the **PhotoOutput** API.
3. Added the readonly type **MetadataObjectType** to the **MetadataObject** API.
4. Added **readonly timestamp: number** to the **MetadataObject** API.
5. Added **readonly boundingBox: Rect** to the **MetadataObject** API.
**Deprecated APIs**
1. Deprecated the **release(callback: AsyncCallback<void>): void** and **release(): Promise<void>** APIs in **CameraInput**.
2. Deprecated the **CameraInputErrorCode** enums and all their values: **ERROR_UNKNOWN** = **-1**, **ERROR_NO_PERMISSION** = **0**, **ERROR_DEVICE_PREEMPTED** = **1**, **ERROR_DEVICE_DISCONNECTED** = **2**, **ERROR_DEVICE_IN_USE** = **3**, **ERROR_DRIVER_ERROR** = **4**
3. Deprecated the **CameraInputError** API and its attribute **CameraInputErrorCode**.
4. Deprecated the **CaptureSessionErrorCode** enums and all their values: **ERROR_UNKNOWN** = **-1**, **ERROR_INSUFFICIENT_RESOURCES** = **0**, **ERROR_TIMEOUT** = **1**
5. Deprecated the **CaptureSessionError** API and its attribute **CaptureSessionErrorCode**.
6. Deprecated the **PreviewOutputErrorCode** enum and its value: **ERROR_UNKNOWN** = **-1**
7. Deprecated the **PreviewOutputError** API and its attribute **PreviewOutputErrorCode**.
8. Deprecated the **PhotoOutputErrorCode** enums and all their values: **ERROR_UNKNOWN** = **-1**, **ERROR_DRIVER_ERROR** = **0**, **ERROR_INSUFFICIENT_RESOURCES** = **1**, **ERROR_TIMEOUT** = **2**
9. Deprecated the **PhotoOutputError** API and its attribute **PhotoOutputErrorCode**.
10. Deprecated the **VideoOutputErrorCode** enums and all their values: **ERROR_UNKNOWN** = **-1**, **ERROR_DRIVER_ERROR** = **0**
11. Deprecated the **VideoOutputError** API and its attribute **VideoOutputErrorCode**.
12. Deprecated **getType(callback: AsyncCallback<MetadataObjectType>): void** in the **MetadataObject** API.
13. Deprecated **getType(): Promise<MetadataObjectType>** in the **MetadataObject** API.
14. Deprecated **getTimestamp(callback: AsyncCallback<number>): void** in the **MetadataObject** API.
15. Deprecated **getTimestamp(): Promise<number>** in the **MetadataObject** API.
16. Deprecated **getBoundingBox(callback: AsyncCallback<Rect>): void** in the **MetadataObject** API.
17. Deprecated **getBoundingBox(): Promise<Rect>** in the **MetadataObject** API.
18. Deprecated the **MetadataOutputErrorCode** enums and all their values: **ERROR_UNKNOWN** = **-1**, **ERROR_INSUFFICIENT_RESOURCES** = **0**
19. Deprecated the **MetadataOutputError** API and its attribute **MetadataOutputErrorCode**.
**Changed APIs**
1. Changed the return modes of the **getCameraManager** API in the camera module from asynchronous callback and asynchronous promise to the synchronous mode. Therefore, the original APIs **getCameraManager(context: Context, callback: AsyncCallback<CameraManager>): void** and **getCameraManager(context: Context): Promise<CameraManager>** are changed to **getCameraManager(context: Context): CameraManager**.
The sample code is as follows:
```
let cameraManager = camera.getCameraManager(context);
```
2. Changed the return modes of the **getSupportedCameras** API in CameraManager from asynchronous callback and asynchronous promise to the synchronous mode. Therefore, the original APIs **getSupportedCameras(callback: AsyncCallback<Array<CameraDevice>>): void** and **getSupportedCameras(): Promise<Array<CameraDevice>>** are changed to **getSupportedCameras(): Array<CameraDevice>**.
The sample code is as follows:
```
let cameras = cameraManager.getSupportedCameras();
```
3. Changed the return modes of the **getSupportedOutputCapability** API in CameraManager from asynchronous callback and asynchronous promise to the synchronous mode. Therefore, the original APIs **getSupportedOutputCapability(camera: CameraDevice, callback: AsyncCallback<CameraOutputCapability>): void** and **getSupportedOutputCapability(camera: CameraDevice): Promise<CameraOutputCapability>** are changed to **getSupportedOutputCapability(camera: CameraDevice): CameraOutputCapability**.
The sample code is as follows:
```
let cameraDevice = cameras[0];
let CameraOutputCapability = cameraManager.getSupportedOutputCapability(cameraDevice);
```
4. Changed the return modes of the **createCameraInput(camera: CameraDevice)** API in CameraManager from asynchronous callback and asynchronous promise to the synchronous mode. Therefore, the original APIs **createCameraInput(camera: CameraDevice, callback: AsyncCallback<CameraInput>): void** and **createCameraInput(camera: CameraDevice): Promise<CameraInput>** are changed to **createCameraInput(camera: CameraDevice): CameraInput**.
The sample code is as follows:
```
let cameraDevice = cameras[0];
let cameraInput = cameraManager.createCameraInput(cameraDevice);
```
5. Changed the return modes of the **createCameraInput(position: CameraPosition, type: CameraType)** API in CameraManager from asynchronous callback and asynchronous promise to the synchronous mode. Therefore, the original APIs **createCameraInput(position: CameraPosition, type: CameraType, callback: AsyncCallback<CameraInput>): void** and **createCameraInput(position: CameraPosition, type: CameraType): Promise<CameraInput>** are changed to **createCameraInput(position: CameraPosition, type: CameraType): CameraInput**.
The sample code is as follows:
```
let cameraDevice = cameras[0];
let position = cameraDevice.cameraPosition;
let type = cameraDevice.cameraType;
let cameraInput = cameraManager.createCameraInput(position, type);
```
6. Changed the return modes of the **createPreviewOutput** API in CameraManager from asynchronous callback and asynchronous promise to the synchronous mode. Therefore, the original APIs **createPreviewOutput(profile: Profile, surfaceId: string, callback: AsyncCallback<PreviewOutput>): void** and **createPreviewOutput(profile: Profile, surfaceId: string): Promise<PreviewOutput>** are changed to **createPreviewOutput(profile: Profile, surfaceId: string): PreviewOutput**.
The sample code is as follows:
```
let profile = cameraoutputcapability.previewProfiles[0];
let previewOutput = cameraManager.createPreviewOutput(profile, surfaceId);
```
7. Changed the return modes of the **createPhotoOutput** API in CameraManager from asynchronous callback and asynchronous promise to the synchronous mode. Therefore, the original APIs **createPhotoOutput(profile: Profile, surfaceId: string, callback: AsyncCallback<PhotoOutput>): void** and **createPhotoOutput(profile: Profile, surfaceId: string): Promise<PhotoOutput>** are changed to **createPhotoOutput(profile: Profile, surfaceId: string): PhotoOutput**.
The sample code is as follows:
```
let profile = cameraoutputcapability.photoProfiles[0];
let photoOutput = cameraManager.createPhotoOutput(profile, surfaceId);
```
8. Changed the return modes of the **createVideoOutput** API in CameraManager from asynchronous callback and asynchronous promise to the synchronous mode. Therefore, the original APIs **createVideoOutput(profile: VideoProfile, surfaceId: string, callback: AsyncCallback<VideoOutput>): void** and **createVideoOutput(profile: VideoProfile, surfaceId: string): Promise<VideoOutput>** are changed to **createVideoOutput(profile: VideoProfile, surfaceId: string): VideoOutput**.
The sample code is as follows:
```
let profile = cameraoutputcapability.videoProfiles[0];
let videoOutput = cameraManager.createVideoOutput(profile, surfaceId);
```
9. Changed the return modes of the **createMetadataOutput** API in CameraManager from asynchronous callback and asynchronous promise to the synchronous mode. Therefore, the original APIs **createMetadataOutput(metadataObjectTypes: Array<MetadataObjectType>, callback: AsyncCallback<MetadataOutput>): void** and **createMetadataOutput(metadataObjectTypes: Array<MetadataObjectType>): Promise<MetadataOutput>** are changed to **createMetadataOutput(metadataObjectTypes: Array<MetadataObjectType>): MetadataOutput**.
The sample code is as follows:
```
let metadataObjectTypes = cameraoutputcapability.supportedMetadataObjectTypes;
let metadataOutput = cameraManager.createMetadataOutput(metadataObjectTypes);
```
10. Changed the return modes of the **createCaptureSession** API in CameraManager from asynchronous callback and asynchronous promise to the synchronous mode. Therefore, the original APIs **createCaptureSession(callback: AsyncCallback<CaptureSession>): void** and **createCaptureSession(): Promise<CaptureSession>** are changed to **createCaptureSession(): CaptureSession**.
The sample code is as follows:
```
let captureSession = cameraManager.createCaptureSession();
```
11. Changed the enum **CAMERA_TYPE_UNSPECIFIED** of **CameraType** to **CAMERA_TYPE_DEFAULT**.
12. Changed the return value type of the **on** API in CameraInput from **CameraInputError** to **BusinessError**. Therefore, the original API **on(type: 'error', camera: CameraDevice, callback: ErrorCallback<CameraInputError>): void** is changed to **on(type: 'error', camera: CameraDevice, callback: ErrorCallback<BusinessError>): void**.
The sample code is as follows:
```
let cameraDevice = cameras[0];
cameraInput.on('error', cameraDevice, (BusinessError) => {
})
```
13. Changed the return modes of the **beginConfig** API in CaptureSession from asynchronous callback and asynchronous promise to the synchronous mode. Therefore, the original APIs **beginConfig(callback: AsyncCallback<void>): void** and **beginConfig(): Promise<void>** are changed to **beginConfig(): void**.
The sample code is as follows:
```
captureSession.beginConfig();
```
14. Changed the return modes of the **addInput** API in CaptureSession from asynchronous callback and asynchronous promise to the synchronous mode. Therefore, the original APIs **addInput(cameraInput: CameraInput, callback: AsyncCallback<void>): void** and **addInput(cameraInput: CameraInput): Promise<void>** are changed to **addInput(cameraInput: CameraInput): void**.
The sample code is as follows:
```
captureSession.addInput(cameraInput);
```
15. Changed the return modes of the **removeInput** API in CaptureSession from asynchronous callback and asynchronous promise to the synchronous mode. Therefore, the original APIs **removeInput(cameraInput: CameraInput, callback: AsyncCallback<void>): void** and **removeInput(cameraInput: CameraInput): Promise<void>** are changed to **removeInput(cameraInput: CameraInput): void**.
The sample code is as follows:
```
captureSession.removeInput(cameraInput);
```
16. Changed the return modes of the **addOutput** API in CaptureSession from asynchronous callback and asynchronous promise to the synchronous mode. Therefore, the original APIs **addOutput(cameraOutput: CameraOutput, callback: AsyncCallback<void>): void** and **addOutput(cameraOutput: CameraOutput): Promise<void>** are changed to **addOutput(cameraOutput: CameraOutput): void**.
The sample code is as follows:
```
captureSession.addOutput(previewOutput);
```
17. Changed the return modes of the **removeOutput** API in CaptureSession from asynchronous callback and asynchronous promise to the synchronous mode. Therefore, the original APIs **removeOutput(cameraOutput: CameraOutput, callback: AsyncCallback<void>): void** and **removeOutput(cameraOutput: CameraOutput): Promise<void>** are changed to **removeOutput(cameraOutput: CameraOutput): void**.
The sample code is as follows:
```
captureSession.removeOutput(previewOutput);
```
18. Changed the return modes of the **hasFlash** API in CaptureSession from asynchronous callback and asynchronous promise to the synchronous mode. Therefore, the original APIs **hasFlash(callback: AsyncCallback<boolean>): void** and **hasFlash(): Promise<boolean>** are changed to **hasFlash(): boolean**.
The sample code is as follows:
```
let status = captureSession.hasFlash();
```
19. Changed the return modes of the **isFlashModeSupported** API in CaptureSession from asynchronous callback and asynchronous promise to the synchronous mode. Therefore, the original APIs **isFlashModeSupported(flashMode: FlashMode, callback: AsyncCallback<boolean>): void** and **isFlashModeSupported(flashMode: FlashMode): Promise<boolean>** are changed to **isFlashModeSupported(flashMode: FlashMode): boolean**.
The sample code is as follows:
```
let status = captureSession.isFlashModeSupported(camera.FlashMode.FLASH_MODE_AUTO);
```
20. Changed the return modes of the **getFlashMode** API in CaptureSession from asynchronous callback and asynchronous promise to the synchronous mode. Therefore, the original APIs **getFlashMode(callback: AsyncCallback<FlashMode>): void** and **getFlashMode(): Promise<FlashMode>** are changed to **getFlashMode(): FlashMode**.
The sample code is as follows:
```
let flashMode = captureSession.getFlashMode();
```
21. Changed the return modes of the **isExposureModeSupported** API in CaptureSession from asynchronous callback and asynchronous promise to the synchronous mode. Therefore, the original APIs **isExposureModeSupported(aeMode: ExposureMode, callback: AsyncCallback<boolean>): void** and **isExposureModeSupported(aeMode: ExposureMode): Promise<boolean>** are changed to **isExposureModeSupported(aeMode: ExposureMode): boolean**.
The sample code is as follows:
```
let isSupported = captureSession.isExposureModeSupported(camera.ExposureMode.EXPOSURE_MODE_LOCKED);
```
22. Changed the return modes of the **getExposureMode** API in CaptureSession from asynchronous callback and asynchronous promise to the synchronous mode. Therefore, the original APIs **getExposureMode(callback: AsyncCallback<ExposureMode>): void** and **getExposureMode(): Promise<ExposureMode>** are changed to **getExposureMode(): ExposureMode**.
The sample code is as follows:
```
let exposureMode = captureSession.getExposureMode();
```
23. Changed the return modes of the **setExposureMode** API in CaptureSession from asynchronous callback and asynchronous promise to the synchronous mode. Therefore, the original APIs **setExposureMode(aeMode: ExposureMode, callback: AsyncCallback<void>): void** and **setExposureMode(aeMode: ExposureMode): Promise<void>** are changed to **setExposureMode(aeMode: ExposureMode): void**.
The sample code is as follows:
```
captureSession.setExposureMode(camera.ExposureMode.EXPOSURE_MODE_LOCKED);
```
24. Changed the return modes of the **getMeteringPoint** API in CaptureSession from asynchronous callback and asynchronous promise to the synchronous mode. Therefore, the original APIs **getMeteringPoint(callback: AsyncCallback<Point>): void** and **getMeteringPoint(): Promise<Point>** are changed to **getMeteringPoint(): Point**.
The sample code is as follows:
```
let exposurePoint = captureSession.getMeteringPoint();
```
25. Changed the return modes of the **setMeteringPoint** API in CaptureSession from asynchronous callback and asynchronous promise to the synchronous mode. Therefore, the original APIs **setMeteringPoint(point: Point, callback: AsyncCallback<void>): void** and **setMeteringPoint(point: Point): Promise<void>** are changed to **setMeteringPoint(point: Point): void**.
The sample code is as follows:
```
let Point2 = {x: 2, y: 2};
captureSession.setMeteringPoint(Point2);
```
26. Changed the return modes of the **getExposureBiasRange** API in CaptureSession from asynchronous callback and asynchronous promise to the synchronous mode. Therefore, the original APIs **getExposureBiasRange(callback: AsyncCallback<Array<number>>): void** and **getExposureBiasRange(): Promise<Array<number>>** are changed to **getExposureBiasRange(): Array<number>**.
The sample code is as follows:
```
let biasRangeArray = captureSession.getExposureBiasRange();
```
27. Changed the return modes of the **setExposureBias** API in CaptureSession from asynchronous callback and asynchronous promise to the synchronous mode. Therefore, the original APIs **setExposureBias(exposureBias: number, callback: AsyncCallback<void>): void** and **setExposureBias(exposureBias: number): Promise<void>** are changed to **setExposureBias(exposureBias: number): void**.
The sample code is as follows:
```
let exposureBias = biasRangeArray[0];
captureSession.setExposureBias(exposureBias);
```
28. Changed the return modes of the **getExposureValue** API in CaptureSession from asynchronous callback and asynchronous promise to the synchronous mode. Therefore, the original APIs **getExposureValue(callback: AsyncCallback<number>): void** and **getExposureValue(): Promise<number>** are changed to **getExposureValue(): number**.
The sample code is as follows:
```
let exposureValue = captureSession.getExposureValue();
```
29. Changed the return modes of the **isFocusModeSupported** API in CaptureSession from asynchronous callback and asynchronous promise to the synchronous mode. Therefore, the original APIs **isFocusModeSupported(afMode: FocusMode, callback: AsyncCallback<boolean>): void** and **isFocusModeSupported(afMode: FocusMode): Promise<boolean>** are changed to **isFocusModeSupported(afMode: FocusMode): boolean**.
The sample code is as follows:
```
let status = captureSession.isFocusModeSupported(camera.FocusMode.FOCUS_MODE_AUTO);
```
30. Changed the return modes of the **getFocusMode** API in CaptureSession from asynchronous callback and asynchronous promise to the synchronous mode. Therefore, the original APIs **getFocusMode(callback: AsyncCallback<FocusMode>): void** and **getFocusMode(): Promise<FocusMode>** are changed to **getFocusMode(): FocusMode**.
The sample code is as follows:
```
let afMode = captureSession.getFocusMode();
```
31. Changed the return modes of the **setFocusMode** API in CaptureSession from asynchronous callback and asynchronous promise to the synchronous mode. Therefore, the original APIs **setFocusMode(afMode: FocusMode, callback: AsyncCallback<void>): void** and **setFocusMode(afMode: FocusMode): Promise<void>** are changed to **setFocusMode(afMode: FocusMode): void**.
The sample code is as follows:
```
captureSession.setFocusMode(camera.FocusMode.FOCUS_MODE_AUTO);
```
32. Changed the return modes of the **setFocusPoint** API in CaptureSession from asynchronous callback and asynchronous promise to the synchronous mode. Therefore, the original APIs **setFocusPoint(point: Point, callback: AsyncCallback<void>): void** and **setFocusPoint(point: Point): Promise<void>** are changed to **setFocusPoint(point: Point): void**.
The sample code is as follows:
```
let Point2 = {x: 2, y: 2};
captureSession.setFocusPoint(Point2);
```
33. Changed the return modes of the **getFocusPoint** API in CaptureSession from asynchronous callback and asynchronous promise to the synchronous mode. Therefore, the original APIs **getFocusPoint(callback: AsyncCallback<Point>): void** and **getFocusPoint(): Promise<Point>** are changed to **getFocusPoint(): Point**.
The sample code is as follows:
```
let point = captureSession.getFocusPoint();
```
34. Changed the return modes of the **getFocalLength** API in CaptureSession from asynchronous callback and asynchronous promise to the synchronous mode. Therefore, the original APIs **getFocalLength(callback: AsyncCallback<number>): void** and **getFocalLength(): Promise<number>** are changed to **getFocalLength(): number**.
The sample code is as follows:
```
let focalLength = captureSession.getFocalLength();
```
35. Changed the return modes of the **getZoomRatioRange** API in CaptureSession from asynchronous callback and asynchronous promise to the synchronous mode. Therefore, the original APIs **getZoomRatioRange(callback: AsyncCallback<Array<number>>): void** and **getZoomRatioRange(): Promise<Array<number>>** are changed to **getZoomRatioRange(): Array<number>**.
The sample code is as follows:
```
let zoomRatioRange = captureSession.getZoomRatioRange();
```
36. Changed the return modes of the **getZoomRatio** API in CaptureSession from asynchronous callback and asynchronous promise to the synchronous mode. Therefore, the original APIs **getZoomRatio(callback: AsyncCallback<number>): void** and **getZoomRatio(): Promise<number>** are changed to **getZoomRatio(): number**.
The sample code is as follows:
```
let zoomRatio = captureSession.getZoomRatio();
```
37. Changed the return modes of the **setZoomRatio** API in CaptureSession from asynchronous callback and asynchronous promise to the synchronous mode. Therefore, the original APIs **setZoomRatio(zoomRatio: number, callback: AsyncCallback<void>): void** and **setZoomRatio(zoomRatio: number): Promise<void>** are changed to **setZoomRatio(zoomRatio: number): void**.
The sample code is as follows:
```
let zoomRatio = zoomRatioRange[0];
captureSession.setZoomRatio(zoomRatio);
```
38. Changed the return modes of the **isVideoStabilizationModeSupported** API in CaptureSession from asynchronous callback and asynchronous promise to the synchronous mode. Therefore, the original APIs **isVideoStabilizationModeSupported(vsMode: VideoStabilizationMode, callback: AsyncCallback<boolean>): void** and **isVideoStabilizationModeSupported(vsMode: VideoStabilizationMode): Promise<boolean>** are changed to **isVideoStabilizationModeSupported(vsMode: VideoStabilizationMode): boolean**.
The sample code is as follows:
```
let isSupported = captureSession.isVideoStabilizationModeSupported(camera.VideoStabilizationMode.OFF);
```
39. Changed the return modes of the **getActiveVideoStabilizationMode** API in CaptureSession from asynchronous callback and asynchronous promise to the synchronous mode. Therefore, the original APIs **getActiveVideoStabilizationMode(callback: AsyncCallback<VideoStabilizationMode>): void** and **getActiveVideoStabilizationMode(): Promise<VideoStabilizationMode>** are changed to **getActiveVideoStabilizationMode(): VideoStabilizationMode**.
The sample code is as follows:
```
let vsMode = captureSession.getActiveVideoStabilizationMode();
```
40. Changed the return modes of the **setVideoStabilizationMode** API in CaptureSession from asynchronous callback and asynchronous promise to the synchronous mode. Therefore, the original APIs **setVideoStabilizationMode(mode: VideoStabilizationMode, callback: AsyncCallback<void>): void** and **setVideoStabilizationMode(mode: VideoStabilizationMode): Promise<void>** are changed to **setVideoStabilizationMode(mode: VideoStabilizationMode): void**.
The sample code is as follows:
```
captureSession.setVideoStabilizationMode(camera.VideoStabilizationMode.OFF);
```
41. Changed the **on(type:'error') callback** type in CaptureSession from **ErrorCallback<CaptureSessionError>** to **ErrorCallback<BusinessError>**. Therefore, the original API **on(type: 'error', callback: ErrorCallback<CaptureSessionError>): void** is changed to **on(type: 'error', callback: ErrorCallback<BusinessError>): void**.
The sample code is as follows:
```
captureSession.on('error', (BusinessError) => {
})
```
42. Changed the **on(type:'error') callback** type in PreviewOutput, from **ErrorCallback<PreviewOutputError>** to **ErrorCallback<BusinessError>**. Therefore, the original API **on(type: 'error', callback: ErrorCallback<PreviewOutputError>): void** is changed to **on(type: 'error', callback: ErrorCallback<BusinessError>): void**.
The sample code is as follows:
```
previewOutput.on('error', (BusinessError) => {
})
```
43. Changed the return modes of the **isMirrorSupported** API in PhotoOutput from asynchronous callback and asynchronous promise to the synchronous mode. Therefore, the original APIs **isMirrorSupported(callback: AsyncCallback<boolean>): void** and **isMirrorSupported(): Promise<boolean>** are changed to **isMirrorSupported(): boolean**.
The sample code is as follows:
```
let isSupported = photoOutput.isMirrorSupported();
```
44. Changed the **on(type:'error') callback** type in PhotoOutput, from **ErrorCallback<PhotoOutputError>** to **ErrorCallback<BusinessError>**. Therefore, the original API **on(type: 'error', callback: ErrorCallback<PhotoOutputError>): void** is changed to **on(type: 'error', callback: ErrorCallback<BusinessError>): void**.
The sample code is as follows:
```
PhotoOutput.on('error', (BusinessError) => {
})
```
45. Changed the **on(type:'error') callback** type in VideoOutput, from **ErrorCallback<VideoOutputError>** to **ErrorCallback<BusinessError>**. Therefore, the original API **on(type: 'error', callback: ErrorCallback<VideoOutputError>): void** is changed to **on(type: 'error', callback: ErrorCallback<BusinessError>): void**.
The sample code is as follows:
```
VideoOutput.on('error', (BusinessError) => {
})
```
46. Changed the **on(type:'error') callback** type in MetadataOutput, from **ErrorCallback<MetadataOutputError>** to **ErrorCallback<BusinessError>**. Therefore, the original API **on(type: 'error', callback: ErrorCallback<MetadataOutputError>): void** is changed to **on(type: 'error', callback: ErrorCallback<BusinessError>): void**.
The sample code is as follows:
```
MetadataOutput.on('error', (BusinessError) => {
})
```
\ No newline at end of file
# ChangeLog of NFC JS API Changes in the Communication Subsystem
Compared with OpenHarmony 3.2 Beta4, OpenHarmony 3.2.10.2(Mr) has the following API changes in the distributed data management subsystem.
## cl.nfc.1 API Change
Some NFC JS APIs in API versions 6 to 8 cannot throw error codes and need to be deprecated and deleted, and then APIs in API version 9 are used instead.
You need to adapt your application based on the following information.
**Change Impacts**
Some JS APIs in API versions 6 to 8 are affected. Your application needs to adapt new APIs so that it can properly implement functions in the SDK environment of the new version.
**Key API/Component Changes**
| Module | Class | Method/Attribute/Enumeration/Constant| Change Type|
| -------------------------------- | ------------- | ------------------- | -------- |
| api/@ohos.nfc.cardEmulation.d.ts | cardEmulation | FeatureType | Deprecated |
| api/@ohos.nfc.cardEmulation.d.ts | cardEmulation | isSupported | Deprecated |
| api/@ohos.nfc.cardEmulation.d.ts | cardEmulation | hasHceCapability | Added |
| api/@ohos.nfc.controller.d.ts | nfcController | isNfcAvailable | Deprecated |
| api/@ohos.nfc.controller.d.ts | nfcController | openNfc | Deprecated |
| api/@ohos.nfc.controller.d.ts | nfcController | closeNfc | Deprecated |
| api/@ohos.nfc.controller.d.ts | nfcController | enableNfc | Added |
| api/@ohos.nfc.controller.d.ts | nfcController | disableNfc | Added |
| api/@ohos.nfc.tag.d.ts | tag | getNfcATag | Deprecated |
| api/@ohos.nfc.tag.d.ts | tag | getNfcBTag | Deprecated |
| api/@ohos.nfc.tag.d.ts | tag | getNfcFTag | Deprecated |
| api/@ohos.nfc.tag.d.ts | tag | getNfcVTag | Deprecated |
| api/@ohos.nfc.tag.d.ts | tag | getNfcA | Added |
| api/@ohos.nfc.tag.d.ts | tag | getNfcB | Added |
| api/@ohos.nfc.tag.d.ts | tag | getNfcF | Added |
| api/@ohos.nfc.tag.d.ts | tag | getNfcV | Added |
| api/tag/tagSession.d.ts | TagSession | getTagInfo | Deprecated |
| api/tag/tagSession.d.ts | TagSession | connectTag | Deprecated |
| api/tag/tagSession.d.ts | TagSession | reset | Deprecated |
| api/tag/tagSession.d.ts | TagSession | isTagConnected | Deprecated |
| api/tag/tagSession.d.ts | TagSession | setSendDataTimeout | Deprecated |
| api/tag/tagSession.d.ts | TagSession | getSendDataTimeout | Deprecated |
| api/tag/tagSession.d.ts | TagSession | sendData | Deprecated |
| api/tag/tagSession.d.ts | TagSession | getMaxSendLength | Deprecated |
| api/tag/tagSession.d.ts | TagSession | connect | Added |
| api/tag/tagSession.d.ts | TagSession | resetConnection | Added |
| api/tag/tagSession.d.ts | TagSession | isConnected | Added |
| api/tag/tagSession.d.ts | TagSession | setTimeout | Added |
| api/tag/tagSession.d.ts | TagSession | getTimeout | Added |
| api/tag/tagSession.d.ts | TagSession | transmit | Added |
| api/tag/tagSession.d.ts | TagSession | getMaxTransmitSize | Added |
**Adaptation Guide**
View the following API references:
[@ohos.nfc.cardEmulation (Standard NFC Card Emulation)](https://gitee.com/openharmony/docs/blob/master/en/application-dev/reference/apis/js-apis-cardEmulation.md)
[@ohos.nfc.controller (Standard NFC)](https://gitee.com/openharmony/docs/blob/master/en/application-dev/reference/apis/js-apis-nfcController.md)
[@ohos.nfc.tag (Standard NFC Tags)](https://gitee.com/openharmony/docs/blob/master/en/application-dev/reference/apis/js-apis-nfcTag.md)
[tagSession (Standard NFC Tag Session)](https://gitee.com/openharmony/docs/blob/master/en/application-dev/reference/apis/js-apis-tagSession.md)
```
```
# Resource Scheduler Subsystem ChangeLog
## cl.resourceschedule.backgroundTaskManager
Rectified the original APIs of **backgroundTaskManager** of the resource scheduler subsystem. All APIs of API version 9 in the **@ohos.backgroundTaskManager.d.ts** file are deleted, and the APIs of API version 9 in the **@ohos.resourceschedule.backgroundTaskManager.d.ts** file are used. The new APIs in API version 9 comply with the error code specifications.
**Change Impacts**
If your application is developed based on the SDK versions of OpenHarmony 3.2.10.5 and later, adapt to the modules and APIs in API version 9 and the pattern for returning error codes. Otherwise, the service logic will be affected.
**Key API/Component Changes**
The following methods, attributes, enums, and constants are changed in API version 9 and later versions. All the APIs in the **@ohos.backgroundTaskManager.d.ts** file are migrated to the **@ohos.resourceschedule.backgroundTaskManager.d.ts** file.
| Class| API Type| Declaration| Description|
| -- | -- | -- | -- |
| backgroundTaskManager | method | function resetAllEfficiencyResources(): void; | Deleted in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager | method | function applyEfficiencyResources(request: EfficiencyResourcesRequest): bool; | Changed in API version 9 to **function applyEfficiencyResources(request: EfficiencyResourcesRequest): void;** and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager.ResourceType | enum | export enum ResourceType | Deleted in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager.ResourceType | enum | CPU = 1 | Deleted in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager.ResourceType | enum | COMMON_EVENT = 1 << 1 | Deleted in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager.ResourceType | enum | TIMER = 1 << 2 | Deleted in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager.ResourceType | enum | WORK_SCHEDULER = 1 << 3 | Deleted in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager.ResourceType | enum | BLUETOOTH = 1 << 4 | Deleted in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager.ResourceType | enum | GPS = 1 << 5 | Deleted in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager.ResourceType | enum | AUDIO = 1 << 6 | Deleted in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager.EfficiencyResourcesRequest | interface | export interface EfficiencyResourcesRequest | Deleted in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager.EfficiencyResourcesRequest | field | reason: string | Deleted in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager.EfficiencyResourcesRequest | field | isProcess?: bool | Deleted in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager.EfficiencyResourcesRequest | field | isPersist?: bool | Deleted in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager.EfficiencyResourcesRequest | field | timeOut: number | Deleted in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager.EfficiencyResourcesRequest | field | isApply: bool | Deleted in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager.EfficiencyResourcesRequest | field | resourceTypes: number | Deleted in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
**Adaptation Guide**
Import the **backgroundTaskManager** module.
```
import bundle form '@ohos.resourceschedule.backgroundTaskManager'
```
Exception handling also needs to be adapted. For details, see the [backgroundTaskManager API reference](../../../application-dev/reference/apis/js-apis-resourceschedule-backgroundTaskManager.md).
## c2.resourceschedule.workScheduler
Rectified the original APIs of **workScheduler** of the resource scheduler subsystem. All APIs of API version 9 in the **@ohos.workScheduler.d.ts** file are deleted, and the APIs of API version 9 in the **@ohos.resourceschedule.workScheduler.d.ts** file are used. The new APIs in API version 9 comply with the error code specifications.
**Change Impacts**
If your application is developed based on the SDK versions of OpenHarmony 3.2.10.5 and later, adapt to the modules and APIs in API version 9 and the pattern for returning error codes. Otherwise, the service logic will be affected.
**Key API/Component Changes**
The following methods, attributes, enums, and constants are changed in API version 9 and later versions. The **@ohos.workScheduler.d.ts** file is deleted, and all the APIs in it are moved to the **@ohos.resourceschedule.workScheduler.d.ts** file.
| Class| API Type| Declaration| Change Type|
| -- | -- | -- | -- |
| workScheduler | namespace | declare namespace workScheduler | Deleted in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.WorkInfo | interface | export interface WorkInfo | Deleted in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.WorkInfo | field | parameters?: {[key: string]: any} | Deleted in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.WorkInfo | field | idleWaitTime?: number | Deleted in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.WorkInfo | field | isDeepIdle?: boolean | Deleted in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.WorkInfo | field | repeatCount?: number | Deleted in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.WorkInfo | field | isRepeat?: boolean | Deleted in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.WorkInfo | field | repeatCycleTime?: number | Deleted in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.WorkInfo | field | storageRequest?: StorageRequest | Deleted in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.WorkInfo | field | batteryStatus?: BatteryStatus | Deleted in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.WorkInfo | field | batteryLevel?: number | Deleted in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.WorkInfo | field | chargerType?: ChargingType | Deleted in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.WorkInfo | field | isCharging?: boolean | Deleted in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.WorkInfo | field | networkType?: NetworkType | Deleted in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.WorkInfo | field | isPersisted?: boolean | Deleted in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.WorkInfo | field | abilityName: string | Deleted in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.WorkInfo | field | bundleName: string | Deleted in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.WorkInfo | field | workId: number | Deleted in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler | method | function isLastWorkTimeOut(workId: number): Promise; | Deleted in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler | method | function isLastWorkTimeOut(workId: number, callback: AsyncCallback<void>): boolean; | Deleted in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler | method | function stopAndClearWorks(): boolean; | Changed in API version 8 to **function stopAndClearWorks(): boolean;** and moved to the **ohos.resourceschedule.workScheduler.d.ts** file|
| workScheduler | method | function obtainAllWorks(): Promise<Array<WorkInfo>>; | Deleted in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler | method | function obtainAllWorks(callback: AsyncCallback<void>): Array<WorkInfo>; | Deleted in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler | method | function getWorkStatus(workId: number): Promise<WorkInfo>; | Deleted in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler | method | function getWorkStatus(workId: number, callback: AsyncCallback<WorkInfo>): void; | Deleted in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler | method | function stopWork(work: WorkInfo, needCancel?: boolean): boolean; | Changed in API version 8 to **function stopWork(work: WorkInfo, needCancel?: boolean): void;** and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler | method | function startWork(work: WorkInfo): boolean; | Changed in API version 9 to **function startWork(work: WorkInfo): void;** and moved to the **ohos.resourceschedule.workScheduler.d.ts** file|
| workScheduler.NetworkType | enum | export enum NetworkType | Deleted in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.NetworkType | enum | NETWORK_TYPE_ANY = 0 | Deleted in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.NetworkType | enum | NETWORK_TYPE_MOBILE | Deleted in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.NetworkType | enum | NETWORK_TYPE_WIFI | Deleted in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.NetworkType | enum | NETWORK_TYPE_BLUETOOTH | Deleted in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.NetworkType | enum | NETWORK_TYPE_WIFI_P2P | Deleted in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.NetworkType | enum | NETWORK_TYPE_ETHERNET | Deleted in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.ChargingType | enum | export enum ChargingType | Deleted in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.ChargingType | enum | CHARGING_PLUGGED_ANY = 0 | Deleted in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.ChargingType | enum | CHARGING_PLUGGED_AC | Deleted in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.ChargingType | enum | CHARGING_PLUGGED_USB | Deleted in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.ChargingType | enum | CHARGING_PLUGGED_WIRELESS | Deleted in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.BatteryStatus | enum | export enum BatteryStatus | Deleted in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.BatteryStatus | enum | BATTERY_STATUS_LOW = 0 | Deleted in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.BatteryStatus | enum | BATTERY_STATUS_OKAY | Deleted in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.BatteryStatus | enum | BATTERY_STATUS_LOW_OR_OKAY | Deleted in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.StorageRequest | enum | export enum StorageRequest | Deleted in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.BatteryStatus | enum | STORAGE_LEVEL_LOW = 0 | Deleted in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.BatteryStatus | enum | STORAGE_LEVEL_OKAY | Deleted in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.BatteryStatus | enum | STORAGE_LEVEL_LOW_OR_OKAY | Deleted in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
**Adaptation Guide**
Import the **workScheduler** module.
```
import bundle form '@ohos.resourceschedule.workScheduler'
```
Exception handling also needs to be adapted. For details, see the [workScheduler API reference](../../../application-dev/reference/apis/js-apis-resourceschedule-workScheduler.md).
# ArkUI Subsystem ChangeLog
## cl.arkui.1 Restrictions on Data Type Declarations of State Variables
1. The data types of state variables decorated by state decorators must be explicitly declared. They cannot be declared as **any** or **Date**.
Example:
```ts
// xxx.ets
@Entry
@Component
struct DatePickerExample {
// Incorrect: @State isLunar: any = false
@State isLunar: boolean = false
// Incorrect: @State selectedDate: Date = new Date('2021-08-08')
private selectedDate: Date = new Date('2021-08-08')
build() {
Column() {
Button('Switch Calendar')
.margin({ top: 30 })
.onClick(() => {
this.isLunar = !this.isLunar
})
DatePicker({
start: new Date('1970-1-1'),
end: new Date('2100-1-1'),
selected: this.selectedDate
})
.lunar(this.isLunar)
.onChange((value: DatePickerResult) => {
this.selectedDate.setFullYear(value.year, value.month, value.day)
console.info('select current date is: ' + JSON.stringify(value))
})
}.width('100%')
}
}
```
![datePicker](../../../application-dev/reference/arkui-ts/figures/datePicker.gif)
2. The data type declaration of the **@State**, **@Provide**, **@Link**, or **@Consume** decorated state variables can consist of only one of the primitive data types or reference data types.
The **Length**, **ResourceStr**, and **ResourceColor** types are combinations of primitive data types or reference data types. Therefore, they cannot be used by the aforementioned types of state variables.
For details about the definitions of **Length**, **ResourceStr**, and **ResourceColor**, see [Types](../../../application-dev/reference/arkui-ts/ts-types.md).
Example:
```ts
// xxx.ets
@Entry
@Component
struct IndexPage {
// Incorrect: @State message: string | Resource = 'Hello World'
@State message: string = 'Hello World'
// Incorrect: @State message: ResourceStr = $r('app.string.hello')
@State resourceStr: Resource = $r('app.string.hello')
build() {
Row() {
Column() {
Text(`${this.message}`)
.fontSize(50)
.fontWeight(FontWeight.Bold)
}
.width('100%')
}
.height('100%')
}
}
```
![hello](../../../application-dev/quick-start/figures/hello.PNG)
**Change Impacts**
1. If the data type of a state variable decorated by a state decorator is declared as **any**, a build error will occur.
```ts
// ArkTS:ERROR Please define an explicit type, not any.
@State isLunar: any = false
```
2. If the data type of a state variable decorated by a state decorator is declared as **Date**, a build error will occur.
```ts
// ArkTS:ERROR The @State property 'selectedDate' cannot be a 'Date' object.
@State selectedDate: Date = new Date('2021-08-08')
```
3. If the data type of a **@State**, **@Provide**, **@Link**, and or **@Consume** decorated state variable is Length, **ResourceStr**, or **ResourceColor**, a build error will occur.
```ts
/* ArkTS:ERROR The state variable type here is 'ResourceStr', it contains both a simple type and an object type,
which are not allowed to be defined for state variable of a struct.*/
@State message: ResourceStr = $r('app.string.hello')
```
**Key API/Component Changes**
N/A
**Adaptation Guide**
1. Explicitly declare the data type for state variables decorated by state decorators.
2. If a state variable decorated by a state decorator uses the **Date** object, change it to a regular variable – a variable not decorated by any decorator.
3. Adapt the **@State**, **@Provide**, **@Link**, and **@Consume** decorated variables based on the following code snippet so that they do not use the **Length(string|number|Resource)**, **ResourceStr(string|Resource)**, and **ResourceColor(string|number|Color|Resource)** types:
```ts
// Incorrect:
@State message: ResourceStr = $r('app.string.hello')
// Corrected:
@State resourceStr: Resource = $r('app.string.hello')
```
## cl.arkui.2 Initialization Rules and Restrictions of Custom Components' Member Variables
Comply with the following rules when using constructors to initialize member variables:
| **From the Variable in the Parent Component (Right) to the Variable in the Child Component (Below)**| **regular** | **@State** | **@Link** | **@Prop** | **@Provide** | **@Consume** | **@ObjectLink** |
|---------------------------------|----------------------------|------------|-----------|-----------|--------------|--------------|------------------|
| **regular** | Supported | Supported | Supported | Supported | Not supported | Not supported | Supported |
| **@State** | Supported | Supported | Supported | Supported | Supported | Supported | Supported |
| **@Link** | Not supported | Supported (1) | Supported (1) | Supported (1) | Supported (1) | Supported (1) | Supported (1) |
| **@Prop** | Supported | Supported | Supported | Supported | Supported | Supported | Supported |
| **@Provide** | Supported | Supported | Supported | Supported | Supported | Supported | Supported |
| **@Consume** | Not supported | Not supported | Not supported | Not supported | Not supported | Not supported | Not supported |
| **@ObjectLink** | Not supported | Not supported | Not supported | Not supported | Not supported | Not supported | Not supported |
| **From the Variable in the Parent Component (Right) to the Variable in the Child Component (Below)**| **@StorageLink** | **@StorageProp** | **@LocalStorageLink** | **@LocalStorageProp** |
|------------------|------------------|------------------|-----------------------|------------------------|
| **regular** | Supported | Not supported | Not supported | Not supported |
| **@State** | Supported | Supported | Supported | Supported |
| **@Link** | Supported (1) | Supported (1) | Supported (1) | Supported (1) |
| **@Prop** | Supported | Supported | Supported | Supported |
| **@Provide** | Supported | Supported | Supported | Supported |
| **@Consume** | Not supported | Not supported | Not supported | Not supported |
| **@ObjectLink** | Not supported | Not supported | Not supported | Not supported |
> **NOTE**
>
> **Supported (1)**: The dollar sign ($) must be used, for example, **this.$varA**.
>
> **regular**: refers to a regular variable that is not decorated by any decorator.
**@StorageLink**, **@StorageProp**, **@LocalStorageLink**, and **@LocalStorageProp** variables cannot be initialized from the parent component.
**Change Impacts**
1. Variables decorated by **@LocalStorageLink** and **@LocalStorageProp** cannot be initialized from the parent component.
```ts
@Entry
@Component
struct LocalStorageComponent {
build() {
Column() {
Child({
/* ArkTS:ERROR Property 'simpleVarName' in the custom component 'Child' cannot
initialize here (forbidden to specify). */
simpleVarName: 1,
/* ArkTS:ERROR Property 'objectName' in the custom component 'Child' cannot
initialize here (forbidden to specify). */
objectName: new ClassA("x")
})
}
}
}
@Component
struct Child {
@LocalStorageLink("storageSimpleProp") simpleVarName: number = 0;
@LocalStorageProp("storageObjectProp") objectName: ClassA = new ClassA("x");
build() {}
}
```
2. The **@ObjectLink** decorated variable cannot be directly initialized from a decorated variable in the parent component. The source of the parent component must be an array item or object attribute decorated by **@State**, **@Link**, **@Provide**, **@Consume**, or **@ObjectLink**.
```ts
let NextID : number = 0;
@Observed class ClassA {
public id : number;
public c: number;
constructor(c: number) {
this.id = NextID++;
this.c = c;
}
}
@Component
struct Child {
@ObjectLink varA : ClassA;
build() {
Row() {
Text('ViewA-' + this.varA.id)
}
}
}
@Component
struct Parent {
@Link linkValue: ClassA
build() {
Column() {
/* ArkTS:ERROR The @Link property 'linkValue' cannot be assigned to
the @ObjectLink property 'varA'.*/
Child({ varA: this.linkValue })
}
}
}
```
**Key API/Component Changes**
N/A
**Adaptation Guide**
1. When building a child component, do not perform the build on the variables decorated by **@LocalStorageLink** and **@LocalStorageProp** in the child component.
To change these variables from the parent component, use the API provided by the **LocalStorage** (such as the **set** API) to assign values to them.
2. For details about how to use **@ObjectLink**, see [@Observed and @ObjectLink](../../../application-dev/quick-start/arkts-observed-and-objectlink.md).
# Bundle Manager Subsystem ChangeLog
## cl.bundlemanager.1 Changed Underlying Capability by Adding Verification to bundle-name in the Signing Certification During Application Installation
During application installation, the **bundle-name** field in the [signing certificate profile](../../../application-dev/security/app-provision-structure.md) is verified against the bundle name of the application.
If the value of **bundle-name** is different from the value of **bundleName** in the application configuration file, the installation fails and the following error information is displayed:
```
error: verify signature failed.
```
**Change Impact**
For applications using system images of 3.2.10.5 or later, if the **bundle-name** field in the signing certificate profile is different from the bundle name of the application, application installation fails. This change has no impact on applications using system images earlier than 3.2.10.5.
**Key API/Component Changes**
No API or component change is involved.
**Adaptation Guide**
If "error: verify signature failed" is displayed, change **bundle-name** in the signing certificate profile to the bundle name of the application, generate a new signing certificate (with the file name extension .p7b), and sign the application again.
For details about how to use the signing tool and generate a signing certificate, see [hapsigner Guide](../../../application-dev/security/hapsigntool-guidelines.md).
## cl.bundlemanager.2 Changed Underlying Capability by Adding Control over Applications Without Entry Icons
If no entry icon is configured for an application that has not requested the **AllowHideDesktopIcon** privilege, a default icon is displayed on the home screen. Any click on the icon redirects to the application details page. An application is determined to have no entry icon in either of the following scenarios:
1. The **abilities** field is not configured for the application.
2. The **abilities** field is configured for the application, but the **skills** field under the ability of any page type does not contain both **ohos.want.action.home** and **entity.system.home**, as follows:
```json
"skills": [
{
"actions": [
"ohos.want.action.home"
],
"entities": [
"entity.system.home"
]
}
]
```
If the application installation mode is **hdc_std install** or **bm install**, a default icon is displayed for the application on the home screen.
If your application does not need an icon to be displayed on the home screen, request the **AllowHideDesktopIcon** privilege and configure it in the signing certificate or trustlist (**install_list_capability.json**). For details, see [Application Privilege Configuration Guide](../../../device-dev/subsystems/subsys-app-privilege-config-guide.md).
If your application needs an icon to be displayed on the home screen, select an ability from **abilities** and configure its **skills** field to contain both **ohos.want.action.home** and **entity.system.home**.
**Change Impact**
For applications using system images of 3.2.10.5 and later versions, if no entry icon is configured for an application, the default icon is displayed on the home screen when the application is installed using the CLI. This change has no impact on applications using system images earlier than 3.2.10.5.
**Key API/Component Changes**
No API or component change is involved.
**Adaptation Guide**
If your application does not need an icon to be displayed on the home screen, request the **AllowHideDesktopIcon** privilege and configure it in the signing certificate or trustlist (**install_list_capability.json**). For details, see [Application Privilege Configuration Guide](../../../device-dev/subsystems/subsys-app-privilege-config-guide.md).
If your application needs an icon to be displayed on the home screen, select an ability from **abilities** and configure its **skills** field to contain both **ohos.want.action.home** and **entity.system.home**.
## cl.bundlemanager.3 Changed Underlying Capability by Restricting AllowAppUsePrivilegeExtension, AllowAppMultiProcess, and AllowFormVisibleNotify from Being Configured in the Signing Certificate
The **AllowAppUsePrivilegeExtension**, **AllowAppMultiProcess**, and **AllowFormVisibleNotify** privileges can no longer be configured in the signing certificate. They can be requested only through the trustlist (**install_list_capability.json**). If your application requests these privileges in the signing certificate, the installation may fail or the privileges may be invalid.
If the following error information is displayed, adapt to the new privilege configuration method. For details, see [Application Privilege Configuration Guide](../../../device-dev/subsystems/subsys-app-privilege-config-guide.md).
```
error: install parse profile prop check error.
```
For the XTS or local debugging demo, if the **install_list_capability.json** file on the development board cannot be modified, you can change the bundle name of the application to start with **com.acts.** and request the privileges in the signing certificate.
The **AllowAppUsePrivilegeExtension** privilege is requested by configuring it under the **extensionAbilities** field, with the **type** attribute set to **dataShare** or **service**, in the application configuration file. If this privilege is not configured, the installation fails.
**Change Impact**
For applications using system images of 3.2.10.5 or later, if the required privileges are not requested using the trustlist (**install_list_capability.json**), application installation may fail. This change has no impact on applications using system images earlier than 3.2.10.5.
**Key API/Component Changes**
No API or component change is involved.
**Adaptation Guide**
If the following error information is displayed, adapt to the new privilege configuration method. For details, see [Application Privilege Configuration Guide](../../../device-dev/subsystems/subsys-app-privilege-config-guide.md).
```
error: install parse profile prop check error.
```
For the XTS or local debugging demo, if the **install_list_capability.json** file on the development board cannot be modified, you can change the bundle name of the application to start with **com.acts.** and request the privileges in the signing certificate.
## cl.bundlemanager.4 Changed Underlying Capability by Not Decompressing the HAP During HAP Installation
The HAP will no longer be decompressed during installation. After the installation is complete, only the HAP file exists in the installation directory. As a result, the application must use the standard resource management interface, rather than a combined path, to access a resource file.
**Change Impact**
If the application uses a combined path to access a resource file, the access fails. It must use the resource management interface.
**Key API/Component Changes**
No API or component change is involved.
**Adaptation Guide**
The resource management subsystem provides the JS interface for accessing resource files. Reference: [Accessing Resource Files](../../../application-dev/reference/apis/js-apis-resource-manager.md#getrawfilecontent9)
\ No newline at end of file
# File Management Subsystem Changelog
## cl.filemanagement.1 environment Module Change
The file management subsystem **d.ts** file has been archived and moved to the **file** directory. The **environment** module supports error code processing.
**Change Impact**
If your application is developed based on earlier versions, note that the **d.ts** file location and the name of the module to be imported are changed. The **environment** module supports error code processing. See [Adaptation Guide](../OpenHarmony_3.2.8.1/changelogs-filemanagement.md) for more details.
**Key API/Component Changes**
Before the change, **environment** is imported from **@ohos.environment**:
```js
import environment from '@ohos.environment';
```
Now, **environment** is imported from **@ohos.file.environment**:
```js
import environment from '@ohos.file.environment';
```
## cl.filemanagement.2 securityLabel Change
Moved the file management subsystem **d.ts** file to the **file** directory. The **securityLabel** module supports error code processing.
**Change Impact**
If your application is developed based on earlier versions, note that the **d.ts** file location and the name of the module to be imported are changed. The **securityLabel** module supports error code processing. See [Adaptation Guide](../OpenHarmony_3.2.8.1/changelogs-filemanagement.md) for more details.
**Key API/Component Changes**
Before the change, **securityLabel** is imported from **@ohos.securityLabel**:
```js
import securityLabel from '@ohos.securityLabel';
```
Now, **securityLabel** is imported from **@ohos.file.securityLabel**:
```js
import securityLabel from '@ohos.file.securityLabel';
```
## cl.filemanagement.3 fs Change
Changed the **ino** attribute type of **Stat** under **fs**.
**Change Impact**
The **ino** attribute type is changed from number to BigInt, to adapt to the **inode** range of all types of files in the file system.
**Key API/Component Changes**
The type of the **ino** attribute of **Stat** is changed from number to BigInt.
## cl.filemanagement.4 fileAccess Change
Moved the file management subsystem **d.ts** file to the **file** directory. The **fileAccess** module supports error code processing.
**Change Impact**
If your application is developed based on earlier versions, note that the **d.ts** file location and the name of the module to be imported are changed. The **fileAccess** module supports error code processing. See [Adaptation Guide](../OpenHarmony_3.2.8.1/changelogs-filemanagement.md) for more details.
**Key API/Component Changes**
Before the change, **fileAccess** is imported from **@ohos.data.fileAccess**:
```js
import fileAccess from '@ohos.data.fileAccess';
```
Now, **fileAccess** is imported from **@ohos.file.fileAccess**:
```js
import fileAccess from '@ohos.file.fileAccess';
```
## cl.filemanagement.5 fileExtensionInfo Change
Moved the file management subsystem **d.ts** file to the **file** directory. The **fileExtensionInfo** module supports error code processing.
**Change Impact**
If your application is developed based on earlier versions, note that the **d.ts** file location and the name of the module to be imported are changed. The **fileExtensionInfo** module supports error code processing. See [Adaptation Guide](../OpenHarmony_3.2.8.1/changelogs-filemanagement.md) for more details.
**Key API/Component Changes**
Before the change, **fileExtensionInfo** is imported from **@ohos.fileExtensionInfo**:
```js
import fileExtensionInfo from '@ohos.fileExtensionInfo';
```
Now, **fileExtensionInfo** is imported from **@ohos.file.fileExtensionInfo**:
```js
import fileExtensionInfo from '@ohos.file.fileExtensionInfo';
```
## cl.filemanagement.6 storageStatistics Change
Moved the file management subsystem **d.ts** file to the **file** directory. The **fileExtensionInfo** module supports error code processing.
**Change Impact**
If your application is developed based on earlier versions, note that the **d.ts** file location and the name of the module to be imported are changed. The **storageStatistics** module supports error code processing. See [Adaptation Guide](../OpenHarmony_3.2.8.1/changelogs-filemanagement.md) for more details.
**Key API/Component Changes**
Before the change, **storageStatistics** was imported from **@ohos.storageStatistics**:
```js
import storageStatistics from '@ohos.storageStatistics';
```
Now, **storageStatistics** is imported from **@ohos.file.storageStatistics**:
```js
import storageStatistics from '@ohos.file.storageStatistics';
```
## cl.filemanagement.7 volumeManager Change
Moved the file management subsystem **d.ts** file to the **file** directory. The **fileExtensionInfo** module supports error code processing.
**Change Impact**
If your application is developed based on earlier versions, note that the **d.ts** file location and the name of the module to be imported are changed. The **volumeManager** module supports error code processing. See [Adaptation Guide](../OpenHarmony_3.2.8.1/changelogs-filemanagement.md) for more details.
**Key API/Component Changes**
Before the change, **volumeManager** was imported from **@ohos.volumeManager**:
```js
import volumeManager from '@ohos.volumeManager';
```
Now, **volumeManager** is imported from **@ohos.file.volumeManager**:
```js
import volumeManager from '@ohos.file.volumeManager';
```
## cl.filemanagement.8 fileio API Changes
Deprecated the **fileio** APIs, which do not return error codes; added APIs that return error codes.
**Change Impact**
For applications developed based on earlier versions, pay attention to the iterative update of deprecated APIs. The specifications of the new APIs are slightly adjusted. Pay attention to the usage of the new APIs.
**Key API/Component Changes**
The APIs of **@ohos.fileio** do not support error code handling and are deprecated. New APIs with minor changes in parameters are added in **@ohos.file.fs** to support unified error code handling specifications. The new APIs function the same as the original APIs. The following table lists the API changes.
The API names remain unchanged.
| Module | Method/Attribute/Enum/Constant | Change Type|
| ------------------------- | ------------------------------------------------------------ | -------- |
| @ohos.fileio | **function** access(path: string, mode?: number, callback?: AsyncCallback\<void>): void \| Promise\<void> | Deprecated |
| @ohos.fileio | **function** accessSync(path: string, mode?: number): void | Deprecated |
| @ohos.file.fs | **function** access(path: string, callback?: AsyncCallback\<boolean>): void \| Promise\<boolean> | Added |
| @ohos.file.fs | **function** accessSync(path: string): boolean | Added |
| @ohos.fileio | **function** close(fd: number, callback?: AsyncCallback\<void>): void \| Promise\<void> | Deprecated |
| @ohos.fileio | **function** closeSync(fd: number): void | Deprecated |
| @ohos.file.fs | **function** close(file: File \| number, callback?: AsyncCallback\<void>): void \| Promise\<void> | Added |
| @ohos.file.fs | **function** closeSync(file: File \| number): void | Added |
| @ohos.fileio | **function** mkdir(path: string, mode?: number, callback?: AsyncCallback\<void>): void \| Promise\<void> | Deprecated |
| @ohos.fileio | **function** mkdirSync(path: string, mode?: number): void | Deprecated |
| @ohos.file.fs | **function** mkdir(path: string, callback?: AsyncCallback\<void>): void \| Promise\<void> | Added |
| @ohos.file.fs | **function** mkdirSync(path: string): void | Added |
| @ohos.fileio | **function** readText(filePath: string, options?: { position?: number; length?: number; encoding?: string; }, callback?: AsyncCallback\<string>): void \| Promise\<string> | Deprecated |
| @ohos.fileio | **function** readTextSync(filePath: string, options?: { position?: number; length?: number; encoding?: string; }): string | Deprecated |
| @ohos.file.fs | **function** readText(filePath: string, options?: { offset?: number; length?: number; encoding?: string; }, callback?: AsyncCallback\<string>): void \| Promise\<string> | Added |
| @ohos.file.fs | **function** readTextSync(filePath: string, options?: { offset?: number; length?: number; encoding?: string; }): string | Added |
| @ohos.fileio | **function** Stream.read(buffer: ArrayBuffer, options?: { offset?: number; length?: number; position?: number; }, callback?: AsyncCallback\<ReadOut>): void \| Promise\<ReadOut> | Deprecated |
| @ohos.fileio | **function** Stream.readSync(buffer: ArrayBuffer, options?: { offset?: number; length?: number; position?: number; }): number | Deprecated |
| @ohos.file.fs | **function** Stream.read(fd: number, buffer: ArrayBuffer, options?: { offset?: number; length?: number; }, callback?: AsyncCallback\<number>): void \| Promise\<number> | Added |
| @ohos.file.fs | **function** Stream.readSync(fd: number, buffer: ArrayBuffer, options?: { offset?: number; length?: number; }): number | Added |
| @ohos.fileio | **function** Stream.write(buffer: ArrayBuffer \| string, options?: { offset?: number; length?: number; position?: number; encoding?: string; }, callback?: AsyncCallback\<number>): void \| Promise\<void> | Deprecated |
| @ohos.fileio | **function** Stream.writeSync(buffer: ArrayBuffer \| string, options?: { offset?: number; length?: number; position?: number; encoding?: string; }): number | Deprecated |
| @ohos.file.fs | **function** Stream.write(buffer: ArrayBuffer \| string, options?: { offset?: number; length?: number; encoding?: string; }, callback?: AsyncCallback\<number>): void \| Promise\<void> | Added |
| @ohos.file.fs | **function** Stream.writeSync(buffer: ArrayBuffer \| string, options?: { offset?: number; length?: number; encoding?: string; }): number | Added |
**Adaptation Guide**
The APIs of @ohos.file.fs support unified exception handling. For details, see [File Management](../../../application-dev/reference/apis/js-apis-file-fs.md).
# Input Method Framework ChangeLog
## cl.inputmethod_frameworks.1 API Filename Change
The following modules do not comply with the OpenHarmony API file naming rules. Therefore, they are modified in API version 9 and later.
**Change Impacts**
The SDK after the change is incompatible with the earlier versions. Therefore, adaptation is required for applications developed in earlier versions so that they can be properly built with the SDK in the new version.
**Key API/Component Changes**
| Module| File Name Before Change| File Name After Change|
|------|--------------|--------------|
| Input method framework module| @ohos.inputmethod.d.ts |@ohos.inputMethod.d.ts |
| Input method service module|@ohos.inputmethodengine.d.ts | @ohos.inputMethodEngine.d.ts |
| Input method ExtentionAbility module| @ohos.inputmethodextensionability.d.ts | @ohos.InputMethodExtensionAbility.d.ts |
| Input method ExtentionContext module|@ohos.inputmethodextensioncontext.d.ts | @ohos.InputMethodExtensionContext.d.ts |
| Input method subtype module| @ohos.inputMethodSubtype.d.ts | @ohos.InputMethodSubtype.d.ts |
**Adaptation Guide**
In the application code, change the name of the d.ts file following **import** to the new file name, which complies with the UpperCamelCase or lowerCamelCase style.
Example:
```js
import inputMethodEngine from '@ohos.inputMethodEngine';
```
# Location Subsystem ChangeLog
## cl.location.1 API Migration from @ohos.geolocation.d.ts to @ohos.geoLocationManager.d.ts
APIs in **@ohos.geolocation.d.ts** do not support throwing error codes. To support this function, all APIs in **@ohos.geolocation.d.ts** are migrated to the newly added **@ohos.geoLocationManager.d.ts** file, and corresponding error code description is added.
To use APIs of the location subsystem, you need to import **@ohos.geoLocationManager**.
import geoLocationManager from '@ohos.geoLocationManager';
**Change Impacts**
All APIs of the location subsystem are affected. To ensure normal use of these APIs, you need to import **@ohos.geoLocationManager**.
import geoLocationManager from '@ohos.geoLocationManager';
**Key API/Component Changes**
| Class | API Type | Declaration | Change Type |
| ----------- | --------- | ------------------------------------------------------------ | ------------------------------------------------------------ |
| geolocation | method | function on(type: 'locationChange', request: LocationRequest, callback: Callback<Location>): void; | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | method | function off(type: 'locationChange', callback?: Callback<Location>): void; | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | method | function on(type: 'locationServiceState', callback: Callback<boolean>): void; | Migrated to **@ohos.geoLocationManager.d.ts** and changed **type: 'locationServiceState'** to **type: 'locationEnabledChange'**.|
| geolocation | method | function off(type: 'locationServiceState', callback?: Callback<boolean>): void; | Migrated to **@ohos.geoLocationManager.d.ts** and changed **type: 'locationServiceState'** to **type: 'locationEnabledChange'**.|
| geolocation | method | function on(type: 'cachedGnssLocationsReporting', request: CachedGnssLocationsRequest, callback: Callback<Array<Location>>): void; | Migrated to **@ohos.geoLocationManager.d.ts** and changed **type: 'cachedGnssLocationsReporting'** to **type: 'cachedGnssLocationsChange'**.|
| geolocation | method | function off(type: 'cachedGnssLocationsReporting', callback?: Callback<Array<Location>>): void; | Migrated to **@ohos.geoLocationManager.d.ts** and changed **type: 'cachedGnssLocationsReporting'** to **type: 'cachedGnssLocationsChange'**.|
| geolocation | method | function on(type: 'gnssStatusChange', callback: Callback<SatelliteStatusInfo>): void; | Migrated to **@ohos.geoLocationManager.d.ts** and changed **type: 'gnssStatusChange'** to **type: 'satelliteStatusChange'**.|
| geolocation | method | function off(type: 'gnssStatusChange', callback?: Callback<SatelliteStatusInfo>): void; | Migrated to **@ohos.geoLocationManager.d.ts** and changed **type: 'gnssStatusChange'** to **type: 'satelliteStatusChange'**.|
| geolocation | method | function on(type: 'nmeaMessageChange', callback: Callback<string>): void; | Migrated to **@ohos.geoLocationManager.d.ts** and changed **type: 'nmeaMessageChange'** to **type: 'nmeaMessage'**.|
| geolocation | method | function off(type: 'nmeaMessageChange', callback?: Callback<string>): void; | Migrated to **@ohos.geoLocationManager.d.ts** and changed **type: 'nmeaMessageChange'** to **type: 'nmeaMessage'**.|
| geolocation | method | function on(type: 'fenceStatusChange', request: GeofenceRequest, want: WantAgent): void; | Migrated to **@ohos.geoLocationManager.d.ts** and changed **type: 'fenceStatusChange'** to **type: 'gnssFenceStatusChange'**.|
| geolocation | method | function off(type: 'fenceStatusChange', request: GeofenceRequest, want: WantAgent): void; | Migrated to **@ohos.geoLocationManager.d.ts** and changed **type: 'fenceStatusChange'** to **type: 'gnssFenceStatusChange'**.|
| geolocation | method | function getCurrentLocation(request: CurrentLocationRequest, callback: AsyncCallback<Location>): void; | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | method | function getCurrentLocation(callback: AsyncCallback<Location>): void; | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | method | function getCurrentLocation(request?: CurrentLocationRequest): Promise<Location>; | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | method | function getLastLocation(callback: AsyncCallback<Location>): void; | Migrated to **@ohos.geoLocationManager.d.ts** and changed to **function getLastLocation(): Location**.|
| geolocation | method | function getLastLocation(): Promise<Location>; | Migrated to **@ohos.geoLocationManager.d.ts** and changed to **function getLastLocation(): Location**.|
| geolocation | method | function isLocationEnabled(callback: AsyncCallback<boolean>): void; | Migrated to **@ohos.geoLocationManager.d.ts** and changed to **function isLocationEnabled(): boolean**.|
| geolocation | method | function isLocationEnabled(): Promise<boolean>; | Migrated to **@ohos.geoLocationManager.d.ts** and changed to **function isLocationEnabled(): boolean**.|
| geolocation | method | function requestEnableLocation(callback: AsyncCallback<boolean>): void; | Deleted. |
| geolocation | method | function requestEnableLocation(): Promise<boolean>; | Deleted. |
| geolocation | method | function enableLocation(callback: AsyncCallback<boolean>): void; | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | method | function enableLocation(): Promise<boolean>; | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | method | function disableLocation(callback: AsyncCallback<boolean>): void; | Migrated to **@ohos.geoLocationManager.d.ts** and changed to **function disableLocation(): void**.|
| geolocation | method | function disableLocation(): Promise<boolean>; | Migrated to **@ohos.geoLocationManager.d.ts** and changed to **function disableLocation(): void**.|
| geolocation | method | function getAddressesFromLocation(request: ReverseGeoCodeRequest, callback: AsyncCallback<Array<GeoAddress>>): void; | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | method | function getAddressesFromLocation(request: ReverseGeoCodeRequest): Promise<Array<GeoAddress>>; | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | method | function getAddressesFromLocationName(request: GeoCodeRequest, callback: AsyncCallback<Array<GeoAddress>>): void; | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | method | function getAddressesFromLocationName(request: GeoCodeRequest): Promise<Array<GeoAddress>>; | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | method | function isGeoServiceAvailable(callback: AsyncCallback<boolean>): void; | Migrated to **@ohos.geoLocationManager.d.ts** and changed to **function isGeocoderAvailable(): boolean**.|
| geolocation | method | function isGeoServiceAvailable(): Promise<boolean>; | Migrated to **@ohos.geoLocationManager.d.ts** and changed to **function isGeocoderAvailable(): boolean**.|
| geolocation | method | function getCachedGnssLocationsSize(callback: AsyncCallback<number>): void; | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | method | function getCachedGnssLocationsSize(): Promise<number>; | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | method | function flushCachedGnssLocations(callback: AsyncCallback<boolean>): void; | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | method | function flushCachedGnssLocations(): Promise<boolean>; | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | method | function sendCommand(command: LocationCommand, callback: AsyncCallback<boolean>): void; | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | method | function sendCommand(command: LocationCommand): Promise<boolean>; | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | method | function enableLocationMock(callback: AsyncCallback<void>): void; | Migrated to **@ohos.geoLocationManager.d.ts** and changed to **function enableLocationMock(): void**.|
| geolocation | method | function enableLocationMock(): Promise<void>; | Migrated to **@ohos.geoLocationManager.d.ts** and changed to **function enableLocationMock(): void**.|
| geolocation | method | function disableLocationMock(callback: AsyncCallback<void>): void; | Migrated to **@ohos.geoLocationManager.d.ts** and changed to **function disableLocationMock(): void**.|
| geolocation | method | function disableLocationMock(): Promise<void>; | Migrated to **@ohos.geoLocationManager.d.ts** and changed to **function disableLocationMock(): void**.|
| geolocation | method | function setMockedLocations(config: LocationMockConfig, callback: AsyncCallback<void>): void; | Migrated to **@ohos.geoLocationManager.d.ts** and changed to **function setMockedLocations(config: LocationMockConfig): void**.|
| geolocation | method | function setMockedLocations(config: LocationMockConfig): Promise<void>; | Migrated to **@ohos.geoLocationManager.d.ts** and changed to **function setMockedLocations(config: LocationMockConfig): void**.|
| geolocation | method | function enableReverseGeocodingMock(callback: AsyncCallback<void>): void; | Migrated to **@ohos.geoLocationManager.d.ts** and changed to **function enableReverseGeocodingMock(): void**.|
| geolocation | method | function enableReverseGeocodingMock(): Promise<void>; | Migrated to **@ohos.geoLocationManager.d.ts** and changed to **function enableReverseGeocodingMock(): void**.|
| geolocation | method | function disableReverseGeocodingMock(callback: AsyncCallback<void>): void; | Migrated to **@ohos.geoLocationManager.d.ts** and changed to **function disableReverseGeocodingMock(): void**.|
| geolocation | method | function disableReverseGeocodingMock(): Promise<void>; | Migrated to **@ohos.geoLocationManager.d.ts** and changed to **function disableReverseGeocodingMock(): void**.|
| geolocation | method | function setReverseGeocodingMockInfo(mockInfos: Array<ReverseGeocodingMockInfo>, callback: AsyncCallback<void>): void; | Migrated to **@ohos.geoLocationManager.d.ts** and changed to **function setReverseGeocodingMockInfo(mockInfos: Array<ReverseGeocodingMockInfo>): void**.|
| geolocation | method | function setReverseGeocodingMockInfo(mockInfos: Array<ReverseGeocodingMockInfo>): Promise<void>; | Migrated to **@ohos.geoLocationManager.d.ts** and changed to **function setReverseGeocodingMockInfo(mockInfos: Array<ReverseGeocodingMockInfo>): void**.|
| geolocation | method | function isLocationPrivacyConfirmed(type: LocationPrivacyType, callback: AsyncCallback<boolean>): void; | Migrated to **@ohos.geoLocationManager.d.ts** and changed to **function isLocationPrivacyConfirmed(type: LocationPrivacyType): boolean**.|
| geolocation | method | function isLocationPrivacyConfirmed(type: LocationPrivacyType,): Promise<boolean>; | Migrated to **@ohos.geoLocationManager.d.ts** and changed to **function isLocationPrivacyConfirmed(type: LocationPrivacyType): boolean**.|
| geolocation | method | function setLocationPrivacyConfirmStatus(type: LocationPrivacyType, isConfirmed: boolean, callback: AsyncCallback<void>): void; | Migrated to **@ohos.geoLocationManager.d.ts** and changed to **function setLocationPrivacyConfirmStatus(type: LocationPrivacyType, isConfirmed: boolean): void**.|
| geolocation | method | function setLocationPrivacyConfirmStatus(type: LocationPrivacyType, isConfirmed: boolean): Promise<void>; | Migrated to **@ohos.geoLocationManager.d.ts** and changed to **function setLocationPrivacyConfirmStatus(type: LocationPrivacyType, isConfirmed: boolean): void**.|
| geolocation | interface | SatelliteStatusInfo | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | interface | CachedGnssLocationsRequest | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | interface | GeofenceRequest | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | interface | Geofence | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | interface | ReverseGeoCodeRequest | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | interface | GeoCodeRequest | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | interface | GeoAddress | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | interface | LocationRequest | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | interface | CurrentLocationRequest | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | interface | Location | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | enum | LocationRequestPriority | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | enum | LocationRequestScenario | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | enum | GeoLocationErrorCode | Deprecated. |
| geolocation | enum | LocationPrivacyType | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | enum | LocationCommand | Migrated to **@ohos.geoLocationManager.d.ts**. |
**(Optional) Adaptation Guide**
The following sample code shows how to call **enableLocation** in the new version:
```ts
import geoLocationManager from '@ohos.geoLocationManager';
try {
geoLocationManager.enableLocation((err, data) => {
if (err) {
console.log('enableLocation: err=' + JSON.stringify(err));
}
});
} catch (err) {
console.error("errCode:" + err.code + ",errMessage:" + err.message);
}
```
# Location Subsystem ChangeLog
## cl.location.1 API Migration from @ohos.geolocation.d.ts to @ohos.geoLocationManager.d.ts
APIs in **@ohos.geolocation.d.ts** do not support throwing error codes. To support this function, all APIs in **@ohos.geolocation.d.ts** are migrated to the newly added **@ohos.geoLocationManager.d.ts** file, and corresponding error code description is added.
To use APIs of the location subsystem, you need to import **@ohos.geoLocationManager**.
import geoLocationManager from '@ohos.geoLocationManager';
**Change Impacts**
All APIs of the location subsystem are affected. To ensure normal use of these APIs, you need to import **@ohos.geoLocationManager**.
import geoLocationManager from '@ohos.geoLocationManager';
**Key API/Component Changes**
| Class | API Type | Declaration | Change Type |
| ----------- | --------- | ------------------------------------------------------------ | ------------------------------------------------------------ |
| geolocation | namespace | declare namespace geolocation | Migrated to **@ohos.geoLocationManager.d.ts** and replaced by **namespace geoLocationManager**.|
| geolocation | method | function on(type: 'locationChange', request: LocationRequest, callback: Callback<Location>): void; | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | method | function off(type: 'locationChange', callback?: Callback<Location>): void; | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | method | function on(type: 'locationServiceState', callback: Callback<boolean>): void; | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | method | function off(type: 'locationServiceState', callback?: Callback<boolean>): void; | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | method | function on(type: 'cachedGnssLocationsReporting', request: CachedGnssLocationsRequest, callback: Callback<Array<Location>>): void; | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | method | function off(type: 'cachedGnssLocationsReporting', callback?: Callback<Array<Location>>): void; | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | method | function on(type: 'gnssStatusChange', callback: Callback<SatelliteStatusInfo>): void; | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | method | function off(type: 'gnssStatusChange', callback?: Callback<SatelliteStatusInfo>): void; | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | method | function on(type: 'nmeaMessageChange', callback: Callback<string>): void; | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | method | function off(type: 'nmeaMessageChange', callback?: Callback<string>): void; | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | method | function on(type: 'fenceStatusChange', request: GeofenceRequest, want: WantAgent): void; | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | method | function off(type: 'fenceStatusChange', request: GeofenceRequest, want: WantAgent): void; | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | method | function getCurrentLocation(request: CurrentLocationRequest, callback: AsyncCallback<Location>): void; | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | method | function getCurrentLocation(callback: AsyncCallback<Location>): void; | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | method | function getCurrentLocation(request?: CurrentLocationRequest): Promise<Location>; | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | method | function getLastLocation(callback: AsyncCallback<Location>): void; | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | method | function getLastLocation(): Promise<Location>; | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | method | function isLocationEnabled(callback: AsyncCallback<boolean>): void; | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | method | function isLocationEnabled(): Promise<boolean>; | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | method | function requestEnableLocation(callback: AsyncCallback<boolean>): void; | Deleted. |
| geolocation | method | function requestEnableLocation(): Promise<boolean>; | Deleted. |
| geolocation | method | function enableLocation(callback: AsyncCallback<boolean>): void; | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | method | function enableLocation(): Promise<boolean>; | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | method | function disableLocation(callback: AsyncCallback<boolean>): void; | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | method | function disableLocation(): Promise<boolean>; | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | method | function getAddressesFromLocation(request: ReverseGeoCodeRequest, callback: AsyncCallback<Array<GeoAddress>>): void; | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | method | function getAddressesFromLocation(request: ReverseGeoCodeRequest): Promise<Array<GeoAddress>>; | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | method | function getAddressesFromLocationName(request: GeoCodeRequest, callback: AsyncCallback<Array<GeoAddress>>): void; | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | method | function getAddressesFromLocationName(request: GeoCodeRequest): Promise<Array<GeoAddress>>; | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | method | function isGeoServiceAvailable(callback: AsyncCallback<boolean>): void; | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | method | function isGeoServiceAvailable(): Promise<boolean>; | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | method | function getCachedGnssLocationsSize(callback: AsyncCallback<number>): void; | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | method | function getCachedGnssLocationsSize(): Promise<number>; | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | method | function flushCachedGnssLocations(callback: AsyncCallback<boolean>): void; | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | method | function flushCachedGnssLocations(): Promise<boolean>; | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | method | function sendCommand(command: LocationCommand, callback: AsyncCallback<boolean>): void; | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | method | function sendCommand(command: LocationCommand): Promise<boolean>; | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | interface | SatelliteStatusInfo | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | interface | CachedGnssLocationsRequest | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | interface | GeofenceRequest | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | interface | Geofence | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | interface | ReverseGeoCodeRequest | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | interface | GeoCodeRequest | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | interface | GeoAddress | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | interface | LocationRequest | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | interface | CurrentLocationRequest | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | interface | Location | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | enum | LocationRequestPriority | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | enum | LocationRequestScenario | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | enum | GeoLocationErrorCode | Deprecated. |
| geolocation | enum | LocationPrivacyType | Migrated to **@ohos.geoLocationManager.d.ts**. |
| geolocation | enum | LocationCommand | Migrated to **@ohos.geoLocationManager.d.ts**. |
**(Optional) Adaptation Guide**
The following sample code shows how to call **enableLocation** in the new version:
```ts
import geoLocationManager from '@ohos.geoLocationManager';
try {
geoLocationManager.enableLocation((err, data) => {
if (err) {
console.log('enableLocation: err=' + JSON.stringify(err));
}
});
} catch (err) {
console.error("errCode:" + err.code + ",errMessage:" + err.message);
}
```
# Location Subsystem ChangeLog
## cl.location.1 API Migration from @system.geolocation.d.ts to @ohos.geoLocationManager.d.ts
APIs in **@system.geolocation.d.ts** do not support throwing error codes. To support this function, all APIs in **@system.geolocation.d.ts** are migrated to the newly added **@ohos.geoLocationManager.d.ts** file, and corresponding error code description is added.
To use APIs of the location subsystem, you need to import **@ohos.geoLocationManager**.
import geoLocationManager from '@ohos.geoLocationManager';
**Change Impacts**
All APIs of the location subsystem are affected. To ensure normal use of these APIs, you need to import **@ohos.geoLocationManager**.
import geoLocationManager from '@ohos.geoLocationManager';
**Key API/Component Changes**
| Class | API Type | Declaration | Change Type |
| ----------- | --------- | ------------------------------------------------------------ | ------------------------------------------------------------ |
| Geolocation | class | Geolocation | Migrated to **@ohos.geoLocationManager.d.ts** and replaced by **ohos.geoLocationManager/geoLocationManager**.|
| Geolocation | interface | static getLocation(options?: GetLocationOption): void; | Migrated to **@ohos.geoLocationManager.d.ts** and replaced by **ohos.geoLocationManager/geoLocationManager.getCurrentLocation**.|
| Geolocation | interface | static getLocationType(options?: GetLocationTypeOption): void; | Deprecated. |
| Geolocation | interface | static subscribe(options: SubscribeLocationOption): void; | Migrated to **@ohos.geoLocationManager.d.ts** and replaced by **ohos.geoLocationManager/geoLocationManager.on#event:locationChange**.|
| Geolocation | interface | static unsubscribe(): void; | Migrated to **@ohos.geoLocationManager.d.ts** and replaced by **ohos.geoLocationManager/geoLocationManager.off#event:locationChange**.|
| Geolocation | interface | static getSupportedCoordTypes(): Array<string>; | Deprecated. |
| | interface | GeolocationResponse | Migrated to **@ohos.geoLocationManager.d.ts** and replaced by **ohos.geoLocationManager/geoLocationManager.Location**.|
| | interface | GetLocationOption | Migrated to **@ohos.geoLocationManager.d.ts** and replaced by **ohos.geoLocationManager/geoLocationManager.CurrentLocationRequest**.|
| | interface | GetLocationTypeResponse | Deprecated. |
| | interface | GetLocationTypeOption | Deprecated. |
| | interface | SubscribeLocationOption | Migrated to **@ohos.geoLocationManager.d.ts** and replaced by **ohos.geoLocationManager/geoLocationManager.LocationRequest**.|
**(Optional) Adaptation Guide**
The following sample code shows how to call **enableLocation** in the new version:
```ts
import geoLocationManager from '@ohos.geoLocationManager';
try {
geoLocationManager.enableLocation((err, data) => {
if (err) {
console.log('enableLocation: err=' + JSON.stringify(err));
}
});
} catch (err) {
console.error("errCode:" + err.code + ",errMessage:" + err.message);
}
```
# User IAM Subsystem ChangeLog
## cl.useriam.1 API9 Authentication Result Code Class Name Change
The name of the authentication result code class of user IAM API version 9 is changed from **ResultCode** to **UserAuthResultCode**.
**Change Impacts**
Applications developed based on earlier versions are not affected. For the applications developed from this version, the class name of the error code needs to be adapted. Otherwise, the service logic is affected.
**Key API/Component Changes**
N/A
**Adaptation Guide**
Change the class name for invoking the authentication result code from **ResultCode** to **UserAuthResultCode**.
# Window Subsystem ChangeLog
## cl.window.1 Change of Window Stage Lifecycle Listener Types
Changed the enumerated listener types of the window stage lifecycle in version 3.2.10.5 and later.
**Change Impacts**
Application lifecycle listeners developed using **FOREGROUND** and **BACKGROUND** in versions earlier than 3.2.10.5 will be invalidated in version 3.2.10.5 and later.
**Key API/Component Changes**
## WindowStageEventType<sup>9+</sup>
Before change
| Name | Value | Description |
| ---------- | ---- | ---------- |
| FOREGROUND | 1 | The window stage is running in the foreground.|
| BACKGROUND | 4 | The window stage is running in the background.|
After change
| Name | Value | Description |
| ------ | ---- | ---------- |
| SHOWN | 1 | The window stage is running in the foreground.|
| HIDDEN | 4 | The window stage is running in the background.|
**Adaptation Guide**
When registering lifecycle listeners, change the foreground and background event types to **SHOWN** and **HIDDEN**, respectively.
```
import Ability from '@ohos.application.Ability';
class myAbility extends Ability {
onWindowStageCreate(windowStage) {
console.log('onWindowStageCreate');
try {
windowStage.on('windowStageEvent', (stageEventType) => {
switch (stageEventType) {
case window.WindowStageEventType.SHOWN:
console.log("windowStage shown");
break;
case window.WindowStageEventType.ACTIVE:
console.log("windowStage active");
break;
case window.WindowStageEventType.INACTIVE:
console.log("windowStage inActive");
break;
case window.WindowStageEventType.HIDDEN:
console.log("windowStage hidden");
break;
default:
break;
}
} )
} catch (exception) {
console.error('Failed to enable the listener for window stage event changes. Cause:' +
JSON.stringify(exception));
};
}
};
```
# Ability Subsystem Changelog
## cl.ability.1 RestartFlag Attribute Names Changed and Unsupported Attribute Deleted in appRecovery
In the **appRecovery** API, the enum names of **RestartFlag** are changed from **NO_RESTART** upon a specific fault to **RESTART** upon a specific fault.
The **CPP_CRASH_NO_RESTART** enum is deleted.
**Change Impact**
If your application uses the **CPP_CRASH_NO_RESTART**, **JS_CRASH_NO_RESTART**, or **APP_FREEZE_NO_RESTART** attribute in versions earlier than 3.2.10.6, its behavior will change after an upgrade to 3.2.10.6.
**Key API/Component Changes**
**RestartFlag** <sup>9+</sup>
Before change:
| Name | Value | Description |
| ----------------------------- | ---- | ------------------------------------------------------------ |
| ALWAYS_RESTART | 0 | The application is restarted in all cases.|
| CPP_CRASH_NO_RESTART | 0x0001 | The application is **not restarted** in the case of CPP_CRASH.|
| JS_CRASH_NO_RESTART | 0x0002 | The application is **not restarted** in the case of JS_CRASH.|
| APP_FREEZE_NO_RESTART | 0x0004 | The application is **not restarted** in the case of APP_FREEZE.|
| NO_RESTART | 0xFFFF | The application is not restarted in any case.|
After change:
| Name | Value | Description |
| ---------- | ---- | ---------- |
| ALWAYS_RESTART | 0 | The application is restarted in all cases.|
| CPP_CRASH_NO_RESTART | NA | **Deleted.** The restart in this scenario is not supported.|
| RESTART_WHEN_JS_CRASH | 0x0001 | The application is **restarted** in the case of JS_CRASH.|
| RESTART_WHEN_APP_FREEZE | 0x0002 | The application is **restarted** in the case of APP_FREEZE.|
| NO_RESTART | 0xFFFF | The application is not restarted in any case.|
**Adaptation Guide**
Perform adaptation based on the new semantics.
# File Subsystem Changelog
## cl.file.1 mediaLibrary APIs Changed
All APIs provided by the mediaLibrary module of the multimedia subsystem are deprecated.
**Change Impact**
All APIs described in [mediaLibrary](../../../application-dev/reference/apis/js-apis-medialibrary.md) are deprecated. Third-party applications can only select and save files in the public directory by calling the APIs of [FilePicker](../../../application-dev/reference/apis/js-apis-file-picker.md).
For applications developed based on earlier versions, pay attention to the changes of APIs.
**Key API/Component Changes**
The table below lists the **mediaLibrary** APIs that can be substituted by the **FilePicker** APIs.
| Module | Method/Attribute/Enum/Constant | Change Type|
| ------------------------- | ------------------------------------------------------------ | -------- |
| medialibrary | **function** getMediaLibrary(context: Context): MediaLibrary; | Deprecated |
| medialibrary | **function** getFileAssets(options: MediaFetchOptions, callback: AsyncCallback\<FetchFileResult\>): void | Deprecated |
| medialibrary | **function** getFileAssets(options: MediaFetchOptions): Promise\<FetchFileResult\> | Deprecated |
| medialibrary | **function** createAsset(mediaType: MediaType, displayName: string, relativePath: string, callback: AsyncCallback\<FileAsset\>): void | Deprecated |
| medialibrary | **function** createAsset(mediaType: MediaType, displayName: string, relativePath: string): Promise\<FileAsset\> | Deprecated |
| medialibrary | **function** getPublicDirectory(type: DirectoryType, callback: AsyncCallback\<string\>): void | Deprecated |
| medialibrary | **function** getPublicDirectory(type: DirectoryType): Promise\<string\> | Deprecated |
| medialibrary | **function** release(callback: AsyncCallback\<void\>): void | Deprecated |
| medialibrary | **function** release(): Promise\<void\> | Deprecated |
| medialibrary | **function** FileAsset.open(mode: string, callback: AsyncCallback\<number\>): void | Deprecated |
| medialibrary | **function** FileAsset.open(mode: string): Promise\<number\> | Deprecated |
| medialibrary | **function** FileAsset.close(fd: number, callback: AsyncCallback\<void\>): void | Deprecated |
| medialibrary | **function** FileAsset.close(fd: number): Promise\<void\> | Deprecated |
| medialibrary | **function** FetchFileResult.getCount(): number | Deprecated |
| medialibrary | **function** FetchFileResult.isAfterLast(): boolean | Deprecated |
| medialibrary | **function** FetchFileResult.close(): void | Deprecated |
| medialibrary | **function** FetchFileResult.getFirstObject(callback: AsyncCallback\<FileAsset\>): void | Deprecated |
| medialibrary | **function** FetchFileResult.getFirstObject(): Promise\<FileAsset\> | Deprecated |
| medialibrary | **function** FetchFileResult.getNextObject(callback: AsyncCallback\<FileAsset\>): void | Deprecated |
| medialibrary | **function** FetchFileResult.getNextObject(): Promise\<FileAsset\> | Deprecated |
| medialibrary | **function** FetchFileResult.getLastObject(callback: AsyncCallback\<FileAsset\>): void | Deprecated |
| medialibrary | **function** FetchFileResult.getLastObject(): Promise\<FileAsset\> | Deprecated |
| medialibrary | **function** FetchFileResult.getPositionObject(index: number, callback: AsyncCallback\<FileAsset\>): void | Deprecated |
| medialibrary | **function** FetchFileResult.getPositionObject(index: number): Promise\<FileAsset\> | Deprecated |
| medialibrary | **function** FetchFileResult.getAllObject(callback: AsyncCallback\<Array\<FileAsset\>\>): void | Deprecated |
| medialibrary | **function** FetchFileResult.getAllObject(): Promise\<Array\<FileAsset\>\> | Deprecated |
| medialibrary | **function** Album.getFileAssets(options: MediaFetchOptions, callback: AsyncCallback\<FetchFileResult\>): void | Deprecated |
| medialibrary | **function** Album.getFileAssets(options?: MediaFetchOptions): Promise\<FetchFileResult\> | Deprecated |
| medialibrary | **enum** FileKey | Deprecated |
| medialibrary | **enum** DirectoryType | Deprecated |
| medialibrary | **enum** MediaType | Deprecated |
| medialibrary | **interface** MediaFetchOptions | Deprecated |
| medialibrary | **interface** FileAsset | Deprecated |
**Adaptation Guide**
**The following example shows how to use the mediaLibrary APIs to edit a file in the public directory:**
1. Call **getMediaLibrary** to obtain a **mediaLibrary** instance.
2. Create a **MediaFetchOptions** object, and call **getFileAssets** to obtain files in the public directory.
3. Call the **FetchFileResult** APIs to obtain the file asset of the target file.
4. Call **fileAsset.open** to open the file and obtain the FD.
5. Call [fs.writeSync](../../../application-dev/reference/apis/js-apis-file-fs.md#writesync) to edit the file through the FD.
6. After the edit, call **fileAsset.close** to close the FD of the file.
7. Call **fetchFileResult.close** to release the resources occupied by **getFileAssets**.
8. Call **release** to release the **mediaLibrary** instance.
**Example**
```js
import mediaLibrary from '@ohos.multimedia.mediaLibrary';
import fs from '@ohos.file.fs';
async function example() {
try {
let context = getContext(this);
let media = mediaLibrary.getMediaLibrary(context);
let fileKeyObj = mediaLibrary.FileKey;
let imageType = mediaLibrary.MediaType.IMAGE;
let getImageOp = {
selections: fileKeyObj.MEDIA_TYPE + '= ?',
selectionArgs: [imageType.toString()],
order: fileKeyObj.DATE_ADDED + ' DESC',
};
const fetchFileResult = await media.getFileAssets(getImageOp);
const fileAsset = await fetchFileResult.getFirstObject();
console.info('mediaLibrary fileAsset displayName: ' + fileAsset.displayName);
let fd = await fileAsset.open('rw');
console.info('mediaLibrary fileAsset open fd: ' + fd);
let writeLen = fs.writeSync(fd, 'hello, world');
console.info('write data to file succeed and size is: ' + writeLen);
fileAsset.close(fd);
fetchFileResult.close();
media.release();
} catch (err) {
console.error('mediaLibrary fail, err: ' + err);
}
}
```
**The following example shows how to use the FilePicker APIs to edit a file in the public directory:**
1. Obtain a **DocumentViewPicker** object.
2. Call **DocumentViewPicker.select** to select a file.
3. After a file is selected, a file URI is returned.
4. After the UI is returned from DocumentViewPicker, call [fs.openSync](../../../application-dev/reference/apis/js-apis-file-fs.md#fsopensync) to open the file based on the URI and obtain the FD.
5. Call [fs.writeSync](../../../application-dev/reference/apis/js-apis-file-fs.md#writesync) to edit the file through the FD.
6. After the edit, call [fs.closeSync](../../../application-dev/reference/apis/js-apis-file-fs.md#closesync) to close the FD.
**Example**
```js
import mediaLibrary from '@ohos.multimedia.mediaLibrary';
import picker from '@ohos.file.picker';
import fs from '@ohos.file.fs';
let uri;
async function example() {
try {
let DocumentSelectOptions = new picker.DocumentSelectOptions();
let documentPicker = new picker.DocumentViewPicker();
documentPicker.select(DocumentSelectOptions).then((DocumentSelectResult) => {
console.info('DocumentViewPicker.select successfully, DocumentSelectResult uri: ' + JSON.stringify(DocumentSelectResult));
uri = DocumentSelectResult[0];
}).catch((err) => {
console.error('DocumentViewPicker.select failed with err: ' + err);
});
} catch (err) {
console.error('DocumentViewPicker failed with err: ' + err);
}
}
async function writeFile() {
try {
let file = fs.openSync(uri, fs.OpenMode.READ_WRITE);
console.info('DocumentViewPicker file fd: ' + file.fd);
let writeLen = fs.writeSync(file.fd, 'hello, world');
console.info('write data to file succeed and size is: ' + writeLen);
fs.closeSync(file);
} catch (err) {
console.error('DocumentViewPicker fail, err: ' + err);
}
}
```
**The following example shows how to use the mediaLibrary APIs to create a file in the public directory:**
1. Call **getMediaLibrary** to obtain a **mediaLibrary** instance.
2. Call **getPublicDirectory** to obtain the path of the public directory.
3. Call **createAsset** to create a file and obtain the file asset.
4. Call **fileAsset.open** to open the file and obtain the FD.
5. Call **fs.write** to edit the file through the FD.
6. After the edit, call **fileAsset.close** to close the FD.
7. Call **release** to release the **mediaLibrary** instance.
**Example**
```js
import mediaLibrary from '@ohos.multimedia.mediaLibrary';
import fs from '@ohos.file.fs';
async function example() {
try {
let context = getContext(this);
let media = mediaLibrary.getMediaLibrary(context);
let mediaType = mediaLibrary.MediaType.FILE;
let DIR_DOWNLOAD = mediaLibrary.DirectoryType.DIR_DOWNLOAD;
const path = await media.getPublicDirectory(DIR_DOWNLOAD);
const fileAsset = await media.createAsset(mediaType, 'test.txt', path);
console.info('mediaLibrary fileAsset displayName: ' + fileAsset.displayName);
let fd = await fileAsset.open('rw');
console.info('mediaLibrary fileAsset open fd: ' + fd);
let writeLen = fs.writeSync(fd, 'hello, world');
console.info('write data to file succeed and size is: ' + writeLen);
fileAsset.close(fd);
media.release();
} catch (err) {
console.error('mediaLibrary fail, err: ' + err);
}
}
```
**The following example shows how to use the FilePicker APIs to create a file in the public directory:**
1. Obtain a **DocumentViewPicker** object.
2. Call **DocumentViewPicker.save** to create and save an empty file.
3. After the file is saved, a file URI is returned.
4. After the UI is returned from DocumentViewPicker, call [fs.openSync](../../../application-dev/reference/apis/js-apis-file-fs.md#fsopensync) to open the file based on the URI and obtain the FD.
5. Call [fs.writeSync](../../../application-dev/reference/apis/js-apis-file-fs.md#writesync) to edit the file through the FD.
6. After the edit, call [fs.closeSync](../../../application-dev/reference/apis/js-apis-file-fs.md#closesync) to close the FD.
**Example**
```js
import mediaLibrary from '@ohos.multimedia.mediaLibrary';
import picker from '@ohos.file.picker';
import fs from '@ohos.file.fs';
let uri;
async function example() {
try {
let DocumentSaveOptions = new picker.DocumentSaveOptions();
DocumentSaveOptions.newFileNames = ['DocumentViewPicker01.txt'];
let documentPicker = new picker.DocumentViewPicker();
documentPicker.save(DocumentSaveOptions).then((DocumentSaveResult) => {
console.info('DocumentViewPicker.save successfully, DocumentSaveResult uri: ' + JSON.stringify(DocumentSaveResult));
uri = DocumentSaveResult[0];
}).catch((err) => {
console.error('DocumentViewPicker.save failed with err: ' + err);
});
} catch (err) {
console.error('DocumentViewPicker failed with err: ' + err);
}
}
async function writeFile() {
try {
let file = fs.openSync(uri, fs.OpenMode.READ_WRITE);
console.info('DocumentViewPicker file fd: ' + file.fd);
let writeLen = fs.writeSync(file.fd, 'hello, world');
console.info('write data to file succeed and size is: ' + writeLen);
fs.closeSync(file);
} catch (err) {
console.error('DocumentViewPicker fail, err: ' + err);
}
}
```
**Key API/Component Changes**
The table below lists the mediaLibrary APIs that are not open to third-party applications due to function control. There are no substitute APIs for them.
| Module | Method/Attribute/Enum/Constant | Change Type|
| ------------------------- | ------------------------------------------------------------ | -------- |
| medialibrary | **function** getMediaLibrary(): MediaLibrary; | Deprecated |
| medialibrary | **function** on(type: 'deviceChange'\|'albumChange'\|'imageChange'\|'audioChange'\|'videoChange'\|'fileChange'\|'remoteFileChange', callback: Callback\<void\>): void | Deprecated |
| medialibrary | **function** off(type: 'deviceChange'\|'albumChange'\|'imageChange'\|'audioChange'\|'videoChange'\|'fileChange'\|'remoteFileChange', callback?: Callback\<void\>): void | Deprecated |
| medialibrary | **function** deleteAsset(uri: string): Promise\<void\> | Deprecated |
| medialibrary | **function** deleteAsset(uri: string, callback: AsyncCallback\<void\>): void | Deprecated |
| medialibrary | **function** storeMediaAsset(option: MediaAssetOption, callback: AsyncCallback\<string\>): void | Deprecated |
| medialibrary | **function** storeMediaAsset(option: MediaAssetOption): Promise\<string\> | Deprecated |
| medialibrary | **function** startImagePreview(images: Array\<string\>, index: number, callback: AsyncCallback\<void\>): void | Deprecated |
| medialibrary | **function** startImagePreview(images: Array\<string\>, callback: AsyncCallback\<void\>): void | Deprecated |
| medialibrary | **function** startImagePreview(images: Array\<string\>, index?: number): Promise\<void\> | Deprecated |
| medialibrary | **function** startMediaSelect(option: MediaSelectOption, callback: AsyncCallback\<Array\<string\>\>): void | Deprecated |
| medialibrary | **function** startMediaSelect(option: MediaSelectOption): Promise\<Array\<string\>\> | Deprecated |
| medialibrary | **function** getActivePeers(): Promise\<Array\<PeerInfo\>\>; | Deprecated |
| medialibrary | **function** getActivePeers(callback: AsyncCallback\<Array\<PeerInfo\>\>): void; | Deprecated |
| medialibrary | **function** getAllPeers(): Promise\<Array\<PeerInfo\>\>; | Deprecated |
| medialibrary | **function** FileAsset.isDirectory(callback: AsyncCallback\<boolean\>): void | Deprecated |
| medialibrary | **function** FileAsset.isDirectory():Promise\<boolean\> | Deprecated |
| medialibrary | **function** FileAsset.commitModify(callback: AsyncCallback\<void\>): void | Deprecated |
| medialibrary | **function** FileAsset.commitModify(): Promise\<void\> | Deprecated |
| medialibrary | **function** FileAsset.getThumbnail(callback: AsyncCallback\<image.PixelMap\>): void | Deprecated |
| medialibrary | **function** FileAsset.getThumbnail(size: Size, callback: AsyncCallback\<image.PixelMap\>): void | Deprecated |
| medialibrary | **function** FileAsset.getThumbnail(size?: Size): Promise\<image.PixelMap\> | Deprecated |
| medialibrary | **function** FileAsset.favorite(isFavorite: boolean, callback: AsyncCallback\<void\>): void | Deprecated |
| medialibrary | **function** FileAsset.favorite(isFavorite: boolean): Promise\<void\> | Deprecated |
| medialibrary | **function** FileAsset.isFavorite(callback: AsyncCallback\<boolean\>): void | Deprecated |
| medialibrary | **function** FileAsset.isFavorite():Promise\<boolean\> | Deprecated |
| medialibrary | **function** FileAsset.trash(isTrash: boolean, callback: AsyncCallback\<void\>): void | Deprecated |
| medialibrary | **function** FileAsset.trash(isTrash: boolean): Promise\<void\> | Deprecated |
| medialibrary | **function** FileAsset.isTrash(callback: AsyncCallback\<boolean\>): void | Deprecated |
| medialibrary | **function** FileAsset.isTrash():Promise\<boolean\> | Deprecated |
| medialibrary | **function** getAlbums(options: MediaFetchOptions, callback: AsyncCallback\<Array\<Album\>\>): void | Deprecated |
| medialibrary | **function** getAlbums(options: MediaFetchOptions): Promise\<Array\<Album\>\> | Deprecated |
| medialibrary | **function** Album.commitModify(callback: AsyncCallback\<void\>): void | Deprecated |
| medialibrary | **function** Album.commitModify(): Promise\<void\> | Deprecated |
| medialibrary | **enum** DeviceType | Deprecated |
| medialibrary | **interface** PeerInfo | Deprecated |
| medialibrary | **interface** Size | Deprecated |
| medialibrary | **interface** MediaAssetOption | Deprecated |
| medialibrary | **interface** MediaSelectOption | Deprecated |
# Upload and Download Subsystem Changelog
## cl.request.2 request API Change
Deleted the beta APIs in API version 9:
1. function download(context: BaseContext, config: DownloadConfig, callback: AsyncCallback\<DownloadTask>): void;
2. function download(context: BaseContext, config: DownloadConfig): Promise\<DownloadTask>;
3. function upload(context: BaseContext, config: UploadConfig, callback: AsyncCallback\<UploadTask>): void;
4. function upload(context: BaseContext, config: UploadConfig): Promise\<UploadTask>;
**Change Impact**
The application developed based on an earlier version in the stage model needs to be adapted to the new APIs. Otherwise, the original service logic will be affected.
**Key API/Component Changes**
| Module | Class | Method/Attribute/Enum/Constant | Change Type|
|--------------|--------------|-------------------------------------------------------------------------------------------------------------------|------|
| ohos.request | request | function download(context: BaseContext, config: DownloadConfig, callback: AsyncCallback\<DownloadTask>): void; | Deleted |
| ohos.request | request | function download(context: BaseContext, config: DownloadConfig): Promise\<DownloadTask>; | Deleted |
| ohos.request | request | function upload(context: BaseContext, config: UploadConfig, callback: AsyncCallback\<UploadTask>): void; | Deleted |
| ohos.request | request | function upload(context: BaseContext, config: UploadConfig): Promise\<UploadTask>; | Deleted |
**Adaptation Guide**
Call the new APIs. The following uses **downloadFile** as an example to show how it is called in the new version:
```ts
try {
request.downloadFile(globalThis.abilityContext, { url: 'https://xxxx/xxxxx.hap',
filePath: 'xxx/xxxxx.hap'}, (err, data) => {
if (err) {
console.error('Failed to request the download. Cause: ' + JSON.stringify(err));
return;
}
});
} catch (err) {
console.log("downloadFile callback fail." + "errCode:" + err.code + ",errMessage:" + err.message);
}
```
# Telephony Subsystem Changelog
## cl.telephony.1 Radio Module API Change
### Changed the `isNrSupported` API in the radio module of the telephone subsystem:
NR is a proper noun and must be capitalized.
You need to adapt your application.
**Change Impacts**
The JS API needs to be adapted for applications developed based on earlier versions. Otherwise, relevant functions will be affected.
**Key API/Component Changes**
- Involved APIs:
isNrSupported(): boolean;
isNrSupported(slotId: number): boolean;
- Before change:
```js
function isNrSupported(): boolean;
function isNrSupported(slotId: number): boolean;
```
- After change:
```js
function isNRSupported(): boolean;
function isNRSupported(slotId: number): boolean;
```
**Adaptation Guide**
Use the new API. The sample code is as follows:
```js
let result = radio.isNrSupported();
console.log("Result: "+ result);
```
```js
let slotId = 0;
let result = radio.isNRSupported(slotId);
console.log("Result: "+ result);
```
# Resource Scheduler Subsystem Changelog
## cl.resourceschedule.workScheduler
The data type of the **parameters** attribute value is changed. Specifically, the number, string, and boolean types are supported, but the any type is not.
**Change Impact**
For applications developed based on OpenHarmony3.2.10.7 and later SDK versions, the **parameters** attribute value can use the number, string, and boolean types only. If it uses the any type, a compilation error is reported.
**Key API/Component Changes**
The **parameters** attribute in @ohos.resourceschedule.workScheduler.d.ts is changed.
| Class| API Type| Statement Before the Change| Statement After the Change|
| -- | -- | -- | -- |
| workScheduler.WorkInfo | field | parameters?: {[key: string]: any} | parameters?: {[key: string]: number | string | boolean} |
**Adaptation Guide**
The **parameters** attribute uses the {[key: string]: number | string | boolean} data type.
# Telephony Subsystem Changelog
## cl.telephony.1 Call Module reject API Change
Changed the `reject` API to the `rejectCall` API in the call module of the telephony subsystem since API version 9.
You need to adapt your application.
**Change Impact**
The `reject` API is deprecated and cannot be used any more. Use the `rejectCall` API instead. Otherwise, relevant functions will be affected.
- Involved APIs:
```js
function reject(callId: number, callback: AsyncCallback<void>): void;
function reject(callId: number, options: RejectMessageOptions, callback: AsyncCallback<void>): void;
function reject(callId?: number, options?: RejectMessageOptions): Promise<void>;
function reject(callback: AsyncCallback<void>): void;
function reject(options: RejectMessageOptions, callback: AsyncCallback<void>): void;
```
- Before change:
```js
function reject(callId: number, callback: AsyncCallback<void>): void;
function reject(callId: number, options: RejectMessageOptions, callback: AsyncCallback<void>): void;
function reject(callId?: number, options?: RejectMessageOptions): Promise<void>;
function reject(callback: AsyncCallback<void>): void;
function reject(options: RejectMessageOptions, callback: AsyncCallback<void>): void;
```
- After change:
```js
function rejectCall(callId: number, callback: AsyncCallback<void>): void;
function rejectCall(callId: number, options: RejectMessageOptions, callback: AsyncCallback<void>): void;
function rejectCall(callId?: number, options?: RejectMessageOptions): Promise<void>;
function rejectCall(callback: AsyncCallback<void>): void;
function rejectCall(options: RejectMessageOptions, callback: AsyncCallback<void>): void;
```
**Adaptation Guide**
The `reject` API is deprecated and cannot be used any more. Use the `rejectCall` API instead.
Use the new API. The sample code is as follows:
```js
call.rejectCall("138xxxxxxxx", (err, data) => {
console.log(`callback: err->${JSON.stringify(err)}, data->${JSON.stringify(data)}`);
});
```
```js
let rejectMessageOptions={
messageContent: "Unknown number blocked"
}
let promise = call.rejectCall(1, rejectMessageOptions);
promise.then(data => {
console.log(`rejectCall success, promise: data->${JSON.stringify(data)}`);
}).catch(err => {
console.error(`rejectCall fail, promise: err->${JSON.stringify(err)}`);
});
```
```js
let rejectMessageOptions={
messageContent: "Unknown number blocked"
}
let promise = call.rejectCall(1, rejectMessageOptions);
promise.then(data => {
console.log(`rejectCall success, promise: data->${JSON.stringify(data)}`);
}).catch(err => {
console.error(`rejectCall fail, promise: err->${JSON.stringify(err)}`);
});
```
```js
call.rejectCall((err, data) => {
console.log(`callback: err->${JSON.stringify(err)}, data->${JSON.stringify(data)}`);
});
```
```js
let rejectMessageOptions={
messageContent: "Unknown number blocked"
}
call.rejectCall(rejectMessageOptions, (err, data) => {
console.log(`callback: err->${JSON.stringify(err)}, data->${JSON.stringify(data)}`);
});
```
## cl.telephony.2 Call Module answer API Change
Changed the `answer` API to the `answerCall` API in the call module of the telephony subsystem since API version 9.
You need to adapt your application.
**Change Impact**
The `answer` API is deprecated and cannot be used any more. Use the `answerCall` API instead. Otherwise, relevant functions will be affected.
- Involved APIs:
```js
function answer(callId: number, callback: AsyncCallback<void>): void;
function answer(callId?: number): Promise<void>;
function answer(callback: AsyncCallback<void>): void;
```
- Before change:
```js
function answer(callId: number, callback: AsyncCallback<void>): void;
function answer(callId?: number): Promise<void>;
function answer(callback: AsyncCallback<void>): void;
```
- After change:
```js
function answerCall(callId: number, callback: AsyncCallback<void>): void;
function answerCall(callId?: number): Promise<void>;
function answerCall(callback: AsyncCallback<void>): void;
```
**Adaptation Guide**
The `answer` API is deprecated and cannot be used any more. Use the `answerCall` API instead.
Use the new API. The sample code is as follows:
```js
call.answerCall(1, (err, data) => {
console.log(`callback: err->${JSON.stringify(err)}, data->${JSON.stringify(data)}`);
});
```
```js
let promise = call.answerCall(1);
promise.then(data => {
console.log(`answerCall success, promise: data->${JSON.stringify(data)}`);
}).catch(err => {
console.error(`answerCall fail, promise: err->${JSON.stringify(err)}`);
});
```
```js
call.answerCall((err, data) => {
console.log(`callback: err->${JSON.stringify(err)}, data->${JSON.stringify(data)}`);
});
```
## cl.telephony.1 Call Module hangup API Change
Changed the `hangup` API to the `hangUpCall` API in the call module of the telephony subsystem since API version 9.
You need to adapt your application.
**Change Impact**
The `hangup` API is deprecated and cannot be used any more. Use the `hangUpCall` API instead. Otherwise, relevant functions will be affected.
- Involved APIs:
```js
function hangup(callId: number, callback: AsyncCallback<void>): void;
function hangup(callId?: number): Promise<void>;
function hangup(callback: AsyncCallback<void>): void;
```
- Before change:
```js
function hangup(callId: number, callback: AsyncCallback<void>): void;
function hangup(callId?: number): Promise<void>;
function hangup(callback: AsyncCallback<void>): void;
```
- After change:
```js
function hangUpCall(callId: number, callback: AsyncCallback<void>): void;
function hangUpCall(callId?: number): Promise<void>;
function hangUpCall(callback: AsyncCallback<void>): void;
```
**Adaptation Guide**
The `hangup` API is deprecated and cannot be used any more. Use the `hangUpCall` API instead.
Use the new API. The sample code is as follows:
```js
call.hangUpCall(1, (err, data) => {
console.log(`callback: err->${JSON.stringify(err)}, data->${JSON.stringify(data)}`);
});
```
```js
let promise = call.hangUpCall(1);
promise.then(data => {
console.log(`hangUpCall success, promise: data->${JSON.stringify(data)}`);
}).catch(err => {
console.error(`hangUpCall fail, promise: err->${JSON.stringify(err)}`);
});
```
```js
call.hangUpCall((err, data) => {
console.log(`callback: err->${JSON.stringify(err)}, data->${JSON.stringify(data)}`);
});
```
# Web Subsystem Changelog
Compared with earlier versions, OpenHarmony 3.2.10.7 has the following API changes in its web subsystem:
## cl.web.1 HitTestTypeV9 Name Change
Renamed the enum class **HitTestTypeV9** **WebHitTestType** to meet the naming conventions.
**Change Impact**
The enum class **HitTestTypeV9** and APIs that use **HitTestTypeV9** as a parameter or return value cannot be used in OpenHarmony 3.2.10.7 and later versions.
**Key API/Component Changes**
- Involved APIs:
enum HitTestTypeV9
- Before change:
```ts
enum HitTestTypeV9
```
- After change:
```ts
enum WebHitTestType
```
**Adaptation Guide**
Replace **HitTestTypeV9** with **WebHitTestType**.
## cl.web.2 HeaderV9 Name Change
Renamed the struct **HeaderV9** **WebHeader** to meet the naming conventions.
**Change Impact**
The struct **HeaderV9** and APIs that use **HeaderV9** as a parameter or return value cannot be used in OpenHarmony 3.2.10.7 and later versions.
**Key API/Component Changes**
- Involved APIs:
interface HeaderV9
- Before change:
```ts
interface HeaderV9
```
- After change:
```ts
interface WebHeader
```
**Adaptation Guide**
Replace **HeaderV9** with **WebHeader**.
## cl.web.3 Member Change of HitTestValue
Rename the member variable **HitTestTypeV9** in the **HitTestValue** struct **WebHitTestType** to meet the naming conventions.
**Change Impact**
The struct **HitTestValue** and APIs that use **HitTestValue** as a parameter or return value cannot be used in OpenHarmony 3.2.10.7 and later versions.
**Key API/Component Changes**
- Involved APIs:
interface HitTestValue
- Before change:
```ts
interface HitTestValue {
/**
* Get the hit test type.
*
* @since 9
*/
type: HitTestTypeV9;
/**
* Get the hit test extra data.
*
* @since 9
*/
extra: string;
}
```
- After change:
```ts
interface HitTestValue {
/**
* Get the hit test type.
*
* @since 9
*/
type: WebHitTestType;
/**
* Get the hit test extra data.
*
* @since 9
*/
extra: string;
}
```
**Adaptation Guide**
Replace **HitTestTypeV9** with **WebHitTestType**.
## cl.web.4 Parameter Type Change of loadUrl
Changed the type of the **headers** parameter in **loadUrl** to **WebHeader** to meet the naming conventions.
**Change Impact**
The **loadUrl** API that uses the **headers** parameter cannot be used in OpenHarmony 3.2.10.7 and later versions.
**Key API/Component Changes**
- Involved APIs:
loadUrl(url: string | Resource, headers?: Array\<HeaderV9>): void
- Before change:
```ts
loadUrl(url: string | Resource, headers?: Array<HeaderV9>): void
```
- After change:
```ts
loadUrl(url: string | Resource, headers?: Array<WebHeader>): void
```
**Adaptation Guide**
Change the type of the **headers** parameter in **loadUrl** from **HeaderV9** to **WebHeader**.
## cl.web.5 Return Value Type Change of getHitTest
Changed the return value type of the **getHitTest** API to **WebHitTest** to meet the naming conventions.
**Change Impact**
The **getHitTest** API cannot be used in OpenHarmony 3.2.10.7 and later versions.
**Key API/Component Changes**
- Involved APIs:
getHitTest(): HitTestTypeV9
- Before change:
```ts
getHitTest(): HitTestTypeV9
```
- After change:
```ts
getHitTest(): WebHitTestType
```
**Adaptation Guide**
Change the return value type of the **getHitTest** API from **HitTestTypeV9** to **WebHitTestType**.
## cl.web.6 Moving of the WebMessagePort Class
Moved the **WebMessagePort** class to **@ohos.web.webview.d.ts** and added error throwing.
**Change Impact**
If your application is developed based on earlier versions, note that the **d.ts** file storage location and the name of the module to be imported are changed. In addition, be mindful of the error codes now that the APIs in the class support error code processing.
**Key API/Component Changes**
- Involved APIs:
postMessageEvent(message: WebMessageEvent): void;
onMessageEvent(callback: (result: string) => void): void;
- Before change:
```ts
postMessageEvent(message: WebMessageEvent): void;
onMessageEvent(callback: (result: string) => void): void;
```
- After change:
```ts
postMessageEvent(message: WebMessage): void;
onMessageEvent(callback: (result: WebMessage) => void): void;
```
**Adaptation Guide**
Instead of importing APIs from the original **WebMessagePort** class, import APIs from **@ohos.web.webview** as follows:
```ts
import web_webview from '@ohos.web.webview';
```
## cl.web.7 Moving of the HitTestValue Class
Moved the **HitTestValue** class to **@ohos.web.webview.d.ts**; changed **HitTestValue** from a class to an API; changed the **getType** and **getExtra** from APIs to attributes.
**Change Impact**
If your application is developed based on earlier versions, note that the **d.ts** file storage location and the name of the module to be imported are changed.
**Key API/Component Changes**
- Involved APIs:
getType(): HitTestType;
getExtra(): string;
- Before change:
```ts
getType(): HitTestType;
getExtra(): string;
```
- After change:
```ts
type: WebHitTestType;
extra: string;
```
**Adaptation Guide**
Instead of importing APIs from the original **HitTestValue** class, import APIs from **@ohos.web.webview** as follows:
```ts
import web_webview from '@ohos.web.webview';
```
## cl.web.8 Moving of API Version 9 APIs Under WebCookie
Moved APIs of API version 9 in the **WebCookie** class to **web.webview.webview.WebCookieManager**
and added error throwing.
**Change Impact**
If your application is developed based on earlier versions, note that the **d.ts** file storage location and the name of the module to be imported are changed. In addition, be mindful of the error codes now that the APIs in the class support error code processing.
The APIs in the class are static.
**Key API/Component Changes**
- Involved APIs:
isCookieAllowed(): boolean;
isThirdPartyCookieAllowed(): boolean;
putAcceptCookieEnabled(accept: boolean): void;
putAcceptThirdPartyCookieEnabled(accept: boolean): void;
setCookie(url: string, value: string): boolean;
saveCookieSync(): boolean;
getCookie(url: string): string;
existCookie(): boolean;
deleteEntireCookie(): void;
deleteSessionCookie(): void;
- Before change:
```ts
isCookieAllowed(): boolean;
isThirdPartyCookieAllowed(): boolean;
putAcceptCookieEnabled(accept: boolean): void;
putAcceptThirdPartyCookieEnabled(accept: boolean): void;
setCookie(url: string, value: string): boolean;
saveCookieSync(): boolean;
getCookie(url: string): string;
existCookie(): boolean;
deleteEntireCookie(): void;
deleteSessionCookie(): void;
```
- After change:
```ts
static isCookieAllowed(): boolean;
static isThirdPartyCookieAllowed(): boolean;
static putAcceptCookieEnabled(accept: boolean): void;
static putAcceptThirdPartyCookieEnabled(accept: boolean): void;
static setCookie(url: string, value: string): void;
static saveCookieAsync(): Promise<void>;
static saveCookieAsync(callback: AsyncCallback<void>): void;
static getCookie(url: string): string;
static existCookie(): boolean;
static deleteEntireCookie(): void;
static deleteSessionCookie(): void;
```
**Adaptation Guide**
Instead of importing APIs from the original **WebCookie** class, import APIs from **@ohos.web.webview** as follows:
```ts
import web_webview from '@ohos.web.webview';
```
## cl.web.9 Moving of API Version 9 APIs Under WebController
Moved APIs of API version 9 in the **WebController** class to **web.webview.webview.WebviewController** and added error throwing.
**Change Impact**
If your application is developed based on earlier versions, note that the **d.ts** file storage location and the name of the module to be imported are changed. In addition, be mindful of the error codes now that the APIs in the class support error code processing.
The **getDefaultUserAgent** API is renamed **getUserAgent**.
**Key API/Component Changes**
- Involved APIs:
zoomIn(): boolean;
zoomOut(): boolean;
createWebMessagePorts(): Array\<WebMessagePort>;
postMessage(options: { message: WebMessageEvent, uri: string}): void;
getHitTestValue(): HitTestValue;
getWebId(): number;
getDefaultUserAgent(): string;
getTitle(): string;
getPageHeight(): number;
backOrForward(step: number): void;
searchAllAsync(searchString: string): void;
clearMatches(): void;
searchNext(forward: boolean): void;
clearSslCache(): void;
clearClientAuthenticationCache(): void;
getUrl(): string;
- Before change:
```ts
zoomIn(): boolean;
zoomOut(): boolean;
createWebMessagePorts(): Array<WebMessagePort>;
postMessage(options: { message: WebMessageEvent, uri: string}): void;
getHitTestValue(): HitTestValue;
getWebId(): number;
getDefaultUserAgent(): string;
getTitle(): string;
getPageHeight(): number;
backOrForward(step: number): void;
searchAllAsync(searchString: string): void;
clearMatches(): void;
searchNext(forward: boolean): void;
clearSslCache(): void;
clearClientAuthenticationCache(): void;
getUrl(): string;
```
- After change:
```ts
zoomIn(): void;
zoomOut(): void;
createWebMessagePorts(): Array<WebMessagePort>;
postMessage(name: string, ports: Array<WebMessagePort>, uri: string): void;
getHitTestValue(): HitTestValue;
getWebId(): number;
getUserAgent(): string;
getTitle(): string;
getPageHeight(): number;
backOrForward(step: number): void;
searchAllAsync(searchString: string): void;
clearMatches(): void;
searchNext(forward: boolean): void;
clearSslCache(): void;
clearClientAuthenticationCache(): void;
getUrl(): string;
```
**Adaptation Guide**
Instead of importing APIs from the original **WebController** class, import APIs from **@ohos.web.webview** as follows:
```ts
import web_webview from '@ohos.web.webview';
```
## cl.web.10 Moving of the WebAsyncController Class
Moved the APIs in the **WebAsyncController** class to the **web.webview.webview.WebviewController** class and added error throwing.
**Change Impact**
If your application is developed based on earlier versions, pay attention to error code processing.
**Key API/Component Changes**
- Involved APIs:
storeWebArchive(baseName: string, autoName: boolean): Promise\<string>;
storeWebArchive(baseName: string, autoName: boolean, callback : AsyncCallback\<string>): void;
- Before change:
```ts
storeWebArchive(baseName: string, autoName: boolean): Promise<string>;
storeWebArchive(baseName: string, autoName: boolean, callback : AsyncCallback<string>): void;
```
- After change:
```ts
storeWebArchive(baseName: string, autoName: boolean): Promise<string>;
storeWebArchive(baseName: string, autoName: boolean, callback : AsyncCallback<string>): void;
```
**Adaptation Guide**
Example:
```ts
// xxx.ets
import web_webview from '@ohos.web.webview'
@Entry
@Component
struct WebComponent {
controller: web_webview.WebviewController = new web_webview.WebviewController();
build() {
Column() {
Button('saveWebArchive')
.onClick(() => {
try {
this.controller.storeWebArchive("/data/storage/el2/base/", true, (error, filename) => {
if (error) {
console.info(`save web archive error: ` + JSON.stringify(error))
return;
}
if (filename != null) {
console.info(`save web archive success: ${filename}`)
}
});
} catch (error) {
console.error(`ErrorCode: ${error.code}, Message: ${error.message}`);
}
})
Web({ src: 'www.example.com', controller: this.controller })
}
}
}
```
## cl.web.11 Removal of webDebuggingAccess
The definition of the **webDebuggingAccess** API is inappropriate. This API should take effect for all **Web** instances. In light of this, it is removed and replaced by the new API **setWebDebuggingAccess**.
**Change Impacts**
This API must be deprecated and replaced with the **setWebDebuggingAccess** API.
**Key API/Component Changes**
| Class| API Type| Declaration| Change Type|
| -- | -- | -- | -- |
|WebAttribute | method | webDebugggingAccess(webDebugggingAccess: boolean): WebAttribute| Deleted|
**Adaptation Guide**
Use the new API **setWebDebuggingAccess**.
## cl.web.12 Adding of setWebDebuggingAccess
Added the static API **setWebDebuggingAccess** to **WebviewController**. It sets whether to enable web debugging works for all **Web** instances.
**Change Impacts**
The original **webDebugggingAccess** API must be replaced with the new API in the application.
**Key API/Component Changes**
| Class| API Type| Declaration| Change Type|
| -- | -- | -- | -- |
|webview.WebviewController | method | static setWebDebugggingAccess(webDebugggingAccess: boolean): void| Added|
**Adaptation Guide**
The following exemplifies how to enable web debugging:
```ts
// xxx.ets
import web_webview from '@ohos.web.webview';
@Entry
@Component
struct WebComponent {
controller: web_webview.WebviewController = new web_webview.WebviewController();
aboutToAppear():void {
try {
web_webview.WebviewController.setWebDebuggingAccess(true);
} catch(error) {
console.error(`ErrorCode: ${error.code}, Message: ${error.message}`);
}
}
build() {
Column() {
Web({ src: 'www.example.com', controller: this.controller })
}
}
}
```
# Ability Framework Changelog
## cl.ability.1 AreaMode APIs Changed
Duplicate **AreaMode** APIs are deleted.
**Change Impact**
JS APIs in API version 9 are affected. Your application needs to adapt these APIs so that it can properly implement features in the SDK environment of the new version.
**Key API/Component Changes**
| Module | Class | Method/Attribute/Enum/Constant | Change Type|
| ------------------------- | ------------------- | ------------------------------------------------------------ | -------- |
| @ohos.app.ability.common.d.ts | common.AreaMode | | Deleted |
| application/Context.d.ts | AreaMode | | Deleted |
**Adaptation Guide**
Use **AreaMode** in **@ohos.app.ability.contextConstant.d.ts**.
```ts
import contextConstant from '@ohos.app.ability.contextConstant';
let area: contextConstant.AreaMode = contextConstant.AreaMode.EL1;
```
## cl.ability.2 killProcessesBySelf Renamed
The **killProcessesBySelf** API is renamed **killAllProcesses**.
**Change Impact**
JS APIs in API version 9 are affected. Your application needs to adapt these APIs so that it can properly implement features in the SDK environment of the new version.
**Key API/Component Changes**
| Module | Class | Method/Attribute/Enum/Constant | Change Type|
| ------------------------------ | ------------------ | ----------------------------------------------------- | -------- |
| application/ApplicationContext | ApplicationContext | killProcessesBySelf(): Promise\<void\>; | Deleted |
| application/ApplicationContext | ApplicationContext | killProcessesBySelf(callback: AsyncCallback\<void\>); | Deleted |
| application/ApplicationContext | ApplicationContext | killAllProcesses(): Promise\<void\>; | Added |
| application/ApplicationContext | ApplicationContext | killAllProcesses(callback: AsyncCallback\<void\>); | Added |
**Adaptation Guide**
The following code snippet shows how to call **killProcessesBySelf** in an application.
Code before the change:
```ts
let context: common.UIAbilityContext = globalThis.abilityContext;
let appContext = context.getApplicationContext();
appContext.killProcessesBySelf()
```
Code after the change:
```ts
let context: common.UIAbilityContext = globalThis.abilityContext;
let appContext = context.getApplicationContext();
appContext.killAllProcesses()
```
## cl.ability.3 getProcessRunningInformation Renamed
The **getProcessRunningInformation** API is renamed **getRunningProcessInformation**.
**Change Impact**
JS APIs in API version 9 are affected. Your application needs to adapt these APIs so that it can properly implement features in the SDK environment of the new version.
**Key API/Component Changes**
| Module | Class | Method/Attribute/Enum/Constant | Change Type|
| ----------------------------------- | ------------------ | ------------------------------------------------------------ | -------- |
| @ohos.app.ability.appManager.d.ts | appManager | function getProcessRunningInformation(): Promise\<Array\<ProcessRunningInformation\>\>; | Deleted |
| @ohos.app.ability.appManager.d.ts | appManager | function getProcessRunningInformation(callback: AsyncCallback\<Array\<ProcessRunningInformation\>\>): void; | Deleted |
| @ohos.app.ability.appManager.d.ts | appManager | function getRunningProcessInformation(): Promise\<Array\<ProcessInformation\>\>; | Added |
| @ohos.app.ability.appManager.d.ts | appManager | function getRunningProcessInformation(callback: AsyncCallback\<Array\<ProcessInformation\>\>): void; | Added |
| application/ApplicationContext.d.ts | ApplicationContext | getProcessRunningInformation(): Promise\<Array\<ProcessRunningInformation\>\>; | Deleted |
| application/ApplicationContext.d.ts | ApplicationContext | getProcessRunningInformation(callback: AsyncCallback\<Array\<ProcessRunningInformation\>\>): void; | Deleted |
| application/ApplicationContext.d.ts | ApplicationContext | getRunningProcessInformation(): Promise\<Array\<ProcessInformation\>\>; | Added |
| application/ApplicationContext.d.ts | ApplicationContext | getRunningProcessInformation(callback: AsyncCallback\<Array\<ProcessInformation\>\>): void; | Added |
**Adaptation Guide**
The following code snippet shows how to call **getProcessRunningInformation** in an application.
Code before the change:
```ts
let context: common.UIAbilityContext = globalThis.abilityContext;
let appContext = context.getApplicationContext();
appContext.getProcessRunningInformation()
```
Code after the change:
```ts
let context: common.UIAbilityContext = globalThis.abilityContext;
let appContext = context.getApplicationContext();
appContext.getRunningProcessInformation()
```
## cl.ability.4 WantConstant.Flags API Changed
**WantConstant.Flags** has multiple invalid flag definitions. These invalid flags are deleted.
**Change Impact**
JS APIs in API version 9 are affected. Your application needs to adapt these APIs so that it can properly implement features in the SDK environment of the new version.
**Key API/Component Changes**
| Module | Class | Method/Attribute/Enum/Constant | Change Type|
| ------------------------- | ------------------- | ------------------------------------------------------------ | -------- |
| @ohos.app.ability.wantConstant.d.ts | wantConstant.Flags | FLAG_ABILITY_FORWARD_RESULT | Deleted |
| @ohos.app.ability.wantConstant.d.ts | wantConstant.Flags | FLAG_ABILITY_CONTINUATION | Deleted |
| @ohos.app.ability.wantConstant.d.ts | wantConstant.Flags | FLAG_NOT_OHOS_COMPONENT | Deleted |
| @ohos.app.ability.wantConstant.d.ts | wantConstant.Flags | FLAG_ABILITY_FORM_ENABLED | Deleted |
| @ohos.app.ability.wantConstant.d.ts | wantConstant.Flags | FLAG_AUTH_PERSISTABLE_URI_PERMISSION | Deleted |
| @ohos.app.ability.wantConstant.d.ts | wantConstant.Flags | FLAG_AUTH_PREFIX_URI_PERMISSION | Deleted |
| @ohos.app.ability.wantConstant.d.ts | wantConstant.Flags | FLAG_ABILITYSLICE_MULTI_DEVICE | Deleted |
| @ohos.app.ability.wantConstant.d.ts | wantConstant.Flags | FLAG_START_FOREGROUND_ABILITY | Deleted |
| @ohos.app.ability.wantConstant.d.ts | wantConstant.Flags | FLAG_ABILITY_CONTINUATION_REVERSIBLE | Deleted |
| @ohos.app.ability.wantConstant.d.ts | wantConstant.Flags | FLAG_INSTALL_WITH_BACKGROUND_MODE | Deleted |
| @ohos.app.ability.wantConstant.d.ts | wantConstant.Flags | FLAG_ABILITY_CLEAR_MISSION | Deleted |
| @ohos.app.ability.wantConstant.d.ts | wantConstant.Flags | FLAG_ABILITY_NEW_MISSION | Deleted |
| @ohos.app.ability.wantConstant.d.ts | wantConstant.Flags | FLAG_ABILITY_MISSION_TOP | Deleted |
## cl.ability.5 WantConstant.Action API Changed
**WantConstant.Action** has multiple invalid action definitions. These invalid actions are deleted.
**Change Impact**
JS APIs in API version 9 are affected. Your application needs to adapt these APIs so that it can properly implement features in the SDK environment of the new version.
**Key API/Component Changes**
| Module | Class | Method/Attribute/Enum/Constant | Change Type|
| ------------------------- | ------------------- | ------------------------------------------------------------ | -------- |
| @ohos.app.ability.wantConstant.d.ts | wantConstant.Action | ACTION_APP_ACCOUNT_AUTH | Deleted |
| @ohos.app.ability.wantConstant.d.ts | wantConstant.Action | ACTION_MARKET_DOWNLOAD | Deleted |
| @ohos.app.ability.wantConstant.d.ts | wantConstant.Action | ACTION_MARKET_CROWDTEST | Deleted |
| @ohos.app.ability.wantConstant.d.ts | wantConstant.Action | DLP_PARAMS_SANDBOX | Deleted |
| @ohos.app.ability.wantConstant.d.ts | wantConstant.Action | DLP_PARAMS_BUNDLE_NAME | Deleted |
| @ohos.app.ability.wantConstant.d.ts | wantConstant.Action | DLP_PARAMS_MODULE_NAME | Deleted |
| @ohos.app.ability.wantConstant.d.ts | wantConstant.Action | DLP_PARAMS_ABILITY_NAME | Deleted |
## cl.ability.6 Caller APIs Changed
Caller APIs use the **Parcelable** and **MessageSequence** objects provided by RPC in API version 9 to replace the deprecated **Sequenceable** and **MessageParcel** object.
**Change Impact**
JS APIs in API version 9 are affected. Your application needs to adapt these APIs so that it can properly implement features in the SDK environment of the new version.
**Key API/Component Changes**
| Module | Class | Method/Attribute/Enum/Constant | Change Type|
| ------------------------- | ------------------- | ------------------------------------------------------------ | -------- |
| api/@ohos.app.ability.UIAbility.d.ts | CalleeCallback | (indata: rpc.MessageParcel): rpc.Sequenceable; | Changed to **(indata: rpc.MessageSequence): rpc.Parcelable;**. |
| api/@ohos.app.ability.UIAbility.d.ts | Caller | call(method: string, data: rpc.Sequenceable): Promise<void>; | Changed to **call(method: string, data: rpc.Parcelable): Promise<void>;**. |
| api/@ohos.app.ability.UIAbility.d.ts | Caller | callWithResult(method: string, data: rpc.Sequenceable): Promise<rpc.MessageParcel>; | Changed to **callWithResult(method: string, data: rpc.Parcelable): Promise<rpc.MessageSequence>;**. |
**Adaptation Guide**
The following illustrates how to call the caller APIs in your application.
Code before the change:
```ts
class MyMessageAble{
name:""
str:""
num: 1
constructor(name, str) {
this.name = name;
this.str = str;
}
marshalling(messageParcel) {
messageParcel.writeInt(this.num);
messageParcel.writeString(this.str);
console.log('MyMessageAble marshalling num[' + this.num + '] str[' + this.str + ']');
return true;
}
unmarshalling(messageParcel) {
this.num = messageParcel.readInt();
this.str = messageParcel.readString();
console.log('MyMessageAble unmarshalling num[' + this.num + '] str[' + this.str + ']');
return true;
}
};
let method = 'call_Function';
function funcCallBack(pdata) {
console.log('Callee funcCallBack is called ' + pdata);
let msg = new MyMessageAble("test", "");
pdata.readSequenceable(msg);
return new MyMessageAble("test1", "Callee test");
}
export default class MainUIAbility extends UIAbility {
onCreate(want, launchParam) {
console.log('Callee onCreate is called');
try {
this.callee.on(method, funcCallBack);
} catch (error) {
console.log('Callee.on catch error, error.code: ' + error.code +
' error.message: ' + error.message);
}
}
}
```
Code after the change:
```ts
class MyMessageAble{
name:""
str:""
num: 1
constructor(name, str) {
this.name = name;
this.str = str;
}
marshalling(messageSequence) {
messageSequence.writeInt(this.num);
messageSequence.writeString(this.str);
console.log('MyMessageAble marshalling num[' + this.num + '] str[' + this.str + ']');
return true;
}
unmarshalling(messageSequence) {
this.num = messageSequence.readInt();
this.str = messageSequence.readString();
console.log('MyMessageAble unmarshalling num[' + this.num + '] str[' + this.str + ']');
return true;
}
};
let method = 'call_Function';
function funcCallBack(pdata) {
console.log('Callee funcCallBack is called ' + pdata);
let msg = new MyMessageAble("test", "");
pdata.readParcelable(msg);
return new MyMessageAble("test1", "Callee test");
}
export default class MainUIAbility extends UIAbility {
onCreate(want, launchParam) {
console.log('Callee onCreate is called');
try {
this.callee.on(method, funcCallBack);
} catch (error) {
console.log('Callee.on catch error, error.code: ' + error.code +
' error.message: ' + error.message);
}
}
}
```
## cl.ability.7 WantConstant.Flags API Changed
The **wantConstant** API had two similar enums. Now the two enums are combined into one.
**Change Impact**
JS APIs in API version 9 are affected. Your application needs to adapt these APIs so that it can properly implement features in the SDK environment of the new version.
**Key API/Component Changes**
| Module | Class | Method/Attribute/Enum/Constant | Change Type|
| ----------------------------------- | ---------------------- | ----------------------------------- | -------- |
| @ohos.app.ability.wantConstant.d.ts | wantConstant.Parameter | ABILITY_BACK_TO_OTHER_MISSION_STACK | Deleted |
| @ohos.app.ability.wantConstant.d.ts | wantConstant.Params | ABILITY_BACK_TO_OTHER_MISSION_STACK | Added |
**Adaptation Guide**
Use **ABILITY_BACK_TO_OTHER_MISSION_STACK** in **@ohos.app.ability.wantConstant.d.ts**.
```ts
import wantConstant from '@ohos.app.ability.wantConstant';
let backToOtherMissionStack: wantConstant.Params = wantParam.Params.ABILITY_BACK_TO_OTHER_MISSION_STACK;
```
# ArkUI Subsystem Changelog
## cl.arkui.1 Return Value Type Change of getInspectorTree
**Change Impact**
The code that uses the **getInspectorTree** API in versions earlier than OpenHarmony 3.2.10.7 must be adapted.
**Key API/Component Changes**
The return value of the **getInspectorTree** API is changed from the string type to the Object type.
**Adaptation Guide**
Adapt the code that takes the return value of **getInspectorTree** as a string.The sample code is as follows:
- Before change:
```typescript
console.info(getInspectorTree())
```
- After change:
```typescript
console.info(JSON.stringify(getInspectorTree()))
```
## cl.arkui.2 Deprecation the forceRebuild Attribute of \<GridItem>
**Change Impact**
None. The attribute has no effect.
**Key API/Component Changes**
Deprecate the **forceRebuild** attribute of the **\<GridItem>** component.
**Adaptation Guide**
Delete the code that uses the **forceRebuild** attribute. This will not affect the functionality of the **\<GridItem>** component.
## cl.arkui.3 Plugin Module API Changes
### 1. API Change in the **PluginComponentTemplate** Module
Renamed the **ability** parameter **bundleName** to more clearly indicate the intended meaning.
You need to adapt your application.
**Change Impact**
The application developed based on earlier versions must be adapted to the change. Otherwise, build errors will occur.
**Key API/Component Changes**
- Involved APIs:
interface PluginComponentTemplate {
source: string;
bundleName: string;
}
interface PluginComponentInterface {
(value: { template: PluginComponentTemplate; data: any }): PluginComponentAttribute;
}
- Before change:
```js
interface PluginComponentTemplate { source: string; ability: string; }
interface PluginComponentInterface {
(value: { template: PluginComponentTemplate; data: any }): PluginComponentAttribute;
}
```
- After change:
```js
interface PluginComponentTemplate { source: string; bundleName: string; }
interface PluginComponentInterface {
(value: { template: PluginComponentTemplate; data: any }): PluginComponentAttribute;
}
```
**Adaptation Guide**
Use the new API. The sample code is as follows:
- Before change:
```js
PluginComponent({
template: { source: 'plugincomponent1', ability: 'com.example.plugin' },
data: { 'countDownStartValue': 'new countDownStartValue' }
}).size({ width: 500, height: 100 })
```
- After change:
```js
PluginComponent({
template: { source: 'plugincomponent1', bundleName: 'com.example.plugin' },
data: { 'countDownStartValue': 'new countDownStartValue' }
}).size({ width: 500, height: 100 })
```
### 2. API Change in the **pluginComponentManager** Module
Renamed the **want** parameter **target** to more clearly indicate the intended meaning.
You need to adapt your application.
**Change Impact**
The application developed based on earlier versions must be adapted to the change. Otherwise, alarms will arise. Though the build may be successful, the API will not work as intended.
**Key API/Component Changes**
- Involved APIs:
interface PushParameterForStage {
owner: Want;
target: Want;
name: string;
data: KVObject;
extraData: KVObject;
jsonPath?: string;
}
function push(param: PushParameterForStage, callback: AsyncCallback\<void>): void;
interface RequestParameterForStage {
owner: Want;
target: Want;
name: string;
data: KVObject;
jsonPath?: string;
}
function request(param: RequestParameterForStage, callback: AsyncCallback\<RequestCallbackParameters>): void;
- Before change:
```js
interface PushParameterForStage {
owner: Want;
want: Want;
name: string;
data: KVObject;
extraData: KVObject;
jsonPath?: string;
}
function push(param: PushParameterForStage, callback: AsyncCallback<void>): void;
interface RequestParameterForStage {
owner: Want;
want: Want;
name: string;
data: KVObject;
jsonPath?: string;
}
function request(param: RequestParameterForStage, callback: AsyncCallback<RequestCallbackParameters>): void;
```
- After change:
```js
interface PushParameterForStage {
owner: Want;
target: Want;
name: string;
data: KVObject;
extraData: KVObject;
jsonPath?: string;
}
function push(param: PushParameterForStage, callback: AsyncCallback<void>): void;
interface RequestParameterForStage {
owner: Want;
target: Want;
name: string;
data: KVObject;
jsonPath?: string;
}
function request(param: RequestParameterForStage, callback: AsyncCallback<RequestCallbackParameters>): void;
```
**Adaptation Guide**
Use the new API. The sample code is as follows:
- Before change:
```js
import pluginComponentManager from '@ohos.pluginComponent'
pluginComponentManager.push({
owner:{
bundleName:"com.example.provider",
abilityName:"com.example.provider.MainAbility"
},
want: {
bundleName: "com.example.provider",
abilityName: "com.example.provider.MainAbility",
},
name: "ets/pages/plugin2.js",
data: {
"js": "ets/pages/plugin.js",
"key_1": 1111,
},
extraData: {
"extra_str": "this is push event"
},
jsonPath: "",
},
(err, data) => {
console.log("push_callback:err: " ,JSON.stringify(err));
console.log("push_callback:data: " , JSON.stringify(data));
console.log("push_callback: push ok!");
}
)
pluginComponentManager.request({
owner:{
bundleName:"com.example.provider",
abilityName:"com.example.provider.MainAbility"
},
want: {
bundleName: "com.example.provider",
abilityName: "ets/pages/plugin2.js",
},
name: "plugintemplate",
data: {
"key_1": " myapplication plugin component test",
"key_2": 123456
},
jsonPath: "",
},
(err, data) => {
console.log("request_callback: componentTemplate.ability=" + data.componentTemplate.ability)
console.log("request_callback: componentTemplate.source=" + data.componentTemplate.source)
}
)
```
- After change:
```js
import pluginComponentManager from '@ohos.pluginComponent'
pluginComponentManager.push({
owner:{
bundleName:"com.example.provider",
abilityName:"com.example.provider.MainAbility"
},
target: {
bundleName: "com.example.provider",
abilityName: "com.example.provider.MainAbility",
},
name: "ets/pages/plugin2.js",
data: {
"js": "ets/pages/plugin.js",
"key_1": 1111,
},
extraData: {
"extra_str": "this is push event"
},
jsonPath: "",
},
(err, data) => {
console.log("push_callback:err: " ,JSON.stringify(err));
console.log("push_callback:data: " , JSON.stringify(data));
console.log("push_callback: push ok!");
}
)
pluginComponentManager.request({
owner:{
bundleName:"com.example.provider",
abilityName:"com.example.provider.MainAbility"
},
target: {
bundleName: "com.example.provider",
abilityName: "ets/pages/plugin2.js",
},
name: "plugintemplate",
data: {
"key_1": " myapplication plugin component test",
"key_2": 123456
},
jsonPath: "",
},
(err, data) => {
console.log("request_callback: componentTemplate.ability=" + data.componentTemplate.ability)
console.log("request_callback: componentTemplate.source=" + data.componentTemplate.source)
}
)
```
# Bundle Manager Subsystem Changelog
## cl.bundlemanager.1 Deleted getAbilityIcon
The **getAbilityIcon** API in [@ohos.bundle.bundleManager.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/@ohos.bundle.bundleManager.d.ts) is deleted. The **getMediaContent** API in [@ohos.resourceManager.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/@ohos.resourceManager.d.ts) can be used instead.
**Change Impact**<br>
The **getAbilityIcon** API does not take effect.
**Key API/Component Changes**<br>
The **getAbilityIcon** API is deleted from **@ohos.bundle.bundleManager.d.ts**.
**Adaptation Guide**<br>
If your application uses **getAbilityIcon** in **@ohos.bundle.bundleManager.d.ts**, replace it with **getMediaContent** in **@ohos.resourceManager.d.ts**. You need to obtain the icon ID in advance. For details, see [Usage Guide](../../../application-dev/reference/apis/js-apis-resource-manager.md#getmediacontent9).
## cl.bundlemanager.2 Bottom-Layer Capability Changed So That Only the System Resource HAP Supports Custom Permissions
Only the system resource HAP supports custom permissions. During HAP parsing, the bundle manager module parses the **definePermissions** field only in the configuration file of the resource HAP (bundle name: **ohos.global.systemres**), but not this field in other HAPs. This field is used to define permissions.
If an application requires custom permissions, add the permissions under the **definePermissions** field in the [configuration file](https://gitee.com/openharmony/utils_system_resources/blob/master/systemres/main/config.json) of the system resource HAP. For details about the permission format, see [Defining Permissions](../../../application-dev/quick-start/module-structure.md#internal-structure-of-the-definepermissions-attribute).
**Change Impact**<br>
After an upgrade to the new version image, the custom permission of the application does not take effect, and the authorization fails.
**Key API/Component Changes**<br>
The bottom-layer capability of the bundle manager module is changed. Only the system resource HAP supports custom permissions.
**Adaptation Guide**<br>
If an application requires custom permissions, add the permissions under the **definePermissions** field in the [configuration file](https://gitee.com/openharmony/utils_system_resources/blob/master/systemres/main/config.json) of the system resource HAP. For details about the permission format, see [Defining Permissions](../../../application-dev/quick-start/module-structure.md#internal-structure-of-the-definepermissions-attribute).
## cl.bundlemanager.3 Level-2 Module File Names Changed
The level-2 module file names of the bundle manager module are changed to their respective API names in the file, as listed below.
| Original File Name|New File Name|
|----|----|
| bundleManager/abilityInfo.d.ts | bundleManager/AbilityInfo.d.ts |
| bundleManager/applicationInfo.d.ts | bundleManager/ApplicationInfo.d.ts |
| bundleManager/bundleInfo.d.ts | bundleManager/BundleInfo.d.ts |
| bundleManager/dispatchInfo.d.ts | bundleManager/DispatchInfo.d.ts |
| bundleManager/elementName.d.ts | bundleManager/ElementName.d.ts |
| bundleManager/extensionAbilityInfo.d.ts | bundleManager/ExtensionAbilityInfo.d.ts |
| bundleManager/hapModuleInfo.d.ts | bundleManager/HapModuleInfo.d.ts |
| bundleManager/launcherAbilityInfo.d.ts | bundleManager/LauncherAbilityInfo.d.ts |
| bundleManager/metadata.d.ts | bundleManager/Metadata.d.ts |
| bundleManager/packInfo.d.ts | bundleManager/BundlePackInfo.d.ts |
| bundleManager/permissionDef.d.ts | bundleManager/PermissionDef.d.ts |
| bundleManager/remoteAbilityInfo.d.ts | bundleManager/RemoteAbilityInfo.d.ts |
| bundleManager/shortcutInfo.d.ts | bundleManager/ShortcutInfo.d.ts |
To sum up, except **packInfo**, which is changed to **BundlePackInfo**, the other file names are changed to start with uppercase letters.
**Change Impact**<br>
The change of the level-2 module file names does not affect the use of the level-1 module. If a level-2 module interface under **bundleManager** is directly imported to the .ts file and an error is reported during compilation on DevEco Studio, you must change the name of the imported file.
**Key API/Component Changes**<br>
The .d.ts file names in the **bundleManager** folder are changed to their respective API names in the file.
**Adaptation Guide**<br>
Generally, no adaptation is required. If a file in the **bundleManager** folder is directly imported to the application, you must change the imported file name as follows:
**Before change:**
```ts
import {AbilityInfo} from 'bundleManger/abilityInfo';
import {ExtensionAbilityInfo} from 'bundleManger/extensionAbilityInfo';
import {BundlePackInfo} from 'bundleManger/packInfo';
```
**After change:**
```ts
import {AbilityInfo} from 'bundleManger/AbilityInfo';
import {ExtensionAbilityInfo} from 'bundleManger/ExtensionAbilityInfo';
import {BundlePackInfo} from 'bundleManger/BundlePackInfo';
```
## cl.bundlemanager.4 LaunchType Enum Type Name Changed from STANDARD to MULTITON
The enum type name of [LaunchType](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/@ohos.bundle.bundleManager.d.ts) is changed from **STANDARD** to **MULTITON**. The enum value remains unchanged, indicating the multi-instance type.
**Change Impact**<br>
The **LaunchType.STANDARD** type does not take effect.
**Key API/Component Changes**<br>
The enum type name of **LaunchType** is changed from **STANDARD** to **MULTITON**.
**Adaptation Guide**<br>
Change **LaunchType.STANDARD** to **LaunchType.MULTITON** for your application.
## cl.bundlemanager.5 Changed the isVisible Field in the AbilityInfo Struct to exported
The **isVisible** field in the [AbilityInfo](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/AbilityInfo.d.ts) struct is changed to **exported**. The type remains unchanged, indicating whether the ability can be exported and used by other abilities.
**Change Impact**<br>
The **isVisible** field does not take effect.
**Key API/Component Changes**<br>
The **isVisible** field in the [AbilityInfo](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/AbilityInfo.d.ts) struct is changed to **exported**, and the type remains unchanged.
**Adaptation Guide**<br>
Change **isVisible** to **exported** for your application.
## cl.bundlemanager.6 Changed the isVisible Field in the ExtensionAbilityInfo Struct to exported
The **isVisible** field in the [ExtensionAbilityInfo](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/ExtensionAbilityInfo.d.ts) struct is changed to **exported**. The type remains unchanged, indicating whether the ability can be exported and used by other abilities.
**Change Impact**<br>
The **isVisible** field does not take effect.
**Key API/Component Changes**<br>
The **isVisible** field in the [ExtensionAbilityInfo](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/ExtensionAbilityInfo.d.ts) struct is changed to **exported**, and the type remains unchanged.
**Adaptation Guide**<br>
Change **isVisible** to **exported** for your application.
## cl.bundlemanager.7 Changed the visible Field in the ModuleAbilityInfo Struct to exported
The **visible** field in the [ModuleAbilityInfo](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/BundlePackInfo.d.ts) struct is changed to **exported**. The type remains unchanged, indicating whether the ability can be exported and used by other abilities.
**Change Impact**<br>
The **visible** field does not take effect.
**Key API/Component Changes**<br>
The **visible** field in the [ModuleAbilityInfo](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/BundlePackInfo.d.ts) struct is changed to **exported**, and the type remains unchanged.
**Adaptation Guide**<br>
Change **visible** to **exported** for your application.
## cl.bundlemanager.8 Deleted the distributedNotificationEnabled Tag from the app.json File
The [distributedNotificationEnabled](../../../application-dev/quick-start/app-configuration-file.md) tag is deleted from the **app.json** file.
**Change Impact**<br>
If this tag is used, an error is reported during compilation on DevEco Studio.
**Adaptation Guide**<br>
Delete this tag from the configuration file.
## cl.bundlemanager.9 Deleted the entityType Tag from the app.json File
The [entityType](../../../application-dev/quick-start/app-configuration-file.md) tag is deleted from the **app.json** file.
**Change Impact**<br>
If this tag is used, an error is reported during compilation on DevEco Studio.
**Adaptation Guide**<br>
Delete this tag from the configuration file.
## cl.bundlemanager.10 Deleted the keepAlive Tag from the app.json File
The [keepAlive](../../../application-dev/quick-start/app-configuration-file.md) tag is deleted from the **app.json** file.
**Change Impact**<br>
If this tag is used, an error is reported during compilation on DevEco Studio.
**Adaptation Guide**<br>
Delete this tag from the configuration file.
## cl.bundlemanager.11 Deleted the removable Tag from the app.json File
The [removable](../../../application-dev/quick-start/app-configuration-file.md) tag is deleted from the **app.json** file.
**Change Impact**<br>
If this tag is used, an error is reported during compilation on DevEco Studio.
**Adaptation Guide**<br>
Delete this tag from the configuration file.
## cl.bundlemanager.12 Deleted the singleton Tag from the app.json File
The [singleton](../../../application-dev/quick-start/app-configuration-file.md) tag is deleted from the **app.json** file.
**Change Impact**<br>
If this tag is used, an error is reported during compilation on DevEco Studio.
**Adaptation Guide**<br>
Delete this tag from the configuration file.
## cl.bundlemanager.13 Deleted the userDataClearable Tag from the app.json File
The [userDataClearable](../../../application-dev/quick-start/app-configuration-file.md) tag is deleted from the **app.json** file.
**Change Impact**<br>
If this tag is used, an error is reported during compilation on DevEco Studio.
**Adaptation Guide**<br>
Delete this tag from the configuration file.
## cl.bundlemanager.14 No Longer Chinese Characters for the name Tag under module in the module.json File
The value of [name](../../../application-dev/quick-start/module-configuration-file.md) under **module** in the **module.json** file does not support Chinese characters.
**Change Impact**<br>
If the tag is set to Chinese, an error is reported during compilation on DevEco Studio.
**Adaptation Guide**<br>
Set this tag to English.
## cl.bundlemanager.15 No Longer Chinese Characters for the name Tag under ability in the module.json File
The value of [name](../../../application-dev/quick-start/module-configuration-file.md) under **ability** in the **module.json** file does not support Chinese characters.
**Change Impact**<br>
If the tag is set to Chinese, an error is reported during compilation on DevEco Studio.
**Adaptation Guide**<br>
Set this tag to English.
## cl.bundlemanager.16 Deleted the uiSyntax Tag from the module.json File
The [uiSyntax](../../../application-dev/quick-start/module-configuration-file.md) tag is deleted from the **module.json** file.
**Change Impact**<br>
If this tag is used, an error is reported during compilation on DevEco Studio.
**Adaptation Guide**<br>
Delete this tag from the configuration file.
## cl.bundlemanager.17 Changed srcEntrance to srcEntry in the module.json File
The [srcEntrance](../../../application-dev/quick-start/module-configuration-file.md) tag under **module** and **ability** in the **module.json** file is changed to **srcEntry**.
**Change Impact**<br>
If the **srcEntrance** tag is used, an error is reported during compilation on DevEco Studio.
**Adaptation Guide**<br>
Replace the **srcEntrance** tag with **srcEntry** in the configuration file.
## cl.bundlemanager.18 Deleted the apiVersion Tag Under distroFilter from the module.json File
The **apiVersion** tag under [distroFilter](../../../application-dev/quick-start/module-configuration-file.md) is deleted from the **module.json** file.
**Change Impact**<br>
If this tag is used, an error is reported during compilation on DevEco Studio.
**Adaptation Guide**<br>
Delete this tag from the configuration file.
## cl.bundlemanager.19 Changed distroFilter to distributionFilter in the module.json File
The [distroFilter](../../../application-dev/quick-start/module-configuration-file.md) tag in the **module.json** file is changed to **distributionFilter**.
**Change Impact**<br>
If the **distroFilter** tag is used, an error is reported during compilation on DevEco Studio.
**Adaptation Guide**<br>
Replace **distroFilter** with **distributionFilter** in the configuration file.
## cl.bundlemanager.20 Changed standard of launchType to multiton in the module.json File
The **standard** mode of the [launchType](../../../application-dev/quick-start/module-configuration-file.md) tag in the **module.json** file is changed to **multiton**.
**Adaptation Guide**<br>
Replace **standard** of **launchType** with **multiton** in the configuration file.
## cl.bundlemanager.20 Changed visible of abilities to exported in the module.json File
The **visible** tag under [abilities](../../../application-dev/quick-start/module-configuration-file.md) in the [module.json] file is changed to **exported**, indicating whether the ability supports export and can be used by other ability.
**Adaptation Guide**<br>
Replace **visible** under **abilities** with **exported** in the configuration file.
# Util Subsystem Changelog
Compared with OpenHarmony 3.2 Beta4, OpenHarmony 3.2.10.7(MR) has the following API changes in the util subsystem.
## cl.util.1. randomUUID Name Changed
The **randomUUID** function name is changed to **generateRandomUUID**.
Before change: function randomUUID(entropyCache?: boolean): string <br>After change: function generateRandomUUID(entropyCache?: boolean): string
You need to adapt your application.
**Change Impact**
JS APIs in API version 9 are affected. Your application needs to adapt these APIs so that it can properly implement features in the SDK environment of the new version.
**Key API/Component Changes**
| Module | Method/Attribute/Enum/Constant | Change Type|
| :---------- | ------------------- | ------- |
| @ohos.util | function randomUUID(entropyCache?: boolean): string | Deleted |
| @ohos.util | function generateRandomUUID(entropyCache?: boolean): string| Added |
**Adaptation Guide**
Refer to the code snippet below to call **generateRandomUUID** in your application.
Example:
```ts
import util from '@ohos.util'
let uuid = util.generateRandomUUID(true);
console.log("RFC 4122 Version 4 UUID:" + uuid);
// Output:
// RFC 4122 Version 4 UUID:88368f2a-d5db-47d8-a05f-534fab0a0045
```
## cl.util.2 randomBinaryUUID Name Changed
The **randomBinaryUUID** function name is changed to **generateRandomBinaryUUID**.
Before change: function randomBinaryUUID(entropyCache?: boolean): Uint8Array<br>After change: function generateRandomBinaryUUID(entropyCache?: boolean): Uint8Array
You need to adapt your application.
**Change Impact**
JS APIs in API version 9 are affected. Your application needs to adapt these APIs so that it can properly implement features in the SDK environment of the new version.
**Key API/Component Changes**
| Module | Method/Attribute/Enum/Constant | Change Type|
| :---------- | ------------------- | ------- |
| @ohos.util | function randomBinaryUUID(entropyCache?: boolean): Uint8Array; | Deleted |
| @ohos.util | function generateRandomBinaryUUID(entropyCache?: boolean): Uint8Array| Added |
**Adaptation Guide**
Refer to the code snippet below to call **generateRandomBinaryUUID** in your application.
Example:
```ts
import util from '@ohos.util'
let uuid = util.generateRandomBinaryUUID(true);
console.log(JSON.stringify(uuid));
// Output:
// 138,188,43,243,62,254,70,119,130,20,235,222,199,164,140,150
```
## cl.util.3. contains Parameter Type in the LRUCache Class Changed
The **contains** parameter type in the LRUCache class is changed from **object** to **K**.
Before change: contains(key: object): boolean <br>After change: contains(key: K): boolean
You need to adapt your application.
**Change Impact**
JS APIs in API version 9 are affected. Your application needs to adapt these APIs so that it can properly implement features in the SDK environment of the new version.
**Key API/Component Changes**
| Module | Class | Method/Attribute/Enum/Constant | Change Type|
| :-------- | ---------| -------------------------------- | -------- |
| @ohos.util | LRUCache | contains(key: object): boolean | Deleted |
| @ohos.util | LRUCache | contains(key: K): boolean | Added |
**Adaptation Guide**
Follow the code snippet to use the **contains** function in your application.
Example:
```ts
import util from '@ohos.util'
let pro = new util.LRUCache();
pro.put(2,10);
let obj = {1:"key"};
let result = pro.contains(obj);
```
# Ability Framework Changelog
Compared with OpenHarmony 3.2 Release, OpenHarmony 3.2.12.2 provides more detailed error code information for the APIs of the ability framework.
## cl.ability.1 Added and Optimized API Error Code Description
The error code description and all error codes that may be returned by the APIs are commented out. This helps developers control the error process more accurately.
**Change Impact**
The external declaration of the JS APIs of API version 9 is affected, but the API functionalities are not affected. You can determine whether to adapt to the JS APIs.
**Key API/Component Changes**
The comments of the following modules are updated. For details, see the corresponding external API declaration and API development guide.
| Module | Description of Major Changes |
| ----------------------------------- | ------------------------------------------------------------ |
| @ohos.app.ability.UIAbility | Added the description of error codes 16200001, 16200002, 16200004, 16200005, 16000050.|
| @ohos.app.ability.abilityManager | Added the description of error codes 201, 202, and 16000050, and adjusted the description of error code 401.|
| @ohos.app.ability.appManager | Added the description of error codes 201, 202, and 16000050, and adjusted the description of error code 401.|
| @ohos.app.ability.dataUriUtils | Added the description of error code 401. |
| @ohos.app.ability.errorManager | Added the description of error code 16000003. |
| @ohos.app.ability.missionManager | Added the description of error codes 201, 202, 16300001, 16300002, and 16000009, and adjusted the description of error code 401.|
| @ohos.app.ability.quickFixManager | Added the description of error codes 201, 202, 18500001, 18500002, and 18500008. |
| @ohos.app.ability.wantAgent | Added the description of error codes 16000007, 16000015, and 16000151. |
| application/AbilityDelegator | Added the description of error codes 16000001, 16000002, 16000004, 16000005, 16000006, 16000008, 16000009, 16000010, 16000011, 16000050, 16000053, 16000055, 16200001, and 16000100.|
| application/ApplicationContext | Added the description of error codes 16000011 and 16000050. |
| application/Context | Added the description of error codes 201, 202, and 401. |
| application/ServiceExtensionContext | Added the description of error codes 201, 202, 16000001, 16000002, 16000004, 16000005, 16000006, 16000008, 16000009, 16000010, 16000011, 16000050, 16000053, 16000055, and 16200001.|
| application/UIAbilityContext | Added the description of error codes 201, 16000001, 16000002, 16000004, 16000005, 16000006, 16000008, 16000009, 16000010, 16000011, 16000050, 16000053, 16000055, 16200001, and 16000100.|
| @ohos.app.form.formHost | Added the description of error codes 201, 202, 16500050, 16500060, 16501000, 16501001, and 16501003, and adjusted the description of error code 401.|
| @ohos.app.form.formProvider | Added the error codes 202, 16500050, 16500060, 16500100, 16501000, 16501001, 16501002, and 16501003, and adjusted the description of error code 401.|
| application/FormExtensionContext | Added the description of error codes 202, 401, 16500050, 16500100, 16500101, and 16501000.|
# Notification Subsystem Changelog
Compared with OpenHarmony 3.2 Release, OpenHarmony 3.2.12.2 provides more detailed error code information for the APIs of the notification subsystem.
## cl.notification.1 Added and Optimized API Error Code Description
The error code description and all error codes that may be returned by the APIs are commented out. This helps developers control the error process more accurately.
**Change Impact**
The external declaration of the JS APIs of API version 9 is affected, but the API functionalities are not affected. You can determine whether to adapt to the JS APIs.
**Key API/Component Changes**
The comments of the following modules are updated. For details, see the corresponding external API declaration and API development guide.
| Module | Major Change |
| --------------------------- | ------------------------------------------------------------ |
| @ohos.commonEventManager | Added the description of error codes 801, 1500007, and 1500008. |
| @ohos.notificationManager | Added the description of error codes 201, 202, 1600001, 1600002, 1600003, 1600004, 1600005, 1600007, 1600008, 1600009, 1600010, and 17700001, and adjusted the description of error code 401.|
| @ohos.notificationSubscribe | Added the description of error codes 201, 202, 1600001, 1600002, 1600003, 1600007, 1600008, and 17700001, and adjusted the description of error code 401.|
# USB Manager ChangeLog
## cl.usb_manager.1 Error Information Return Method Change of APIs
The USB manager API uses service logic return values to indicate the error information, which does not comply with the API error code specifications of OpenHarmony. Beginning from API version 9, error information is returned by throwing exceptions.
**Change Impacts**
The application developed based on earlier versions needs to adapt the method for returning API error information. Otherwise, the original service logic will be affected.
**Key API/Component Changes**
Changed the USB module name from **@ohos.usb.d.ts** to **@ohos.usbV9.d.ts**, and added error code processing for all APIs in the module.
**Adaptation Guide**
Take the **getDevices** API as an example. The sample code is as follows:
```ts
import usbV9 from '@ohos.usbV9'
try {
usbV9.getDevices(); // If an improper parameter is passed to this API, an exception will be thrown.
} catch (err) {
console.error("getDevices errCode:" + err.code + ",errMessage:" + err.message);
}
```
# File Management Subsystem ChangeLog
## cl.filemanagement.1 File I/O API Changes
The return value of file I/O APIs of **file_api** does not contain the error code. The original APIs are deprecated, and new APIs are added.
**Change Impacts**
For applications developed based on earlier versions, pay attention to the iterative update of discarded APIs. The specifications of the new APIs are slightly adjusted. Pay attention to the usage of the new APIs.
**Key API/Component Changes**
For the adaptation to the unified API exception handling mode, related file I/O APIs are deprecated, and corresponding new APIs are added. Original APIs are stored in **@ohos.fileio**, and the new ones are stored in **@ohos.file.fs**. The newly added APIs support unified error code handling specifications and function the same as the original APIs. The parameters are slightly adjusted.
| Module | Method/Attribute/Enumeration/Constant | Change Type|
| ------------- | ------------------------------------------------------------ | -------- |
| @ohos.fileio | **function** open(path: string, flags?: number, mode?: number, callback?: AsyncCallback<number>): void \| Promise<number>; | Deprecated |
| @ohos.fileio | **function** openSync(path: string, flags?: number, mode?: number): number; | Deprecated |
| @ohos.file.fs | **function** open(path: string, mode?: number, callback?: AsyncCallback<File>): void \| Promise<File>; | Added |
| @ohos.file.fs | **function** openSync(path: string, mode?: number): File; | Added |
| @ohos.fileio | **function** read(fd: number, buffer: ArrayBuffer, options?: { offset?: number; length?: number; position?: number; }, callback?: AsyncCallback<ReadOut>): void \| Promise<ReadOut>; | Deprecated |
| @ohos.fileio | **function** readSync(fd: number, buffer: ArrayBuffer, options?: { offset?: number; length?: number; position?: number; }): number; | Deprecated |
| @ohos.file.fs | **function** read(fd: number, buffer: ArrayBuffer, options?: { offset?: number; length?: number; }, callback?: AsyncCallback<number>): void \| Promise<number>; | Added |
| @ohos.file.fs | **function** readSync(fd: number, buffer: ArrayBuffer, options?: { offset?: number; length?: number; }): number; | Added |
| @ohos.fileio | **function** stat(path: string, callback?: AsyncCallback<Stat>): void \| Promise<Stat>; | Deprecated |
| @ohos.fileio | **function** statSync(path: string): Stat; | Deprecated |
| @ohos.fileio | **function** fstat(fd: number, callback?: AsyncCallback<Stat>): void \| Promise<Stat>; | Deprecated |
| @ohos.fileio | **function** fstatSync(fd: number): Stat; | Deprecated |
| @ohos.file.fs | **function** stat(file: string \| number, callback?: AsyncCallback<Stat>): void \| Promise<Stat>; | Added |
| @ohos.file.fs | **function** statSync(file: string \| number): Stat; | Added |
| @ohos.fileio | **function** truncate(path: string, len?: number, callback?: AsyncCallback<void>): void \| Promise<void>; | Deprecated |
| @ohos.fileio | **function** truncateSync(path: string, len?: number): void; | Deprecated |
| @ohos.fileio | **function** ftruncate(fd: number, len?: number, callback?: AsyncCallback<void>): void \| Promise<void>; | Deprecated |
| @ohos.fileio | **function** ftruncateSync(fd: number, len?: number): void; | Deprecated |
| @ohos.file.fs | **function** truncate(file: string \| number, len?: number, callback?: AsyncCallback<void>): void \| Promise<void>; | Added |
| @ohos.file.fs | **function** truncateSync(file: string \| number, len?: number): void; | Added |
| @ohos.fileio | **function** write(fd: number, buffer: ArrayBuffer \| string, options?: { offset?: number; length?: number; position?: number; encoding?: string; }, callback?: AsyncCallback<number>): void \| Promise<void>; | Deprecated |
| @ohos.fileio | **function** writeSync(fd: number, buffer: ArrayBuffer \| string, options?: { offset?: number; length?: number; position?: number; encoding?: string; }): number; | Deprecated |
| @ohos.file.fs | **function** write(fd: number, buffer: ArrayBuffer \| string, options?: { offset?: number; length?: number; encoding?: string; }, callback?: AsyncCallback<number>): void \| Promise<void>; | Added |
| @ohos.file.fs | **function** writeSync(fd: number, buffer: ArrayBuffer \| string, options?: { offset?: number; length?: number; encoding?: string; }): number; | Added |
**Adaptation Guide**
The original APIs use **@ohos.fileio**, which is imported as follows:
```js
import fileio from '@ohos.fileio';
```
The new APIs use **@ohos.file.fs**, which is imported as follows:
```js
import fs from '@ohos.file.fs';
```
In addition, exception handling needs to be adapted. Sample code for synchronous API exception handling is as follows:
```js
import fs from '@ohos.file.fs'
try {
let file = fs.openSync(path, fs.OpenMode.READ_ONLY);
} catch (err) {
console.error("openSync errCode:" + err.code + ", errMessage:" + err.message);
}
```
Sample code for handling exceptions of the **promise** method of an asynchronous API:
```js
import fs from '@ohos.file.fs'
try {
let file = await fs.open(path, fs.OpenMode.READ_ONLY);
} catch (err) {
console.error("open promise errCode:" + err.code + ", errMessage:" + err.message);
}
```
Sample code for handling exceptions of the **callback** method of an asynchronous API:
```js
import fs from '@ohos.file.fs'
try {
fs.open(path, fs.OpenMode.READ_ONLY, function(e, file){ // Asynchronous thread (such as system call) errors are obtained from the callback.
if (e) {
console.error("open in async errCode:" + e.code + ", errMessage:" + e.message);
}
});
} catch (err) {// Errors (such as invalid parameters) of the main thread are obtained through try catch.
console.error("open callback errCode:" + err.code + ", errMessage:" + err.message);
}
```
# Globalization Subsystem ChangeLog
## cl.global.1 Support of Error Codes for the Internalization Module
APIs provided by the internationalization component of the globalization subsystem are changed to support error codes in the following scenarios. The following changes are made in API version 9 and later:
- Obtaining the local expression of a country or language
- Obtaining the list of languages supported by the system and the list of areas supported by a language
- Checking whether a language matches an area
- Obtaining and setting the system language, country or region, and area
- Obtaining and setting the 24-hour format of the system
- Obtaining, adding, and removing the preferred language
- Obtaining and setting localized numbers
You need to adapt your applications based on the following information:
**Change Impacts**
The preceding APIs are changed to the static methods of the **System** class. When such an API is called, add the class name to the end of the module name.
The return value data type of the setting APIs (for example, **setSystemLanguage**) is changed from boolean to void.
When a call to an API fails, an error code is returned according to the failure cause. For example, when permissions are not correctly configured for an application, **201** is returned.
**Key API/Component Changes**
Involved APIs:
- getDisplayCountry(country: string, locale: string, sentenceCase?: boolean): string;
- getDisplayLanguage(language: string, locale: string, sentenceCase?: boolean): string;
- getSystemLanguages(): Array<string>;
- getSystemCountries(language: string): Array<string>;
- isSuggested(language: string, region?: string): boolean;
- getSystemLanguage(): string;
- setSystemLanguage(language: string): void;
- getSystemRegion(): string;
- setSystemRegion(region: string): void;
- getSystemLocale(): string;
- setSystemLocale(locale: string): void;
- is24HourClock(): boolean;
- set24HourClock(option: boolean): void;
- addPreferredLanguage(language: string, index?: number): void;
- removePreferredLanguage(index: number): void;
- getPreferredLanguageList(): Array<string>;
- getFirstPreferredLanguage(): string;
- getAppPreferredLanguage(): string;
- setUsingLocalDigit(flag: boolean): void;
- getUsingLocalDigit(): boolean;
**Adaptation Guide**
Use the **try-catch** block to capture errors returned by an API.
```
import I18n from '@ohos.i18n'
try {
I18n.System.setSystemLanguage('zh');
} catch(error) {
console.error(`call System.setSystemLanguage failed, error code: ${error.code}, message: ${error.message}.`)
}
```
# Multimodal Input ChangeLog
## cl.multimodalinput.1 Error Information Return Method Change of APIs
The internal APIs of the following modules used service logic return values to indicate error information, which did not comply with the error code specifications of OpenHarmony. Therefore, they are modified in API version 9 and later.
- Input device management module (**@ohos.multimodalInput.inputDevice.d.ts**): third-party APIs
- Input consumer module (**@ohos.multimodalInput.inputConsumer.d.ts**): system APIs
- Screen hopping module (**@ohos.multimodalInput.inputDeviceCooperate.d.ts**): system APIs
- Key injection module (**@ohos.multimodalInput.inputEventClient.d.ts**): system APIs
- Input listening module (**@ohos.multimodalInput.inputMonitor.d.ts**): system APIs
- Mouse pointer module (**@ohos.multimodalInput.pointer.d.ts**): system APIs and third-party APIs
Asynchronous APIs in the preceding modules have the following changes: A parameter check error is returned synchronously; a service logic error is returned via **AsyncCallback** or the **error** object of **Promise**. No change is made to synchronous APIs.
**Change Impacts**
The application developed based on earlier versions needs to adapt the method for returning API error information. Otherwise, the original service logic will be affected.
**Key API/Component Changes**
- supportKeys(deviceId: number, keys: Array&lt;KeyCode&gt;, callback: AsyncCallback&lt;Array&lt;boolean&gt;&gt;): void;
- supportKeys(deviceId: number, keys: Array&lt;KeyCode&gt;): Promise&lt;Array&lt;boolean&gt;&gt;;
- getKeyboardType(deviceId: number, callback: AsyncCallback&lt;KeyboardType&gt;): void; &gt;
- getKeyboardType(deviceId: number): Promise&lt;KeyboardType&gt;;
- setPointerSpeed(speed: number, callback: AsyncCallback&lt;void&gt;): void;
- setPointerSpeed(speed: number): Promise&lt;void&gt;;
- getPointerSpeed(callback: AsyncCallback&lt;number&gt;): void;
- getPointerSpeed(): Promise&lt;number&gt;;
- setPointerStyle(windowId: number, pointerStyle: PointerStyle, callback: AsyncCallback&lt;void&gt;): void;
- setPointerStyle(windowId: number, pointerStyle: PointerStyle): Promise&lt;void&gt;;
- getPointerStyle(windowId: number, callback: AsyncCallback&lt;PointerStyle&gt;): void;
- getPointerStyle(windowId: number): Promise&lt;PointerStyle&gt;;
- setPointerVisible(visible: boolean, callback: AsyncCallback&lt;void&gt;): void;
- setPointerVisible(visible: boolean): Promise&lt;void&gt;;
- isPointerVisible(callback: AsyncCallback&lt;boolean&gt;): void;
- isPointerVisible(): Promise&lt;boolean&gt;;
- on(type:"touch", receiver:TouchEventReceiver):void;
- on(type:"mouse", receiver:Callback&lt;MouseEvent&gt;):void;
- off(type:"touch", receiver?:TouchEventReceiver):void;
- off(type:"mouse", receiver?:Callback&lt;MouseEvent&gt;):void;
- injectEvent({KeyEvent: KeyEvent}): void;
- enable(enable: boolean, callback: AsyncCallback&lt;void&gt;): void;
- enable(enable: boolean): Promise&lt;void&gt;;
- start(sinkDeviceDescriptor: string, srcInputDeviceId: number, callback: AsyncCallback&lt;void&gt;): void;
- start(sinkDeviceDescriptor: string, srcInputDeviceId: number): Promise&lt;void&gt;;
- stop(callback: AsyncCallback&lt;void&gt;): void;
- stop(): Promise&lt;void&gt;;
- getState(deviceDescriptor: string, callback: AsyncCallback&lt;{ state: boolean }&gt;): void;
- getState(deviceDescriptor: string): Promise&lt;{ state: boolean }&gt;;
- on(type: 'cooperation', callback: AsyncCallback&lt;{ deviceDescriptor: string, eventMsg: EventMsg }&gt;): void;
- off(type: 'cooperation', callback?: AsyncCallback&lt;void&gt;): void;
- on(type: "key", keyOptions: KeyOptions, callback: Callback&lt;KeyOptions&gt;): void;
- off(type: "key", keyOptions: KeyOptions, callback?: Callback&lt;KeyOptions&gt;): void;
Deprecated APIs:
- getDeviceIds(callback: AsyncCallback&lt;Array&lt;number&gt;&gt;): void;
- getDeviceIds(): Promise&lt;Array&lt;number&gt;&gt;;
- getDevice(deviceId: number, callback: AsyncCallback&lt;InputDeviceData&gt;): void;
- getDevice(deviceId: number): Promise&lt;InputDeviceData&gt;;
Substitute APIs:
- getDeviceList(callback: AsyncCallback&lt;Array&lt;number&gt;&gt;): void;
- getDeviceList(): Promise&lt;Array&lt;number&gt;&gt;;
- getDeviceInfo(deviceId: number, callback: AsyncCallback&lt;InputDeviceData&gt;): void;
- getDeviceInfo(deviceId: number): Promise&lt;InputDeviceData&gt;;
Changed APIs:
Before change:
- supportKeys(deviceId: number, keys: Array&lt;KeyCode&gt;, callback: Callback&lt;Array&lt;boolean&gt;&gt;): void;
- getKeyboardType(deviceId: number, callback: Callback&lt;KeyboardType&gt;): void;
After change:
- supportKeys(deviceId: number, keys: Array&lt;KeyCode&gt;, callback: AsyncCallback&lt;Array&lt;boolean&gt;&gt;): void;
- getKeyboardType(deviceId: number, callback: AsyncCallback&lt;KeyboardType&gt;): void;
**Adaptation Guide**
The following uses **setPointerVisible** as an example:
```ts
import pointer from '@ohos.multimodalInput.pointer';
pointer.setPointerVisible(true, (error) => {
console.log(`Set pointer visible success`);
});
try {
pointer.setPointerVisible(true, (error) => {
if (error) {
console.log(`Set pointer visible failed, error: ${JSON.stringify(error, [`code`, `message`])}`);
return;
}
console.log(`Set pointer visible success`);
});
} catch (error) {
console.log(`Set pointer visible failed, error: ${JSON.stringify(error, [`code`, `message`])}`);
}
```
# Power Subsystem ChangeLog
## cl.powermgr.1 Error Information Return Method Change of APIs
The following APIs used service logic return values to indicate error information, which did not comply with the error code specifications of OpenHarmony. Therefore, they are modified in API version 9 and later.
- Power consumption statistics: [@ohos.batteryStatistics](../../../application-dev/reference/apis/js-apis-batteryStatistics.md)
- Brightness: [@ohos.brightness](../../../application-dev/reference/apis/js-apis-brightness.md)
- Power manager: [@ohos.power](../../../application-dev/reference/apis/js-apis-power.md)
- RunningLock: [@ohos.runningLock](../../../application-dev/reference/apis/js-apis-runninglock.md)
- Thermal manager: [@ohos.thermal](../../../application-dev/reference/apis/js-apis-thermal.md)
Asynchronous API: An error message is returned via **AsyncCallback** or the **error** object of **Promise**.
Synchronous API: An error message is returned via an exception.
#### Change Impacts
The application developed based on earlier versions needs to adapt the method for returning API error information. Otherwise, the original service logic will be affected.
#### Key API/Component Changes
Error code processing is added for the following APIs:
- getBatteryStats(callback: AsyncCallback<Array&lt;BatteryStatsInfo&gt;>): void
- getAppPowerValue(uid: number): number
- getAppPowerPercent(uid: number): number
- getHardwareUnitPowerValue(type: ConsumptionType): number
- getHardwareUnitPowerPercent(type: ConsumptionType): number
- setValue(value: number): void
- shutdown(reason: string): void;
- isActive(): boolean
- wakeup(detail: string): void
- suspend(): void
- getPowerMode(): DevicePowerMode
- setPowerMode(mode: DevicePowerMode, callback: AsyncCallback&lt;void&gt;): void
- setPowerMode(mode: DevicePowerMode): Promise&lt;void&gt;
- hold(timeout: number): void
- isHolding(): boolean
- unhold(): void
- isSupported(type: RunningLockType): boolean
- isSupported(type: RunningLockType): boolean
- create(name: string, type: RunningLockType, callback: AsyncCallback&lt;RunningLock&gt;): void
- create(name: string, type: RunningLockType): Promise&lt;RunningLock&gt;
- registerThermalLevelCallback(callback: Callback&lt;ThermalLevel&gt;): void
- unregisterThermalLevelCallback(callback?: Callback&lt;void&gt;): void
- getLevel(): ThermalLevel
#### Adaptation Guide
For details, see the API reference document of each API.
## cl.powermgr.2 System API Change
#### Change Impacts
The application developed based on earlier versions needs to adapt to new API names and the new method for returning API error information. Otherwise, the original service logic will be affected.
#### Key API/Component Changes
| Bundle Name | Original API | New API |
| ----------- | ------------------------------------ | ------------------------------ |
| @ohos.power | shutdownDevice(reason: string): void | shutdown(reason: string): void |
| @ohos.power | rebootDevice(reason: string): void | reboot(reason: string): void |
| @ohos.power | wakeupDevice(detail: string): void | wakeup(detail: string): void |
| @ohos.power | suspendDevice(): void | suspend(): void |
#### Adaptation Guide
For details, see [@ohos.power](../../../application-dev/reference/apis/js-apis-power.md).
# Upload and Download Subsystem ChangeLog
Compared with OpenHarmony 3.2 Beta3, OpenHarmony 3.2.8.1 has the following changes in its upload and download subsystem:
## cl.request.1 Changes of Error Code Definitions and Some API Names
- The processing of the [upload and download error codes](https://gitee.com/openharmony/docs/blob/master/en/application-dev/reference/errorcodes/errorcode-request.md) is added to the upload and download APIs.
- An error message is returned via **AsyncCallback** or the **error** object of **Promise**. An error message related to the parameter type or quantity is returned via an exception.
- Some APIs need to be replaced with new APIs, and the parameters remain unchanged.
**Change Impacts**
The application developed based on earlier versions needs to adapt the method for returning API error information. Otherwise, the original service logic will be affected.
**Key API/Component Changes**
| Module | Class | Method/Attribute/Enumeration/Constant | Change Type|
| -------------- | -------------------------- | ------------------------------------------------------------ | -------- |
| ohos.request | request | EXCEPTION_PERMISSION | Added |
| ohos.request | request | EXCEPTION_PARAMCHECK | Added |
| ohos.request | request | EXCEPTION_UNSUPPORTED | Added |
| ohos.request | request | EXCEPTION_FILEIO | Added |
| ohos.request | request | EXCEPTION_FILEPATH | Added |
| ohos.request | request | EXCEPTION_SERVICE | Added |
| ohos.request | request | EXCEPTION_OTHERS | Added |
| ohos.request | request | ERROR_OFFLINE | Added |
| ohos.request | request | ERROR_UNSUPPORTED_NETWORK_TYPE | Added |
| ohos.request | request | function downloadFile(context: BaseContext, config: DownloadConfig, callback: AsyncCallback<DownloadTask>): void; | Added |
| ohos.request | request | function downloadFile(context: BaseContext, config: DownloadConfig): Promise<DownloadTask>; | Added |
| ohos.request | request | function uploadFile(context: BaseContext, config: UploadConfig, callback: AsyncCallback<UploadTask>): void; | Added |
| ohos.request | request | function uploadFile(context: BaseContext, config: UploadConfig): Promise<UploadTask>; | Added |
| ohos.request | DownloadTask | delete(callback: AsyncCallback<boolean>): void; | Added |
| ohos.request | DownloadTask | delete(): Promise<boolean>; | Added |
| ohos.request | DownloadTask | suspend(callback: AsyncCallback<boolean>): void; | Added |
| ohos.request | DownloadTask | suspend(): Promise<boolean>; | Added |
| ohos.request | DownloadTask | restore(callback: AsyncCallback<boolean>): void; | Added |
| ohos.request | DownloadTask | restore(): Promise<boolean>; | Added |
| ohos.request | DownloadTask | getTaskInfo(callback: AsyncCallback<DownloadInfo>): void; | Added |
| ohos.request | DownloadTask | getTaskInfo(): Promise<DownloadInfo>; | Added |
| ohos.request | DownloadTask | getTaskMimeType(callback: AsyncCallback<string>): void; | Added |
| ohos.request | DownloadTask | getTaskMimeType(): Promise<string>; | Added |
| ohos.request | UploadTask | delete(callback: AsyncCallback<boolean>): void; | Added |
| ohos.request | UploadTask | delete(): Promise<boolean>; | Added |
| ohos.request | request | function download(config: DownloadConfig, callback: AsyncCallback<DownloadTask>): void;<br>Substitute API: function downloadFile(context: BaseContext, config: DownloadConfig, callback: AsyncCallback<DownloadTask>): void;| Deprecated |
| ohos.request | request | function download(config: DownloadConfig): Promise<DownloadTask>;<br>Substitute API: function downloadFile(context: BaseContext, config: DownloadConfig): Promise<DownloadTask>; | Deprecated |
| ohos.request | request | function download(context: BaseContext, config: DownloadConfig, callback: AsyncCallback<DownloadTask>): void;<br>Substitute API: function downloadFile(context: BaseContext, config: DownloadConfig, callback: AsyncCallback<DownloadTask>): void; | Deprecated |
| ohos.request | request | function download(context: BaseContext, config: DownloadConfig): Promise<DownloadTask>;<br>Substitute API: function downloadFile(context: BaseContext, config: DownloadConfig): Promise<DownloadTask>; | Deprecated |
| ohos.request | request | function upload(config: UploadConfig, callback: AsyncCallback<UploadTask>): void;<br>Substitute API: function uploadFile(context: BaseContext, config: UploadConfig, callback: AsyncCallback<UploadTask>): void; | Deprecated |
| ohos.request | request | function upload(config: UploadConfig): Promise<UploadTask>;<br>Substitute API: function uploadFile(context: BaseContext, config: UploadConfig): Promise<UploadTask>; | Deprecated |
| ohos.request | request | function upload(context: BaseContext, config: UploadConfig, callback: AsyncCallback<UploadTask>): void;<br>Substitute API: function uploadFile(context: BaseContext, config: UploadConfig, callback: AsyncCallback<UploadTask>): void; | Deprecated |
| ohos.request | request | function upload(context: BaseContext, config: UploadConfig): Promise<UploadTask>;<br>Substitute API: function uploadFile(context: BaseContext, config: UploadConfig): Promise<UploadTask>; | Deprecated |
| ohos.request | DownloadTask | remove(callback: AsyncCallback<boolean>): void;<br>Substitute API: delete(callback: AsyncCallback<boolean>): void | Deprecated |
| ohos.request | DownloadTask | remove(): Promise<boolean>;<br>Substitute API: delete(): Promise<boolean>; | Deprecated |
| ohos.request | DownloadTask | pause(callback: AsyncCallback<boolean>): void;<br>Substitute API: suspend(callback: AsyncCallback<boolean>): void; | Deprecated |
| ohos.request | DownloadTask | pause(): Promise<boolean>;<br>Substitute API: suspend(): Promise<boolean>; | Deprecated |
| ohos.request | DownloadTask | resume(callback: AsyncCallback<boolean>): void;<br>Substitute API: restore(callback: AsyncCallback<boolean>): void; | Deprecated |
| ohos.request | DownloadTask | resume(): Promise<boolean>;<br>Substitute API: restore(): Promise<boolean>; | Deprecated |
| ohos.request | DownloadTask | query(callback: AsyncCallback<DownloadInfo>): void;<br>Substitute API: getTaskInfo(callback: AsyncCallback<DownloadInfo>): void; | Deprecated |
| ohos.request | DownloadTask | query(): Promise<DownloadInfo>;<br>Substitute API: getTaskInfo(): Promise<DownloadInfo>; | Deprecated |
| ohos.request | DownloadTask | queryMimeType(callback: AsyncCallback<string>): void;<br>Substitute API: getTaskMimeType(callback: AsyncCallback<string>): void; | Deprecated |
| ohos.request | DownloadTask | queryMimeType(): Promise<string>;<br>Substitute API: getTaskMimeType(): Promise<string>; | Deprecated |
| ohos.request | UploadTask | remove(callback: AsyncCallback<boolean>): void;<br>Substitute API: delete(callback: AsyncCallback<boolean>): void; | Deprecated |
| ohos.request | UploadTask | remove(): Promise<boolean>;<br>Substitute API: delete(): Promise<boolean>; | Deprecated |
| system.request | UploadResponse | code | Deprecated |
| system.request | UploadResponse | data | Deprecated |
| system.request | UploadResponse | headers | Deprecated |
| system.request | DownloadResponse | token | Deprecated |
| system.request | OnDownloadCompleteResponse | uri | Deprecated |
| system.request | RequestFile | filename | Deprecated |
| system.request | RequestFile | name | Deprecated |
| system.request | RequestFile | uri | Deprecated |
| system.request | RequestFile | type | Deprecated |
| system.request | RequestData | name | Deprecated |
| system.request | RequestData | value | Deprecated |
| system.request | UploadRequestOptions | url | Deprecated |
| system.request | UploadRequestOptions | data | Deprecated |
| system.request | UploadRequestOptions | files | Deprecated |
| system.request | UploadRequestOptions | header | Deprecated |
| system.request | UploadRequestOptions | description | Deprecated |
| system.request | UploadRequestOptions | success | Deprecated |
| system.request | UploadRequestOptions | fail | Deprecated |
| system.request | UploadRequestOptions | complete | Deprecated |
| system.request | OnDownloadCompleteOptions | token | Deprecated |
| system.request | OnDownloadCompleteOptions | success | Deprecated |
| system.request | OnDownloadCompleteOptions | fail | Deprecated |
| system.request | OnDownloadCompleteOptions | complete | Deprecated |
| system.request | Request | static upload(options: UploadRequestOptions): void; | Deprecated |
| system.request | Request | static download(options: DownloadRequestOptions): void; | Deprecated |
| system.request | Request | static onDownloadComplete(options: OnDownloadCompleteOptions): void; | Deprecated |
**Adaptation Guide**
The following uses **downloadFile** as an example to show how it is called in the new version:
```ts
try {
request.downloadFile(globalThis.abilityContext, { url: 'https://xxxx/xxxxx.hap',
filePath: 'xxx/xxxxx.hap'}, (err, data) => {
if (err) {
console.error('Failed to request the download. Cause: ' + JSON.stringify(err));
return;
}
});
} catch (err) {
console.log("downloadFile callback fail." + "errCode:" + err.code + ",errMessage:" + err.message);
}
```
# Bundle Manager Subsystem ChangeLog
## cl.bundlemanager.1 Bundle Manager API Changes
The bundle manager APIs use service logic return values to indicate the error information, which does not comply with the API error code specifications of OpenHarmony. APIs in API version 8 and earlier are deprecated. Replace them with APIs in API version 9 instead.
**Change Impacts**
The application developed based on the SDK versions of OpenHarmony 3.2.8.2 and later needs to adapt the modules and APIs (version 9) and their method for returning API error information. Otherwise, the original service logic will be affected.
**Key API/Component Changes**
The new APIs are classified by module. The original **d.ts** file is divided into multiple ones. You can import the **d.ts** files as required. The newly added APIs support unified error code handling specifications and function the same as the original APIs. APIs whose functions are changed or added are listed separately.
For adaptation to the unified API exception handling mode, bundle manager APIs (version 8 and earlier) are deprecated (original APIs in the following table) and corresponding new APIs (version 9) in the following table are added.
| Original API (Deprecated) | New API (Added) |
| ------------------------------------ | ------------------------------------------------------------ |
| @ohos.bundle.d.ts | [@ohos.bundle.bundleManager.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/@ohos.bundle.bundleManager.d.ts) |
| @ohos.bundle.d.ts | [@ohos.bundle.freeInstall.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/@ohos.bundle.freeInstall.d.ts) |
| @ohos.bundle.d.ts | [@ohos.bundle.installer.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/@ohos.bundle.installer.d.ts) |
| @ohos.bundle.innerBundleManager.d.ts | [@ohos.bundle.launcherBundleManager.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/@ohos.bundle.launcherBundleManager.d.ts) |
| @ohos.bundle.innerBundleManager.d.ts | [@ohos.bundle.bundleMonitor.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/@ohos.bundle.bundleMonitor.d.ts) |
| @ohos.bundle.defaultAppManager.d.ts | [@ohos.bundle.defaultAppManager.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/@ohos.bundle.defaultAppManager.d.ts) |
| @ohos.distributedBundle.d.ts | [@ohos.bundle.distributedBundleManager.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/@ohos.bundle.distributedBundleManager.d.ts) |
| N/A | [@ohos.bundle.appControl.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/@ohos.bundle.appControl.d.ts) |
| @system.package.d.ts | N/A |
**Adaptation Guide**
1. Call the bundle manager query API.
```
import bundle form '@ohos.bundle.bundleManager'
```
2. Call the bundle manager installation and uninstallation API.
```
import installer form '@ohos.bundle.installer'
```
3. Call the bundle manager installation-free API.
```
import freeInstall form '@ohos.bundle.freeInstall'
```
4. Call the bundle manager launcher APIs.
```
import launcherBundleManager form '@ohos.bundle.launcherBundleManager'
import bundleMonitor form '@ohos.bundle.bundleMonitor'
```
6. Call the bundle manager API for the default application.
```
import defaultAppManager form '@ohos.bundle.defaultAppManager'
```
7. Call the distributed bundle manager API.
```
import distributedBundle form '@ohos.bundle.distributedBundle'
```
In addition, exception handling is needed. For details, see the API reference for the new APIs.
## cl.bundlemanager.1 Bundle Manager API Structure Changes
The bundle manager APIs use service logic return values to indicate the error information, which does not comply with the API error code specifications of OpenHarmony. The structures of APIs in API version 8 and earlier are deprecated. Use the structures of APIs in API version 9 instead.
**Change Impacts**
The application developed based on the SDK versions of OpenHarmony 3.2.8.2 and later needs to adapt new structures. Otherwise, the original service logic will be affected. The export function of original level-2 modules will also be deprecated. Instead, the level-2 modules' export function of new APIs will be used, and new level-1 d.ts modules are imported.
**Key API/Component Changes**
The structures of APIs in API version 8 and earlier are sorted out and deprecated, and those of new APIs in API version 9 are added. The following table lists the comparison before and after the change. Some structures are combined. For example, replace **moduleInfo.d.ts** with **hapModuleInfo.d.ts** and **customizeData.d.ts** with **metadata.d.ts**. The structures' functions are the same as those of the original ones. Structures whose attributes are changed or added are listed separately.
| Original Structure (Deprecated) | New Structure (Added) |
| -------------------------------- | ------------------------------------------------------------ |
| bundle/abilityInfo.d.ts | [bundleManager/AbilityInfo.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/AbilityInfo.d.ts) |
| bundle/applicationInfo.d.ts | [bundleManager/ApplicationInfo.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/ApplicationInfo.d.ts) |
| bundle/bundleInfo.d.ts | [bundleManager/BundleInfo.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/BundleInfo.d.ts) |
| bundle/bundleInstaller.d.ts | [@ohos.bundle.installer.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/@ohos.bundle.installer.d.ts) |
| bundle/bundleStatusCallback.d.ts | [@ohos.bundle.bundleMonitor.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/@ohos.bundle.bundleMonitor.d.ts) |
| bundle/customizeData.d.ts | [bundleManager/Metadata.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/Metadata.d.ts) |
| bundle/dispatchInfo.d.ts | [bundleManager/DispatchInfo.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/DispatchInfo.d.ts) |
| bundle/elementName.d.ts | [bundleManager/ElementName.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/ElementName.d.ts) |
| bundle/extensionAbilityInfo.d.ts | [bundleManager/ExtensionAbilityInfo.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/ExtensionAbilityInfo.d.ts) |
| bundle/hapModuleInfo.d.ts | [bundleManager/HapModuleInfo.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/HapModuleInfo.d.ts) |
| bundle/launcherAbilityInfo.d.ts | [bundleManager/LauncherAbilityInfo.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/LauncherAbilityInfo.d.ts) |
| bundle/metadata.d.ts | [bundleManager/Metadata.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/Metadata.d.ts) |
| bundle/moduleInfo.d.ts | [bundleManager/HapModuleInfo.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/HapModuleInfo.d.ts) |
| bundle/PermissionDef.d.ts | [bundleManager/PermissionDef.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/PermissionDef.d.ts) |
| bundle/remoteAbilityInfo.d.ts | [bundleManager/RemoteAbilityInfo.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/RemoteAbilityInfo.d.ts) |
| bundle/shortcutInfo.d.ts | [bundleManager/ShortcutInfo.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/ShortcutInfo.d.ts) |
**Adaptation Guide**
1. Replace the code of original structures with the code of new ones.
2. Deprecate the export function of original level-2 modules. Instead, use the level-2 modules' export function of new APIs, and import new level-1 d.ts modules.
## cl.bundlemanager.3 Bundle Manager Query API Changes
Bundle manager query APIs are changed as follows: APIs of version 8 and earlier in **@ohos.bundle** are deprecated, and APIs of version 9 in **@ohos.bundle** are changed to **@ohos.bundle.bundleManager**, **@ohos.bundle.freeInstall**, and **@ohos.bundle.installer**. Most deprecated APIs are added to **@ohos.bundle.bundleManager** and changed to system APIs, and the exception handling capability is added.
API call mode: APIs are now used by the **@ohos.bundle.bundleManager**, **@ohos.bundle.freeInstall**, and **@ohos.bundle.installer** modules, instead of the **@ohos.bundle** module.
The system capability of the **@ohos.bundle.bundleManager** and **@ohos.bundle.installer** modules is **SystemCapability.BundleManager.BundleFramework.Core**, and that of **@ohos.bundle.freeInstall** is **SystemCapability.BundleManager.BundleFramework.FreeInstall**.
**Change Impacts**
There is no impact on applications that use the APIs of versions earlier than 9. The applications that use the APIs of version 9 need to adapt new modules and APIs. APIs of version 9 in **@ohos.bundle** are moved to the new **@ohos.bundle.bundleManager.d.ts**, **@ohos.bundle.freeInstall**, and **@ohos.bundle.installer** files.
**Key API/Component Changes**
The following table lists the deprecated and changed APIs involved in **@ohos.bundle.d.ts**. The APIs not listed in the table have no change in API names and input parameters, and they have new exception handling and import modules. The APIs can be directly used after being imported to **@ohos.bundle.bundleManager.d.ts**, **@ohos.bundle.freeInstall**, and **@ohos.bundle.installer**. The APIs listed in the table are changed in API version 9, and those marked with "N/A" are deprecated in API version 9.
| Original API (Deprecated) | New API (Changed or Added) | System API| New File Name |
| ---------------------------- | ---------------------------- | --------- | ------------------------------- |
| BundleFlag | BundleFlag | No | @ohos.bundle.bundleManager.d.ts |
| N/A | ApplicationFlag | Yes | @ohos.bundle.bundleManager.d.ts |
| N/A | AbilityFlag | Yes | @ohos.bundle.bundleManager.d.ts |
| ExtensionFlag | ExtensionAbilityFlag | Yes | @ohos.bundle.bundleManager.d.ts |
| ColorMode | N/A | No | N/A |
| GrantStatus | PermissionGrantState | No | @ohos.bundle.bundleManager.d.ts |
| AbilityType | AbilityType | No | @ohos.bundle.bundleManager.d.ts |
| AbilitySubType | N/A | No | N/A |
| DisplayOrientation | DisplayOrientation | No | @ohos.bundle.bundleManager.d.ts |
| LaunchMode | LaunchType | No | @ohos.bundle.bundleManager.d.ts |
| ExtensionAbilityType | ExtensionAbilityType | Yes | @ohos.bundle.bundleManager.d.ts |
| BundleOptions | N/A | No | N/A |
| InstallErrorCode | N/A | No | N/A |
| UpgradeFlag | UpgradeFlag | Yes | @ohos.bundle.freeInstall.d.ts |
| SupportWindowMode | SupportWindowMode | No | @ohos.bundle.bundleManager.d.ts |
| getBundleInfo | getBundleInfo | Yes | @ohos.bundle.bundleManager.d.ts |
| getBundleInstaller | getBundleInstaller | Yes | @ohos.bundle.installer.d.ts |
| getAbilityInfo | queryAbilityInfo | Yes | @ohos.bundle.bundleManager.d.ts |
| getApplicationInfo | getApplicationInfo | Yes | @ohos.bundle.bundleManager.d.ts |
| queryAbilityByWant | queryAbilityInfo | Yes | @ohos.bundle.bundleManager.d.ts |
| getAllBundleInfo | getAllBundleInfo | Yes | @ohos.bundle.bundleManager.d.ts |
| getAllApplicationInfo | getAllApplicationInfo | Yes | @ohos.bundle.bundleManager.d.ts |
| getNameForUid | getBundleNameByUid | Yes | @ohos.bundle.bundleManager.d.ts |
| getBundleArchiveInfo | getBundleArchiveInfo | Yes | @ohos.bundle.bundleManager.d.ts |
| getLaunchWantForBundle | getLaunchWantForBundle | Yes | @ohos.bundle.bundleManager.d.ts |
| cleanBundleCacheFiles | cleanBundleCacheFiles | Yes | @ohos.bundle.bundleManager.d.ts |
| setApplicationEnabled | setApplicationEnabled | Yes | @ohos.bundle.bundleManager.d.ts |
| setAbilityEnabled | setAbilityEnabled | Yes | @ohos.bundle.bundleManager.d.ts |
| queryExtensionAbilityInfos | queryExtensionAbilityInfo | Yes | @ohos.bundle.bundleManager.d.ts |
| getPermissionDef | getPermissionDef | Yes | @ohos.bundle.bundleManager.d.ts |
| getAbilityLabel | getAbilityLabel | Yes | @ohos.bundle.bundleManager.d.ts |
| getAbilityIcon | getAbilityIcon | Yes | @ohos.bundle.bundleManager.d.ts |
| isAbilityEnabled | isAbilityEnabled | Yes | @ohos.bundle.bundleManager.d.ts |
| isApplicationEnabled | isApplicationEnabled | Yes | @ohos.bundle.bundleManager.d.ts |
| setModuleUpgradeFlag | setHapModuleUpgradeFlag | Yes | @ohos.bundle.freeInstall.d.ts |
| isModuleRemovable | isHapModuleRemovable | Yes | @ohos.bundle.freeInstall.d.ts |
| getBundlePackInfo | getBundlePackInfo | Yes | @ohos.bundle.freeInstall.d.ts |
| getDispatcherVersion | getDispatchInfo | Yes | @ohos.bundle.freeInstall.d.ts |
| getProfileByAbility | getProfileByAbility | No | @ohos.bundle.bundleManager.d.ts |
| getProfileByExtensionAbility | getProfileByExtensionAbility | No | @ohos.bundle.bundleManager.d.ts |
| setDisposedStatus | setDisposedStatus | Yes | @ohos.bundle.appControl.d.ts |
| getDisposedStatus | getDisposedStatus | Yes | @ohos.bundle.appControl.d.ts |
| N/A | deleteDisposedStatus | Yes | @ohos.bundle.appControl.d.ts |
| getBundleInfoSync | getBundleInfoSync | Yes | @ohos.bundle.bundleManager.d.ts |
| getApplicationInfoSync | getApplicationInfoSync | Yes | @ohos.bundle.bundleManager.d.ts |
| N/A | getBundleInfoForSelf | No | @ohos.bundle.bundleManager.d.ts |
**Adaptation Guide**
Replace the original APIs with new ones of version 9 and import related modules.
Old import module:
```
import bundle form '@ohos.bundle'
```
New import module:
```
import bundle form '@ohos.bundle.bundleManager'
import freeInstall form '@ohos.bundle.freeInstall'
import installer form '@ohos.bundle.installer'
import appControl form '@ohos.bundle.appControl'
```
## cl.bundlemanager.4 BundleInfo Structure Changes
All **bundle/bundleInfo.d.ts** fields in the bundle manager are deprecated. [bundle/bundleInfo.d.ts]((https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundle/bundleInfo.d.ts)) is changed to [bundleManager/BundleInfo.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/BundleInfo.d.ts), involving field type changes.
**Change Impacts**
There is no impact on applications that use the APIs of versions earlier than 9. The applications that use the APIs of version 9 need to adapt new modules and APIs. When a level-2 module is used to export **BundleInfo**, the **@ohos.bundle.bundleManager** module needs to be imported.
**Key API/Component Changes**
The following table describes the changed fields in the **BundleInfo** structure. After other fields are deprecated in **bundle/bundleInfo.d.ts**, they have corresponding values in the new **[bundleManager/BundleInfo.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/BundleInfo.d.ts)**. If corresponding fields do not exist, the fields have been deprecated in API version 9.
| Deprecated | Added or Changed in API Version 9 | Type |
| --------------------- | --------------------- | ------------------------------------------ |
| type | N/A | string |
| appId | N/A | string |
| N/A | signatureInfo | SignatureInfo |
| uid | N/A | number |
| abilityInfos | N/A | Array\<AbilityInfo> |
| reqPermissions | N/A | Array<string> |
| compatibleVersion | N/A | number |
| isCompressNativeLibs | N/A | boolean |
| entryModuleName | N/A | string |
| cpuAbi | N/A | string |
| isSilentInstallation | N/A | string |
| entryInstallationFree | N/A | boolean |
| reqPermissionStates | permissionGrantStates | Array\<bundleManager.PermissionGrantState> |
| extensionAbilityInfo | N/A | Array\<ExtensionAbilityInfo> |
| hapModuleInfos | hapModulesInfo | Array\<HapModuleInfo> |
The **SignatureInfo** structure is added to API version 9 as follows.
| Field | Type |
| ----------- | ------ |
| appId | string |
| fingerprint | string |
**Adaptation Guide**
Use the **BundleInfo** structure of API version 9 for modules imported for bundle manager query. The following module needs to be imported when a level-2 module is used for export.
```
import bundle form '@ohos.bundle.bundleManager'
```
## cl.bundlemanager.5 ApplicationInfo Structure Changes
The **ApplicationInfo** structure is changed. The original **bundle/applicationInfo.d.ts** fields in the bundle manager are deprecated, and the file is changed from **bundle/applicationInfo.d.ts** to **bundleManager/ApplicationInfo.d.ts**, involving field type changes.
**Change Impacts**
There is no impact on applications that use the APIs of versions earlier than 9. The applications that use the APIs of version 9 need to adapt new modules and APIs. When a level-2 module is used to export **ApplicationInfo**, the **@ohos.bundle.bundleManager** module needs to be imported.
**Key API/Component Changes**
The following table describes the changed fields in the **ApplicationInfo** structure. After other fields are deprecated in **bundle/applicationInfo.d.ts**, they have corresponding values in the new [bundleManager/ApplicationInfo.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/ApplicationInfo.d.ts). If corresponding fields do not exist, the fields have been deprecated in API version 9.
| Deprecated | Added or Changed in API Version 9| Type |
| ---------------- | -------------- | ---------------------------------- |
| systemApp | N/A | boolean |
| labelId | N/A | string |
| labelIndex | labelId | number |
| iconId | N/A | string |
| iconIndex | iconId | number |
| supportedModes | N/A | number |
| moduleSourceDirs | N/A | Array\<string> |
| moduleInfos | N/A | Array\<ModuleInfo> |
| metaData | N/A | Map\<string,Array\<CustomizeData>> |
| entityType | N/A | string |
| fingerprint | N/A | string |
**Adaptation Guide**
Use the **ApplicationInfo** structure of API version 9 for modules imported for bundle manager query.
## cl.bundlemanager.6 HapModuleInfo Structure Changes
The **HapModuleInfo** structure is changed. The original **bundle/hapModuleInfo.d.ts** and **moduleInfo.d.ts** fields in the bundle manager are deprecated, and the files are changed to [bundleManager/HapModuleInfo.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/HapModuleInfo.d.ts), involving field type changes.
**Change Impacts**
There is no impact on applications that use the APIs of versions earlier than 9. The applications that use the APIs of version 9 need to adapt new modules and APIs. When a level-2 module is used to export **HapModuleInfo**, the **@ohos.bundle.bundleManager** module needs to be imported.
**Key API/Component Changes**
The following table describes the changed fields in the **HapModuleInfo** structure. After other fields are deprecated in **bundle/hapModuleInfo.d.ts**, they have corresponding values in the new **bundleManager/HapModuleInfo.d.ts** file.
| Deprecated | Added or Changed in API Version 9 | Type |
| -------------------- | ---------------------- | ---------------------------- |
| abilityInfo | abilitiesInfo | Array<AbilityInfo> |
| N/A | moduleSourceDir | string |
| backgroundImg | N/A | string |
| supportedModes | N/A | string |
| reqCapabilities | N/A | Array\<string> |
| moduleName | N/A | string |
| mainAbilityName | N/A | string |
| extensionAbilityInfo | extensionAbilitiesInfo | Array\<ExtensionAbilityInfo> |
**Adaptation Guide**
Use the **HapModuleInfo** structure of API version 9 for modules imported for bundle manager query.
## cl.bundlemanager.7 ModuleInfo Structure Changes
The original **bundle/hapModuleInfo.d.ts** and **moduleInfo.d.ts** fields in the bundle manager are deprecated, and the files are changed to [bundleManager/HapModuleInfo.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/HapModuleInfo.d.ts), involving field changes.
The **ModuleInfo** structure is deprecated and replaced by **HapModuleInfo** in [bundleManager/HapModuleInfo.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/HapModuleInfo.d.ts).
**Change Impacts**
There is no impact on applications that use the APIs of versions earlier than 9. The applications that use the APIs of version 9 need to adapt new modules and APIs. The **ModuleInfo** structure is deprecated and replaced by **HapModuleInfo**.
**Key API/Component Changes**
The **ModuleInfo** structure is deprecated and replaced by **HapModuleInfo**.
**Adaptation Guide**
Use the **HapModuleInfo** structure of API version 9.
## cl.bundlemanager.8 AbilityInfo Structure Changes
The **AbilityInfo** structure is changed. The original **bundle/abilityInfo.d.ts** file is deprecated and changed to **bundleManager/AbilityInfo.d.ts**, involving field type changes.
**Change Impacts**
There is no impact on applications that use the APIs of versions earlier than 9. The applications that use the APIs of version 9 need to adapt new modules and APIs.
**Key API/Component Changes**
The following table lists the field changes in the **AbilityInfo** structure for the bundle manager. Fields that are not listed in the table exist in the new **AbilityInfo** structure after being deprecated. Fields marked with "N/A" have been deprecated in API version 9 and do not exist in the new **AbilityInfo** structure.
| Deprecated | Added or Changed in API Version 9 | Type |
| ------------------ | ------------------ | --------------------- |
| launchMode | launchType | number |
| supportWindowMode | supportWindowModes | Array\<number> |
| targetAbility | N/A | string |
| backgroundModes | N/A | number |
| formEnabled | N/A | boolean |
| subType | N/A | AbilitySubType |
| deviceCapabilities | N/A | Array\<string> |
| metaData | N/A | Array\<CustomizeData> |
| maxWindowRatio | N/A | number |
| minWindowRatio | N/A | number |
| maxWindowWidth | N/A | number |
| minWindowWidth | N/A | number |
| maxWindowHeight | N/A | number |
| minWindowHeight | N/A | number |
| N/A | windowSize | WindowSize |
The fields of the new structure **WindowSize** of API version 9 are as follows.
| Field | Type |
| :-------------: | :----: |
| maxWindowRatio | number |
| minWindowRatio | number |
| maxWindowWidth | number |
| minWindowWidth | number |
| maxWindowHeight | number |
| minWindowHeight | number |
**Adaptation Guide**
Use the **AbilityInfo** structure of API version 9.
## cl.bundlemanager.9 BundleFlag Changes
**BundleFlag** is changed to **BundleFlag**, **ApplicationFlag**, and **AbilityFlag** in **@ohos.bundle.bundleManager**. Different types of flags are passed based on the input parameters of new APIs.
**Change Impacts**
**BundleFlag** is changed to **BundleFlag**, **ApplicationFlag**, and **AbilityFlag** in **@ohos.bundle.bundleManager**. Different types of flags are passed based on the input parameters of new APIs. If **BundleFlag** of a version earlier than API version 9 is directly used, the query may fail.
**Key API/Component Changes**
**BundleFlag** in the original **@ohos.bundle** is deprecated and replaced by **BundleFlag**, **ApplicationFlag**, and **AbilityFlag** in the new **@ohos.bundle.bundleManager**.
The following table describes **BundleFlag** of API version 9.
| BundleFlag | Value | Description |
| ----------------------------------------- | ---------- | ------------------------------------------------------------ |
| GET_BUNDLE_INFO_DEFAULT | 0x00000000 | Obtains the default **BundleInfo**. The obtained **BundleInfo** does not contain **signatureInfo**, **hapModuleInfo**, **appInfo**, **reqPermissionDetails**, or **permissionGrantStates**.|
| GET_BUNDLE_INFO_WITH_APPLICATION | 0x00000001 | Obtains **appInfos** with the default **BundleInfo**. |
| GET_BUNDLE_INFO_WITH_HAP_MODULE | 0x00000002 | Obtains **hapModulesInfo** with the default **BundleInfo**. |
| GET_BUNDLE_INFO_WITH_ABILITY | 0x00000004 | Indicates whether **abilitiesInfo** is obtained with **hapModulesInfo**. This flag must be used together with **GET_BUNDLE_INFO_WITH_HAP_MODULE** and cannot be used independently.|
| GET_BUNDLE_INFO_WITH_EXTENSION_ABILITY | 0x00000008 | Indicates whether **extensionAbilitiesInfo** is obtained with **hapModulesInfo**. This flag must be used together with **GET_BUNDLE_INFO_WITH_HAP_MODULE** and cannot be used independently.|
| GET_BUNDLE_INFO_WITH_REQUESTED_PERMISSION | 0x00000010 | Obtains **reqPermissionDetails** and **permissionGrantStates** with the default **BundleInfo**. |
| GET_BUNDLE_INFO_WITH_METADATA | 0x00000020 | Indicates whether the returned **ApplicationInfo**, **AbilityInfo**, and **ExtensionAbilityInfo** contain metadata. This flag cannot be used independently.|
| GET_BUNDLE_INFO_WITH_DISABLE | 0x00000040 | Obtains **BundleInfo** of a disabled application and disabled ability information in **abilitiesInfo**.|
| GET_BUNDLE_INFO_WITH_SIGNATURE_INFO | 0x00000080 | Obtains **signatureInfo** with the default **BundleInfo**. |
The following table describes **ApplicationFlag** of API version 9.
| ApplicationFlag | Value | Description |
| ------------------------------------ | ---------- | ------------------------------------------------------------ |
| GET_APPLICATION_INFO_DEFAULT | 0x00000000 | Obtains the default **ApplicationInfo**. The obtained **ApplicationInfo** does not contain permission or metadata information.|
| GET_APPLICATION_INFO_WITH_PERMISSION | 0x00000001 | Obtains **permissions** with the default **ApplicationInfo**. |
| GET_APPLICATION_INFO_WITH_METADATA | 0x00000002 | Obtains **metadata** with the default **ApplicationInfo**. |
| GET_APPLICATION_INFO_WITH_DISABLE | 0x00000004 | Obtains disabled application information. |
The following table describes **AbilityFlag** of API version 9.
| AbilityFlag | Value | Description |
| --------------------------------- | ---------- | ------------------------------------------------------------ |
| GET_ABILITY_INFO_DEFAULT | 0x00000000 | Obtains the default **AbilityInfo**. The obtained **AbilityInfo** does not contain permission, metadata, or disabled ability information.|
| GET_ABILITY_INFO_WITH_PERMISSION | 0x00000001 | Obtains **AbilityInfo** with permission information. |
| GET_ABILITY_INFO_WITH_APPLICATION | 0x00000002 | Obtains **AbilityInfo** with the **ApplicationInfo** structure. |
| GET_ABILITY_INFO_WITH_METADATA | 0x00000004 | Obtains **AbilityInfo** with metadata information. |
| GET_ABILITY_INFO_WITH_DISABLE | 0x00000008 | Obtains all **AbilityInfo**, including disabled abilities. |
| GET_ABILITY_INFO_ONLY_SYSTEM_APP | 0x00000010 | Obtains **AbilityInfo** for system applications. |
**Adaptation Guide**
Use various flags according to the called API in **@ohos.bundle.bundleManager.d.ts**.
## cl.bundlemanager.10 ApplicationType Enumerated Value Changes in the Default Application Module
For the **@ohos.bundle.defaultApp** module, both API functions and usage remain unchanged, but only the enumerated values of **ApplicationType** are changed.
**Change Impacts**
There is no impact on applications that use the APIs of versions earlier than 9. The applications that use the APIs of version 9 need to adapt new enumerated values.
**Key API/Component Changes**
The enumerated values of **ApplicationType** are changed as follows.
| ApplicationType| Added or Changed in API Version 9 | API Version 8 and Earlier|
| :-------------: | :-------------: | :--------: |
| BROWSER | "Web Browser" | "BROWSER" |
| IMAGE | "Image Gallery" | "IMAGE" |
| AUDIO | "Audio Player" | "AUDIO" |
| VIDEO | "Video Player" | "VIDEO" |
| PDF | "PDF Viewer" | "PDF" |
| WORD | "Word Viewer" | "WORD" |
| EXCEL | "Excel Viewer" | "EXCEL" |
| PPT | "PPT Viewer" | "PPT" |
**Adaptation Guide**
Import the default application module and call related APIs.
```
import defaultApp form '@ohos.bundle.defaultAppManager'
```
## cl.bundlemanager.11 Distributed Bundle Manager Changes
API exception handling is rectified. The distributed bundle manager module is changed. The original **@ohos.distributedBundle.d.ts** APIs are deprecated, and the **@ohos.distributedBundle.d.ts** file is changed to [@ohos.bundle.distributedBundleManager.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/@ohos.bundle.distributedBundleManager.d.ts). The **getRemoteAbilityInfos** API is changed to **getRemoteAbilityInfo**. The export function of a level-2 module in the **RemoteAbilityInfo** structure can be used only after a new module is imported.
**Change Impacts**
Applications using APIs earlier than version 9 are not affected. The names of the distributed module and the **getRemoteAbilityInfos** API are changed. As a result, applications using APIs of version 9 may fail to be compiled using the new SDK.
**Key API/Component Changes**
All APIs in **@ohos.distributedBundle.d.ts** are deprecated. The **@ohos.bundle.distributedBundleManager.d.ts** file is added. The functions of some APIs are the same as those of the original ones. New APIs support exception handling. The API changes are as follows.
| Deprecated | Added or Changed in API Version 9 | System API|
| --------------------- | -------------------- | --------- |
| getRemoteAbilityInfos | getRemoteAbilityInfo | Yes |
**Adaptation Guide**
Import a new distributed module.
```
import distributedBundle form '@ohos.bundle.distributedBundle'
```
## cl.bundlemanager.12 Installation-Free Module and API Changes
APIs support exception handling rectification. The installation-free module is moved from **@ohos.bundle.d.ts** to **@ohos.bundle.freeInstall.d.ts**, involving module and API changes. The system capability is **SystemCapability.BundleManager.BundleFramework.FreeInstall**.
1. The imported **@ohos.bundle** module needs to be changed to **@ohos.bundle.freeInstall**.
2. The **setModuleUpgradeFlag** API is changed to **setHapModuleUpgradeFlag**.
3. The **isModuleRemovable** API is changed to **isHapModuleRemovable**.
4. The **getDispatcher** API is changed to **getDispatchInfo**.
**Change Impacts**
Applications using APIs earlier than version 9 are not affected. Applications using APIs of version 9 will fail to be compiled.
**Key API/Component Changes**
The following table lists the installation-free API changes. For APIs not listed in the table, their names and usage are unchanged, but the module name is changed.
| Deprecated | Added or Changed in API Version 9 | System API|
| -------------------- | ----------------------- | --------- |
| setModuleUpgradeFlag | setHapModuleUpgradeFlag | Yes |
| isModuleRemovable | isHapModuleRemovable | Yes |
| getDispatcher | getDispatchInfo | Yes |
**Adaptation Guide**
To use installation-free APIs, import a new module and modify the APIs according to their mappings.
```
import freeInstall from '@ohos.bundle.freeInstall'
```
## cl.bundlemanager.13 Installation-Free Structure Field Changes
The fields of the **DisPatchInfo**, **AbilityFormInfo**, **ModuleDistroInfo**, and **ModuleConfigInfo** structures are changed as follows:
1. The name of the **dispatchAPI** field in **DispatchInfo** is changed to [dispatchAPIVersion](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/DispatchInfo.d.ts), and the type is string, which is unchanged. The field indicates the version of the installation-free API. The meaning remains unchanged.
2. The type of the **supportDimensions** field in the **AbilityFormInfo** structure is changed from **Array\<number>** to **Array\<string>**.
3. The type of the **defaultDimension** field in the **AbilityFormInfo** structure is changed from **number** to **string**.
4. The **mainAbility** field is deprecated in the **ModuleDistroInfo** structure and moved to the **ModuleConfigInfo** structure.
5. The **mainAbility** field is added to the **ModuleConfigInfo** structure.
**Change Impacts**
Applications using APIs earlier than version 9 are not affected. The value type of certain fields in the structures is changed. As a result, applications using APIs of version 9 may fail to be compiled using the new SDK.
**Key API/Component Changes**
1. DispatchInfo
| Deprecated | Added or Changed in API Version 9 | Type |
| ----------- | ------------------ | ------ |
| dispatchAPI | dispatchAPIVersion | string |
2. AbilityFormInfo
| Field | Type in API Version 9 | Original Type |
| ----------------- | -------------- | -------------- |
| supportDimensions | Array\<string> | Array\<number> |
| defaultDimension | string | number |
3. ModuleDistroInfo
| Field | Added or Changed in API Version 9| Type |
| ----------- | -------------- | ------ |
| mainAbility | N/A | string |
4. MooduleConfigInfo
| Field| Added or Changed in API Version 9| Type |
| ---- | -------------- | ------ |
| N/A | mainAbility | string |
**Adaptation Guide**
To use installation-free APIs, import a new module and modify the structures according to their mappings.
```
import freeInstall from '@ohos.bundle.freeInstall'
```
## cl.bundlemanager.14 Structure Changes
The structure **GrantStatus** is changed to **PermissionGrantState**. The enumeration type and values remain unchanged.
**Change Impacts**
Applications using APIs earlier than version 9 are not affected. The structure name is changed. As a result, applications using APIs of version 9 may fail to be compiled using the new SDK.
**Key API/Component Changes**
The **GrantStatus** structure indicating the authorization status is changed to **PermissionGrantState** in **@ohos.bundle.bundleManager.d.ts**.
| Name | Value|
| ------------------ | ------ |
| PERMISSION_DENIED | -1 |
| PERMISSION_GRANTED | 0 |
**Adaptation Guide**
Import a new module and change the structure name to **PermissionGrantState**.
```
import bundle form '@ohos.bundle.bundleManager'
```
## cl.bundlemanager.15 Bundle Manager ShortcutInfo Structure Field Changes
Fields in the **ShortcutInfo** structure of the bundle manager are changed. The **bundle/shortcutInfo.d.ts** fields are deprecated, and the file is changed to [bundleManager/ShortcutInfo.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/ShortcutInfo.d.ts). The **ShortcutInfo** and **ShortWant** structures are changed to system APIs.
**Change Impacts**
Applications using APIs earlier than version 9 are not affected. The value type of certain fields in the structures is changed. As a result, applications using APIs of version 9 may fail to be compiled using the new SDK.
**Key API/Component Changes**
The **ShortcutInfo** and **ShortcutWant** structures are involved. To use the level-2 module export function, import the new module **@ohos.bundle.launcherBundleManager**.
The following table lists the field changes of the **ShortcutInfo** structure. Fields that are not listed in the table still exist in API version 9.
| Deprecated | Added or Changed in API Version 9| Type |
| -------------- | -------------- | ------- |
| disableMessage | N/A | string |
| isStatic | N/A | boolean |
| isHomeShortcut | N/A | boolean |
| isEnabled | N/A | boolean |
| disableMessage | N/A | boolean |
The following table lists the field changes of the **ShortcutWant** structure. Fields that are not listed in the table still exist in API version 9.
| Deprecated | Added or Changed in API Version 9| Type |
| ----------- | -------------- | ------ |
| targetClass | targetAbility | string |
**Adaptation Guide**
To use installation-free APIs, import a new module and modify the structures according to their mappings.
```
import launcherBundleManager form '@ohos.bundle.launcherBundleManager'
```
## cl.bundlemanager.16 getBundleInstaller API Changes
The **getBundleInstaller** API of the bundle manager is moved from **@ohos.bundle.d.ts** to [@ohos.bundle.installer.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/@ohos.bundle.installer.d.ts).
The system capability is **SystemCapability.BundleManager.BundleFramework.Core**.
**Change Impacts**
Applications using APIs earlier than version 9 are not affected. Applications that use APIs of version 9 need to adapt the new module and APIs.
**Key API/Component Changes**
1. For **getBundleInstaller**, the import module is changed from **@ohos.bundle** to **@ohos.bundle.installer**.
**Adaptation Guide**
Import the new bundle manager installation module and call **getBundleInstaller**.
```
import installer form '@ohos.bundle.installer'
```
## cl.bundlemanager.17 Bundle Manager Installation API Changes
The bundle manager installation API is moved from **bundle/bundleInstaller.d.ts** to [@ohos.bundle.installer.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/@ohos.bundle.installer.d.ts). The system capability is **SystemCapability.BundleManager.BundleFramework.Core**.
**Change Impacts**
Applications using APIs earlier than version 9 are not affected. Applications that use APIs of version 9 need to adapt the new module and APIs.
**Key API/Component Changes**
1. The exception handling capability is added to the **install**, **uninstall**, and **recover** APIs. The API names and input parameters remain unchanged, and only the module name is changed.
2. Fields are added to the **HashParam** structure as follows.
| Added in API Version 9 | Type |
| ---------- | ------ |
| moduleName | string |
| hashValue | string |
3. Fields are added to the **InstallParam** structure as follows.
| Added in API Version 9 | Type |
| ----------------- | ----------------- |
| userId | number |
| installFlag | number |
| isKeepData | boolean |
| hashParams | Array\<HashParam> |
| crowdtestDeadline | number |
4. The **InstallStatus** structure is deprecated.
**Adaptation Guide**
Import the new bundle manager installation module and call **getBundleInstaller**.
```
import installer form '@ohos.bundle.installer'
```
## cl.bundlemanager.18 Bundle Manager Installation Function Changes
The installation specifications of the bundle manager module are changed, in which whether the application **deviceType** setting matches the device type is verified. If they do not match, the installation fails.
**Change Impacts**
Applications developed in earlier versions are affected. Applications can be successfully installed in the image of the new version only after adaptation.
**Key API/Component Changes**
N/A
**Adaptation Guide**
Configure device types in the application configuration file **config.json** or **module.json**.
```
{
"module": {
"name": "entry",
"type": "entry",
// ...
"deviceTypes":[
// In this example, default and tablet are configured. In this case, the application can be installed on default and tablet.
"default",
"tablet"
],
// ...
}
```
## cl.bundlemanager.19 innerBundleManger Module API Changes
**innerBundleManager** API functions are unchanged, but API usage is changed. The [@ohos.bundle.launcherBundleManager.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/@ohos.bundle.launcherBundleManager.d.ts) module needs to be imported to use **innerBundleManager** APIs. The system capability is **SystemCapability.BundleManager.BundleFramework.Core**.
**Change Impacts**
There is no impact on applications that use the APIs of versions earlier than 9. Applications that use the **innerBundleManager** API capabilities need to adapt the new module and APIs.
**Key API/Component Changes**
The functions and input parameters of the following APIs remain unchanged, and API exception handling is added. When a level-2 module is used to export **ShortcutInfo** and **ShortcutWant**, the **@ohos.bundle.launcherBundleManager** module needs to be imported. The **on** and **off** APIs are deprecated from **@ohos.bundle.innerBundleManger.d.ts** and moved to **@ohos.bundle.bundleMonitor.d.ts**.
1. getLauncherAbilityInfos<br>
2. getAllLauncherAbilityInfos<br>
3. getShortcutInfos
**Adaptation Guide**
Import the new module **@ohos.bundle.launcherBundleManage**.
```
import launcherBundleManager form '@ohos.bundle.launcherBundleManage'
```
## cl.bundlemanager.20 innerBundleManagr Module Changes
**innerBundleManager** API functions are unchanged, but API usage is changed. The [@ohos.bundle.bundleMonitor.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/@ohos.bundle.bundleMonitor.d.ts) module needs to be imported to use **innerBundleManager** APIs, which are system APIs. The system capability is **SystemCapability.BundleManager.BundleFramework.Core**.
**Change Impacts**
There is no impact on applications that use the APIs of versions earlier than 9. Applications that use the **innerBundleManager** API capabilities need to adapt the new module and APIs.
**Key API/Component Changes**
The **on** and **off** APIs are changed to **@ohos.bundle.bundleMonitor.d.ts**. The input parameters are different from those of the original APIs. The function prototype of the APIs of version 9 is as follows:
```
function on(type: BundleChangedEvent, callback: Callback<BundleChangedInfo>): void;
function off(type: BundleChangedEvent, callback?: Callback<BundleChangedInfo>): void;
```
**BundleChangedEvent**:
```
type BundleChangedEvent = 'add' | 'update' | 'remove';
```
Callback function of **BundleChangedInfo**:
```
interface BundleChangedInfo {
readonly bundleName: string;
readonly userId: number;
}
```
After obtaining **BundleChangedInfo**, perform related operations (that is, the **add**, **update**, and **remove** functions in **BundleStatusCallback** of the original API).
**Adaptation Guide**
Import the **bundleMonitor** module and call related APIs.
```
import bundleMonitor form '@ohos.bundle.bundleMonitor'
```
## cl.bundlemanager.21 bundleStatusCallback.d.ts API Changes
The **bundleStatusCallback.d.ts** APIs of the bundle manager are deprecated and moved to [@ohos.bundle.bundleMonitor.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/@ohos.bundle.bundleMonitor.d.ts). The **add**, **update**, and **remove** functions in **BundleStatusCallback** are deprecated and changed to **BundleChangedEvent**, which is a system API. The system capability is **SystemCapability.BundleManager.BundleFramework.Core**.
**Change Impacts**
There is no impact on applications that use the APIs of versions earlier than 9. Applications that use the **BundleStatusCallback** API capabilities need to adapt the new module and APIs.
**Key API/Component Changes**
All the following functions are deprecated. The **BundleChangedEvent** API is added to **@ohos.bundle.bundleMonitor.d.ts**.
1. add
2. update
3. remove
**Adaptation Guide**
Import the **bundleMonitor** module and call related APIs. Different from the previous **BundleStatusCallback**, **BundleStatusCallback** passes the **add**, **update**, and **remove** functions to the **on** and **off** APIs. The **BundleMonitor** uses the **on** or **off** API of version 9 to return **BundleChangedInfo** to the caller through the callback.
```
import bundleMonitor form '@ohos.bundle.bundleMonitor'
```
## cl.bundlemanager.22 Zlib Module API Changes
The **Zlib** module APIs of the bundle manager are changed. Certain APIs in [@ohos.zlib.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/@ohos.zlib.d.ts) are deprecated and changed. The system capability is **SystemCapability.BundleManager.Zlib**.
**Change Impacts**
There is no impact on applications that use the APIs of versions earlier than 9. Applications that use APIs of version 9 need to adapt the new module and APIs.
**Key API/Component Changes**
The following table lists the changed APIs in **@ohos.zlib.d.ts**. The usage of the new APIs of version 9 is the same, and API exception handling is supported.
| Deprecated | Added or Changed in API Version 9| System API|
| --------- | -------------- | --------- |
| zipFile | compressFile | Yes |
| unzipFile | decompressFile | Yes |
| ErrorCode | N/A | Yes |
**Adaptation Guide**
The import module does not change. The new API is directly used to adapt exception handling.
```
import zlib form '@ohos.zlib'
```
\ No newline at end of file
# Wi-Fi Subsystem ChangeLog
## cl.wifi.1 Migration of System APIs and APIs in API Version 9 to the New @ohos.wifiManager.d.ts
**@ohos.wifi.d.ts** does not allow for throwing error codes, which is required by API version 9 and the system APIs. Therefore, all system APIs and APIs in API version 9 of **@ohos.wifi.d.ts** are migrated to the newly added **@ohos.wifiManager.d.ts**, and error code description is also added.
Import **@ohos.wifiManager.d.ts**, so that system APIs and APIs in API version 9 of the Wi-Fi subsystem can be used.
import wifiManager from '@ohos.wifiManager';
**Change Impacts**
System APIs and APIs in API version 9 are affected. Import **@ohos.wifiManager** to make sure that system APIs and APIs in API version 9 of the Wi-Fi subsystem can be used.
import wifiManager from '@ohos.wifiManager';
Other APIs are not affected.
**Key API/Component Changes**
| Class| Type | Declaration | Change Type |
| ---- | --------- | ------------------------------------------------------------ | ------------------------------------------------------------ |
| wifi | namespace | declare namespace wifi | Migrated this API in API version 9 to **@ohos.wifiManager.d.ts**. |
| wifi | method | function enableWifi(): void | Migrated this API in API version 9 to **@ohos.wifiManager.d.ts**, and changed the return value type to void. |
| wifi | method | function disableWifi(): void | Migrated this API in API version 9 to **@ohos.wifiManager.d.ts**, and changed the return value type to void. |
| wifi | method | function scan(): void | Migrated this API in API version 9 to **@ohos.wifiManager.d.ts**, and changed the return value type to void. |
| wifi | method | function getScanResults(): Promise&lt;Array&lt;WifiScanInfo&gt;&gt; | Migrated this API in API version 9 to **@ohos.wifiManager.d.ts**, and changed **getScanInfos** to **getScanResults**.|
| wifi | method | function getScanResults(callback: AsyncCallback&lt;Array&lt;WifiScanInfo&gt;&gt;): void | Migrated this API in API version 9 to **@ohos.wifiManager.d.ts**, and changed **getScanInfos** to **getScanResults**.|
| wifi | method | function getScanResultsSync(): &nbsp;Array&lt;[WifiScanInfo]&gt; | Migrated this API in API version 9 to **@ohos.wifiManager.d.ts**. |
| wifi | method | function addCandidateConfig(config: WifiDeviceConfig): Promise&lt;number&gt; | Migrated this API in API version 9 to **@ohos.wifiManager.d.ts**. |
| wifi | method | function addCandidateConfig(config: WifiDeviceConfig, callback: AsyncCallback&lt;number&gt;): void | Migrated this API in API version 9 to **@ohos.wifiManager.d.ts**. |
| wifi | method | function removeCandidateConfig(networkId: number): Promise&lt;void&gt; | Migrated this API in API version 9 to **@ohos.wifiManager.d.ts**. |
| wifi | method | function removeCandidateConfig(networkId: number, callback: AsyncCallback&lt;void&gt;): void | Migrated this API in API version 9 to **@ohos.wifiManager.d.ts**. |
| wifi | method | function addUntrustedConfig(config: WifiDeviceConfig): Promise&lt;boolean&gt; | Deleted this API in API version 9. |
| wifi | method | function addUntrustedConfig(config: WifiDeviceConfig, callback: AsyncCallback&lt;boolean&gt;): void | Deleted this API in API version 9. |
| wifi | method | function removeUntrustedConfig(config: WifiDeviceConfig): Promise&lt;boolean&gt; | Deleted this API in API version 9. |
| wifi | method | function removeUntrustedConfig(config: WifiDeviceConfig, callback: AsyncCallback&lt;boolean&gt;): void | Deleted this API in API version 9. |
| wifi | method | function getCandidateConfigs(): &nbsp;Array&lt;[WifiDeviceConfig]&gt; | Migrated this API in API version 9 to **@ohos.wifiManager.d.ts**. |
| wifi | method | function connectToCandidateConfig(networkId: number): void | Migrated this API in API version 9 to **@ohos.wifiManager.d.ts**. |
| wifi | method | function connectToNetwork(networkId: number): void | Migrated this API in API version 9 to **@ohos.wifiManager.d.ts**, and changed the return value to **void**.|
| wifi | method | function connectToDevice(config: WifiDeviceConfig): void | Migrated this API in API version 9 to **@ohos.wifiManager.d.ts**, and changed the return value to **void**.|
| wifi | method | function disconnect(): void | Migrated this API in API version 9 to **@ohos.wifiManager.d.ts**, and changed the return value to **void**.|
| wifi | method | function reassociate(): void | Migrated this API in API version 9 to **@ohos.wifiManager.d.ts**, and changed the return value to **void**.|
| wifi | method | function reconnect(): void | Migrated this API in API version 9 to **@ohos.wifiManager.d.ts**, and changed the return value to **void**.|
| wifi | method | function disableNetwork(netId: number): void | Migrated this API in API version 9 to **@ohos.wifiManager.d.ts**, and changed the return value to **void**.|
| wifi | method | function removeAllNetwork(): void | Migrated this API in API version 9 to **@ohos.wifiManager.d.ts**, and changed the return value to **void**.|
| wifi | method | function removeDevice(id: number): void | Migrated this API in API version 9 to **@ohos.wifiManager.d.ts**, and changed the return value to **void**.|
| wifi | method | function enableHotspot(): void | Migrated this API in API version 9 to **@ohos.wifiManager.d.ts**, and changed the return value to **void**.|
| wifi | method | function disableHotspot(): void | Migrated this API in API version 9 to **@ohos.wifiManager.d.ts**, and changed the return value to **void**.|
| wifi | method | function setHotspotConfig(config: HotspotConfig): void | Migrated this API in API version 9 to **@ohos.wifiManager.d.ts**, and changed the return value to **void**.|
| wifi | method | function getP2pLocalDevice(): Promise&lt;WifiP2pDevice&gt; | Migrated this API in API version 9 to **@ohos.wifiManager.d.ts**. |
| wifi | method | function getP2pLocalDevice(callback: AsyncCallback&lt;WifiP2pDevice&gt;): void | Migrated this API in API version 9 to **@ohos.wifiManager.d.ts**. |
| wifi | method | function getP2pGroups(): Promise&lt;Array&lt;WifiP2pGroupInfo&gt;&gt; | Migrated this API in API version 9 to **@ohos.wifiManager.d.ts**. |
| wifi | method | function getP2pGroups(callback: AsyncCallback&lt;Array&lt;WifiP2pGroupInfo&gt;&gt;): void | Migrated this API in API version 9 to **@ohos.wifiManager.d.ts**. |
| wifi | method | function createGroup(config: WifiP2PConfig): void | Migrated this API in API version 9 to **@ohos.wifiManager.d.ts**, and changed the return value to **void**.|
| wifi | method | function removeGroup(): void | Migrated this API in API version 9 to **@ohos.wifiManager.d.ts**, and changed the return value to **void**.|
| wifi | method | function p2pConnect(config: WifiP2PConfig): void | Migrated this API in API version 9 to **@ohos.wifiManager.d.ts**, and changed the return value to **void**.|
| wifi | method | function p2pCancelConnect(): void | Migrated this API in API version 9 to **@ohos.wifiManager.d.ts**, and changed the return value to **void**.|
| wifi | method | function startDiscoverDevices(): void | Migrated this API in API version 9 to **@ohos.wifiManager.d.ts**, and changed the return value to **void**.|
| wifi | method | function stopDiscoverDevices(): void | Migrated this API in API version 9 to **@ohos.wifiManager.d.ts**, and changed the return value to **void**.|
| wifi | method | function deletePersistentGroup(netId: number): void | Migrated this API in API version 9 to **@ohos.wifiManager.d.ts**, and changed the return value to **void**.|
| wifi | method | function setDeviceName(devName: string): void | Migrated this API in API version 9 to **@ohos.wifiManager.d.ts**, and changed the return value to **void**.|
| wifi | interface | export interface WifiEapConfig | Migrated this API in API version 9 to **@ohos.wifiManager.d.ts**. |
| wifi | enum | export enum EapMethod | Migrated this API in API version 9 to **@ohos.wifiManager.d.ts**. |
| wifi | enum | export enum Phase2Method | Migrated this API in API version 9 to **@ohos.wifiManager.d.ts**. |
| wifi | interface | export interface WifiDeviceConfig | Migrated this API in API version 9 to **@ohos.wifiManager.d.ts**, and added the **eapConfig** parameter.|
| wifi | interface | export interface IpConfig | Migrated this API in API version 9 to **@ohos.wifiManager.d.ts**, and added the **prefixLength** parameter.|
| wifi | interface | export interface WifiInfoElem | Migrated this API in API version 9 to **@ohos.wifiManager.d.ts**. |
| wifi | enum | export enum WifiChannelWidth | Migrated this API in API version 9 to **@ohos.wifiManager.d.ts**. |
| wifi | interface | export interface WifiScanInfo | Migrated this API in API version 9 to **@ohos.wifiManager.d.ts**, and added the following three parameters: **centerFrequency0**, **centerFrequency1**, and **infoElems**.|
| wifi | enum | export enum WifiSecurityType | Migrated this API in API version 9 to **@ohos.wifiManager.d.ts**, and added four encryption types. |
| wifi | interface | export interface WifiLinkedInfo | Migrated this API in API version 9 to **@ohos.wifiManager.d.ts**, and added the **MacType** parameter. |
**(Optional) Adaptation Guide**
The following uses **getLinkedInfo** as an example to show how it is called in the new version:
```
import wifiManager from '@ohos.wifiManager'
wifiManager.getLinkedInfo((err, data) => {
if (err) {
console.error("get linked info error");
return;
}
console.info("get linked info: " + JSON.stringify(data));
});
wifiManager.getLinkedInfo().then(data => {
console.info("get linked info: " + JSON.stringify(data));
}).catch(error => {
console.info("get linked info error");
});
```
## cl.wifiext.1 Migration of System APIs and APIs in API Version 9 to the New @ohos.wifiManagerExt.d.ts
**@ohos.wifiext.d.ts** does not allow for throwing error codes, which is required by API version 9 and the system API. Therefore, all system APIs and APIs in API version 9 of **@ohos.wifiext.d.ts** are migrated to the newly added **@ohos.wifiManagerExt.d.ts**, and error code description is also added.
Import **@ohos.wifiManagerExt.d.ts**, so that system APIs and APIs in API version 9 of the Wi-Fi subsystem can be used.
import wifiManagerExt from '@ohos.wifiManagerExt';
**Change Impacts**
System APIs and APIs in API version 9 are affected. Import **@ohos.wifiManagerExt**, so that system APIs and APIs in API version 9 of the Wi-Fi subsystem can be used together with the Wi-Fi manager.
import wifiManagerExt from '@ohos.wifiManagerExt';
Other APIs are not affected.
# Account Subsystem ChangeLog
## cl.account_os_account.1 Change in Error Information Return Method of Account System APIs
Certain system APIs of the account subsystem use service logic return values to indicate error information, which does not comply with the API error code specifications of OpenHarmony. The following changes are made in API version 9 and later:
Asynchronous API: An error message is returned via **AsyncCallback** or the **error** object of **Promise**.
Synchronous API: An error message is returned via an exception.
**Change Impacts**
The application developed based on earlier versions needs to adapt the new APIs and their method for returning API error information. Otherwise, the original service logic will be affected.
**Key API/Component Changes**
Before change:
- class UserAuth
- setProperty(request: SetPropertyRequest, callback: AsyncCallback&lt;number&gt;): void;
- setProperty(request: SetPropertyRequest): Promise&lt;number&gt;;
- cancelAuth(contextID: Uint8Array): number;
- class PINAuth
- registerInputer(inputer: Inputer): boolean;
- UserIdentityManager
- cancel(challenge: Uint8Array): number;
After change:
- class UserAuth
- setProperty(request: SetPropertyRequest, callback: AsyncCallback&lt;void&gt;): void;
- setProperty(request: SetPropertyRequest): Promise&lt;void&gt;;
- cancelAuth(contextID: Uint8Array): void;
- class PINAuth
- registerInputer(inputer: Inputer): void;
- UserIdentityManager
- cancel(challenge: Uint8Array): void;
**Adaptation Guide**
The following uses **setProperty** as an example for asynchronous APIs:
```
import account_osAccount from "@ohos.account.osAccount"
userAuth.setProperty({
authType: account_osAccount.AuthType.PIN,
key: account_osAccount.SetPropertyType.INIT_ALGORITHM,
setInfo: new Uint8Array([0])
}, (err) => {
if (err) {
console.log("setProperty failed, error: " + JSON.stringify(err));
} else {
console.log("setProperty successfully");
}
});
userAuth.setProperty({
authType: account_osAccount.AuthType.PIN,
key: account_osAccount.SetPropertyType.INIT_ALGORITHM,
setInfo: new Uint8Array([0])
}).catch((err) => {
if (err) {
console.log("setProperty failed, error: " + JSON.stringify(err));
} else {
console.log("setProperty successfully");
}
});
```
The following uses **registerInputer** as an example for synchronous APIs:
```
import account_osAccount from "@ohos.account.osAccount"
let pinAuth = new account_osAccount.PINAuth()
let inputer = {
onGetData: (authType, passwordRecipient) => {
let password = new Uint8Array([0]);
passwordRecipient.onSetData(authType, password);
}
}
try {
pinAuth.registerInputer(inputer);
} catch (err) {
console.log("registerInputer failed, error: " + JSON.stringify(err));
}
```
## cl.account_os_account.2 ACTION Definition Change for the Application Account Authentication Service
**Change Impacts**
For the application developed based on an earlier version, you need to modify **ACTION** in the application configuration file (**config.json** for the FA model and **module.json5** for the Stage model) to normally provide the application authentication service.
**Key API/Component Changes**
Involved constant:
@ohos.ability.wantConstant.ACTION_APP_ACCOUNT_AUTH
Before change:
ACTION_APP_ACCOUNT_AUTH = "account.appAccount.action.auth"
After change:
ACTION_APP_ACCOUNT_AUTH = "ohos.appAccount.action.auth"
**Adaptation Guide**
For a third-party application providing the account authentication service, adapt the changed application account authentication **ACTION** in the **ServiceAbility** configuration file (**config.json** for the FA module or **module.json5** for the Stage module).
```
"abilities": [
{
"name": "ServiceAbility",
"srcEntrance": "./ets/ServiceAbility/ServiceAbility.ts",
...
"visible": true,
"skills": {
{
"actions": [
"ohos.appAccount.action.auth"
]
}
}
}]
}
# Customization Subsystem ChangeLog
Compared with OpenHarmony 3.2.8.1, OpenHarmony 3.2.8.3 has the following API changes in the customization subsystem:
## cl.Customization.1 Change of the Enterprise Device Management Module Name
Beginning from OpenHarmony 3.2.8.3, **@ohos.enterpriseDeviceManager.d.ts** is changed to **@ohos.enterprise.adminManager.d.ts**. You need to adapt your applications according to the following information.
**Change Impacts**
The application developed based on OpenHarmony earlier than 3.2.8.3 must be adapted so that it can be properly compiled in the SDK environment of the new version.
**Key API/Component Changes**
| Original API | New API |
| --------------------------------- | ---------------------------------- |
| @ohos.enterpriseDeviceManager.d.ts | @ohos.enterprise.adminManager.d.ts |
**Adaptation Guide**
The original APIs are only migrated to the new namespace. Therefore, you can modify **import** to solve the adaptation problem.
If the original API uses **@ohos.enterpriseDeviceManager**:
```js
import enterpriseDeviceManager from '@ohos.enterpriseDeviceManager';
```
You can directly modify **import** to switch to the new namespace:
```js
import enterpriseDeviceManager from '@ohos.enterprise.adminManager';
```
## cl.Customization.2 enterpriseDeviceManager/DeviceSettingsManager.d.ts Module Change
Beginning from OpenHarmony 3.2.8.3, **enterpriseDeviceManager/DeviceSettingsManager.d.ts** is changed to **ohos.enterprise.dateTimeManager.d.ts**.
**Change Impacts**
The application developed based on OpenHarmony earlier than 3.2.8.3 must be adapted so that it can be properly compiled in the SDK environment of the new version.
**Key API/Component Changes**
| Original API | Original API Type | New API | New API Type |
| --------------------------------- | --------- | ---------------------------------- | ----- |
| enterpriseDeviceManager/DeviceSettingsManager.d.ts | interface | @ohos.enterprise.dateTimeManager.d.ts | namespace |
**Adaptation Guide**
If the **setDateTime** API of **enterpriseDeviceManager/DeviceSettingsManager.d.ts** is used:
```js
import enterpriseDeviceManager from '@ohos.enterpriseDeviceManager'
let wantTemp = {
bundleName: "bundleName",
abilityName: "abilityName",
};
enterpriseDeviceManager.getDeviceSettingsManager((error, mgr) => {
if (error) {
console.log("error code:" + error.code + " error message:" + error.message);
return;
}
mgr.setDateTime(wantTemp, 1526003846000, (error) => {
if (error) {
console.log("error code:" + error.code + " error message:" + error.message);
}
});
});
```
You need to import the new namespace for adaptation:
```js
import dateTimeManager from '@ohos.enterprise.dateTimeManager'
let wantTemp = {
bundleName: "bundleName",
abilityName: "abilityName",
};
dateTimeManager.setDateTime(wantTemp, 1526003846000, (error) => {
if (error) {
console.log("error code:" + error.code + " error message:" + error.message);
}
})
```
## cl.Customization.3 System API Change
Beginning from OpenHarmony 3.2.8.3, all enterprise device management APIs are changed to system APIs.
**Change Impacts**
All APIs can be called only by system applications.
**Key API/Component Changes**
| Module | Class | Method/Attribute/Enumeration/Constant | Change Type|
| ------------------------- | ------------------- | ------------------------------------------------------------ | -------- |
| @ohos.enterprise.adminManager | adminManager | **function** enableAdmin(admin: Want, enterpriseInfo: EnterpriseInfo, type: AdminType, callback: AsyncCallback<**void**>): void; | Changed to a system API |
| @ohos.enterprise.adminManager | adminManager | **function** enableAdmin(admin: Want, enterpriseInfo: EnterpriseInfo, type: AdminType, userId: number, callback: AsyncCallback<**void**>): void; | Changed to a system API |
| @ohos.enterprise.adminManager | adminManager | **function** enableAdmin(admin: Want, enterpriseInfo: EnterpriseInfo, type: AdminType, userId?: number): Promise<**void**>; | Changed to a system API |
| @ohos.enterprise.adminManager | adminManager | **function** disableAdmin(admin: Want, callback: AsyncCallback<**void**>): void; | Changed to a system API |
| @ohos.enterprise.adminManager | adminManager | **function** disableAdmin(admin: Want, userId: number, callback: AsyncCallback<**void**>): void; | Changed to a system API |
| @ohos.enterprise.adminManager | adminManager | **function** disableAdmin(admin: Want, userId?: number): Promise<**void**>; | Changed to a system API |
| @ohos.enterprise.adminManager | adminManager | **function** disableSuperAdmin(bundleName: String, callback: AsyncCallback<**void**>): void; | Changed to a system API |
| @ohos.enterprise.adminManager | adminManager | **function** disableSuperAdmin(bundleName: String): Promise<**void**>; | Changed to a system API |
| @ohos.enterprise.adminManager | adminManager | **function** isAdminEnabled(admin: Want, callback: AsyncCallback<**boolean**>): void; | Changed to a system API |
| @ohos.enterprise.adminManager | adminManager | **function** isAdminEnabled(admin: Want, userId: number, callback: AsyncCallback<**boolean**>): void; | Changed to a system API |
| @ohos.enterprise.adminManager | adminManager | **function** isAdminEnabled(admin: Want, userId?: number): Promise<**boolean**>; | Changed to a system API |
| @ohos.enterprise.adminManager | adminManager | **function** getEnterpriseInfo(admin: Want, callback: AsyncCallback<**EnterpriseInfo**>): void; | Changed to a system API |
| @ohos.enterprise.adminManager | adminManager | **function** getEnterpriseInfo(admin: Want): Promise<**EnterpriseInfo**>; | Changed to a system API |
| @ohos.enterprise.adminManager | adminManager | **function** setEnterpriseInfo(admin: Want, enterpriseInfo: EnterpriseInfo, callback: AsyncCallback<**void**>): void; | Changed to a system API |
| @ohos.enterprise.adminManager | adminManager | **function** setEnterpriseInfo(admin: Want, enterpriseInfo: EnterpriseInfo): Promise<**void**>; | Changed to a system API |
| @ohos.enterprise.adminManager | adminManager | **function** isSuperAdmin(bundleName: String, callback: AsyncCallback<**boolean**>): void; | Changed to a system API |
| @ohos.enterprise.adminManager | adminManager | **function** isSuperAdmin(bundleName: String): Promise<**boolean**>; | Changed to a system API |
| @ohos.enterprise.adminManager | adminManager | **function** subscribeManagedEvent(admin: Want, managedEvents: Array<**ManagedEvent**>, callback: AsyncCallback<**void**>): void; | Changed to a system API |
| @ohos.enterprise.adminManager | adminManager | **function** subscribeManagedEvent(admin: Want, managedEvents: Array<**ManagedEvent**>): Promise<**void**>; | Changed to a system API |
| @ohos.enterprise.adminManager | adminManager | **function** unsubscribeManagedEvent(admin: Want, managedEvents: Array<**ManagedEvent**>, callback: AsyncCallback<**void**>): void; | Changed to a system API |
| @ohos.enterprise.adminManager | adminManager | **function** unsubscribeManagedEvent(admin: Want, managedEvents: Array<**ManagedEvent**>): Promise<**void**>; | Changed to a system API |
| @ohos.enterprise.adminManager | adminManager | **interface** EnterpriseInfo | Changed to a system API |
| @ohos.enterprise.adminManager | adminManager | **enum** AdminType | Changed to a system API |
| @ohos.enterprise.adminManager | adminManager | **enum** ManagedEvent | Changed to a system API |
| @ohos.enterprise.dataTimeManager | dateTimeManager | **function** setDateTime(admin: Want, time: number, callback: AsyncCallback<**void**>): void; | Changed to a system API |
| @ohos.enterprise.dataTimeManager | dateTimeManager | **function** setDateTime(admin: Want, time: number): Promise<**void**>; | Changed to a system API |
## cl.Customization.4 API Permission Change
Beginning from OpenHarmony 3.2.8.3, permission verification is required for some APIs.
**Change Impacts**
The application developed based on OpenHarmony earlier than 3.2.8.3 must have the corresponding permission so that it can properly call these APIs.
**Key API/Component Changes**
| Module | Class | Method/Attribute/Enumeration/Constant | New Permission|
| ------------------------- | ------------------- | ------------------------------------------------------------ | -------- |
| @ohos.enterprise.adminManager | adminManager | **function** enableAdmin(admin: Want, enterpriseInfo: EnterpriseInfo, type: AdminType, callback: AsyncCallback<**void**>): void; | ohos.permission.MANAGE_ENTERPRISE_DEVICE_ADMIN |
| @ohos.enterprise.adminManager | adminManager | **function** enableAdmin(admin: Want, enterpriseInfo: EnterpriseInfo, type: AdminType, userId: number, callback: AsyncCallback<**void**>): void; | ohos.permission.MANAGE_ENTERPRISE_DEVICE_ADMIN |
| @ohos.enterprise.adminManager | adminManager | **function** enableAdmin(admin: Want, enterpriseInfo: EnterpriseInfo, type: AdminType, userId?: number): Promise<**void**>; | ohos.permission.MANAGE_ENTERPRISE_DEVICE_ADMIN |
| @ohos.enterprise.adminManager | adminManager | **function** disableAdmin(admin: Want, callback: AsyncCallback<**void**>): void; | ohos.permission.MANAGE_ENTERPRISE_DEVICE_ADMIN |
| @ohos.enterprise.adminManager | adminManager | **function** disableAdmin(admin: Want, userId: number, callback: AsyncCallback<**void**>): void; | ohos.permission.MANAGE_ENTERPRISE_DEVICE_ADMIN |
| @ohos.enterprise.adminManager | adminManager | **function** disableAdmin(admin: Want, userId?: number): Promise<**void**>; | ohos.permission.MANAGE_ENTERPRISE_DEVICE_ADMIN |
| @ohos.enterprise.adminManager | adminManager | **function** disableSuperAdmin(bundleName: String, callback: AsyncCallback<**void**>): void; | ohos.permission.MANAGE_ENTERPRISE_DEVICE_ADMIN |
| @ohos.enterprise.adminManager | adminManager | **function** disableSuperAdmin(bundleName: String): Promise<**void**>; | ohos.permission.MANAGE_ENTERPRISE_DEVICE_ADMIN |
| @ohos.enterprise.adminManager | adminManager | **function** setEnterpriseInfo(admin: Want, enterpriseInfo: EnterpriseInfo, callback: AsyncCallback<**void**>): void; | ohos.permission.SET_ENTERPRISE_INFO |
| @ohos.enterprise.adminManager | adminManager | **function** setEnterpriseInfo(admin: Want, enterpriseInfo: EnterpriseInfo): Promise<**void**>; | ohos.permission.SET_ENTERPRISE_INFO |
| @ohos.enterprise.adminManager | adminManager | **function** subscribeManagedEvent(admin: Want, managedEvents: Array<**ManagedEvent**>, callback: AsyncCallback<**void**>): void; | ohos.permission.ENTERPRISE_SUBSCRIBE_MANAGED_EVENT |
| @ohos.enterprise.adminManager | adminManager | **function** subscribeManagedEvent(admin: Want, managedEvents: Array<**ManagedEvent**>): Promise<**void**>; | ohos.permission.ENTERPRISE_SUBSCRIBE_MANAGED_EVENT |
| @ohos.enterprise.adminManager | adminManager | **function** unsubscribeManagedEvent(admin: Want, managedEvents: Array<**ManagedEvent**>, callback: AsyncCallback<**void**>): void; | ohos.permission.ENTERPRISE_SUBSCRIBE_MANAGED_EVENT |
| @ohos.enterprise.adminManager | adminManager | **function** unsubscribeManagedEvent(admin: Want, managedEvents: Array<**ManagedEvent**>): Promise<**void**>; | ohos.permission.ENTERPRISE_SUBSCRIBE_MANAGED_EVENT |
| @ohos.enterprise.dataTimeManager | dateTimeManager | **function** setDateTime(admin: Want, time: number, callback: AsyncCallback<**void**>): void; | ohos.permission.ENTERPRISE_SET_DATETIME |
| @ohos.enterprise.dataTimeManager | dateTimeManager | **function** setDateTime(admin: Want, time: number): Promise<**void**>; | ohos.permission.ENTERPRISE_SET_DATETIME |
**Adaptation Guide**
Apply for the corresponding permission to call these APIs properly.
# Location Subsystem ChangeLog
## cl.location.1 Migration of System APIs and APIs in API Version 9 to the New @ohos.geoLocationManager.d.ts
APIs in **@ohos.geolocation.d.ts** do not support throwing error codes. However, APIs in API version 9 and system APIs all need to support throwing error codes. To support this function, all system APIs and APIs in API version 9 in **@ohos.geolocation.d.ts** are migrated to the newly added **@ohos.geoLocationManager.d.ts** file, and corresponding error code description is added.
To use system APIs and APIs in API version 9 of the location subsystem, you need to import **@ohos.geoLocationManager**.
import geoLocationManager from '@ohos.geoLocationManager';
**Change Impacts**
System APIs and APIs in API version 9 are affected. To ensure normal use of these APIs, you need to import **@ohos.geoLocationManager**.
import geoLocationManager from '@ohos.geoLocationManager';
Other APIs are not affected.
**Key API/Component Changes**
| Class| Type| Declaration| Change Type|
| -- | -- | -- | -- |
|geolocation| namespace | declare namespacegeolocation| Migrated this API in API version 9 to **@ohos.geoLocationManager.d.ts**.|
|geolocation | interface | export interface ReverseGeocodingMockInfo | Migrated this API in API version 9 to **@ohos.geoLocationManager.d.ts**.|
|geolocation | interface | export interface LocationMockConfig | Migrated this API in API version 9 to **@ohos.geoLocationManager.d.ts**.|
|geolocation | interface | export interface CountryCode | Migrated this API in API version 9 to **@ohos.geoLocationManager.d.ts**.|
|geolocation | enum | export enum CountryCodeType | Migrated this API in API version 9 to **@ohos.geoLocationManager.d.ts**.|
|geolocation.GeoAddress | field | isFromMock?: Boolean; | Migrated this API in API version 9 to **@ohos.geoLocationManager.d.ts**.|
|geolocation.Location | field | isFromMock?: Boolean; | Migrated this API in API version 9 to **@ohos.geoLocationManager.d.ts**.|
|geolocation.GeoLocationErrorCode | field | NOT_SUPPORTED = 100 | Migrated this API in API version 9 to **@ohos.geoLocationManager.d.ts**.|
|geolocation.GeoLocationErrorCode | field | QUERY_COUNTRY_CODE_ERROR | Migrated this API in API version 9 to **@ohos.geoLocationManager.d.ts**.|
|geolocation| method | function on(type: 'countryCodeChange', callback: Callback&lt;CountryCode&gt;): void; | Migrated this API in API version 9 to **@ohos.geoLocationManager.d.ts**.|
|geolocation| method | function off(type: 'countryCodeChange', callback?: Callback&lt;CountryCode&gt;): void; | Migrated this API in API version 9 to **@ohos.geoLocationManager.d.ts**.|
|geolocation| method | function getCountryCode(callback: AsyncCallback&lt;CountryCode&gt;): void; | Migrated this API in API version 9 to **@ohos.geoLocationManager.d.ts**.|
|geolocation| method | function getCountryCode(): Promise&lt;CountryCode&gt;; | Migrated this API in API version 9 to **@ohos.geoLocationManager.d.ts**.|
|geolocation| method | function enableLocationMock(scenario: LocationRequestScenario, callback: AsyncCallback&lt;void&gt;): void; | Deleted this API in API version 9.|
|geolocation| method | function enableLocationMock(callback: AsyncCallback&lt;void&gt;): void; | Migrated this API in API version 9 to **@ohos.geoLocationManager.d.ts**.|
|geolocation| method | function enableLocationMock(scenario: LocationRequestScenario): Promise&lt;void&gt;; | Deleted this API in API version 9.|
|geolocation| method | function enableLocationMock(): Promise&lt;void&gt;; | Migrated this API in API version 9 to **@ohos.geoLocationManager.d.ts**.|
|geolocation| method | function disableLocationMock(scenario: LocationRequestScenario, callback: AsyncCallback&lt;void&gt;): void; | Deleted this API in API version 9.|
|geolocation| method | function disableLocationMock(callback: AsyncCallback&lt;void&gt;): void; | Migrated this API in API version 9 to **@ohos.geoLocationManager.d.ts**. |
|geolocation| method | function disableLocationMock(scenario: LocationRequestScenario): Promise&lt;void&gt;; | Deleted this API in API version 9.|
|geolocation| method | function disableLocationMock(): Promise&lt;void&gt;; | Migrated this API in API version 9 to **@ohos.geoLocationManager.d.ts**. |
|geolocation| method | function setMockedLocations(config: LocationMockConfig, callback: AsyncCallback&lt;void&gt;): void; | Migrated this API in API version 9 to **@ohos.geoLocationManager.d.ts**. |
|geolocation| method | function setMockedLocations(config: LocationMockConfig): Promise&lt;void&gt;; | Migrated this API in API version 9 to **@ohos.geoLocationManager.d.ts**. |
|geolocation| method | function enableReverseGeocodingMock(callback: AsyncCallback&lt;void&gt;): void; | Migrated this API in API version 9 to **@ohos.geoLocationManager.d.ts**. |
|geolocation| method | function enableReverseGeocodingMock(): Promise&lt;void&gt;; | Migrated this API in API version 9 to **@ohos.geoLocationManager.d.ts**. |
|geolocation| method | function disableReverseGeocodingMock(callback: AsyncCallback&lt;void&gt;): void; | Migrated this API in API version 9 to **@ohos.geoLocationManager.d.ts**. |
|geolocation| method | function disableReverseGeocodingMock(): Promise&lt;void&gt;; | Migrated this API in API version 9 to **@ohos.geoLocationManager.d.ts**. |
|geolocation| method | function setReverseGeocodingMockInfo(mockInfos: Array&lt;ReverseGeocodingMockInfo&gt;, callback: AsyncCallback&lt;void&gt;): void; | Migrated this API in API version 9 to **@ohos.geoLocationManager.d.ts**. |
|geolocation| method | function setReverseGeocodingMockInfo(mockInfos: Array&lt;ReverseGeocodingMockInfo&gt;): Promise&lt;void&gt;; | Migrated this API in API version 9 to **@ohos.geoLocationManager.d.ts**. |
|geolocation| method | function isLocationPrivacyConfirmed(type: LocationPrivacyType, callback: AsyncCallback&lt;boolean&gt;): void; | Migrated this API in API version 9 to **@ohos.geoLocationManager.d.ts**. |
|geolocation| method | function isLocationPrivacyConfirmed(type: LocationPrivacyType): Promise&lt;boolean&gt;; | Migrated this API in API version 9 to **@ohos.geoLocationManager.d.ts**. |
|geolocation| method | function setLocationPrivacyConfirmStatus(type: LocationPrivacyType, isConfirmed: boolean, callback: AsyncCallback&lt;boolean&gt;): void; | Migrated this API in API version 9 to **@ohos.geoLocationManager.d.ts** and changed the return value in the callback to **void**. |
|geolocation| method | function setLocationPrivacyConfirmStatus(type: LocationPrivacyType, isConfirmed: boolean): Promise&lt;boolean&gt;; | Migrated this API in API version 9 to **@ohos.geoLocationManager.d.ts** and changed the return value in the promise to **void**. |
**(Optional) Adaptation Guide**
The following uses **enableLocation** as an example to show how it is called in the new version:
```ts
import geoLocationManager from '@ohos.geoLocationManager';
try {
geoLocationManager.enableLocation((err, data) => {
if (err) {
console.log('enableLocation: err=' + JSON.stringify(err));
}
});
} catch (err) {
console.error("errCode:" + err.code + ",errMessage:" + err.message);
}
```
## cl.location.2 Location Service Permission Change
From API version 9, the **ohos.permission.APPROXIMATELY_LOCATION** permission is added for obtaining the approximate location.
If you use API version 9 or later, you need to apply for both the **ohos.permission.LOCATION** and **ohos.permission.APPROXIMATELY_LOCATION** permissions. Applying for only the **ohos.permission.LOCATION** permission will fail.
**Change Impacts**
Applications using API versions earlier than 9 are not affected. For an application using API version 9 or later, the method for applying for the location permission is changed. The details are as follows:
Before using basic location capabilities, check whether your application has been granted the permission to access the device location information. If not, your application needs to obtain the permission from the user as described below.
The system provides the following location permissions:
- ohos.permission.LOCATION
- ohos.permission.APPROXIMATELY_LOCATION
- ohos.permission.LOCATION_IN_BACKGROUND
If your application needs to access the device location information, it must first apply for required permissions. Specifically speaking:
API versions earlier than 9: Apply for **ohos.permission.LOCATION**.
API version 9 and later: Apply for **ohos.permission.APPROXIMATELY_LOCATION**, or apply for **ohos.permission.APPROXIMATELY_LOCATION** and **ohos.permission.LOCATION**. Note that **ohos.permission.LOCATION** cannot be applied for separately.
| API Version| Location Permission| Permission Application Result| Location Accuracy|
| -------- | -------- | -------- | -------- |
| Earlier than 9| ohos.permission.LOCATION | Success| Location accurate to meters|
| 9 and later| ohos.permission.LOCATION | Failure| No location obtained|
| 9 and later| ohos.permission.APPROXIMATELY_LOCATION | Success| Location accurate to 5 kilometers|
| 9 and later| ohos.permission.APPROXIMATELY_LOCATION and ohos.permission.LOCATION| Success| Location accurate to meters|
If your application needs to access the device location information when running in the background, it must be configured to be able to run in the background and be granted the **ohos.permission.LOCATION_IN_BACKGROUND** permission. In this way, the system continues to report device location information after your application moves to the background.
You can declare the required permission in your application's configuration file. For details, see the [permission application guide](../../../application-dev/security/accesstoken-guidelines.md).
**Key API/Component Changes**
Applications using API versions earlier than 9 are not affected.
If your application uses API version 9 or later and needs to call APIs requiring the **ohos.permission.LOCATION** permission in **@ohos.geolocation** and **@ohos.geoLocationManager**, you need to apply for the corresponding permission as described previously.
# Distributed Scheduler Subsystem ChangeLog
## cl.DistributedManagerService.1 Adding DATASYNC Permission Verification on the continuationManager API
In earlier versions, the **continuationManager** API does not verify the caller, which does not comply with the OpenHarmony API specifications.
Now, before using **continuationManager**, the caller must apply for the **ohos.permission.DISTRIBUTED_DATASYNC** permission.
**Change Impacts**
The application developed based on earlier versions needs to apply for the **ohos.permission.DISTRIBUTED_DATASYNC** permission in advance. Otherwise, the original service logic will be affected.
**Key API/Component Changes**
Involved APIs:
- continuationManager.registerContinuation;
- continuationManager.on;
- continuationManager.off;
- continuationManager.unregisterContinuation;
- continuationManager.updateContinuationState;
- continuationManager.startContinuationDeviceManager;
# *Example* Subsystem ChangeLog
Changes that affect contract compatibility of the last version should be described in the ChangeLog. The changes include but are not limited to those related to API names, parameters, return values, required permissions, call sequence, enumerated values, configuration parameters, and paths. The last version can be an LTS, release, beta, or monthly version, or the like. Contract compatibility, also called semantic compatibility, means that the original program behavior should remain consistent over versions.
## cl.subsystemname.x xxx Function Change (Example: DeviceType Attribute Change or Camera Permission Change. Use a short description.)
Add the number **cl.*subsystemname*.*x*** before each change title, where **cl** is the abbreviation of ChangeLog, *subsystemname* is the standard English name of the subsystem, and *x* indicates the change sequence number (starting from 1 in ascending order).
Describe the changes in terms of functions. Example: *n* and *m* of the *a* function are changed. Developers need to adapt their applications based on the change description.
If there is a requirement or design document corresponding to the change, attach the requirement number or design document number in the description.
**Change Impacts**
Describe whether released APIs (JS or native APIs) are affected or API behavior is changed.
Describe whether available applications are affected, that is, whether an adaptation is required for building the application code in the SDK environment of the new version.
**Key API/Component Changes**
List the API/component changes involved in the function change.
**Adaptation Guide (Optional)**
Provide guidance for developers on how to adapt their application to the changes to be compatible with the new version.
Example:
Change parameter *n* to *m* in the *a* file.
```
sample code
```
# Telephony Subsystem Changelog
## cl.telephony.1 Input Parameter Change of System APIs of the SMS Module
Input parameters are changed for some released system APIs of the SMS module of the telephony subsystem, which do not comply with the API specifications of OpenHarmony. The following changes are made in API version 9 and later:
The **slotId** parameter is added to the **isImsSmsSupported** API, indicating the slot ID.
**Change Impacts**
Input parameters of JavaScript APIs need to be adapted for applications developed based on earlier versions. Otherwise, relevant functions will be affected.
**Key API/Component Changes**
- Involved APIs
isImsSmsSupported(callback: AsyncCallback<boolean>): void;
isImsSmsSupported(): Promise<boolean>;
- Before change:
```js
function isImsSmsSupported(callback: AsyncCallback<boolean>): void;
function isImsSmsSupported(): Promise<boolean>;
```
- After change:
```js
function isImsSmsSupported(slotId: number, callback: AsyncCallback<boolean>): void;
function isImsSmsSupported(slotId: number): Promise<boolean>;
```
**Adaptation Guide**
Add an input parameter. The sample code is as follows:
Callback mode
```js
let slotId = 0;
sms.isImsSmsSupported(slotId, (err, data) => {
console.log(`callback: err->${JSON.stringify(err)}, data->${JSON.stringify(data)}`);
});
```
Promise mode
```js
let slotId = 0;
let promise = sms.isImsSmsSupported(slotId);
promise.then(data => {
console.log(`isImsSmsSupported success, promise: data->${JSON.stringify(data)}`);
}).catch(err => {
console.error(`isImsSmsSupported failed, promise: err->${JSON.stringify(err)}`);
});
```
\ No newline at end of file
# *Example* Subsystem ChangeLog
Changes that affect contract compatibility of the last version should be described in the ChangeLog. The changes include but are not limited to those related to API names, parameters, return values, required permissions, call sequence, enumerated values, configuration parameters, and paths. The last version can be an LTS, release, beta, or monthly version, or the like. Contract compatibility, also called semantic compatibility, means that the original program behavior should remain consistent over versions.
## cl.subsystemname.x xxx Function Change (Example: DeviceType Attribute Change or Camera Permission Change. Use a short description.)
Add the number **cl.*subsystemname*.*x*** before each change title, where **cl** is the abbreviation of ChangeLog, *subsystemname* is the standard English name of the subsystem, and *x* indicates the change sequence number (starting from 1 in ascending order).
Describe the changes in terms of functions. Example: *n* and *m* of the *a* function are changed. Developers need to adapt their applications based on the change description.
If there is a requirement or design document corresponding to the change, attach the requirement number or design document number in the description.
**Change Impacts**
Describe whether released APIs (JS or native APIs) are affected or API behavior is changed.
Describe whether available applications are affected, that is, whether an adaptation is required for building the application code in the SDK environment of the new version.
**Key API/Component Changes**
List the API/component changes involved in the function change.
**Adaptation Guide (Optional)**
Provide guidance for developers on how to adapt their application to the changes to be compatible with the new version.
Example:
Change parameter *n* to *m* in the *a* file.
```
sample code
```
# User IAM Subsystem Changelog
## cl.useriam.1 Deletion of API9 GetVesion
Deleted the **GetVersion()** API.
**Change Impact**
The **GetVersion()** API cannot be used from this version.
**Key API/Component Changes**
| Module | Class | Method/Attribute/Enum/Constant | Change Type |
| ---------------------- | ------------------- | ------------------------- | ------------------------ |
| ohos.userIAM.userAuth | function | getVersion() : number | Deleted|
**Adaptation Guide**
Delete the use of **GetVersion()**.
## cl.useriam.2 Change of the API8 GetVesion() Return Value
Changed the return value of **GetVersion()** (in API version 8) from **0** to **1**.
**Change Impact**
If the application verifies the return value of **GetVersion()** (API version 8), the verification fails.
**Key API/Component Changes**
The return value of **GetVersion()** (in API version 8) is changed from **0** to **1**.
**Adaptation Guide**
Delete the use of **GetVersion()** (API version 8) because this API has been deprecated.
# Account Subsystem ChangeLog
## cl.account_os_account.1 Expansion of Distributed Account Nickname and Profile Picture Specifications
The existing distributed account nickname and profile picture specifications cannot meet requirements in scenarios where the nickname is long and profile picture is large.
Therefore, the distributed account nickname and profile picture specifications are expanded.
**Change Impacts**
The API change is forward compatible. Applications developed based on earlier versions can use the APIs in accordance with the new specifications, without affecting the original logic.
**Key API/Component Changes**
Before change:
- The nickname cannot exceed 20 characters, and the profile picture size cannot exceed 3 MB.
After change:
- The nickname cannot exceed 1024 characters, and the profile picture size cannot exceed 10 MB.
# Location Subsystem ChangeLog
## cl.location.1 Deletion of the geoLocationManager.requestEnableLocation API in API Version 9
When the location function is disabled, your application can call the **geoLocationManager.requestEnableLocation** API to request the user to enable the location function. However, this API is seldom used because the user is not notified of the scenario in which your application uses the location information.
Therefore, your application shows a popup, asking the user to go to the settings page and enable the location function. In addition, the popup clearly states the scenarios in which the location information will be used, improving user experience.
**Change Impacts**
Your application cannot use the **geoLocationManager.requestEnableLocation** API in API version 9 to request the user to enable the location function. Instead, you need to implement a popup asking the user to enable the location function for your application.
**Key API/Component Changes**
| Class | API Type| Declaration | Change Type |
| ------------------ | -------- | ------------------------------------------------------------ | ------------------ |
| geoLocationManager | method | function requestEnableLocation(callback: AsyncCallback&lt;boolean&gt;): void; | Deleted from API version 9|
| geoLocationManager | method | function requestEnableLocation(): Promise&lt;boolean&gt;; | Deleted from API version 9|
# Wi-Fi Subsystem ChangeLog
## cl.location.1 Location Service Permission Change
From API version 9, the **ohos.permission.APPROXIMATELY_LOCATION** permission is added for obtaining the approximate location.
If you use API version 9 or later, you need to apply for both the **ohos.permission.LOCATION** and **ohos.permission.APPROXIMATELY_LOCATION** permissions. Applying for only the **ohos.permission.LOCATION** permission will fail.
**Change Impacts**
Applications using API versions earlier than 9 are not affected. For an application using API version 9 or later, the method for applying for the location permission is changed. The details are as follows:
Before using basic location capabilities, check whether your application has been granted the permission to access the device location information. If not, your application needs to obtain the permission from the user as described below.
The system provides the following location permissions:
- ohos.permission.LOCATION
- ohos.permission.APPROXIMATELY_LOCATION
- ohos.permission.LOCATION_IN_BACKGROUND
If your application needs to access the device location information, it must first apply for required permissions. Specifically speaking:
API versions earlier than 9: Apply for **ohos.permission.LOCATION**.
API version 9 and later: Apply for **ohos.permission.APPROXIMATELY_LOCATION**, or apply for **ohos.permission.APPROXIMATELY_LOCATION** and **ohos.permission.LOCATION**. Note that **ohos.permission.LOCATION** cannot be applied for separately.
| API Version| Location Permission | Permission Application Result| Location Accuracy |
| ------------- | ------------------------------------------------------------ | -------- | -------------------------------- |
| Earlier than 9 | ohos.permission.LOCATION | Success | Location accurate to meters|
| 9 and later | ohos.permission.LOCATION | Failure | No location obtained |
| 9 and later | ohos.permission.APPROXIMATELY_LOCATION | Success | Location accurate to 5 kilometers |
| 9 and later | ohos.permission.APPROXIMATELY_LOCATION and ohos.permission.LOCATION| Success | Location accurate to meters|
If your application needs to access the device location information when running in the background, it must be configured to be able to run in the background and be granted the **ohos.permission.LOCATION_IN_BACKGROUND** permission. In this way, the system continues to report device location information after your application moves to the background.
You can declare the required permissions in your application's configuration file. For details, see the [permission application guide](../../../application-dev/security/accesstoken-guidelines.md).
**Key API/Component Changes**
| Class | API Type| Declaration | Change Type |
| ----------- | -------- | ------------------------------------------------------------ | ------------------------------------------------------------ |
| wifiManager | method | function scan(): void; | The permission is changed to **ohos.permission.SET_WIFI_INFO**, **ohos.permission.LOCATION**, and **ohos.permission.APPROXIMATELY_LOCATION**.|
| wifiManager | method | function getScanResults(): Promise&lt;Array&lt;WifiScanInfo&gt;&gt;; | The permission is changed to **ohos.permission.GET_WIFI_INFO** and **ohos.permission.GET_WIFI_PEERS_MAC** or **ohos.permission.GET_WIFI_INFO**, **ohos.permission.LOCATION**, and **ohos.permission.APPROXIMATELY_LOCATION**.|
| wifiManager | method | function getScanResults(callback: AsyncCallback&lt;Array&lt;WifiScanInfo&gt;&gt;): void; | The permission is changed to **ohos.permission.GET_WIFI_INFO** and **ohos.permission.GET_WIFI_PEERS_MAC** or **ohos.permission.GET_WIFI_INFO**, **ohos.permission.LOCATION**, and **ohos.permission.APPROXIMATELY_LOCATION**.|
| wifiManager | method | function getScanResultsSync(): Array&lt;WifiScanInfo&gt;; | The permission is changed to **ohos.permission.GET_WIFI_INFO** and **ohos.permission.GET_WIFI_PEERS_MAC** or **ohos.permission.GET_WIFI_INFO**, **ohos.permission.LOCATION**, and **ohos.permission.APPROXIMATELY_LOCATION**.|
| wifiManager | method | function getCandidateConfigs(): Array&lt;WifiDeviceConfig&gt;; | The permission is changed to **ohos.permission.GET_WIFI_INFO**, **ohos.permission.LOCATION**, and **ohos.permission.APPROXIMATELY_LOCATION**.|
| wifiManager | method | function getDeviceConfigs(): Array&lt;WifiDeviceConfig&gt;; | The permission is changed to **ohos.permission.GET_WIFI_INFO**, **ohos.permission.LOCATION**, **ohos.permission.APPROXIMATELY_LOCATION**, and **ohos.permission.GET_WIFI_CONFIG**.|
| wifiManager | method | function getStations(): Array&lt;StationInfo&gt;; | The permission is changed to **ohos.permission.GET_WIFI_INFO**, **ohos.permission.LOCATION**, **ohos.permission.APPROXIMATELY_LOCATION**, and **ohos.permission.MANAGE_WIFI_HOTSPOT**.|
| wifiManager | method | function getCurrentGroup(): Promise&lt;WifiP2pGroupInfo&gt;; | The permission is changed to **ohos.permission.GET_WIFI_INFO**, **ohos.permission.LOCATION**, and **ohos.permission.APPROXIMATELY_LOCATION**.|
| wifiManager | method | function getCurrentGroup(callback: AsyncCallback&lt;WifiP2pGroupInfo&gt;): void; | The permission is changed to **ohos.permission.GET_WIFI_INFO**, **ohos.permission.LOCATION**, and **ohos.permission.APPROXIMATELY_LOCATION**.|
| wifiManager | method | function getP2pPeerDevices(): Promise&lt;WifiP2pDevice[]&gt;; | The permission is changed to **ohos.permission.GET_WIFI_INFO**, **ohos.permission.LOCATION**, and **ohos.permission.APPROXIMATELY_LOCATION**.|
| wifiManager | method | function getP2pPeerDevices(callback: AsyncCallback&lt;WifiP2pDevice[]&gt;): void; | The permission is changed to **ohos.permission.GET_WIFI_INFO**, **ohos.permission.LOCATION**, and **ohos.permission.APPROXIMATELY_LOCATION**.|
| wifiManager | method | function p2pConnect(config: WifiP2PConfig): void; | The permission is changed to **ohos.permission.GET_WIFI_INFO**, **ohos.permission.LOCATION**, and **ohos.permission.APPROXIMATELY_LOCATION**.|
| wifiManager | method | function startDiscoverDevices(): void; | The permission is changed to **ohos.permission.GET_WIFI_INFO**, **ohos.permission.LOCATION**, and **ohos.permission.APPROXIMATELY_LOCATION**.|
| wifiManager | method | function getP2pGroups(): Promise&lt;Array&lt;WifiP2pGroupInfo&gt;&gt;; | The permission is changed to **ohos.permission.GET_WIFI_INFO**, **ohos.permission.LOCATION**, and **ohos.permission.APPROXIMATELY_LOCATION**.|
| wifiManager | method | function getP2pGroups(callback: AsyncCallback&lt;Array&lt;WifiP2pGroupInfo&gt;&gt;): void; | The permission is changed to **ohos.permission.GET_WIFI_INFO**, **ohos.permission.LOCATION**, and **ohos.permission.APPROXIMATELY_LOCATION**.|
| wifiManager | method | function on(type: "p2pDeviceChange", callback: Callback&lt;WifiP2pDevice&gt;): void; | The permission is changed to **ohos.permission.GET_WIFI_INFO**, **ohos.permission.LOCATION**, and **ohos.permission.APPROXIMATELY_LOCATION**.|
| wifiManager | method | function off(type: "p2pDeviceChange", callback?: Callback&lt;WifiP2pDevice&gt;): void; | The permission is changed to **ohos.permission.LOCATION** and **ohos.permission.APPROXIMATELY_LOCATION**.|
| wifiManager | method | function on(type: "p2pPeerDeviceChange", callback: Callback&lt;WifiP2pDevice[]&gt;): void; | The permission is changed to **ohos.permission.GET_WIFI_INFO**, **ohos.permission.LOCATION**, and **ohos.permission.APPROXIMATELY_LOCATION**.|
| wifiManager | method | function off(type: "p2pPeerDeviceChange", callback?: Callback&lt;WifiP2pDevice[]&gt;): void; | The permission is changed to **ohos.permission.LOCATION** and **ohos.permission.APPROXIMATELY_LOCATION**.|
# Web Subsystem ChangeLog
Compared with earlier versions, OpenHarmony 4.0.2.1 has the following API changes in its Web subsystem:
## cl.web.1 Parameter Type Change of postMessageEvent
The **postMessageEvent** API supported only the string type. In OpenHarmony 4.0.2.1 and later versions, it also supports the ArrayBuffer type.
**Change Impacts**
The API change is forward compatible. Applications developed based on earlier versions can still use the API, and the original functions are not affected.
**Key API/Component Changes**
- Involved APIs
postMessageEvent(message: string): void
- Before change
```ts
postMessageEvent(message: string): void
```
- After change
```ts
type WebMessage = ArrayBuffer | string
postMessageEvent(message: WebMessage): void
```
**Adaptation Guide**
The API change is forward compatible. Applications developed based on earlier versions can still use the API, and the original functions are not affected.
## cl.web.2 Parameter Type Change of onMessageEvent
The **onMessageEvent** API supported only the string type. In OpenHarmony 4.0.2.1 and later versions, it also supports the ArrayBuffer type.
**Change Impacts**
The API change is forward compatible. Applications developed based on earlier versions can still use the API. With the corresponding logic handling added, the original functions are not affected.
**Key API/Component Changes**
- Involved APIs
onMessageEvent(callback: (result: string) => void): void
- Before change
```ts
onMessageEvent(callback: (result: string) => void): void
```
- After change
```ts
type WebMessage = ArrayBuffer | string
onMessageEvent(callback: (result: WebMessage) => void): void
```
**Adaptation Guide**
The API change is forward compatible. Applications developed based on earlier versions can still use the API. With the corresponding logic handling added, the original functions are not affected.
# Ability Subsystem ChangeLog
## cl.ability.1 System API Usage Rule Change
System application verification is not performed for system APIs provided by the ability when they are called. The APIs can be used by a third-party application using the full SDK, which brings security risks. Therefore, application identity verification is added to OpenHarmony 4.0.2.1 and later versions.
**Change Impacts**
System APIs are available to only system applications. When a third-party application tries to use a system API, the **202** error will be returned via either an exception or asynchronous callback.
**Key API/Component Changes**
Below are the system APIs.
| Module | API | Error Code Return Mode|
| -------------------------------------- | ------------------------------------------------------------ | -------------- |
| @ohos.app.ability.abilityManager.d.ts | updateConfiguration(config: Configuration, callback: AsyncCallback<void>): void | Asynchronous callback |
| @ohos.app.ability.abilityManager.d.ts | updateConfiguration(config: Configuration): Promise<void> | Asynchronous callback |
| @ohos.app.ability.abilityManager.d.ts | getAbilityRunningInfos(): Promise<Array<AbilityRunningInfo>> | Asynchronous callback |
| @ohos.app.ability.abilityManager.d.ts | getAbilityRunningInfos(callback: AsyncCallback<Array<AbilityRunningInfo>>): void | Asynchronous callback |
| @ohos.app.ability.abilityManager.d.ts | getExtensionRunningInfos(upperLimit: number): Promise<Array<ExtensionRunningInfo>> | Asynchronous callback |
| @ohos.app.ability.abilityManager.d.ts | getExtensionRunningInfos(upperLimit: number, callback: AsyncCallback<Array<ExtensionRunningInfo>>): void | Asynchronous callback |
| @ohos.app.ability.abilityManager.d.ts | getTopAbility(): Promise<ElementName> | Exception |
| @ohos.app.ability.abilityManager.d.ts | getTopAbility(callback: AsyncCallback<ElementName>): void | Exception |
| @ohos.app.ability.appManager.d.ts | on(type: "applicationState", observer: ApplicationStateObserver): number | Asynchronous callback |
| @ohos.app.ability.appManager.d.ts | on(type: "applicationState", observer: ApplicationStateObserver, bundleNameList: Array<string>): number | Asynchronous callback |
| @ohos.app.ability.appManager.d.ts | off(type: "applicationState", observerId: number, callback: AsyncCallback<void>): void | Asynchronous callback |
| @ohos.app.ability.appManager.d.ts | off(type: "applicationState", observerId: number): Promise<void> | Asynchronous callback |
| @ohos.app.ability.appManager.d.ts | getForegroundApplications(callback: AsyncCallback<Array<AppStateData>>): void | Asynchronous callback |
| @ohos.app.ability.appManager.d.ts | getForegroundApplications(): Promise<Array<AppStateData>> | Asynchronous callback |
| @ohos.app.ability.appManager.d.ts | killProcessWithAccount(bundleName: string, accountId: number): Promise<void> | Asynchronous callback |
| @ohos.app.ability.appManager.d.ts | killProcessWithAccount(bundleName: string, accountId: number, callback: AsyncCallback<void>): void | Asynchronous callback |
| @ohos.app.ability.appManager.d.ts | killProcessesByBundleName(bundleName: string): Promise<void> | Asynchronous callback |
| @ohos.app.ability.appManager.d.ts | killProcessesByBundleName(bundleName: string, callback: AsyncCallback<void>) | Asynchronous callback |
| @ohos.app.ability.appManager.d.ts | clearUpApplicationData(bundleName: string): Promise<void> | Asynchronous callback |
| @ohos.app.ability.appManager.d.ts | clearUpApplicationData(bundleName: string, callback: AsyncCallback<void>) | Asynchronous callback |
| @ohos.app.ability.missionManager.d.ts | on(type: "mission", listener: MissionListener): number | Asynchronous callback |
| @ohos.app.ability.missionManager.d.ts | off(type: "mission", listenerId: number, callback: AsyncCallback<void>): void | Asynchronous callback |
| @ohos.app.ability.missionManager.d.ts | off(type: "mission", listenerId: number): Promise<void> | Asynchronous callback |
| @ohos.app.ability.missionManager.d.ts | getMissionInfo(deviceId: string, missionId: number, callback: AsyncCallback<MissionInfo>): void | Asynchronous callback |
| @ohos.app.ability.missionManager.d.ts | getMissionInfo(deviceId: string, missionId: number): Promise<MissionInfo> | Asynchronous callback |
| @ohos.app.ability.missionManager.d.ts | getMissionInfos(deviceId: string, numMax: number, callback: AsyncCallback<Array<MissionInfo>>): void | Asynchronous callback |
| @ohos.app.ability.missionManager.d.ts | getMissionInfos(deviceId: string, numMax: number): Promise<Array<MissionInfo>> | Asynchronous callback |
| @ohos.app.ability.missionManager.d.ts | getMissionSnapShot(deviceId: string, missionId: number, callback: AsyncCallback<MissionSnapshot>): void | Asynchronous callback |
| @ohos.app.ability.missionManager.d.ts | getMissionSnapShot(deviceId: string, missionId: number): Promise<MissionSnapshot> | Asynchronous callback |
| @ohos.app.ability.missionManager.d.ts | getLowResolutionMissionSnapShot(deviceId: string, missionId: number, callback: AsyncCallback<MissionSnapshot>): void | Asynchronous callback |
| @ohos.app.ability.missionManager.d.ts | getLowResolutionMissionSnapShot(deviceId: string, missionId: number): Promise<MissionSnapshot> | Asynchronous callback |
| @ohos.app.ability.missionManager.d.ts | lockMission(missionId: number, callback: AsyncCallback<void>): void | Asynchronous callback |
| @ohos.app.ability.missionManager.d.ts | lockMission(missionId: number): Promise<void> | Asynchronous callback |
| @ohos.app.ability.missionManager.d.ts | unlockMission(missionId: number, callback: AsyncCallback<void>): void | Asynchronous callback |
| @ohos.app.ability.missionManager.d.ts | unlockMission(missionId: number): Promise<void> | Asynchronous callback |
| @ohos.app.ability.missionManager.d.ts | clearMission(missionId: number, callback: AsyncCallback<void>): void | Asynchronous callback |
| @ohos.app.ability.missionManager.d.ts | clearMission(missionId: number): Promise<void> | Asynchronous callback |
| @ohos.app.ability.missionManager.d.ts | clearAllMissions(callback: AsyncCallback<void>): void | Asynchronous callback |
| @ohos.app.ability.missionManager.d.ts | clearAllMissions(): Promise<void> | Asynchronous callback |
| @ohos.app.ability.missionManager.d.ts | moveMissionToFront(missionId: number, callback: AsyncCallback<void>): void | Asynchronous callback |
| @ohos.app.ability.missionManager.d.ts | moveMissionToFront(missionId: number, options: StartOptions, callback: AsyncCallback<void>): void | Asynchronous callback |
| @ohos.app.ability.missionManager.d.ts | moveMissionToFront(missionId: number, options?: StartOptions): Promise<void> | Asynchronous callback |
| @ohos.app.ability.quickFixManager.d.ts | applyQuickFix(hapModuleQuickFixFiles: Array<string>, callback: AsyncCallback<void>): void | Asynchronous callback |
| @ohos.app.ability.quickFixManager.d.ts | applyQuickFix(hapModuleQuickFixFiles: Array<string>): Promise<void> | Asynchronous callback |
| @ohos.app.ability.quickFixManager.d.ts | getApplicationQuickFixInfo(bundleName: string, callback: AsyncCallback<ApplicationQuickFixInfo>): void | Asynchronous callback |
| @ohos.app.ability.quickFixManager.d.ts | getApplicationQuickFixInfo(bundleName: string): Promise<ApplicationQuickFixInfo> | Asynchronous callback |
| @ohos.app.ability.wantAgent.d.ts | getWant(agent: WantAgent, callback: AsyncCallback<Want>): void | Asynchronous callback |
| @ohos.app.ability.wantAgent.d.ts | getWant(agent: WantAgent): Promise<Want> | Asynchronous callback |
| @ohos.app.form.formHost.d.ts | deleteForm(formId: string, callback: AsyncCallback<void>): void | Asynchronous callback |
| @ohos.app.form.formHost.d.ts | deleteForm(formId: string): Promise<void> | Asynchronous callback |
| @ohos.app.form.formHost.d.ts | releaseForm(formId: string, callback: AsyncCallback<void>): void | Asynchronous callback |
| @ohos.app.form.formHost.d.ts | releaseForm(formId: string, isReleaseCache: boolean, callback: AsyncCallback<void>): void | Asynchronous callback |
| @ohos.app.form.formHost.d.ts | releaseForm(formId: string, isReleaseCache?: boolean): Promise<void> | Asynchronous callback |
| @ohos.app.form.formHost.d.ts | requestForm(formId: string, callback: AsyncCallback<void>): void | Asynchronous callback |
| @ohos.app.form.formHost.d.ts | requestForm(formId: string): Promise<void> | Asynchronous callback |
| @ohos.app.form.formHost.d.ts | castToNormalForm(formId: string, callback: AsyncCallback<void>): void | Asynchronous callback |
| @ohos.app.form.formHost.d.ts | castToNormalForm(formId: string): Promise<void> | Asynchronous callback |
| @ohos.app.form.formHost.d.ts | notifyVisibleForms(formIds: Array<string>, callback: AsyncCallback<void>): void | Asynchronous callback |
| @ohos.app.form.formHost.d.ts | notifyVisibleForms(formIds: Array<string>): Promise<void> | Asynchronous callback |
| @ohos.app.form.formHost.d.ts | notifyInvisibleForms(formIds: Array<string>, callback: AsyncCallback<void>): void | Asynchronous callback |
| @ohos.app.form.formHost.d.ts | notifyInvisibleForms(formIds: Array<string>): Promise<void> | Asynchronous callback |
| @ohos.app.form.formHost.d.ts | enableFormsUpdate(formIds: Array<string>, callback: AsyncCallback<void>): void | Asynchronous callback |
| @ohos.app.form.formHost.d.ts | enableFormsUpdate(formIds: Array<string>): Promise<void> | Asynchronous callback |
| @ohos.app.form.formHost.d.ts | disableFormsUpdate(formIds: Array<string>, callback: AsyncCallback<void>): void | Asynchronous callback |
| @ohos.app.form.formHost.d.ts | disableFormsUpdate(formIds: Array<string>): Promise<void> | Asynchronous callback |
| @ohos.app.form.formHost.d.ts | isSystemReady(callback: AsyncCallback<void>): void | Exception |
| @ohos.app.form.formHost.d.ts | isSystemReady(): Promise<void> | Exception |
| @ohos.app.form.formHost.d.ts | getAllFormsInfo(callback: AsyncCallback<Array<formInfo.FormInfo>>): void | Asynchronous callback |
| @ohos.app.form.formHost.d.ts | getAllFormsInfo(): Promise<Array<formInfo.FormInfo>> | Asynchronous callback |
| @ohos.app.form.formHost.d.ts | getFormsInfo(bundleName: string, callback: AsyncCallback<Array<formInfo.FormInfo>>): void | Asynchronous callback |
| @ohos.app.form.formHost.d.ts | getFormsInfo(bundleName: string, moduleName: string, callback: AsyncCallback<Array<formInfo.FormInfo>>): void | Asynchronous callback |
| @ohos.app.form.formHost.d.ts | getFormsInfo(bundleName: string, moduleName?: string): Promise<Array<formInfo.FormInfo>> | Asynchronous callback |
| @ohos.app.form.formHost.d.ts | deleteInvalidForms(formIds: Array<string>, callback: AsyncCallback<number>): void | Asynchronous callback |
| @ohos.app.form.formHost.d.ts | deleteInvalidForms(formIds: Array<string>): Promise<number> | Asynchronous callback |
| @ohos.app.form.formHost.d.ts | acquireFormState(want: Want, callback: AsyncCallback<formInfo.FormStateInfo>): void | Asynchronous callback |
| @ohos.app.form.formHost.d.ts | acquireFormState(want: Want): Promise<formInfo.FormStateInfo> | Asynchronous callback |
| @ohos.app.form.formHost.d.ts | on(type: "formUninstall", callback: Callback<string>): void | Exception |
| @ohos.app.form.formHost.d.ts | off(type: "formUninstall", callback?: Callback<string>): void | Exception |
| @ohos.app.form.formHost.d.ts | notifyFormsVisible(formIds: Array<string>, isVisible: boolean, callback: AsyncCallback<void>): void | Asynchronous callback |
| @ohos.app.form.formHost.d.ts | notifyFormsVisible(formIds: Array<string>, isVisible: boolean): Promise<void> | Asynchronous callback |
| @ohos.app.form.formHost.d.ts | notifyFormsEnableUpdate(formIds: Array<string>, isEnableUpdate: boolean, callback: AsyncCallback<void>): void | Asynchronous callback |
| @ohos.app.form.formHost.d.ts | notifyFormsEnableUpdate(formIds: Array<string>, isEnableUpdate: boolean): Promise<void> | Asynchronous callback |
| @ohos.app.form.formHost.d.ts | shareForm(formId: string, deviceId: string, callback: AsyncCallback<void>): void | Asynchronous callback |
| @ohos.app.form.formHost.d.ts | shareForm(formId: string, deviceId: string): Promise<void> | Asynchronous callback |
| @ohos.app.form.formHost.d.ts | notifyFormsPrivacyProtected(formIds: Array<string>, isProtected: boolean, callback: AsyncCallback<void>): void | Asynchronous callback |
| @ohos.app.form.formHost.d.ts | notifyFormsPrivacyProtected(formIds: Array<string>, isProtected: boolean): Promise<void> | Asynchronous callback |
| @ohos.app.form.formProvider.d.ts | requestPublishForm(want: Want, formBindingData: formBindingData.FormBindingData, callback: AsyncCallback<string>): void | Asynchronous callback |
| @ohos.app.form.formProvider.d.ts | requestPublishForm(want: Want, callback: AsyncCallback<string>): void | Asynchronous callback |
| @ohos.app.form.formProvider.d.ts | requestPublishForm(want: Want, formBindingData?: formBindingData.FormBindingData): Promise<string> | Asynchronous callback |
| @ohos.app.form.formProvider.d.ts | isRequestPublishFormSupported(callback: AsyncCallback<boolean>): void | Exception |
| @ohos.app.form.formProvider.d.ts | isRequestPublishFormSupported(): Promise<boolean> | Exception |
| UIAbilityContext.d.ts | startAbilityWithAccount(want: Want, accountId: number, callback: AsyncCallback<void>): void | Asynchronous callback |
| UIAbilityContext.d.ts | startAbilityWithAccount(want: Want, accountId: number, options: StartOptions, callback: AsyncCallback<void>): void | Asynchronous callback |
| UIAbilityContext.d.ts | startAbilityWithAccount(want: Want, accountId: number, options?: StartOptions): Promise<void> | Asynchronous callback |
| UIAbilityContext.d.ts | startAbilityForResultWithAccount(want: Want, accountId: number, callback: AsyncCallback<AbilityResult>): void | Exception |
| UIAbilityContext.d.ts | startAbilityForResultWithAccount(want: Want, accountId: number, options: StartOptions, callback: AsyncCallback<AbilityResult>): void | Exception |
| UIAbilityContext.d.ts | startAbilityForResultWithAccount(want: Want, accountId: number, options?: StartOptions): Promise<AbilityResult> | Exception |
| UIAbilityContext.d.ts | startServiceExtensionAbility(want: Want, callback: AsyncCallback<void>): void | Asynchronous callback |
| UIAbilityContext.d.ts | startServiceExtensionAbility(want: Want): Promise<void> | Asynchronous callback |
| UIAbilityContext.d.ts | startServiceExtensionAbilityWithAccount(want: Want, accountId: number, callback: AsyncCallback<void>): void | Asynchronous callback |
| UIAbilityContext.d.ts | startServiceExtensionAbilityWithAccount(want: Want, accountId: number): Promise<void> | Asynchronous callback |
| UIAbilityContext.d.ts | stopServiceExtensionAbility(want: Want, callback: AsyncCallback<void>): void | Asynchronous callback |
| UIAbilityContext.d.ts | stopServiceExtensionAbility(want: Want): Promise<void> | Asynchronous callback |
| UIAbilityContext.d.ts | stopServiceExtensionAbilityWithAccount(want: Want, accountId: number, callback: AsyncCallback<void>): void | Asynchronous callback |
| UIAbilityContext.d.ts | stopServiceExtensionAbilityWithAccount(want: Want, accountId: number): Promise<void> | Asynchronous callback |
| UIAbilityContext.d.ts | connectServiceExtensionAbilityWithAccount(want: Want, accountId: number, options: ConnectOptions): number | Asynchronous callback |
| UIAbilityContext.d.ts | setMissionIcon(icon: image.PixelMap, callback: AsyncCallback<void>): void | Asynchronous callback |
| UIAbilityContext.d.ts | setMissionIcon(icon: image.PixelMap): Promise<void> | Asynchronous callback |
| ServiceExtensionContext.d.ts | startAbilityWithAccount(want: Want, accountId: number, callback: AsyncCallback<void>): void | Asynchronous callback |
| ServiceExtensionContext.d.ts | startAbilityWithAccount(want: Want, accountId: number, options: StartOptions, callback: AsyncCallback<void>): void | Asynchronous callback |
| ServiceExtensionContext.d.ts | startAbilityWithAccount(want: Want, accountId: number, options?: StartOptions): Promise<void> | Asynchronous callback |
| ServiceExtensionContext.d.ts | startServiceExtensionAbility(want: Want, callback: AsyncCallback<void>): void | Asynchronous callback |
| ServiceExtensionContext.d.ts | startServiceExtensionAbility(want: Want): Promise<void> | Asynchronous callback |
| ServiceExtensionContext.d.ts | startServiceExtensionAbilityWithAccount(want: Want, accountId: number, callback: AsyncCallback<void>): void | Asynchronous callback |
| ServiceExtensionContext.d.ts | startServiceExtensionAbilityWithAccount(want: Want, accountId: number): Promise<void> | Asynchronous callback |
| ServiceExtensionContext.d.ts | stopServiceExtensionAbility(want: Want, callback: AsyncCallback<void>): void | Asynchronous callback |
| ServiceExtensionContext.d.ts | stopServiceExtensionAbility(want: Want): Promise<void> | Asynchronous callback |
| ServiceExtensionContext.d.ts | stopServiceExtensionAbilityWithAccount(want: Want, accountId: number, callback: AsyncCallback<void>): void | Asynchronous callback |
| ServiceExtensionContext.d.ts | stopServiceExtensionAbilityWithAccount(want: Want, accountId: number): Promise<void> | Asynchronous callback |
| ServiceExtensionContext.d.ts | connectServiceExtensionAbilityWithAccount(want: Want, accountId: number, options: ConnectOptions): number | Asynchronous callback |
| Context.d.ts | createBundleContext(bundleName: string): Context | Exception |
| Context.d.ts | createModuleContext(bundleName: string, moduleName: string): Context | Exception |
| FormExtensionContext.d.ts | startAbility(want: Want, callback: AsyncCallback<void>): void | Asynchronous callback |
| FormExtensionContext.d.ts | startAbility(want: Want): Promise<void> | Asynchronous callback |
# Bluetooth Subsystem ChangeLog
## cl.bluetooth.1 API Migration to @ohos.bluetoothManager.d.ts
**@ohos.bluetooth.d.ts** does not allow for throwing error codes, which is required by API version 9 and system APIs. Therefore, all APIs of **@ohos.bluetooth.d.ts** are migrated to the newly added **@ohos.bluetoothManager.d.ts**, and error code description is also added.
To use Bluetooth APIs, import **@ohos.bluetoothManager**.
```ts
import bluetoothManager from '@ohos.bluetoothManager';
```
**Change Impacts**
System APIs and APIs in API version 9 are affected. Import **@ohos.bluetoothManager** to use APIs that can throw error codes.
```ts
import bluetoothManager from '@ohos.bluetoothManager';
```
**Key API/Component Changes**
| Class | Original API | New API | Change Type |
| ---------------------------- | ------------------------------------------------------------ | ------------------------------------------------------------ | ------------------------------------------------------------ |
| bluetooth | function getState(): BluetoothState | function getState(): BluetoothState | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | method | function getBtConnectionState(): ProfileConnectionState; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | function pairDevice(deviceId: string): boolean | function pairDevice(deviceId: string): void | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts** and changed the return value to **void**.|
| bluetooth | function cancelPairedDevice(deviceId: string): boolean | function cancelPairedDevice(deviceId: string): void | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts** and changed the return value to **void**.|
| bluetooth | function getRemoteDeviceName(deviceId: string): string | function getRemoteDeviceName(deviceId: string): string | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | function getRemoteDeviceClass(deviceId: string): DeviceClass | function getRemoteDeviceClass(deviceId: string): DeviceClass | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | function enableBluetooth(): boolean | function enableBluetooth(): void | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts** and changed the return value to **void**.|
| bluetooth | function disableBluetooth(): boolean | function disableBluetooth(): void | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts** and changed the return value to **void**.|
| bluetooth | function getLocalName(): string | function getLocalName(): string | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | function getPairedDevices(): Array&lt;string&gt;; | function getPairedDevices(): Array&lt;string&gt;; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | function getProfileConnState(profileId: ProfileId): ProfileConnectionState | function getProfileConnectionState(profileId: ProfileId): ProfileConnectionState | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts** and changed the API name to **getProfileConnectionState**.|
| bluetooth | function setDevicePairingConfirmation(device: string, accept: boolean): boolean | function setDevicePairingConfirmation(device: string, accept: boolean): void | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts** and changed the return value to **void**.|
| bluetooth | function setLocalName(name: string): boolean; | function setLocalName(name: string): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts** and changed the return value to **void**.|
| bluetooth | function setBluetoothScanMode(mode: ScanMode, duration: number): boolean | function setBluetoothScanMode(mode: ScanMode, duration: number): void | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts** and changed the return value to **void**.|
| bluetooth | function getBluetoothScanMode(): ScanMod | function getBluetoothScanMode(): ScanMode | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | function startBluetoothDiscovery(): boolean | function startBluetoothDiscovery(): void | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**, added the **ohos.permission.APPROXIMATELY_LOCATION** permission, and changed the return value to **void**.|
| bluetooth | function stopBluetoothDiscovery(): boolean; | function stopBluetoothDiscovery(): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts** and changed the return value to **void**.|
| bluetooth | function on(type: "bluetoothDeviceFind", callback: Callback&lt;Array&lt;string&gt;&gt;): void; | function on(type: "bluetoothDeviceFind", callback: Callback&lt;Array&lt;string&gt;&gt;): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | function off(type: "bluetoothDeviceFind", callback?: Callback&lt;Array&lt;string&gt;&gt;): void; | function off(type: "bluetoothDeviceFind", callback?: Callback&lt;Array&lt;string&gt;&gt;): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | function on(type: "bondStateChange", callback: Callback&lt;BondStateParam&gt;): void; | function on(type: "bondStateChange", callback: Callbackk&lt;BondStateParam&gt;): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | function off(type: "bondStateChange", callback?: Callback&lt;BondStateParam&gt;): void; | function off(type: "bondStateChange", callback?: Callback&lt;BondStateParam&gt;): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | function on(type: "pinRequired", callback: Callback&lt;PinRequiredParam&gt;): void; | function on(type: "pinRequired", callback: Callback&lt;PinRequiredParam&gt;): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | function off(type: "pinRequired", callback?: Callback&lt;PinRequiredParam&gt;): void; | function off(type: "pinRequired", callback?: Callback&lt;PinRequiredParam&gt;): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | function on(type: "stateChange", callback: Callback&lt;BluetoothState&gt;): void; | function on(type: "stateChange", callback: Callback&lt;BluetoothState&gt;): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | function off(type: "stateChange", callback?: Callback&lt;BluetoothState&gt;): void; | function off(type: "stateChange", callback?: Callback&lt;BluetoothState&gt;): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | function sppListen(name: string, option: SppOption, callback: AsyncCallback&lt;number&gt;): void; | function sppListen(name: string, option: SppOption, callback: AsyncCallback&lt;number&gt;): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | function sppAccept(serverSocket: number, callback: AsyncCallback&lt;number&gt;): void; | function sppAccept(serverSocket: number, callback: AsyncCallback&lt;number&gt;): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | function sppConnect(device: string, option: SppOption, callback: AsyncCallback&lt;number&gt;): void; | function sppConnect(device: string, option: SppOption, callback: AsyncCallback&lt;number&gt;): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | function sppCloseServerSocket(socket: number): void; | function sppCloseServerSocket(socket: number): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | function sppCloseClientSocket(socket: number): void; | function sppCloseClientSocket(socket: number): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | function sppWrite(clientSocket: number, data: ArrayBuffer): boolean; | function sppWrite(clientSocket: number, data: ArrayBuffer): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts** and changed the return value to **void**.|
| bluetooth | function on(type: "sppRead", clientSocket: number, callback: Callback&lt;ArrayBuffer&gt;): void; | function on(type: "sppRead", clientSocket: number, callback: Callback&lt;ArrayBuffer&gt;): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | function off(type: "sppRead", clientSocket: number, callback?: Callback&lt;ArrayBuffer&gt;): void; | function off(type: "sppRead", clientSocket: number, callback?: Callback&lt;ArrayBuffer&gt;): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | function getProfile(profileId: ProfileId): A2dpSourceProfile | HandsFreeAudioGatewayProfile; | function getProfileInstance(profileId: ProfileId): A2dpSourceProfile |
| bluetooth | function getProfileInst(profileId: ProfileId): A2dpSourceProfile | HandsFreeAudioGatewayProfile | HidHostProfile |
| BaseProfile | getConnectionDevices(): Array&lt;string&gt;; | getConnectionDevices(): Array&lt;string&gt;; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| BaseProfile | getDeviceState(device: string): ProfileConnectionState; | getDeviceState(device: string): ProfileConnectionState; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| A2dpSourceProfile | connect(device: string): boolean; | connect(device: string): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts** and changed the return value to **void**.|
| A2dpSourceProfile | disconnect(device: string): boolean; | disconnect(device: string): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts** and changed the return value to **void**.|
| A2dpSourceProfile | on(type: "connectionStateChange", callback: Callback&lt;StateChangeParam&gt;): void; | on(type: "connectionStateChange", callback: Callback&lt;StateChangeParam&gt;): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| A2dpSourceProfile | off(type: "connectionStateChange", callback?: Callback&lt;StateChangeParam&gt;): void; | off(type: "connectionStateChange", callback?: Callback&lt;StateChangeParam&gt;): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| A2dpSourceProfile | getPlayingState(device: string): PlayingState; | getPlayingState(device: string): PlayingState; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| HandsFreeAudioGatewayProfile | connect(device: string): boolean; | connect(device: string): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts** and changed the return value to **void**.|
| HandsFreeAudioGatewayProfile | disconnect(device: string): boolean; | disconnect(device: string): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts** and changed the return value to **void**.|
| HandsFreeAudioGatewayProfile | on(type: "connectionStateChange", callback: Callback&lt;StateChangeParam&gt;): void; | on(type: "connectionStateChange", callback: Callback&lt;StateChangeParam&gt;): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| HandsFreeAudioGatewayProfile | off(type: "connectionStateChange", callback?: Callback&lt;StateChangeParam&gt;): void; | off(type: "connectionStateChange", callback?: Callback&lt;StateChangeParam&gt;): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| HidHostProfile | connect(device: string): boolean; | connect(device: string): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts** and changed the return value to **void**.|
| HidHostProfile | disconnect(device: string): boolean; | disconnect(device: string): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts** and changed the return value to **void**.|
| HidHostProfile | on(type: "connectionStateChange", callback: Callback&lt;StateChangeParam&gt;): void; | on(type: "connectionStateChange", callback: Callback&lt;StateChangeParam&gt;): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| HidHostProfile | off(type: "connectionStateChange", callback?: Callback&lt;StateChangeParam&gt;): void; | off(type: "connectionStateChange", callback?: Callback&lt;StateChangeParam&gt;): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| PanProfile | disconnect(device: string): boolean; | disconnect(device: string): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts** and changed the return value to **void**.|
| PanProfile | on(type: "connectionStateChange", callback: Callback&lt;StateChangeParam&gt;): void; | on(type: "connectionStateChange", callback: Callback&lt;StateChangeParam&gt;): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| PanProfile | off(type: "connectionStateChange", callback?: Callback&lt;StateChangeParam&gt;): void; | off(type: "connectionStateChange", callback?: Callback&lt;StateChangeParam&gt;): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| PanProfile | setTethering(enable: boolean): void; | setTethering(enable: boolean): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| PanProfile | isTetheringOn(): boolean; | isTetheringOn(): boolean; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| BLE | function createGattServer(): GattServer; | function createGattServer(): GattServer; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| BLE | function createGattClientDevice(deviceId: string): GattClientDevice; | function createGattClientDevice(deviceId: string): GattClientDevice; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| BLE | function getConnectedBLEDevices(): Array&lt;string&gt;; | function getConnectedBLEDevices(): Array&lt;string&gt;; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| BLE | function startBLEScan(filters: Array&lt;ScanFilter&gt;, options?: ScanOptions): void; | function startBLEScan(filters: Array&lt;ScanFilter&gt;, options?: ScanOptions): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts** and added the **ohos.permission.APPROXIMATELY_LOCATION** permission.|
| BLE | function stopBLEScan(): void; | function stopBLEScan(): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| BLE | mefunction on(type: "BLEDeviceFind", callback: Callback&lt;Array&lt;ScanResult&gt;&gt;): void;thod | function on(type: "BLEDeviceFind", callback: Callback&lt;Array&lt;ScanResult&gt;&gt;): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| BLE | function off(type: "BLEDeviceFind", callback?: Callback&lt;Array&lt;ScanResult&gt;&gt;): void; | function off(type: "BLEDeviceFind", callback?: Callback&lt;Array&lt;ScanResult&gt;&gt;): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| GattServer | startAdvertising(setting: AdvertiseSetting, advData: AdvertiseData, advResponse?: AdvertiseData): void; | startAdvertising(setting: AdvertiseSetting, advData: AdvertiseData, advResponse?: AdvertiseData): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| GattServer | stopAdvertising(): void; | stopAdvertising(): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| GattServer | addService(service: GattService): boolean; | addService(service: GattService): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts** and changed the return value to **void**.|
| GattServer | removeService(serviceUuid: string): boolean; | removeService(serviceUuid: string): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts** and changed the return value to **void**.|
| GattServer | close(): void; | close(): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**.
| GattServer | notifyCharacteristicChanged(deviceId: string, notifyCharacteristic: NotifyCharacteristic): boolean; | notifyCharacteristicChanged(deviceId: string, notifyCharacteristic: NotifyCharacteristic): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts** and changed the return value to **void**. |
| GattServer | sendResponse(serverResponse: ServerResponse): boolean; | sendResponse(serverResponse: ServerResponse): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts** and changed the return value to **void**. |
| GattServer | on(type: "characteristicRead", callback: Callback&lt;CharacteristicReadReq&gt;): void; | on(type: "characteristicRead", callback: Callback&lt;CharacteristicReadRequest&gt;): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| GattServer | off(type: "characteristicRead", callback?: Callback&lt;CharacteristicReadReq&gt;): void; | off(type: "characteristicRead", callback?: Callback&lt;CharacteristicReadRequest&gt;): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| GattServer | on(type: "characteristicWrite", callback: Callback&lt;CharacteristicWriteReq&gt;): void; | on(type: "characteristicWrite", callback: Callback&lt;CharacteristicWriteRequest&gt;): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| GattServer | off(type: "characteristicWrite", callback?: Callback&lt;CharacteristicWriteReq&gt;): void; | off(type: "characteristicWrite", callback?: Callback&lt;CharacteristicWriteRequest&gt;): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| GattServer | on(type: "descriptorRead", callback: Callback&lt;DescriptorReadReq&gt;): void; | on(type: "descriptorRead", callback: Callback&lt;DescriptorReadRequest&gt;): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| GattServer | off(type: "descriptorRead", callback?: Callback&lt;DescriptorReadReq&gt;): void; | off(type: "descriptorRead", callback?: Callback&lt;DescriptorReadRequest&gt;): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| GattServer | on(type: "descriptorWrite", callback: Callback&lt;DescriptorWriteReq&gt;): void; | on(type: "descriptorWrite", callback: Callback&lt;DescriptorWriteRequest&gt;): void;| Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| GattServer | off(type: "descriptorWrite", callback?: Callback&lt;DescriptorWriteReq&gt;): void; | off(type: "descriptorWrite", callback?: Callback&lt;DescriptorWriteRequest&gt;): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| GattServer | on(type: "connectStateChange", callback: Callback&lt;BLEConnectChangedState&gt;): void; | on(type: "connectStateChange", callback: Callback&lt;BLEConnectChangedState&gt;): void;| Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| GattServer | off(type: "connectStateChange", callback?: Callback&lt;BLEConnectChangedState&gt;): void; | off(type: "connectStateChange", callback?: Callback&lt;BLEConnectChangedState&gt;): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| GattClientDevice | connect(): boolean; | connect(): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts** and changed the return value to **void**. |
| GattClientDevice | disconnect(): boolean; | disconnect(): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts** and changed the return value to **void**. |
| GattClientDevice | close(): boolean; | close(): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts** and changed the return value to **void**. |
| GattClientDevice | getDeviceName(callback: AsyncCallback&lt;string&gt;): void; | getDeviceName(callback: AsyncCallback&lt;string&gt;): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| GattClientDevice | getDeviceName(): Promise&lt;string&gt;; | getDeviceName(): Promise&lt;string&gt;; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| GattClientDevice | getServices(callback: AsyncCallback&lt;Array&lt;GattService&gt;&gt;): void; | getServices(callback: AsyncCallback&lt;Array&lt;GattService&gt;&gt;): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| GattClientDevice | getServices(): Promise&lt;Array&lt;GattService&gt;&gt;; | getServices(): Promise&lt;Array&lt;GattService&gt;&gt;; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| GattClientDevice | readCharacteristicValue(characteristic: BLECharacteristic, callback: AsyncCallback&lt;BLECharacteristic&gt;): void; | readCharacteristicValue(characteristic: BLECharacteristic, callback: AsyncCallback&lt;BLECharacteristic&gt;): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| GattClientDevice | readCharacteristicValue(characteristic: BLECharacteristic): Promise&lt;BLECharacteristic&gt;; | readCharacteristicValue(characteristic: BLECharacteristic): Promise&lt;BLECharacteristic&gt;; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| GattClientDevice | readDescriptorValue(descriptor: BLEDescriptor, callback: AsyncCallback&lt;BLEDescriptor&gt;): void; | readDescriptorValue(descriptor: BLEDescriptor, callback: AsyncCallback&lt;BLEDescriptor&gt;): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| GattClientDevice | readDescriptorValue(descriptor: BLEDescriptor): Promise&lt;BLEDescriptor&gt;; | readDescriptorValue(descriptor: BLEDescriptor): Promise&lt;BLEDescriptor&gt;; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| GattClientDevice | writeCharacteristicValue(characteristic: BLECharacteristic): boolean; | writeCharacteristicValue(characteristic: BLECharacteristic): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts** and changed the return value to **void**. |
| GattClientDevice | writeDescriptorValue(descriptor: BLEDescriptor): boolean; | writeDescriptorValue(descriptor: BLEDescriptor): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts** and changed the return value to **void**. |
| GattClientDevice | getRssiValue(callback: AsyncCallback&lt;number&gt;): void; | getRssiValue(callback: AsyncCallback&lt;number&gt;): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| GattClientDevice | getRssiValue(): Promise&lt;number&gt;; | getRssiValue(): Promise&lt;number&gt;; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| GattClientDevice | setBLEMtuSize(mtu: number): boolean; | setBLEMtuSize(mtu: number): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts** and changed the return value to **void**. |
| GattClientDevice | setNotifyCharacteristicChanged(characteristic: BLECharacteristic, enable: boolean): boolean; | setNotifyCharacteristicChanged(characteristic: BLECharacteristic, enable: boolean): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts** and changed the return value to **void**. |
| GattClientDevice | on(type: "BLECharacteristicChange", callback: Callback&lt;BLECharacteristic&gt;): void; | on(type: "BLECharacteristicChange", callback: Callback&lt;BLECharacteristic&gt;): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| GattClientDevice | off(type: "BLECharacteristicChange", callback?: Callback&lt;BLECharacteristic&gt;): void; | off(type: "BLECharacteristicChange", callback?: Callback&lt;BLECharacteristic&gt;): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| GattClientDevice | on(type: "BLEConnectionStateChange", callback: Callback&lt;BLEConnectChangedState&gt;): void; | on(type: "BLEConnectionStateChange", callback: Callback&lt;BLEConnectChangedState&gt;): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| GattClientDevice | off(type: "BLEConnectionStateChange", callback?: Callback&lt;BLEConnectChangedState&gt;): void; | off(type: "BLEConnectionStateChange", callback?: Callback&lt;BLEConnectChangedState&gt;): void; | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | GattService | GattService | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | BLECharacteristic | BLECharacteristic | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | BLEDescriptor | BLEDescriptor | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | NotifyCharacteristic | NotifyCharacteristic | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | CharacteristicReadReq | CharacteristicReadRequest | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | CharacteristicWriteReq | CharacteristicWriteRequest | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | DescriptorReadRe | DescriptorReadRequest | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | DescriptorWriteReq | DescriptorWriteRequest | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | ServerResponse | ServerResponse | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | BLEConnectChangedState | BLEConnectChangedState | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | ScanResult | ScanResult | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | AdvertiseSetting | AdvertiseSetting | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | AdvertiseData | AdvertiseData | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | ManufactureData | ManufactureData | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | ServiceData | ServiceData | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | ScanFilter | ScanFilter | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | ScanOptions | ScanOptions | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | SppOption | SppOption | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | PinRequiredParam | PinRequiredParam | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | DeviceClass | DeviceClass | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | BondStateParam | BondStateParam | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | StateChangeParam | StateChangeParam | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | ScanDuty | ScanDuty | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | MatchMode | MatchMode | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | ProfileConnectionState | ProfileConnectionState | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | BluetoothState | BluetoothState | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | SppType | SppType | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | ScanMode | ScanMode | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | BondState | BondState | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | MajorClass | MajorClass | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | MajorMinorClass | MajorMinorClass | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | PlayingState | PlayingState | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
| bluetooth | ProfileId | ProfileId | Migrated this API in API version 9 to **@ohos.bluetoothManager.d.ts**. |
**(Optional) Adaptation Guide**
The following uses **enableLocation** as an example to show how it is called in the new version:
```ts
import bluetoothManager from '@ohos.bluetoothManager';
try {
var state = bluetoothManager.getState();
} catch (err) {
console.error("errCode:" + err.code + ",errMessage:" + err.message);
}
```
# Distributed Data Management Subsystem JS API Changelog
## cl.distributeddatamgr.1 API Change
Changed the **relationalStore** APIs of the distributed data management (distributeddatamgr) subsystem.
Before change:
After **getRdbStore()** is called, the application determines whether the RDB store is newly created based on the **openStatus** attribute (openStatus == ON_CREATE) of the returned **rdbStore** object.
After change:
After **getRdbStore()** is called, the application determines whether the RDB store is newly created based on the **version** attribute (version == 0) of the returned **rdbStore** object.
You need to adapt your application.
**Change Impact**
The JS APIs of API version 10 are affected and need to be changed accordingly. Otherwise, certain functions cannot be properly implemented in the SDK of the new version.
**Key API/Component Changes**
| Module | Class | Method/Attribute/Enum/Constant| Change Type|
| ------------------------------ | --------------- | ---------------- | ------- |
| @ohos.data.relationalStore | RdbStore | **openStatus: number;** is changed to **version: number;**.| Changed |
**Adaptation Guide**
Refer to the following code to set or obtain the RDB store version for an application:
```ts
const STORE_CONFIG = {
name: "rdbstore.db",
securityLevel: data_rdb.SecurityLevel.S1
}
data_rdb.getRdbStore(this.context, STORE_CONFIG, function (err, rdbStore) {
// Before:
// if (rdbStore.openStatus == ON_CREATE) {
// rdbStore.executeSql("CREATE TABLE IF NOT EXISTS student (id INTEGER PRIMARY KEY AUTOINCREMENT, score REAL);", null) // create table xxx
// }
// Now:
if (rdbStore.version == 0) {
rdbStore.executeSql("CREATE TABLE IF NOT EXISTS student (id INTEGER PRIMARY KEY AUTOINCREMENT, score REAL);", null) // create table xxx
// Set the RDB store version, which is a positive integer greater than 0.
rdbStore.version == 3
}
// Obtain the RDB store version.
console.info("Get RdbStore version is " + rdbStore.version)
})
```
# File Management Subsystem ChangeLog
## cl.filemanagement.1 Changed environment
The file management subsystem **d.ts** file has been archived and moved to the **file** directory. The **environment** module supports error code processing.
**Change Impacts**
If your application is developed based on earlier versions, note that the **d.ts** file storage location and the name of the module to be imported are changed. The **environment** module supports error code processing. See [adaptation instructions](../OpenHarmony_3.2.8.1/changelogs-filemanagement.md) for more details.
**Key API/Component Changes**
Before the change, **environment** was imported using **@ohos.environment**:
```js
import environment from '@ohos.environment';
```
But now, **environment** is imported using **@ohos.file.environment**:
```js
import environment from '@ohos.file.environment';
```
## cl.filemanagement.2 Changed securityLabel
The file management subsystem **d.ts** file has been archived and moved to the **file** directory. The **securityLabel** module supports error code processing.
**Change Impacts**
If your application is developed based on earlier versions, note that the **d.ts** file storage location and the name of the module to be imported are changed. The **securityLabel** module supports error code processing. See [adaptation instructions](../OpenHarmony_3.2.8.1/changelogs-filemanagement.md) for more details.
**Key API/Component Changes**
Before the change, **securityLabel** was imported using **@ohos.securityLabel**:
```js
import securityLabel from '@ohos.securityLabel';
```
But now, **securityLabel** is imported using **@ohos.file.securityLabel**:
```js
import securityLabel from '@ohos.file.securityLabel';
```
## cl.filemanagement.3 Changed fs
The **ino** attribute type of the **Stat** API under the **fs** module is changed.
**Change Impacts**
The **ino** attribute type is changed from number to BigInt, to adapt the inode range of all types of files in the file system.
**Key API/Component Changes**
The type of the **ino** attribute of the **Stat** API is changed from number to BigInt.
## cl.filemanagement.4 Changed fileAccess
The file management subsystem **d.ts** file has been archived and moved to the **file** directory. The **fileAccess** module supports error code processing.
**Change Impacts**
If your application is developed based on earlier versions, note that the **d.ts** file storage location and the name of the module to be imported are changed. The **fileAccess** module supports error code processing. See [adaptation instructions](../OpenHarmony_3.2.8.1/changelogs-filemanagement.md) for more details.
**Key API/Component Changes**
Before the change, **fileAccess** was imported using **@ohos.data.fileAccess**:
```js
import fileAccess from '@ohos.data.fileAccess';
```
But now, **fileAccess** is imported using **@ohos.file.fileAccess**:
```js
import fileAccess from '@ohos.file.fileAccess';
```
## cl.filemanagement.5 Changed fileExtensionInfo
The file management subsystem **d.ts** file has been archived and moved to the **file** directory. The **fileExtensionInfo** module supports error code processing.
**Change Impacts**
If your application is developed based on earlier versions, note that the **d.ts** file storage location and the name of the module to be imported are changed. The **fileExtensionInfo** module supports error code processing. See [adaptation instructions](../OpenHarmony_3.2.8.1/changelogs-filemanagement.md) for more details.
**Key API/Component Changes**
Before the change, **fileExtensionInfo** was imported using **@ohos.fileExtensionInfo**:
```js
import fileExtensionInfo from '@ohos.fileExtensionInfo';
```
But now, **fileExtensionInfo** is imported using **@ohos.file.fileExtensionInfo**:
```js
import fileExtensionInfo from '@ohos.file.fileExtensionInfo';
```
## cl.filemanagement.6 Changed storageStatistics
The file management subsystem **d.ts** file has been archived and moved to the **file** directory. The **fileExtensionInfo** module supports error code processing.
**Change Impacts**
If your application is developed based on earlier versions, note that the **d.ts** file storage location and the name of the module to be imported are changed. The **storageStatistics** module supports error code processing. See [adaptation instructions](../OpenHarmony_3.2.8.1/changelogs-filemanagement.md) for more details.
**Key API/Component Changes**
Before the change, **storageStatistics** was imported using **@ohos.storageStatistics**:
```js
import storageStatistics from '@ohos.storageStatistics';
```
But now, **storageStatistics** is imported using **@ohos.file.storageStatistics**:
```js
import storageStatistics from '@ohos.file.storageStatistics';
```
## cl.filemanagement.7 Changed volumeManager
The file management subsystem **d.ts** file has been archived moved to the **file** directory. The **volumeManager** module supports error code processing.
**Change Impacts**
If your application is developed based on earlier versions, note that the **d.ts** file storage location and the name of the module to be imported are changed. The **volumeManager** module supports error code processing. See [adaptation instructions](../OpenHarmony_3.2.8.1/changelogs-filemanagement.md) for more details.
**Key API/Component Changes**
Before the change, **volumeManager** was imported using **@ohos.volumeManager**:
```js
import volumeManager from '@ohos.volumeManager';
```
But now, **volumeManager** is imported using **@ohos.file.volumeManager**:
```js
import volumeManager from '@ohos.file.volumeManager';
```
# Globalization Subsystem ChangeLog
## cl.global.1 Runtime Authentication Added for System APIs
The internationalization component of the globalization subsystem adds runtime authentication for system APIs in certain scenarios. The following changes are made in API version 9 and later:
- Setting the system language, country or region, and area
- Setting the 24-hour format of the system
- Adding and removing the preferred language
- Setting localized numbers
You need to adapt your application based on the following information.
**Change Impacts**
APIs involved in the preceding scenarios can be properly called only by system applications that have the **UPDATE_CONFIGURATION** permission.
**Key API/Component Changes**
- Involved APIs:
- setSystemLanguage(language: string): void;
- setSystemRegion(region: string): void;
- setSystemLocale(locale: string): void;
- set24HourClock(option: boolean): void;
- addPreferredLanguage(language: string, index?: number): void;
- removePreferredLanguage(index: number): void;
- setUsingLocalDigit(flag: boolean): void;
**Adaptation Guide**
Make sure the application trying to call any of the above APIs is a system application. Non-system applications are not allowed to call the APIs.
An exception will be thrown upon lack of a necessary permission or a call request from a non-system application. The exception can be captured via **try-catch**.
```js
import I18n from '@ohos.i18n'
try {
I18n.System.setSystemLanguage('zh');
} catch(error) {
console.error(`call System.setSystemLanguage failed, error code: ${error.code}, message: ${error.message}.`)
}
```
# Media Subsystem ChangeLog
## cl.media.1 API Change of the Playback Function
Added the [AVPlayer](../../../application-dev/reference/apis/js-apis-media.md#avplayer9)<sup>9+</sup> API for audio and video playback, with the updated state machine and error codes, which is recommended. The following APIs for audio playback and video playback are no longer maintained: [AudioPlayer](../../../application-dev/reference/apis/js-apis-media.md#audioplayer)<sup>6+</sup> and [VideoPlayer](../../../application-dev/reference/apis/js-apis-media.md#videoplayer)<sup>8+</sup>.
**Change Impacts**
The original APIs can still be used but are no longer maintained. You are advised to use the new API instead.
**Key API/Component Changes**
Added APIs
| Class | Declaration |
| -------------- | ------------------------------------------------------------ |
| media | createAVPlayer(callback: AsyncCallback\<AVPlayer>): void |
| media | createAVPlayer() : Promise\<AVPlayer> |
| media.AVPlayer | interface AVPlayer |
| media.AVPlayer | videoScaleType ?: VideoScaleType |
| media.AVPlayer | url ?: string |
| media.AVPlayer | surfaceId ?: string |
| media.AVPlayer | stop(callback: AsyncCallback\<void>): void |
| media.AVPlayer | stop(): Promise\<void> |
| media.AVPlayer | setVolume(volume: number): void |
| media.AVPlayer | setSpeed(speed: PlaybackSpeed): void |
| media.AVPlayer | setBitrate(bitrate: number): void |
| media.AVPlayer | seek(timeMs: number, mode?:SeekMode): void |
| media.AVPlayer | reset(callback: AsyncCallback\<void>): void |
| media.AVPlayer | reset(): Promise\<void> |
| media.AVPlayer | release(callback: AsyncCallback\<void>): void |
| media.AVPlayer | release(): Promise\<void> |
| media.AVPlayer | readonly width: number |
| media.AVPlayer | readonly state: AVPlayerState |
| media.AVPlayer | readonly height: number |
| media.AVPlayer | readonly duration: number |
| media.AVPlayer | readonly currentTime: number |
| media.AVPlayer | prepare(callback: AsyncCallback\<void>): void |
| media.AVPlayer | prepare(): Promise\<void> |
| media.AVPlayer | play(callback: AsyncCallback\<void>): void |
| media.AVPlayer | play(): Promise\<void> |
| media.AVPlayer | pause(callback: AsyncCallback\<void>): void |
| media.AVPlayer | pause(): Promise\<void> |
| media.AVPlayer | on(type: 'volumeChange', callback: Callback\<number>): void |
| media.AVPlayer | on(type: 'videoSizeChange', callback: (width: number, height: number) => void): void |
| media.AVPlayer | on(type: 'timeUpdate', callback: Callback\<number>): void |
| media.AVPlayer | on(type: 'stateChange', callback: (state: AVPlayerState, reason: StateChangeReason) => void): void |
| media.AVPlayer | on(type: 'startRenderFrame', callback: Callback\<void>): void |
| media.AVPlayer | on(type: 'speedDone', callback: Callback\<number>): void |
| media.AVPlayer | on(type: 'seekDone', callback: Callback\<number>): void |
| media.AVPlayer | on(type: 'error', callback: ErrorCallback): void |
| media.AVPlayer | on(type: 'endOfStream', callback: Callback\<void>): void |
| media.AVPlayer | on(type: 'durationUpdate', callback: Callback\<number>): void |
| media.AVPlayer | on(type: 'bufferingUpdate', callback: (infoType: BufferingInfoType, value: number) => void): void |
| media.AVPlayer | on(type: 'bitrateDone', callback: Callback\<number>): void |
| media.AVPlayer | on(type: 'availableBitrates', callback: (bitrates: Array\<number>) => void): void |
| media.AVPlayer | on(type: 'audioInterrupt', callback: (info: audio.InterruptEvent) => void): void |
| media.AVPlayer | off(type: 'volumeChange'): void |
| media.AVPlayer | off(type: 'videoSizeChange'): void |
| media.AVPlayer | off(type: 'timeUpdate'): void |
| media.AVPlayer | off(type: 'stateChange'): void |
| media.AVPlayer | off(type: 'startRenderFrame'): void |
| media.AVPlayer | off(type: 'speedDone'): void |
| media.AVPlayer | off(type: 'seekDone'): void |
| media.AVPlayer | off(type: 'error'): void |
| media.AVPlayer | off(type: 'endOfStream'): void |
| media.AVPlayer | off(type: 'durationUpdate'): void |
| media.AVPlayer | off(type: 'bufferingUpdate'): void |
| media.AVPlayer | off(type: 'bitrateDone'): void |
| media.AVPlayer | off(type: 'availableBitrates'): void |
| media.AVPlayer | off(type: 'audioInterrupt'): void |
| media.AVPlayer | loop: boolean |
| media.AVPlayer | getTrackDescription(callback: AsyncCallback\<Array\<MediaDescription>>): void |
| media.AVPlayer | getTrackDescription() : Promise\<Array\<MediaDescription>> |
| media.AVPlayer | fdSrc ?: AVFileDescriptor |
| media.AVPlayer | audioInterruptMode ?: audio.InterruptMode |
| unnamed | type AVPlayerState = 'idle' \| 'initialized' \| 'prepared' \| 'playing' \| 'paused' \| 'completed' \| 'stopped' \| 'released' \| 'error' |
APIs no longer maintained
| Class | Declaration |
| ----------------- | ------------------------------------------------------------ |
| media | createVideoPlayer(callback: AsyncCallback\<VideoPlayer>): void |
| media | createVideoPlayer() : Promise\<VideoPlayer> |
| media | createAudioPlayer(): AudioPlayer |
| media.AudioPlayer | interface AudioPlayer |
| media.AudioPlayer | play(): void |
| media.AudioPlayer | release(): void |
| media.AudioPlayer | audioInterruptMode ?: audio.InterruptMode |
| media.AudioPlayer | fdSrc: AVFileDescriptor |
| media.AudioPlayer | seek(timeMs: number): void |
| media.AudioPlayer | readonly duration: number |
| media.AudioPlayer | loop: boolean |
| media.AudioPlayer | readonly state: AudioState |
| media.AudioPlayer | getTrackDescription(callback: AsyncCallback\<Array\<MediaDescription>>): void |
| media.AudioPlayer | getTrackDescription() : Promise\<Array\<MediaDescription>> |
| media.AudioPlayer | on(type: 'bufferingUpdate', callback: (infoType: BufferingInfoType, value: number) => void): void |
| media.AudioPlayer | on(type: 'play' \| 'pause' \| 'stop' \| 'reset' \| 'dataLoad' \| 'finish' \| 'volumeChange', callback: () => void): void |
| media.AudioPlayer | on(type: 'timeUpdate', callback: Callback\<number>): void |
| media.AudioPlayer | on(type: 'audioInterrupt', callback: (info: audio.InterruptEvent) => void): void |
| media.AudioPlayer | on(type: 'error', callback: ErrorCallback): void |
| media.AudioPlayer | setVolume(vol: number): void |
| media.AudioPlayer | pause(): void |
| media.AudioPlayer | readonly currentTime: number |
| media.AudioPlayer | stop(): void |
| media.AudioPlayer | reset(): void |
| media.AudioPlayer | src: string |
| media.VideoPlayer | interface VideoPlayer |
| media.VideoPlayer | play(callback: AsyncCallback\<void>): void |
| media.VideoPlayer | play(): Promise\<void> |
| media.VideoPlayer | prepare(callback: AsyncCallback\<void>): void |
| media.VideoPlayer | prepare(): Promise\<void> |
| media.VideoPlayer | release(callback: AsyncCallback\<void>): void |
| media.VideoPlayer | release(): Promise\<void> |
| media.VideoPlayer | audioInterruptMode ?: audio.InterruptMode |
| media.VideoPlayer | fdSrc: AVFileDescriptor |
| media.VideoPlayer | seek(timeMs: number, callback: AsyncCallback\<number>): void |
| media.VideoPlayer | seek(timeMs: number, mode:SeekMode, callback: AsyncCallback\<number>): void |
| media.VideoPlayer | seek(timeMs: number, mode?:SeekMode): Promise\<number> |
| media.VideoPlayer | readonly duration: number |
| media.VideoPlayer | loop: boolean |
| media.VideoPlayer | videoScaleType ?: VideoScaleType |
| media.VideoPlayer | readonly state: VideoPlayState |
| media.VideoPlayer | getTrackDescription(callback: AsyncCallback\<Array\<MediaDescription>>): void |
| media.VideoPlayer | getTrackDescription() : Promise\<Array\<MediaDescription>> |
| media.VideoPlayer | readonly height: number |
| media.VideoPlayer | on(type: 'playbackCompleted', callback: Callback\<void>): void |
| media.VideoPlayer | on(type: 'bufferingUpdate', callback: (infoType: BufferingInfoType, value: number) => void): void |
| media.VideoPlayer | on(type: 'startRenderFrame', callback: Callback\<void>): void |
| media.VideoPlayer | on(type: 'videoSizeChanged', callback: (width: number, height: number) => void): void |
| media.VideoPlayer | on(type: 'audioInterrupt', callback: (info: audio.InterruptEvent) => void): void |
| media.VideoPlayer | on(type: 'error', callback: ErrorCallback): void |
| media.VideoPlayer | setDisplaySurface(surfaceId: string, callback: AsyncCallback\<void>): void |
| media.VideoPlayer | setDisplaySurface(surfaceId: string): Promise\<void> |
| media.VideoPlayer | setVolume(vol: number, callback: AsyncCallback\<void>): void |
| media.VideoPlayer | setVolume(vol: number): Promise\<void> |
| media.VideoPlayer | url: string |
| media.VideoPlayer | pause(callback: AsyncCallback\<void>): void |
| media.VideoPlayer | pause(): Promise\<void> |
| media.VideoPlayer | readonly currentTime: number |
| media.VideoPlayer | setSpeed(speed:number, callback: AsyncCallback\<number>): void |
| media.VideoPlayer | setSpeed(speed:number): Promise\<number> |
| media.VideoPlayer | stop(callback: AsyncCallback\<void>): void |
| media.VideoPlayer | stop(): Promise\<void> |
| media.VideoPlayer | readonly width: number |
| media.VideoPlayer | reset(callback: AsyncCallback\<void>): void |
| media.VideoPlayer | reset(): Promise\<void> |
| unnamed | type AudioState = 'idle' \| 'playing' \| 'paused' \| 'stopped' \| 'error' |
| unnamed | type VideoPlayState = 'idle' \| 'prepared' \| 'playing' \| 'paused' \| 'stopped' \| 'error' |
**Adaptation Guide**
For details, see the [reference](../../../application-dev/reference/apis/js-apis-media.md) for each API.
## cl.media.2 API Change of the Recording Function
Added the [AVRecorder](../../../application-dev/reference/apis/js-apis-media.md#avrecorder9)<sup>9+</sup> API for audio and video recording, with the updated state machine and error codes, which is recommended. The following APIs for audio recording and video recording are no longer maintained: [AudioRecorder](../../../application-dev/reference/apis/js-apis-media.md#audiorecorder)<sup>6+</sup> and [VideoRecorder](../../../application-dev/reference/apis/js-apis-media.md#videorecorder9)<sup>9+</sup>.
The [AudioSourceType](../../../application-dev/reference/apis/js-apis-media.md#audiosourcetype9) and [VideoSourceType](../../../application-dev/reference/apis/js-apis-media.md#videosourcetype9) APIs shared by the old and new recording APIs are changed to non-system APIs.
**Change Impacts**
The [AudioRecorder](../../../application-dev/reference/apis/js-apis-media.md#audiorecorder)<sup>6+</sup> and [VideoRecorder](../../../application-dev/reference/apis/js-apis-media.md#videorecorder9)<sup>9+</sup> APIs can still be used but are no longer maintained. You are advised to use the [AVRecorder](../../../application-dev/reference/apis/js-apis-media.md#avrecorder9)<sup>9+</sup> API instead.
**Key API/Component Changes**
Added APIs
| Class | Declaration |
| ----------------------- | ------------------------------------------------------------ |
| media | createAVRecorder(callback: AsyncCallback\<AVRecorder>): void |
| media | createAVRecorder() : Promise\<AVRecorder> |
| media.AVRecorder | interface AVRecorder |
| media.AVRecorder | prepare(config: AVRecorderConfig, callback: AsyncCallback\<void>): void |
| media.AVRecorder | prepare(config: AVRecorderConfig): Promise\<void> |
| media.AVRecorder | release(callback: AsyncCallback\<void>): void |
| media.AVRecorder | release(): Promise\<void> |
| media.AVRecorder | readonly state: AVRecorderState |
| media.AVRecorder | on(type: 'stateChange', callback: (state: AVRecorderState, reason: StateChangeReason) => void): void |
| media.AVRecorder | on(type: 'error', callback: ErrorCallback): void |
| media.AVRecorder | resume(callback: AsyncCallback\<void>): void |
| media.AVRecorder | resume(): Promise\<void> |
| media.AVRecorder | start(callback: AsyncCallback\<void>): void |
| media.AVRecorder | start(): Promise\<void> |
| media.AVRecorder | off(type: 'stateChange'): void |
| media.AVRecorder | off(type: 'error'): void |
| media.AVRecorder | pause(callback: AsyncCallback\<void>): void |
| media.AVRecorder | pause(): Promise\<void> |
| media.AVRecorder | stop(callback: AsyncCallback\<void>): void |
| media.AVRecorder | stop(): Promise\<void> |
| media.AVRecorder | reset(callback: AsyncCallback\<void>): void |
| media.AVRecorder | reset(): Promise\<void> |
| media.AVRecorder | getInputSurface(callback: AsyncCallback\<string>): void |
| media.AVRecorder | getInputSurface(): Promise\<string> |
| media.AVRecorderConfig | videoSourceType?: VideoSourceType |
| media.AVRecorderConfig | audioSourceType?: AudioSourceType |
| media.AVRecorderConfig | profile: AVRecorderProfile |
| media.AVRecorderConfig | rotation?: number |
| media.AVRecorderConfig | url: string |
| media.AVRecorderConfig | location?: Location |
| media.AVRecorderConfig | interface AVRecorderConfig |
| media.AVRecorderProfile | videoBitrate?: number |
| media.AVRecorderProfile | videoCodec?: CodecMimeType |
| media.AVRecorderProfile | audioCodec?: CodecMimeType |
| media.AVRecorderProfile | videoFrameRate?: number |
| media.AVRecorderProfile | videoFrameHeight?: number |
| media.AVRecorderProfile | audioSampleRate?: number |
| media.AVRecorderProfile | audioBitrate?: number |
| media.AVRecorderProfile | videoFrameWidth?: number |
| media.AVRecorderProfile | audioChannels?: number |
| media.AVRecorderProfile | fileFormat: ContainerFormatType |
| media.AVRecorderProfile | interface AVRecorderProfile |
| unnamed | type AVRecorderState = 'idle' \| 'prepared' \| 'started' \| 'paused' \| 'stopped' \| 'released' \| 'error' |
APIs no longer maintained
| Class | Declaration |
| -------------------------- | ------------------------------------------------------------ |
| media | createVideoRecorder(callback: AsyncCallback\<VideoRecorder>): void |
| media | createVideoRecorder(): Promise\<VideoRecorder> |
| media | createAudioRecorder(): AudioRecorder |
| media.AudioRecorder | interface AudioRecorder |
| media.AudioRecorder | prepare(config: AudioRecorderConfig): void |
| media.AudioRecorder | release(): void |
| media.AudioRecorder | on(type: 'prepare' \| 'start' \| 'pause' \| 'resume' \| 'stop' \| 'release' \| 'reset', callback: () => void): void |
| media.AudioRecorder | on(type: 'error', callback: ErrorCallback): void |
| media.AudioRecorder | resume(): void |
| media.AudioRecorder | start(): void |
| media.AudioRecorder | pause(): void |
| media.AudioRecorder | stop(): void |
| media.AudioRecorder | reset(): void |
| media.AudioRecorderConfig | audioSampleRate?: number |
| media.AudioRecorderConfig | location?: Location |
| media.AudioRecorderConfig | fileFormat?: ContainerFormatType |
| media.AudioRecorderConfig | interface AudioRecorderConfig |
| media.AudioRecorderConfig | audioEncoder?: AudioEncoder |
| media.AudioRecorderConfig | audioEncodeBitRate?: number |
| media.AudioRecorderConfig | numberOfChannels?: number |
| media.AudioRecorderConfig | format?: AudioOutputFormat |
| media.AudioRecorderConfig | uri: string |
| media.AudioRecorderConfig | audioEncoderMime?: CodecMimeType |
| media.VideoRecorder | interface VideoRecorder |
| media.VideoRecorder | prepare(config: VideoRecorderConfig, callback: AsyncCallback\<void>): void |
| media.VideoRecorder | prepare(config: VideoRecorderConfig): Promise\<void> |
| media.VideoRecorder | release(callback: AsyncCallback\<void>): void |
| media.VideoRecorder | release(): Promise\<void> |
| media.VideoRecorder | readonly state: VideoRecordState |
| media.VideoRecorder | on(type: 'error', callback: ErrorCallback): void |
| media.VideoRecorder | resume(callback: AsyncCallback\<void>): void |
| media.VideoRecorder | resume(): Promise\<void> |
| media.VideoRecorder | start(callback: AsyncCallback\<void>): void |
| media.VideoRecorder | start(): Promise\<void> |
| media.VideoRecorder | pause(callback: AsyncCallback\<void>): void |
| media.VideoRecorder | pause(): Promise\<void> |
| media.VideoRecorder | stop(callback: AsyncCallback\<void>): void |
| media.VideoRecorder | stop(): Promise\<void> |
| media.VideoRecorder | reset(callback: AsyncCallback\<void>): void |
| media.VideoRecorder | reset(): Promise\<void> |
| media.VideoRecorder | getInputSurface(callback: AsyncCallback\<string>): void |
| media.VideoRecorder | getInputSurface(): Promise\<string> |
| media.VideoRecorderConfig | videoSourceType: VideoSourceType |
| media.VideoRecorderConfig | audioSourceType?: AudioSourceType |
| media.VideoRecorderConfig | profile: VideoRecorderProfile |
| media.VideoRecorderConfig | rotation?: number |
| media.VideoRecorderConfig | url: string |
| media.VideoRecorderConfig | location?: Location |
| media.VideoRecorderConfig | interface VideoRecorderConfig |
| media.VideoRecorderProfile | readonly videoBitrate: number |
| media.VideoRecorderProfile | readonly videoCodec: CodecMimeType |
| media.VideoRecorderProfile | readonly audioCodec: CodecMimeType |
| media.VideoRecorderProfile | readonly videoFrameRate: number |
| media.VideoRecorderProfile | readonly videoFrameHeight: number |
| media.VideoRecorderProfile | readonly audioSampleRate: number |
| media.VideoRecorderProfile | readonly audioBitrate: number |
| media.VideoRecorderProfile | readonly videoFrameWidth: number |
| media.VideoRecorderProfile | readonly audioChannels: number |
| media.VideoRecorderProfile | readonly fileFormat: ContainerFormatType |
| media.VideoRecorderProfile | interface VideoRecorderProfile |
| unnamed | type VideoRecordState = 'idle' \| 'prepared' \| 'playing' \| 'paused' \| 'stopped' \| 'error' |
Changed APIs
| Class | Declaration | Capability Before Change | Capability After Change | Whether a System API Before Change| Whether a System API After Change|
| --------------------- | ------------------------------------------------------------ | ----------------------------------------------- | -------------------------------------------- | -------------------- | -------------------- |
| media.AudioSourceType | enum AudioSourceType { /** * default audio source type. * @since 9 * @syscap SystemCapability.Multimedia.Media.AVRecorder */ AUDIO_SOURCE_TYPE_DEFAULT = 0, /** * source type mic. * @since 9 * @syscap SystemCapability.Multimedia.Media.AVRecorder */ AUDIO_SOURCE_TYPE_MIC = 1, } | SystemCapability.Multimedia.Media.VideoRecorder | SystemCapability.Multimedia.Media.AVRecorder | Yes | No |
| media.VideoSourceType | enum VideoSourceType { /** * surface raw data. * @since 9 * @syscap SystemCapability.Multimedia.Media.AVRecorder */ VIDEO_SOURCE_TYPE_SURFACE_YUV = 0, /** * surface ES data. * @since 9 * @syscap SystemCapability.Multimedia.Media.AVRecorder */ VIDEO_SOURCE_TYPE_SURFACE_ES = 1, } | SystemCapability.Multimedia.Media.VideoRecorder | SystemCapability.Multimedia.Media.AVRecorder | Yes | No |
**Adaptation Guide**
For details, see the [reference](../../../application-dev/reference/apis/js-apis-media.md) for each API.
## cl.media.3 Error Code Change
Added the standard error code enumeration type [AVErrorCode9](../../../application-dev/reference/apis/js-apis-media.md#averrorcode)<sup>9+</sup> that replaces the original error code enumeration type [MediaErrorCode](../../../application-dev/reference/apis/js-apis-media.md#mediaerrorcode)<sup>8+</sup>.
**Change Impacts**
The error code enumeration type [MediaErrorCode](../../../application-dev/reference/apis/js-apis-media.md#mediaerrorcode)<sup>8+</sup> is still used for original APIs. [AVErrorCode9](../../../application-dev/reference/apis/js-apis-media.md#averrorcode)<sup>9+</sup> is used for newly added APIs.
**Key API/Component Changes**
Added API
| Class | Declaration |
| ----------------- | ------------------------------------------------------------ |
| media.AVErrorCode | enum AVErrorCode { /** * operation success. * @since 9 * @syscap SystemCapability.Multimedia.Media.Core */ AVERR_OK = 0, /** * permission denied. * @since 9 * @syscap SystemCapability.Multimedia.Media.Core */ AVERR_NO_PERMISSION = 201, /** * invalid parameter. * @since 9 * @syscap SystemCapability.Multimedia.Media.Core */ AVERR_INVALID_PARAMETER = 401, /** * the api is not supported in the current version * @since 9 * @syscap SystemCapability.Multimedia.Media.Core */ AVERR_UNSUPPORT_CAPABILITY = 801, /** * the system memory is insufficient or the number of services reaches the upper limit * @since 9 * @syscap SystemCapability.Multimedia.Media.Core */ AVERR_NO_MEMORY = 5400101, /** * current status does not allow or do not have permission to perform this operation * @since 9 * @syscap SystemCapability.Multimedia.Media.Core */ AVERR_OPERATE_NOT_PERMIT = 5400102, /** * data flow exception information * @since 9 * @syscap SystemCapability.Multimedia.Media.Core */ AVERR_IO = 5400103, /** * system or network response timeout. * @since 9 * @syscap SystemCapability.Multimedia.Media.Core */ AVERR_TIMEOUT = 5400104, /** * service process died. * @since 9 * @syscap SystemCapability.Multimedia.Media.Core */ AVERR_SERVICE_DIED = 5400105, /** * unsupported media format * @since 9 * @syscap SystemCapability.Multimedia.Media.Core */ AVERR_UNSUPPORT_FORMAT = 5400106, } |
API no longer maintained
| Class | Declaration |
| -------------------- | ------------------------------------------------------------ |
| media.MediaErrorCode | enum MediaErrorCode { /** * operation success. * @since 8 * @syscap SystemCapability.Multimedia.Media.Core */ MSERR_OK = 0, /** * malloc or new memory failed. maybe system have no memory. * @since 8 * @syscap SystemCapability.Multimedia.Media.Core */ MSERR_NO_MEMORY = 1, /** * no permission for the operation. * @since 8 * @syscap SystemCapability.Multimedia.Media.Core */ MSERR_OPERATION_NOT_PERMIT = 2, /** * invalid argument. * @since 8 * @syscap SystemCapability.Multimedia.Media.Core */ MSERR_INVALID_VAL = 3, /** * an I/O error occurred. * @since 8 * @syscap SystemCapability.Multimedia.Media.Core */ MSERR_IO = 4, /** * operation time out. * @since 8 * @syscap SystemCapability.Multimedia.Media.Core */ MSERR_TIMEOUT = 5, /** * unknown error. * @since 8 * @syscap SystemCapability.Multimedia.Media.Core */ MSERR_UNKNOWN = 6, /** * media service died. * @since 8 * @syscap SystemCapability.Multimedia.Media.Core */ MSERR_SERVICE_DIED = 7, /** * operation is not permit in current state. * @since 8 * @syscap SystemCapability.Multimedia.Media.Core */ MSERR_INVALID_STATE = 8, /** * operation is not supported in current version. * @since 8 * @syscap SystemCapability.Multimedia.Media.Core */ MSERR_UNSUPPORTED = 9, } |
<!--no_check-->
\ No newline at end of file
# Test Subsystem ChangeLog
## cl.testfwk_arkxtest.1 API Name Change of Rect
The definition of **Rect**, an enumeration type that indicates the component bound information, is changed since version 4.0.2.1.
## Change Impacts
This change affects the **Rect** API provided by **@ohos.uitest**. If you have used the **Rect** API of **@ohos.uitest-api9** during test case development, adaptation is required so that the compilation can be successful in the SDK environment of the new version.
## Key API/Component Changes
### Rect<sup>9+</sup>
Before change
| Name | Value | Description |
| ------- | ---- | ------------------------- |
| leftX | 1 | X-coordinate of the upper left corner of the component bounds.|
| topY | 2 | Y-coordinate of the upper left corner of the component bounds.|
| rightX | 3 | X-coordinate of the lower right corner of the component bounds.|
| bottomY | 4 | Y-coordinate of the lower right corner of the component bounds.|
After change
| Name | Value | Description |
| ------ | ---- | ------------------------- |
| left | 1 | X-coordinate of the upper left corner of the component bounds.|
| top | 2 | Y-coordinate of the upper left corner of the component bounds.|
| right | 3 | X-coordinate of the lower right corner of the component bounds.|
| bottom | 4 | Y-coordinate of the lower right corner of the component bounds.|
## Adaptation Guide
### Adaptation to the API Name Change
You can replace the class name according to the following rules:
- `leftX-->left`
- `topY-->top`
- `rightX-->right`
- `bottomY-->bottom`
# USB Subsystem API Changelog
## cl.usb_manager.1 System API Change
Runtime authentication is performed for system APIs of the USB manager. An asynchronous API throws an error code via **Promise.reject**.
If your application is developed based on earlier versions, modify the return values of functions. Otherwise, the original service logic will be affected.
**Key API/Component Changes**
| Bundle Name | Original API | New API |
| --------------- | ------------------------------------------------------------ | ------------------------------------------------------------ |
| ohos.usbV9.d.ts | function setCurrentFunctions(funcs: FunctionType): Promise<boolean>; | function setCurrentFunctions(funcs: FunctionType): Promise<void>; |
| ohos.usbV9.d.ts | function setPortRoles(portId: number, powerRole: PowerRoleType, dataRole: DataRoleType): Promise<boolean>; | function setPortRoles(portId: number, powerRole: PowerRoleType, dataRole: DataRoleType): Promise<void>; |
## cl.usb_manager.2 SDK API Deletion
The **@ohos.usbV9.d.ts** file was deleted in OpenHarmony 4.0.5.5.
You need to import **@ohos.usbManager** to use USB service APIs.
```ts
import usbManager from '@ohos.usbManager';
```
**Adaptation Guide**
For details about usage of each API, see the [API Reference](../../../application-dev/reference/apis/js-apis-usbManager.md).
# Web Subsystem Changelog
Compared with earlier versions, OpenHarmony 4.0.2.2 has the following API changes in its web subsystem:
## cl.web.1 Removal of webDebuggingAccess
The definition of the **webDebuggingAccess** API is inappropriate. This API should take effect for all **Web** instances. In light of this, it is removed and replaced by the new API **setWebDebuggingAccess**.
**Change Impacts**
This API must be deprecated and replaced with the **setWebDebuggingAccess** API.
**Key API/Component Changes**
| Class| API Type| Declaration| Change Type|
| -- | -- | -- | -- |
|WebAttribute | method | webDebugggingAccess(webDebugggingAccess: boolean): WebAttribute| Deleted |
**Adaptation Guide**
Use the new API **setWebDebuggingAccess**.
## cl.web.2 Adding of setWebDebuggingAccess
Added the static API **setWebDebuggingAccess** to **WebviewController**. It sets whether to enable web debugging works for all **Web** instances.
**Change Impacts**
The original **webDebugggingAccess** API must be replaced with the new API in the application.
**Key API/Component Changes**
| Class| API Type| Declaration| Change Type|
| -- | -- | -- | -- |
|webview.WebviewController | method | static setWebDebugggingAccess(webDebugggingAccess: boolean): void| Added|
**Adaptation Guide**
The following exemplifies how to enable web debugging:
```ts
// xxx.ets
import web_webview from '@ohos.web.webview';
@Entry
@Component
struct WebComponent {
controller: web_webview.WebviewController = new web_webview.WebviewController();
aboutToAppear():void {
try {
web_webview.WebviewController.setWebDebuggingAccess(true);
} catch(error) {
console.error(`ErrorCode: ${error.code}, Message: ${error.message}`);
}
}
build() {
Column() {
Web({ src: 'www.example.com', controller: this.controller })
}
}
}
# Bundle Management Subsystem Changelog
## cl.bundlemanager.1 Changed Underlying Capability by Not Decompressing the HAP During HAP Installation
The HAP will no longer be decompressed during installation. After the installation is complete, only the HAP file exists in the installation directory. As a result, the application must use the standard resource management interface, rather than a combined path, to access a resource file.
**Change Impact**<br>
If the application uses a combined path to access a resource file, the access fails. It must use the resource management interface.
**Key API/Component Changes**<br>
No API or component change is involved.
**Adaptation Guide**<br>
The resource management subsystem provides the JS interface for accessing resource files. Reference: [Accessing Resource Files](../../../application-dev/reference/apis/js-apis-resource-manager.md#getrawfilecontent9)
# Globalization Subsystem Changelog
## cl.resourceManager.1 Change in the Meaning of the Return Value for the API Used to Obtain the rawfile Descriptor
Changed the meaning of the return value for the API used to obtain the rawfile descriptor after the non-decompression feature is added in this version. The change in the meaning of the return value, namely, **descriptor: RawFileDescriptor {fd, offset, length}**, is described as follows:
**Before change:**
**fd**: file descriptor for accessing the rawfile.
**offset**: offset for accessing the rawfile. In this case, the value is **0**.
**length**: size of the rawfile to access.
**After change:**
**fd**: file descriptor for accessing the HAP where the rawfile is located.
**offset**: offset of the accessed rawfile relative to the HAP.
**length**: size of the rawfile to access.
**Change Impact**
In versions earlier than 4.0.2.2, the rawfile can be accessed only through **fd**. In version 4.0.2.2 or later, the rawfile can be accessed only through **{fd, offset, and length}**.
**Key API/Component Changes**
| **Original API** |
| ---------------- |
| getRawFd(path: string, callback: AsyncCallback\<RawFileDescriptor>): void |
| getRawFd(path: string): Promise\<RawFileDescriptor> |
| getRawFileDescriptor(path: string, callback: AsyncCallback\<RawFileDescriptor>): void|
| getRawFileDescriptor(path: string): Promise\<RawFileDescriptor>|
||
**Sample Code**
The following is an example of calling the **getRawFd** API:
```
try {
this.context.resourceManager.getRawFd("test.ogg", (error, value) => {
if (error != null) {
console.log(`callback getRawFd failed error code: ${error.code}, message: ${error.message}.`);
} else {
let fileDescriptor = {
fd = value.fd,
offset = value.offset,
length = value.length
}
this.avPlayer.fdSrc(fileDescriptor); // Take the audio player as an example. When calling fdSrc, pass fileDescriptor in addition to fd.
}
});
} catch (error) {
console.error(`callback getRawFd failed, error code: ${error.code}, message: ${error.message}.`)
};
```
# Ability Subsystem Changelog
## cl.ability.1 RestartFlag Attribute Names Changed and Unsupported Attribute Deleted in appRecovery
In the **appRecovery** API, the enum names of **RestartFlag** are changed from **NO_RESTART** upon a specific fault to **RESTART** upon a specific fault.
The **CPP_CRASH_NO_RESTART** enum is deleted.
**Change Impact**
If your application uses the **CPP_CRASH_NO_RESTART**, **JS_CRASH_NO_RESTART**, or **APP_FREEZE_NO_RESTART** attribute in versions earlier than 4.0.2.3, its behavior will change after an upgrade to 4.0.2.3.
**Key API/Component Changes**
**RestartFlag** <sup>9+</sup>
Before change:
| Name | Value | Description |
| ----------------------------- | ---- | ------------------------------------------------------------ |
| ALWAYS_RESTART | 0 | The application is restarted in all cases.|
| CPP_CRASH_NO_RESTART | 0x0001 | The application is **not restarted** in the case of CPP_CRASH.|
| JS_CRASH_NO_RESTART | 0x0002 | The application is **not restarted** in the case of JS_CRASH.|
| APP_FREEZE_NO_RESTART | 0x0004 | The application is **not restarted** in the case of APP_FREEZE.|
| NO_RESTART | 0xFFFF | The application is not restarted in any case.|
After change:
| Name | Value | Description |
| ---------- | ---- | ---------- |
| ALWAYS_RESTART | 0 | The application is restarted in all cases.|
| CPP_CRASH_NO_RESTART | NA | **Deleted.** The restart in this scenario is not supported.|
| RESTART_WHEN_JS_CRASH | 0x0001 | The application is **restarted** in the case of JS_CRASH.|
| RESTART_WHEN_APP_FREEZE | 0x0002 | The application is **restarted** in the case of APP_FREEZE.|
| NO_RESTART | 0xFFFF | The application is not restarted in any case.|
**Adaptation Guide**
Perform adaptation based on the new semantics.
# ANS Subsystem Changelog
## cl.notificationManager.1 API Renaming
Renamed certain APIs to meet the naming conventions.
**Change Impact**
The underlying layer still supports the functions of the original APIs, and therefore these APIs can be called in OpenHarmony 4.0.2.3.
**Key API/Component Changes**
| Bundle Name | Original API | New API |
| --------------- | ------------------------------------------------------------ | ------------------------------------------------------------ |
| ohos.notificationManager.d.ts | **function** supportDoNotDisturbMode(callback: AsyncCallback\<boolean>): **void**; | **function** isSupportDoNotDisturbMode(callback: AsyncCallback\<boolean>): **void**; |
| ohos.notificationManager.d.ts | **function** supportDoNotDisturbMode(): Promise\<boolean>; | **function** isSupportDoNotDisturbMode(): Promise\<boolean>; |
**Adaptation Guide**
Call the new API **isSupportDoNotDisturbMode**.
# ArkUI Subsystem Changelog
## cl.arkui.1 Restrictions on Data Type Declarations of State Variables
1. The data types of state variables decorated by state decorators must be explicitly declared. They cannot be declared as **any**.
Example:
```ts
// xxx.ets
@Entry
@Component
struct DatePickerExample {
// Incorrect: @State isLunar: any = false
@State isLunar: boolean = false
build() {
...
}
}
```
2. The data type declaration of the **@State**, **@Provide**, **@Link**, or **@Consume** decorated state variables can consist of only one of the primitive data types or reference data types.
The **Length**, **ResourceStr**, and **ResourceColor** types are combinations of primitive data types or reference data types. Therefore, they cannot be used by the aforementioned types of state variables.
For details about the definitions of **Length**, **ResourceStr**, and **ResourceColor**, see [Types](../../../application-dev/reference/arkui-ts/ts-types.md).
Example:
```ts
// xxx.ets
@Entry
@Component
struct IndexPage {
// Incorrect: @State message: string | Resource = 'Hello World'
@State message: string = 'Hello World'
// Incorrect: @State message: ResourceStr = $r('app.string.hello')
@State resourceStr: Resource = $r('app.string.hello')
build() {
Row() {
Column() {
Text(`${this.message}`)
.fontSize(50)
.fontWeight(FontWeight.Bold)
}
.width('100%')
}
.height('100%')
}
}
```
![hello](../../../application-dev/quick-start/figures/hello.PNG)
**Change Impacts**
1. If the data type of a state variable decorated by a state decorator is declared as **any**, a build error message will be displayed.
```ts
// ArkTS:WARN Please define an explicit type, not any.
@State isLunar: any = false
```
3. If the data type of a **@State**, **@Provide**, **@Link**, and or **@Consume** decorated state variable is Length, **ResourceStr**, or **ResourceColor**,
a build error will occur.
```ts
/* ArkTS:ERROR The state variable type here is 'ResourceStr', it contains both a simple type and an object type,
which are not allowed to be defined for state variable of a struct.*/
@State message: ResourceStr = $r('app.string.hello')
```
**Key API/Component Changes**
N/A
**Adaptation Guide**
1. Explicitly declare the data type for state variables decorated by state decorators.
3.
Adapt the **@State**, **@Provide**, **@Link**, and **@Consume** decorated variables based on the following code snippet so that they do not use the **Length(string|number|Resource)**, **ResourceStr(string|Resource)**, and **ResourceColor(string|number|Color|Resource)** types:
```ts
// Incorrect:
@State message: ResourceStr = $r('app.string.hello')
// Corrected:
@State resourceStr: Resource = $r('app.string.hello')
```
## cl.arkui.2 Initialization Rules and Restrictions of Custom Components' Member Variables
Comply with the following rules when using constructors to initialize member variables:
| **From the Variable in the Parent Component (Right) to the Variable in the Child Component (Below)**| **regular** | **@State** | **@Link** | **@Prop** | **@Provide** | **@Consume** | **@ObjectLink** |
| -------------------------- | ----------- | ---------- | --------- | --------- | ------------ | ------------ | --------------- |
| **regular** | Supported | Supported | Supported | Supported | Not supported | Not supported | Supported |
| **@State** | Supported | Supported | Supported | Supported | Supported | Supported | Supported |
| **@Link** | Not supported | Supported (1) | Supported (1) | Supported (1) | Supported (1) | Supported (1) | Supported (1) |
| **@Prop** | Supported | Supported | Supported | Supported | Supported | Supported | Supported |
| **@Provide** | Supported | Supported | Supported | Supported | Supported | Supported | Supported |
| **@Consume** | Not supported | Not supported | Not supported | Not supported | Not supported | Not supported | Not supported |
| **@ObjectLink** | Not supported | Not supported | Not supported | Not supported | Not supported | Not supported | Not supported |
| **From the Variable in the Parent Component (Right) to the Variable in the Child Component (Below)**| **@StorageLink** | **@StorageProp** | **@LocalStorageLink** | **@LocalStorageProp** |
| -------------------------- | ---------------- | ---------------- | --------------------- | --------------------- |
| **regular** | Supported | Not supported | Not supported | Not supported |
| **@State** | Supported | Supported | Supported | Supported |
| **@Link** | Supported (1) | Supported (1) | Supported (1) | Supported (1) |
| **@Prop** | Supported | Supported | Supported | Supported |
| **@Provide** | Supported | Supported | Supported | Supported |
| **@Consume** | Not supported | Not supported | Not supported | Not supported |
| **@ObjectLink** | Not supported | Not supported | Not supported | Not supported |
> **NOTE**
>
> **Supported (1)**: The dollar sign ($) must be used, for example, **this.$varA**.
>
> **regular**: refers to a regular variable that is not decorated by any decorator.
**@StorageLink**, **@StorageProp**, **@LocalStorageLink**, and **@LocalStorageProp** variables cannot be initialized from the parent component.
**Change Impacts**
1. **@LocalStorageLink** and **@LocalStorageProp** variables cannot be initialized from the parent component. Otherwise, a build error message will be displayed.
```ts
@Entry
@Component
struct LocalStorageComponent {
build() {
Column() {
Child({
/* ArkTS:WARN Property 'simpleVarName' in the custom component 'Child' cannot
initialize here (forbidden to specify). */
simpleVarName: 1,
/* ArkTS:WARN Property 'objectName' in the custom component 'Child' cannot
initialize here (forbidden to specify). */
objectName: new ClassA("x")
})
}
}
}
@Component
struct Child {
@LocalStorageLink("storageSimpleProp") simpleVarName: number = 0;
@LocalStorageProp("storageObjectProp") objectName: ClassA = new ClassA("x");
build() {}
}
```
2. The **@ObjectLink** decorated variable cannot be directly initialized from a decorated variable in the parent component. The source of the parent component must be an array item or object attribute decorated by **@State**, **@Link**, **@Provide**, **@Consume**, or **@ObjectLink**.
```ts
let NextID : number = 0;
@Observed class ClassA {
public id : number;
public c: number;
constructor(c: number) {
this.id = NextID++;
this.c = c;
}
}
@Component
struct Child {
@ObjectLink varA : ClassA;
build() {
Row() {
Text('ViewA-' + this.varA.id)
}
}
}
@Component
struct Parent {
@Link linkValue: ClassA
build() {
Column() {
/* ArkTS:ERROR The @Link property 'linkValue' cannot be assigned to
the @ObjectLink property 'varA'.*/
Child({ varA: this.linkValue })
}
}
}
```
**Key API/Component Changes**
N/A
**Adaptation Guide**
1. When building a child component, do not assign values to the variables decorated by **@LocalStorageLink** and **@LocalStorageProp** in the child component.
To change these variables from the parent component, use the API provided by the **LocalStorage** (such as the **set** API) to assign values to them.
2. For details about how to use **@ObjectLink**, see [\@Observed and \@ObjectLink Decorators: Observing Attribute Changes in Nested Class Objects](../../../application-dev/quick-start/arkts-observed-and-objectlink.md).
## cl.arkui.3 Change of the onScrollBegin Event of the \<List> and \<Scroll> Components
The **onScrollBegin** event of the **\<List>** and **\<Scroll>** components is renamed **onScrollFrameBegin**. In the **onScrollBegin** event, the amount to scroll by is indicated by the **dx** and **dy** parameters. In the **onScrollFrameBegin** event, it is indicated by the **offset** parameter. The **onScrollFrameBegin** event adds the **ScrollState** parameter to indicate whether the component is in the finger dragging or inertial scrolling state.
**Change Impacts**
The **onScrollBegin** event is deprecated and must be replaced with the **onScrollFrameBegin** event.
**Key API/Component Changes**
| Old Event | New Event |
| ---------------------------------------- | ---------------------------------------- |
| onScrollBegin(event: (dx: number, dy: number) => { dxRemain: number, dyRemain: number }) | onScrollFrameBegin(event: (offset: number, state: ScrollState) => { offsetRemain: number }) |
For details about the **onScrollFrameBegin** event, see the following:
- [Scroll Events](../../../application-dev/reference/arkui-ts/ts-container-scroll.md#events)
- [List Events](../../../application-dev/reference/arkui-ts/ts-container-list.md#events)
**Adaptation Guide**
Switch the event from **onScrollBegin** to **onScrollFrameBegin**, and use the **offset** parameter in **onScrollFrameBegin**, rather than the **dx** and **dy** parameters in **onScrollBegin**, to indicate the amount to scroll by.
Example of using the **onScrollBegin** event:
```ts
@Entry
@Component
struct NestedScroll {
@State listPosition: number = 0; // 0 indicates scrolling to the top of the list, 1 indicates scrolling to the middle of the list, and 2 indicates scrolling to the bottom of the list.
private arr: number[] = [1, 2, 3, 4, 5, 6, 7, 8, 9, 10]
private scrollerForScroll: Scroller = new Scroller()
private scrollerForList: Scroller = new Scroller()
build() {
Flex() {
Scroll(this.scrollerForScroll) {
Column() {
Text("Scroll Area")
.width("100%").height("40%").backgroundColor(0X330000FF)
.fontSize(16).textAlign(TextAlign.Center)
.onClick(() => {
this.scrollerForList.scrollToIndex(5)
})
List({ space: 20, scroller: this.scrollerForList }) {
ForEach(this.arr, (item) => {
ListItem() {
Text("ListItem" + item)
.width("100%").height("100%").borderRadius(15)
.fontSize(16).textAlign(TextAlign.Center).backgroundColor(Color.White)
}.width("100%").height(100)
}, item => item)
}
.width("100%")
.height("50%")
.edgeEffect(EdgeEffect.None)
.onReachStart(() => {
this.listPosition = 0
})
.onReachEnd(() => {
this.listPosition = 2
})
.onScrollBegin((dx: number, dy: number) => {
if ((this.listPosition == 0 && dy >= 0) || (this.listPosition == 2 && dy <= 0)) {
this.scrollerForScroll.scrollBy(0, -dy)
return { dxRemain: dx, dyRemain: 0 }
}
this.listPosition = 1
return { dxRemain: dx, dyRemain: dy };
})
Text("Scroll Area")
.width("100%").height("40%").backgroundColor(0X330000FF)
.fontSize(16).textAlign(TextAlign.Center)
}
}
.width("100%").height("100%")
}.width('100%').height('100%').backgroundColor(0xDCDCDC).padding(20)
}
}
```
Example of using the **onScrollFrameBegin** event:
```ts
@Entry
@Component
struct NestedScroll {
@State listPosition: number = 0; // 0 indicates scrolling to the top of the list, 1 indicates scrolling to the middle of the list, and 2 indicates scrolling to the bottom of the list.
private arr: number[] = [1, 2, 3, 4, 5, 6, 7, 8, 9, 10]
private scrollerForScroll: Scroller = new Scroller()
private scrollerForList: Scroller = new Scroller()
build() {
Flex() {
Scroll(this.scrollerForScroll) {
Column() {
Text("Scroll Area")
.width("100%").height("40%").backgroundColor(0X330000FF)
.fontSize(16).textAlign(TextAlign.Center)
.onClick(() => {
this.scrollerForList.scrollToIndex(5)
})
List({ space: 20, scroller: this.scrollerForList }) {
ForEach(this.arr, (item) => {
ListItem() {
Text("ListItem" + item)
.width("100%").height("100%").borderRadius(15)
.fontSize(16).textAlign(TextAlign.Center).backgroundColor(Color.White)
}.width("100%").height(100)
}, item => item)
}
.width("100%")
.height("50%")
.edgeEffect(EdgeEffect.None)
.onReachStart(() => {
this.listPosition = 0
})
.onReachEnd(() => {
this.listPosition = 2
})
.onScrollFrameBegin((offset: number, state: ScrollState) => {
if ((this.listPosition == 0 && offset >= 0) || (this.listPosition == 2 && offset <= 0)) {
this.scrollerForScroll.scrollBy(0, -offset)
return { offsetRemain: 0 }
}
this.listPosition = 1
return { offsetRemain: offset };
})
Text("Scroll Area")
.width("100%").height("40%").backgroundColor(0X330000FF)
.fontSize(16).textAlign(TextAlign.Center)
}
}
.width("100%").height("100%")
}.width('100%').height('100%').backgroundColor(0xDCDCDC).padding(20)
}
}
```
# USB Subsystem API Changelog
## cl.usb_manager.1 Bundle Name Change
For applications developed based on earlier versions, you need to change the name of the imported bundle. Otherwise, the original service logic will be affected.
**Key API/Component Changes**
| Original Bundle Name | New Bundle Name |
|------------------ | ------------------- |
| ohos.usbV9.d.ts | ohos.usbManager.d.ts |
**Adaptation Guide**
Change **@ohos.usbV9** to **@ohos.usbManager** when importing the bundle.
## cl.usb_manager.2 API Parameter Type Change
For applications developed based on earlier versions, you need to modify the parameter type. Otherwise, the original service logic will be affected.
**Key API/Component Changes**
| Original Class Name | New Class Name |
|---------------| ------------- |
| interface USBConfig | interface USBConfiguration |
| Original Namespace | New Namespace |
|---------------| ------------- |
| @namespace usbV9 | @namespace usbManager |
| Bundle Name | Original API | New API |
| --------------- | ------------------------------------------------------------ | ------------------------------------------------------------ |
| ohos.usbManager.d.ts | function setConfiguration(pipe: USBDevicePipe, config: USBConfig): number; | function setConfiguration(pipe: USBDevicePipe, config: USBConfiguration): number; |
**Adaptation Guide**
When calling **setConfiguration**, change the parameter type from **USBConfig** to **USBConfiguration**.
# Telephony Subsystem Changelog
## cl.telephony.radio.1 isNrSupported API Change
NR is a proper noun and must be capitalized.
You need to adapt your application.
**Change Impact**
The JS API needs to be adapted for applications developed based on earlier versions. Otherwise, relevant functions will be affected.
**Key API/Component Changes**
- Involved APIs:
isNrSupported(): boolean;
isNrSupported(slotId: number): boolean;
- Before change:
```js
function isNrSupported(): boolean;
function isNrSupported(slotId: number): boolean;
```
- After change:
```js
function isNRSupported(): boolean;
function isNRSupported(slotId: number): boolean;
```
**Adaptation Guide**
Use the new API. The sample code is as follows:
```js
let result = radio.isNrSupported();
console.log("Result: "+ result);
```
```js
let slotId = 0;
let result = radio.isNRSupported(slotId);
console.log("Result: "+ result);
```
## cl.telephony.call.2 dial API Change
Changed the `dial` API to the `dialCall` API in the call module of the telephony subsystem since API version 9.
You need to adapt your application.
**Change Impact**
The `dial` API is deprecated and cannot be used anymore. Use the `dialCall` API instead. Otherwise, relevant functions will be affected.
**Key API/Component Changes**
- Involved APIs:
dial(phoneNumber: string, callback: AsyncCallback<boolean>): void;
dial(phoneNumber: string, options: DialOptions, callback: AsyncCallback<boolean>): void;
dial(phoneNumber: string, options?: DialOptions): Promise<boolean>;
- Before change:
```js
function dial(phoneNumber: string, callback: AsyncCallback<boolean>): void;
function dial(phoneNumber: string, options: DialOptions, callback: AsyncCallback<boolean>): void;
function dial(phoneNumber: string, options?: DialOptions): Promise<boolean>;
```
- After change:
```js
function dialCall(phoneNumber: string, callback: AsyncCallback<void>): void;
function dialCall(phoneNumber: string, options: DialCallOptions, callback: AsyncCallback<void>): void;
function dialCall(phoneNumber: string, options?: DialCallOptions): Promise<void>;
```
**Adaptation Guide**
The `dial` API is deprecated and cannot be used anymore. Use the `dialCall` API instead.
Use the new API. The sample code is as follows:
```js
call.dialCall("138xxxxxxxx", (err, data) => {
console.log(`callback: err->${JSON.stringify(err)}, data->${JSON.stringify(data)}`);
});
```
```js
call.dialCall("138xxxxxxxx", {
accountId: 0,
videoState: 0,
dialScene: 0,
dialType: 0,
}, (err, data) => {
console.log(`callback: err->${JSON.stringify(err)}, data->${JSON.stringify(data)}`);
});
```
```js
try {
call.dialCall('138xxxxxxxx');
console.log(`dialCall success, promise: data->${JSON.stringify(data)}`);
} catch (error) {
console.log(`dialCall fail, promise: err->${JSON.stringify(error)}`);
}
```
# App Access Control Subsystem ChangeLog
OpenHarmony 4.0.3.2 has the following changes in the APIs of the app access control subsystem:
## cl.access_token.1 getPermissionUsedRecords Name Change
Changed **getPermissionUsedRecords** to **getPermissionUsedRecord**.
**Change Impact**
The **getPermissionUsedRecords()** API cannot be used in OpenHarmony 4.0.3.3 and later versions.
**Key API/Component Changes**
- Involved APIs:
function getPermissionUsedRecords
- Before change:
```ts
function getPermissionUsedRecords
```
- After change:
```ts
function getPermissionUsedRecord
```
**Adaptation Guide**
Use **getPermissionUsedRecord()**.
# Security Subsystem Changelog
## cl.security.1 ParamsSpec Attribute Name Change
Changed **algoName** of the **ParamsSpec** structure to **algName**.
**Change Impact**
For the released JavaScript APIs that use **ParamsSpec** and its child classes **IvParamsSpec**, **GcmParamsSpec**, and **CcmParamsSpec** as parameters or return values, **algoName** must be changed to **algName**.
The change must be made for all the applications that use these APIs. Otherwise, the compilation in the SDK of the new version cannot be successful.
**Key API/Component Changes**
API prototype before the change:
```ts
interface ParamsSpec {
/**
* Indicates the algorithm name. Should be set before initialization of a cipher object.
* @type { string }
* @syscap SystemCapability.Security.CryptoFramework
* @since 9
*/
algoName : string;
}
```
API prototype after the change:
```ts
interface ParamsSpec {
/**
* Indicates the algorithm name. Should be set before initialization of a cipher object.
* @type { string }
* @syscap SystemCapability.Security.CryptoFramework
* @since 9
*/
algName : string;
}
```
**Adaptation Guide**
Change **algoName** to **algName** in **ParamsSpec** and its child classes **IvParamsSpec**, **GcmParamsSpec**, and **CcmParamsSpec**.
```ts
function genGcmParamsSpec() {
let arr = [0, 0, 0, 0 , 0, 0, 0, 0, 0, 0 , 0, 0]; // 12 bytes
let dataIv = new Uint8Array(arr);
let ivBlob = {data : dataIv};
arr = [0, 0, 0, 0 , 0, 0, 0, 0]; // 8 bytes
let dataAad = new Uint8Array(arr);
let aadBlob = {data : dataAad};
arr = [0, 0, 0, 0 , 0, 0, 0, 0, 0, 0, 0, 0 , 0, 0, 0, 0]; // 16 bytes
let dataTag = new Uint8Array(arr);
let tagBlob = {data : dataTag};
let gcmParamsSpec = {iv : ivBlob, aad : aadBlob, authTag : tagBlob, algName : "GcmParamsSpec"};
return gcmParamsSpec;
}
```
For details, see the APIs of **ParamsSpec** in [Crypto Framework](../../../application-dev/reference/apis/js-apis-cryptoFramework.md#paramsspec).
## Change of cl.security.2 ECC Algorithm Parameter Name from ECC512 to ECC521
**Change Impact**
Behavior of released JavaScript APIs will be changed.
The application needs to be adapted to obtain the correct result in the SDK of the new version.
**Key API/Component Changes**
The parameter passed in the APIs is changed from **ECC512** to **ECC521**. The related APIs remain unchanged. For details, see [Key Generation Specifications](../../../application-dev/security/cryptoFramework-overview.md#key-generation-specifications). The following APIs are involved:
cryptoFramework.createAsyKeyGenerator
cryptoFramework.createSign
cryptoFramework.createVerify
cryptoFramework.createKeyAgreement
**Adaptation Guide**
```js
import cryptoFramework from "@ohos.security.cryptoFramework"
let asyKeyGenerator = cryptoFramework.createAsyKeyGenerator("ECC521");
```
# Web Subsystem Changelog
Compared with earlier versions, OpenHarmony 4.0.3.2 has the following API changes in its web subsystem:
## cl.web.1 HitTestTypeV9 Name Change
Renamed the enum class **HitTestTypeV9** **WebHitTestType** to meet the naming conventions.
**Change Impact**
The enum class **HitTestTypeV9** and APIs that use **HitTestTypeV9** as a parameter or return value cannot be used in OpenHarmony 4.0.3.2 and later versions.
**Key API/Component Changes**
- Involved APIs:
enum HitTestTypeV9
- Before change:
```ts
enum HitTestTypeV9
```
- After change:
```ts
enum WebHitTestType
```
**Adaptation Guide**
Replace **HitTestTypeV9** with **WebHitTestType**.
## cl.web.2 HeaderV9 Name Change
Renamed the struct **HeaderV9** **WebHeader** to meet the naming conventions.
**Change Impact**
The struct **HeaderV9** and APIs that use **HeaderV9** as a parameter or return value cannot be used in OpenHarmony 4.0.3.2 and later versions.
**Key API/Component Changes**
- Involved APIs:
interface HeaderV9
- Before change:
```ts
interface HeaderV9
```
- After change:
```ts
interface WebHeader
```
**Adaptation Guide**
Replace **HeaderV9** with **WebHeader**.
## cl.web.3 Member Change of HitTestValue
Rename the member variable **HitTestTypeV9** in the **HitTestValue** struct **WebHitTestType** to meet the naming conventions.
**Change Impact**
The struct **HitTestValue** and APIs that use **HitTestValue** as a parameter or return value cannot be used in OpenHarmony 4.0.3.2 and later versions.
**Key API/Component Changes**
- Involved APIs:
interface HitTestValue
- Before change:
```ts
interface HitTestValue {
/**
* Get the hit test type.
*
* @since 9
*/
type: HitTestTypeV9;
/**
* Get the hit test extra data.
*
* @since 9
*/
extra: string;
}
```
- After change:
```ts
interface HitTestValue {
/**
* Get the hit test type.
*
* @since 9
*/
type: WebHitTestType;
/**
* Get the hit test extra data.
*
* @since 9
*/
extra: string;
}
```
**Adaptation Guide**
Replace **HitTestTypeV9** with **WebHitTestType**.
## cl.web.4 Parameter Type Change of loadUrl
Changed the type of the **headers** parameter in **loadUrl** to **WebHeader** to meet the naming conventions.
**Change Impact**
The **loadUrl** API that uses the **headers** parameter cannot be used in OpenHarmony 4.0.3.2 and later versions.
**Key API/Component Changes**
- Involved APIs:
loadUrl(url: string | Resource, headers?: Array\<HeaderV9>): void
- Before change:
```ts
loadUrl(url: string | Resource, headers?: Array<HeaderV9>): void
```
- After change:
```ts
loadUrl(url: string | Resource, headers?: Array<WebHeader>): void
```
**Adaptation Guide**
Change the type of the **headers** parameter in **loadUrl** from **HeaderV9** to **WebHeader**.
## cl.web.5 Return Value Type Change of getHitTest
Changed the return value type of the **getHitTest** API to **WebHitTest** to meet the naming conventions.
**Change Impact**
The **getHitTest** API cannot be used in OpenHarmony 4.0.3.2 and later versions.
**Key API/Component Changes**
- Involved APIs:
getHitTest(): HitTestTypeV9
- Before change:
```ts
getHitTest(): HitTestTypeV9
```
- After change:
```ts
getHitTest(): WebHitTestType
```
**Adaptation Guide**
Change the return value type of the **getHitTest** API from **HitTestTypeV9** to **WebHitTestType**.
## cl.web.6 Moving of the WebMessagePort Class
Moved the **WebMessagePort** class to **@ohos.web.webview.d.ts** and added error throwing.
**Change Impact**
If your application is developed based on earlier versions, note that the **d.ts** file storage location and the name of the module to be imported are changed. In addition, be mindful of the error codes now that the APIs in the class support error code processing.
**Key API/Component Changes**
- Involved APIs:
postMessageEvent(message: WebMessageEvent): void;
onMessageEvent(callback: (result: string) => void): void;
- Before change:
```ts
postMessageEvent(message: WebMessageEvent): void;
onMessageEvent(callback: (result: string) => void): void;
```
- After change:
```ts
postMessageEvent(message: WebMessage): void;
onMessageEvent(callback: (result: WebMessage) => void): void;
```
**Adaptation Guide**
Instead of importing APIs from the original **WebMessagePort** class, import APIs from **@ohos.web.webview** as follows:
```ts
import web_webview from '@ohos.web.webview';
```
## cl.web.7 Moving of the HitTestValue Class
Moved the **HitTestValue** class to **@ohos.web.webview.d.ts**; changed **HitTestValue** from a class to an API; changed the **getType** and **getExtra** from APIs to attributes.
**Change Impact**
If your application is developed based on earlier versions, note that the **d.ts** file storage location and the name of the module to be imported are changed.
**Key API/Component Changes**
- Involved APIs:
getType(): HitTestType;
getExtra(): string;
- Before change:
```ts
getType(): HitTestType;
getExtra(): string;
```
- After change:
```ts
type: WebHitTestType;
extra: string;
```
**Adaptation Guide**
Instead of importing APIs from the original **HitTestValue** class, import APIs from **@ohos.web.webview** as follows:
```ts
import web_webview from '@ohos.web.webview';
```
## cl.web.8 Moving of API Version 9 APIs Under WebCookie
Moved APIs of API version 9 in the **WebCookie** class to **web.webview.webview.WebCookieManager**
and added error throwing.
**Change Impact**
If your application is developed based on earlier versions, note that the **d.ts** file storage location and the name of the module to be imported are changed. In addition, be mindful of the error codes now that the APIs in the class support error code processing.
The APIs in the class are static.
**Key API/Component Changes**
- Involved APIs:
isCookieAllowed(): boolean;
isThirdPartyCookieAllowed(): boolean;
putAcceptCookieEnabled(accept: boolean): void;
putAcceptThirdPartyCookieEnabled(accept: boolean): void;
setCookie(url: string, value: string): boolean;
saveCookieSync(): boolean;
getCookie(url: string): string;
existCookie(): boolean;
deleteEntireCookie(): void;
deleteSessionCookie(): void;
- Before change:
```ts
isCookieAllowed(): boolean;
isThirdPartyCookieAllowed(): boolean;
putAcceptCookieEnabled(accept: boolean): void;
putAcceptThirdPartyCookieEnabled(accept: boolean): void;
setCookie(url: string, value: string): boolean;
saveCookieSync(): boolean;
getCookie(url: string): string;
existCookie(): boolean;
deleteEntireCookie(): void;
deleteSessionCookie(): void;
```
- After change:
```ts
static isCookieAllowed(): boolean;
static isThirdPartyCookieAllowed(): boolean;
static putAcceptCookieEnabled(accept: boolean): void;
static putAcceptThirdPartyCookieEnabled(accept: boolean): void;
static setCookie(url: string, value: string): void;
static saveCookieAsync(): Promise<void>;
static saveCookieAsync(callback: AsyncCallback<void>): void;
static getCookie(url: string): string;
static existCookie(): boolean;
static deleteEntireCookie(): void;
static deleteSessionCookie(): void;
```
**Adaptation Guide**
Instead of importing APIs from the original **WebCookie** class, import APIs from **@ohos.web.webview** as follows:
```ts
import web_webview from '@ohos.web.webview';
```
## cl.web.9 Moving of API Version 9 APIs Under WebController
Moved APIs of API version 9 in the **WebController** class to **web.webview.webview.WebviewController** and added error throwing.
**Change Impact**
If your application is developed based on earlier versions, note that the **d.ts** file storage location and the name of the module to be imported are changed. In addition, be mindful of the error codes now that the APIs in the class support error code processing.
The **getDefaultUserAgent** API is renamed **getUserAgent**.
**Key API/Component Changes**
- Involved APIs:
zoomIn(): boolean;
zoomOut(): boolean;
createWebMessagePorts(): Array\<WebMessagePort>;
postMessage(options: { message: WebMessageEvent, uri: string}): void;
getHitTestValue(): HitTestValue;
getWebId(): number;
getDefaultUserAgent(): string;
getTitle(): string;
getPageHeight(): number;
backOrForward(step: number): void;
searchAllAsync(searchString: string): void;
clearMatches(): void;
searchNext(forward: boolean): void;
clearSslCache(): void;
clearClientAuthenticationCache(): void;
getUrl(): string;
- Before change:
```ts
zoomIn(): boolean;
zoomOut(): boolean;
createWebMessagePorts(): Array<WebMessagePort>;
postMessage(options: { message: WebMessageEvent, uri: string}): void;
getHitTestValue(): HitTestValue;
getWebId(): number;
getDefaultUserAgent(): string;
getTitle(): string;
getPageHeight(): number;
backOrForward(step: number): void;
searchAllAsync(searchString: string): void;
clearMatches(): void;
searchNext(forward: boolean): void;
clearSslCache(): void;
clearClientAuthenticationCache(): void;
getUrl(): string;
```
- After change:
```ts
zoomIn(): void;
zoomOut(): void;
createWebMessagePorts(): Array<WebMessagePort>;
postMessage(name: string, ports: Array<WebMessagePort>, uri: string): void;
getHitTestValue(): HitTestValue;
getWebId(): number;
getUserAgent(): string;
getTitle(): string;
getPageHeight(): number;
backOrForward(step: number): void;
searchAllAsync(searchString: string): void;
clearMatches(): void;
searchNext(forward: boolean): void;
clearSslCache(): void;
clearClientAuthenticationCache(): void;
getUrl(): string;
```
**Adaptation Guide**
Instead of importing APIs from the original **WebController** class, import APIs from **@ohos.web.webview** as follows:
```ts
import web_webview from '@ohos.web.webview';
```
## cl.web.10 Moving of the WebAsyncController Class
Moved the APIs in the **WebAsyncController** class to the **web.webview.webview.WebviewController** class and added error throwing.
**Change Impact**
If your application is developed based on earlier versions, pay attention to error code processing.
**Key API/Component Changes**
- Involved APIs:
storeWebArchive(baseName: string, autoName: boolean): Promise\<string>;
storeWebArchive(baseName: string, autoName: boolean, callback : AsyncCallback\<string>): void;
- Before change:
```ts
storeWebArchive(baseName: string, autoName: boolean): Promise<string>;
storeWebArchive(baseName: string, autoName: boolean, callback : AsyncCallback<string>): void;
```
- After change:
```ts
storeWebArchive(baseName: string, autoName: boolean): Promise<string>;
storeWebArchive(baseName: string, autoName: boolean, callback : AsyncCallback<string>): void;
```
**Adaptation Guide**
Example:
```ts
// xxx.ets
import web_webview from '@ohos.web.webview'
@Entry
@Component
struct WebComponent {
controller: web_webview.WebviewController = new web_webview.WebviewController();
build() {
Column() {
Button('saveWebArchive')
.onClick(() => {
try {
this.controller.storeWebArchive("/data/storage/el2/base/", true, (error, filename) => {
if (error) {
console.info(`save web archive error: ` + JSON.stringify(error))
return;
}
if (filename != null) {
console.info(`save web archive success: ${filename}`)
}
});
} catch (error) {
console.error(`ErrorCode: ${error.code}, Message: ${error.message}`);
}
})
Web({ src: 'www.example.com', controller: this.controller })
}
}
}
```
# Account Subsystem Changelog
OpenHarmony 4.0.3.2 has the following changes in account module APIs:
## cl.account_os_account.1 App Account API isAccountRemovable Renamed
Changed **isAccountRemovable** in the **Authenticator** class to **checkAccountRemovable**.
**Change Impact**
The **isAccountRemovable** API in the **Authenticator** class cannot be used from 4.0.3.2. Use **checkAccountRemovable** instead.
**Key API/Component Changes**
- Involved APIs:
```ts
class Authenticator {
...
isAccountRemovable
...
}
```
- Before change:
```ts
class Authenticator {
...
/**
* Checks whether the specified account can be removed.
* @param name Indicates the account name.
* @param callback Indicates the authenticator callback.
* @returns void.
* @since 9
*/
isAccountRemovable(name: string, callback: AuthCallback): void;
...
}
```
- After change:
```ts
class Authenticator {
...
/**
* Checks whether the specified account can be removed.
* @param name Indicates the account name.
* @param callback Indicates the authenticator callback.
* @returns void.
* @since 9
*/
checkAccountRemovable(name: string, callback: AuthCallback): void;
...
}
```
## cl.account_os_account.2 OS Account API checkConstraintEnabled Renamed
Changed **checkConstraintEnabled** to **checkOsAccountConstraintEnabled**.
**Change Impact**
The **checkConstraintEnabled** API cannot be used from 4.0.3.2. Use **checkOsAccountConstraintEnabled** instead.
**Key API/Component Changes**
- Involved APIs:
```
interface AccountManager {
...
checkConstraintEnabled
...
}
```
- Before change:
```ts
checkConstraintEnabled(localId: number, constraint: string, callback: AsyncCallback<boolean>): void;
checkConstraintEnabled(localId: number, constraint: string): Promise<boolean>;
```
- After change:
```ts
checkOsAccountConstraintEnabled(localId: number, constraint: string, callback: AsyncCallback<boolean>): void;
checkOsAccountConstraintEnabled(localId: number, constraint: string): Promise<boolean>;
```
## cl.account_os_account.3 OS Account API **checkOsAccountConstraintEnabled** Permission Scenario Change
Added an optional permission **ohos.permission.INTERACT_ACROSS_LOCAL_ACCOUNTS** to the **checkOsAccountConstraintEnabled** API.
**Change Impact**
In 4.0.3.2 and later versions, an app with the **ohos.permission.INTERACT_ACROSS_LOCAL_ACCOUNTS** permission can also call **checkOsAccountConstraintEnabled**.
The use of **ohos.permission.MANAGE_LOCAL_ACCOUNTS** is not affected.
**Key API/Component Changes**
- Involved APIs:
```
interface AccountManager {
...
checkOsAccountConstraintEnabled
...
}
```
- Before change:
```ts
...
* @permission ohos.permission.MANAGE_LOCAL_ACCOUNTS
...
checkOsAccountConstraintEnabled(localId: number, constraint: string, callback: AsyncCallback<boolean>): void;
checkOsAccountConstraintEnabled(localId: number, constraint: string): Promise<boolean>;
```
- After change:
```ts
...
* @permission ohos.permission.MANAGE_LOCAL_ACCOUNTS or ohos.permission.INTERACT_ACROSS_LOCAL_ACCOUNTS
...
checkOsAccountConstraintEnabled(localId: number, constraint: string, callback: AsyncCallback<boolean>): void;
checkOsAccountConstraintEnabled(localId: number, constraint: string): Promise<boolean>;
```
## cl.account_os_account.4 OS Account API queryOsAccountLocalIdFromProcessd Renamed
Changed **queryOsAccountLocalIdFromProcess** to **getOsAccountLocalId**.
**Change Impact**
The **queryOsAccountLocalIdFromProcess** API cannot be used from 4.0.3.2. Use **getOsAccountLocalId** instead.
**Key API/Component Changes**
- Involved APIs:
```
interface AccountManager {
...
queryOsAccountLocalIdFromProcess
...
}
```
- Before change:
```ts
queryOsAccountLocalIdFromProcess(callback: AsyncCallback<number>): void;
queryOsAccountLocalIdFromProcess(): Promise<number>;
```
- After change:
```ts
getOsAccountLocalId(callback: AsyncCallback<number>): void;
getOsAccountLocalId(): Promise<number>;
```
## cl.account_os_account.5 OS Account API queryOsAccountLocalIdFromUid Renamed
Changed **queryOsAccountLocalIdFromUid** to **getOsAccountLocalIdForUid**.
**Change Impact**
The **queryOsAccountLocalIdFromUid** API cannot be used from 4.0.3.2. Use **getOsAccountLocalIdForUid** instead.
**Key API/Component Changes**
- Involved APIs:
```
interface AccountManager {
...
queryOsAccountLocalIdFromUid
...
}
```
- Before change:
```ts
queryOsAccountLocalIdFromUid(uid: number, callback: AsyncCallback<number>): void;
queryOsAccountLocalIdFromUid(uid: number): Promise<number>;
```
- After change:
```ts
getOsAccountLocalIdForUid(uid: number, callback: AsyncCallback<number>): void;
getOsAccountLocalIdForUid(uid: number): Promise<number>;
```
## cl.account_os_account.6 OS Account API queryOsAccountLocalIdFromDomain Renamed
Changed **queryOsAccountLocalIdFromDomain** to **getOsAccountLocalIdForDomain**.
**Change Impact**
The **queryOsAccountLocalIdFromDomain** API cannot be used from 4.0.3.2. Use **getOsAccountLocalIdForDomain** instead.
**Key API/Component Changes**
- Involved APIs:
```
interface AccountManager {
...
queryOsAccountLocalIdFromDomain
...
}
```
- Before change:
```ts
queryOsAccountLocalIdFromDomain(domainInfo: DomainAccountInfo, callback: AsyncCallback<number>): void;
queryOsAccountLocalIdFromDomain(domainInfo: DomainAccountInfo): Promise<number>;
```
- After change:
```ts
getOsAccountLocalIdForDomain(domainInfo: DomainAccountInfo, callback: AsyncCallback<number>): void;
getOsAccountLocalIdForDomain(domainInfo: DomainAccountInfo): Promise<number>;
```
## cl.account_os_account.7 OS Account API getActivatedOsAccountIds Renamed
Changed **getActivatedOsAccountIds** to **getActivatedOsAccountLocalIds**.
**Change Impact**
The **getActivatedOsAccountIds** API cannot be used from 4.0.3.2. Use **getActivatedOsAccountLocalIds** instead.
**Key API/Component Changes**
- Involved APIs:
```
interface AccountManager {
...
getActivatedOsAccountIds
...
}
```
- Before change:
```ts
getActivatedOsAccountIds(callback: AsyncCallback<Array<number>>): void;
getActivatedOsAccountIds(): Promise<Array<number>>;
```
- After change:
```ts
getActivatedOsAccountLocalIds(callback: AsyncCallback<Array<number>>): void;
getActivatedOsAccountLocalIds(): Promise<Array<number>>;
```
## cl.account_os_account.8 OS Account API queryOsAccountLocalIdBySerialNumber Renamed
Changed **queryOsAccountLocalIdBySerialNumber** to **getOsAccountLocalIdForSerialNumber**.
**Change Impact**
The **queryOsAccountLocalIdBySerialNumber** API cannot be used from 4.0.3.2. Use **getOsAccountLocalIdForSerialNumber** instead.
**Key API/Component Changes**
- Involved APIs:
```
interface AccountManager {
...
queryOsAccountLocalIdBySerialNumber
...
}
```
- Before change:
```ts
queryOsAccountLocalIdBySerialNumber(serialNumber: number, callback: AsyncCallback<number>): void;
queryOsAccountLocalIdBySerialNumber(serialNumber: number): Promise<number>;
```
- After change:
```ts
getOsAccountLocalIdForSerialNumber(serialNumber: number, callback: AsyncCallback<number>): void;
getOsAccountLocalIdForSerialNumber(serialNumber: number): Promise<number>;
```
## cl.account_os_account.9 OS Account API querySerialNumberByOsAccountLocalId Renamed
Changed **querySerialNumberByOsAccountLocalId** to **getSerialNumberForOsAccountLocalId**.
**Change Impact**
The **querySerialNumberByOsAccountLocalId** API cannot be used from 4.0.3.2. Use **getSerialNumberForOsAccountLocalId** instead.
**Key API/Component Changes**
- Involved APIs:
```
interface AccountManager {
...
querySerialNumberByOsAccountLocalId
...
}
```
- Before change:
```ts
querySerialNumberByOsAccountLocalId(localId: number, callback: AsyncCallback<number>): void;
querySerialNumberByOsAccountLocalId(localId: number): Promise<number>;
```
- After change:
```ts
getSerialNumberForOsAccountLocalId(localId: number, callback: AsyncCallback<number>): void;
getSerialNumberForOsAccountLocalId(localId: number): Promise<number>;
```
## cl.account_os_account.10 OS Account API getBundleIdFromUid Renamed
Changed **getBundleIdFromUid** to **getBundleIdForUid**.
**Change Impact**
The **getBundleIdFromUid** API cannot be used from 4.0.3.2. Use **getBundleIdForUid** instead.
**Key API/Component Changes**
- Involved APIs:
```
interface AccountManager {
...
getBundleIdFromUid
...
}
```
- Before change:
```ts
getBundleIdFromUid(uid: number, callback: AsyncCallback<number>): void;
getBundleIdFromUid(uid: number): Promise<number>;
```
- After change:
```ts
getBundleIdForUid(uid: number, callback: AsyncCallback<number>): void;
getBundleIdForUid(uid: number): Promise<number>;
```
## cl.account_os_account.11 OS Account API queryOsAccountConstraintSourceTypes Renamed
Changed **queryOsAccountConstraintSourceTypes** to **getOsAccountConstraintSourceTypes**.
**Change Impact**
The **queryOsAccountConstraintSourceTypes** API cannot be used from 4.0.3.2. Use **getOsAccountConstraintSourceTypes** instead.
**Key API/Component Changes**
- Involved APIs:
```
interface AccountManager {
...
queryOsAccountConstraintSourceTypes
...
}
```
- Before change:
```ts
queryOsAccountConstraintSourceTypes(localId: number, constraint: string, callback: AsyncCallback<Array<ConstraintSourceTypeInfo>>): void;
queryOsAccountConstraintSourceTypes(localId: number, constraint: string): Promise<Array<ConstraintSourceTypeInfo>>;
```
- After change:
```ts
getOsAccountConstraintSourceTypes(localId: number, constraint: string, callback: AsyncCallback<Array<ConstraintSourceTypeInfo>>): void;
getOsAccountConstraintSourceTypes(localId: number, constraint: string): Promise<Array<ConstraintSourceTypeInfo>>;
```
# ArkUI Subsystem Changelog
## cl.arkui.1 Return Value Type Change of getInspectorTree
**Change Impact**
The code that uses the **getInspectorTree** API in versions earlier than OpenHarmony 4.0.3.2 must be adapted.
**Key API/Component Changes**
The return value of the **getInspectorTree** API is changed from the string type to the Object type.
**Adaptation Guide**
Adapt the code that takes the return value of **getInspectorTree** as a string.The sample code is as follows:
- Before change:
```typescript
console.info(getInspectorTree())
```
- After change:
```typescript
console.info(JSON.stringify(getInspectorTree()))
```
## cl.arkui.2 Deprecation the forceRebuild Attribute of \<GridItem>
**Change Impact**
None. The attribute has no effect.
**Key API/Component Changes**
Deprecate the **forceRebuild** attribute of the **\<GridItem>** component.
**Adaptation Guide**
Delete the code that uses the **forceRebuild** attribute. This will not affect the functionality of the **\<GridItem>** component.
## cl.arkui.1 API Changes of the Router Module in API Version 9
Replaced the **enableAlertBeforeBackPage**, **enableBackPageAlert**, **disableAlertBeforeBackPage** APIs in **ohos.router** to **showAlertBeforeBackPage** and **hideAlertBeforeBackPage** to facilitate development.
**Change Impact**
The **enableAlertBeforeBackPage** and **enableBackPageAlert** APIs must be replaced with **showAlertBeforeBackPage**.
The **disableAlertBeforeBackPage** API must be replaced with **hideAlertBeforeBackPage**.
**Key API/Component Changes**
**router.enableAlertBeforeBackPage**, **router.enableBackPageAlert**, and **router.disableAlertBeforeBackPage**
* Before change:
```ts
router.enableAlertBeforeBackPage();
router.enableBackPageAlert()
```
* After change:
```ts
router.showAlertBeforeBackPage()
```
* Before change:
```ts
router.disableAlertBeforeBackPage()
```
* After change:
```ts
router.hideAlertBeforeBackPage()
```
**Adaptation Guide**
Replace **enableAlertBeforeBackPage** and **enableBackPageAlert** with **showAlertBeforeBackPage**.
Replace **disableAlertBeforeBackPage** with **hideAlertBeforeBackPage**.
# Bundle Manager Subsystem Changelog
## cl.bundlemanager.1 Deleted getAbilityIcon
The **getAbilityIcon** API in [@ohos.bundle.bundleManager.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/@ohos.bundle.bundleManager.d.ts) is deleted. The **getMediaContent** API in [@ohos.resourceManager.d.ts](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/@ohos.resourceManager.d.ts) can be used instead.
**Change Impact**<br>
The **getAbilityIcon** API does not take effect.
**Key API/Component Changes**<br>
The **getAbilityIcon** API is deleted from **@ohos.bundle.bundleManager.d.ts**.
**Adaptation Guide**<br>
If your application uses **getAbilityIcon** in **@ohos.bundle.bundleManager.d.ts**, replace it with **getMediaContent** in **@ohos.resourceManager.d.ts**. You need to obtain the icon ID in advance. For details, see [Usage Guide](../../../application-dev/reference/apis/js-apis-resource-manager.md#getmediacontent9).
## cl.bundlemanager.2 Added Error Code 202
Error code 202 is added to the bundle manager subsystem. If a non-system application calls a system API of API version 9 or later provided by the bundle manager subsystem, error code 202 is returned.
**Change Impact**<br>
Error code 202 is returned when a non-system application calls a system API of API version 9 or later provided by the bundle manager subsystem.
**Key API/Component Changes**<br>
If a non-system application calls a system API of API version 9 or later provided by the bundle manager subsystem, error code 202 is returned.
**Adaptation Guide**<br>
No adaptation is required.
# Common Event Subsystem Changelog
## cl.ces.1 Event Enum Change of ohos.commonEvent
**Change Impact**
For applications developed based on earlier versions, the following common events of the **.ohos.commonEvent** module must be adapted.
| Common Event |
| ----------------------------------- |
| COMMON_EVENT_PACKAGE_CACHE_CLEARED |
| COMMON_EVENT_USB_STATE |
| COMMON_EVENT_USB_PORT_CHANGED |
| COMMON_EVENT_VOLUME_REMOVED |
| COMMON_EVENT_VOLUME_UNMOUNTED |
| COMMON_EVENT_VOLUME_MOUNTED |
| COMMON_EVENT_VOLUME_BAD_REMOVAL |
| COMMON_EVENT_VOLUME_EJECT |
| COMMON_EVENT_SLOT_CHANGE |
| COMMON_EVENT_SPN_INFO_CHANGED |
| COMMON_EVENT_QUICK_FIX_APPLY_RESULT |
**Key API/Component Changes**
Replace the common events in **ohos.commonEvent** with those in **ohos.commonEventManager**.
| Common Event in ohos.commonEvent | Common Event in ohos.commonEventManager |
| ----------------------------------- | ----------------------------------- |
| COMMON_EVENT_PACKAGE_CACHE_CLEARED | COMMON_EVENT_PACKAGE_CACHE_CLEARED |
| COMMON_EVENT_USB_STATE | COMMON_EVENT_USB_STATE |
| COMMON_EVENT_USB_PORT_CHANGED | COMMON_EVENT_USB_PORT_CHANGED |
| COMMON_EVENT_VOLUME_REMOVED | COMMON_EVENT_VOLUME_REMOVED |
| COMMON_EVENT_VOLUME_UNMOUNTED | COMMON_EVENT_VOLUME_UNMOUNTED |
| COMMON_EVENT_VOLUME_MOUNTED | COMMON_EVENT_VOLUME_MOUNTED |
| COMMON_EVENT_VOLUME_BAD_REMOVAL | COMMON_EVENT_VOLUME_BAD_REMOVAL |
| COMMON_EVENT_VOLUME_EJECT | COMMON_EVENT_VOLUME_EJECT |
| COMMON_EVENT_SLOT_CHANGE | COMMON_EVENT_SLOT_CHANGE |
| COMMON_EVENT_SPN_INFO_CHANGED | COMMON_EVENT_SPN_INFO_CHANGED |
| COMMON_EVENT_QUICK_FIX_APPLY_RESULT | COMMON_EVENT_QUICK_FIX_APPLY_RESULT |
**Adaptation Guide**
Replace the events in **ohos.commonEvent** with those in **ohos.commonEventManager**.
Before change:
```typescript
import commonEvent from '@ohos.commonEvent';
let event: string = commonEvent.Support.COMMON_EVENT_PACKAGE_CACHE_CLEARED;
```
After change:
```typescript
import commonEventManager from '@ohos.commonEventManager';
let event: string = commonEventManager.Support.COMMON_EVENT_PACKAGE_CACHE_CLEARED;
```
# File Management Subsystem Changelog
## cl.filemanagement.1 Filter Module Change
Moved **Filter** from **@ohos.fileio** to **@ohos.file.fs**. The attributes of **Filter** remain unchanged.
**Change Impact**
If your application is developed using the APIs of earlier versions, note that the position of **Filter** in the **d.ts** file and the module name are changed. The **Filter** type is moved to **@ohos.file.fs**.
**Key API/Component Changes**
Before the change, **Filter** is in the **@ohos.fileio** module and imported as follows:
```js
import Filter from '@ohos.fileio';
```
**Adaptation Guide**
Now, **Filter** is in the **@ohos.file.fs** module and imported as follows:
```js
import Filter from '@ohos.file.fs';
```
# Pasteboard Subsystem Changelog
OpenHarmony 4.0.3.2 has the following changes in the APIs of the pasteboard subsystem:
## cl.pasteboard.1 convertToTextV9 API Change
Renamed **convertToTextV9** **toPlainText()** and changed the API from asynchronous to synchronous.
**Change Impact**
Applications developed using the **convertToTextV9** API in versions earlier than OpenHarmony 4.0.3.3 cannot be used in OpenHarmony 4.0.3.3 and later versions.
**Key API/Component Changes**
- Involved APIs:
function convertToTextV9
- Before change:
```ts
convertToTextV9(callback: AsyncCallback<string>): void;
convertToTextV9(): Promise<string>;
```
- After change:
```ts
toPlainText(): string;
```
**Adaptation Guide**
Replace **convertToTextV9**, an asynchronous API, with **toPlainText**, a synchronous API.
## cl.pasteboard.2 ShareOption Enum Name Change
Changed the enum names of **ShareOption** from UpperCamelCase to all caps.
**Change Impact**
Applications developed using the **InApp/LocalDevice/CrossDevice** attributes in versions earlier than OpenHarmony 4.0.3.3 cannot be used in OpenHarmony 4.0.3.3 and later versions.
**Key API/Component Changes**
ShareOption<sup>9+</sup>
Before change:
| Name| Value| Description |
| ---- |---|-------------------|
| InApp | 0 | Only intra-application pasting is allowed. |
| LocalDevice | 1 | Paste is allowed in any application on the local device.|
| CrossDevice | 2 | Paste is allowed in any application across devices. |
After change:
| Name| Value| Description |
| ---- |---|-------------------|
| INAPP | 0 | Only intra-application pasting is allowed. |
| LOCALDEVICE | 1 | Paste is allowed in any application on the local device.|
| CROSSDEVICE | 2 | Paste is allowed in any application across devices. |
**Adaptation Guide**
Perform adaptation based on the new semantics.
# Power Subsystem Changelog
## cl.powermgr.1 CommonEventBatteryChangedCode API Change
Changed the **CommonEventBatteryChangedCode** enum class in [@ohos.batteryInfo](../../../application-dev/reference/apis/js-apis-battery-info.md) as follows:
- Changed the class name to **CommonEventBatteryChangedKey**.
- Deleted **EXTRA_MAX_CURRENT**, **EXTRA_MAX_VOLTAGE**, and **EXTRA_CHARGE_COUNTER**.
- Changed the enum value type from numeric to string.
#### Change Impact
The JS API needs to be adapted for applications developed based on earlier versions. Otherwise, relevant functions will be affected.
#### Key API/Component Changes
Before change:
| Name | Value | Description |
| -------------------- | ---- | -------------------------------------------------- |
| EXTRA_SOC | 0 | Remaining battery level in percentage. |
| EXTRA_VOLTAGE | 1 | Battery voltage of the device. |
| EXTRA_TEMPERATURE | 2 | Battery temperature of the device. |
| EXTRA_HEALTH_STATE | 3 | Battery health status of the device. |
| EXTRA_PLUGGED_TYPE | 4 | Type of the charger connected to the device. |
| EXTRA_MAX_CURRENT | 5 | Maximum battery current of the device. |
| EXTRA_MAX_VOLTAGE | 6 | Maximum battery voltage of the device. |
| EXTRA_CHARGE_STATE | 7 | Battery charging status of the device. |
| EXTRA_CHARGE_COUNTER | 8 | Number of battery charging times of the device. |
| EXTRA_PRESENT | 9 | Whether the battery is supported by the device or installed.|
| EXTRA_TECHNOLOGY | 10 | Battery technology of the device. |
| EXTRA_CAPACITY_LEVEL | 11 | Battery level of the device. |
After change:
| Name | Value | Description |
| -------------------- | --------------- | -------------------------------------------------- |
| EXTRA_SOC | "soc" | Remaining battery level in percentage. |
| EXTRA_CHARGE_STATE | "chargeState" | Battery charging status of the device. |
| EXTRA_HEALTH_STATE | "healthState" | Battery health status of the device. |
| EXTRA_PLUGGED_TYPE | "pluggedType" | Type of the charger connected to the device. |
| EXTRA_VOLTAGE | "voltage" | Battery voltage of the device. |
| EXTRA_TECHNOLOGY | "technology" | Battery technology of the device. |
| EXTRA_TEMPERATURE | "temperature" | Battery temperature of the device. |
| EXTRA_PRESENT | "present" | Whether the battery is supported by the device or installed.|
| EXTRA_CAPACITY_LEVEL | "capacityLevel" | Battery level of the device. |
#### Adaptation Guide
For details, see the API reference of the [@ohos.batteryInfo](../../../application-dev/reference/apis/js-apis-battery-info.md) API.
## cl.powermgr.2 estimatedRemainingChargeTime API Change
Changed the **estimatedRemainingChargeTime** API in [@ohos.batteryInfo](../../../application-dev/reference/apis/js-apis-battery-info.md) to a system API.
#### Change Impact
The JS API needs to be adapted for applications developed based on earlier versions. Otherwise, relevant functions will be affected.
#### Adaptation Guide
For details, see the API reference of the [@ohos.batteryInfo](../../../application-dev/reference/apis/js-apis-battery-info.md) API.
## cl.powermgr.3 System Common Event Behavior Change
The following common events are provided in the battery information through [@ohos.commonEventManager (common event module)](https://gitee.com/openharmony/docs/blob/master/en/application-dev/reference/apis/js-apis-commonEventManager.md):
- COMMON_EVENT_BATTERY_LOW: common event for low battery level. It includes the remaining battery in percentage.
- COMMON_EVENT_BATTERY_OKAY: common event for normal battery level. It includes the remaining battery in percentage.
- COMMON_EVENT_POWER_CONNECTED: common event for connection to an external power supply. It includes the type of the power supply to which the device is connected.
- COMMON_EVENT_POWER_DISCONNECTED: common event for disconnection from an external power supply. It includes the type of the power supply from which the device is disconnected.
- COMMON_EVENT_CHARGING: common event for starting of battery charging. It includes the battery charging status.
- COMMON_EVENT_DISCHARGING: common event for ending of battery charging. It includes the battery charging status.
Changed the method of obtaining data from common events from **CommonEventData.data** to **CommonEventData.code**.
#### Change Impact
The application developed based on earlier versions needs to adapt the method for obtaining common events in the battery information. Otherwise, the original service logic will be affected.
#### Adaptation Guide
For details, see the API reference of the [@ohos.commonEventManager (Common Event Manager)](../../../application-dev/reference/apis/js-apis-commonEventManager.md) API.
# Pan-sensor Subsystem Changelog
## cl.ability.1 Attribute Name Changed from venderName to vendorName in the Sensor API
**venderName** is changed to **vendorName**.
**Change Impact**
The **venderName** attribute cannot be used anymore. Use **vendorName** instead.
**Key API/Component Changes**
- Before change:
```js
interface Sensor {
sensorName:string; /**< Sensor name */
venderName:string; /**< Sensor vendor version */
firmwareVersion:string; /**< Sensor firmware version */
hardwareVersion:string; /**< Sensor hardware version */
sensorId:number; /**< Sensor type ID, {@code SensorType} */
maxRange:number; /**< Maximum measurement range of the sensor */
minSamplePeriod:number; /**< Minimum sample period allowed, in ns */
maxSamplePeriod:number; /**< maximum sample period allowed, in ns */
precision:number; /**< Sensor accuracy */
power:number; /**< Sensor power */
}
```
- After change:
```js
interface Sensor {
sensorName:string; /**< Sensor name */
vendorName:string; /**< Sensor vendor version */
firmwareVersion:string; /**< Sensor firmware version */
hardwareVersion:string; /**< Sensor hardware version */
sensorId:number; /**< Sensor type ID, {@code SensorType} */
maxRange:number; /**< Maximum measurement range of the sensor */
minSamplePeriod:number; /**< Minimum sample period allowed, in ns */
maxSamplePeriod:number; /**< maximum sample period allowed, in ns */
precision:number; /**< Sensor accuracy */
power:number; /**< Sensor power */
}
```
**Adaptation Guide**
Replace **venderName** with **vendorName**.
# Startup Subsystem JS API Changelog
## cl.startup.1 Bundle Name Change
**Change Impact**
The original bundle name **@ohos.systemParameterV9** will be deleted and cannot be used anymore. Use the new bundle name **@ohos.systemParameterEnhance** instead.
**Adaptation Guide**
Change the bundle name from **@ohos.systemParameterV9** to **@ohos.systemParameterEnhance**. The APIs remain unchanged. The following is the sample code:
```js
import @ohos.systemParameterEnhance
```
# Bundle Manager Subsystem Changelog
## cl.bundlemanager.1 Bottom-Layer Capability Changed So That Only the System Resource HAP Supports Custom Permissions
Only the system resource HAP supports custom permissions. During HAP parsing, the bundle manager module parses the **definePermissions** field only in the configuration file of the resource HAP (bundle name: **ohos.global.systemres**), but not this field in other HAPs. This field is used to define permissions.
If an application requires custom permissions, add the permissions under the **definePermissions** field in the [configuration file](https://gitee.com/openharmony/utils_system_resources/blob/master/systemres/main/config.json) of the system resource HAP. For details about the permission format, see [Defining Permissions](../../../application-dev/quick-start/module-structure.md#internal-structure-of-the-definepermissions-attribute).
**Change Impact**<br>
After an upgrade to the new version image, the custom permission of the application does not take effect, and the authorization fails.
**Key API/Component Changes**<br>
The bottom-layer capability of the bundle manager module is changed. Only the system resource HAP supports custom permissions.
**Adaptation Guide**<br>
If an application requires custom permissions, add the permissions under the **definePermissions** field in the [configuration file](https://gitee.com/openharmony/utils_system_resources/blob/master/systemres/main/config.json) of the system resource HAP. For details about the permission format, see [Defining Permissions](../../../application-dev/quick-start/module-structure.md#internal-structure-of-the-definepermissions-attribute).
## cl.bundlemanager.2 Level-2 Module File Names Changed
The level-2 module file names of the bundle manager module are changed to their respective API names in the file, as listed below.
| Original File Name|New File Name|
|----|----|
| bundleManager/abilityInfo.d.ts | bundleManager/AbilityInfo.d.ts |
| bundleManager/applicationInfo.d.ts | bundleManager/ApplicationInfo.d.ts |
| bundleManager/bundleInfo.d.ts | bundleManager/BundleInfo.d.ts |
| bundleManager/dispatchInfo.d.ts | bundleManager/DispatchInfo.d.ts |
| bundleManager/elementName.d.ts | bundleManager/ElementName.d.ts |
| bundleManager/extensionAbilityInfo.d.ts | bundleManager/ExtensionAbilityInfo.d.ts |
| bundleManager/hapModuleInfo.d.ts | bundleManager/HapModuleInfo.d.ts |
| bundleManager/launcherAbilityInfo.d.ts | bundleManager/LauncherAbilityInfo.d.ts |
| bundleManager/metadata.d.ts | bundleManager/Metadata.d.ts |
| bundleManager/packInfo.d.ts | bundleManager/BundlePackInfo.d.ts |
| bundleManager/permissionDef.d.ts | bundleManager/PermissionDef.d.ts |
| bundleManager/remoteAbilityInfo.d.ts | bundleManager/RemoteAbilityInfo.d.ts |
| bundleManager/shortcutInfo.d.ts | bundleManager/ShortcutInfo.d.ts |
To sum up, except **packInfo**, which is changed to **BundlePackInfo**, the other file names are changed to start with uppercase letters.
**Change Impact**<br>
The change of the level-2 module file names does not affect the use of the level-1 module. If a level-2 module interface under **bundleManager** is directly imported to the .ts file and an error is reported during compilation on DevEco Studio, you must change the name of the imported file.
**Key API/Component Changes**<br>
The .d.ts file names in the **bundleManager** folder are changed to their respective API names in the file.
**Adaptation Guide**<br>
Generally, no adaptation is required. If a file in the **bundleManager** folder is directly imported to the application, you must change the imported file name as follows:
**Before change:**
```ts
import {AbilityInfo} from 'bundleManger/abilityInfo';
import {ExtensionAbilityInfo} from 'bundleManger/extensionAbilityInfo';
import {BundlePackInfo} from 'bundleManger/packInfo';
```
**After change:**
```ts
import {AbilityInfo} from 'bundleManger/AbilityInfo';
import {ExtensionAbilityInfo} from 'bundleManger/ExtensionAbilityInfo';
import {BundlePackInfo} from 'bundleManger/BundlePackInfo';
```
## cl.bundlemanager.3 LaunchType Enum Type Name Changed from STANDARD to MULTITON
The enum type name of [LaunchType](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/@ohos.bundle.bundleManager.d.ts) is changed from **STANDARD** to **MULTITON**. The enum value remains unchanged, indicating the multi-instance type.
**Change Impact**<br>
The **LaunchType.STANDARD** type does not take effect.
**Key API/Component Changes**<br>
The enum type name of **LaunchType** is changed from **STANDARD** to **MULTITON**.
**Adaptation Guide**<br>
Change **LaunchType.STANDARD** to **LaunchType.MULTITON** for your application.
## cl.bundlemanager.4 Changed the isVisible Field in the AbilityInfo Struct to exported
The **isVisible** field in the [AbilityInfo](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/AbilityInfo.d.ts) struct is changed to **exported**. The type remains unchanged, indicating whether the ability can be exported and used by other abilities.
**Change Impact**<br>
The **isVisible** field does not take effect.
**Key API/Component Changes**<br>
The **isVisible** field in the [AbilityInfo](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/AbilityInfo.d.ts) struct is changed to **exported**, and the type remains unchanged.
**Adaptation Guide**<br>
Change **isVisible** to **exported** for your application.
## cl.bundlemanager.5 Changed the isVisible Field in the ExtensionAbilityInfo Struct to exported
The **isVisible** field in the [ExtensionAbilityInfo](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/ExtensionAbilityInfo.d.ts) struct is changed to **exported**. The type remains unchanged, indicating whether the ability can be exported and used by other abilities.
**Change Impact**<br>
The **isVisible** field does not take effect.
**Key API/Component Changes**<br>
The **isVisible** field in the [ExtensionAbilityInfo](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/ExtensionAbilityInfo.d.ts) struct is changed to **exported**, and the type remains unchanged.
**Adaptation Guide**<br>
Change **isVisible** to **exported** for your application.
## cl.bundlemanager.6 Changed the visible Field in the ModuleAbilityInfo Struct to exported
The **visible** field in the [ModuleAbilityInfo](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/BundlePackInfo.d.ts) struct is changed to **exported**. The type remains unchanged, indicating whether the ability can be exported and used by other abilities.
**Change Impact**<br>
The **visible** field does not take effect.
**Key API/Component Changes**<br>
The **visible** field in the [ModuleAbilityInfo](https://gitee.com/openharmony/interface_sdk-js/blob/master/api/bundleManager/BundlePackInfo.d.ts) struct is changed to **exported**, and the type remains unchanged.
**Adaptation Guide**<br>
Change **visible** to **exported** for your application.
# Resource Scheduler Subsystem Changelog
## cl.resourceschedule.workScheduler
The WorkSchedulerExtensionAbility provides a default WorkSchedulerExtensionContext.
**Change Impact**
Applications developed based on OpenHarmony4.0.5.1 and later SDK versions can use the default context attribute as the context environment of a WorkSchedulerExtension.
**Key API/Component Changes**
The context attribute is added to **@ohos.WorkSchedulerExtensionAbility.d.ts**. The **application/WorkSchedulerExtensionContext.d.ts** file is added, which is inherited from ExtensionContext.
| Module| Class| Method/Attribute/Enum/Constant| Change Type|
| -- | -- | -- | -- |
| @ohos.WorkSchedulerExtensionAbility.d.ts | WorkSchedulerExtensionAbility | context: WorkSchedulerExtensionContext; | Added|
| application/WorkSchedulerExtensionContext.d.ts | WorkSchedulerExtensionContext | - | Added|
**Adaptation Guide**
The context is obtained through a WorkSchedulerExtensionAbility child class instance.
```ts
import WorkSchedulerExtensionAbility from '@ohos.WorkSchedulerExtensionAbility';
class MyWorkSchedulerExtensionAbility extends WorkSchedulerExtensionAbility {
onWorkStart(workInfo) {
let WorkSchedulerExtensionContext = this.context; // Obtain the WorkSchedulerExtensionContext.
}
}
```
# Ability Framework Changelog
## Added the saveAppState API to cl.ability.appRecovery
The API **saveAppState (context?: UIAbilityContext): boolean;** is added.
**Change Impact**
When developing an application based on OpenHarmony 4.0.5.2 or a later SDK version, you can use **saveAppState** with the ability context specified to save the state of the specified ability.
**Key API/Component Changes**
The **saveAppState** API is added to the **@ohos.app.ability.appRecovery.d.ts** file.
| Module| Class| Method/Attribute/Enum/Constant| Change Type|
| -- | -- | -- | -- |
| @ohos.app.ability.appRecovery.d.ts | appRecovery | saveAppState(context?: UIAbilityContext): boolean; | Added|
**Adaptation Guide**
Call **saveAppState** with the UIAbility context specified to save the ability state.
```ts
import appRecovery from '@ohos.app.ability.appRecovery';
onBackground() {
hilog.info(0x0000, '[demo]', '%{public}s', 'EntryAbility onBackground');
appRecovery.saveAppState(this.context)
}
```
## Added the setRestartWant API to cl.ability.appRecovery.
The API **setRestartWant (want: Want): void;** is added.
**Change Impact**
To develop an application based on OpenHarmony 4.0.5.2 or a later SDK version, you can use **setRestartWant** to set the ability to recover.
**Key API/Component Changes**
The **setRestartWant** API is added to the **@ohos.app.ability.appRecovery.d.ts** file.
| Module| Class| Method/Attribute/Enum/Constant| Change Type|
| -- | -- | -- | -- |
| @ohos.app.ability.appRecovery.d.ts | appRecovery | setRestartWant(want: Want): void; | Added|
**Adaptation Guide**
Call **setRestartWant** to set the ability to recover.
```ts
import appRecovery from '@ohos.app.ability.appRecovery';
Button ("Start to Recover Ability")
.fontSize(40)
.fontWeight(FontWeight.Bold)
.onClick(()=> {
// set restart want
let want = {
bundleName: "ohos.samples.recovery",
abilityName: "RecoveryAbility"
};
appRecovery.setRestartWant(want);
})
```
# Pan-sensor Subsystem Changelog
## cl.vibrator Added isSupportEffect
The **isSupportEffect** API is added.
**Change Impact**
Applications developed based on OpenHarmony4.0.5.2 or a later SDK version can use **isSupportEffect** to check whether the passed effect ID is supported.
**Key API/Component Changes**
The **isSupportEffect** API is added in **@ohos.vibrator.d.ts**.
| Module| Class| Method/Attribute/Enum/Constant| Change Type|
| -- | -- | -- | -- |
| @ohos.vibrator.d.ts | vibrator | isSupportEffect(effectId: string, callback: AsyncCallback&lt;boolean&gt;): void | Added|
| @ohos.vibrator.d.ts | vibrator | isSupportEffect(effectId: string): Promise&lt;boolean&gt; | Added|
**Adaptation Guide**
Call **isSupportEffect** to check whether the passed effect ID is supported.
```ts
import vibrator from '@ohos.vibrator';
try {
// Check whether 'haptic.clock.timer' is supported.
vibrator.isSupportEffect('haptic.clock.timer', function (err, state) {
if (err) {
console.error('isSupportEffect failed, error:' + JSON.stringify(err));
return;
}
console.log('The effectId is ' + (state ? 'supported' : 'unsupported'));
if (state) {
try {
vibrator.startVibration({ // To use startVibration, you must configure the ohos.permission.VIBRATE permission.
type: 'preset',
effectId: 'haptic.clock.timer',
count: 1,
}, {
usage: 'unknown'
}, (error) => {
if(error) {
console.error('haptic.clock.timer vibrator error:' + JSON.stringify(error));
} else {
console.log('haptic.clock.timer vibrator success');
}
});
} catch (error) {
console.error('Exception in, error:' + JSON.stringify(error));
}
}
})
} catch (error) {
console.error('Exception in, error:' + JSON.stringify(error));
}
```
## cl.vibrator Added stopVibration
The **stopVibration** API is added.
**Change Impact**
Applications developed based on OpenHarmony4.0.5.2 or a later SDK version can use **stopVibration** to stop vibration in all modes.
**Key API/Component Changes**
The **stopVibration** API is added in **@ohos.vibrator.d.ts**.
| Module | Class | Method/Attribute/Enum/Constant | Change Type|
| ------------------- | -------- | -------------------------------------------------------- | -------- |
| @ohos.vibrator.d.ts | vibrator | stopVibration(callback: AsyncCallback&lt;void&gt;): void | Added |
| @ohos.vibrator.d.ts | vibrator | stopVibration(): Promise&lt;void&gt; | Added |
**Adaptation Guide**
Call **stopVibration** to stop vibration in all modes.
```ts
import vibrator from '@ohos.vibrator';
try {
// Stop vibration in all modes.
vibrator.stopVibration(function (error) {
if (error) {
console.log('error.code' + error.code + 'error.message' + error.message);
return;
}
console.log('Callback returned to indicate successful.');
})
} catch (error) {
console.info('errCode: ' + error.code + ' ,msg: ' + error.message);
}
```
# Input Method Framework Subsystem – Input Method Framework Service Changelog
## @ohos.InputMethodSubtype Change of name, label, and id
Changed the **name**, **label**, and **id** attributes since API version 9.
**Change Impact**
Applications must be adapted to the following changes.
| Name| Before Change| After Change|
| -------- | -------- | -------- |
| label | (1) Value: ID of the input method subtype.| (1) Value: Label of the input method subtype.|
| name | (1) Description: Name of the input method subtype. (2) Value: Label of the input method subtype.| (1) Description: Bundle name of the input method; (2) Value: Bundle name of the input method.|
| id | (1) Value: Bundle name of the input method.| (1) Value: ID of the input method subtype.|
**Adaptation Guide**
Update the code to adapt to the preceding changes.
# Theme Framework Subsystem – Screenlock Management Service Changelog
## cl.screenlock.1 Permission Change of isLocked and unlock
Changed the **isLocked** and **unlock** APIs to system APIs since API version 9.
You need to adapt your application based on the following information.
**Change Impact**
The JS API needs to be adapted for applications developed based on earlier versions. Otherwise, relevant functions will be affected.
- Involved APIs:
```js
function isLocked(): boolean;
function unlock(callback: AsyncCallback<boolean>): void;
function unlock():Promise<boolean>;
```
- Before change:
```js
* Checks whether the screen is currently locked.
*
* @returns Returns {@code true} if the screen is currently locked; returns {@code false} otherwise.
* @syscap SystemCapability.MiscServices.ScreenLock
* @since 9
*/
function isLocked(): boolean;
/**
* Unlock the screen.
*
* @returns Returns {@code true} if the screen is unlocked successfully; returns {@code false} otherwise.
* @throws {BusinessError} 401 - parameter error.
* @throws {BusinessError} 202 - permission verification failed, application which is not a system application uses system API.
* @throws {BusinessError} 13200002 - the screenlock management service is abnormal.
* @syscap SystemCapability.MiscServices.ScreenLock
* @systemapi Hide this for inner system use.
* @since 9
*/
function unlock(callback: AsyncCallback<boolean>): void;
/**
* Unlock the screen.
*
* @returns Returns {@code true} if the screen is unlocked successfully; returns {@code false} otherwise.
* @throws {BusinessError} 401 - parameter error.
* @throws {BusinessError} 202 - permission verification failed, application which is not a system application uses system API.
* @throws {BusinessError} 13200002 - the screenlock management service is abnormal.
* @syscap SystemCapability.MiscServices.ScreenLock
* @systemapi Hide this for inner system use.
* @since 9
*/
function unlock():Promise<boolean>;
```
- After change:
```js
* Checks whether the screen is currently locked.
*
* @returns Returns {@code true} if the screen is currently locked; returns {@code false} otherwise.
* @throws {BusinessError} 202 - permission verification failed, application which is not a system application uses system API.
* @syscap SystemCapability.MiscServices.ScreenLock
* @systemapi Hide this for inner system use.
* @since 9
*/
function isLocked(): boolean;
/**
* Unlock the screen.
*
* @returns Returns {@code true} if the screen is unlocked successfully; returns {@code false} otherwise.
* @throws {BusinessError} 401 - parameter error.
* @throws {BusinessError} 13200002 - the screenlock management service is abnormal.
* @syscap SystemCapability.MiscServices.ScreenLock
* @since 9
*/
function unlock(callback: AsyncCallback<boolean>): void;
/**
* Unlock the screen.
*
* @returns Returns {@code true} if the screen is unlocked successfully; returns {@code false} otherwise.
* @throws {BusinessError} 13200002 - the screenlock management service is abnormal.
* @syscap SystemCapability.MiscServices.ScreenLock
* @since 9
*/
function unlock():Promise<boolean>;
```
**Adaptation Guide**
Make sure the APIs are only invoked by system applications.
The code snippet is as follows:
```js
try {
let ret = screenLock.isLocked();
console.error(`Obtain whether the screen is locked successfully , ret is: ${ret}`);
} catch (error) {
console.error(`Failed to obtain whether the screen is locked, error is : ${error.code}, ${error.message}`);
}
```
```js
screenlock.unlock((err, data) => {
if (err) {
console.error(`Failed to unlock the screen, because: ${err.message}`);
return;
}
console.info(`unlock the screen successfully. result: ${data}`);
});
```
```js
screenlock.unlock().then((data) => {
console.info(`unlock the screen successfully. result: ${data}`);
}).catch((err) => {
console.error(`Failed to unlock the screen, because: ${err.message}`);
});
```
## cl.screenlock.2 Deprecation of isSecure
Deprecated the **isSecure** API since API version 9.
You need to adapt your application based on the following information.
**Change Impact**
The API can no longer be used after being deleted.
- Involved APIs:
```js
function isSecure(): boolean;
```
- Before change:
```js
function isSecure(): boolean;
```
- After change:
The API is deleted.
**Adaptation Guide**
Update the code so that the deprecated API is not used.
# Theme Framework Subsystem – Wallpaper Management Service Changelog
## cl.wallpaper.1 Permission Change of getColorsSync, getMinHeightSync, getMinWidthSync, restore, and setImage
Changed the **getColorsSync**, **getMinHeightSync**, **getMinWidthSync**, restore, and **setImage** APIs to system APIs since API version 9.
You need to adapt your application based on the following information.
**Change Impact**
The JS API needs to be adapted for applications developed based on earlier versions. Otherwise, relevant functions will be affected.
- Involved APIs:
```js
function getColorsSync(wallpaperType: WallpaperType): Array<RgbaColor>;
function getMinHeightSync(): number;
function getMinWidthSync(): number;
function restore(wallpaperType: WallpaperType, callback: AsyncCallback<void>): void;
function restore(wallpaperType: WallpaperType): Promise<void>;
function setImage(source: string | image.PixelMap, wallpaperType: WallpaperType, callback: AsyncCallback<void>): void;
function setImage(source: string | image.PixelMap, wallpaperType: WallpaperType): Promise<void>;
```
- Before change:
```js
/**
* Obtains the wallpaper colors for the wallpaper of the specified type. Returns rgbaColor type of array callback function.
* @param wallpaperType Indicates the wallpaper type.
* @returns { Array<RgbaColor> } the Array<RgbaColor> returned by the function.
* @throws {BusinessError} 401 - parameter error.
* @throws {BusinessError} 202 - permission verification failed, application which is not a system application uses system API.
* @syscap SystemCapability.MiscServices.Wallpaper
* @systemapi Hide this for inner system use.
* @since 9
*/
function getColorsSync(wallpaperType: WallpaperType): Array<RgbaColor>;
/**
* Obtains the minimum height of the wallpaper. in pixels. returns 0 if no wallpaper has been set.
* @returns { number } the number returned by the function.
* @throws {BusinessError} 202 - permission verification failed, application which is not a system application uses system API.
* @syscap SystemCapability.MiscServices.Wallpaper
* @systemapi Hide this for inner system use.
* @since 9
*/
function getMinHeightSync(): number;
/**
* Obtains the minimum width of the wallpaper. in pixels. returns 0 if no wallpaper has been set.
* @returns { number } the number returned by the function.
* @throws {BusinessError} 202 - permission verification failed, application which is not a system application uses system API.
* @syscap SystemCapability.MiscServices.Wallpaper
* @systemapi Hide this for inner system use.
* @since 9
*/
function getMinWidthSync(): number;
/**
* Removes a wallpaper of the specified type and restores the default one.
* @param wallpaperType Indicates the wallpaper type.
* @throws {BusinessError} 401 - parameter error.
* @throws {BusinessError} 201 - permission denied.
* @throws {BusinessError} 202 - permission verification failed, application which is not a system application uses system API.
* @permission ohos.permission.SET_WALLPAPER
* @syscap SystemCapability.MiscServices.Wallpaper
* @systemapi Hide this for inner system use.
* @since 9
*/
function restore(wallpaperType: WallpaperType, callback: AsyncCallback<void>): void;
/**
* Removes a wallpaper of the specified type and restores the default one.
* @param wallpaperType Indicates the wallpaper type.
* @throws {BusinessError} 401 - parameter error.
* @throws {BusinessError} 201 - permission denied.
* @throws {BusinessError} 202 - permission verification failed, application which is not a system application uses system API.
* @permission ohos.permission.SET_WALLPAPER
* @syscap SystemCapability.MiscServices.Wallpaper
* @systemapi Hide this for inner system use.
* @since 9
*/
function restore(wallpaperType: WallpaperType): Promise<void>;
/**
* Sets a wallpaper of the specified type based on the uri path from a JPEG or PNG file or the pixel map of a PNG file.
* @param source Indicates the uri path from a JPEG or PNG file or the pixel map of the PNG file.
* @param wallpaperType Indicates the wallpaper type.
* @throws {BusinessError} 401 - parameter error.
* @throws {BusinessError} 201 - permission denied.
* @throws {BusinessError} 202 - permission verification failed, application which is not a system application uses system API.
* @permission ohos.permission.SET_WALLPAPER
* @syscap SystemCapability.MiscServices.Wallpaper
* @systemapi Hide this for inner system use.
* @since 9
*/
function setImage(source: string | image.PixelMap, wallpaperType: WallpaperType, callback: AsyncCallback<void>): void;
/**
* Sets a wallpaper of the specified type based on the uri path from a JPEG or PNG file or the pixel map of a PNG file.
* @param source Indicates the uri path from a JPEG or PNG file or the pixel map of the PNG file.
* @param wallpaperType Indicates the wallpaper type.
* @throws {BusinessError} 401 - parameter error.
* @throws {BusinessError} 201 - permission denied.
* @throws {BusinessError} 202 - permission verification failed, application which is not a system application uses system API.
* @permission ohos.permission.SET_WALLPAPER
* @syscap SystemCapability.MiscServices.Wallpaper
* @systemapi Hide this for inner system use.
* @since 9
*/
function setImage(source: string | image.PixelMap, wallpaperType: WallpaperType): Promise<void>;
```
- After change:
```js
/**
* Obtains the wallpaper colors for the wallpaper of the specified type. Returns rgbaColor type of array callback function.
* @param wallpaperType Indicates the wallpaper type.
* @returns { Array<RgbaColor> } the Array<RgbaColor> returned by the function.
* @throws {BusinessError} 401 - parameter error.
* @syscap SystemCapability.MiscServices.Wallpaper
* @since 9
*/
function getColorsSync(wallpaperType: WallpaperType): Array<RgbaColor>;
/**
* Obtains the minimum height of the wallpaper. in pixels. returns 0 if no wallpaper has been set.
* @returns { number } the number returned by the function.
* @syscap SystemCapability.MiscServices.Wallpaper
* @since 9
*/
function getMinHeightSync(): number;
/**
* Obtains the minimum width of the wallpaper. in pixels. returns 0 if no wallpaper has been set.
* @returns { number } the number returned by the function.
* @syscap SystemCapability.MiscServices.Wallpaper
* @since 9
*/
function getMinWidthSync(): number;
/**
* Removes a wallpaper of the specified type and restores the default one.
* @param wallpaperType Indicates the wallpaper type.
* @throws {BusinessError} 401 - parameter error.
* @throws {BusinessError} 201 - permission denied.
* @permission ohos.permission.SET_WALLPAPER
* @syscap SystemCapability.MiscServices.Wallpaper
* @since 9
*/
function restore(wallpaperType: WallpaperType, callback: AsyncCallback<void>): void;
/**
* Removes a wallpaper of the specified type and restores the default one.
* @param wallpaperType Indicates the wallpaper type.
* @throws {BusinessError} 401 - parameter error.
* @throws {BusinessError} 201 - permission denied.
* @permission ohos.permission.SET_WALLPAPER
* @syscap SystemCapability.MiscServices.Wallpaper
* @since 9
*/
function restore(wallpaperType: WallpaperType): Promise<void>;
/**
* Sets a wallpaper of the specified type based on the uri path from a JPEG or PNG file or the pixel map of a PNG file.
* @param source Indicates the uri path from a JPEG or PNG file or the pixel map of the PNG file.
* @param wallpaperType Indicates the wallpaper type.
* @throws {BusinessError} 401 - parameter error.
* @throws {BusinessError} 201 - permission denied.
* @permission ohos.permission.SET_WALLPAPER
* @syscap SystemCapability.MiscServices.Wallpaper
* @since 9
*/
function setImage(source: string | image.PixelMap, wallpaperType: WallpaperType, callback: AsyncCallback<void>): void;
/**
* Sets a wallpaper of the specified type based on the uri path from a JPEG or PNG file or the pixel map of a PNG file.
* @param source Indicates the uri path from a JPEG or PNG file or the pixel map of the PNG file.
* @param wallpaperType Indicates the wallpaper type.
* @throws {BusinessError} 401 - parameter error.
* @throws {BusinessError} 201 - permission denied.
* @permission ohos.permission.SET_WALLPAPER
* @syscap SystemCapability.MiscServices.Wallpaper
* @since 9
*/
function setImage(source: string | image.PixelMap, wallpaperType: WallpaperType): Promise<void>;
```
**Adaptation Guide**
Make sure the APIs are only invoked by system applications.
The code snippet is as follows:
```js
try {
let colors = wallpaper.getColorsSync(wallpaper.WallpaperType.WALLPAPER_SYSTEM);
console.log(`success to getColorsSync: ${JSON.stringify(colors)}`);
} catch (error) {
console.error(`failed to getColorsSync because: ${JSON.stringify(error)}`);
}
```
```js
let minHeight = wallpaper.getMinHeightSync();
```
```js
let minWidth = wallpaper.getMinWidthSync();
```
```js
wallpaper.restore(wallpaper.WallpaperType.WALLPAPER_SYSTEM, (error) => {
if (error) {
console.error(`failed to restore because: ${JSON.stringify(error)}`);
return;
}
console.log(`success to restore.`);
});
```
```js
wallpaper.restore(wallpaper.WallpaperType.WALLPAPER_SYSTEM).then(() => {
console.log(`success to restore.`);
}).catch((error) => {
console.error(`failed to restore because: ${JSON.stringify(error)}`);
});
```
```js
// The source type is string.
let wallpaperPath = "/data/data/ohos.acts.aafwk.plrdtest.form/files/Cup_ic.jpg";
wallpaper.setImage(wallpaperPath, wallpaper.WallpaperType.WALLPAPER_SYSTEM, (error) => {
if (error) {
console.error(`failed to setImage because: ${JSON.stringify(error)}`);
return;
}
console.log(`success to setImage.`);
});
```
```js
// The source type is string.
let wallpaperPath = "/data/data/ohos.acts.aafwk.plrdtest.form/files/Cup_ic.jpg";
wallpaper.setImage(wallpaperPath, wallpaper.WallpaperType.WALLPAPER_SYSTEM).then(() => {
console.log(`success to setImage.`);
}).catch((error) => {
console.error(`failed to setImage because: ${JSON.stringify(error)}`);
});
```
## cl.wallpaper.2 Deprecation of getIdSync, getFileSync, isChangeAllowed, isUserChangeAllowed, on, off, and RgbaColor
Deprecated the **getIdSync**, **getFileSync**, **isChangeAllowed**, **isUserChangeAllowed**, **on**, **off**, and **RgbaColor** APIs since API version 9.
You need to adapt your application based on the following information.
**Change Impact**
The APIs can no longer be used after being deleted.
- Involved APIs:
```js
function getIdSync(wallpaperType: WallpaperType): number;
function getFileSync(wallpaperType: WallpaperType): number;
function isChangeAllowed(): boolean;
function isUserChangeAllowed(): boolean;
function on(type: 'colorChange', callback: (colors: Array<RgbaColor>, wallpaperType: WallpaperType) => void): void;
function off(type: 'colorChange', callback?: (colors: Array<RgbaColor>, wallpaperType: WallpaperType) => void): void;
interface RgbaColor {
red: number;
green: number;
blue: number;
alpha: number;
}
```
- Before change:
```js
function getIdSync(wallpaperType: WallpaperType): number;
function getFileSync(wallpaperType: WallpaperType): number;
function isChangeAllowed(): boolean;
function isUserChangeAllowed(): boolean;
function on(type: 'colorChange', callback: (colors: Array<RgbaColor>, wallpaperType: WallpaperType) => void): void;
function off(type: 'colorChange', callback?: (colors: Array<RgbaColor>, wallpaperType: WallpaperType) => void): void;
interface RgbaColor {
red: number;
green: number;
blue: number;
alpha: number;
}
```
- After change:
The APIs are deleted.
**Adaptation Guide**
Update the code so that the deprecated APIs are not used.
# ArkUI Subsystem Changelog
## cl.arkui.1 Change in the Default Scrollbar State of \<List> and \<Gird> Components
Changed the default state of the scrollbar in the **\<List>** and **\<Gird>** components from **BarState.Off** to **BarState.Auto**.
**Change Impact**
In the scenario where the scrollbar status is not set in the **\<List>** and **\<Gird>** components:
- Before change:
The scrollbar is not displayed.
- After change:
The scrollbar is displayed during scrolling and is hidden 2 seconds after the scrolling stops.
**Key API/Component Changes**
**scrollBar** attribute of the **\<List>** and **\<Gird>** components:
- [List](../../../application-dev/reference/arkui-ts/ts-container-list.md#attributes)
- [Grid](../../../application-dev/reference/arkui-ts/ts-container-grid.md#attributes)
**Adaptation Guide**
In scenarios where the scrollbar is not required, set the **scrollBar** attribute of the **\<List>** and **\<Gird>** components to **BarState.Off**.
The code snippet is as follows:
```ts
// xxx.ets
@Entry
@Component
struct ListItemExample {
private arr: number[] = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9]
build() {
Column() {
List({ space: 20, initialIndex: 0 }) {
ForEach(this.arr, (item) => {
ListItem() {
Text('' + item)
.width('100%').height(100).fontSize(16)
.textAlign(TextAlign.Center).borderRadius(10).backgroundColor(0xFFFFFF)
}
}, item => item)
}
.width('90%')
.scrollBar(BarState.Off)
}.width('100%').height('100%').backgroundColor(0xDCDCDC).padding({ top: 5 })
}
}
```
# HUKS Changelog
## cl.huks.1 Change of the Permission for Using attestKeyItem
The **attestKeyItem** interface attests a key using a public key encapsulated based on the device certificate chain. Any arbitrary export of the device certificate increases the risks on user privacy. Therefore, certain permissions are required for using this interface.
**Change Impact**
Applications without the **ohos.permission.ACCESS_IDS** permission or the system_basic or system_core permission cannot call **attestKeyItem()**.
**Key API/Component Changes**
- Involved APIs:
attestKeyItem(keyAlias: string, options: HuksOptions, callback: AsyncCallback\<HuksReturnResult\>): void;
attestKeyItem(keyAlias: string, options: HuksOptions): Promise\<HuksReturnResult\>;
- Before change:
The AccessToken permission is verified only for the applications that pass in a tag related to **ATTESTATION_ID**.
- After change:
**attestKeyItem()** can be called only by a system application with the system_basic or system_core permission or an application with the **ohos.permission.ACCESS_IDS** permission.
**Adaptation Guide**
Applications with the system_basic or system_core permission can call **attestKeyItem()**. If an application with the normal permission needs to call **attestKeyItem()**, it must have the **ohos.permission.ACCESS_IDS** permission. For details about how to apply for the permission, see [ACL](../../../application-dev/security/accesstoken-overview.md#acl).
# Web Subsystem Changelog
Compared with earlier versions, OpenHarmony 4.0.6.1 has the following API changes in its web subsystem:
## cl.web.1 Parameters in createWebMessagePorts
Added an optional parameter to the **WebMessagePort** API to accommodate more data types.
**Change Impact**
None (The added parameter is optional, and the API is forward compatible.)
**Key API/Component Changes**
- Involved APIs:
createWebMessagePorts(): Array\<WebMessagePort>;
- Before change:
```ts
createWebMessagePorts(): Array<WebMessagePort>;
```
- After change:
```ts
createWebMessagePorts(isExtentionType?: boolean): Array<WebMessagePort>;
```
**Adaptation Guide**
N/A
# USB Subsystem API Changelog
## cl.usb_manager.1 SDK API Deletion
For applications developed based on earlier versions, you need to change the name of the imported bundle. Otherwise, the original service logic will be affected.
**Key API/Component Changes**
The **@ohos.usbV9.d.ts** file is replaced by the **@ohos.usbManager.d.ts** file.
| New Bundle | Original Bundle | Deleted Bundle |
| -------------------- | ------------- | --------------- |
| ohos.usbManager.d.ts | ohos.usb.d.ts | ohos.usbV9.d.ts |
You need to import **@ohos.usbManager** to use USB service APIs.
```ts
import usbManager from '@ohos.usbManager';
```
**Adaptation Guide**
For details about usage of each API, see the [API Reference](../../../application-dev/reference/apis/js-apis-usbManager.md).
# Globalization Subsystem Changelog
## cl.resourceManager.1 Addition of getStringSync and getStringByNameSync APIs
Added the **getStringSync** and **getStringByNameSync** APIs and error codes to obtain and format strings.
| Bundle Name | API |
| --------------- | ---------------------------------------------------- |
| ohos.resourceManager.d.ts | getStringSync(resId: number, ...args: Array<string \| number>): string; |
| ohos.resourceManager.d.ts | getStringSync(resource: Resource, ...args: Array<string \| number>): string; |
| ohos.resourceManager.d.ts | getStringByNameSync(resName: string, ...args: Array<string \| number>): string; |
**Change Impact**
In versions earlier than 4.0.6.2, only the values of string resources can be directly obtained. In 4.0.6.2 or later, the values of string resources can be formatted based on the input arguments for enhanced query.
The following error codes are added:
9001007 If the resource obtained by resId formatting error.
9001008 If the resource obtained by resName formatting error.
**Sample Code**
The following uses **getStringSync** as an example. Before the change, only example 1 is supported. After the change, both example 1 and example 2 are supported.
```
Example 1:
try {
this.context.resourceManager.getStringSync($r('app.string.test').id);
} catch (error) {
console.error(`getStringSync failed, error code: ${error.code}, message: ${error.message}.`)
}
Example 2:
try {
this.context.resourceManager.getStringSync($r('app.string.test').id, "format string", 787, 98.78);
} catch (error) {
console.error(`getStringSync failed, error code: ${error.code}, message: ${error.message}.`)
}
```
**Adaptation Guide**
For details, see the API reference.
[API Reference](../../../application-dev/reference/apis/js-apis-resource-manager.md)
[Error Codes](../../../application-dev/reference/errorcodes/errorcode-resource-manager.md)
# ArkUI Subsystem Changelog
Fixed the issue where the layout of child components in the [\<Stack>](../../../application-dev/reference/arkui-ts/ts-container-stack.md) container does not follow the **alignContent** settings when the child components do not fit in the container.
Example:
```ts
@Entry
@Component
struct StackExample {
build() {
Stack({alignContent:Alignment.TopEnd}){
Text('First child, show in bottom')
.width(200).height(200).backgroundColor(0xd2cab3).margin(10)
}.width(150).height(150).backgroundColor(Color.Pink).margin(100)
}
}
```
Before: Child components are not arranged based on **alignContent:Alignment.TopEnd**.
![stack](figures/stack_before.jpg)
After: Child components are arranged based on **alignContent:Alignment.TopEnd**.
![stack](figures/stack_after.jpg)
**Change Impact**
The previous workaround – setting the **Offset** or **translate** attribute – needs to be removed.
**Adaptation Guide**
Remove the **Offset** and **translate** settings for the child components and use **alignContent** for layout.
# HUKS Changelog
## cl.huks.1 HUKS Supports RsaPssSaltLengthType
Before the change, the HUKS uses **RSA_PSS_SALT_LEN_MAX** for signing or signature verification by default.
After the change, the type defined by **HuksRsaPssSaltLenType** is passed in for signature or signature verification. If **HuksRsaPssSaltLenType** is not passed in, **RSA_PSS_SALT_LEN_MAX** is used by default.
**Change Impact**
Behaviors of released JavaScript APIs have been changed.
**Key API/Component Changes**
Released JavaScript APIs remain unchanged, but the parameter set passed to the APIs are changed.
**Adaptation Guide**
The following uses RSA signing as an example.
```js
import huks from '@ohos.security.huks';
let keyAlias = 'rsa_Key';
let inData = new Uint8Array(
0x4B, 0x1E, 0x22, 0x64, 0xA9, 0x89, 0x60, 0x1D, 0xEC, 0x78, 0xC0, 0x5D, 0xBE, 0x46, 0xAD, 0xCF,
0x1C, 0x35, 0x16, 0x11, 0x34, 0x01, 0x4E, 0x9B, 0x7C, 0x00, 0x66, 0x0E, 0xCA, 0x09, 0xC0, 0xF3,
);
/* Parameters for signing */
let signProperties = new Array();
signProperties[0] = {
tag: huks.HuksTag.HUKS_TAG_ALGORITHM,
value: huks.HuksKeyAlg.HUKS_ALG_RSA,
}
signProperties[1] = {
tag: huks.HuksTag.HUKS_TAG_PURPOSE,
value:
huks.HuksKeyPurpose.HUKS_KEY_PURPOSE_SIGN
}
signProperties[2] = {
tag: huks.HuksTag.HUKS_TAG_KEY_SIZE,
value: huks.HuksKeySize.HUKS_RSA_KEY_SIZE_2048,
}
signProperties[3] = {
tag: huks.HuksTag.HUKS_TAG_PADDING,
value: huks.HuksKeyPadding.HUKS_PADDING_PSS,
}
signProperties[4] = {
tag: huks.HuksTag.HUKS_TAG_DIGEST,
value: huks.HuksKeyDigest.HUKS_DIGEST_SHA1,
}
signProperties[5] = {
tag: huks.HuksTag.HUKS_TAG_RSA_PSS_SALT_LEN_TYPE,
value: huks.HuksRsaPssSaltLenType.HUKS_RSA_PSS_SALT_LEN_MAX,
}
let signOptions = {
properties: signProperties,
inData: inData
}
huks.initSession(keyAlias, signOptions);
```
For more information, see [HUKS Development](../../../application-dev/security/huks-guidelines.md) and [HUKS](../../../application-dev/reference/apis/js-apis-huks.md).
## cl.huks.2 Resolved the Issues in Storage or Export of Derived or Agreed Keys
Before the change, the HUKS supports storage and export of derived keys and agreed keys, which poses security risks.
After the change, the application needs to pass in **HuksKeyStorageType** for key derivation or key agreement. Only storage or export is allowed at a time. If this parameter is not passed in, both storage and export are supported by default, which poses security risks and is not recommended.
**Change Impact**
Behaviors of released JavaScript APIs have been changed.
**Key API/Component Changes**
Released JavaScript APIs remain unchanged, but the parameter set passed to the APIs are changed.
**Adaptation Guide**
For more information, see [HUKS Development](../../../application-dev/security/huks-guidelines.md) and [HUKS](../../../application-dev/reference/apis/js-apis-huks.md).
## cl.huks.3 Adding Tags for Fine-grained User Identity Access Control
Added **HUKS_TAG_KEY_AUTH_PURPOSE** to **HuksTag** for fine-grained user identity access control. This tag specifies the user identity authentication used for specific algorithm.
**Change Impact**
The new HuksTag does not affect existing APIs.
**Key API/Component Changes**
**HuksTag** is added with **HUKS_TAG_KEY_AUTH_PURPOSE** to support fine-grained user identity access control.
**Adaptation Guide**
For more information, see [Fine-grained User Identity Authentication](../../../application-dev/security/huks-guidelines.md#fine-grained-user-identity-authentication) and [HuksTag](../../../application-dev/reference/apis/js-apis-huks.md#hukstag).
# Resource Scheduler Subsystem Changelog
## cl.resourceschedule.reminderAgent.1
The reminder agent allows you to customize buttons for system applications. Clicking a custom button will redirect you to the specified application page.
**Change Impact**
For system applications developed based on OpenHarmony 4.0.7.1 and later SDK versions, you can set custom buttons for reminders.
**Key API/Component Changes**
| Module| Class| Method/Attribute/Enum/Constant| Change Type|
| -- | -- | -- | -- |
| reminderAgentManager | ActionButtonType | ACTION_BUTTON_TYPE_CUSTOM = 2 | Added|
| reminderAgentManager | ActionButton | wantAgent?: WantAgent | Added|
| reminderAgentManager | WantAgent | uri?: string | Added|
| reminderAgentManager | ReminderRequest | actionButton?: [ActionButton?, ActionButton?, ActionButton?] | Changed|
**Adaptation Guide**
```ts
import reminderAgentManager from '@ohos.reminderAgentManager';
let targetReminderAgent: reminderAgentManager.ReminderRequestAlarm = {
reminderType: reminderAgentManager.ReminderType.REMINDER_TYPE_ALARM, // The reminder type is alarm clock.
...
actionButton: [
{
title: 'Remind later',
type: reminderAgentManager.ActionButtonType.ACTION_BUTTON_TYPE_SNOOZE
},
{
title: 'Close',
type: reminderAgentManager.ActionButtonType.ACTION_BUTTON_TYPE_CLOSE
},
{
title: 'Custom',
type: reminderAgentManager.ActionButtonType.ACTION_BUTTON_TYPE_CUSTOM,
wantAgent: {
pkgName: "com.example.myapplication",
abilityName: "EntryAbility",
}
},
]
}
```
## cl.resourceschedule.reminderAgent.2
The reminder agent allows you to set reminders to automatically disappear at the given time.
**Change Impact**
For system applications developed based on OpenHarmony 4.0.7.1 and later SDK versions, you can set the reminders to disappear automatically.
**Key API/Component Changes**
| Module| Class| Method/Attribute/Enum/Constant| Change Type|
| -- | -- | -- | -- |
| reminderAgentManager | ReminderRequest | tapDismissed?: boolean | Added|
| reminderAgentManager | ReminderRequest | autoDeletedTime?: number | Added|
**Adaptation Guide**
```ts
import reminderAgentManager from '@ohos.reminderAgentManager';
let targetReminderAgent: reminderAgentManager.ReminderRequestAlarm = {
reminderType: reminderAgentManager.ReminderType.REMINDER_TYPE_ALARM, // The reminder type is alarm clock.
...
tapDismissed: true,
autoDeletedTime: 300,
}
```
# ArkUI Subsystem Changelog
### Restrictions on Using Decorators
#### 1. Restrictions on Using Component Decorators
Component decorators @Component, @Entry, @Preview, and @CustomDialog apply only to structs, not classes.
**Example**
```
@Component
// ERROR:The '@Component' decorator can only be used with 'struct'.
class Index {
build() {
}
}
```
**Change Impact**
If @Component, @Entry, @Preview, or @CustomDialog is used to decorate components other than structs, a compile time error will occur.
**Key API/Component Changes**
N/A
**Adaptation Guide**
Use @Component, @Entry, @Preview, and @CustomDialog to decorate only structs.
#### 2. Restrictions on Using Component Member Variable Decorators
Component member variable decorators @State, @Prop, @Link, @Provide, @Consume, @ObjectLink, @StorageLink, @StorageProp, @LocalStorageLink, @LocalStorageProp, @Watch, and @BuilderParam can decorate only the member variables of structs.
**Example**
```
@Component
class Index {
// ERROR: The '@State' decorator can only be used with 'struct'.
@State message: string = 'Hello world'
build() {
}
}
```
**Change Impact**
If any of the aforementioned component member variable decorators is used to decorate a member variable of components other than structs, a compile time error will occur.
**Key API/Component Changes**
N/A
**Adaptation Guide**
Use the aforementioned component member variable decorators to decorate only the member variables of structs.
# Multi-language Runtime Subsystem Changelog
## cl.arkcompiler.1 New Alarms and Existing Alarm Enhancements for LLVM
**Change Impact**
By default, the **-Werror** option is disabled for the OpenHarmony NDK. If you have enabled the **-Werror** option, you are advised to correct the code based on the suggestions in the check result or mask the errors.
**Changes in Key Compilation Check Rules**
| New Check Item| Description| Suggestion|
| --- | --- | --- |
| Wunused-but-set-variable | An alarm is generated when the code contains unused variables (including the ++ operator).| Add the **maybe_unused** attribute when defining variables or use macros to distinguish variables.|
| Wdeprecated-non-prototype | An alarm is generated when a function without a prototype exists in the code.| Add a function prototype and specify the parameters.|
| Wunqualified-std-cast-call | An alarm is generated when **std::move** is incorrectly used in code.| Specify the use case of **std::move** and check the code.|
| Wdeprecated-builtins | An alarm is generated when a deprecated built-in function is used in the code.| Use the substitute function.|
| Warray-parameter | An alarm is generated when a function parameter contains an array that uses inconsistent forms.| Ensure the consistency of the function parameter.|
| Wbitwise-instead-of-logical | An alarm is generated when bitwise OR is used in Boolean operations.| Use logical OR in Boolean operations.|
| Wint-conversion | An alarm is generated when an int variable is converted to a pointer in the code.| Use a new implementation mode in the code.|
| Wdeprecated-declarations | An alarm is generated when a deprecated definition (including functions and variables) is used in code.| Use a new implementation mode in the code.|
| Wnull-pointer-subtraction | An alarm is generated when a null pointer is used in the subtraction operation.| Do not a null pointer in the subtraction operation.|
| Wunused-but-set-parameter | An alarm is generated when a function contains unused parameters.| Delete unused parameters.|
| Warray-bounds | An alarm is generated when out-of-bounds access to an array occurs in the code.| Modify the out-of-bounds access.|
| Wdeprecated-pragma | An alarm is generated when a deprecated macro is used in the code.| Delete the deprecated macro.|
| Wreserved-identifier | An alarm is generated when a variable starting with __ is used in the code.| Check the code to prevent variables starting with underscores (_) from being used externally.|
**Adaptation Guide**
1. For issues in the code that are not detected by LLVM 12, check and update the code.
2. Some old implementations are discarded during LLVM update. Adapt to the new rules and update the code.
3. If you believe a certain type of error can be masked, use the **-Wno-xxx** option to mask the error.
Defective code example
```
void Heap::Resume(TriggerGCType gcType)
{
if (mode_ != HeapMode::SPAWN &&
activeSemiSpace_->AdjustCapacity(inactiveSemiSpace_->GetAllocatedSizeSinceGC())) {
// If activeSpace capacity changes, oldSpace maximumCapacity should change too.
size_t multiple = 2;
// oldSpaceMaxLimit is assigned a value but is not used.
size_t oldSpaceMaxLimit = 0;
if (activeSemiSpace_->GetInitialCapacity() >= inactiveSemiSpace_->GetInitialCapacity()) {
size_t delta = activeSemiSpace_->GetInitialCapacity() - inactiveSemiSpace_->GetInitialCapacity();
oldSpaceMaxLimit = oldSpace_->GetMaximumCapacity() - delta * multiple;
} else {
size_t delta = inactiveSemiSpace_->GetInitialCapacity() - activeSemiSpace_->GetInitialCapacity();
oldSpaceMaxLimit = oldSpace_->GetMaximumCapacity() + delta * multiple;
}
inactiveSemiSpace_->SetInitialCapacity(activeSemiSpace_->GetInitialCapacity());
}
// irrelated code ...
}
```
The oldSpaceMaxLimit variable is not used, and the compiler reports an alarm.
```
../../arkcompiler/ets_runtime/ecmascript/mem/heap.cpp:247:16: error: variable 'oldSpaceMaxLimit' set but not used [-Werror,-Wunused-but-set-variable]
size_t oldSpaceMaxLimit = 0;
```
The error is rectified after the attribute is added.
```
void Heap::Resume(TriggerGCType gcType)
{
if (mode_ != HeapMode::SPAWN &&
activeSemiSpace_->AdjustCapacity(inactiveSemiSpace_->GetAllocatedSizeSinceGC())) {
// If activeSpace capacity changes, oldSpace maximumCapacity should change too.
size_t multiple = 2;
// Add the maybe_unused attribute and declare that the variable oldSpaceMaxLimit may not be used.
[[maybe_unused]] size_t oldSpaceMaxLimit = 0;
if (activeSemiSpace_->GetInitialCapacity() >= inactiveSemiSpace_->GetInitialCapacity()) {
size_t delta = activeSemiSpace_->GetInitialCapacity() - inactiveSemiSpace_->GetInitialCapacity();
oldSpaceMaxLimit = oldSpace_->GetMaximumCapacity() - delta * multiple;
} else {
size_t delta = inactiveSemiSpace_->GetInitialCapacity() - activeSemiSpace_->GetInitialCapacity();
oldSpaceMaxLimit = oldSpace_->GetMaximumCapacity() + delta * multiple;
}
inactiveSemiSpace_->SetInitialCapacity(activeSemiSpace_->GetInitialCapacity());
}
// irrelated code ...
}
```
## cl.arkcompiler.2 LLVM Parsing Format Changed
**Change Impact**
When your code depends on the **version-script** or **-gcc-toolchain** option, parsing may fail if you continue to use the original LLVM 12 configuration file or options.
**Changes in Key Compilation Rules**
1. The symbol representation is changed. In the new version, consecutive greater signs (>) are represented as ">>", which was represented as "> >" in the old version.
2. The -xx options are deprecated. For example, the **-gcc-toolchain** option is replaced by the **--gcc-toolchain** option. (This option has been marked as deprecated in versions later than Clang 3.4 and is officially deprecated in LLVM15.)
**Adaptation Guide**
If two consecutive greater signs (>) exist in the code (without considering the number of spaces in the middle), they will be parsed as "> >" in the older version and ">>" in the new version in version-script (due to mangling differences). In LLVM15, ">>" must be used.
Original configuration file
```
{
global:
extern "C++" {
"google::protobuf::TextFormat::ParseFromString(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, google::protobuf::Message*)";
// In LLVM 12, "> >" can be parsed, but ">>" cannot.
"google::protobuf::TextFormat::PrintToString(google::protobuf::Message const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >*)";
};
local:
*;
}
```
Modified configuration file
```
{
global:
extern "C++" {
"google::protobuf::TextFormat::ParseFromString(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, google::protobuf::Message*)";
// In LLVM 15, ">>" can be parsed.
"google::protobuf::TextFormat::PrintToString(google::protobuf::Message const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>*)";
};
local:
*;
}
```
## cl.arkcompiler.3 LLVM emu-tls Changed
**Change Impact**
If you use both LLVM 12 and LLVM 15 (this behavior is prohibited) for your code, the emu-tls symbol cannot be found in libc++.so.
**Key Library Dependency Changes**
In LLVM 15, the emu-tls symbol is extracted from the target binary file to libc++.so. That is, the __emutls_get_address attribute changes from an internal symbol to an externally visible symbol, which is included in libc++.so. As a result, the compiled dynamic library may depend on libc++.so.
**Adaptation Guide**
This symbol is also in libclang_rt.builtin.a. If you do not want the compiled dynamic library to depend on libc++.so, statically link the libclang_rt.builtin.a library.
## cl.arkcompiler.4 LLVM Official Release Notes
**Change Impact**
New features are added and internal interfaces are changed (such as IR in LLVM and compiler front-end modification). For details, see the official release notes.
**Key Documents**
https://releases.llvm.org/13.0.0/docs/ReleaseNotes.html
https://releases.llvm.org/14.0.0/docs/ReleaseNotes.html
https://releases.llvm.org/15.0.0/docs/ReleaseNotes.html
**Adaptation Guide**
For details about the updates and adaptation guide, see the official documents.
# Web Subsystem Changelog
Compared with earlier versions, OpenHarmony 4.0.7.3 has the following API changes in its web subsystem:
## cl.web.1 New Input Parameter Type of the setResponseData API
Added the input parameter type **Resource** for the **setResponseData** API.
**Change Impact**
In the scenario where a HAP file is not decompressed, the file path in the HAP does not exist. Under this scenario, to access resources in the HAP file, you must use the input parameter **data:Resource** instead of **data:number**.
**Key API/Component Changes**
- Involved APIs:
setResponseData
- Before change:
```ts
setResponseData(data: string | number)
```
- After change:
```ts
setResponseData(data: string | number | Resource)
```
**Adaptation Guide**
When a HAP file is decompressed, open the hold the FD of the target resource file, and then transfer the resource response data to the kernel through **setResponseData(data:number)**.
```ts
// xxx.ets
import web_webview from '@ohos.web.webview'
import fileio from '@ohos.fileio';
@Entry
@Component
struct WebComponent {
controller: web_webview.WebviewController = new web_webview.WebviewController()
responseweb: WebResourceResponse = new WebResourceResponse()
heads: Header[] = new Array()
build() {
Column() {
Web({ src: 'www.example.com', controller: this.controller })
.onInterceptRequest((event) => {
console.log('url:' + event.request.getRequestUrl())
var head1:Header = {
headerKey:"Connection",
headerValue:"keep-alive"
}
var head2:Header = {
headerKey:"Cache-Control",
headerValue:"no-cache"
}
var length = this.heads.push(head1)
length = this.heads.push(head2)
this.responseweb.setResponseHeader(this.heads)
this.responseweb.setResponseEncoding('utf-8')
this.responseweb.setResponseMimeType('text/html')
this.responseweb.setResponseCode(200)
this.responseweb.setReasonMessage('OK')
//// fd scheme --start
// '/xxx/.../test.html' is the local path of the file.
// @ts-ignore
let fd = fileio.openSync('/xxx/.../test.html', 0o102, 0o666)
this.responseweb.setResponseData(fd)
//// fd scheme --end
return this.responseweb
})
}
}
}
```
When a HAP file is decompressed, the file path in the HAP does not exist. In this case, transfer the resource response data to the kernel through **setResponseData(data:Resource)**.
```ts
// xxx.ets
import web_webview from '@ohos.web.webview'
@Entry
@Component
struct WebComponent {
controller: web_webview.WebviewController = new web_webview.WebviewController()
responseweb: WebResourceResponse = new WebResourceResponse()
heads: Header[] = new Array()
build() {
Column() {
Web({ src: 'www.example.com', controller: this.controller })
.onInterceptRequest((event) => {
console.log('url:' + event.request.getRequestUrl())
var head1:Header = {
headerKey:"Connection",
headerValue:"keep-alive"
}
var head2:Header = {
headerKey:"Cache-Control",
headerValue:"no-cache"
}
var length = this.heads.push(head1)
length = this.heads.push(head2)
this.responseweb.setResponseHeader(this.heads)
this.responseweb.setResponseEncoding('utf-8')
this.responseweb.setResponseMimeType('text/html')
this.responseweb.setResponseCode(200)
this.responseweb.setReasonMessage('OK')
//// Resource scheme --start
// Specify the target file in the rawfile directory of the HAP file.
this.responseweb.setResponseData($rawfile('test.html'))
//// Resource scheme --end
return this.responseweb
})
}
}
}
```
# ArkUI Subsystem Changelog
## cl.arkui.1 Change in the \<Button> Component Hover Effect
Changed the hover effect of the **\<Button>** component from scale-up by 100% to 105% to overlay of 0% to 5% opacity, and the pressed effect to overlay of 5% to 10% opacity.
**Change Impact**
The visual effect of the **\<Button>** component is affected.
## cl.arkui.2 Change in the Multi-line Text Alignment Mode of Toasts
Changed the alignment mode of multi-line text in toasts from center-aligned to left-aligned.
**Change Impact**
The visual effect of toasts is affected.
## cl.arkui.3 Change in \<SideBarContainer> Component Attributes and Display Modes
1. Added the **minContentWidth** attribute, whose default value is **360vp**. If this attribute is not set, the value **0vp** is used. If this attribute is set to a value less than 0, the default value is used. In Embed mode, when the component size is increased, only the content area is enlarged; when the component size is decreased, the content area is shrunk until its width reaches the value defined by **minContentWidth**, and then the sidebar is shrunk until its width reaches the value defined by **minSideBarWidth**; if the component size is further decreased, while respecting the minimum width of the sidebar, the content area is further shrunk, with the content clipped, until it is 0 vp large. **minContentWidth**, whether it is specified or kept at the default value, takes precedence over **minSideBarWidth** and **sideBarWidth** of the sidebar.
2. Changed the default value of **minSideBarWidth** and **SideBarWidth** to **200vp** in API version 9 and earlier versions, and **240vp** in API version 10.
3. Added the Auto display mode. The sidebar is displayed in Embed mode when the component size is greater than or equal to the sum of **minSideBarWidth** and **minContentWidth** and in Overlay mode otherwise. If **minSideBarWidth** or **minContentWidth** is not set, the default value will be used for calculation. If the calculation result is less than 600 vp, 600 vp will be used as the breakpoint value for mode switching.
**Change Impact**
The default visual effect of the **\<SideBarContainer>** component is affected in API version 10.
# ArkCompiler Subsystem Changelog
## cl.ArkCompiler.1 type compileMode uses es2abc by default
The composition of ArkCompiler in sdk has ts2abc compiler and es2abc compiler, supporting compilation of ets/ts/js files.<br>
Compilation Mode Introduction:<br>
&emsp;Non-type compilation: convert ets/ts sourceCode into js sourceCode, and use ArkCompiler compiler es2abc to generate bytecode. <br>
&emsp;type compilation: convert ets/ts sourceCode into ts sourceCode, and use ArkCompiler compiler ts2abc (previous version)/es2abc (enabled in this version) to generate bytecode. <br>
Application Project hvigor version:<br>
&emsp;hvigorVersion field and @ohos/hvigor-ohos-plugin field in dependencies of hvigor-config.json5 file in the hvigor directory of the application project.<br>
Enable type compilation:<br>
&emsp;When the hvigor version is greater than or equal to 2.6.0-rc.9.s, the type compilation mode is used by default, or in the build-profile.json5 file of the same level directory as the application sourceCode (src directory), configure the "aotCompileMode": "type" option under the buildOption tag<br>
When type compilation is enabled and this version of the SDK is used, the ArkCompiler compiler es2abc will be used by default to compile the ts sourceCode to generate bytecode, and it is not recommended to use the old version SDK with ts2abc enabled for type compilation.<br>
**Change Impact**<br>
With DevEco Studio development, after the type compilation mode is enabled and the new version of the SDK is used, due to the change of the compilation mode and the change of the ArkCompiler compiler, application compilation failures and runtime crashes may occur.<br>
**Key API/Component Changes**<br>
type compileMode uses arkcompiler frontend compiler es2abc by default<br>
**Adaptation Guide**
1. When the hvigor version is greater than or equal to 2.6.0-rc.9.s, the developer needs to configure "aotCompileMode": "" in the build-profile.json5 file to switch to the original compilation mode (not type).
# ArkUI Subsystem Changelog
## cl.arkui.1 Change of Certain Predicates of uiAppearance from Public APIs to System APIs
Changed the namespace **uiAppearance** and its internal **DarkMode** enum predicates from public APIs to system APIs.
**Change Impact**
None. The namespace **uiAppearance** and its internal **DarkMode** enum are used only by system APIs before and after the change.
**Key API/Component Changes**
The system API description is added to the following APIs:
- declare namespace uiAppearance
- enum DarkMode
- ALWAYS_DARK = 0
- ALWAYS_LIGHT = 1
# Distributed Data Management Subsystem Changelog
## cl.distributeddatamgr.1 Changed ValuesBucket to a Public Interface
**Change Impact**
For applications developed based on earlier versions, only system applications can use **ValuesBucket**. From this version, **ValuesBucket** can be called by third-party applications.
**Key API/Component Changes**
Before change:
```ts
/**
* Indicates possible value types
*
* @syscap SystemCapability.DistributedDataManager.DataShare.Core
* @systemapi
* @StageModelOnly
* @since 9
*/
export type ValueType = number | string | boolean;
```
After change:
```ts
/**
* Indicates possible value types
*
* @syscap SystemCapability.DistributedDataManager.DataShare.Core
* @StageModelOnly
* @since 10
*/
export type ValueType = number | string | boolean;
}
```
## cl.distributeddatamgr.2 Changed Some Predicate Interfaces in dataSharePredicates to Public Interfaces
**Change Impact**
For applications developed based on earlier versions, only system applications can use **dataSharePredicates**. From this version, on, the namespace **dataSharePredicates**, **dataSharePredicates** class, and some predicate interfaces can be called by third-party applications.
**Key API/Component Changes**
The involved interfaces are as follows:
- equalTo(field: string, value: ValueType): DataSharePredicates
- and(): DataSharePredicates
- orderByAsc(field: string): DataSharePredicates
- orderByDesc(field: string): DataSharePredicates
- limit(total: number, offset: number): DataSharePredicates
- in(field: string, value: Array<ValueType>): DataSharePredicates
# ArkUI Subsystem Changelog
## cl.arkui.1 Restrictions on Data Type Declarations of State Variables
The data types of state variables decorated by state decorators must be explicitly declared. They cannot be declared as **any**.
**Example**
```ts
// xxx.ets
@Entry
@Component
struct DatePickerExample {
// Incorrect: @State isLunar: any = false
@State isLunar: boolean = false
build() {
...
}
}
```
**Change Impacts**
If the data type of a state variable decorated by a state decorator is declared as **any**, a WARN-level (previously ERROR-level) build error will occur.
```ts
// ArkTS:ERROR Please define an explicit type, not any.
@State isLunar: any = false
```
**Key API/Component Changes**
N/A
**Adaptation Guide**
Explicitly declare the data type for state variables decorated by state decorators.
## cl.arkui.2 Initialization Rules and Restrictions of Custom Components' Member Variables
**@LocalStorageLink** and **@LocalStorageProp** variables cannot be initialized from the parent component.
**Example**
```ts
let NextID: number = 0;
@Observed
class ClassA {
public id: number;
public c: number;
constructor(c: number) {
this.id = NextID++;
this.c = c;
}
}
@Entry
@Component
struct LocalStorageComponent {
build() {
Column() {
Child({
/* ArkTS:ERROR Property 'simpleVarName' in the custom component 'Child' cannot
initialize here (forbidden to specify). */
simpleVarName: 1,
/* ArkTS:ERROR Property 'objectName' in the custom component 'Child' cannot
initialize here (forbidden to specify). */
objectName: new ClassA(1)
})
}
}
}
@Component
struct Child {
@LocalStorageLink("storageSimpleProp") simpleVarName: number = 0;
@LocalStorageProp("storageObjectProp") objectName: ClassA = new ClassA(1);
build() {
}
}
```
**Change Impacts**
If **@LocalStorageLink** and **@LocalStorageProp** variables are initialized from the parent component, a WARN-level (previously ERROR-level) build error will occur.
**Key API/Component Changes**
N/A
**Adaptation Guide**
When building a child component, do not assign values to the variables by **@LocalStorageLink** and **@LocalStorageProp** in the child component.
To change these variables from the parent component, use the API provided by the **LocalStorage** (such as the **set** API) to assign values to them.
## cl.arkui.3 Change of the bottom Definition in Toast Options in the PromptAction Module
Changed the definition of the **bottom** attribute in toast options from distance between the top of the toast and the bottom of the screen to distance between the bottom of the toast and the bottom of the screen.
**Example**
```ts
import promptAction from '@ohos.promptAction';
@Entry
@Component
struct Index {
build() {
Row() {
Button()
.onClick(() => {
try {
promptAction.showToast({
message: 'Message Info',
duration: 2000
});
} catch (error) {
console.error(`showToast args error code is ${error.code}, message is ${error.message}`);
};
})
}
}
}
```
**Change Impacts**
In the **PromptAction** module, the same value for the **bottom** attribute may result in different toast appearances, depending on whether the API version used by the compiler is earlier than 10 or not.
**Key API/Component Changes**
N/A
**Adaptation Guide**
When setting the **bottom** attribute, account for the definition change.
## cl.arkui.4 Content Layout Change of AlertDialog
The content layout of the alert dialog box varies according to the following conditions: 1. whether there is a title. 2. whether the text is on a single line.
Currently, only the single-line text without a title is centered. In other cases, the text is left-aligned.
**Example**
```ts
// xxx.ets
@Entry
@Component
struct AlertDialogExample {
build() {
Column({ space: 5 }) {
Button('one button dialog')
.onClick(() => {
AlertDialog.show(
{
title: 'title',
message: 'text'.repeat(20),
autoCancel: true,
alignment: DialogAlignment.Bottom,
offset: { dx: 0, dy: -20 },
gridCount: 3,
confirm: {
value: 'button',
action: () => {
console.info('Button-clicking callback')
}
},
cancel: () => {
console.info('Closed callbacks')
}
}
)
})
.backgroundColor(0x317aff)
}.width('100%').margin({ top: 5 })
}
}
```
**Change Impacts**
The layout for the text specified by the **message** attribute of the alert dialog box is subject to the title and number of lines of the text.
**Key API/Component Changes**
N/A
**Adaptation Guide**
No proactive adaptation is required. You can also use **customDialog** for related implementation.
## cl.arkui.5 Avoidance Behavior Optimization of Popup
Before the change, the popup preferentially uses the lower area for avoidance. As a result, it cannot be displayed in the upper area even if the space is sufficient.
After the change: The popup preferentially uses the upper area for avoidance when it is configured to show above the target component; it preferentially uses the upper or lower area for avoidance when it is configured to show below the target component.
**Change Impacts**
The optimized popup avoidance behavior occurs when the **bindpopup** attribute is used.
**Key API/Component Changes**
N/A
**Adaptation Guide**
If the popup position is not as expected, you can adjust the **placement** settings.
# Distributed Data Management Subsystem Changelog
## cl.datashare.1 Change of the data Type in PublishedItem from Ashmem to ArrayBuffer
**Change Impact**
Changed the type of **data** in **PublishedItem** from Ashmem to ArrayBuffer.
## PublishedItem<sup>10+</sup>
Defines the data to publish.
**System capability**: SystemCapability.DistributedDataManager.DataShare.Consumer
| Name| Type| Mandatory| Description|
| -------- | -------- | -------- | -------- |
| key | string | Yes| Key of the data to publish.|
| data | string \| ArrayBuffer | Yes| Data to publish. If a large volume of data is to be published, use **data** of the ArrayBuffer type. |
| subscriberId | string | Yes| Subscriber ID.|
**Adaptation Guide**
The sample code is as follows:
**Example**
```ts
let arrayBuffer = new ArrayBuffer(1);
let version = 1;
let data : Array<dataShare.PublishedItem> = [{key:"key2", subscriberId:"11", data:arrayBuffer}];
function publishCallback(err, result: Array<dataShare.OperationResult>) {
console.info("publishCallback " + JSON.stringify(result));
}
try {
console.info("data length is:", data.length);
dataShareHelper.publish(data, "com.acts.ohos.data.datasharetest", version, publishCallback);
} catch (e) {
console.error("publish error " + JSON.stringify(e));
}
```
# Device Management Changelog
## cl.device_manager.1 API Permission Change
Added permission verification for some APIs.
**Change Impact**
Applications developed in versions later than OpenHarmony 4.0.8.2 must have the specific permission to call the APIs.
**Key API/Component Changes**
| Module | Class | Method/Attribute/Enum/Constant | New Permission|
| ------------------------- | ------------------- | ------------------------------------------------------------ | -------- |
| @ohos.distributedHardware.deviceManager | deviceManager | **function** release(): void | ohos.permission.ACCESS_SERVICE_DM |
| @ohos.distributedHardware.deviceManager | deviceManager | **function** getTrustedDeviceListSync(): Array&lt;DeviceInfo&gt; | ohos.permission.ACCESS_SERVICE_DM |
| @ohos.distributedHardware.deviceManager | deviceManager | **function** getTrustedDeviceListSync(isRefresh: boolean): Array&lt;DeviceInfo&gt;; | ohos.permission.ACCESS_SERVICE_DM |
| @ohos.distributedHardware.deviceManager | deviceManager | **function** getTrustedDeviceList(callback:AsyncCallback&lt;Array&lt;DeviceInfo&gt;&gt;): void | ohos.permission.ACCESS_SERVICE_DM |
| @ohos.distributedHardware.deviceManager | deviceManager | **function** getTrustedDeviceList(): Promise&lt;Array&lt;DeviceInfo&gt;&gt; | ohos.permission.ACCESS_SERVICE_DM |
| @ohos.distributedHardware.deviceManager | deviceManager | **function** getLocalDeviceInfoSync(): DeviceInfo | ohos.permission.ACCESS_SERVICE_DM |
| @ohos.distributedHardware.deviceManager | deviceManager | **function** getLocalDeviceInfo(callback:AsyncCallback&lt;DeviceInfo&gt;): void | ohos.permission.ACCESS_SERVICE_DM |
| @ohos.distributedHardware.deviceManager | deviceManager | **function** getLocalDeviceInfo(): Promise&lt;DeviceInfo&gt; | ohos.permission.ACCESS_SERVICE_DM |
| @ohos.distributedHardware.deviceManager | deviceManager | **function** getDeviceInfo(networkId: string, callback:AsyncCallback&lt;DeviceInfo&gt;): void | ohos.permission.ACCESS_SERVICE_DM |
| @ohos.distributedHardware.deviceManager | deviceManager | **function** getDeviceInfo(networkId: string): Promise&lt;DeviceInfo&gt; | ohos.permission.ACCESS_SERVICE_DM |
| @ohos.distributedHardware.deviceManager | deviceManager | **function** startDeviceDiscovery(subscribeInfo: SubscribeInfo): void | ohos.permission.ACCESS_SERVICE_DM |
| @ohos.distributedHardware.deviceManager | deviceManager | **function** startDeviceDiscovery(subscribeInfo: SubscribeInfo, filterOptions?: string): void | ohos.permission.ACCESS_SERVICE_DM |
| @ohos.distributedHardware.deviceManager | deviceManager | **function** stopDeviceDiscovery(subscribeId: number): void | ohos.permission.ACCESS_SERVICE_DM |
| @ohos.distributedHardware.deviceManager | deviceManager | **function** publishDeviceDiscovery(publishInfo: PublishInfo): void | ohos.permission.ACCESS_SERVICE_DM |
| @ohos.distributedHardware.deviceManager | deviceManager | **function** unPublishDeviceDiscovery(publishId: number): void | ohos.permission.ACCESS_SERVICE_DM |
| @ohos.distributedHardware.deviceManager | deviceManager | **function** authenticateDevice(deviceInfo: DeviceInfo, authParam: AuthParam, callback: AsyncCallback&lt;{deviceId: string, pinToken ?: number}&gt;): void | ohos.permission.ACCESS_SERVICE_DM |
| @ohos.distributedHardware.deviceManager | deviceManager | **function** unAuthenticateDevice(deviceInfo: DeviceInfo): void | ohos.permission.ACCESS_SERVICE_DM |
| @ohos.distributedHardware.deviceManager | deviceManager | **function** verifyAuthInfo(authInfo: AuthInfo, callback: AsyncCallback&lt;{deviceId: string, level: number}&gt;): void | ohos.permission.ACCESS_SERVICE_DM |
| @ohos.distributedHardware.deviceManager | deviceManager | **function** setUserOperation(operateAction: number, params: string): void | ohos.permission.ACCESS_SERVICE_DM |
| @ohos.distributedHardware.deviceManager | deviceManager | **function** requestCredentialRegisterInfo(requestInfo: string, callback: AsyncCallback&lt;{registerInfo: string}&gt;): void; | ohos.permission.ACCESS_SERVICE_DM |
| @ohos.distributedHardware.deviceManager | deviceManager | **function** importCredential(credentialInfo: string, callback: AsyncCallback&lt;{resultInfo: string}&gt;): void; | ohos.permission.ACCESS_SERVICE_DM |
| @ohos.distributedHardware.deviceManager | deviceManager | **function** deleteCredential(queryInfo: string, callback: AsyncCallback&lt;{resultInfo: string}&gt;): void; | ohos.permission.ACCESS_SERVICE_DM |
| @ohos.distributedHardware.deviceManager | deviceManager | **function** on(type: 'uiStateChange', callback: Callback&lt;{ param: string}&gt;): void; | ohos.permission.ACCESS_SERVICE_DM |
| @ohos.distributedHardware.deviceManager | deviceManager | **function** off(type: 'uiStateChange', callback?: Callback&lt;{ param: string}&gt;): void; | ohos.permission.ACCESS_SERVICE_DM |
| @ohos.distributedHardware.deviceManager | deviceManager | **function** on(type: 'deviceStateChange', callback: Callback&lt;{ action: DeviceStateChangeAction, device: DeviceInfo }&gt;): void | ohos.permission.ACCESS_SERVICE_DM |
| @ohos.distributedHardware.deviceManager | deviceManager | **function** off(type: 'deviceStateChange', callback?: Callback&lt;{ action: DeviceStateChangeAction, device: DeviceInfo }&gt;): void | ohos.permission.ACCESS_SERVICE_DM |
| @ohos.distributedHardware.deviceManager | deviceManager | **function** on(type: 'deviceFound', callback: Callback&lt;{ subscribeId: number, device: DeviceInfo }&gt;): void | ohos.permission.ACCESS_SERVICE_DM |
| @ohos.distributedHardware.deviceManager | deviceManager | **function** off(type: 'deviceFound', callback?: Callback&lt;{ subscribeId: number, device: DeviceInfo }&gt;): void | ohos.permission.ACCESS_SERVICE_DM |
| @ohos.distributedHardware.deviceManager | deviceManager | **function** on(type: 'discoverFail', callback: Callback&lt;{ subscribeId: number, reason: number }&gt;): void | ohos.permission.ACCESS_SERVICE_DM |
| @ohos.distributedHardware.deviceManager | deviceManager | **function** off(type: 'discoverFail', callback?: Callback&lt;{ subscribeId: number, reason: number }&gt;): void | ohos.permission.ACCESS_SERVICE_DM |
| @ohos.distributedHardware.deviceManager | deviceManager | **function** on(type: 'publishSuccess', callback: Callback&lt;{ publishId: number }&gt;): void | ohos.permission.ACCESS_SERVICE_DM |
| @ohos.distributedHardware.deviceManager | deviceManager | **function** off(type: 'publishSuccess', callback?: Callback&lt;{ publishId: number }&gt;): void | ohos.permission.ACCESS_SERVICE_DM |
| @ohos.distributedHardware.deviceManager | deviceManager | **function** on(type: 'publishFail', callback: Callback&lt;{ publishId: number, reason: number }&gt;): void | ohos.permission.ACCESS_SERVICE_DM |
| @ohos.distributedHardware.deviceManager | deviceManager | **function** off(type: 'publishFail', callback?: Callback&lt;{ publishId: number, reason: number }&gt;): void | ohos.permission.ACCESS_SERVICE_DM |
| @ohos.distributedHardware.deviceManager | deviceManager | **function** on(type: 'serviceDie', callback: () =&gt; void): void | ohos.permission.ACCESS_SERVICE_DM |
| @ohos.distributedHardware.deviceManager | deviceManager | **function** off(type: 'serviceDie', callback?: () =&gt; void): void | ohos.permission.ACCESS_SERVICE_DM |
**Adaptation Guide**
Apply for the corresponding permission to call these APIs.
## cl.device_manager.2 Permission Verification for All System APIs
Added permission verification for all system APIs.
**Change Impact**
Non-system applications and applications without system API permission cannot call system APIs.
**Key API/Component Changes**
System API permission verification is performed on all APIs. The table below describes the APIs.
| API/Enum/Variable| Type| Is System API|
| -------- | -------- | ------- |
| createDeviceManager(bundleName: string, callback: AsyncCallback&lt;DeviceManager&gt;): void; | interface | Yes|
| release(): void | interface | Yes|
| getTrustedDeviceListSync(): Array&lt;DeviceInfo&gt; | interface | Yes|
| getTrustedDeviceListSync(isRefresh: boolean): Array&lt;DeviceInfo&gt;; | interface | Yes|
| getTrustedDeviceList(callback:AsyncCallback&lt;Array&lt;DeviceInfo&gt;&gt;): void | interface | Yes|
| getTrustedDeviceList(): Promise&lt;Array&lt;DeviceInfo&gt;&gt; | interface | Yes|
| getLocalDeviceInfoSync(): DeviceInfo | interface | Yes|
| getLocalDeviceInfo(callback:AsyncCallback&lt;DeviceInfo&gt;): void | interface | Yes|
| getLocalDeviceInfo(): Promise&lt;DeviceInfo&gt; | interface | Yes|
| getDeviceInfo(networkId: string, callback:AsyncCallback&lt;DeviceInfo&gt;): void | interface | Yes|
| getDeviceInfo(networkId: string): Promise&lt;DeviceInfo&gt; | interface | Yes|
| startDeviceDiscovery(subscribeInfo: SubscribeInfo): void | interface | Yes|
| startDeviceDiscovery(subscribeInfo: SubscribeInfo, filterOptions?: string): void | interface | Yes|
| stopDeviceDiscovery(subscribeId: number): void | interface | Yes|
| publishDeviceDiscovery(publishInfo: PublishInfo): void | interface | Yes|
| unPublishDeviceDiscovery(publishId: number): void | interface | Yes|
| authenticateDevice(deviceInfo: DeviceInfo, authParam: AuthParam, callback: AsyncCallback&lt;{deviceId: string, pinToken ?: number}&gt;): void |interface | Yes|
| unAuthenticateDevice(deviceInfo: DeviceInfo): void | interface | Yes|
| verifyAuthInfo(authInfo: AuthInfo, callback: AsyncCallback&lt;{deviceId: string, level: number}&gt;): void | interface | Yes|
| setUserOperation(operateAction: number, params: string): void | interface | Yes|
| requestCredentialRegisterInfo(requestInfo: string, callback: AsyncCallback&lt;{registerInfo: string}&gt;): void; | interface | Yes|
| importCredential(credentialInfo: string, callback: AsyncCallback&lt;{resultInfo: string}&gt;): void; | interface | Yes|
| deleteCredential(queryInfo: string, callback: AsyncCallback&lt;{resultInfo: string}&gt;): void; | interface | Yes|
| on(type: 'uiStateChange', callback: Callback&lt;{ param: string}&gt;): void; | interface | Yes|
| off(type: 'uiStateChange', callback?: Callback&lt;{ param: string}&gt;): void; | interface | Yes|
| on(type: 'deviceStateChange', callback: Callback&lt;{ action: DeviceStateChangeAction, device: DeviceInfo }&gt;): void | interface | Yes|
| off(type: 'deviceStateChange', callback?: Callback&lt;{ action: DeviceStateChangeAction, device: DeviceInfo }&gt;): void | interface | Yes|
| on(type: 'deviceFound', callback: Callback&lt;{ subscribeId: number, device: DeviceInfo }&gt;): void | interface | Yes|
| off(type: 'deviceFound', callback?: Callback&lt;{ subscribeId: number, device: DeviceInfo }&gt;): void | interface | Yes|
| on(type: 'discoverFail', callback: Callback&lt;{ subscribeId: number, reason: number }&gt;): void | interface | Yes|
| off(type: 'discoverFail', callback?: Callback&lt;{ subscribeId: number, reason: number }&gt;): void | interface | Yes|
| on(type: 'publishSuccess', callback: Callback&lt;{ publishId: number }&gt;): void | interface | Yes|
| off(type: 'publishSuccess', callback?: Callback&lt;{ publishId: number }&gt;): void | interface | Yes|
| on(type: 'publishFail', callback: Callback&lt;{ publishId: number, reason: number }&gt;): void | interface | Yes|
| off(type: 'publishFail', callback?: Callback&lt;{ publishId: number, reason: number }&gt;): void | interface | Yes|
| on(type: 'serviceDie', callback: () =&gt; void): void | interface | Yes|
| off(type: 'serviceDie', callback?: () =&gt; void): void | interface | Yes|
**Adaptation Guide**
Make sure the caller of the preceding APIs is a system application or an application that has the system API permission.
# Distributed Data Management Subsystem Changelog
## cl.distributeddatamgr.1 Replacement of context with a context Without the Optional Identifier
**Change Impact**
For applications developed based on earlier versions, use SDK API version 10 when **context** is used.
**Key API/Component Changes**
Deleted the following:
```ts
/**
* Indicates datashare extension ability context.
*
* @type ?{ ExtensionContext }
* @syscap SystemCapability.DistributedDataManager.DataShare.Provider
* @systemapi
* @StageModelOnly
* @since 9
*/
context?: ExtensionContext;
```
Added the following:
```ts
/**
* Indicates datashare extension ability context.
*
* @type { ExtensionContext }
* @syscap SystemCapability.DistributedDataManager.DataShare.Provider
* @systemapi
* @StageModelOnly
* @since 10
*/
context: ExtensionContext;
```
## cl.distributeddatamgr.2 Change of the Return Value Type of Function Pointer Variables in the OH_Predicates Struct from OH_Predicates to OH_Predicates *
**Change Impact**
This change is incompatible with earlier versions. You need to use the new function pointer variables in the **OH_Predicates** struct.
**Key API/Component Changes**
Before the change:
```ts
OH_Predicates (*equalTo)(OH_Predicates *predicates, const char *field, OH_VObject *valueObject);
OH_Predicates (*notEqualTo)(OH_Predicates *predicates, const char *field, OH_VObject *valueObject);
OH_Predicates (*beginWrap)(OH_Predicates *predicates);
OH_Predicates (*endWrap)(OH_Predicates *predicates);
OH_Predicates (*orOperate)(OH_Predicates *predicates);
OH_Predicates (*andOperate)(OH_Predicates *predicates);
OH_Predicates (*isNull)(OH_Predicates *predicates, const char *field);
OH_Predicates (*isNotNull)(OH_Predicates *predicates, const char *field);
OH_Predicates (*like)(OH_Predicates *predicates, const char *field, OH_VObject *valueObject);
OH_Predicates (*between)(OH_Predicates *predicates, const char *field, OH_VObject *valueObject);
OH_Predicates (*notBetween)(OH_Predicates *predicates, const char *field, OH_VObject *valueObject);
OH_Predicates (*greaterThan)(OH_Predicates *predicates, const char *field, OH_VObject *valueObject);
OH_Predicates (*lessThan)(OH_Predicates *predicates, const char *field, OH_VObject *valueObject);
OH_Predicates (*greaterThanOrEqualTo)(OH_Predicates *predicates, const char *field, OH_VObject *valueObject);
OH_Predicates (*lessThanOrEqualTo)(OH_Predicates *predicates, const char *field, OH_VObject *valueObject);
OH_Predicates (*orderBy)(OH_Predicates *predicates, const char *field, OH_OrderType type);
OH_Predicates (*distinct)(OH_Predicates *predicates);
OH_Predicates (*limit)(OH_Predicates *predicates, unsigned int value);
OH_Predicates (*offset)(OH_Predicates *predicates, unsigned int rowOffset);
OH_Predicates (*groupBy)(OH_Predicates *predicates, char const *const *fields, int length);
OH_Predicates (*in)(OH_Predicates *predicates, const char *field, OH_VObject *valueObject);
OH_Predicates (*notIn)(OH_Predicates *predicates, const char *field, OH_VObject *valueObject);
OH_Predicates (*clear)(OH_Predicates *predicates);
```
After the change:
```ts
OH_Predicates *(*equalTo)(OH_Predicates *predicates, const char *field, OH_VObject *valueObject);
OH_Predicates *(*notEqualTo)(OH_Predicates *predicates, const char *field, OH_VObject *valueObject);
OH_Predicates *(*beginWrap)(OH_Predicates *predicates);
OH_Predicates *(*endWrap)(OH_Predicates *predicates);
OH_Predicates *(*orOperate)(OH_Predicates *predicates);
OH_Predicates *(*andOperate)(OH_Predicates *predicates);
OH_Predicates *(*isNull)(OH_Predicates *predicates, const char *field);
OH_Predicates *(*isNotNull)(OH_Predicates *predicates, const char *field);
OH_Predicates *(*like)(OH_Predicates *predicates, const char *field, OH_VObject *valueObject);
OH_Predicates *(*between)(OH_Predicates *predicates, const char *field, OH_VObject *valueObject);
OH_Predicates *(*notBetween)(OH_Predicates *predicates, const char *field, OH_VObject *valueObject);
OH_Predicates *(*greaterThan)(OH_Predicates *predicates, const char *field, OH_VObject *valueObject);
OH_Predicates *(*lessThan)(OH_Predicates *predicates, const char *field, OH_VObject *valueObject);
OH_Predicates *(*greaterThanOrEqualTo)(OH_Predicates *predicates, const char *field, OH_VObject *valueObject);
OH_Predicates *(*lessThanOrEqualTo)(OH_Predicates *predicates, const char *field, OH_VObject *valueObject);
OH_Predicates *(*orderBy)(OH_Predicates *predicates, const char *field, OH_OrderType type);
OH_Predicates *(*distinct)(OH_Predicates *predicates);
OH_Predicates *(*limit)(OH_Predicates *predicates, unsigned int value);
OH_Predicates *(*offset)(OH_Predicates *predicates, unsigned int rowOffset);
OH_Predicates *(*groupBy)(OH_Predicates *predicates, char const *const *fields, int length);
OH_Predicates *(*in)(OH_Predicates *predicates, const char *field, OH_VObject *valueObject);
OH_Predicates *(*notIn)(OH_Predicates *predicates, const char *field, OH_VObject *valueObject);
OH_Predicates *(*clear)(OH_Predicates *predicates);
```
**Adaptation Guide**
The sample code is as follows:
Sample code before the change:
```
predicates->beginWrap(predicates).equalTo(predicates, "data1", valueObject).orOperate(predicates);
```
Sample code after the change:
```
predicates->beginWrap(predicates)->equalTo(predicates, "data1", valueObject)->orOperate(predicates);
```
## cl.distributeddatamgr.3 Change of the Error Codes in the OH_Rdb_ErrCode Struct
**Change Impact**
Changed **RDB_ERR_INVALID_ARGS** to **RDB_E_INVALID_ARGS**, and **RDB_ERR_OK** to **RDB_OK**, and added error codes.
**Key API/Component Changes**
Before the change:
```ts
RDB_ERR_INVALID_ARGS = -2,
RDB_ERR = -1,
RDB_ERR_OK = 0
```
After the change:
```ts
RDB_ERR = -1,
RDB_OK = 0,
E_BASE = 14800000,
RDB_E_NOT_SUPPORTED = 801,
RDB_E_ERROR = E_BASE,
RDB_E_INVALID_ARGS = (E_BASE + 1),
RDB_E_CANNOT_UPDATE_READONLY = (E_BASE + 2),
RDB_E_REMOVE_FILE = (E_BASE + 3),
RDB_E_EMPTY_TABLE_NAME = (E_BASE + 5),
RDB_E_EMPTY_VALUES_BUCKET = (E_BASE + 6),
RDB_E_EXECUTE_IN_STEP_QUERY = (E_BASE + 7),
RDB_E_INVALID_COLUMN_INDEX = (E_BASE + 8),
RDB_E_INVALID_COLUMN_TYPE = (E_BASE + 9),
RDB_E_EMPTY_FILE_NAME = (E_BASE + 10),
RDB_E_INVALID_FILE_PATH = (E_BASE + 11),
RDB_E_TRANSACTION_IN_EXECUTE = (E_BASE + 12),
RDB_E_INVALID_STATEMENT = (E_BASE + 13),
RDB_E_EXECUTE_WRITE_IN_READ_CONNECTION = (E_BASE + 14),
RDB_E_BEGIN_TRANSACTION_IN_READ_CONNECTION = (E_BASE + 15),
RDB_E_NO_TRANSACTION_IN_SESSION = (E_BASE + 16),
RDB_E_MORE_STEP_QUERY_IN_ONE_SESSION = (E_BASE + 17),
RDB_E_NO_ROW_IN_QUERY = (E_BASE + 18),
RDB_E_INVALID_BIND_ARGS_COUNT = (E_BASE + 19),
RDB_E_INVALID_OBJECT_TYPE = (E_BASE + 20),
RDB_E_INVALID_CONFLICT_FLAG = (E_BASE + 21),
RDB_E_HAVING_CLAUSE_NOT_IN_GROUP_BY = (E_BASE + 22),
RDB_E_NOT_SUPPORTED_BY_STEP_RESULT_SET = (E_BASE + 23),
RDB_E_STEP_RESULT_SET_CROSS_THREADS = (E_BASE + 24),
RDB_E_STEP_RESULT_QUERY_NOT_EXECUTED = (E_BASE + 25),
RDB_E_STEP_RESULT_IS_AFTER_LAST = (E_BASE + 26),
RDB_E_STEP_RESULT_QUERY_EXCEEDED = (E_BASE + 27),
RDB_E_STATEMENT_NOT_PREPARED = (E_BASE + 28),
RDB_E_EXECUTE_RESULT_INCORRECT = (E_BASE + 29),
RDB_E_STEP_RESULT_CLOSED = (E_BASE + 30),
RDB_E_RELATIVE_PATH = (E_BASE + 31),
RDB_E_EMPTY_NEW_ENCRYPT_KEY = (E_BASE + 32),
RDB_E_CHANGE_UNENCRYPTED_TO_ENCRYPTED = (E_BASE + 33),
RDB_E_CHANGE_ENCRYPT_KEY_IN_BUSY = (E_BASE + 34),
RDB_E_STEP_STATEMENT_NOT_INIT = (E_BASE + 35),
RDB_E_NOT_SUPPORTED_ATTACH_IN_WAL_MODE = (E_BASE + 36),
RDB_E_CREATE_FOLDER_FAIL = (E_BASE + 37),
RDB_E_SQLITE_SQL_BUILDER_NORMALIZE_FAIL = (E_BASE + 38),
RDB_E_STORE_SESSION_NOT_GIVE_CONNECTION_TEMPORARILY = (E_BASE + 39),
RDB_E_STORE_SESSION_NO_CURRENT_TRANSACTION = (E_BASE + 40),
RDB_E_NOT_SUPPORT = (E_BASE + 41),
RDB_E_INVALID_PARCEL = (E_BASE + 42),
RDB_E_QUERY_IN_EXECUTE = (E_BASE + 43),
RDB_E_SET_PERSIST_WAL = (E_BASE + 44),
RDB_E_DB_NOT_EXIST = (E_BASE + 45),
RDB_E_ARGS_READ_CON_OVERLOAD = (E_BASE + 46),
RDB_E_WAL_SIZE_OVER_LIMIT = (E_BASE + 47),
RDB_E_CON_OVER_LIMIT = (E_BASE + 48)
```
# File Subsystem Changelog
## cl.file.1 Change of the mediaLibrary Interface Compatibility
Changed the compatibility of some **mediaLibrary** APIs.
**Change Impact**
The compatibility of some [mediaLibrary](../../../application-dev/reference/apis/js-apis-medialibrary.md) APIs is changed.
For applications developed based on earlier versions, pay attention to the iterative update of deprecated APIs.
**Key API/Component Changes**
| Module | Method/Attribute/Enum/Constant | Change Type|
| ------------------------- | ------------------------------------------------------------ | -------- |
| medialibrary | **function** getFileAssets(options: MediaFetchOptions, callback: AsyncCallback&lt;FetchFileResult&gt;): void | Interface compatibility changed |
| medialibrary | **function** getFileAssets(options: MediaFetchOptions): Promise&lt;FetchFileResult&gt; | Interface compatibility changed |
| medialibrary | **function** createAsset(mediaType: MediaType, displayName: string, relativePath: string, callback: AsyncCallback&lt;FileAsset&gt;): void| Interface compatibility changed |
| medialibrary | **function** createAsset(mediaType: MediaType, displayName: string, relativePath: string): Promise&lt;FileAsset&gt;| Interface compatibility changed |
| medialibrary | **function** getAlbums(options: MediaFetchOptions, callback: AsyncCallback&lt;Array&lt;Album&gt;&gt;): void | Interface compatibility changed |
| medialibrary | **function** getAlbums(options: MediaFetchOptions): Promise&lt;Array&lt;Album&gt;&gt; | Interface compatibility changed |
| medialibrary | **function** FileAsset.commitModify(callback: AsyncCallback&lt;void&gt;): void | Interface compatibility changed |
| medialibrary | **function** FileAsset.commitModify(): Promise&lt;void&gt; | Interface compatibility changed |
**Adaptation Guide**
**getFileAssets**
From API version 10, the albums represented by physical directories are replaced by logical albums, which allows multiple files in an album and presence of a file in multiple albums. This design, however, makes **parent**, **albumId**, **albumUri**, and **albumName** incompatible. They cannot be used as parameters of **MediaFetchOptions** in **getFileAssets()**. See the following example:
1. Use [getMediaLibrary](../../../application-dev/reference/apis/js-apis-medialibrary.md#medialibrarygetmedialibrary) to obtain a **MediaLibrary** instance.
2. Use [MediaFetchOptions](../../../application-dev/reference/apis/js-apis-medialibrary.md#mediafetchoptions7) to create the file fetching options.
3. Use [getFileAssets](../../../application-dev/reference/apis/js-apis-medialibrary.md#getfileassets7) to obtain file assets.
**Incorrect code example**:
```js
import mediaLibrary from '@ohos.multimedia.mediaLibrary';
async function example() {
try {
let context = getContext(this);
let media = mediaLibrary.getMediaLibrary(context);
let fileKeyObj = mediaLibrary.FileKey;
let albumId = 1;
let getImageOp = {
selections: fileKeyObj.ALBUM_ID + '= ?', // File assets cannot be obtained based on the parent, albumId, albumUri, and albumName attributes.
selectionArgs: [albumId.toString()],
};
const fetchFileResult = await media.getFileAssets(getImageOp); // The obtained fetchFileResult is empty.
const fileAsset = await fetchFileResult.getFirstObject();
console.info('mediaLibrary fileAsset displayName: ' + fileAsset.displayName);
} catch (err) {
console.error('mediaLibrary fail, err: ' + err);
}
}
```
Use **getFileAssets()** as follows:
**Correct code example**:
```js
import mediaLibrary from '@ohos.multimedia.mediaLibrary';
async function example() {
try {
let context = getContext(this);
let media = mediaLibrary.getMediaLibrary(context);
let fileKeyObj = mediaLibrary.FileKey;
let imageType = mediaLibrary.MediaType.IMAGE;
let getImageOp = {
selections: fileKeyObj.MEDIA_TYPE + '= ?',
selectionArgs: [imageType.toString()], // Query all files of the image type.
};
const fetchFileResult = await media.getFileAssets(getImageOp);
const fileAsset = await fetchFileResult.getFirstObject();
console.info('mediaLibrary fileAsset displayName: ' + fileAsset.displayName);
} catch (err) {
console.error('mediaLibrary fail, err: ' + err);
}
}
```
**createAsset**
From the SDK of API version 10, **relativePath** is no longer associated with an album. After a file is created, the last-level directory of **relativePath** is not displayed as an album.
**getAlbums**
From the SDK of API version 10, **relativePath** is no longer associated with an album. Therefore, **relativePath** cannot be used as a search criterion in **getAlbums**, and the values of **ALBUM_NAME** can be **Camera** and **Screenshots** only. See the following example:
1. Use [getMediaLibrary](../../../application-dev/reference/apis/js-apis-medialibrary.md#medialibrarygetmedialibrary) to obtain a **MediaLibrary** instance.
2. Use [MediaFetchOptions](../../../application-dev/reference/apis/js-apis-medialibrary.md#mediafetchoptions7) to create the album fetching options.
3. Use [getAlbums](../../../application-dev/reference/apis/js-apis-medialibrary.md#getalbums7) to obtain albums.
**Incorrect code example**:
```js
import mediaLibrary from '@ohos.multimedia.mediaLibrary';
async function example() {
try {
let context = getContext(this);
let media = mediaLibrary.getMediaLibrary(context);
let AlbumNoArgsfetchOp = {
selections: mediaLibrary.FileKey.ALBUM_NAME + ' = ?',
selectionArgs:['New album 1'], //Obtain the album named New album 1.
};
const albumList = await media.getAlbums(AlbumNoArgsfetchOp); // The fetchFileResult returned is empty.
for (let i = 0; i < albumList.length; i++) {
console.info('mediaLibrary album albumName: ' + albumList[i].albumName);
}
} catch (err) {
console.error('mediaLibrary fail, err: ' + err);
}
}
```
The following example shows how to obtain **Camera** and **Screenshots** albums:
**Correct code example**:
```js
import mediaLibrary from '@ohos.multimedia.mediaLibrary';
async function example() {
try {
let context = getContext(this);
let media = mediaLibrary.getMediaLibrary(context);
let AlbumNoArgsfetchOp = {
selections: mediaLibrary.FileKey.ALBUM_NAME + ' = ? OR ' + mediaLibrary.FileKey.ALBUM_NAME + ' = ?',
selectionArgs: ['Camera', 'Screenshots'], // Obtain the camera and screenshot albums.
};
const albumList = await media.getAlbums(AlbumNoArgsfetchOp);
for (let i = 0; i < albumList.length; i++) {
console.info('mediaLibrary album albumName: ' + albumList[i].albumName);
}
} catch (err) {
console.error('mediaLibrary fail, err: ' + err);
}
}
```
**FileAsset.commitModify**
The **orientation** attribute for audio is deleted from the SDK of API version 10. When **commitModify** is used, the **orientation** attribute of audio resources cannot be modified.
# Pan-sensor Subsystem Changelog
## cl.vibrator.1 Added Attributes Related to Custom Vibration
The attributes **VibrateFromFile** (custom vibration effect) and **HapticFileDescriptor** (file descriptor of the custom vibration configuration file) are added. The vibration effect supported by **startVibration** is extended from **VibrateEffect = VibrateTime | VibratePreset** to **VibrateEffect = VibrateTime | VibratePreset | VibrateFromFile**.
**Change Impact**
When developing applications based on OpenHarmony4.0.8.2 and later SDK versions, you can use the **VibrateFromFile** attribute to enable devices that support custom vibration to trigger vibration according to the vibration sequence configured in the custom vibration configuration file.
**Key API/Component Changes**
Added the **VibrateFromFile** and **HapticFileDescriptor** attributes to **@ohos.vibrator.d.ts**.
| Module| Class| Method/Attribute/Enum/Constant| Change Type|
| -- | -- | -- | -- |
| @ohos.vibrator.d.ts | vibrator | HapticFileDescriptor | Added|
| @ohos.vibrator.d.ts | vibrator | VibrateFromFile | Added|
**Adaptation Guide**
Obtain the resources in the vibration configuration file through the resource management API, and start or stop custom vibration as required.
```ts
import vibrator from '@ohos.vibrator';
import resourceManager from '@ohos.resourceManager';
const FILE_NAME = "xxx.json";
async function openResource(fileName) {
let fileDescriptor = undefined;
let mgr = await resourceManager.getResourceManager();
await mgr.getRawFd(fileName).then(value => {
fileDescriptor = {fd: value.fd, offset: value.offset, length: value.length};
console.log('openResource success fileName: ' + fileName);
}).catch(error => {
console.log('openResource err: ' + error);
});
return fileDescriptor;
}
async function closeResource(fileName) {
let mgr = await resourceManager.getResourceManager();
await mgr.closeRawFd(fileName).then(()=> {
console.log('closeResource success fileName: ' + fileName);
}).catch(error => {
console.log('closeResource err: ' + error);
});
}
// Obtain the file descriptor of the vibration configuration file.
let rawFd = openResource(FILE_NAME);
// To use startVibration and stopVibration, you must configure the ohos.permission.VIBRATE permission.
try {
// Start custom vibration.
vibrator.startVibration({
type: "file",
hapticFd: { fd: rawFd.fd, offset: rawFd.offset, length: rawFd.length }
}, {
usage: "alarm"
}).then(() => {
console.info('startVibration success');
}, (error) => {
console.info('startVibration error');
});
// Stop vibration in all modes.
vibrator.stopVibration(function (error) {
if (error) {
console.log('error.code' + error.code + 'error.message' + error.message);
return;
}
console.log('Callback returned to indicate successful.');
})
} catch (error) {
console.info('errCode: ' + error.code + ' ,msg: ' + error.message);
}
// Close the vibration configuration file.
closeResource(FILE_NAME);
```
# ArkUI Subsystem Changelog
## cl.arkui.1 Change in the Priority of alignContent and align Attributes for the \<Stack> Component
Changed the priority of **alignContent** and **align** as follows:
API version 9 and earlier: The universal attribute **align** prevails.
API version 10 and later: The last set attribute prevails.
When two attributes provide the same functions, the last set attribute takes effect. This rule applies to **alignContent** and **align**, both of which set the alignment mode when used for the **\<Stack>** component.
**Example**
```ts
// xxx.ets
@Entry
@Component
struct StackExample {
build() {
Stack({alignContent:Alignment.Start}){
Text("Stack's child").backgroundColor(Color.Brown).height("100").width(100)
}
.width(300).height(300)
.backgroundColor(Color.Pink)
.align(Alignment.Center)
.alignContent(Alignment.TopEnd)
}
}
```
API version 9 and earlier: Child components are arranged based on the universal attribute **align**.
![stack](figures/api9.png)
API version 10 and later: Child components are arranged based on the **alignContent** attribute, which is set at a later time than **align**.
![stack](figures/api10_and_later.png)
**Change Impact**
When both **alignContent** and **align** attributes are set, the last set attribute prevails.
## cl.arkui.2 Behavior Change of the fillText and strokeText APIs of the \<Canvas> Component
When the **fillText** and **strokeText** APIs are used to draw text, no text wrapping occurs.
**Example**
```ts
// xxx.ets
@Entry
@Component
struct FillText {
private settings: RenderingContextSettings = new RenderingContextSettings(true)
private context: CanvasRenderingContext2D = new CanvasRenderingContext2D(this.settings)
build() {
Flex({ direction: FlexDirection.Column, alignItems: ItemAlign.Center, justifyContent: FlexAlign.Center }) {
Canvas(this.context)
.width('100%')
.height('100%')
.backgroundColor('#ffff00')
.onReady(() =>{
this.context.font = '50px sans-serif'
this.context.fillText("Hello World!", 0, 100)
this.context.fillText("Hello World! This is a long string to fully show", 0, 150)
this.context.strokeText("Hello World!", 0, 250)
this.context.strokeText("Hello World! This is a long string to fully show", 0, 300)
})
}
.width('100%')
.height('100%')
}
}
```
API version 9 and earlier: When the **fillText** and **strokeText** APIs are used to draw text, the text is wrapped based on the component width.
![stack](figures/api9filltext.jpeg)
API version 10 and later: When the **fillText** and **strokeText** APIs are used to draw text, no text wrapping occurs.
![stack](figures/api10filltext.jpeg)
**Change Impact**
The text appearance is affected now that the text is not wrapped based on the component width.
# Multimedia Subsystem Changelog
## cl.multimedia.1 Reference Paths Changed for the Audio/Video Encapsulation and Decapsulation Header Files
| Header File | Original Reference Path | New Reference Path |
| ------------------------------- | ------------------------------------- | ------------------------------------- |
| native_avmuxer.h | <multimedia/native_avmuxer.h> | <multimedia/player_framework/native_avmuxer.h> |
| native_avdemuxer.h | <multimedia/native_avdemuxer.h> | <multimedia/player_framework/native_avdemuxer.h> |
| native_avsource.h | <multimedia/native_avsource.h> | <multimedia/player_framework/native_avsource.h> |
**Change Impact**
Applications that use the involved APIs may have compatibility issues.
**Adaptation Guide**
Modify the reference paths when referencing the encapsulation and decapsulation header files.
# Application Access Control Subsystem Changelog
## cl.accessToken.1 Change of the Media and Files Permission Group
The original **Media and File** permission group contains the following permissions:
- ohos.permission.MEDIA_LOCATION
- ohos.permission.READ_MEDIA
- ohos.permission.WRITE_MEDIA
Changed the permission group as follows:
- Moved **ohos.permission.MEDIA_LOCATION** to the **Images and Videos** permission group.
- Moved **ohos.permission.READ_MEDIA** and **ohos.permission.WRITE_MEDIA** to the **Documents** permission group.
**Change Impact**
The permission group rather than the permission is presented in the dialog box for requesting permissions.
- Before the change, if the three permissions are applied for an application, a dialog box for requesting the media and file permissions will be displayed only once.
- After the change, if the three permissions are applied for an application, a dialog box for requesting the **Images and Videos** permissions and a dialog box for requesting the **Documents** permission will be displayed.
**Key API/Component Changes**
Permission groups before the change:
| Permission | Permission Group |
| -------- | ---------------------------- |
| ohos.permission.MEDIA_LOCATION | Media and file|
| ohos.permission.READ_MEDIA | Media and file|
| ohos.permission.WRITE_MEDIA | Media and file|
Permission groups after the change:
| Permission | Permission Group |
| -------- | ---------------------------- |
| ohos.permission.MEDIA_LOCATION | Images and videos |
| ohos.permission.READ_MEDIA | Documents |
| ohos.permission.WRITE_MEDIA | Documents |
**Adaptation Guide**
N/A
## cl.accessToken.2 Change of the Permission Requesting Modes of the Phone, Messaging, and Call Logs Permission Groups
The **Phone**, **Messaging**, and **Call logs** permission groups contain the following permissions:
- ohos.permission.ANSWER_CALL
- ohos.permission.MANAGE_VOICEMAIL
- ohos.permission.READ_CELL_MESSAGES
- ohos.permission.READ_MESSAGES
- ohos.permission.RECEIVE_MMS
- ohos.permission.RECEIVE_SMS
- ohos.permission.RECEIVE_WAP_MESSAGES
- ohos.permission.SEND_MESSAGES
- ohos.permission.READ_CALL_LOG
- ohos.permission.WRITE_CALL_LOG
- ohos.permission.MEDIA_LOCATION
These permissions can be pre-authorized only.
**Change Impact**
Instead of requesting these permissions through a pop-up window, the system applications can obtain the permissions only in pre-authorization mode.
**Key API/Component Changes**
N/A
**Adaptation Guide**
These permissions can be pre-authorized only.
# Arkcompiler Subsystem Changelog
## cl.arkcompiler.1 -- Removing of ts2abc compiler in sdk
The composition of Arkcompiler in sdk was ts2abc compiler and es2abc compiler, supporting compilation of ets/js files. The ts2abc compiler has been removed from sdk since this version, thus it can't be used for abc file generation. Developers can view the corresponding changes in directory ets\build-tools\ets-loader\bin and directory js\build-tools\ets-loader\bin of sdk as presented in the picture below.
![stack](figures/api10_sdk_arkcompiler_component_change.png)
**Change Impacts**
After updating the sdk, developing through DevEco will not be influenced. However, if developing scripts to use ts2abc compiler for abc file generation, one should switch to es2abc compiler
**Key API/Component Changes**
The ts2abc compiler related components are removed from sdk
**Adaptation Guide**
1. For developers using DevEco for application developing, the removing of ts2abc compiler has no influence.
2. For developers writing scripts to use ts2abc compiler need to switch to es2abc compiler. Details of usage of es2abc compiler and the comparison between es2abc and ts2abc can be referred at[usage guideline of es2abc and comparison between es2abc and ts2abc](https://gitee.com/openharmony/arkcompiler_ets_frontend#%E4%BD%BF%E7%94%A8%E8%AF%B4%E6%98%8E). Assuming a.js as the target js file for compilation. For the scenario of abc generation, which is of the highest frequency, comparison of using es2abc compiler and ts2abc are present as below:
- script mode
1. es2abc: es2abc a.js --output a.abc
2. ts2abc: node --expose-gc pathToIndex/index.js a.js --output a.abc
- module mode
1. es2abc: es2abc a.js --module --output a.abc
2. ts2abc: node --expose-gc pathToIndex/index.js a.js --module --output a.abc
\ No newline at end of file
# ArkUI Subsystem Changelog
## cl.arkui.1 Support for the undefined Parameter by Universal Events
Added support for passing **undefined** as a parameter for universal events (click, touch, show/hide, key, focus, mouse, and component area change events).
**Example**
```ts
// xxx.ets
@Entry
@Component
struct Example {
build() {
Button("test")
.onClick(()=>{
console.log("click");
})
.onClick(undefined)
}
}
```
**Change Impact**
If the event callback parameter is **undefined**, the system will not respond to the configured event callback.
**Key API/Component Changes**
N/A
**Adaptation Guide**
If the event parameter is set to **undefined**, the event is disabled. Set the parameter based on the use case.
## cl.arkui.2 Initialization Requirement Change of @Prop/@BuilderParam Decorated Variables
**Example**
```ts
// xxx.ets
@Entry
@Component
struct Parent {
@State message: string = 'Parent'
build() {
Column() {
Child() // Compile time error.
}
}
}
@Component
struct Child {
@Prop message: string
build() {
Column() {
}
}
}
```
**Change Impact**
If the @Prop or @BuilderParam decorated variable is not initialized locally or initialized from its parent component, a compile time error will occur.
**Key API/Component Changes**
N/A
**Adaptation Guide**
Assign an initial value to the @Prop or @BuilderParam decorated variable or pass the value from the parent component.
## cl.arkui.3 Initial Value Requirement Change of @BuilderParam Decorated Variables
**Example**
```ts
// xxx.ets
@Builder
function builderFunction() {
Text('Hello Builder')
}
function normal () {
}
@Component
struct Index {
@BuilderParam builderParam: ()=>void = builderFunction
@BuilderParam builderParam2: ()=>void = normal // Compile time error.
build() {
Column() {
}
}
}
```
**Change Impact**
If the initial value of the @BuilderParam decorated variable is not an @Builder method, the compilation will fail.
**Key API/Component Changes**
N/A
**Adaptation Guide**
Pass in an @Builder method as the initial value of the @BuilderParam variable.
## cl.arkui.4 Type Change of the searchButton Attribute of the \<Search> Component from SearchButtonOption to SearchButtonOptions
**Change Impact**
If the **SearchButtonOption** type is explicitly used, the compilation will fail.
**Key API/Component Changes**
The type **SearchButtonOption** of the **searchButton** attribute is changed to **SearchButtonOptions**.
**Adaptation Guide**
Change **SearchButtonOption** to **SearchButtonOptions**.
# Bundle Management Subsystem Changelog
## cl.bundlemanager.1 Bottom Layer Implementation of getAllBundleInfo in @ohos.bundle.d.ts Changed
The **getAllBundleInfo** API in the **@ohos.bundle.d.ts** file is marked as deprecated. On the image with **targetAPILevel** set to API 9 or later, the returned data list is empty.
**Change Impact**
After an update to the new image version, the calling of **getAllBundleInfo** in **@ohos.bundle.d.ts** is successful. However, the returned data list is empty. To obtain the bundle information, call **getAllBundleInfo** in the **@ohos.bundle.bundleManager.d.ts** file.
**Key API/Component Changes**
The bottom-layer implementation is changed. The result value of **getAllBundleInfo** in **@ohos.bundle.d.ts** is empty.
**Adaptation Guide**
If your application uses **getAllBundleInfo** in **@ohos.bundle.d.ts**, replace it with **getAllBundleInfo** in **@ohos.bundle.bundleManager.d.ts**. For details about how to use the new API, see [API Reference](../../../application-dev/reference/apis/js-apis-bundleManager.md#bundlemanagergetallbundleinfo).
```ets
import bundleManager from '@ohos.bundle.bundleManager';
```
## cl.bundlemanager.2 Bottom Layer Implementation of getAllApplicationInfo in @ohos.bundle.d.ts Changed
The **getAllApplicationInfo** API in the **@ohos.bundle.d.ts** file is marked as deprecated. On the image with **targetAPILevel** set to API 9 or later, the returned data list is empty.
**Change Impact**
After an update to the new image version, the calling of **getAllApplicationInfo** in **@ohos.bundle.d.ts** is successful. However, the returned data list is empty. To obtain the application information, call **getAllApplicationInfo** in the **@ohos.bundle.bundleManager.d.ts** file.
**Key API/Component Changes**
The bottom-layer implementation is changed. The result value of **getAllApplicationInfo** in **@ohos.bundle.d.ts** is empty.
**Adaptation Guide**
If your application uses **getAllApplicationInfo** in **@ohos.bundle.d.ts**, replace it with **getAllApplicationInfo** in **@ohos.bundle.bundleManager.d.ts**. For details about how to use the new API, see [API Reference](../../../application-dev/reference/apis/js-apis-bundleManager.md#bundlemanagergetallapplicationinfo).
```ets
import bundleManager from '@ohos.bundle.bundleManager';
```
## cl.bundlemanager.3 Permission on getAllBundleInfo in @ohos.bundle.bundleManager.d.ts Changed
The APIs for obtaining the application list require authorization from the end user.
Therefore, the permission on **getAllBundleInfo** in **@ohos.bundle.bundleManager.d.ts** is changed to **ohos.permission.GET_INSTALLED_BUNDLE_LIST**.
**Change Impact**
After an update to the new image version, you must have the **ohos.permission.GET_INSTALLED_BUNDLE_LIST** permission when calling **getAllBundleInfo**. Otherwise, the call fails.
**Key API/Component Changes**
The permission on **getAllBundleInfo** in **@ohos.bundle.bundleManager.d.ts** is changed to **ohos.permission.GET_INSTALLED_BUNDLE_LIST**.
**Adaptation Guide**
Add the **ohos.permission.GET_INSTALLED_BUNDLE_LIST** permission to the configuration file of the application. This permission is of the **user_grant** type and is not authorized by default during application installation. You must display a dialog box to ask the permission from the user or use pre-authorization. For details about how to display a dialog box to ask for permission, see [Requesting User Authorization](../../../application-dev/security/accesstoken-guidelines.md#requesting-user-authorization). For details about how to use pre-authorization, see [Pre-authorizing user_grant Permissions](../../../application-dev/security/accesstoken-guidelines.md#pre-authorizing-user_grant-permissions).
## cl.bundlemanager.4 Permission on getAllApplicationInfo in @ohos.bundle.bundleManager.d.ts Changed
The APIs for obtaining the application list require authorization from the end user.
Therefore, the permission on **getAllApplicationInfo** in **@ohos.bundle.bundleManager.d.ts** is changed to **ohos.permission.GET_INSTALLED_BUNDLE_LIST**.
**Change Impact**
After an update to the new image version, you must have the **ohos.permission.GET_INSTALLED_BUNDLE_LIST** permission when calling **getAllApplicationInfo**. Otherwise, the call fails.
**Key API/Component Changes**
The permission on **getAllApplicationInfo** in **@ohos.bundle.bundleManager.d.ts** is changed to **ohos.permission.GET_INSTALLED_BUNDLE_LIST**.
**Adaptation Guide**
Add the **ohos.permission.GET_INSTALLED_BUNDLE_LIST** permission to the configuration file of the application. This permission is of the **user_grant** type and is not authorized by default during application installation. You must display a dialog box to ask the permission from the user or use pre-authorization. For details about how to display a dialog box to ask for permission, see [Requesting User Authorization](../../../application-dev/security/accesstoken-guidelines.md#requesting-user-authorization). For details about how to use pre-authorization, see [Pre-authorizing user_grant Permissions](../../../application-dev/security/accesstoken-guidelines.md#pre-authorizing-user_grant-permissions).
## cl.bundlemanager.5 getSpecifiedDistributionType Moved from @ohos.bundle.installer.d.ts to @ohos.bundle.bundleManager.d.ts
The **getSpecifiedDistributionType** API is moved from **@ohos.bundle.installer.d.ts** to **@ohos.bundle.bundleManager.d.ts**.
**Change Impact**
After an update to the new SDK version, the **getSpecifiedDistributionType** API in **@ohos.bundle.installer.d.ts** is moved to **@ohos.bundle.bundleManager.d.ts**.
**Key API/Component Changes**
The **getSpecifiedDistributionType** API in **@ohos.bundle.installer.d.ts** is moved to **@ohos.bundle.bundleManager.d.ts**.
**Adaptation Guide**
To use **getSpecifiedDistributionType**, import the **bundleManager** module.
```ets
import bundleManager form '@ohos.bundle.bundleManager'
```
## cl.bundlemanager.6 getAdditionalInfo Moved from @ohos.bundle.installer.d.ts to @ohos.bundle.bundleManager.d.ts
The **getAdditionalInfo** API is moved from **@ohos.bundle.installer.d.ts** to **@ohos.bundle.bundleManager.d.ts**.
**Change Impact**
After an update to the new SDK version, the **getAdditionalInfo** API in **@ohos.bundle.installer.d.ts** is moved to **@ohos.bundle.bundleManager.d.ts**.
**Key API/Component Changes**
The **getAdditionalInfo** API is moved from **@ohos.bundle.installer.d.ts** to **@ohos.bundle.bundleManager.d.ts**.
**Adaptation Guide**
To use **getAdditionalInfo**, import the **bundleManager** module.
```ets
import bundleManager form '@ohos.bundle.bundleManager'
```
## cl.bundlemanager.7 proxyDatas Renamed proxyData in the module.json5 File
**proxyDatas** is renamed **proxyData**.
**Change Impact**
After an update to the new SDK version, **proxyDatas** is **renamed proxyData**. If your application is not adapted, the build will fail.
**Key API/Component Changes**
**proxyDatas** is renamed **proxyData**.
**Adaptation Guide**
Replace **proxyDatas** with **proxyData**. The content of **proxyDatas** does not need to be changed.
# Security Subsystem Changelog
## cl.security.1 Addition of the @throws Tags for Exceptions Thrown in API Version 9
Added the @throws tags for the APIs of API version 9 in the JS document.
**Change Impact**
For released JS interfaces, the exception handling process may be affected, including synchronous and asynchronous exceptions. Check the exception handling process based on the latest @throws tags and make adaptation.
**Key API/Component Changes**
Before change:
```ts
interface Key {
/**
* Encode the key object to binary data.
*
* @returns { DataBlob } the binary data of the key object.
* @syscap SystemCapability.Security.CryptoFramework
* @since 9
*/
getEncoded(): DataBlob;
}
interface AsyKeyGenerator {
/**
* Used to generate asymmetric key pair.
*
* @param { AsyncCallback<KeyPair> } callback - the callback used to return keypair.
* @throws { BusinessError } 401 - invalid parameters.
* @throws { BusinessError } 17620001 - memory error.
* @syscap SystemCapability.Security.CryptoFramework
* @since 9
*/
generateKeyPair(callback: AsyncCallback<KeyPair>): void;
/**
* Used to generate asymmetric key pair.
*
* @returns { Promise<KeyPair> } the promise used to return keypair.
* @throws { BusinessError } 401 - invalid parameters.
* @throws { BusinessError } 17620001 - memory error.
* @syscap SystemCapability.Security.CryptoFramework
* @since 9
*/
generateKeyPair(): Promise<KeyPair>;
/**
* Used to convert asymmetric key data to key pair object.
*
* @param { DataBlob } pubKey - the public key data blob.
* @param { DataBlob } priKey - the private key data blob.
* @param { AsyncCallback<KeyPair> } callback - the callback used to return keypair.
* @throws { BusinessError } 401 - invalid parameters.
* @throws { BusinessError } 17620001 - memory error.
* @syscap SystemCapability.Security.CryptoFramework
* @since 9
*/
convertKey(pubKey: DataBlob, priKey: DataBlob, callback: AsyncCallback<KeyPair>): void;
/**
* Used to convert asymmetric key data to key pair object.
*
* @param { DataBlob } pubKey - the public key data blob.
* @param { DataBlob } priKey - the private key data blob.
* @returns { Promise<KeyPair> } the promise used to return keypair.
* @throws { BusinessError } 401 - invalid parameters.
* @throws { BusinessError } 17620001 - memory error.
* @syscap SystemCapability.Security.CryptoFramework
* @since 9
*/
convertKey(pubKey: DataBlob, priKey: DataBlob): Promise<KeyPair>;
}
/**
* Provides the asymmetric key generator instance func.
*
* @param { string } algName - indicates the algorithm name.
* @returns { AsyKeyGenerator } the generator obj create by algName.
* @throws { BusinessError } 401 - invalid parameters.
* @syscap SystemCapability.Security.CryptoFramework
* @since 9
*/
function createAsyKeyGenerator(algName: string): AsyKeyGenerator;
/**
* Create a cipher object for encryption and decryption operations according to the given specifications.
* Two different Cipher objects should be created when using RSA encryption and decryption,
* even with the same specifications.
*
* @param { string } transformation - indicates the description to be transformed to cipher specifications.
* @returns { Cipher } the cipher object returned by the function.
* @throws { BusinessError } 401 - invalid parameters.
* @throws { BusinessError } 801 - this operation is not supported.
* @syscap SystemCapability.Security.CryptoFramework
* @since 9
*/
function createCipher(transformation: string): Cipher;
/**
* Create sign class.
*
* @param { string } algName - indicates the algorithm name and params.
* @returns { Sign } the sign class.
* @throws { BusinessError } 401 - invalid parameters.
* @syscap SystemCapability.Security.CryptoFramework
* @since 9
*/
function createSign(algName: string): Sign;
/**
* Create verify class.
*
* @param { string } algName - indicates the algorithm name and params.
* @returns { Verify } the verify class.
* @throws { BusinessError } 401 - invalid parameters.
* @syscap SystemCapability.Security.CryptoFramework
* @since 9
*/
function createVerify(algName: string): Verify;
/**
* Create key agreement class.
*
* @param { string } algName - indicates the algorithm name and params.
* @returns { KeyAgreement } the key agreement class.
* @throws { BusinessError } 401 - invalid parameters.
* @syscap SystemCapability.Security.CryptoFramework
* @since 9
*/
function createKeyAgreement(algName: string): KeyAgreement;
```
After change:
```ts
interface Key {
/**
* Encode the key object to binary data.
*
* @returns { DataBlob } the binary data of the key object.
* @throws { BusinessError } 801 - this operation is not supported.
* @throws { BusinessError } 17620001 - memory error.
* @throws { BusinessError } 17630001 - crypto operation error.
* @syscap SystemCapability.Security.CryptoFramework
* @since 9
*/
getEncoded(): DataBlob;
}
interface AsyKeyGenerator {
/**
* Used to generate asymmetric keypair.
*
* @param { AsyncCallback<KeyPair> } callback - the callback used to return keypair.
* @throws { BusinessError } 401 - invalid parameters.
* @throws { BusinessError } 17620001 - memory error.
* @throws { BusinessError } 17630001 - crypto operation error.
* @syscap SystemCapability.Security.CryptoFramework
* @since 9
*/
generateKeyPair(callback: AsyncCallback<KeyPair>): void;
/**
* Used to generate asymmetric keypair.
*
* @returns { Promise<KeyPair> } the promise used to return keypair.
* @throws { BusinessError } 401 - invalid parameters.
* @throws { BusinessError } 17620001 - memory error.
* @throws { BusinessError } 17630001 - crypto operation error.
* @syscap SystemCapability.Security.CryptoFramework
* @since 9
*/
generateKeyPair(): Promise<KeyPair>;
/**
* Used to convert asymmetric key data to keypair object.
*
* @param { DataBlob } pubKey - the public key data blob.
* @param { DataBlob } priKey - the private key data blob.
* @param { AsyncCallback<KeyPair> } callback - the callback used to return keypair.
* @throws { BusinessError } 401 - invalid parameters.
* @throws { BusinessError } 17620001 - memory error.
* @throws { BusinessError } 17630001 - crypto operation error.
* @syscap SystemCapability.Security.CryptoFramework
* @since 9
*/
convertKey(pubKey: DataBlob, priKey: DataBlob, callback: AsyncCallback<KeyPair>): void;
/**
* Used to convert asymmetric key data to keypair object.
*
* @param { DataBlob } pubKey - the public key data blob.
* @param { DataBlob } priKey - the private key data blob.
* @returns { Promise<KeyPair> } the promise used to return keypair.
* @throws { BusinessError } 401 - invalid parameters.
* @throws { BusinessError } 17620001 - memory error.
* @throws { BusinessError } 17630001 - crypto operation error.
* @syscap SystemCapability.Security.CryptoFramework
* @since 9
*/
convertKey(pubKey: DataBlob, priKey: DataBlob): Promise<KeyPair>;
}
/**
* Create the asymmetric key generator instance according to the given algorithm name.
*
* @param { string } algName - indicates the algorithm name.
* @returns { AsyKeyGenerator } the asymmetric key generator instance.
* @throws { BusinessError } 401 - invalid parameters.
* @throws { BusinessError } 801 - this operation is not supported.
* @throws { BusinessError } 17620001 - memory error.
* @syscap SystemCapability.Security.CryptoFramework
* @since 9
*/
function createAsyKeyGenerator(algName: string): AsyKeyGenerator;
/**
* Create a cipher object for encryption and decryption operations according to the given specifications.
* Two different Cipher objects should be created when using RSA encryption and decryption,
* even with the same specifications.
*
* @param { string } transformation - indicates the description to be transformed to cipher specifications.
* @returns { Cipher } the cipher object returned by the function.
* @throws { BusinessError } 401 - invalid parameters.
* @throws { BusinessError } 801 - this operation is not supported.
* @throws { BusinessError } 17620001 - memory error.
* @syscap SystemCapability.Security.CryptoFramework
* @since 9
*/
function createCipher(transformation: string): Cipher;
/**
* Create a sign object for generating signatures.
*
* @param { string } algName - indicates the algorithm name and params.
* @returns { Sign } the sign class.
* @throws { BusinessError } 401 - invalid parameters.
* @throws { BusinessError } 801 - this operation is not supported.
* @throws { BusinessError } 17620001 - memory error.
* @syscap SystemCapability.Security.CryptoFramework
* @since 9
*/
function createSign(algName: string): Sign;
/**
* Create a verify object for verifying signatures.
*
* @param { string } algName - indicates the algorithm name and the parameters.
* @returns { Verify } the verify class.
* @throws { BusinessError } 401 - invalid parameters.
* @throws { BusinessError } 801 - this operation is not supported.
* @throws { BusinessError } 17620001 - memory error.
* @syscap SystemCapability.Security.CryptoFramework
* @since 9
*/
function createVerify(algName: string): Verify;
/**
* Create a key agreement object.
*
* @param { string } algName - indicates the algorithm name and params.
* @returns { KeyAgreement } the key agreement object.
* @throws { BusinessError } 401 - invalid parameters.
* @throws { BusinessError } 801 - this operation is not supported.
* @throws { BusinessError } 17620001 - memory error.
* @syscap SystemCapability.Security.CryptoFramework
* @since 9
*/
function createKeyAgreement(algName: string): KeyAgreement;
```
**Adaptation Guide**
Check the exception handling process based on the latest @throws tags and modify the code as required.
- For synchronization methods, such as **createSign**, use try/catch to process error information.
- For asynchronous methods, such as **convertKey**, use try/catch to process synchronous parameter errors and use the **error** object to obtain asynchronous parameter errors and service execution errors.
# Device Management Changelog
## The cl.distributedDeviceManager.1 API Change
Added device management APIs in OpenHarmony 4.0.9.2.
**Change Impact**
The original [Device Management APIs](../../../application-dev/reference/apis/js-apis-device-manager.md) can still be used but will no longer be maintained. You are advised to use the new APIs for development.
**Key API/Component Changes**
The following APIs are added.
| Module | Class | API |
| ------------------------------------ | ------------------- | ------------------------------------------------------------ |
| @ohos.distributedDeviceManager | function | **function** createDeviceManager(bundleName: string): DeviceManager; |
| @ohos.distributedDeviceManager | function | **function** releaseDeviceManager(deviceManager: DeviceManager): void; |
| @ohos.distributedDeviceManager | DeviceManager | **function** getAvailableDeviceListSync(): Array&lt;DeviceBasicInfo&gt;; |
| @ohos.distributedDeviceManager | DeviceManager | **function** getAvailableDeviceList(callback:AsyncCallback&lt;Array&lt;DeviceBasicInfo&gt;&gt;): void; |
| @ohos.distributedDeviceManager | DeviceManager | **function** getAvailableDeviceList(): Promise&lt;Array&lt;DeviceBasicInfo&gt;&gt;; |
| @ohos.distributedDeviceManager | DeviceManager | **function** getLocalDeviceNetworkId(): string; |
| @ohos.distributedDeviceManager | DeviceManager | **function** getLocalDeviceName(): string; |
| @ohos.distributedDeviceManager | DeviceManager | **function** getLocalDeviceType(): number; |
| @ohos.distributedDeviceManager | DeviceManager | **function** getLocalDeviceId(): string; |
| @ohos.distributedDeviceManager | DeviceManager | **function** getDeviceName(networkId: string): string; |
| @ohos.distributedDeviceManager | DeviceManager | **function** getDeviceType(networkId: string): number; |
| @ohos.distributedDeviceManager | DeviceManager | **function** startDiscovering(discoverParam: {[key:&nbsp;string]:&nbsp;Object} , filterOptions?: {[key:&nbsp;string]:&nbsp;Object} ): void; |
| @ohos.distributedDeviceManager | DeviceManager | **function** stopDiscovering(): void; |
| @ohos.distributedDeviceManager | DeviceManager | **function** bindTarget(deviceId: string, bindParam: {[key:&nbsp;string]:&nbsp;Object} , callback: AsyncCallback&lt;{deviceId: string}&gt;): void; |
| @ohos.distributedDeviceManager | DeviceManager | **function** unbindTarget(deviceId: string): void; |
| @ohos.distributedDeviceManager | DeviceManager | **function** replyUiAction(action: number, actionResult: string): void; |
| @ohos.distributedDeviceManager | DeviceManager | **function** on(type: 'replyResult', callback: Callback&lt;{ param: string}&gt;): void; |
| @ohos.distributedDeviceManager | DeviceManager | **function** off(type: 'replyResult', callback?: Callback&lt;{ param: string}&gt;): void; |
| @ohos.distributedDeviceManager | DeviceManager | **function** on(type: 'deviceStateChange', callback: Callback&lt;{ action: DeviceStateChange, device: DeviceBasicInfo }&gt;): void; |
| @ohos.distributedDeviceManager | DeviceManager | **function** off(type: 'deviceStateChange', callback?: Callback&lt;{ action: DeviceStateChange, device: DeviceBasicInfo }&gt;): void; |
| @ohos.distributedDeviceManager | DeviceManager | **function** on(type: 'discoverSuccess', callback: Callback&lt;{ device: DeviceBasicInfo }&gt;): void; |
| @ohos.distributedDeviceManager | DeviceManager | **function** off(type: 'discoverSuccess', callback?: Callback&lt;{ device: DeviceBasicInfo }&gt;): void; |
| @ohos.distributedDeviceManager | DeviceManager | **function** on(type: 'deviceNameChange', callback: Callback&lt;{ deviceName: string }&gt;): void; |
| @ohos.distributedDeviceManager | DeviceManager | **function** off(type: 'deviceNameChange', callback?: Callback&lt;{ deviceName: string }&gt;): void; |
| @ohos.distributedDeviceManager | DeviceManager | **function** on(type: 'discoverFailure', callback: Callback&lt;{ reason: number }&gt;): void; |
| @ohos.distributedDeviceManager | DeviceManager | **function** off(type: 'discoverFailure', callback?: Callback&lt;{ reason: number }&gt;): void; |
| @ohos.distributedDeviceManager | DeviceManager | **function** on(type: 'serviceDie', callback?: Callback&lt;{}&gt;): void; |
| @ohos.distributedDeviceManager | DeviceManager | **function** off(type: 'serviceDie', callback?: Callback&lt;{}&gt;): void; |
**Adaptation Guide**
See [Device Management](../../../application-dev/reference/apis/js-apis-distributedDeviceManager.md).
# Multimedia Subsystem Changelog
## cl.multimedia.1 Stream Type Enum Declaration in Audio C APIs Changed
For the audio APIs of API version 10 in C, the audio output stream type is changed from **AUDIOSTREAM_TYPE_RERNDERER** to **AUDIOSTREAM_TYPE_RENDERER**.
**Change Impact**
Applications that use the involved APIs may have compatibility issues.
**Key API/Component Changes**
Before change:
```C
enum OH_AudioStream_Type {
/**
* The type for audio stream is renderer.
*/
AUDIOSTREAM_TYPE_RERNDERER = 1,
/**
* The type for audio stream is capturer.
*/
AUDIOSTREAM_TYPE_CAPTURER = 2
};
```
After change:
```C
enum OH_AudioStream_Type {
/**
* The type for audio stream is renderer.
*/
AUDIOSTREAM_TYPE_RENDERER = 1,
/**
* The type for audio stream is capturer.
*/
AUDIOSTREAM_TYPE_CAPTURER = 2
};
```
**Adaptation Guide**
Change **AUDIOSTREAM_TYPE_RERNDERER** to **AUDIOSTREAM_TYPE_RENDERER** in your code. Example:
Before change:
```C
OH_AudioStreamBuilder* builder;
OH_AudioStreamBuilder_Create(&builder, AUDIOSTREAM_TYPE_RERNDERER);
```
After change:
```C
OH_AudioStreamBuilder* builder;
OH_AudioStreamBuilder_Create(&builder, AUDIOSTREAM_TYPE_RENDERER);
```
## cl.multimedia.2 OH_AudioStream_Content Removed
For the audio APIs of API version 10 in C, **OH_AudioStream_Content** is removed for the audio output stream attributes.
**Change Impact**
Applications that use the involved APIs may have compatibility issues.
**Key API/Component Changes**
- In the **native_audiostream_base.h** file
Before change:
```C
typedef enum {
AUDIOSTREAM_CONTENT_TYPE_UNKNOWN = 0,
AUDIOSTREAM_CONTENT_TYPE_SPEECH = 1,
AUDIOSTREAM_CONTENT_TYPE_MUSIC = 2,
AUDIOSTREAM_CONTENT_TYPE_MOVIE = 3,
} OH_AudioStream_Content;
```
After change: **OH_AudioStream_Content** is removed.
- In the **native_audiostreambuilder.h** file
Before change:
```C
OH_AudioStream_Result OH_AudioStreamBuilder_SetRendererInfo(OH_AudioStreamBuilder* builder,
OH_AudioStream_Usage usage, OH_AudioStream_Content content);
```
After change:
```C
OH_AudioStream_Result OH_AudioStreamBuilder_SetRendererInfo(OH_AudioStreamBuilder* builder,
OH_AudioStream_Usage usage);
```
- In the **native_audiorenderer.h** file
Before change:
```C
OH_AudioStream_Result OH_AudioRenderer_GetRendererInfo(OH_AudioRenderer* renderer,
OH_AudioStream_Usage* usage, OH_AudioStream_Content* content);
```
After change:
```C
OH_AudioStream_Result OH_AudioRenderer_GetRendererInfo(OH_AudioRenderer* renderer,
OH_AudioStream_Usage* usage);
```
**Adaptation Guide**
When using **OH_AudioStreamBuilder_SetRendererInfo**, check the original **OH_AudioStream_Content** type against the following table and use the corresponding **OH_AudioStream_Usage** type based on the scenario.
| OH_AudioStream_Content | OH_AudioStream_Usage |
| ------------------------------- | ------------------------------------- |
| AUDIOSTREAM_CONTENT_TYPE_SPEECH | AUDIOSTREAM_USAGE_VOICE_COMMUNICATION |
| AUDIOSTREAM_CONTENT_TYPE_MUSIC | AUDIOSTREAM_USAGE_MUSIC |
| AUDIOSTREAM_CONTENT_TYPE_MOVIE | AUDIOSTREAM_USAGE_MOVIE |
**OH_AudioRenderer_GetRendererInfo** can be used to obtain the **OH_AudioStream_Usage** attribute but not the **OH_AudioStream_Content** attribute.
## cl.multimedia.3 OH_AudioStream_Usage Changed
In the **native_audiostream_base.h** file of the audio interfaces of API version 10 in C, for the **OH_AudioStream_Usage** enum, the enumerated value **AUDIOSTREAM_USAGE_MEDIA** is deleted, and **AUDIOSTREAM_USAGE_COMMUNICATION** is changed to **AUDIOSTREAM_USAGE_VOICE_COMMUNICATION** and **AUDIOSTREAM_USAGE_VOICE_ASSISTANT**.
**Change Impact**
Applications that use the involved APIs may have compatibility issues.
**Key API/Component Changes**
Before change:
```C
typedef enum {
AUDIOSTREAM_USAGE_UNKNOWN = 0,
AUDIOSTREAM_USAGE_MEDIA = 1,
AUDIOSTREAM_USAGE_COMMUNICATION = 2,
} OH_AudioStream_Usage;
```
After change:
```C
typedef enum {
/**
* Unknown usage.
*/
AUDIOSTREAM_USAGE_UNKNOWN = 0,
/**
* Music usage.
*/
AUDIOSTREAM_USAGE_MUSIC = 1,
/**
* Voice communication usage.
*/
AUDIOSTREAM_USAGE_VOICE_COMMUNICATION = 2,
/**
* Voice assistant usage.
*/
AUDIOSTREAM_USAGE_VOICE_ASSISTANT = 3,
/**
* Movie or video usage.
*/
AUDIOSTREAM_USAGE_MOVIE = 10,
} OH_AudioStream_Usage;
```
**Adaptation Guide**
When using **OH_AudioStreamBuilder_SetRendererInfo**, set **OH_AudioStream_Usage** to **AUDIOSTREAM_USAGE_MUSIC** or **AUDIOSTREAM_USAGE_MOVIE**, rather than **AUDIOSTREAM_USAGE_MEDIA**.
Before change:
```C
OH_AudioStreamBuilder_SetRendererInfo(builder, AUDIOSTREAM_USAGE_MEDIA);
```
After change:
```C
OH_AudioStreamBuilder_SetRendererInfo(builder, AUDIOSTREAM_USAGE_MUSIC); // Music scene
```
Or:
```C
OH_AudioStreamBuilder_SetRendererInfo(builder, AUDIOSTREAM_USAGE_MOVIE); // Video scene
```
When using **OH_AudioStreamBuilder_SetRendererInfo**, set **OH_AudioStream_Usage** to **AUDIOSTREAM_USAGE_VOICE_COMMUNICATION** or **AUDIOSTREAM_USAGE_VOICE_ASSISTANT**, rather than **AUDIOSTREAM_USAGE_COMMUNICATION**.
Before change:
```C
OH_AudioStreamBuilder_SetRendererInfo(builder, AUDIOSTREAM_USAGE_COMMUNICATION);
```
After change:
```C
OH_AudioStreamBuilder_SetRendererInfo(builder, AUDIOSTREAM_USAGE_VOICE_COMMUNICATION); // Communication scene
```
Or:
```C
OH_AudioStreamBuilder_SetRendererInfo(builder, AUDIOSTREAM_USAGE_VOICE_ASSISTANT); // Voice assistant scene
```
## cl.multimedia.4 AUDIOSTREAM_SAMPLE_F32LE Deleted for **OH_AudioStream_SampleFormat**
In the **native_audiostream_base.h** file of the audio interfaces of API version 10 in C, the enumerated value **AUDIOSTREAM_SAMPLE_F32LE** is deleted for the **OH_AudioStream_SampleFormat** enum.
**Change Impact**
Applications that use the involved APIs may have compatibility issues.
**Key API/Component Changes**
Before change:
```C
typedef enum {
AUDIOSTREAM_SAMPLE_U8 = 0,
AUDIOSTREAM_SAMPLE_S16LE = 1,
AUDIOSTREAM_SAMPLE_S24LE = 2,
AUDIOSTREAM_SAMPLE_S32LE = 3,
AUDIOSTREAM_SAMPLE_F32LE = 4,
} OH_AudioStream_SampleFormat;
```
After change:
```C
typedef enum {
/**
* Unsigned 8 format.
*/
AUDIOSTREAM_SAMPLE_U8 = 0,
/**
* Signed 16 bit integer, little endian.
*/
AUDIOSTREAM_SAMPLE_S16LE = 1,
/**
* Signed 24 bit integer, little endian.
*/
AUDIOSTREAM_SAMPLE_S24LE = 2,
/**
* Signed 32 bit integer, little endian.
*/
AUDIOSTREAM_SAMPLE_S32LE = 3,
} OH_AudioStream_SampleFormat;
```
**Adaptation Guide**
Do not use **AUDIOSTREAM_SAMPLE_F32LE** for **OH_AudioStream_SampleFormat**.
## cl.multimedia.5 Enumerated Values Added for OH_AudioStream_Result
In the **native_audiostream_base.h** file of the audio interfaces of API version 10 in C, new enumerated values are added for the **OH_AudioStream_Result** enum.
**Change Impact**
None.
**Key API/Component Changes**
Before change:
```C
typedef enum {
/**
* The call was successful.
*/
AUDIOSTREAM_SUCCESS,
/**
* This means that the function was executed with an invalid input parameter.
*/
AUDIOSTREAM_ERROR_INVALID_PARAM,
/**
* Execution status exception.
*/
AUDIOSTREAM_ERROR_ILLEGAL_STATE,
/**
* An system error has occurred.
*/
AUDIOSTREAM_ERROR_SYSTEM
} OH_AudioStream_Result;
```
After change:
```C
typedef enum {
/**
* The call was successful.
*/
AUDIOSTREAM_SUCCESS = 0,
/**
* This means that the function was executed with an invalid input parameter.
*/
AUDIOSTREAM_ERROR_INVALID_PARAM = 1,
/**
* Execution status exception.
*/
AUDIOSTREAM_ERROR_ILLEGAL_STATE = 2,
/**
* An system error has occurred.
*/
AUDIOSTREAM_ERROR_SYSTEM = 3
} OH_AudioStream_Result;
```
**Adaptation Guide**
No adaptation is required.
# Bundle Management Subsystem Changelog
## cl.bundlemanager.1 schema in the module.json File Changed
In the **module.json** file, the **name** attributes of the **module**, **ability**, and **extensionAbility** fields must start with a letter and contain only letters, digits, underscores (_), and dots (.).
**Change Impact**
After an update to the new SDK version, the build fails if the **name** attributes of these fields do not meet the preceding requirements.
**Key API/Component Changes**
In the **module.json** file, the **name** attributes of the **module**, **ability**, and **extensionAbility** fields must start with a letter and contain only letters, digits, underscores (_), and dots (.).
**Adaptation Guide**
Modify the **name** attributes for these fields accordingly to the new requirements.
\ No newline at end of file
# Media Subsystem ChangeLog
## cl.media.1 Playback APIs Changed
The APIs related to audio track switching are deleted.
**Change Impact**
These APIs are unavailable.
**Key API/Component Changes**
The deleted APIs are as follows:
| Class | API |
| -------------- | ------------------------------------------------------------ |
| Media.Core | MD_KEY_LANGUAGE |
| Media.AVPlayer | selectTrack(index: number): void |
| Media.AVPlayer | deselectTrack(index: number): void |
| Media.AVPlayer | getCurrentTrack(trackType: MediaType, callback: AsyncCallback\<number>): void |
| Media.AVPlayer | getCurrentTrack(trackType: MediaType): Promise\<number> |
| Media.AVPlayer | on(type: 'trackChange', callback: (index: number, isSelect: boolean) => void): void; |
| Media.AVPlayer | off(type: 'trackChange'): void |
# Multimedia Subsystem Changelog
## cl.multimedia.1 Deleted content from getAudioEffectInfoArray
The input parameter **content** is deleted from **getAudioEffectInfoArray**.
**Change Impact**
Applications that use the involved APIs may have compatibility issues.
**Key API/Component Changes**
Before change:
```js
getAudioEffectInfoArray(content: ContentType, usage: StreamUsage, callback: AsyncCallback<AudioEffectInfoArray>): void;
getAudioEffectInfoArray(content: ContentType, usage: StreamUsage): Promise<AudioEffectInfoArray>;
```
After change:
```js
getAudioEffectInfoArray(usage: StreamUsage, callback: AsyncCallback<AudioEffectInfoArray>): void;
getAudioEffectInfoArray(usage: StreamUsage): Promise<AudioEffectInfoArray>;
```
**Adaptation Guide**
When calling this API, pass in only the input parameter **usage**. If **getAudioEffectInfoArray** is used in your application code, delete the **content** parameter.
# Readme
- [Ability Framework](changelogs-ability.md)
- [Account Subsystem](changelogs-account_os_account.md)
- [ArkUI Subsystem](changelogs-arkui.md)
- [Multimedia Subsystem - Camera](changelogs-camera.md)
- [Device Manager Subsystem](changelogs-device-manager.md)
- [USB Subsystem](changelogs-device-usb.md)
- [Distributed Scheduler Subsystem](changelogs-dmsfwk.md)
- [DSoftBus Subsystem](changelogs-dsoftbus.md)
- [Customization Subsystem](changelogs-enterprise_device_management.md)
- [File Management Subsystem](changelogs-filemanagement.md)
- [Geolocation Subsystem](changelogs-geolocation.md)
- [Globalization Subsystem](changelogs-global.md)
- [Input Method Framework](changelogs-inputmethod-framworks.md)
- [Multimedia Subsystem](changelogs-multimedia.md)
- [Multimodal Input Subsystem](changelogs-multimodalinput.md)
- [Common Event and Notification Subsystem](changelogs-notification.md)
- [Power Service Subsystem](changelogs-power.md)
- [Upload and Download Subsystem](changelogs-request.md)
- [Resource Manager Subsystem](changelogs-resource-manager.md)
- [Resource Scheduler Subsystem](changelogs-resourceschedule.md)
- [Telephony Subsystem](changelogs-telephony.md)
- [Test Subsystem](changelogs-testfwk_arkxtest.md)
- [Theme Framework](changelogs-theme.md)
- [User IAM Subsystem](changelogs-useriam.md)
- [Abiligy Framework - WantAgent](changelogs-wantAgent.md)
- [Web Subsystem](changelogs-web.md)
- [Communications Subsystem - Wi-Fi](changelogs-wifi.md)
<!--no_check-->
\ No newline at end of file
# *Example* Subsystem ChangeLog # *Example* Subsystem Changelog
Changes that affect contract compatibility of the last version should be described in the ChangeLog. The changes include but are not limited to those related to API names, parameters, return values, required permissions, call sequence, enumerated values, configuration parameters, and paths. The last version can be an LTS, release, beta, or monthly version, or the like. Contract compatibility, also called semantic compatibility, means that the original program behavior should remain consistent over versions. Changes that affect contract compatibility of the last version should be described in the changelog. The changes include but are not limited to those related to API names, parameters, return values, required permissions, call sequence, enumerated values, configuration parameters, and paths. The last version can be an LTS, release, beta, or monthly version, or the like. Contract compatibility, also called semantic compatibility, means that the original program behavior should remain consistent over versions.
## cl.subsystemname.x xxx Function Change (Example: DeviceType Attribute Change or Camera Permission Change. Use a short description.) ## cl.subsystemname.x xxx Function Change (Example: DeviceType Attribute Change or Camera Permission Change. Use a short description.)
Add the number **cl.*subsystemname*.*x*** before each change title, where **cl** is the abbreviation of ChangeLog, *subsystemname* is the standard English name of the subsystem, and *x* indicates the change sequence number (starting from 1 in ascending order). Add the number **cl.*subsystemname*.*x*** before each change title, where **cl** is the abbreviation of changelog, *subsystemname* is the standard English name of the subsystem, and *x* indicates the change sequence number (starting from 1 in ascending order).
Describe the changes in terms of functions. Example: *n* and *m* of the *a* function are changed. Developers need to adapt their applications based on the change description. Describe the changes in terms of functions. Example: *n* and *m* of the *a* function are changed. Developers need to adapt their applications based on the change description.
If there is a requirement or design document corresponding to the change, attach the requirement number or design document number in the description. If there is a requirement or design document corresponding to the change, attach the requirement number or design document number in the description.
**Change Impacts** **Change Impact**
Describe whether released APIs (JS or native APIs) are affected or API behavior is changed. Describe whether released APIs (JS or native APIs) are affected or API behavior is changed.
Describe whether available applications are affected, that is, whether an adaptation is required for building the application code in the SDK environment of the new version. Describe whether available applications are affected, that is, whether an adaptation is required for building the application code in the SDK environment of the new version.
**Key API/Component Changes** **Key API/Component Changes**
List the API/component changes involved in the function change. List the API/component changes involved in the function change.
**Adaptation Guide (Optional)** **Adaptation Guide**
Provide guidance for developers on how to adapt their application to the changes to be compatible with the new version. Provide guidance for developers on how to adapt their application to the changes to be compatible with the new version.
Example: Example:
Change parameter *n* to *m* in the *a* file. Change parameter *n* to *m* in the *a* file.
``` ```
......
# Ability Subsystem ChangeLog # Ability Framework Changelog
## cl.ability.1 Application Component Startup Rule Change ## cl.ability.1 Application Component Startup Rule Change
The rules for starting application components of the ability subsystem are changed in the following scenarios: The rules for starting application components are changed in the following scenarios:
- Start application components when the application is in the background. - Start an application component when the application is in the background.
- Start invisible application components across applications. - Start an invisible application component across applications.
- Start **serviceAbility** and **dataAbility** of the FA model across applications. - Start a ServiceAbility and DataAbility of the FA model across applications.
- Use the **startAbilityByCall** API. - Use the **startAbilityByCall** API.
You need to adapt your application based on the following information. You need to adapt your application.
**Change Impacts**
**Change Impact**
If new rules are not adapted, application components cannot be started in the previous scenarios. If new rules are not adapted, application components cannot be started in the previous scenarios.
> **NOTE** > **NOTE**
> >
> Starting application components refers to any behavior starting or connecting to an ability. > Starting application components refers to any behavior starting or connecting to an ability.
> >
...@@ -69,13 +70,13 @@ If new rules are not adapted, application components cannot be started in the pr ...@@ -69,13 +70,13 @@ If new rules are not adapted, application components cannot be started in the pr
**Adaptation Guide** **Adaptation Guide**
Startup rules for different scenarios are as follows: Startup rules for different scenarios are as follows:
- **Start application components when the application is in the background.** - **Starting an application component when the application is in the background**
- OpenHarmony 3.2 Beta3 rules: - Rule in OpenHarmony 3.2 Beta3:
- Starting application components when the application is in the background is not restricted. - There is no restriction.
- OpenHarmony 3.2 Beta4 rules: - Rule in OpenHarmony 3.2 Beta4:
- When the application is in the background, starting application components requires authentication. The following permission needs to be applied for: - Authentication is required. The following permissions must be configured:
```json - ```json
{ {
"name": "ohos.permission.START_ABILITIES_FROM_BACKGROUND", "name": "ohos.permission.START_ABILITIES_FROM_BACKGROUND",
"grantMode": "system_grant", "grantMode": "system_grant",
...@@ -84,18 +85,19 @@ Startup rules for different scenarios are as follows: ...@@ -84,18 +85,19 @@ Startup rules for different scenarios are as follows:
"distributedSceneEnable": false "distributedSceneEnable": false
} }
``` ```
> **NOTE** > **NOTE**
> >
> 1. Starting components of the same application is also restricted by this rule. > 1. Starting an application component of the same application is also restricted by this rule.
> 2. For SDKs of API version 8 or earlier, starting **serviceAbility** and **dataAbility** is not restricted by this rule. > 2. For SDKs of API version 8 or earlier, starting a ServiceAbility and DataAbility is not restricted by this rule.
- **Starting an invisible application component across applications**
- **Start invisible application components across applications.** - Rule in OpenHarmony 3.2 Beta3:
- OpenHarmony 3.2 Beta3 rules:
- For applications whose APL is normal, invisible application components cannot be started across applications. - For applications whose APL is normal, invisible application components cannot be started across applications.
- OpenHarmony 3.2 Beta4 rules: - Rule in OpenHarmony 3.2 Beta4:
- For all applications, starting invisible application components across applications requires authentication. The following permission needs to be applied for: - For all applications, starting an invisible application component across applications requires authentication. The following permissions must be configured:
```json - ```json
{ {
"name": "ohos.permission.START_INVISIBLE_ABILITY", "name": "ohos.permission.START_INVISIBLE_ABILITY",
"grantMode": "system_grant", "grantMode": "system_grant",
...@@ -103,26 +105,26 @@ Startup rules for different scenarios are as follows: ...@@ -103,26 +105,26 @@ Startup rules for different scenarios are as follows:
"provisionEnable": true, "provisionEnable": true,
"distributedSceneEnable": false "distributedSceneEnable": false
} }
``` ```
- **Start serviceAbility and dataAbility of the FA model across applications.** - **Starting a ServiceAbility and DataAbility of the FA model across applications**
- OpenHarmony 3.2 Beta3 rules: - Rule in OpenHarmony 3.2 Beta3:
- Starting **serviceAbility** and **dataAbility** across applications is not restricted. - There is no restriction.
- OpenHarmony 3.2 Beta4 rules: - Rule in OpenHarmony 3.2 Beta4:
- Associated startup needs to be configured for the provider of **serviceAbility** and **dataAbility**. Otherwise, **serviceAbility** and **dataAbility** cannot be started across applications. (Associated startup cannot be configured for common applications.) - Associated startup must be configured for the provider of the ServiceAbility and DataAbility. Otherwise, they cannot be started across applications. (Associated startup cannot be configured for common applications.)
- **Use the startAbilityByCall API.** - **Using the startAbilityByCall API**
- OpenHarmony 3.2 Beta3 rules: - Rule in OpenHarmony 3.2 Beta3:
- The API call is not restricted. - This is no restriction.
- OpenHarmony 3.2 Beta4 rules: - Rule in OpenHarmony 3.2 Beta4:
- The **startAbilityByCall** API cannot be called by the same application. - The **startAbilityByCall** API cannot be called by the same application.
- Calling the **startAbilityByCall** API across applications requires authentication. The following permission needs to be applied for: - Calling the **startAbilityByCall** API across applications requires authentication. The following permissions must be configured:
```json - ```json
{ {
"name": "ohos.permission.ABILITY_BACKGROUND_COMMUNICATION", "name": "ohos.permission.ABILITY_BACKGROUND_COMMUNICATION",
"grantMode": "system_grant", "grantMode": "system_grant",
...@@ -137,24 +139,24 @@ Startup rules for different scenarios are as follows: ...@@ -137,24 +139,24 @@ Startup rules for different scenarios are as follows:
## cl.ability.2 Cross-Device Application Component Startup Rule Change (for System Applications Only) ## cl.ability.2 Cross-Device Application Component Startup Rule Change (for System Applications Only)
The rules for starting cross-device application components of the ability subsystem are changed in the following scenarios: The rules for starting cross-device application components are changed in the following scenarios:
- Start application components when the application is in the background. - Start an application component when the application is in the background.
- Start invisible application components across applications. - Start an invisible application component across applications.
- Start **serviceAbility** of the FA model across applications. - Start a ServiceAbility of the FA model across applications.
You need to adapt your application based on the following information. You need to adapt your application.
**Change Impacts** **Change Impact**
If new rules are not adapted, application components cannot be started in the previous scenarios. If new rules are not adapted, application components cannot be started in the previous scenarios.
>**NOTE** > **NOTE**
> >
>Starting application components refers to any behavior starting or connecting to an ability. > Starting application components refers to any behavior starting or connecting to an ability.
> >
>1. Start an ability using APIs such as **startAbility**, **startAbilityForResult**, and **startAbilityByCall**. > 1. Start an ability using APIs such as **startAbility**, **startAbilityForResult**, and **startAbilityByCall**.
>2. Connect to an ability using APIs such as **connectAbility**. > 2. Connect to an ability using APIs such as **connectAbility**.
**Key API/Component Changes** **Key API/Component Changes**
...@@ -181,13 +183,13 @@ If new rules are not adapted, application components cannot be started in the pr ...@@ -181,13 +183,13 @@ If new rules are not adapted, application components cannot be started in the pr
**Adaptation Guide** **Adaptation Guide**
Startup rules for different scenarios are as follows: Startup rules for different scenarios are as follows:
- **Start application components when the application is in the background.** - **Starting an application component when the application is in the background**
- OpenHarmony 3.2 Beta3 rules: - Rule in OpenHarmony 3.2 Beta3:
- Starting application components when the application is in the background is not restricted. - There is no restriction.
- OpenHarmony 3.2 Beta4 rules: - Rule in OpenHarmony 3.2 Beta4:
- When the application is in the background, starting application components requires authentication. The following permission needs to be applied for: - Authentication is required. The following permissions must be configured:
```json - ```json
{ {
"name": "ohos.permission.START_ABILITIES_FROM_BACKGROUND", "name": "ohos.permission.START_ABILITIES_FROM_BACKGROUND",
"grantMode": "system_grant", "grantMode": "system_grant",
...@@ -196,18 +198,17 @@ Startup rules for different scenarios are as follows: ...@@ -196,18 +198,17 @@ Startup rules for different scenarios are as follows:
"distributedSceneEnable": false "distributedSceneEnable": false
} }
``` ```
> **NOTE** > **NOTE**
> 1. Starting an application component of the same application is also restricted by this rule.
> 1. Starting components of the same application is also restricted by this rule. 2. For SDKs of API version 8 or earlier, starting a ServiceAbility is not restricted by this rule.
> 2. For SDKs of API version 8 or earlier, starting **serviceAbility** is not restricted by this rule.
- **Start invisible application components across applications.** - **Starting an invisible application component across applications**
- OpenHarmony 3.2 Beta3 rules: - Rule in OpenHarmony 3.2 Beta3:
- Invisible application components cannot be started across applications. - Invisible application components cannot be started across applications.
- OpenHarmony 3.2 Beta4 rules: - Rule in OpenHarmony 3.2 Beta4:
- Starting invisible application components across applications requires authentication. The following permission needs to be applied for: - Authentication is required. The following permissions must be configured:
```json - ```json
{ {
"name": "ohos.permission.START_INVISIBLE_ABILITY", "name": "ohos.permission.START_INVISIBLE_ABILITY",
"grantMode": "system_grant", "grantMode": "system_grant",
...@@ -215,31 +216,31 @@ Startup rules for different scenarios are as follows: ...@@ -215,31 +216,31 @@ Startup rules for different scenarios are as follows:
"provisionEnable": true, "provisionEnable": true,
"distributedSceneEnable": false "distributedSceneEnable": false
} }
``` ```
- **Start serviceAbility of the FA model across applications.** - **Starting a ServiceAbility of the FA model across applications**
- OpenHarmony 3.2 Beta3 rules: - Rule in OpenHarmony 3.2 Beta3:
- Starting **serviceAbility** across applications is not restricted. - There is no restriction.
- OpenHarmony 3.2 Beta4 rules: - Rule in OpenHarmony 3.2 Beta4:
- Associated startup needs to be configured for the **serviceAbility** provider application. Otherwise, **serviceAbility** cannot be started across applications. (Associated startup cannot be configured for common applications.) - Associated startup needs to be configured for the provider of the ServiceAbility. Otherwise, the ServiceAbility cannot be started across applications. (Associated startup cannot be configured for common applications.)
- Configure associated startup as follows: - Configure associated startup as follows:
```json - ```json
{ {
"bundleName": "", "bundleName": "",
"app_signature": ["xxxxxxxxxxxxxxxxxxx"], "app_signature": ["xxxxxxxxxxxxxxxxxxx"],
"associatedWakeUp": true "associatedWakeUp": true
} }
``` ```
## cl.ability.3 API Exception Handling Method Change ## cl.ability.3 API Exception Handling Method Change
Certain APIs of the ability subsystem use service logic return values to indicate error information, which does not comply with the API error code specifications of OpenHarmony. Certain APIs of the ability subsystem use service logic return values to indicate error information, which does not comply with the API error code specifications of OpenHarmony.
**Change Impacts** **Change Impact**
The application developed based on earlier versions needs to adapt the new APIs and their method for returning API error information. Otherwise, the original service logic will be affected. The application developed based on earlier versions needs to be adapted. Otherwise, the service logic will be affected.
**Key API/Component Changes** **Key API/Component Changes**
...@@ -275,7 +276,7 @@ For adaptation to the unified API exception handling mode, certain ability subsy ...@@ -275,7 +276,7 @@ For adaptation to the unified API exception handling mode, certain ability subsy
**Adaptation Guide** **Adaptation Guide**
The original APIs are only migrated to the new namespace. Therefore, you can modify **import** to solve the adaptation problem. The original APIs are only moved to the new namespace. Therefore, you can modify **import** to solve the adaptation problem.
If the original API uses **@ohos.application.missionManager**: If the original API uses **@ohos.application.missionManager**:
...@@ -293,11 +294,11 @@ In addition, exception handling is needed. For details, see the API reference fo ...@@ -293,11 +294,11 @@ In addition, exception handling is needed. For details, see the API reference fo
## cl.ability.4 API Change ## cl.ability.4 API Change
The names of some ability subsystem APIs are changed. The names of certain ability subsystem APIs are changed.
**Key API/Component Changes** **Key API/Component Changes**
| Module | Class | Method/Attribute/Enumeration/Constant | Change Type| | Module | Class | Method/Attribute/Enum/Constant | Change Type|
| ----------------------------------------- | ----------------------- | ------------------------------------------------------------ | -------- | | ----------------------------------------- | ----------------------- | ------------------------------------------------------------ | -------- |
| @ohos.application.Ability | Caller | onRelease(callback: OnReleaseCallBack): **void**; | Deprecated | | @ohos.application.Ability | Caller | onRelease(callback: OnReleaseCallBack): **void**; | Deprecated |
| @ohos.app.ability.UIAbility | Caller | on(**type**: "release", callback: OnReleaseCallBack): **void**; | Added | | @ohos.app.ability.UIAbility | Caller | on(**type**: "release", callback: OnReleaseCallBack): **void**; | Added |
......
# Account Subsystem ChangeLog # Account Subsystem Changelog
## cl.account_os_account.1 Change of Definition and Return Mode of Error Codes ## cl.account_os_account.1 Change of Definition and Return Mode of Error Codes
To solve the issues that error code definitions of the account subsystem APIs were inconsistent and that the return mode of the error codes did not comply with relevant specifications of OpenHarmony, the following changes are made and take effect in API version 9 and later: To ensure consistent error codes and normalized return of error codes in the account subsystem APIs, the following changes are made in API version 9:
- Added the following unified error code definitions: - Added the following error code definitions:
- [Account Error Codes](https://gitee.com/openharmony/docs/blob/master/en/application-dev/reference/errorcodes/errorcode-account.md) - [Account Error Codes](../../../application-dev/reference/errorcodes/errorcode-account.md)
- [App Account Error Codes](https://gitee.com/openharmony/docs/blob/master/en/application-dev/reference/errorcodes/errorcode-account.md)
- Returned an error code in either of the following ways, according to the API type: - Changed the error code return modes as follows:
- Asynchronous API: An error message is returned via **AsyncCallback** or the **error** object of **Promise**. An error message related to the parameter type or quantity is returned via an exception. - Asynchronous APIs: Return error information in the **error** object of **AsyncCallback** or **Promise**. Throw an exception to return an error related to the parameter type or quantity.
- Synchronous API: An error message is returned via an exception. - Synchronous APIs: Throw an exception to return an error message.
**Change Impacts** **Change Impact**
The application developed based on earlier versions needs to adapt the method for returning API error information. Otherwise, the original service logic will be affected. The application developed based on earlier versions needs to adapt the method for returning API error information. Otherwise, the service logic will be affected.
**Key API/Component Changes** **Key API/Component Changes**
The mentioned changes involve the following APIs: Involved APIs:
- class AccountManager - class AccountManager
- activateOsAccount(localId: number, callback: AsyncCallback&lt;void&gt;): void; - activateOsAccount(localId: number, callback: AsyncCallback&lt;void&gt;): void;
- removeOsAccount(localId: number, callback: AsyncCallback&lt;void&gt;): void; - removeOsAccount(localId: number, callback: AsyncCallback&lt;void&gt;): void;
...@@ -63,13 +62,13 @@ The mentioned changes involve the following APIs: ...@@ -63,13 +62,13 @@ The mentioned changes involve the following APIs:
**Adaptation Guide** **Adaptation Guide**
The following uses **activateOsAccount** as an example to illustrate the error information processing logic of an asynchronous API: The following uses **activateOsAccount** as an example to describe the error information processing logic of an asynchronous API:
```ts ```ts
import account_osAccount from "@ohos.account.osAccount" import account_osAccount from "@ohos.account.osAccount"
let accountMgr = account_osAccount.getAccountManager() let accountMgr = account_osAccount.getAccountManager()
let callbackFunc = (err) => { let callbackFunc = (err) => {
if (err != null) { // Handle the business error. if (err != null) { // handle the bussiness error
console.log("account_osAccount failed, error: " + JSON.stringify(err)); console.log("account_osAccount failed, error: " + JSON.stringify(err));
} else { } else {
console.log("account_osAccount successfully"); console.log("account_osAccount successfully");
...@@ -77,29 +76,159 @@ let callbackFunc = (err) => { ...@@ -77,29 +76,159 @@ let callbackFunc = (err) => {
} }
try { try {
accountMgr.activateOsAccount("100", callbackFunc); accountMgr.activateOsAccount("100", callbackFunc);
} catch (err) { // Process the error that is related to the parameter type. } catch (err) { // handle the parameter type error
console.log("account_osAccount failed for incorrect parameter type, error: " + JSON.stringify(err)); console.log("account_osAccount failed for incorrect parameter type, error: " + JSON.stringify(err));
} }
try { try {
accountMgr.activateOsAccount(); accountMgr.activateOsAccount();
} catch (err) { // Process the error that is related to the parameter quantity. } catch (err) { // handle the parameter number error
console.log("account_osAccount failed for incorrect parameter number, error: " + JSON.stringify(err)); console.log("account_osAccount failed for incorrect parameter number, error: " + JSON.stringify(err));
} }
``` ```
The following uses **registerInputer** as an example to illustrate the error information processing logic of a synchronous API: The following uses **registerInputer** as an example to describe the error information processing logic of a synchronous API:
```ts ```ts
import account_osAccount from "@ohos.account.osAccount" import account_osAccount from "@ohos.account.osAccount"
let pinAuth = new account_osAccount.PINAuth() let pinAuth = new account_osAccount.PINAuth()
try { try {
pinAuth.registerInputer({}) pinAuth.registerInputer({})
} catch (err) { // Process the error that is related to the parameter type. } catch (err) { // handle the parameter type error
console.log("account_osAccount failed for incorrect parameter type, error: " + JSON.stringify(err)); console.log("account_osAccount failed for incorrect parameter type, error: " + JSON.stringify(err));
} }
try { try {
pinAuth.registerInputer() pinAuth.registerInputer()
} catch (err) { // Process the error that is related to the parameter quantity. } catch (err) { // handle the parameter number error
console.log("account_osAccount failed for incorrect parameter number, error: " + JSON.stringify(err)); console.log("account_osAccount failed for incorrect parameter number, error: " + JSON.stringify(err));
} }
``` ```
# Account Subsystem Changelog
## cl.account_os_account.2 Change in Error Information Return of Account System APIs
Some system APIs of the account subsystem use service logic return values to indicate error information, which does not comply with the API error code specifications of OpenHarmony. The following changes are made in API version 9:
Asynchronous APIs: Return error information in the **error** object of **AsyncCallback** or **Promise**.
Synchronous APIs: Throw an exception to return error information.
**Change Impact**
The application developed based on earlier versions needs to be adapted. Otherwise, the service logic will be affected.
**Key API/Component Changes**
Before change:
- class UserAuth
- setProperty(request: SetPropertyRequest, callback: AsyncCallback&lt;number&gt;): void;
- setProperty(request: SetPropertyRequest): Promise&lt;number&gt;;
- cancelAuth(contextID: Uint8Array): number;
- class PINAuth
- registerInputer(inputer: Inputer): boolean;
- UserIdentityManager
- cancel(challenge: Uint8Array): number;
After change:
- class UserAuth
- setProperty(request: SetPropertyRequest, callback: AsyncCallback&lt;void&gt;): void;
- setProperty(request: SetPropertyRequest): Promise&lt;void&gt;;
- cancelAuth(contextID: Uint8Array): void;
- class PINAuth
- registerInputer(inputer: Inputer): void;
- UserIdentityManager
- cancel(challenge: Uint8Array): void;
**Adaptation Guide**
The following uses **setProperty** as an example for asynchronous APIs:
```
import account_osAccount from "@ohos.account.osAccount"
userAuth.setProperty({
authType: account_osAccount.AuthType.PIN,
key: account_osAccount.SetPropertyType.INIT_ALGORITHM,
setInfo: new Uint8Array([0])
}, (err) => {
if (err) {
console.log("setProperty failed, error: " + JSON.stringify(err));
} else {
console.log("setProperty successfully");
}
});
userAuth.setProperty({
authType: account_osAccount.AuthType.PIN,
key: account_osAccount.SetPropertyType.INIT_ALGORITHM,
setInfo: new Uint8Array([0])
}).catch((err) => {
if (err) {
console.log("setProperty failed, error: " + JSON.stringify(err));
} else {
console.log("setProperty successfully");
}
});
```
The following uses **registerInputer** as an example for synchronous APIs:
```
import account_osAccount from "@ohos.account.osAccount"
let pinAuth = new account_osAccount.PINAuth()
let inputer = {
onGetData: (authType, passwordRecipient) => {
let password = new Uint8Array([0]);
passwordRecipient.onSetData(authType, password);
}
}
try {
pinAuth.registerInputer(inputer);
} catch (err) {
console.log("registerInputer failed, error: " + JSON.stringify(err));
}
```
## cl.account_os_account.3 ACTION Definition Change for the Application Account Authentication Service
**Change Impact**
For the application developed based on an earlier version, you need to modify **ACTION** in the application configuration file (**config.json** for the FA model and **module.json5** for the stage model). Otherwise, the application authentication service will be affected.
**Key API/Component Changes**
Involved constant:
@ohos.ability.wantConstant.ACTION_APP_ACCOUNT_AUTH
Before change:
ACTION_APP_ACCOUNT_AUTH = "account.appAccount.action.auth"
After change:
ACTION_APP_ACCOUNT_AUTH = "ohos.appAccount.action.auth"
**Adaptation Guide**
For a third-party application providing the account authentication service, change **ACTION** in the **ServiceAbility** configuration file (**config.json** for the FA module or **module.json5** for the stage module).
```
"abilities": [
{
"name": "ServiceAbility",
"srcEnty": "./ets/ServiceAbility/ServiceAbility.ts",
...
"visible": true,
"skills": {
{
"actions": [
"ohos.appAccount.action.auth"
]
}
}
}]
}
```
...@@ -5,7 +5,7 @@ ...@@ -5,7 +5,7 @@
Changed the following APIs of the **xcomponent** component of the ArkUI subsystem: Changed the following APIs of the **xcomponent** component of the ArkUI subsystem:
- **getXComponentSurfaceId** and **setXComponentSurfaceSize**: Removed the **@systemapi** tag. - **getXComponentSurfaceId** and **setXComponentSurfaceSize**: Removed the **@systemapi** tag.
- **getXComponentSurfaceId**, **getXComponentContext**, and **setXComponentSurfaceSize**: Specified return value types. - **getXComponentSurfaceId**, **getXComponentContext**, and **setXComponentSurfaceSize**: Specified the return value type.
You need to adapt your application based on the following information. You need to adapt your application based on the following information.
...@@ -23,41 +23,40 @@ Released JS APIs are affected. The application needs to adapt these APIs so that ...@@ -23,41 +23,40 @@ Released JS APIs are affected. The application needs to adapt these APIs so that
**Adaptation Guide** **Adaptation Guide**
Startup rules for different scenarios are as follows: Startup rules for different scenarios are as follows:
Adaptions to be made: Adaptions to be made:
- **getXComponentSurfaceId** - **getXComponentSurfaceId**
- In OpenHarmony 3.2 Beta3: - Rule in OpenHarmony 3.2 Beta3:
- System API - System API
- No specified return value - No specified return value
- In OpenHarmony 3.2 Beta4: - OpenHarmony 3.2 Beta4 rules:
- Public API - Public API
- Return value type specified as string - Return value type specified as string
- You need to process the return value as a string. - You need to process the return value as a string.
- **setXComponentSurfaceSize** - **setXComponentSurfaceSize**
- In OpenHarmony 3.2 Beta3: - Rule in OpenHarmony 3.2 Beta3:
- System API - System API
- No specified return value - No specified return value
- In OpenHarmony 3.2 Beta4: - OpenHarmony 3.2 Beta4 rules:
- Public API - Public API
- Return value type specified as void - Return value type specified as void
- You need to process the return value as a void. - You need to process the return value as a void.
- **getXComponentContext** - **getXComponentContext**
- In OpenHarmony 3.2 Beta3: - Rule in OpenHarmony 3.2 Beta3:
- No specified return value - No specified return value
- In OpenHarmony 3.2 Beta4: - OpenHarmony 3.2 Beta4 rules:
- Return value type specified as object - Return value type specified as object
- You need to process the return value as an object. - You need to process the return value as an object.
## cl.arkui.2 Change of Styles of Popup Component and APIs ## cl.arkui.2 Change of Styles of Popup Component and APIs
The styles of the **alertDialog**, **actionSheet**, and **customDialog** components, as well as the **prompt** and **promptAction** APIs were changed. Specifically speaking: Changed the styles of the **alertDialog**, **actionSheet**, and **customDialog** components, as well as the **prompt** and **promptAction** APIs. Specifically speaking:
The popup background blurring effect is added to **promptAction.showDialog**, **promptAction.showActionMenu**, **alertDialog**, **actionSheet**, and **customDialog**. - Added the popup background blur effect to **promptAction.showDialog**, **promptAction.showActionMenu**, **alertDialog**, **actionSheet**, and **customDialog**.
**Change Impact** **Change Impact**
The popup background blurring effect is set by default. The popup background blur effect is set by default.
**Key API/Component Changes** **Key API/Component Changes**
...@@ -70,16 +69,13 @@ No adaptation is required. ...@@ -70,16 +69,13 @@ No adaptation is required.
## cl.arkui.3 Supplementation of the Initialization Mode and Restriction Verification Scenarios of Custom Components' Member Variables ## cl.arkui.3 Supplementation of the Initialization Mode and Restriction Verification Scenarios of Custom Components' Member Variables
Added verification for scenarios previously left out concerning initialization of custom components' member variables.
**Change Impact** **Change Impact**
If custom components' member variables are initialized or assigned with values not according to the document specifications, an error will be reported during compilation. If custom components' member variables are initialized or assigned with values not according to the document specifications, an error will be reported during compilation.
**Key API/Component Changes** **Key API/Component Changes**
N/A N/A.
**Adaptation Guide** **Adaptation Guide**
...@@ -87,24 +83,22 @@ Make modification according to specifications in the above document. ...@@ -87,24 +83,22 @@ Make modification according to specifications in the above document.
## cl.arkui.4 Supplementation of Verification Scenarios of Value Assignment Restrictions on Member Variables of Custom Parent Components and Child Components ## cl.arkui.4 Supplementation of Verification Scenarios of Value Assignment Restrictions on Member Variables of Custom Parent Components and Child Components
Added verification for scenarios previously left out concerning value assignment of member variables of custom parent components and child components.
**Change Impact** **Change Impact**
If member variables of the parent component or child component are initialized not according to the document specifications, an error will be reported during compilation. If member variables of the parent component or child component are initialized not according to the document specifications, an error will be reported during compilation.
**Key API/Component Changes** **Key API/Component Changes**
N/A N/A.
**Adaptation Guide** **Adaptation Guide**
Make modification according to specifications in the above document, using other decorators or normal member variables for value assignment. Make modification according to specifications in the above document, using other decorators or normal member variables for value assignment.
## cl.arkui.5 Supplementation of Verification for a Single Child Component ## cl.arkui.5 Supplementation of Verification for a Single Subcomponent
Added the check rule that allows only one child component to be enabled for the following components: **Button**, **FlowItem**, **GridItem**, **GridCol**, **ListItem**, **Navigator**, **Refresh**, **RichText**, **ScrollBar**, **StepperItem**, and **TabContent**.
Added verification for a single child component for the following components: **Button**, **FlowItem**, **GridItem**, **GridCol**, **ListItem**, **Navigator**, **Refresh**, **RichText**, **ScrollBar**, **StepperItem**, and **TabContent**.
**Change Impact** **Change Impact**
......
# ChangeLog of JS API Changes in the Multimedia Subsystem # Multimedia Subsystem Changelog
Compared with OpenHarmony 3.2 Beta3, OpenHarmony 3.2 Beta4 has the following changes in APIs of the camera component in the multimedia subsystem.
## Camera API Changes ## Camera API Changes
Some functional APIs are added and some others are deprecated to: Some functional APIs are added and some others are deprecated to:
...@@ -8,152 +6,154 @@ Some functional APIs are added and some others are deprecated to: ...@@ -8,152 +6,154 @@ Some functional APIs are added and some others are deprecated to:
2. Help you quickly understand camera APIs and use them for development. 2. Help you quickly understand camera APIs and use them for development.
3. Facilitate expansion of framework functions in later versions, and reduce coupling between framework modules. 3. Facilitate expansion of framework functions in later versions, and reduce coupling between framework modules.
You need to refer to the following change description to adapt your application. You need to refer to the following change description to adapt your application.
**Change Impacts** **Change Impact**
JS APIs in API version 9 are affected. Your application needs to adapt these APIs so that it can properly implement functions in the SDK environment of the new version. JS APIs in API version 9 are affected. Your application needs to adapt these APIs so that it can properly implement features in the SDK environment of the new version.
**Key API/Component Changes** **Key API/Component Changes**
| Module | Class | Method/Attribute/Enumeration/Constant | Change Type| | Module | Class | Method/Attribute/Enum/Constant | Change Type |
| ---------------------- | ----------------------- | ------------------------------------------------------------ | -------- | | ---------------------- | ----------------------- | ------------------------------------------------------------ | -------- |
| ohos.multimedia.camera | Profile | readonly format:CameraFormat; | Added | | ohos.multimedia.camera | Profile | readonly format:CameraFormat; | Added |
| ohos.multimedia.camera | Profile | readonly size: Size; | Added | | ohos.multimedia.camera | Profile | readonly size: Size; | Added |
| ohos.multimedia.camera | FrameRateRange | readonly min: number; | Added | | ohos.multimedia.camera | FrameRateRange | readonly min: number; | Added |
| ohos.multimedia.camera | FrameRateRange | readonly max: number; | Added | | ohos.multimedia.camera | FrameRateRange | readonly max: number; | Added |
| ohos.multimedia.camera | VideoProfile | readonly frameRateRange: FrameRateRange; | Added | | ohos.multimedia.camera | VideoProfile | readonly frameRateRange: FrameRateRange; | Added |
| ohos.multimedia.camera | CameraOutputCapability | readonly previewProfiles: Array<Profile>; | Added | | ohos.multimedia.camera | CameraOutputCapability | readonly previewProfiles: Array\<Profile>; | Added |
| ohos.multimedia.camera | CameraOutputCapability | readonly photoProfiles: Array<Profile>; | Added | | ohos.multimedia.camera | CameraOutputCapability | readonly photoProfiles: Array\<Profile>; | Added |
| ohos.multimedia.camera | CameraOutputCapability | readonly videoProfiles: Array<VideoProfile>; | Added | | ohos.multimedia.camera | CameraOutputCapability | readonly videoProfiles: Array\<VideoProfile>; | Added |
| ohos.multimedia.camera | CameraOutputCapability | readonly supportedMetadataObjectTypes: Array<MetadataObjectType>; | Added | | ohos.multimedia.camera | CameraOutputCapability | readonly supportedMetadataObjectTypes: Array\<MetadataObjectType>; | Added |
| ohos.multimedia.camera | CameraManager | getSupportedCameras(callback: AsyncCallback<Array<CameraDevice>>): void;<br>getSupportedCameras(): Promise<Array<CameraDevice>>; | Added | | ohos.multimedia.camera | CameraManager | getSupportedCameras(callback: AsyncCallback\<Array\<CameraDevice>>): void;<br/>getSupportedCameras(): Promise\<Array\<CameraDevice>>; | Added |
| ohos.multimedia.camera | CameraManager | getSupportedOutputCapability(camera: CameraDevice, callback: AsyncCallback<CameraOutputCapability>): void;<br>getSupportedOutputCapability(camera: CameraDevice): Promise<CameraOutputCapability>; | Added | | ohos.multimedia.camera | CameraManager | getSupportedOutputCapability(camera: CameraDevice, callback: AsyncCallback\<CameraOutputCapability>): void;<br/>getSupportedOutputCapability(camera: CameraDevice): Promise\<CameraOutputCapability>; | Added |
| ohos.multimedia.camera | CameraManager | isCameraMuted(): boolean; | Added | | ohos.multimedia.camera | CameraManager | isCameraMuted(): boolean; | Added |
| ohos.multimedia.camera | CameraManager | isCameraMuteSupported(): boolean; | Added | | ohos.multimedia.camera | CameraManager | isCameraMuteSupported(): boolean; | Added |
| ohos.multimedia.camera | CameraManager | muteCamera(mute: boolean): void; | Added | | ohos.multimedia.camera | CameraManager | muteCamera(mute: boolean): void; | Added |
| ohos.multimedia.camera | CameraManager | createCameraInput(camera: CameraDevice, callback: AsyncCallback<CameraInput>): void;<br>createCameraInput(camera: CameraDevice): Promise<CameraInput>; | Added | | ohos.multimedia.camera | CameraManager | createCameraInput(camera: CameraDevice, callback: AsyncCallback\<CameraInput>): void;<br/>createCameraInput(camera: CameraDevice): Promise\<CameraInput>; | Added |
| ohos.multimedia.camera | CameraManager | createPreviewOutput(profile: Profile, surfaceId: string, callback: AsyncCallback<PreviewOutput>): void;<br>createPreviewOutput(profile: Profile, surfaceId: string): Promise<PreviewOutput>; | Added | | ohos.multimedia.camera | CameraManager | createPreviewOutput(profile: Profile, surfaceId: string, callback: AsyncCallback\<PreviewOutput>): void;<br/>createPreviewOutput(profile: Profile, surfaceId: string): Promise\<PreviewOutput>; | Added |
| ohos.multimedia.camera | CameraManager | createPhotoOutput(profile: Profile, surfaceId: string, callback: AsyncCallback<PhotoOutput>): void;<br>createPhotoOutput(profile: Profile, surfaceId: string): Promise<PhotoOutput>; | Added | | ohos.multimedia.camera | CameraManager | createPhotoOutput(profile: Profile, surfaceId: string, callback: AsyncCallback\<PhotoOutput>): void;<br/>createPhotoOutput(profile: Profile, surfaceId: string): Promise\<PhotoOutput>; | Added |
| ohos.multimedia.camera | CameraManager | createVideoOutput(profile: VideoProfile, surfaceId: string, callback: AsyncCallback<VideoOutput>): void;<br>createVideoOutput(profile: VideoProfile, surfaceId: string): Promise<VideoOutput>; | Added | | ohos.multimedia.camera | CameraManager | createVideoOutput(profile: VideoProfile, surfaceId: string, callback: AsyncCallback\<VideoOutput>): void;<br/>createVideoOutput(profile: VideoProfile, surfaceId: string): Promise\<VideoOutput>; | Added |
| ohos.multimedia.camera | CameraManager | createMetadataOutput(metadataObjectTypes: Array<MetadataObjectType>, callback: AsyncCallback<MetadataOutput>): void;<br>createMetadataOutput(metadataObjectTypes: Array<MetadataObjectType>): Promise<MetadataOutput>; | Added | | ohos.multimedia.camera | CameraManager | createMetadataOutput(metadataObjectTypes: Array\<MetadataObjectType>, callback: AsyncCallback\<MetadataOutput>): void;<br/>createMetadataOutput(metadataObjectTypes: Array\<MetadataObjectType>): Promise\<MetadataOutput>; | Added |
| ohos.multimedia.camera | CameraManager | createCaptureSession(callback: AsyncCallback<CaptureSession>): void;<br>createCaptureSession(): Promise<CaptureSession>; | Added | | ohos.multimedia.camera | CameraManager | createCaptureSession(callback: AsyncCallback\<CaptureSession>): void;<br/>createCaptureSession(): Promise\<CaptureSession>; | Added |
| ohos.multimedia.camera | CameraManager | on(type: 'cameraMute', callback: AsyncCallback<boolean>): void; | Added | | ohos.multimedia.camera | CameraManager | on(type: 'cameraMute', callback: AsyncCallback\<boolean>): void; | Added |
| ohos.multimedia.camera | CameraManager | getCameras(callback: AsyncCallback<Array<Camera>>): void;<br>getCameras(): Promise<Array<Camera>>; | Deprecated | | ohos.multimedia.camera | CameraManager | getCameras(callback: AsyncCallback\<Array\<Camera>>): void;<br/>getCameras(): Promise\<Array\<Camera>>; | Deprecated |
| ohos.multimedia.camera | CameraManager | createCameraInput(cameraId: string, callback: AsyncCallback<CameraInput>): void;<br>createCameraInput(cameraId: string): Promise<CameraInput>; | Deprecated | | ohos.multimedia.camera | CameraManager | createCameraInput(cameraId: string, callback: AsyncCallback\<CameraInput>): void;<br/>createCameraInput(cameraId: string): Promise\<CameraInput>; | Deprecated |
| ohos.multimedia.camera | CameraManager | createCaptureSession(context: Context, callback: AsyncCallback<CaptureSession>): void;<br>createCaptureSession(context: Context): Promise<CaptureSession>; | Deprecated | | ohos.multimedia.camera | CameraManager | createCaptureSession(context: Context, callback: AsyncCallback\<CaptureSession>): void;<br/>createCaptureSession(context: Context): Promise\<CaptureSession>; | Deprecated |
| ohos.multimedia.camera | CameraManager | createPreviewOutput(surfaceId: string, callback: AsyncCallback<PreviewOutput>): void;<br>createPreviewOutput(surfaceId: string): Promise<PreviewOutput>; | Deprecated | | ohos.multimedia.camera | CameraManager | createPreviewOutput(surfaceId: string, callback: AsyncCallback\<PreviewOutput>): void;<br/>createPreviewOutput(surfaceId: string): Promise\<PreviewOutput>; | Deprecated |
| ohos.multimedia.camera | CameraManager | CreatePhotoOutput(surfaceId: string, callback: AsyncCallback<PhotoOutput>): void;<br>CreatePhotoOutput(surfaceId: string): Promise<PhotoOutput>; | Deprecated | | ohos.multimedia.camera | CameraManager | CreatePhotoOutput(surfaceId: string, callback: AsyncCallback\<PhotoOutput>): void;<br/>CreatePhotoOutput(surfaceId: string): Promise\<PhotoOutput>; | Deprecated |
| ohos.multimedia.camera | CameraManager | createVideoOutput(surfaceId: string, callback: AsyncCallback<VideoOutput>): void;<br>createVideoOutput(surfaceId: string): Promise<VideoOutput>; | Deprecated | | ohos.multimedia.camera | CameraManager | createVideoOutput(surfaceId: string, callback: AsyncCallback\<VideoOutput>): void;<br/>createVideoOutput(surfaceId: string): Promise\<VideoOutput>; | Deprecated |
| ohos.multimedia.camera | CameraManager | createMetadataOutput(callback: AsyncCallback<MetadataOutput>): void;<br>createVideoOutput(): Promise<MetadataOutput>; | Deprecated | | ohos.multimedia.camera | CameraManager | createMetadataOutput(callback: AsyncCallback\<MetadataOutput>): void;<br/>createVideoOutput(): Promise\<MetadataOutput>; | Deprecated |
| ohos.multimedia.camera | CameraStatusInfo | camera: CameraDevice; | Added | | ohos.multimedia.camera | CameraStatusInfo | camera: CameraDevice; | Added |
| ohos.multimedia.camera | CameraStatusInfo | camera: Camera; | Deprecated | | ohos.multimedia.camera | CameraStatusInfo | camera: Camera; | Deprecated |
| ohos.multimedia.camera | CameraDevice | interface CameraDevice | Added | | ohos.multimedia.camera | CameraDevice | interface CameraDevice | Added |
| ohos.multimedia.camera | Camera | interface Camera | Deprecated | | ohos.multimedia.camera | Camera | interface Camera | Deprecated |
| ohos.multimedia.camera | CameraInput | open(callback: AsyncCallback<void>): void;<br>open(): Promise<void>; | Added | | ohos.multimedia.camera | CameraInput | open(callback: AsyncCallback\<void>): void;<br/>open(): Promise\<void>; | Added |
| ohos.multimedia.camera | CameraInput | close(callback: AsyncCallback<void>): void;<br>close(): Promise<void>; | Added | | ohos.multimedia.camera | CameraInput | close(callback: AsyncCallback\<void>): void;<br/>close(): Promise\<void>; | Added |
| ohos.multimedia.camera | CameraInput | on(type: 'error', camera: CameraDevice, callback: ErrorCallback<CameraInputError>): void; | Added | | ohos.multimedia.camera | CameraInput | on(type: 'error', camera: CameraDevice, callback: ErrorCallback\<CameraInputError>): void; | Added |
| ohos.multimedia.camera | CameraInput | isFocusModeSupported(afMode: FocusMode, callback: AsyncCallback<boolean>): void;<br>isFocusModeSupported(afMode: FocusMode): Promise<boolean>; | Deprecated | | ohos.multimedia.camera | CameraInput | isFocusModeSupported(afMode: FocusMode, callback: AsyncCallback\<boolean>): void;<br/>isFocusModeSupported(afMode: FocusMode): Promise\<boolean>; | Deprecated |
| ohos.multimedia.camera | CameraInput | getFocusMode(callback: AsyncCallback<FocusMode>): void;<br>getFocusMode(): Promise<FocusMode>; | Deprecated | | ohos.multimedia.camera | CameraInput | getFocusMode(callback: AsyncCallback\<FocusMode>): void;<br/>getFocusMode(): Promise\<FocusMode>; | Deprecated |
| ohos.multimedia.camera | CameraInput | setFocusMode(afMode: FocusMode, callback: AsyncCallback<void>): void;<br>setFocusMode(afMode: FocusMode): Promise<void>; | Deprecated | | ohos.multimedia.camera | CameraInput | setFocusMode(afMode: FocusMode, callback: AsyncCallback\<void>): void;<br/>setFocusMode(afMode: FocusMode): Promise\<void>; | Deprecated |
| ohos.multimedia.camera | CameraInput | getZoomRatioRange(callback: AsyncCallback<Array<number>>): void;<br>getZoomRatioRange(): Promise<Array<number>>; | Deprecated | | ohos.multimedia.camera | CameraInput | getZoomRatioRange(callback: AsyncCallback\<Array\<number>>): void;<br/>getZoomRatioRange(): Promise\<Array\<number>>; | Deprecated |
| ohos.multimedia.camera | CameraInput | getZoomRatio(callback: AsyncCallback<number>): void;<br>getZoomRatio(): Promise<number>; | Deprecated | | ohos.multimedia.camera | CameraInput | getZoomRatio(callback: AsyncCallback\<number>): void;<br/>getZoomRatio(): Promise\<number>; | Deprecated |
| ohos.multimedia.camera | CameraInput | setZoomRatio(zoomRatio: number, callback: AsyncCallback<void>): void;<br>setZoomRatio(zoomRatio: number): Promise<void>; | Deprecated | | ohos.multimedia.camera | CameraInput | setZoomRatio(zoomRatio: number, callback: AsyncCallback\<void>): void;<br/>setZoomRatio(zoomRatio: number): Promise\<void>; | Deprecated |
| ohos.multimedia.camera | CameraInput | getCameraId(callback: AsyncCallback<string>): void;<br>getCameraId(): Promise<string>; | Deprecated | | ohos.multimedia.camera | CameraInput | getCameraId(callback: AsyncCallback\<string>): void;<br/>getCameraId(): Promise\<string>; | Deprecated |
| ohos.multimedia.camera | CameraInput | getExposurePoint(callback: AsyncCallback<Point>): void;<br>getExposurePoint(): Promise<Point>; | Deprecated | | ohos.multimedia.camera | CameraInput | getExposurePoint(callback: AsyncCallback\<Point>): void;<br/>getExposurePoint(): Promise\<Point>; | Deprecated |
| ohos.multimedia.camera | CameraInput | setExposurePoint(exposurePoint: Point, callback: AsyncCallback<void>): void;<br>setExposurePoint(exposurePoint: Point): Promise<void>; | Deprecated | | ohos.multimedia.camera | CameraInput | setExposurePoint(exposurePoint: Point, callback: AsyncCallback\<void>): void;<br/>setExposurePoint(exposurePoint: Point): Promise\<void>; | Deprecated |
| ohos.multimedia.camera | CameraInput | hasFlash(callback: AsyncCallback<boolean>): void;<br>hasFlash(): Promise<boolean>; | Deprecated | | ohos.multimedia.camera | CameraInput | hasFlash(callback: AsyncCallback\<boolean>): void;<br/>hasFlash(): Promise\<boolean>; | Deprecated |
| ohos.multimedia.camera | CameraInput | isFlashModeSupported(flashMode: FlashMode, callback: AsyncCallback<boolean>): void;<br>isFlashModeSupported(flashMode: FlashMode): Promise<boolean>; | Deprecated | | ohos.multimedia.camera | CameraInput | isFlashModeSupported(flashMode: FlashMode, callback: AsyncCallback\<boolean>): void;<br/>isFlashModeSupported(flashMode: FlashMode): Promise\<boolean>; | Deprecated |
| ohos.multimedia.camera | CameraInput | getFlashMode(callback: AsyncCallback<FlashMode>): void;<br>getFlashMode(): Promise<FlashMode>; | Deprecated | | ohos.multimedia.camera | CameraInput | getFlashMode(callback: AsyncCallback\<FlashMode>): void;<br/>getFlashMode(): Promise\<FlashMode>; | Deprecated |
| ohos.multimedia.camera | CameraInput | setFlashMode(flashMode: FlashMode, callback: AsyncCallback<void>): void;<br>setFlashMode(flashMode: FlashMode): Promise<void>; | Deprecated | | ohos.multimedia.camera | CameraInput | setFlashMode(flashMode: FlashMode, callback: AsyncCallback\<void>): void;<br/>setFlashMode(flashMode: FlashMode): Promise\<void>; | Deprecated |
| ohos.multimedia.camera | CameraInput | isExposureModeSupported(aeMode: ExposureMode, callback: AsyncCallback<boolean>): void;<br>isExposureModeSupported(aeMode: ExposureMode): Promise<boolean>; | Deprecated | | ohos.multimedia.camera | CameraInput | isExposureModeSupported(aeMode: ExposureMode, callback: AsyncCallback\<boolean>): void;<br/>isExposureModeSupported(aeMode: ExposureMode): Promise\<boolean>; | Deprecated |
| ohos.multimedia.camera | CameraInput | getExposureMode(callback: AsyncCallback<ExposureMode>): void;<br>getExposureMode(): Promise<ExposureMode>; | Deprecated | | ohos.multimedia.camera | CameraInput | getExposureMode(callback: AsyncCallback\<ExposureMode>): void;<br/>getExposureMode(): Promise\<ExposureMode>; | Deprecated |
| ohos.multimedia.camera | CameraInput | setExposureMode(aeMode: ExposureMode, callback: AsyncCallback<void>): void;<br>setExposureMode(aeMode: ExposureMode): Promise<void>; | Deprecated | | ohos.multimedia.camera | CameraInput | setExposureMode(aeMode: ExposureMode, callback: AsyncCallback\<void>): void;<br/>setExposureMode(aeMode: ExposureMode): Promise\<void>; | Deprecated |
| ohos.multimedia.camera | CameraInput | getMeteringPoint(callback: AsyncCallback<Point>): void;<br>getMeteringPoint(): Promise<Point>; | Deprecated | | ohos.multimedia.camera | CameraInput | getMeteringPoint(callback: AsyncCallback\<Point>): void;<br/>getMeteringPoint(): Promise\<Point>; | Deprecated |
| ohos.multimedia.camera | CameraInput | setMeteringPoint(point: Point, callback: AsyncCallback<void>): void;<br>setMeteringPoint(point: Point): Promise<void>; | Deprecated | | ohos.multimedia.camera | CameraInput | setMeteringPoint(point: Point, callback: AsyncCallback\<void>): void;<br/>setMeteringPoint(point: Point): Promise\<void>; | Deprecated |
| ohos.multimedia.camera | CameraInput | getExposureBiasRange(callback: AsyncCallback<Array<number>>): void;<br>getExposureBiasRange(): Promise<Array<number>>; | Deprecated | | ohos.multimedia.camera | CameraInput | getExposureBiasRange(callback: AsyncCallback\<Array\<number>>): void;<br/>getExposureBiasRange(): Promise\<Array\<number>>; | Deprecated |
| ohos.multimedia.camera | CameraInput | setExposureBias(exposureBias: number, callback: AsyncCallback<void>): void;<br>setExposureBias(exposureBias: number): Promise<void>; | Deprecated | | ohos.multimedia.camera | CameraInput | setExposureBias(exposureBias: number, callback: AsyncCallback\<void>): void;<br/>setExposureBias(exposureBias: number): Promise\<void>; | Deprecated |
| ohos.multimedia.camera | CameraInput | getExposureValue(callback: AsyncCallback<number>): void;<br>getExposureValue(): Promise<number>; | Deprecated | | ohos.multimedia.camera | CameraInput | getExposureValue(callback: AsyncCallback\<number>): void;<br/>getExposureValue(): Promise\<number>; | Deprecated |
| ohos.multimedia.camera | CameraInput | isFocusModeSupported(afMode: FocusMode, callback: AsyncCallback<boolean>): void;<br>isFocusModeSupported(afMode: FocusMode): Promise<boolean>; | Deprecated | | ohos.multimedia.camera | CameraInput | isFocusModeSupported(afMode: FocusMode, callback: AsyncCallback\<boolean>): void;<br/>isFocusModeSupported(afMode: FocusMode): Promise\<boolean>; | Deprecated |
| ohos.multimedia.camera | CameraInput | getFocusMode(callback: AsyncCallback<FocusMode>): void;<br>getFocusMode(): Promise<FocusMode>; | Deprecated | | ohos.multimedia.camera | CameraInput | getFocusMode(callback: AsyncCallback\<FocusMode>): void;<br/>getFocusMode(): Promise\<FocusMode>; | Deprecated |
| ohos.multimedia.camera | CameraInput | setFocusMode(afMode: FocusMode, callback: AsyncCallback<void>): void;<br>setFocusMode(afMode: FocusMode): Promise<void>; | Deprecated | | ohos.multimedia.camera | CameraInput | setFocusMode(afMode: FocusMode, callback: AsyncCallback\<void>): void;<br/>setFocusMode(afMode: FocusMode): Promise\<void>; | Deprecated |
| ohos.multimedia.camera | CameraInput | setFocusPoint(point: Point, callback: AsyncCallback<void>): void;<br>setFocusPoint(point: Point): Promise<void>; | Deprecated | | ohos.multimedia.camera | CameraInput | setFocusPoint(point: Point, callback: AsyncCallback\<void>): void;<br/>setFocusPoint(point: Point): Promise\<void>; | Deprecated |
| ohos.multimedia.camera | CameraInput | getFocusPoint(callback: AsyncCallback<Point>): void;<br>getFocusPoint(): Promise<Point>; | Deprecated | | ohos.multimedia.camera | CameraInput | getFocusPoint(callback: AsyncCallback\<Point>): void;<br/>getFocusPoint(): Promise\<Point>; | Deprecated |
| ohos.multimedia.camera | CameraInput | getFocalLength(callback: AsyncCallback<number>): void;<br>getFocalLength(): Promise<number>; | Deprecated | | ohos.multimedia.camera | CameraInput | getFocalLength(callback: AsyncCallback\<number>): void;<br/>getFocalLength(): Promise\<number>; | Deprecated |
| ohos.multimedia.camera | CameraInput | getZoomRatioRange(callback: AsyncCallback<Array<number>>): void;<br>getZoomRatioRange(): Promise<Array<number>>; | Deprecated | | ohos.multimedia.camera | CameraInput | getZoomRatioRange(callback: AsyncCallback\<Array\<number>>): void;<br/>getZoomRatioRange(): Promise\<Array\<number>>; | Deprecated |
| ohos.multimedia.camera | CameraInput | getZoomRatio(callback: AsyncCallback<number>): void;<br>getZoomRatio(): Promise<number>; | Deprecated | | ohos.multimedia.camera | CameraInput | getZoomRatio(callback: AsyncCallback\<number>): void;<br/>getZoomRatio(): Promise\<number>; | Deprecated |
| ohos.multimedia.camera | CameraInput | setZoomRatio(zoomRatio: number, callback: AsyncCallback<void>): void;<br>setZoomRatio(zoomRatio: number): Promise<void>; | Deprecated | | ohos.multimedia.camera | CameraInput | setZoomRatio(zoomRatio: number, callback: AsyncCallback\<void>): void;<br/>setZoomRatio(zoomRatio: number): Promise\<void>; | Deprecated |
| ohos.multimedia.camera | CameraInput | on(type: 'focusStateChange', callback: AsyncCallback<FocusState>): void; | Deprecated | | ohos.multimedia.camera | CameraInput | on(type: 'focusStateChange', callback: AsyncCallback\<FocusState>): void; | Deprecated |
| ohos.multimedia.camera | CameraInput | on(type: 'exposureStateChange', callback: AsyncCallback<ExposureState>): void; | Deprecated | | ohos.multimedia.camera | CameraInput | on(type: 'exposureStateChange', callback: AsyncCallback\<ExposureState>): void; | Deprecated |
| ohos.multimedia.camera | CameraInput | on(type: 'error', callback: ErrorCallback<CameraInputError>): void; | Deprecated | | ohos.multimedia.camera | CameraInput | on(type: 'error', callback: ErrorCallback\<CameraInputError>): void; | Deprecated |
| ohos.multimedia.camera | CameraInputErrorCode | ERROR_NO_PERMISSION = 0 | Added | | ohos.multimedia.camera | CameraInputErrorCode | ERROR_NO_PERMISSION = 0 | Added |
| ohos.multimedia.camera | CameraInputErrorCode | ERROR_DEVICE_PREEMPTED = 1 | Added | | ohos.multimedia.camera | CameraInputErrorCode | ERROR_DEVICE_PREEMPTED = 1 | Added |
| ohos.multimedia.camera | CameraInputErrorCode | ERROR_DEVICE_DISCONNECTED = 2 | Added | | ohos.multimedia.camera | CameraInputErrorCode | ERROR_DEVICE_DISCONNECTED = 2 | Added |
| ohos.multimedia.camera | CameraInputErrorCode | ERROR_DEVICE_IN_USE = 3 | Added | | ohos.multimedia.camera | CameraInputErrorCode | ERROR_DEVICE_IN_USE = 3 | Added |
| ohos.multimedia.camera | CameraInputErrorCode | ERROR_DRIVER_ERROR = 4 | Added | | ohos.multimedia.camera | CameraInputErrorCode | ERROR_DRIVER_ERROR = 4 | Added |
| ohos.multimedia.camera | CameraFormat | CAMERA_FORMAT_RGBA_8888 = 3 | Added | | ohos.multimedia.camera | CameraFormat | CAMERA_FORMAT_RGBA_8888 = 3 | Added |
| ohos.multimedia.camera | ExposureMode | EXPOSURE_MODE_AUTO = 1 | Added | | ohos.multimedia.camera | ExposureMode | EXPOSURE_MODE_AUTO = 1 | Added |
| ohos.multimedia.camera | ExposureMode | EXPOSURE_MODE_CONTINUOUS_AUTO = 2 | Added | | ohos.multimedia.camera | ExposureMode | EXPOSURE_MODE_CONTINUOUS_AUTO = 2 | Added |
| ohos.multimedia.camera | ExposureMode | EXPOSURE_MODE_AUTO | Deprecated | | ohos.multimedia.camera | ExposureMode | EXPOSURE_MODE_AUTO | Deprecated |
| ohos.multimedia.camera | ExposureMode | EXPOSURE_MODE_CONTINUOUS_AUTO | Deprecated | | ohos.multimedia.camera | ExposureMode | EXPOSURE_MODE_CONTINUOUS_AUTO | Deprecated |
| ohos.multimedia.camera | VideoStabilizationMode | LOW = 1 | Added | | ohos.multimedia.camera | VideoStabilizationMode | LOW = 1 | Added |
| ohos.multimedia.camera | VideoStabilizationMode | MIDDLE = 2 | Added | | ohos.multimedia.camera | VideoStabilizationMode | MIDDLE = 2 | Added |
| ohos.multimedia.camera | VideoStabilizationMode | HIGH = 3 | Added | | ohos.multimedia.camera | VideoStabilizationMode | HIGH = 3 | Added |
| ohos.multimedia.camera | VideoStabilizationMode | AUTO = 4 | Added | | ohos.multimedia.camera | VideoStabilizationMode | AUTO = 4 | Added |
| ohos.multimedia.camera | VideoStabilizationMode | LOW | Deprecated | | ohos.multimedia.camera | VideoStabilizationMode | LOW | Deprecated |
| ohos.multimedia.camera | VideoStabilizationMode | MIDDLE | Deprecated | | ohos.multimedia.camera | VideoStabilizationMode | MIDDLE | Deprecated |
| ohos.multimedia.camera | VideoStabilizationMode | HIGH | Deprecated | | ohos.multimedia.camera | VideoStabilizationMode | HIGH | Deprecated |
| ohos.multimedia.camera | VideoStabilizationMode | AUTO | Deprecated | | ohos.multimedia.camera | VideoStabilizationMode | AUTO | Deprecated |
| ohos.multimedia.camera | CaptureSession | addOutput(cameraOutput: CameraOutput, callback: AsyncCallback<void>): void;<br>addOutput(cameraOutput: CameraOutput): Promise<void>; | Added | | ohos.multimedia.camera | CaptureSession | addOutput(cameraOutput: CameraOutput, callback: AsyncCallback\<void>): void;<br/>addOutput(cameraOutput: CameraOutput): Promise\<void>; | Added |
| ohos.multimedia.camera | CaptureSession | removeOutput(cameraOutput: CameraOutput, callback: AsyncCallback<void>): void;<br>removeOutput(cameraOutput: CameraOutput): Promise<void>; | Added | | ohos.multimedia.camera | CaptureSession | removeOutput(cameraOutput: CameraOutput, callback: AsyncCallback\<void>): void;<br/>removeOutput(cameraOutput: CameraOutput): Promise\<void>; | Added |
| ohos.multimedia.camera | CaptureSession | isVideoStabilizationModeSupported(vsMode: VideoStabilizationMode, callback: AsyncCallback<boolean>): void;<br>isVideoStabilizationModeSupported(vsMode: VideoStabilizationMode): Promise<boolean>; | Added | | ohos.multimedia.camera | CaptureSession | isVideoStabilizationModeSupported(vsMode: VideoStabilizationMode, callback: AsyncCallback\<boolean>): void;<br/>isVideoStabilizationModeSupported(vsMode: VideoStabilizationMode): Promise\<boolean>; | Added |
| ohos.multimedia.camera | CaptureSession | getActiveVideoStabilizationMode(callback: AsyncCallback<VideoStabilizationMode>): void;<br>getActiveVideoStabilizationMode(): Promise<VideoStabilizationMode>; | Added | | ohos.multimedia.camera | CaptureSession | getActiveVideoStabilizationMode(callback: AsyncCallback\<VideoStabilizationMode>): void;<br/>getActiveVideoStabilizationMode(): Promise\<VideoStabilizationMode>; | Added |
| ohos.multimedia.camera | CaptureSession | setVideoStabilizationMode(mode: VideoStabilizationMode, callback: AsyncCallback<void>): void;<br>setVideoStabilizationMode(mode: VideoStabilizationMode): Promise<void>; | Added | | ohos.multimedia.camera | CaptureSession | setVideoStabilizationMode(mode: VideoStabilizationMode, callback: AsyncCallback\<void>): void;<br/>setVideoStabilizationMode(mode: VideoStabilizationMode): Promise\<void>; | Added |
| ohos.multimedia.camera | CaptureSession | on(type: 'focusStateChange', callback: AsyncCallback<FocusState>): void; | Added | | ohos.multimedia.camera | CaptureSession | on(type: 'focusStateChange', callback: AsyncCallback\<FocusState>): void; | Added |
| ohos.multimedia.camera | CaptureSession | hasFlash(callback: AsyncCallback<boolean>): void;<br>hasFlash(): Promise<boolean>; | Added | | ohos.multimedia.camera | CaptureSession | hasFlash(callback: AsyncCallback\<boolean>): void;<br/>hasFlash(): Promise\<boolean>; | Added |
| ohos.multimedia.camera | CaptureSession | isFlashModeSupported(flashMode: FlashMode, callback: AsyncCallback<boolean>): void;<br>isFlashModeSupported(flashMode: FlashMode): Promise<boolean>; | Added | | ohos.multimedia.camera | CaptureSession | isFlashModeSupported(flashMode: FlashMode, callback: AsyncCallback\<boolean>): void;<br/>isFlashModeSupported(flashMode: FlashMode): Promise\<boolean>; | Added |
| ohos.multimedia.camera | CaptureSession | getFlashMode(callback: AsyncCallback<FlashMode>): void;<br>getFlashMode(): Promise<FlashMode>; | Added | | ohos.multimedia.camera | CaptureSession | getFlashMode(callback: AsyncCallback\<FlashMode>): void;<br/>getFlashMode(): Promise\<FlashMode>; | Added |
| ohos.multimedia.camera | CaptureSession | setFlashMode(flashMode: FlashMode, callback: AsyncCallback<void>): void;<br>setFlashMode(flashMode: FlashMode): Promise<void>; | Added | | ohos.multimedia.camera | CaptureSession | setFlashMode(flashMode: FlashMode, callback: AsyncCallback\<void>): void;<br/>setFlashMode(flashMode: FlashMode): Promise\<void>; | Added |
| ohos.multimedia.camera | CaptureSession | isExposureModeSupported(aeMode: ExposureMode, callback: AsyncCallback<boolean>): void;<br>isExposureModeSupported(aeMode: ExposureMode): Promise<boolean>; | Added | | ohos.multimedia.camera | CaptureSession | isExposureModeSupported(aeMode: ExposureMode, callback: AsyncCallback\<boolean>): void;<br/>isExposureModeSupported(aeMode: ExposureMode): Promise\<boolean>; | Added |
| ohos.multimedia.camera | CaptureSession | getExposureMode(callback: AsyncCallback<ExposureMode>): void;<br>getExposureMode(): Promise<ExposureMode>; | Added | | ohos.multimedia.camera | CaptureSession | getExposureMode(callback: AsyncCallback\<ExposureMode>): void;<br/>getExposureMode(): Promise\<ExposureMode>; | Added |
| ohos.multimedia.camera | CaptureSession | setExposureMode(aeMode: ExposureMode, callback: AsyncCallback<void>): void;<br>setExposureMode(aeMode: ExposureMode): Promise<void>; | Added | | ohos.multimedia.camera | CaptureSession | setExposureMode(aeMode: ExposureMode, callback: AsyncCallback\<void>): void;<br/>setExposureMode(aeMode: ExposureMode): Promise\<void>; | Added |
| ohos.multimedia.camera | CaptureSession | getMeteringPoint(callback: AsyncCallback<Point>): void;<br>getMeteringPoint(): Promise<Point>; | Added | | ohos.multimedia.camera | CaptureSession | getMeteringPoint(callback: AsyncCallback\<Point>): void;<br/>getMeteringPoint(): Promise\<Point>; | Added |
| ohos.multimedia.camera | CaptureSession | setMeteringPoint(point: Point, callback: AsyncCallback<void>): void;<br>setMeteringPoint(point: Point): Promise<void>; | Added | | ohos.multimedia.camera | CaptureSession | setMeteringPoint(point: Point, callback: AsyncCallback\<void>): void;<br/>setMeteringPoint(point: Point): Promise\<void>; | Added |
| ohos.multimedia.camera | CaptureSession | getExposureBiasRange(callback: AsyncCallback<Array<number>>): void;<br>getExposureBiasRange(): Promise<Array<number>>; | Added | | ohos.multimedia.camera | CaptureSession | getExposureBiasRange(callback: AsyncCallback\<Array\<number>>): void;<br/>getExposureBiasRange(): Promise\<Array\<number>>; | Added |
| ohos.multimedia.camera | CaptureSession | setExposureBias(exposureBias: number, callback: AsyncCallback<void>): void;<br>setExposureBias(exposureBias: number): Promise<void>; | Added | | ohos.multimedia.camera | CaptureSession | setExposureBias(exposureBias: number, callback: AsyncCallback\<void>): void;<br/>setExposureBias(exposureBias: number): Promise\<void>; | Added |
| ohos.multimedia.camera | CaptureSession | getExposureValue(callback: AsyncCallback<number>): void;<br>getExposureValue(): Promise<number>; | Added | | ohos.multimedia.camera | CaptureSession | getExposureValue(callback: AsyncCallback\<number>): void;<br/>getExposureValue(): Promise\<number>; | Added |
| ohos.multimedia.camera | CaptureSession | isFocusModeSupported(afMode: FocusMode, callback: AsyncCallback<boolean>): void;<br>isFocusModeSupported(afMode: FocusMode): Promise<boolean>; | Added | | ohos.multimedia.camera | CaptureSession | isFocusModeSupported(afMode: FocusMode, callback: AsyncCallback\<boolean>): void;<br/>isFocusModeSupported(afMode: FocusMode): Promise\<boolean>; | Added |
| ohos.multimedia.camera | CaptureSession | getFocusMode(callback: AsyncCallback<FocusMode>): void;<br>getFocusMode(): Promise<FocusMode>; | Added | | ohos.multimedia.camera | CaptureSession | getFocusMode(callback: AsyncCallback\<FocusMode>): void;<br/>getFocusMode(): Promise\<FocusMode>; | Added |
| ohos.multimedia.camera | CaptureSession | setFocusMode(afMode: FocusMode, callback: AsyncCallback<void>): void;<br>setFocusMode(afMode: FocusMode): Promise<void>; | Added | | ohos.multimedia.camera | CaptureSession | setFocusMode(afMode: FocusMode, callback: AsyncCallback\<void>): void;<br/>setFocusMode(afMode: FocusMode): Promise\<void>; | Added |
| ohos.multimedia.camera | CaptureSession | setFocusPoint(point: Point, callback: AsyncCallback<void>): void;<br>setFocusPoint(point: Point): Promise<void>; | Added | | ohos.multimedia.camera | CaptureSession | setFocusPoint(point: Point, callback: AsyncCallback\<void>): void;<br/>setFocusPoint(point: Point): Promise\<void>; | Added |
| ohos.multimedia.camera | CaptureSession | getFocusPoint(callback: AsyncCallback<Point>): void;<br>getFocusPoint(): Promise<Point>; | Added | | ohos.multimedia.camera | CaptureSession | getFocusPoint(callback: AsyncCallback\<Point>): void;<br/>getFocusPoint(): Promise\<Point>; | Added |
| ohos.multimedia.camera | CaptureSession | getFocalLength(callback: AsyncCallback<number>): void;<br>getFocalLength(): Promise<number>; | Added | | ohos.multimedia.camera | CaptureSession | getFocalLength(callback: AsyncCallback\<number>): void;<br/>getFocalLength(): Promise\<number>; | Added |
| ohos.multimedia.camera | CaptureSession | getZoomRatioRange(callback: AsyncCallback<Array<number>>): void;<br>getZoomRatioRange(): Promise<Array<number>>; | Added | | ohos.multimedia.camera | CaptureSession | getZoomRatioRange(callback: AsyncCallback\<Array\<number>>): void;<br/>getZoomRatioRange(): Promise\<Array\<number>>; | Added |
| ohos.multimedia.camera | CaptureSession | getZoomRatio(callback: AsyncCallback<number>): void;<br>getZoomRatio(): Promise<number>; | Added | | ohos.multimedia.camera | CaptureSession | getZoomRatio(callback: AsyncCallback\<number>): void;<br/>getZoomRatio(): Promise\<number>; | Added |
| ohos.multimedia.camera | CaptureSession | setZoomRatio(zoomRatio: number, callback: AsyncCallback<void>): void;<br>setZoomRatio(zoomRatio: number): Promise<void>; | Added | | ohos.multimedia.camera | CaptureSession | setZoomRatio(zoomRatio: number, callback: AsyncCallback\<void>): void;<br/>setZoomRatio(zoomRatio: number): Promise\<void>; | Added |
| ohos.multimedia.camera | CaptureSession | addOutput(previewOutput: PreviewOutput, callback: AsyncCallback<void>): void;<br>addOutput(previewOutput: PreviewOutput): Promise<void>;<br>addOutput(photoOutput: PhotoOutput, callback: AsyncCallback<void>): void;<br>addOutput(photoOutput: PhotoOutput): Promise<void>;<br>addOutput(videoOutput: VideoOutput, callback: AsyncCallback<void>): void;<br>addOutput(videoOutput: VideoOutput): Promise<void>; | Deprecated | | ohos.multimedia.camera | CaptureSession | addOutput(previewOutput: PreviewOutput, callback: AsyncCallback\<void>): void;<br/>addOutput(previewOutput: PreviewOutput): Promise\<void>;<br/>addOutput(photoOutput: PhotoOutput, callback: AsyncCallback\<void>): void;<br/>addOutput(photoOutput: PhotoOutput): Promise\<void>;<br/>addOutput(videoOutput: VideoOutput, callback: AsyncCallback\<void>): void;<br/>addOutput(videoOutput: VideoOutput): Promise\<void>; | Deprecated |
| ohos.multimedia.camera | CaptureSession | removeOutput(previewOutput: PreviewOutput, callback: AsyncCallback<void>): void;<br>removeOutput(previewOutput: PreviewOutput): Promise<void>;<br>removeOutput(photoOutput: PhotoOutput, callback: AsyncCallback<void>): void;<br>removeOutput(photoOutput: PhotoOutput): Promise<void>;removeOutput(videoOutput: VideoOutput, callback: AsyncCallback<void>): void;<br>removeOutput(videoOutput: VideoOutput): Promise<void>;<br>removeOutput(metadataOutput: MetadataOutput, callback: AsyncCallback<void>): void;<br>removeOutput(metadataOutput: MetadataOutput): Promise<void>; | Deprecated | | ohos.multimedia.camera | CaptureSession | removeOutput(previewOutput: PreviewOutput, callback: AsyncCallback\<void>): void;<br/>removeOutput(previewOutput: PreviewOutput): Promise\<void>;<br/>removeOutput(photoOutput: PhotoOutput, callback: AsyncCallback\<void>): void;<br/>removeOutput(photoOutput: PhotoOutput): Promise\<void>;removeOutput(videoOutput: VideoOutput, callback: AsyncCallback\<void>): void;<br/>removeOutput(videoOutput: VideoOutput): Promise\<void>;<br/>removeOutput(metadataOutput: MetadataOutput, callback: AsyncCallback\<void>): void;<br/>removeOutput(metadataOutput: MetadataOutput): Promise\<void>; | Deprecated |
| ohos.multimedia.camera | CaptureSessionErrorCode | ERROR_INSUFFICIENT_RESOURCES = 0 | Added | | ohos.multimedia.camera | CaptureSessionErrorCode | ERROR_INSUFFICIENT_RESOURCES = 0 | Added |
| ohos.multimedia.camera | CaptureSessionErrorCode | ERROR_TIMEOUT = 1 | Added | | ohos.multimedia.camera | CaptureSessionErrorCode | ERROR_TIMEOUT = 1 | Added |
| ohos.multimedia.camera | CameraOutput | release(callback: AsyncCallback<void>): void;<br>release(): Promise<void>; | Added | | ohos.multimedia.camera | CameraOutput | release(callback: AsyncCallback\<void>): void;<br/>release(): Promise\<void>; | Added |
| ohos.multimedia.camera | PreviewOutput | start(callback: AsyncCallback<void>): void;<br>start(): Promise<void>; | Added | | ohos.multimedia.camera | PreviewOutput | start(callback: AsyncCallback\<void>): void;<br/>start(): Promise\<void>; | Added |
| ohos.multimedia.camera | PreviewOutput | stop(callback: AsyncCallback<void>): void;<br>stop(): Promise<void>; | Added | | ohos.multimedia.camera | PreviewOutput | stop(callback: AsyncCallback\<void>): void;<br/>stop(): Promise\<void>; | Added |
| ohos.multimedia.camera | PreviewOutput | release(callback: AsyncCallback<void>): void;<br>release(): Promise<void>; | Deprecated | | ohos.multimedia.camera | PreviewOutput | release(callback: AsyncCallback\<void>): void;<br/>release(): Promise\<void>; | Deprecated |
| ohos.multimedia.camera | PhotoOutput | release(callback: AsyncCallback<void>): void;<br>release(): Promise<void>; | Deprecated | | ohos.multimedia.camera | PhotoOutput | release(callback: AsyncCallback\<void>): void;<br/>release(): Promise\<void>; | Deprecated |
| ohos.multimedia.camera | VideoOutput | release(callback: AsyncCallback<void>): void;<br>release(): Promise<void>; | Deprecated | | ohos.multimedia.camera | VideoOutput | release(callback: AsyncCallback\<void>): void;<br/>release(): Promise\<void>; | Deprecated |
| ohos.multimedia.camera | PhotoCaptureSetting | mirror?: boolean; | Added | | ohos.multimedia.camera | PhotoCaptureSetting | mirror?: boolean; | Added |
| ohos.multimedia.camera | PhotoOutputErrorCode | ERROR_DRIVER_ERROR = 0 | Added | | ohos.multimedia.camera | PhotoOutputErrorCode | ERROR_DRIVER_ERROR = 0 | Added |
| ohos.multimedia.camera | PhotoOutputErrorCode | ERROR_INSUFFICIENT_RESOURCES = 1 | Added | | ohos.multimedia.camera | PhotoOutputErrorCode | ERROR_INSUFFICIENT_RESOURCES = 1 | Added |
| ohos.multimedia.camera | PhotoOutputErrorCode | ERROR_TIMEOUT = 2 | Added | | ohos.multimedia.camera | PhotoOutputErrorCode | ERROR_TIMEOUT = 2 | Added |
| ohos.multimedia.camera | VideoOutputErrorCode | ERROR_DRIVER_ERROR = 0 | Added | | ohos.multimedia.camera | VideoOutputErrorCode | ERROR_DRIVER_ERROR = 0 | Added |
| ohos.multimedia.camera | MetadataObjectType | FACE_DETECTION = 0 | Added | | ohos.multimedia.camera | MetadataObjectType | FACE_DETECTION = 0 | Added |
| ohos.multimedia.camera | MetadataObjectType | FACE = 0 | Deprecated | | ohos.multimedia.camera | MetadataObjectType | FACE = 0 | Deprecated |
| ohos.multimedia.camera | MetadataOutput | on(type: 'error', callback: ErrorCallback<MetadataOutputError>): void; | Added | | ohos.multimedia.camera | MetadataOutput | on(type: 'error', callback: ErrorCallback\<MetadataOutputError>): void; | Added |
| ohos.multimedia.camera | MetadataOutput | setCapturingMetadataObjectTypes(metadataObjectTypes: Array<MetadataObjectType>, callback: AsyncCallback<void>): void;<br>setCapturingMetadataObjectTypes(metadataObjectTypes: Array<MetadataObjectType>): Promise<void>; | Deprecated | | ohos.multimedia.camera | MetadataOutput | setCapturingMetadataObjectTypes(metadataObjectTypes: Array\<MetadataObjectType>, callback: AsyncCallback\<void>): void;<br/>setCapturingMetadataObjectTypes(metadataObjectTypes: Array\<MetadataObjectType>): Promise\<void>; | Deprecated |
| ohos.multimedia.camera | MetadataOutput | getSupportedMetadataObjectTypes(callback: AsyncCallback<Array<MetadataObjectType>>): void;<br>getSupportedMetadataObjectTypes(): Promise<Array<MetadataObjectType>>; | Deprecated | | ohos.multimedia.camera | MetadataOutput | getSupportedMetadataObjectTypes(callback: AsyncCallback\<Array\<MetadataObjectType>>): void;<br/>getSupportedMetadataObjectTypes(): Promise\<Array\<MetadataObjectType>>; | Deprecated |
| ohos.multimedia.camera | MetadataOutputErrorCode | ERROR_UNKNOWN = -1 | Added | | ohos.multimedia.camera | MetadataOutputErrorCode | ERROR_UNKNOWN = -1 | Added |
| ohos.multimedia.camera | MetadataOutputErrorCode | ERROR_INSUFFICIENT_RESOURCES = 0 | Added | | ohos.multimedia.camera | MetadataOutputErrorCode | ERROR_INSUFFICIENT_RESOURCES = 0 | Added |
| ohos.multimedia.camera | MetadataOutputError | code: MetadataOutputErrorCode; | Added | | ohos.multimedia.camera | MetadataOutputError | code: MetadataOutputErrorCode; | Added |
**Adaptation Guide** **Adaptation Guide**
...@@ -181,21 +181,21 @@ In Beta4 and later versions, the following APIs are changed. ...@@ -181,21 +181,21 @@ In Beta4 and later versions, the following APIs are changed.
4. **CameraOutputCapability** API 4. **CameraOutputCapability** API
Attribute 1: readonly previewProfiles; type: Array<Profile> Attribute 1: readonly previewProfiles; type: Array\<Profile>
Attribute 2: readonly photoProfiles; type: Array<Profile> Attribute 2: readonly photoProfiles; type: Array\<Profile>
Attribute 3: readonly videoProfiles; type: Array<VideoProfile> Attribute 3: readonly videoProfiles; type: Array\<VideoProfile>
Attribute 4: readonly supportedMetadataObjectTypes; type: Array<MetadataObjectType> Attribute 4: readonly supportedMetadataObjectTypes; type: Array\<MetadataObjectType>
5. The following APIs are added to **CameraManager**: 5. The following APIs are added to **CameraManager**:
getSupportedOutputCapability(camera: CameraDevice, callback: AsyncCallback<CameraOutputCapability>): void; getSupportedOutputCapability(camera: CameraDevice, callback: AsyncCallback\<CameraOutputCapability>): void;
getSupportedOutputCapability(camera: CameraDevice): Promise<CameraOutputCapability>; getSupportedOutputCapability(camera: CameraDevice): Promise\<CameraOutputCapability>;
The sample code is as follows: The code snippet is as follows:
``` ```
cameraManager.getSupportedCameras().then((cameras) => { cameraManager.getSupportedCameras().then((cameras) => {
...@@ -221,7 +221,7 @@ In Beta4 and later versions, the following APIs are changed. ...@@ -221,7 +221,7 @@ In Beta4 and later versions, the following APIs are changed.
6. The **isCameraMuted(): boolean;** API is added to **CameraManager**. 6. The **isCameraMuted(): boolean;** API is added to **CameraManager**.
The sample code is as follows: The code snippet is as follows:
``` ```
let ismuted = cameraManager.isCameraMuted(); let ismuted = cameraManager.isCameraMuted();
...@@ -229,7 +229,7 @@ In Beta4 and later versions, the following APIs are changed. ...@@ -229,7 +229,7 @@ In Beta4 and later versions, the following APIs are changed.
7. The **isCameraMuteSupported(): boolean;** API is added to **CameraManager**. 7. The **isCameraMuteSupported(): boolean;** API is added to **CameraManager**.
The sample code is as follows: The code snippet is as follows:
``` ```
let ismutesuppotred = cameraManager.isCameraMuteSupported(); let ismutesuppotred = cameraManager.isCameraMuteSupported();
...@@ -237,16 +237,16 @@ In Beta4 and later versions, the following APIs are changed. ...@@ -237,16 +237,16 @@ In Beta4 and later versions, the following APIs are changed.
8. The **muteCamera(mute: boolean): void;** API is added to **CameraManager**. 8. The **muteCamera(mute: boolean): void;** API is added to **CameraManager**.
The sample code is as follows: The code snippet is as follows:
``` ```
let mute = true; let mute = true;
cameraManager.muteCamera(mute); cameraManager.muteCamera(mute);
``` ```
9. The **on(type: 'cameraMute', callback: AsyncCallback<boolean>): void;** API is added to **CameraManager**. 9. The **on(type: 'cameraMute', callback: AsyncCallback\<boolean>): void;** API is added to **CameraManager**.
The sample code is as follows: The code snippet is as follows:
``` ```
cameraManager.on('cameraMute', (err, curMuetd) => { cameraManager.on('cameraMute', (err, curMuetd) => {
...@@ -257,29 +257,29 @@ In Beta4 and later versions, the following APIs are changed. ...@@ -257,29 +257,29 @@ In Beta4 and later versions, the following APIs are changed.
}) })
``` ```
10. The **open(callback: AsyncCallback<void>): void;** and **open(): Promise<void>;** APIs are added to **CameraInput**. 10. The **open(callback: AsyncCallback\<void>): void;** and **open(): Promise\<void>;** APIs are added to **CameraInput**.
The sample code is as follows: The code snippet is as follows:
``` ```
cameraInput.open((err) => { cameraInput.open((err) => {
if (err) { if (err) {
console.error(`Failed to open the camera. ${err.message}`); console.error(`Failed to open the camera. ${err.message}`);
return; return;
} }
console.log('Callback returned with camera opened.'); console.log('Callback returned with camera opened.');
}) })
``` ```
``` ```
cameraInput.open().then(() => { cameraInput.open().then(() => {
console.log('Promise returned with camera opened.'); console.log('Promise returned with camera opened.');
}) })
``` ```
11. The **close(callback: AsyncCallback<void>): void;** and **close(): Promise<void>;** APIs are added to **CameraInput**. 11. The **close(callback: AsyncCallback\<void>): void;** and **close(): Promise\<void>;** APIs are added to **CameraInput**.
The sample code is as follows: The code snippet is as follows:
``` ```
cameraInput.close((err) => { cameraInput.close((err) => {
...@@ -297,25 +297,25 @@ cameraInput.open().then(() => { ...@@ -297,25 +297,25 @@ cameraInput.open().then(() => {
}) })
``` ```
12. The following enumerations are added to **CameraInputErrorCode**: 12. The following enums are added to **CameraInputErrorCode**:
Enumeration: ERROR_NO_PERMISSION; value: 0 Enum: ERROR_NO_PERMISSION; value: 0
Enumeration: ERROR_DEVICE_PREEMPTED; value: 1 Enum: ERROR_DEVICE_PREEMPTED; value: 1
Enumeration: ERROR_DEVICE_DISCONNECTED; value: 2 Enum: ERROR_DEVICE_DISCONNECTED; value: 2
Enumeration: ERROR_DEVICE_IN_USE; value: 3 Enum: ERROR_DEVICE_IN_USE; value: 3
Enumeration: ERROR_DRIVER_ERROR; value: 4 Enum: ERROR_DRIVER_ERROR; value: 4
13. The following enumeration is added to **CameraFormat**: 13. The following enum is added to **CameraFormat**:
Enumeration: CAMERA_FORMAT_RGBA_8888; value: 3 Enum: CAMERA_FORMAT_RGBA_8888; value: 3
14. The **getMeteringPoint(callback: AsyncCallback<Point>): void;** and **getMeteringPoint(): Promise<Point>;** APIs are added to **CaptureSession**. 14. The **getMeteringPoint(callback: AsyncCallback\<Point>): void;** and **getMeteringPoint(): Promise\<Point>;** APIs are added to **CaptureSession**.
The sample code is as follows: The code snippet is as follows:
``` ```
captureSession.getMeteringPoint((err, exposurePoint) => { captureSession.getMeteringPoint((err, exposurePoint) => {
...@@ -333,9 +333,9 @@ cameraInput.open().then(() => { ...@@ -333,9 +333,9 @@ cameraInput.open().then(() => {
}) })
``` ```
15. The **setMeteringPoint(point: Point, callback: AsyncCallback<void>): void;** and **setMeteringPoint(point: Point): Promise<void>;** APIs are added to **CaptureSession**. 15. The **setMeteringPoint(point: Point, callback: AsyncCallback\<void>): void;** and **setMeteringPoint(point: Point): Promise\<void>;** APIs are added to **CaptureSession**.
The sample code is as follows: The code snippet is as follows:
``` ```
const Point1 = {x: 1, y: 1}; const Point1 = {x: 1, y: 1};
...@@ -357,13 +357,13 @@ cameraInput.open().then(() => { ...@@ -357,13 +357,13 @@ cameraInput.open().then(() => {
}) })
``` ```
16. The following enumerations are added to **CaptureSessionErrorCode**: 16. The following enums are added to **CaptureSessionErrorCode**:
Enumeration: ERROR_INSUFFICIENT_RESOURCES; value: 0 Enum: ERROR_INSUFFICIENT_RESOURCES; value: 0
Enumeration: ERROR_TIMEOUT; value: 1 Enum: ERROR_TIMEOUT; value: 1
17. The **CameraOutput** API is added and contains the **release(callback: AsyncCallback<void>): void;** and **release(): Promise<void>;** methods. 17. The **CameraOutput** API is added and contains the **release(callback: AsyncCallback\<void>): void;** and **release(): Promise\<void>;** methods.
The sample code (for **previewOutput**) is as follows: The sample code (for **previewOutput**) is as follows:
...@@ -383,9 +383,9 @@ cameraInput.open().then(() => { ...@@ -383,9 +383,9 @@ cameraInput.open().then(() => {
}) })
``` ```
18. The **start(callback: AsyncCallback<void>): void;** and **start(): Promise<void>;** APIs are added to **PreviewOutput**. 18. The **start(callback: AsyncCallback\<void>): void;** and **start(): Promise\<void>;** APIs are added to **PreviewOutput**.
The sample code is as follows: The code snippet is as follows:
``` ```
previewOutput.start((err) => { previewOutput.start((err) => {
...@@ -403,9 +403,9 @@ cameraInput.open().then(() => { ...@@ -403,9 +403,9 @@ cameraInput.open().then(() => {
}) })
``` ```
19. The **stop(callback: AsyncCallback<void>): void;** and **stop(): Promise<void>;** APIs are added to **PreviewOutput**. 19. The **stop(callback: AsyncCallback\<void>): void;** and **stop(): Promise\<void>;** APIs are added to **PreviewOutput**.
The sample code is as follows: The code snippet is as follows:
``` ```
previewOutput.stop((err) => { previewOutput.stop((err) => {
...@@ -427,21 +427,21 @@ cameraInput.open().then(() => { ...@@ -427,21 +427,21 @@ cameraInput.open().then(() => {
Attribute 1: mirror?; type: boolean Attribute 1: mirror?; type: boolean
21. The following enumerations are added to **PhotoOutputErrorCode**: 21. The following enums are added to **PhotoOutputErrorCode**:
Enumeration: ERROR_DRIVER_ERROR; value: 0 Enum: ERROR_DRIVER_ERROR; value: 0
Enumeration: ERROR_INSUFFICIENT_RESOURCES; value: 1 Enum: ERROR_INSUFFICIENT_RESOURCES; value: 1
Enumeration: ERROR_TIMEOUT; value: 2 Enum: ERROR_TIMEOUT; value: 2
22. The following enumeration is added to **VideoOutputErrorCode**: 22. The following enum is added to **VideoOutputErrorCode**:
Enumeration: ERROR_DRIVER_ERROR; value: 0 Enum: ERROR_DRIVER_ERROR; value: 0
23. The **on(type: 'error', callback: ErrorCallback<MetadataOutputError>): void;** API is added to **MetadataOutput**. 23. The **on(type: 'error', callback: ErrorCallback\<MetadataOutputError>): void;** API is added to **MetadataOutput**.
The sample code is as follows: The code snippet is as follows:
``` ```
metadataOutput.on('error', (metadataOutputError) => { metadataOutput.on('error', (metadataOutputError) => {
...@@ -449,11 +449,11 @@ cameraInput.open().then(() => { ...@@ -449,11 +449,11 @@ cameraInput.open().then(() => {
}) })
``` ```
24. The following enumerations are added to **MetadataOutputErrorCode**. 24. The following enums are added to **MetadataOutputErrorCode**.
Enumeration: ERROR_UNKNOWN; value: -1 Enum: ERROR_UNKNOWN; value: -1
Enumeration: ERROR_INSUFFICIENT_RESOURCES; value: 0 Enum: ERROR_INSUFFICIENT_RESOURCES; value: 0
25. **MetadataOutputError** API 25. **MetadataOutputError** API
...@@ -461,35 +461,35 @@ cameraInput.open().then(() => { ...@@ -461,35 +461,35 @@ cameraInput.open().then(() => {
**Deprecated APIs** **Deprecated APIs**
1. The **on(type: 'exposureStateChange', callback: AsyncCallback<ExposureState>): void;** API in **CameraInput** is deprecated. 1. The **on(type: 'exposureStateChange', callback: AsyncCallback\<ExposureState>): void;** API in **CameraInput** is deprecated.
2. The **release(callback: AsyncCallback<void>): void;** and **release(): Promise<void>;** APIs in **previewOutput** are deprecated. 2. The **release(callback: AsyncCallback\<void>): void;** and **release(): Promise\<void>;** APIs in **previewOutput** are deprecated.
3. The following APIs in **metadataOutput** are deprecated: 3. The following APIs in **metadataOutput** are deprecated:
setCapturingMetadataObjectTypes(metadataObjectTypes: Array<MetadataObjectType>, callback: AsyncCallback<void>): void;<br>setCapturingMetadataObjectTypes(metadataObjectTypes: Array<MetadataObjectType>): Promise<void>; setCapturingMetadataObjectTypes(metadataObjectTypes: Array\<MetadataObjectType>, callback: AsyncCallback\<void>): void;\<br/>setCapturingMetadataObjectTypes(metadataObjectTypes: Array\<MetadataObjectType>): Promise\<void>;
4. The following APIs in **metadataOutput** are deprecated: 4. The following APIs in **metadataOutput** are deprecated:
getSupportedMetadataObjectTypes(callback: AsyncCallback<Array<MetadataObjectType>>): void;<br>getSupportedMetadataObjectTypes(): Promise<Array<MetadataObjectType>>; getSupportedMetadataObjectTypes(callback: AsyncCallback\<Array\<MetadataObjectType>>): void;<br/>getSupportedMetadataObjectTypes(): Promise\<Array\<MetadataObjectType>>;
5. The **release(callback: AsyncCallback<void>): void;** and **release(): Promise<void>;** APIs in **PreviewOutput** are deprecated. 5. The **release(callback: AsyncCallback\<void>): void;** and **release(): Promise\<void>;** APIs in **PreviewOutput** are deprecated.
6. The **release(callback: AsyncCallback<void>): void;** and **release(): Promise<void>;** APIs in **PhotoOutput** are deprecated. 6. The **release(callback: AsyncCallback\<void>): void;** and **release(): Promise\<void>;** APIs in **PhotoOutput** are deprecated.
7. The **release(callback: AsyncCallback<void>): void;** and **release(): Promise<void>;** APIs in **VideoOutput** are deprecated. 7. The **release(callback: AsyncCallback\<void>): void;** and **release(): Promise\<void>;** APIs in **VideoOutput** are deprecated.
8. The **getCameraId(callback: AsyncCallback<string>): void;** and **getCameraId(): Promise<string>;** APIs in **CameraInput** are deprecated. 8. The **getCameraId(callback: AsyncCallback\<string>): void;** and **getCameraId(): Promise\<string>;** APIs in **CameraInput** are deprecated.
9. The **getExposurePoint(callback: AsyncCallback<Point>): void;** and **getExposurePoint(): Promise<Point>;** APIs in **CameraInput** are deprecated. 9. The **getExposurePoint(callback: AsyncCallback\<Point>): void;** and **getExposurePoint(): Promise\<Point>;** APIs in **CameraInput** are deprecated.
10. The **setExposurePoint(exposurePoint: Point, callback: AsyncCallback<void>): void;** and **setExposurePoint(exposurePoint: Point): Promise<void>;** APIs in **CameraInput** are deprecated. 10. The **setExposurePoint(exposurePoint: Point, callback: AsyncCallback\<void>): void;** and **setExposurePoint(exposurePoint: Point): Promise\<void>;** APIs in **CameraInput** are deprecated.
**Changed APIs** **Changed APIs**
1. In **CameraManager**, the return value of **getCameras** is changed from **Array<Camera>** to **Array<CameraDevice>**, and the API name is changed from **getCameras** to **getSupportedCameras**. Therefore, the **getCameras(callback: AsyncCallback<Array<Camera>>): void;** and **getCameras(): Promise<Array<Camera>>;** APIs are changed to **getSupportedCameras(callback: AsyncCallback<Array<CameraDevice>>): void** and **getSupportedCameras(): Promise<Array<CameraDevice>>;**. 1. In **CameraManager**, the return value of **getCameras** is changed from **Array\<Camera>** to **Array\<CameraDevice>**, and the API name is changed from **getCameras** to **getSupportedCameras**. Therefore, the **getCameras(callback: AsyncCallback\<Array\<Camera>>): void;** and **getCameras(): Promise\<Array\<Camera>>;** APIs are changed to **getSupportedCameras(callback: AsyncCallback\<Array\<CameraDevice>>): void** and **getSupportedCameras(): Promise\<Array\<CameraDevice>>;**.
The sample code is as follows: The code snippet is as follows:
``` ```
cameraManager.getSupportedCameras((err, cameras) => { cameraManager.getSupportedCameras((err, cameras) => {
...@@ -507,9 +507,9 @@ cameraInput.open().then(() => { ...@@ -507,9 +507,9 @@ cameraInput.open().then(() => {
}) })
``` ```
2. In **CameraManager**, the input parameter of **createCameraInput** is changed from **cameraId: string** to **camera: CameraDevice**. Therefore, the **createCameraInput(cameraId: string, callback: AsyncCallback<CameraInput>): void;** and **createCameraInput(cameraId: string): Promise<CameraInput>;** APIs are changed to **createCameraInput(camera: CameraDevice, callback: AsyncCallback<CameraInput>): void;** and **createCameraInput(camera: CameraDevice): Promise<CameraInput>;**. 2. In **CameraManager**, the input parameter of **createCameraInput** is changed from **cameraId: string** to **camera: CameraDevice**. Therefore, the **createCameraInput(cameraId: string, callback: AsyncCallback\<CameraInput>): void;** and **createCameraInput(cameraId: string): Promise\<CameraInput>;** APIs are changed to **createCameraInput(camera: CameraDevice, callback: AsyncCallback\<CameraInput>): void;** and **createCameraInput(camera: CameraDevice): Promise\<CameraInput>;**.
The sample code is as follows: The code snippet is as follows:
``` ```
let cameraDevice = cameras[0]; let cameraDevice = cameras[0];
...@@ -529,9 +529,9 @@ cameraInput.open().then(() => { ...@@ -529,9 +529,9 @@ cameraInput.open().then(() => {
}) })
``` ```
3. In **CameraManager**, the input parameter **profile: Profile** is added to **createPreviewOutput** and the **profile** parameter is obtained by the **getSupportedOutputCapability** API. Therefore, the **createPreviewOutput(surfaceId: string, callback: AsyncCallback<PreviewOutput>): void;** and **createPreviewOutput(surfaceId: string): Promise<PreviewOutput>;** APIs are changed to **createPreviewOutput(profile: Profile, surfaceId: string, callback: AsyncCallback<PreviewOutput>): void;** and **createPreviewOutput(profile: Profile, surfaceId: string): Promise<PreviewOutput>;**. 3. In **CameraManager**, the input parameter **profile: Profile** is added to **createPreviewOutput** and the **profile** parameter is obtained by the **getSupportedOutputCapability** API. Therefore, the **createPreviewOutput(surfaceId: string, callback: AsyncCallback\<PreviewOutput>): void;** and **createPreviewOutput(surfaceId: string): Promise\<PreviewOutput>;** APIs are changed to **createPreviewOutput(profile: Profile, surfaceId: string, callback: AsyncCallback\<PreviewOutput>): void;** and **createPreviewOutput(profile: Profile, surfaceId: string): Promise\<PreviewOutput>;**.
The sample code is as follows: The code snippet is as follows:
``` ```
let profile = cameraoutputcapability.previewProfiles[0]; let profile = cameraoutputcapability.previewProfiles[0];
...@@ -551,9 +551,9 @@ cameraInput.open().then(() => { ...@@ -551,9 +551,9 @@ cameraInput.open().then(() => {
}) })
``` ```
4. In **CameraManager**, the input parameter **profile: Profile** is added to **createPhotoOutput** and the **profile** parameter is obtained by the **getSupportedOutputCapability** API. Therefore, the **CreatePhotoOutput(surfaceId: string, callback: AsyncCallback<PhotoOutput>): void;** and **CreatePhotoOutput(surfaceId: string): Promise<PhotoOutput>;** APIs are changed to **createPhotoOutput(profile: Profile, surfaceId: string, callback: AsyncCallback<PhotoOutput>): void;** and **createPhotoOutput(profile: Profile, surfaceId: string): Promise<PhotoOutput>;**. 4. In **CameraManager**, the input parameter **profile: Profile** is added to **createPhotoOutput** and the **profile** parameter is obtained by the **getSupportedOutputCapability** API. Therefore, the **CreatePhotoOutput(surfaceId: string, callback: AsyncCallback\<PhotoOutput>): void;** and **CreatePhotoOutput(surfaceId: string): Promise\<PhotoOutput>;** APIs are changed to **createPhotoOutput(profile: Profile, surfaceId: string, callback: AsyncCallback\<PhotoOutput>): void;** and **createPhotoOutput(profile: Profile, surfaceId: string): Promise\<PhotoOutput>;**.
The sample code is as follows: The code snippet is as follows:
``` ```
let profile = cameraoutputcapability.photoProfiles[0]; let profile = cameraoutputcapability.photoProfiles[0];
...@@ -573,9 +573,9 @@ cameraInput.open().then(() => { ...@@ -573,9 +573,9 @@ cameraInput.open().then(() => {
}) })
``` ```
5. In **CameraManager**, the input parameter **profile: Profile** is added to **createVideoOutput** and the **profile** parameter is obtained by the **getSupportedOutputCapability** API. Therefore, the **createVideoOutput(surfaceId: string, callback: AsyncCallback<VideoOutput>): void;** and **createVideoOutput(surfaceId: string): Promise<VideoOutput>;** APIs are changed to **createVideoOutput(profile: VideoProfile, surfaceId: string, callback: AsyncCallback<VideoOutput>): void;** and **createVideoOutput(profile: VideoProfile, surfaceId: string): Promise<VideoOutput>;**. 5. In **CameraManager**, the input parameter **profile: Profile** is added to **createVideoOutput** and the **profile** parameter is obtained by the **getSupportedOutputCapability** API. Therefore, the **createVideoOutput(surfaceId: string, callback: AsyncCallback\<VideoOutput>): void;** and **createVideoOutput(surfaceId: string): Promise\<VideoOutput>;** APIs are changed to **createVideoOutput(profile: VideoProfile, surfaceId: string, callback: AsyncCallback\<VideoOutput>): void;** and **createVideoOutput(profile: VideoProfile, surfaceId: string): Promise\<VideoOutput>;**.
The sample code is as follows: The code snippet is as follows:
``` ```
let profile = cameraoutputcapability.videoProfiles[0]; let profile = cameraoutputcapability.videoProfiles[0];
...@@ -595,9 +595,9 @@ cameraInput.open().then(() => { ...@@ -595,9 +595,9 @@ cameraInput.open().then(() => {
}) })
``` ```
6. In **CameraManager**, the input parameter **metadataObjectTypes: Array<MetadataObjectType>** is added to **createMetadataOutput**, and the **metadataObjectTypes** parameter is obtained by the **getSupportedOutputCapability** API. Therefore, the **function createMetadataOutput(callback: AsyncCallback<MetadataOutput>): void;** and **function createMetadataOutput(): Promise<MetadataOutput>;** APIs are changed to **createMetadataOutput(metadataObjectTypes: Array<MetadataObjectType>, callback: AsyncCallback<MetadataOutput>): void;** and **createMetadataOutput(metadataObjectTypes: Array<MetadataObjectType>): Promise<MetadataOutput>;**. 6. In **CameraManager**, the input parameter **metadataObjectTypes: Array\<MetadataObjectType>** is added to **createMetadataOutput**, and the **metadataObjectTypes** parameter is obtained by the **getSupportedOutputCapability** API. Therefore, the **function createMetadataOutput(callback: AsyncCallback\<MetadataOutput>): void;** and **function createMetadataOutput(): Promise\<MetadataOutput>;** APIs are changed to **createMetadataOutput(metadataObjectTypes: Array\<MetadataObjectType>, callback: AsyncCallback\<MetadataOutput>): void;** and **createMetadataOutput(metadataObjectTypes: Array\<MetadataObjectType>): Promise\<MetadataOutput>;**.
The sample code is as follows: The code snippet is as follows:
``` ```
let metadataObjectTypes = cameraoutputcapability.supportedMetadataObjectTypes; let metadataObjectTypes = cameraoutputcapability.supportedMetadataObjectTypes;
...@@ -617,9 +617,9 @@ cameraInput.open().then(() => { ...@@ -617,9 +617,9 @@ cameraInput.open().then(() => {
}) })
``` ```
7. In **CameraManager**, **createCaptureSession** does not need to consider the context attribute. Therefore, the **createCaptureSession(context: Context, callback: AsyncCallback<CaptureSession>): void;** and **createCaptureSession(context: Context): Promise<CaptureSession>;** APIs are changed to **createCaptureSession(callback: AsyncCallback<CaptureSession>): void;** and **createCaptureSession(): Promise<CaptureSession>;**. 7. In **CameraManager**, **createCaptureSession** does not need to consider the context attribute. Therefore, the **createCaptureSession(context: Context, callback: AsyncCallback\<CaptureSession>): void;** and **createCaptureSession(context: Context): Promise\<CaptureSession>;** APIs are changed to **createCaptureSession(callback: AsyncCallback\<CaptureSession>): void;** and **createCaptureSession(): Promise\<CaptureSession>;**.
The sample code is as follows: The code snippet is as follows:
```typescript ```typescript
cameraManager.createCaptureSession((err, captureSession) => { cameraManager.createCaptureSession((err, captureSession) => {
...@@ -639,9 +639,9 @@ cameraInput.open().then(() => { ...@@ -639,9 +639,9 @@ cameraInput.open().then(() => {
8. The type of the **camera** attribute of the **CameraStatusInfo** API is changed from **Camera** to **CameraDevice**. 8. The type of the **camera** attribute of the **CameraStatusInfo** API is changed from **Camera** to **CameraDevice**.
9. In **CameraInput**, the input parameter **camera: CameraDevice** is added to the **on(type: 'error')** API. Therefore, the **on(type: 'error', callback: ErrorCallback<CameraInputError>): void;** API is changed to **on(type: 'error', camera: CameraDevice, callback: ErrorCallback<CameraInputError>): void;**. 9. In **CameraInput**, the input parameter **camera: CameraDevice** is added to the **on(type: 'error')** API. Therefore, the **on(type: 'error', callback: ErrorCallback\<CameraInputError>): void;** API is changed to **on(type: 'error', camera: CameraDevice, callback: ErrorCallback\<CameraInputError>): void;**.
The sample code is as follows: The code snippet is as follows:
``` ```
let cameraDevice = cameras[0]; let cameraDevice = cameras[0];
...@@ -652,51 +652,51 @@ cameraInput.open().then(() => { ...@@ -652,51 +652,51 @@ cameraInput.open().then(() => {
10. The following APIs are moved from **CameraInput** to **CaptureSession**: 10. The following APIs are moved from **CameraInput** to **CaptureSession**:
hasFlash(callback: AsyncCallback<boolean>): void;<br>hasFlash(): Promise<boolean>;<br> hasFlash(callback: AsyncCallback\<boolean>): void;<br/>hasFlash(): Promise\<boolean>;<br/>
isFlashModeSupported(flashMode: FlashMode, callback: AsyncCallback<boolean>): void;<br>isFlashModeSupported(flashMode: FlashMode): Promise<boolean>;<br> isFlashModeSupported(flashMode: FlashMode, callback: AsyncCallback\<boolean>): void;<br/>isFlashModeSupported(flashMode: FlashMode): Promise\<boolean>;<br/>
getFlashMode(callback: AsyncCallback<FlashMode>): void;<br>getFlashMode(): Promise<FlashMode>;<br> getFlashMode(callback: AsyncCallback\<FlashMode>): void;<br/>getFlashMode(): Promise\<FlashMode>;<br/>
setFlashMode(flashMode: FlashMode, callback: AsyncCallback<void>): void;<br>setFlashMode(flashMode: FlashMode): Promise<void>;<br> setFlashMode(flashMode: FlashMode, callback: AsyncCallback\<void>): void;<br/>setFlashMode(flashMode: FlashMode): Promise\<void>;<br/>
isExposureModeSupported(aeMode: ExposureMode, callback: AsyncCallback<boolean>): void;<br>isExposureModeSupported(aeMode: ExposureMode): Promise<boolean>;<br> isExposureModeSupported(aeMode: ExposureMode, callback: AsyncCallback\<boolean>): void;<br/>isExposureModeSupported(aeMode: ExposureMode): Promise\<boolean>;<br/>
getExposureMode(callback: AsyncCallback<ExposureMode>): void;<br>getExposureMode(): Promise<ExposureMode>;<br> getExposureMode(callback: AsyncCallback\<ExposureMode>): void;<br/>getExposureMode(): Promise\<ExposureMode>;<br/>
setExposureMode(aeMode: ExposureMode, callback: AsyncCallback<void>): void;<br>setExposureMode(aeMode: ExposureMode): Promise<void>;<br> setExposureMode(aeMode: ExposureMode, callback: AsyncCallback\<void>): void;<br/>setExposureMode(aeMode: ExposureMode): Promise\<void>;<br/>
getMeteringPoint(callback: AsyncCallback<Point>): void;<br>getMeteringPoint(): Promise<Point>;<br> getMeteringPoint(callback: AsyncCallback\<Point>): void;<br/>getMeteringPoint(): Promise\<Point>;<br/>
setMeteringPoint(point: Point, callback: AsyncCallback<void>): void;<br>setMeteringPoint(point: Point): Promise<void>;<br> setMeteringPoint(point: Point, callback: AsyncCallback\<void>): void;<br/>setMeteringPoint(point: Point): Promise\<void>;<br/>
getExposureBiasRange(callback: AsyncCallback<Array<number>>): void;<br>getExposureBiasRange(): Promise<Array<number>>;<br> getExposureBiasRange(callback: AsyncCallback\<Array\<number>>): void;<br/>getExposureBiasRange(): Promise\<Array\<number>>;<br/>
setExposureBias(exposureBias: number, callback: AsyncCallback<void>): void;<br>setExposureBias(exposureBias: number): Promise<void>;<br> setExposureBias(exposureBias: number, callback: AsyncCallback\<void>): void;<br/>setExposureBias(exposureBias: number): Promise\<void>;<br/>
getExposureValue(callback: AsyncCallback<number>): void;<br>getExposureValue(): Promise<number>;<br> getExposureValue(callback: AsyncCallback\<number>): void;<br/>getExposureValue(): Promise\<number>;<br/>
isFocusModeSupported(afMode: FocusMode, callback: AsyncCallback<boolean>): void;<br>isFocusModeSupported(afMode: FocusMode): Promise<boolean>;<br> isFocusModeSupported(afMode: FocusMode, callback: AsyncCallback\<boolean>): void;<br/>isFocusModeSupported(afMode: FocusMode): Promise\<boolean>;<br/>
getFocusMode(callback: AsyncCallback<FocusMode>): void;<br>getFocusMode(): Promise<FocusMode>;<br> getFocusMode(callback: AsyncCallback\<FocusMode>): void;<br/>getFocusMode(): Promise\<FocusMode>;<br/>
setFocusMode(afMode: FocusMode, callback: AsyncCallback<void>): void;<br>setFocusMode(afMode: FocusMode): Promise<void>;<br> setFocusMode(afMode: FocusMode, callback: AsyncCallback\<void>): void;<br/>setFocusMode(afMode: FocusMode): Promise\<void>;<br/>
setFocusPoint(point: Point, callback: AsyncCallback<void>): void;<br>setFocusPoint(point: Point): Promise<void>;<br> setFocusPoint(point: Point, callback: AsyncCallback\<void>): void;<br/>setFocusPoint(point: Point): Promise\<void>;<br/>
getFocusPoint(callback: AsyncCallback<Point>): void;<br>getFocusPoint(): Promise<Point>;<br> getFocusPoint(callback: AsyncCallback\<Point>): void;<br/>getFocusPoint(): Promise\<Point>;<br/>
getFocalLength(callback: AsyncCallback<number>): void;<br>getFocalLength(): Promise<number>;<br> getFocalLength(callback: AsyncCallback\<number>): void;<br/>getFocalLength(): Promise\<number>;<br/>
getZoomRatioRange(callback: AsyncCallback<Array<number>>): void;<br>getZoomRatioRange(): Promise<Array<number>>;<br> getZoomRatioRange(callback: AsyncCallback\<Array\<number>>): void;<br/>getZoomRatioRange(): Promise\<Array\<number>>;<br/>
getZoomRatio(callback: AsyncCallback<number>): void;<br>getZoomRatio(): Promise<number>;<br> getZoomRatio(callback: AsyncCallback\<number>): void;<br/>getZoomRatio(): Promise\<number>;<br/>
setZoomRatio(zoomRatio: number, callback: AsyncCallback<void>): void;<br>setZoomRatio(zoomRatio: number): Promise<void>; setZoomRatio(zoomRatio: number, callback: AsyncCallback\<void>): void;<br/>setZoomRatio(zoomRatio: number): Promise\<void>;
11. The **on(type: 'focusStateChange', callback: AsyncCallback<FocusState>): void;** API is moved from **CameraInput** to **CaptureSession**. 11. The **on(type: 'focusStateChange', callback: AsyncCallback\<FocusState>): void;** API is moved from **CameraInput** to **CaptureSession**.
The sample code is as follows: The code snippet is as follows:
``` ```
captureSession.on('focusStateChange', (focusState) => { captureSession.on('focusStateChange', (focusState) => {
...@@ -704,33 +704,33 @@ cameraInput.open().then(() => { ...@@ -704,33 +704,33 @@ cameraInput.open().then(() => {
}) })
``` ```
12. The following enumerations are added to **ExposureMode**: 12. The following enums are added to **ExposureMode**:
Enumeration: EXPOSURE_MODE_AUTO; initial value: changed from the default value to **1** Enum: EXPOSURE_MODE_AUTO; initial value: changed from the default value to **1**
Enumeration: EXPOSURE_MODE_CONTINUOUS_AUTO; initial value: changed from the default value to **2** Enum: EXPOSURE_MODE_CONTINUOUS_AUTO; initial value: changed from the default value to **2**
13. The following enumerations are added to **VideoStabilizationMode**: 13. The following enums are added to **VideoStabilizationMode**:
Enumeration: LOW; initial value: changed from the default value to **1** Enum: LOW; initial value: changed from the default value to **1**
Enumeration: MIDDLE; initial value: changed from the default value to **2** Enum: MIDDLE; initial value: changed from the default value to **2**
Enumeration: HIGH; initial value: changed from the default value to **3** Enum: HIGH; initial value: changed from the default value to **3**
Enumeration: AUTO; initial value: changed from the default value to **4** Enum: AUTO; initial value: changed from the default value to **4**
14. In **CaptureSession**, the parameter of the **addOutput** API is changed from the original subclass type (**PreviewOutput**, **PhotoOutput**, **VideoOutput**, and **MetadataOutput**) to the base class type (**CameraOutput**). After the change, the number of APIs is reduced from 8 to 2. 14. In **CaptureSession**, the parameter of the **addOutput** API is changed from the original child class type (**PreviewOutput**, **PhotoOutput**, **VideoOutput**, and **MetadataOutput**) to the base class type (**CameraOutput**). After the change, the number of APIs is reduced from 8 to 2.
APIs before change: APIs before change:
addOutput(previewOutput: PreviewOutput, callback: AsyncCallback<void>): void;<br>addOutput(previewOutput: PreviewOutput): Promise<void>;<br>addOutput(photoOutput: PhotoOutput, callback: AsyncCallback<void>): void;<br>addOutput(photoOutput: PhotoOutput): Promise<void>;<br>addOutput(videoOutput: VideoOutput, callback: AsyncCallback<void>): void;<br>addOutput(videoOutput: VideoOutput): Promise<void>;<br>addOutput(metadataOutput: MetadataOutput, callback: AsyncCallback<void>): void;<br>addOutput(metadataOutput: MetadataOutput): Promise<void>; addOutput(previewOutput: PreviewOutput, callback: AsyncCallback\<void>): void;<br/>addOutput(previewOutput: PreviewOutput): Promise\<void>;<br/>addOutput(photoOutput: PhotoOutput, callback: AsyncCallback\<void>): void;<br/>addOutput(photoOutput: PhotoOutput): Promise\<void>;<br/>addOutput(videoOutput: VideoOutput, callback: AsyncCallback\<void>): void;<br/>addOutput(videoOutput: VideoOutput): Promise\<void>;<br/>addOutput(metadataOutput: MetadataOutput, callback: AsyncCallback\<void>): void;<br/>addOutput(metadataOutput: MetadataOutput): Promise\<void>;
APIs after change: APIs after change:
addOutput(cameraOutput: CameraOutput, callback: AsyncCallback<void>): void;<br>addOutput(cameraOutput: CameraOutput): Promise<void>; addOutput(cameraOutput: CameraOutput, callback: AsyncCallback\<void>): void;<br/>addOutput(cameraOutput: CameraOutput): Promise\<void>;
The sample code (for **PreviewOutput**) is as follows: The sample code (for **previewOutput**) is as follows:
``` ```
captureSession.addOutput(previewOutput, (err) => { captureSession.addOutput(previewOutput, (err) => {
...@@ -748,17 +748,17 @@ cameraInput.open().then(() => { ...@@ -748,17 +748,17 @@ cameraInput.open().then(() => {
}) })
``` ```
15. In **CaptureSession**, the parameter of the **removeOutput** API is changed from the original subclass type (**PreviewOutput**, **PhotoOutput**, **VideoOutput**, and **MetadataOutput**) to the base class type (**CameraOutput**). After the change, the number of APIs is reduced from 8 to 2. 15. In **CaptureSession**, the parameter of the **removeOutput** API is changed from the original child class type (**PreviewOutput**, **PhotoOutput**, **VideoOutput**, and **MetadataOutput**) to the base class type (**CameraOutput**). After the change, the number of APIs is reduced from 8 to 2.
APIs before change: APIs before change:
removeOutput(previewOutput: PreviewOutput, callback: AsyncCallback<void>): void;<br>removeOutput(previewOutput: PreviewOutput): Promise<void>;<br>removeOutput(photoOutput: PhotoOutput, callback: AsyncCallback<void>): void;<br>removeOutput(photoOutput: PhotoOutput): Promise<void>;<br>removeOutput(videoOutput: VideoOutput, callback: AsyncCallback<void>): void;<br>removeOutput(videoOutput: VideoOutput): Promise<void>;<br>removeOutput(metadataOutput: MetadataOutput, callback: AsyncCallback<void>): void;<br>removeOutput(metadataOutput: MetadataOutput): Promise<void>; removeOutput(previewOutput: PreviewOutput, callback: AsyncCallback\<void>): void;<br/>removeOutput(previewOutput: PreviewOutput): Promise\<void>;<br/>removeOutput(photoOutput: PhotoOutput, callback: AsyncCallback\<void>): void;<br/>removeOutput(photoOutput: PhotoOutput): Promise\<void>;<br/>removeOutput(videoOutput: VideoOutput, callback: AsyncCallback\<void>): void;<br/>removeOutput(videoOutput: VideoOutput): Promise\<void>;<br/>removeOutput(metadataOutput: MetadataOutput, callback: AsyncCallback\<void>): void;<br/>removeOutput(metadataOutput: MetadataOutput): Promise\<void>;
APIs after change: APIs after change:
removeOutput(cameraOutput: CameraOutput, callback: AsyncCallback<void>): void;<br>removeOutput(cameraOutput: CameraOutput): Promise<void>; removeOutput(cameraOutput: CameraOutput, callback: AsyncCallback\<void>): void;<br/>removeOutput(cameraOutput: CameraOutput): Promise\<void>;
The sample code (for **PreviewOutput**) is as follows: The sample code (for **previewOutput**) is as follows:
``` ```
captureSession.removeOutput(previewOutput, (err) => { captureSession.removeOutput(previewOutput, (err) => {
...@@ -776,8 +776,8 @@ cameraInput.open().then(() => { ...@@ -776,8 +776,8 @@ cameraInput.open().then(() => {
}) })
``` ```
16. The following enumeration in **MetadataObjectType** is changed: 16. The following enum in **MetadataObjectType** is changed:
The enumeration value name is changed from **FACE** to **FACE_DETECTION**. The enum value name is changed from **FACE** to **FACE_DETECTION**.
17. The name of the **Camera** API is changed to **CameraDevice**. 17. The name of the **Camera** API is changed to **CameraDevice**.
# Distributed Scheduler Subsystem ChangeLog # Distributed Scheduler Subsystem Changelog
## cl.DistributedManagerService.1 continuationManager API Changes ## cl.DistributedManagerService.1 continuationManager on()/off() Changes
- Event names passed to the **continuationManager** API do not comply with the OpenHarmony API specifications. - The event types passed to the **continuationManager.on** and **continuationManager.off** APIs do not comply with the OpenHarmony API specifications.
- The **continuationManager.on** API does not have a unified return value for various events, which does not comply with the OpenHarmony API specifications. - The return value of **continuationManager.on** varies with the event type, which does not comply with the OpenHarmony API specifications.
The following changes have been made: The following changes have been made:
- The device selection event name of **continuationManager.on** and **continuationManager.off** is changed from **deviceConnect** to **deviceSelected**, and the device deselection event name is changed from **deviceDisconnect** to **deviceUnselected**. - Changed the event type **deviceConnect** to **deviceSelected** and **deviceDisconnect** to **deviceUnselected** in the **continuationManager.on** and **continuationManager.off** APIs.
- The **continuationManager.on** API returns **Callback&lt;Array&lt;ContinuationResult&gt;&gt;** for all events. - Changed the return value of **continuationManager.on** to **Callback&lt;Array&lt;ContinuationResult&gt;&gt;** for all events.
**Change Impacts** **Change Impact**
The application developed based on earlier versions needs to adapt the new APIs. Otherwise, the original service logic will be affected. The application developed based on earlier versions needs to be adapted. Otherwise, the service logic will be affected.
**Key API/Component Changes** **Key API/Component Changes**
...@@ -40,10 +40,9 @@ The application developed based on earlier versions needs to adapt the new APIs. ...@@ -40,10 +40,9 @@ The application developed based on earlier versions needs to adapt the new APIs.
``` ```
**Adaptation Guide** **Adaptation Guide**
Change the event names. The sample code is as follows: Change the event names. The sample code is as follows:
Device selection event of **continuationManager.on**: Event of device selection in **continuationManager.on**:
```ts ```ts
let token = 1; let token = 1;
...@@ -61,7 +60,7 @@ Device selection event of **continuationManager.on**: ...@@ -61,7 +60,7 @@ Device selection event of **continuationManager.on**:
} }
``` ```
Device selection event of **continuationManager.off**: Event of device selection in **continuationManager.off**:
```ts ```ts
let token = 1; let token = 1;
...@@ -72,7 +71,7 @@ Device selection event of **continuationManager.off**: ...@@ -72,7 +71,7 @@ Device selection event of **continuationManager.off**:
} }
``` ```
Device deselection event of **continuationManager.on**: Event of device deselection in **continuationManager.on**:
```ts ```ts
let token = 1; let token = 1;
...@@ -91,7 +90,7 @@ Device deselection event of **continuationManager.on**: ...@@ -91,7 +90,7 @@ Device deselection event of **continuationManager.on**:
} }
``` ```
Device deselection event of **continuationManager.off**: Event of device deselection in **continuationManager.off**:
```ts ```ts
let token = 1; let token = 1;
...@@ -101,3 +100,23 @@ Device deselection event of **continuationManager.off**: ...@@ -101,3 +100,23 @@ Device deselection event of **continuationManager.off**:
console.error('off failed, cause: ' + JSON.stringify(err)); console.error('off failed, cause: ' + JSON.stringify(err));
} }
``` ```
## cl.DistributedManagerService.2 Adding DATASYNC Permission Verification to continuationManager APIs
In earlier versions, the **continuationManager** APIs do not verify the caller, which does not comply with the OpenHarmony API specifications.
Now, before using a **continuationManager** API, the caller must apply for the **ohos.permission.DISTRIBUTED_DATASYNC** permission.
**Change Impact**
The application developed based on earlier versions needs to apply for the **ohos.permission.DISTRIBUTED_DATASYNC** permission in advance. Otherwise, the service logic will be affected.
**Key API/Component Changes**
Involved APIs:
- continuationManager.registerContinuation;
- continuationManager.on;
- continuationManager.off;
- continuationManager.unregisterContinuation;
- continuationManager.updateContinuationState;
- continuationManager.startContinuationDeviceManager;
# DSoftBus Subsystem ChangeLog # DSoftBus Subsystem Changelog
## IPC&RPC APIs support the exception handling mode and the selection of synchronous or asynchronous message sending by passing a Boolean value or a numeric value. ## Support for Exception Handling and Selecting Synchronous or Asynchronous Message Sending by Using a Boolean or Numeric Value in IPC&RPC APIs
1. Some IPC&RPC APIs of DSoftBus use service logic return values to indicate the error information, which does not comply with the API error code specifications of OpenHarmony. 1. Some IPC&RPC APIs of DSoftBus use service logic return values to indicate error information, which does not comply with the API error code specifications of OpenHarmony.
2. A Boolean value can be passed to specify the mode of sending information as asynchronous or synchronous. 2. A Boolean value can be passed in to specify the asynchronous or synchronous message transfer mode.
#### Change Impacts #### Change Impact
This version is compatible with earlier versions and no adaptation is required. Newly added APIs can be called to support the following changes: No adaptation is required. Use the new APIs provided by this version to:
1. Supports exception handling and return of error codes. 1. Implement exception handling and return of error codes.
2. Supports selection of synchronous or asynchronous message sending by passing a Boolean value or by passing 0 or a non-0 number. 2. Select synchronous or asynchronous message transfer by using a Boolean value or a number of 0 or non-0.
#### **Key API/Component Changes** #### **Key API/Component Changes**
For adaptation to the unified API exception handling mode, related IPC&RPC APIs are deprecated, and corresponding new APIs and methods are added. The newly added APIs support unified error code handling specifications and function the same as the original APIs. For easy use, related IPC&RPC APIs are deprecated, and new APIs are added to implement unified error code handling. The functionalities of these APIs remain unchanged.
| Class| Deprecated API | New Class | New API | | Class| Deprecated API | New Class | New API |
| ------------ | ------------ | ------------ | ------------ | | ------------ | ------------ | ------------ | ------------ |
| MessageParcel | static create(): MessageParcel | MessageSequence | static create(): MessageSequence | | MessageParcel | static create(): MessageParcel | MessageSequence | static create(): MessageSequence |
...@@ -130,7 +130,7 @@ For adaptation to the unified API exception handling mode, related IPC&RPC APIs ...@@ -130,7 +130,7 @@ For adaptation to the unified API exception handling mode, related IPC&RPC APIs
#### Adaptation Guide #### Adaptation Guide
The newly added APIs return error codes and corresponding error information by throwing exceptions. Take the **create** API in **MessageParcel** as an example. The sample code is as follows: The new APIs return error codes and error information by throwing exceptions. The following uses the **create()** API of **MessageParcel** as an example.
```js ```js
import rpc from '@ohos.rpc' import rpc from '@ohos.rpc'
...@@ -142,4 +142,4 @@ try { ...@@ -142,4 +142,4 @@ try {
console.info("create meassageParcel failed, errorMessage = " + error.errorMessage); console.info("create meassageParcel failed, errorMessage = " + error.errorMessage);
} }
``` ```
For details about sample code of more APIs, see [RPC API reference](../../../application-dev/reference/apis/js-apis-rpc.md). For details about the APIs, see [RPC](../../../application-dev/reference/apis/js-apis-rpc.md).
# File Management Subsystem Changelog
## cl.filemanagement.1 fileio API Changes
Deprecated the **fileio** APIs, which do not return error codes; added APIs that return error codes.
**Change Impact**
For applications developed based on earlier versions, pay attention to the changes of APIs. The specifications of the new APIs are slightly adjusted. Pay attention to the usage of the new APIs.
**Key API/Component Changes**
The APIs of **@ohos.fileio** do not support error code handling and are deprecated. New APIs are added in **@ohos.file.fs** to support unified error code handling and have slight changes in parameters. The functionalities of the APIs remain unchanged.
| Module | Method/Attribute/Enum/Constant | Change Type|
| ------------------------- | ------------------------------------------------------------ | -------- |
| @ohos.fileio | **function** open(path: string, flags?: number, mode?: number, callback?: AsyncCallback<number>): void \| Promise<number>; | Deprecated |
| @ohos.fileio | **function** openSync(path: string, flags?: number, mode?: number): number; | Deprecated |
| @ohos.file.fs | **function** open(path: string, mode?: number, callback?: AsyncCallback<File>): void \| Promise<File>; | Added |
| @ohos.file.fs | **function** openSync(path: string, mode?: number): File; | Added |
| @ohos.fileio | **function** read(fd: number, buffer: ArrayBuffer, options?: { offset?: number; length?: number; position?: number; }, callback?: AsyncCallback<ReadOut>): void \| Promise<ReadOut>; | Deprecated |
| @ohos.fileio | **function** readSync(fd: number, buffer: ArrayBuffer, options?: { offset?: number; length?: number; position?: number; }): number; | Deprecated |
| @ohos.file.fs | **function** read(fd: number, buffer: ArrayBuffer, options?: { offset?: number; length?: number; }, callback?: AsyncCallback<number>): void \| Promise<number>; | Added |
| @ohos.file.fs | **function** readSync(fd: number, buffer: ArrayBuffer, options?: { offset?: number; length?: number; }): number; | Added |
| @ohos.fileio | **function** stat(path: string, callback?: AsyncCallback<Stat>): void \| Promise<Stat>; | Deprecated |
| @ohos.fileio | **function** statSync(path: string): Stat; | Deprecated |
| @ohos.fileio | **function** fstat(fd: number, callback?: AsyncCallback<Stat>): void \| Promise<Stat>; | Deprecated |
| @ohos.fileio | **function** fstatSync(fd: number): Stat; | Deprecated |
| @ohos.file.fs | **function** stat(file: string \| number, callback?: AsyncCallback<Stat>): void \| Promise<Stat>; | Added |
| @ohos.file.fs | **function** statSync(file: string \| number): Stat; | Added |
| @ohos.fileio | **function** truncate(path: string, len?: number, callback?: AsyncCallback<void>): void \| Promise<void>; | Deprecated |
| @ohos.fileio | **function** truncateSync(path: string, len?: number): void; | Deprecated |
| @ohos.fileio | **function** ftruncate(fd: number, len?: number, callback?: AsyncCallback<void>): void \| Promise<void>; | Deprecated |
| @ohos.fileio | **function** ftruncateSync(fd: number, len?: number): void; | Deprecated |
| @ohos.file.fs | **function** truncate(file: string \| number, len?: number, callback?: AsyncCallback<void>): void \| Promise<void>; | Added |
| @ohos.file.fs | **function** truncateSync(file: string \| number, len?: number): void; | Added |
| @ohos.fileio | **function** write(fd: number, buffer: ArrayBuffer \| string, options?: { offset?: number; length?: number; position?: number; encoding?: string; }, callback?: AsyncCallback<number>): void \| Promise<void>; | Deprecated |
| @ohos.fileio | **function** writeSync(fd: number, buffer: ArrayBuffer \| string, options?: { offset?: number; length?: number; position?: number; encoding?: string; }): number; | Deprecated |
| @ohos.file.fs | **function** write(fd: number, buffer: ArrayBuffer \| string, options?: { offset?: number; length?: number; encoding?: string; }, callback?: AsyncCallback<number>): void \| Promise<void>; | Added |
| @ohos.file.fs | **function** writeSync(fd: number, buffer: ArrayBuffer \| string, options?: { offset?: number; length?: number; encoding?: string; }): number; | Added |
**Adaptation Guide**
Before the change, the APIs are imported as follows:
```js
import fileio from '@ohos.fileio';
```
Now, the APIs are imported as follows:
```js
import fs from '@ohos.file.fs';
```
In addition, exception handling needs to be adapted.
Sample code for exception handling in a synchronous API:
```js
import fs from '@ohos.file.fs'
try {
let file = fs.openSync(path, fs.OpenMode.READ_ONLY);
} catch (err) {
console.error("openSync errCode:" + err.code + ", errMessage:" + err.message);
}
```
Sample code for exception handling in an asynchronous API (promise):
```js
import fs from '@ohos.file.fs'
try {
let file = await fs.open(path, fs.OpenMode.READ_ONLY);
} catch (err) {
console.error("open promise errCode:" + err.code + ", errMessage:" + err.message);
}
```
Sample code for exception handling in an asynchronous API (callback):
```js
import fs from '@ohos.file.fs'
try {
fs.open(path, fs.OpenMode.READ_ONLY, function(e, file){ // Asynchronous thread errors (such as a syscall error) are obtained via a callback.
if (e) {
console.error("open in async errCode:" + e.code + ", errMessage:" + e.message);
}
});
} catch (err) {// Main thread errors (such as invalid parameters) are obtained by try catch.
console.error("open callback errCode:" + err.code + ", errMessage:" + err.message);
}
```
...@@ -18,7 +18,7 @@ Asynchronous API: An error message is returned via **AsyncCallback** or the **er ...@@ -18,7 +18,7 @@ Asynchronous API: An error message is returned via **AsyncCallback** or the **er
Synchronous API: An error message is returned via an exception. Synchronous API: An error message is returned via an exception.
**Change Impacts** **Change Impact**
The application developed based on earlier versions needs to adapt the method for returning API error information. Otherwise, the original service logic will be affected. The application developed based on earlier versions needs to adapt the method for returning API error information. Otherwise, the original service logic will be affected.
...@@ -26,51 +26,97 @@ The application developed based on earlier versions needs to adapt the method fo ...@@ -26,51 +26,97 @@ The application developed based on earlier versions needs to adapt the method fo
Error code processing is added for the following APIs: Error code processing is added for the following APIs:
- getSetting(): InputMethodSetting; - getSetting(): InputMethodSetting;
- getController(): InputMethodController; - getController(): InputMethodController;
- switchInputMethod(target: InputMethodProperty, callback: AsyncCallback<boolean>): void;
- switchInputMethod(target: InputMethodProperty): Promise<boolean>; - switchInputMethod(target: InputMethodProperty, callback: AsyncCallback\<boolean>): void;
- switchCurrentInputMethodSubtype(target: InputMethodSubtype, callback: AsyncCallback<boolean>): void;
- switchCurrentInputMethodSubtype(target: InputMethodSubtype): Promise<boolean>; - switchInputMethod(target: InputMethodProperty): Promise\<boolean>;
- switchCurrentInputMethodAndSubtype(inputMethodProperty: InputMethodProperty, inputMethodSubtype: InputMethodSubtype, callback: AsyncCallback<boolean>): void;
- switchCurrentInputMethodAndSubtype(inputMethodProperty: InputMethodProperty, inputMethodSubtype: InputMethodSubtype): Promise<boolean>; - switchCurrentInputMethodSubtype(target: InputMethodSubtype, callback: AsyncCallback\<boolean>): void;
- listInputMethodSubtype(inputMethodProperty: InputMethodProperty, callback: AsyncCallback<Array<InputMethodSubtype>>): void;
- listInputMethodSubtype(inputMethodProperty: InputMethodProperty): Promise<Array<InputMethodSubtype>>; - switchCurrentInputMethodSubtype(target: InputMethodSubtype): Promise\<boolean>;
- listCurrentInputMethodSubtype(callback: AsyncCallback<Array<InputMethodSubtype>>): void;
- listCurrentInputMethodSubtype(): Promise<Array<InputMethodSubtype>>; - switchCurrentInputMethodAndSubtype(inputMethodProperty: InputMethodProperty, inputMethodSubtype: InputMethodSubtype, callback: AsyncCallback\<boolean>): void;
- getInputMethods(enable: boolean, callback: AsyncCallback<Array<InputMethodProperty>>): void;
- getInputMethods(enable: boolean): Promise<Array<InputMethodProperty>>; - switchCurrentInputMethodAndSubtype(inputMethodProperty: InputMethodProperty, inputMethodSubtype: InputMethodSubtype): Promise\<boolean>;
- showOptionalInputMethods(callback: AsyncCallback<boolean>): void;
- showOptionalInputMethods(): Promise<boolean>; - listInputMethodSubtype(inputMethodProperty: InputMethodProperty, callback: AsyncCallback<Array\<InputMethodSubtype>>): void;
- stopInputSession(callback: AsyncCallback<boolean>): void;
- stopInputSession(): Promise<boolean>; - listInputMethodSubtype(inputMethodProperty: InputMethodProperty): Promise<Array\<InputMethodSubtype>>;
- showSoftKeyboard(callback: AsyncCallback<void>): void;
- showSoftKeyboard():Promise<void>; - listCurrentInputMethodSubtype(callback: AsyncCallback<Array\<InputMethodSubtype>>): void;
- hideSoftKeyboard(callback: AsyncCallback<void>): void;
- hideSoftKeyboard():Promise<void>; - listCurrentInputMethodSubtype(): Promise<Array\<InputMethodSubtype>>;
- hide(callback: AsyncCallback<void>): void;
- hide(): Promise<void>; - getInputMethods(enable: boolean, callback: AsyncCallback<Array\<InputMethodProperty>>): void;
- onCreate(want: Want): void;
- onDestroy(): void; - getInputMethods(enable: boolean): Promise<Array\<InputMethodProperty>>;
In **InputClient**:
- sendKeyFunction(action: number, callback: AsyncCallback<boolean>): void; - showOptionalInputMethods(callback: AsyncCallback\<boolean>): void;
- sendKeyFunction(action: number): Promise<boolean>;
- deleteForward(length: number, callback: AsyncCallback<boolean>): void; - showOptionalInputMethods(): Promise\<boolean>;
- deleteForward(length: number): Promise<boolean>;
- deleteBackward(length: number, callback: AsyncCallback<boolean>): void; - stopInputSession(callback: AsyncCallback\<boolean>): void;
- deleteBackward(length: number): Promise<boolean>;
- insertText(text: string, callback: AsyncCallback<boolean>): void; - stopInputSession(): Promise\<boolean>;
- insertText(text: string): Promise<boolean>;
- getForward(length: number, callback: AsyncCallback<string>): void; - showSoftKeyboard(callback: AsyncCallback\<void>): void;
- getForward(length: number): Promise<string>;
- getBackward(length: number, callback: AsyncCallback<string>): void; - showSoftKeyboard():Promise\<void>;
- getBackward(length: number): Promise<string>;
- getEditorAttribute(callback: AsyncCallback<EditorAttribute>): void; - hideSoftKeyboard(callback: AsyncCallback\<void>): void;
- getEditorAttribute(): Promise<EditorAttribute>;
- moveCursor(direction: number, callback: AsyncCallback<void>): void; - hideSoftKeyboard():Promise\<void>;
- moveCursor(direction: number): Promise<void>;
In **InputMethodExtensionAbility**: - hide(callback: AsyncCallback\<void>): void;
- hide(): Promise\<void>;
- onCreate(want: Want): void; - onCreate(want: Want): void;
- onDestroy(): void; - onDestroy(): void;
- In **InputClient**:
- sendKeyFunction(action: number, callback: AsyncCallback\<boolean>): void;
- sendKeyFunction(action: number): Promise\<boolean>;
- deleteForward(length: number, callback: AsyncCallback\<boolean>): void;
- deleteForward(length: number): Promise\<boolean>;
- deleteBackward(length: number, callback: AsyncCallback\<boolean>): void;
- deleteBackward(length: number): Promise\<boolean>;
- insertText(text: string, callback: AsyncCallback\<boolean>): void;
- insertText(text: string): Promise\<boolean>;
- getForward(length: number, callback: AsyncCallback\<string>): void;
- getForward(length: number): Promise\<string>;
- getBackward(length: number, callback: AsyncCallback\<string>): void;
- getBackward(length: number): Promise\<string>;
- getEditorAttribute(callback: AsyncCallback\<EditorAttribute>): void;
- getEditorAttribute(): Promise\EditorAttribute>;
- moveCursor(direction: number, callback: AsyncCallback\<void>): void;
- moveCursor(direction: number): Promise\<void>;
- In **InputMethodExtensionAbility**:
- onCreate(want: Want): void;
- onDestroy(): void;
**Adaptation Guide** **Adaptation Guide**
...@@ -143,11 +189,9 @@ Substitute APIs: ...@@ -143,11 +189,9 @@ Substitute APIs:
- hide(): Promise<void>; - hide(): Promise<void>;
**NOTE** **NOTE**
Use the **getInputMethodAbility()** API to obtain an **InputMethodAbility** object, and do not use **getInputMethodEngine()** to obtain an **InputMethodEngine** object.
- Use the **getInputMethodAbility()** API to obtain an **InputMethodAbility** object, and do not use **getInputMethodEngine()** to obtain an **InputMethodEngine** object. Use methods in **InputMethodAbility**, and do not use methods in **InputMethodEngine**.
- Use methods in **InputMethodAbility**, and do not use methods in **InputMethodEngine**. Use the **on('inputStart')** method in **InputMethodAbility** to obtain a **KeyboardController** instance and an **InputClient** instance, and do not use the **on('inputStart')** method in **InputMethodEngine** to obtain a **TextInputClient** instance.
- Use the **on('inputStart')** method in **InputMethodAbility** to obtain a **KeyboardController** instance and an **InputClient** instance, and do not use the **on('inputStart')** method in **InputMethodEngine** to obtain a **TextInputClient** instance.
Before: Before:
```js ```js
......
# Multimedia Subsystem ChangeLog # Multimedia Subsystem Changelog
## cl.multimedia.audio.001 Call Mode Change of getRoutingManager() ## cl.multimedia.audio.001 Call Mode Change of getRoutingManager()
**getRoutingManager()** is changed from asynchronous to synchronous. **getRoutingManager()** is changed from asynchronous to synchronous.
**Change Impacts** **Change Impact**
If the new mode is not used, an error will be reported during compilation. If the new mode is not used, an error will be reported during compilation.
...@@ -25,7 +25,7 @@ getRoutingManager(): AudioRoutingManager; ...@@ -25,7 +25,7 @@ getRoutingManager(): AudioRoutingManager;
**getStreamManager()** is changed from asynchronous to synchronous. **getStreamManager()** is changed from asynchronous to synchronous.
**Change Impacts** **Change Impact**
If the new mode is not used, an error will be reported during compilation. If the new mode is not used, an error will be reported during compilation.
...@@ -46,7 +46,7 @@ getStreamManager(): AudioStreamManager; ...@@ -46,7 +46,7 @@ getStreamManager(): AudioStreamManager;
In the original **AudioRoutingManager**, the registration mode of the **micStateChange** listener of the **on()** function is changed. In the original **AudioRoutingManager**, the registration mode of the **micStateChange** listener of the **on()** function is changed.
**Change Impacts** **Change Impact**
If the new mode is not used, an error will be reported during compilation. If the new mode is not used, an error will be reported during compilation.
...@@ -71,7 +71,7 @@ interface AudioVolumeGroupManager { ...@@ -71,7 +71,7 @@ interface AudioVolumeGroupManager {
The call mode of **getVolumeGroups()** is changed. The call mode of **getVolumeGroups()** is changed.
**Change Impacts** **Change Impact**
If the new mode is not used, an error will be reported during compilation. If the new mode is not used, an error will be reported during compilation.
...@@ -96,7 +96,7 @@ interface AudioVolumeManager{ ...@@ -96,7 +96,7 @@ interface AudioVolumeManager{
The call mode of **getGroupManager()** is changed. The call mode of **getGroupManager()** is changed.
**Change Impacts** **Change Impact**
If the new mode is not used, an error will be reported during compilation. If the new mode is not used, an error will be reported during compilation.
...@@ -121,9 +121,9 @@ interface AudioVolumeManager{ ...@@ -121,9 +121,9 @@ interface AudioVolumeManager{
**FOCUS_TYPE_RECORDING** of **FocusType** is renamed as **FOCUS_TYPE_DEFAULT**. **FOCUS_TYPE_RECORDING** of **FocusType** is renamed as **FOCUS_TYPE_DEFAULT**.
**Change Impacts** **Change Impact**
If the new name is not used, an error will be reported during compilation. If the new mode is not used, an error will be reported during compilation.
**Key API/Component Changes** **Key API/Component Changes**
...@@ -145,9 +145,9 @@ enum InterruptRequestType { ...@@ -145,9 +145,9 @@ enum InterruptRequestType {
The listener registration name of **interrupt** of the **on()** function in **AudioRenderer** is changed. The listener registration name of **interrupt** of the **on()** function in **AudioRenderer** is changed.
**Change Impacts** **Change Impact**
If the new name is not used, an error will be reported during compilation. If the new mode is not used, an error will be reported during compilation.
**Key API/Component Changes** **Key API/Component Changes**
...@@ -170,141 +170,84 @@ interface AudioRenderer { ...@@ -170,141 +170,84 @@ interface AudioRenderer {
In the MR version, the formal **AVRecorder** APIs (integrating audio and video) will be provided for external use. In the MR version, the formal **AVRecorder** APIs (integrating audio and video) will be provided for external use.
**VideoRecorder** APIs in API version 9 are changed to system APIs, which are available only to system users. In the future, **VideoRecorder** APIs will be deprecated after system users switch to **AVRecorder**. **VideoRecorder** APIs in API version 9 are changed to system APIs, which are available only to system users. In the future, **VideoRecorder** APIs will be deprecated after system users switch to **AVRecorder**.
**Change Impacts** **Change Impact**
If the **VideoRecorder** caller is not a system user, the call will fail. If the **VideoRecorder** caller is not a system user, the call will fail.
Involved APIs and enums:
Involved APIs and enumerations:
function createVideoRecorder(callback: AsyncCallback<VideoRecorder>): void; function createVideoRecorder(callback: AsyncCallback<VideoRecorder>): void;
function createVideoRecorder(): Promise<VideoRecorder>; function createVideoRecorder(): Promise<VideoRecorder>;
type VideoRecordState = 'idle' | 'prepared' | 'playing' | 'paused' | 'stopped' | 'error'; type VideoRecordState = 'idle' | 'prepared' | 'playing' | 'paused' | 'stopped' | 'error';
interface VideoRecorder{ interface VideoRecorder{
prepare(config: VideoRecorderConfig, callback: AsyncCallback<void>): void;
​ prepare(config: VideoRecorderConfig, callback: AsyncCallback<void>): void; prepare(config: VideoRecorderConfig): Promise<void>;
getInputSurface(callback: AsyncCallback<string>): void;
​ prepare(config: VideoRecorderConfig): Promise<void>; getInputSurface(): Promise<string>;
start(callback: AsyncCallback<void>): void;
​ getInputSurface(callback: AsyncCallback<string>): void; start(): Promise<void>;
pause(callback: AsyncCallback<void>): void;
​ getInputSurface(): Promise<string>; pause(): Promise<void>;
resume(callback: AsyncCallback<void>): void;
​ start(callback: AsyncCallback<void>): void; resume(): Promise<void>;
stop(callback: AsyncCallback<void>): void;
​ start(): Promise<void>; stop(): Promise<void>;
release(callback: AsyncCallback<void>): void;
​ pause(callback: AsyncCallback<void>): void; release(): Promise<void>;
reset(callback: AsyncCallback<void>): void;
​ pause(): Promise<void>; reset(): Promise<void>;
on(type: 'error', callback: ErrorCallback): void;
​ resume(callback: AsyncCallback<void>): void; readonly state: VideoRecordState;
​ resume(): Promise<void>;
​ stop(callback: AsyncCallback<void>): void;
​ stop(): Promise<void>;
​ release(callback: AsyncCallback<void>): void;
​ release(): Promise<void>;
​ reset(callback: AsyncCallback<void>): void;
​ reset(): Promise<void>;
​ on(type: 'error', callback: ErrorCallback): void;
​ readonly state: VideoRecordState;
} }
interface VideoRecorderProfile { interface VideoRecorderProfile {
readonly audioBitrate: number;
​ readonly audioBitrate: number; readonly audioChannels: number;
readonly audioCodec: CodecMimeType;
​ readonly audioChannels: number; readonly audioSampleRate: number;
readonly fileFormat: ContainerFormatType;
​ readonly audioCodec: CodecMimeType; readonly videoBitrate: number;
readonly videoCodec: CodecMimeType;
​ readonly audioSampleRate: number; readonly videoFrameWidth: number;
readonly videoFrameHeight: number;
​ readonly fileFormat: ContainerFormatType; readonly videoFrameRate: number;
​ readonly videoBitrate: number;
​ readonly videoCodec: CodecMimeType;
​ readonly videoFrameWidth: number;
​ readonly videoFrameHeight: number;
​ readonly videoFrameRate: number;
} }
enum AudioSourceType { enum AudioSourceType {
AUDIO_SOURCE_TYPE_DEFAULT = 0,
​ AUDIO_SOURCE_TYPE_DEFAULT = 0, AUDIO_SOURCE_TYPE_MIC = 1,
​ AUDIO_SOURCE_TYPE_MIC = 1,
} }
enum VideoSourceType { enum VideoSourceType {
VIDEO_SOURCE_TYPE_SURFACE_YUV = 0,
​ VIDEO_SOURCE_TYPE_SURFACE_YUV = 0, VIDEO_SOURCE_TYPE_SURFACE_ES = 1,
​ VIDEO_SOURCE_TYPE_SURFACE_ES = 1,
} }
enum VideoRecorderConfig { enum VideoRecorderConfig {
audioSourceType?: AudioSourceType;
​ audioSourceType?: AudioSourceType; videoSourceType: VideoSourceType;
profile: VideoRecorderProfile;
​ videoSourceType: VideoSourceType; url: string;
rotation?: number;
​ profile: VideoRecorderProfile; location?: Location;
​ url: string;
​ rotation?: number;
​ location?: Location;
} }
## cl.multimedia.media.002 No Externally Provided Bit Rate Selection API in VideoPlayer ## cl.multimedia.media.002 No Externally Provided Bit Rate Selection API in VideoPlayer
In API version 9, **VideoPlayer** does not externally provide the bit rate selection API. Such an API will be provided by **AVPlayer** in the MR version. In API version 9, **VideoPlayer** does not externally provide the bit rate selection API. Such an API will be provided by **AVPlayer** in the MR version.
**Change Impacts** **Change Impact**
Bit rate selection cannot be performed in the multi-bit rate scenario of **VideoPlayer**. Relevant functions will be provided by **AVPlayer**. Bit rate selection cannot be performed in the multi-bit rate scenario of **VideoPlayer**. Relevant functions will be provided by **AVPlayer**.
**Key API/Component Changes** **Key API/Component Changes**
Deleted APIs: Deleted APIs:
interface VideoPlayer { interface VideoPlayer {
selectBitrate(bitrate: number): Promise<number>;
​ selectBitrate(bitrate: number): Promise<number>; selectBitrate(bitrate: number, callback: AsyncCallback<number>): void;
on(type: 'availableBitratesCollect', callback: (bitrates: Array<number>) => void): void;
​ selectBitrate(bitrate: number, callback: AsyncCallback<number>): void;
​ on(type: 'availableBitratesCollect', callback: (bitrates: Array<number>) => void): void;
} }
## cl.multimedia.media.003 Error Information Change of VideoRecorder ## cl.multimedia.media.003 Error Information Change of VideoRecorder
Original error codes of **VideoRecorder** are changed because they do not comply with the error code specifications. Original error codes of **VideoRecorder** are changed because they do not comply with the error code specifications.
**Change Impacts** **Change Impact**
Error codes returned from **VideoRecorder** are changed. Error codes returned from **VideoRecorder** are changed.
...@@ -315,5 +258,5 @@ Error codes returned from **VideoRecorder** are changed. ...@@ -315,5 +258,5 @@ Error codes returned from **VideoRecorder** are changed.
**Adaptation Guide** **Adaptation Guide**
For details about exception handling, see the following documents: For details about exception handling, see the following documents:
[Media](https://gitee.com/openharmony/docs/blob/master/en/application-dev/reference/apis/js-apis-media.md) https://gitee.com/openharmony/docs/blob/master/zh-cn/application-dev/reference/apis/js-apis-media.md
[Media Error Codes](https://gitee.com/openharmony/docs/blob/master/en/application-dev/reference/errorcodes/errorcode-media.md) https://gitee.com/openharmony/docs/blob/master/zh-cn/application-dev/reference/errorcodes/errorcode-media.md
# Upload and Download Subsystem Changelog
## cl.request.1 Changes of Error Code Definitions and Some API Names
- The processing of the [upload and download error codes](https://gitee.com/openharmony/docs/blob/master/en/application-dev/reference/errorcodes/errorcode-request.md) is added to the upload and download APIs.
- An error message is returned via **AsyncCallback** or the **error** object of **Promise**. An error message related to the parameter type or quantity is returned via an exception.
- Some APIs need to be replaced with new APIs, and the parameters remain unchanged.
**Change Impact**
The application developed based on earlier versions needs to adapt the method for returning API error information. Otherwise, the original service logic will be affected.
**Key API/Component Changes**
| Module | Class | Method/Attribute/Enumeration/Constant | Change Type |
|--------------|--------------|-----------------------------------------------------------------------------------------------------------------------|-----------|
| ohos.request | request | EXCEPTION_PERMISSION | Added|
| ohos.request | request | EXCEPTION_PARAMCHECK | Added|
| ohos.request | request | EXCEPTION_UNSUPPORTED | Added|
| ohos.request | request | EXCEPTION_FILEIO | Added|
| ohos.request | request | EXCEPTION_FILEPATH | Added|
| ohos.request | request | EXCEPTION_SERVICE | Added|
| ohos.request | request | EXCEPTION_OTHERS | Added|
| ohos.request | request | ERROR_OFFLINE | Added|
| ohos.request | request | ERROR_UNSUPPORTED_NETWORK_TYPE | Added|
| ohos.request | request | function downloadFile(context: BaseContext, config: DownloadConfig, callback: AsyncCallback<DownloadTask>): void; | Added|
| ohos.request | request | function downloadFile(context: BaseContext, config: DownloadConfig): Promise<DownloadTask>; | Added|
| ohos.request | request | function uploadFile(context: BaseContext, config: UploadConfig, callback: AsyncCallback<UploadTask>): void; | Added|
| ohos.request | request | function uploadFile(context: BaseContext, config: UploadConfig): Promise<UploadTask>; | Added|
| ohos.request | DownloadTask | delete(callback: AsyncCallback<boolean>): void; | Added|
| ohos.request | DownloadTask | delete(): Promise<boolean>; | Added|
| ohos.request | DownloadTask | suspend(callback: AsyncCallback<boolean>): void; | Added|
| ohos.request | DownloadTask | suspend(): Promise<boolean>; | Added|
| ohos.request | DownloadTask | restore(callback: AsyncCallback<boolean>): void; | Added|
| ohos.request | DownloadTask | restore(): Promise<boolean>; | Added|
| ohos.request | DownloadTask | getTaskInfo(callback: AsyncCallback<DownloadInfo>): void; | Added|
| ohos.request | DownloadTask | getTaskInfo(): Promise<DownloadInfo>; | Added|
| ohos.request | DownloadTask | getTaskMimeType(callback: AsyncCallback<string>): void; | Added|
| ohos.request | DownloadTask | getTaskMimeType(): Promise<string>; | Added|
| ohos.request | UploadTask | delete(callback: AsyncCallback<boolean>): void; | Added|
| ohos.request | UploadTask | delete(): Promise<boolean>; | Added|
| ohos.request | request | function download(config: DownloadConfig, callback: AsyncCallback<DownloadTask>): void;<br>Substitute API: function downloadFile(context: BaseContext, config: DownloadConfig, callback: AsyncCallback<DownloadTask>): void;| Deprecated|
| ohos.request | request | function download(config: DownloadConfig): Promise<DownloadTask>;<br>Substitute API: function downloadFile(context: BaseContext, config: DownloadConfig): Promise<DownloadTask>; | Deprecated|
| ohos.request | request | function download(context: BaseContext, config: DownloadConfig, callback: AsyncCallback<DownloadTask>): void;<br>Substitute API: function downloadFile(context: BaseContext, config: DownloadConfig, callback: AsyncCallback<DownloadTask>): void;| Deprecated|
| ohos.request | request | function download(context: BaseContext, config: DownloadConfig): Promise<DownloadTask>;<br>Substitute API: function downloadFile(context: BaseContext, config: DownloadConfig): Promise<DownloadTask>; | Deprecated|
| ohos.request | request | function upload(config: UploadConfig, callback: AsyncCallback<UploadTask>): void;<br>Substitute API: function uploadFile(context: BaseContext, config: UploadConfig, callback: AsyncCallback<UploadTask>): void; | Deprecated|
| ohos.request | request | function upload(config: UploadConfig): Promise<UploadTask>;<br>Substitute API: function uploadFile(context: BaseContext, config: UploadConfig): Promise<UploadTask>; | Deprecated|
| ohos.request | request | function upload(context: BaseContext, config: UploadConfig, callback: AsyncCallback<UploadTask>): void;<br>Substitute API: function uploadFile(context: BaseContext, config: UploadConfig, callback: AsyncCallback<UploadTask>): void; | Deprecated|
| ohos.request | request | function upload(context: BaseContext, config: UploadConfig): Promise<UploadTask>;<br>Substitute API: function uploadFile(context: BaseContext, config: UploadConfig): Promise<UploadTask>; | Deprecated|
| ohos.request | DownloadTask | remove(callback: AsyncCallback<boolean>): void;<br>Substitute API: delete(callback: AsyncCallback<boolean>): void | Deprecated|
| ohos.request | DownloadTask | remove(): Promise<boolean>;<br>Substitute API: delete(): Promise<boolean>; | Deprecated|
| ohos.request | DownloadTask | pause(callback: AsyncCallback<boolean>): void;<br>Substitute API: suspend(callback: AsyncCallback<boolean>): void; | Deprecated|
| ohos.request | DownloadTask | pause(): Promise<boolean>;<br>Substitute API: suspend(): Promise<boolean>; | Deprecated|
| ohos.request | DownloadTask | resume(callback: AsyncCallback<boolean>): void;<br>Substitute API: restore(callback: AsyncCallback<boolean>): void; | Deprecated|
| ohos.request | DownloadTask | resume(): Promise<boolean>;<br>Substitute API: restore(): Promise<boolean>; | Deprecated|
| ohos.request | DownloadTask | query(callback: AsyncCallback<DownloadInfo>): void;<br>Substitute API: getTaskInfo(callback: AsyncCallback<DownloadInfo>): void; | Deprecated|
| ohos.request | DownloadTask | query(): Promise<DownloadInfo>;<br>Substitute API: getTaskInfo(): Promise<DownloadInfo>; | Deprecated|
| ohos.request | DownloadTask | queryMimeType(callback: AsyncCallback<string>): void;<br>Substitute API: getTaskMimeType(callback: AsyncCallback<string>): void; | Deprecated|
| ohos.request | DownloadTask | queryMimeType(): Promise<string>;<br>Substitute API: getTaskMimeType(): Promise<string>; | Deprecated|
| ohos.request | UploadTask | remove(callback: AsyncCallback<boolean>): void;<br>Substitute API: delete(callback: AsyncCallback<boolean>): void; | Deprecated|
| ohos.request | UploadTask | remove(): Promise<boolean>;<br>Substitute API: delete(): Promise<boolean>; | Deprecated|
| system.request | UploadResponse | code | Deprecated|
| system.request | UploadResponse | data | Deprecated|
| system.request | UploadResponse | headers | Deprecated|
| system.request | DownloadResponse | token | Deprecated|
| system.request | OnDownloadCompleteResponse | uri | Deprecated|
| system.request | RequestFile | filename | Deprecated|
| system.request | RequestFile | name | Deprecated|
| system.request | RequestFile | uri | Deprecated|
| system.request | RequestFile | type | Deprecated|
| system.request | RequestData | name | Deprecated|
| system.request | RequestData | value | Deprecated|
| system.request | UploadRequestOptions | url | Deprecated|
| system.request | UploadRequestOptions | data | Deprecated|
| system.request | UploadRequestOptions | files | Deprecated|
| system.request | UploadRequestOptions | header | Deprecated|
| system.request | UploadRequestOptions | description | Deprecated|
| system.request | UploadRequestOptions | success | Deprecated|
| system.request | UploadRequestOptions | fail | Deprecated|
| system.request | UploadRequestOptions | complete | Deprecated|
| system.request | OnDownloadCompleteOptions | token | Deprecated|
| system.request | OnDownloadCompleteOptions | success | Deprecated|
| system.request | OnDownloadCompleteOptions | fail | Deprecated|
| system.request | OnDownloadCompleteOptions | complete | Deprecated|
| system.request | Request | static upload(options: UploadRequestOptions): void; | Deprecated|
| system.request | Request | static download(options: DownloadRequestOptions): void; | Deprecated|
| system.request | Request | static onDownloadComplete(options: OnDownloadCompleteOptions): void; | Deprecated|
**Adaptation Guide**
The following uses **downloadFile** as an example to show how it is called in the new version:
```ts
try {
request.downloadFile(globalThis.abilityContext, { url: 'https://xxxx/xxxxx.hap',
filePath: 'xxx/xxxxx.hap'}, (err, data) => {
if (err) {
console.error('Failed to request the download. Cause: ' + JSON.stringify(err));
return;
}
});
} catch (err) {
console.log("downloadFile callback fail." + "errCode:" + err.code + ",errMessage:" + err.message);
}
```
# Resource Manager ChangeLog # Resource Manager Changelog
## cl.resourceManager.1 Name Change of Some Multi-Project APIs in API Version 9 of Resource Manager ## cl.resourceManager.1 Name Change of Some Multi-Project APIs in API Version 9 of Resource Manager
The resource manager can return error codes and error information for APIs in API version 9 and later. Some multi-project APIs in API version 9 need to be adapted. The following changes are made in API version 9 and later: The resource manager can return error codes and error information for APIs in API version 9 and later. Some multi-project APIs in API version 9 need to be adapted. The following changes are made in API version 9:
Some multi-project APIs of the resource manager need to be replaced with new APIs, and the parameters remain unchanged. Some multi-project APIs of the resource manager need to be replaced with new APIs, and the parameters remain unchanged.
**Change Impacts** **Change Impact**
For applications developed based on earlier versions, relevant JavaScript multi-project APIs need to be replaced with new APIs. For applications developed based on earlier versions, relevant JavaScript multi-project APIs need to be replaced with new APIs.
...@@ -27,40 +27,42 @@ For applications developed based on earlier versions, relevant JavaScript multi- ...@@ -27,40 +27,42 @@ For applications developed based on earlier versions, relevant JavaScript multi-
**Adaptation Guide** **Adaptation Guide**
The following describes how to change **getMedia** to **getMediaContent** in callback mode. The promise mode is similar. You only need to change the function name, add the error code and error information, and keep other information unchanged. The sample code is as follows: The following describes how to change **getMedia** to **getMediaContent** in callback mode. The promise mode is similar. You only need to change the function name, add the error code and error information, and keep other information unchanged. The code snippet is as follows:
- Before the change: **getMedia(resource: Resource, callback: AsyncCallback<Uint8Array>): void;** - Before the change: **getMedia(resource: Resource, callback: AsyncCallback<Uint8Array>): void;**
```ts
let resource = {
bundleName: "com.example.myapplication",
moduleName: "entry",
id: $r('app.media.test').id
};
this.context.resourceManager.getMedia(resource, (error, value) => {
if (error != null) {
console.log("error is " + error);
} else {
let media = value;
}
});
```
- After the change: **getMediaContent(resource: Resource, callback: AsyncCallback<Uint8Array>): void;** ```ts
```ts let resource = {
let resource = { bundleName: "com.example.myapplication",
bundleName: "com.example.myapplication", moduleName: "entry",
moduleName: "entry", id: $r('app.media.test').id
id: $r('app.media.test').id };
}; this.context.resourceManager.getMedia(resource, (error, value) => {
try {
this.context.resourceManager.getMediaContent(resource, (error, value) => {
if (error != null) { if (error != null) {
console.log("error is " + error); console.log("error is " + error);
} else { } else {
let media = value; let media = value;
} }
}); });
} catch (error) { ```
console.error(`callback getMediaContent failed, error code: ${error.code}, message: ${error.message}.`)
} - After the change: **getMediaContent(resource: Resource, callback: AsyncCallback<Uint8Array>): void;**
```
```ts
let resource = {
bundleName: "com.example.myapplication",
moduleName: "entry",
id: $r('app.media.test').id
};
try {
this.context.resourceManager.getMediaContent(resource, (error, value) => {
if (error != null) {
console.log("error is " + error);
} else {
let media = value;
}
});
} catch (error) {
console.error(`callback getMediaContent failed, error code: ${error.code}, message: ${error.message}.`)
}
```
\ No newline at end of file
# Resource Scheduler Subsystem ChangeLog # Resource Scheduler Subsystem Changelog
## cl.resourceschedule.backgroundTaskManager ## cl.resourceschedule.backgroundTaskManager
Rectified original APIs of **backgroundTaskManager** of the resource scheduler subsystem. All APIs in API version 8 and earlier versions are deprecated, and original APIs in API version 9 are deleted. New APIs in API version 9 need to be used. The new APIs in API version 9 comply with the error code specifications. Rectified original APIs of **backgroundTaskManager** of the resource scheduler subsystem. All APIs in API version 8 and earlier versions are deprecated, and original APIs in API version 9 are deleted. New APIs in API version 9 need to be used. The new APIs in API version 9 comply with the error code specifications.
**Change Impacts** **Change Impact**
The application developed based on the SDK versions of OpenHarmony 3.2.8.2 and later needs to adapt the modules and APIs in API version 9 and their methods for returning API error information. Otherwise, the original service logic will be affected. The application developed based on the SDK versions of OpenHarmony 3.2.8.2 and later needs to adapt the modules and APIs in API version 9 and their methods for returning API error information. Otherwise, the original service logic will be affected.
**Key API/Component Changes** **Key API/Component Changes**
The following methods, attributes, enumerations, and constants are changed in API version 9 and later versions. The **@ohos.backgroundTaskManager.d.ts** file is deprecated and related APIs are migrated to the newly added **@ohos.resourceschedule.backgroundTaskManager.d.ts** file. The following methods, attributes, enums, and constants are changed in API version 9 and later versions. The **@ohos.backgroundTaskManager.d.ts** file is deprecated and related APIs are moved to the newly added **@ohos.resourceschedule.backgroundTaskManager.d.ts** file.
| Class| API Type| Declaration| Description| | Class| API Type| Declaration| Description|
| -- | -- | -- | -- | | -- | -- | -- | -- |
| backgroundTaskManager | namespace | declare namespace backgroundTaskManager | This API is deprecated in API version 9 and later versions and is migrated to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.| | backgroundTaskManager | namespace | declare namespace backgroundTaskManager | Deprecated in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager | method | function resetAllEfficiencyResources(): void; | This API is changed in API version 9 and migrated to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.| | backgroundTaskManager | method | function resetAllEfficiencyResources(): void; | Changed in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager | method | function applyEfficiencyResources(request: EfficiencyResourcesRequest): bool; | This API is changed in API version 9 to **function applyEfficiencyResources(request: EfficiencyResourcesRequest): void;** and migrated to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.| | backgroundTaskManager | method | function applyEfficiencyResources(request: EfficiencyResourcesRequest): bool; | Changed in API version 9 to **function applyEfficiencyResources(request: EfficiencyResourcesRequest): void;** and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager | method | function stopBackgroundRunning(context: Context): Promise<void>; | This API is deprecated in API version 9 and later versions and is migrated to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.| | backgroundTaskManager | method | function stopBackgroundRunning(context: Context): Promise<void>; | Deprecated in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager | method | function stopBackgroundRunning(context: Context, callback: AsyncCallback<void>): void; | This API is deprecated in API version 9 and later versions and is migrated to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.| | backgroundTaskManager | method | function stopBackgroundRunning(context: Context, callback: AsyncCallback<void>): void; | Deprecated in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager | method | function startBackgroundRunning(context: Context, bgMode: BackgroundMode, wantAgent: WantAgent): Promise<void>; | This API is deprecated in API version 9 and later versions and is migrated to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.| | backgroundTaskManager | method | function startBackgroundRunning(context: Context, bgMode: BackgroundMode, wantAgent: WantAgent): Promise<void>; | Deprecated in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager | method | function startBackgroundRunning(context: Context, bgMode: BackgroundMode, wantAgent: WantAgent, callback: AsyncCallback<void>): void; | This API is deprecated in API version 9 and later versions and is migrated to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.| | backgroundTaskManager | method | function startBackgroundRunning(context: Context, bgMode: BackgroundMode, wantAgent: WantAgent, callback: AsyncCallback<void>): void; | Deprecated in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager | method | function requestSuspendDelay(reason: string, callback: Callback<void>): DelaySuspendInfo; | This API is deprecated in API version 9 and later versions and is migrated to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.| | backgroundTaskManager | method | function requestSuspendDelay(reason: string, callback: Callback<void>): DelaySuspendInfo; | Deprecated in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager | method | function getRemainingDelayTime(requestId: number): Promise<number>; | This API is deprecated in API version 9 and later versions and is migrated to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.| | backgroundTaskManager | method | function getRemainingDelayTime(requestId: number): Promise<number>; | Deprecated in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager | method | function getRemainingDelayTime(requestId: number, callback: AsyncCallback<number>): void; | This API is deprecated in API version 9 and later versions and is migrated to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.| | backgroundTaskManager | method | function getRemainingDelayTime(requestId: number, callback: AsyncCallback<number>): void; | Deprecated in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager | method | function cancelSuspendDelay(requestId: number): void; | This API is deprecated in API version 9 and later versions and is migrated to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.| | backgroundTaskManager | method | function cancelSuspendDelay(requestId: number): void; | Deprecated in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager.BackgroundMode | enum | export enum BackgroundMode | This API is deprecated in API version 9 and later versions and is migrated to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.| | backgroundTaskManager.BackgroundMode | enum | export enum BackgroundMode | Deprecated in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager.BackgroundMode | enum | DATA_TRANSFER = 1 | This API is deprecated in API version 9 and later versions and is migrated to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.| | backgroundTaskManager.BackgroundMode | enum | DATA_TRANSFER = 1 | Deprecated in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager.BackgroundMode | enum | AUDIO_PLAYBACK = 2 | This API is deprecated in API version 9 and later versions and is migrated to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.| | backgroundTaskManager.BackgroundMode | enum | AUDIO_PLAYBACK = 2 | Deprecated in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager.BackgroundMode | enum | AUDIO_RECORDING = 3 | This API is deprecated in API version 9 and later versions and is migrated to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.| | backgroundTaskManager.BackgroundMode | enum | AUDIO_RECORDING = 3 | Deprecated in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager.BackgroundMode | enum | LOCATION = 4 | This API is deprecated in API version 9 and later versions and is migrated to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.| | backgroundTaskManager.BackgroundMode | enum | LOCATION = 4 | Deprecated in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager.BackgroundMode | enum | BLUETOOTH_INTERACTION = 5 | This API is deprecated in API version 9 and later versions and is migrated to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.| | backgroundTaskManager.BackgroundMode | enum | BLUETOOTH_INTERACTION = 5 | Deprecated in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager.BackgroundMode | enum | MULTI_DEVICE_CONNECTION = 6 | This API is deprecated in API version 9 and later versions and is migrated to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.| | backgroundTaskManager.BackgroundMode | enum | MULTI_DEVICE_CONNECTION = 6 | Deprecated in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager.BackgroundMode | enum | WIFI_INTERACTION = 7 | This API is deprecated in API version 9 and later versions and is migrated to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.| | backgroundTaskManager.BackgroundMode | enum | WIFI_INTERACTION = 7 | Deprecated in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager.BackgroundMode | enum | VOIP = 8 | This API is deprecated in API version 9 and later versions and is migrated to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.| | backgroundTaskManager.BackgroundMode | enum | VOIP = 8 | Deprecated in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager.BackgroundMode | enum | TASK_KEEPING = 9 | This API is deprecated in API version 9 and later versions and is migrated to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.| | backgroundTaskManager.BackgroundMode | enum | TASK_KEEPING = 9 | Deprecated in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager.DelaySuspendInfo | interface | interface DelaySuspendInfo | This API is deprecated in API version 9 and later versions and is migrated to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.| | backgroundTaskManager.DelaySuspendInfo | interface | interface DelaySuspendInfo | Deprecated in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager.DelaySuspendInfo | field | requestId: number | This API is deprecated in API version 9 and later versions and is migrated to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.| | backgroundTaskManager.DelaySuspendInfo | field | requestId: number | Deprecated in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager.DelaySuspendInfo | field | actualDelayTime: number | This API is deprecated in API version 9 and later versions and is migrated to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.| | backgroundTaskManager.DelaySuspendInfo | field | actualDelayTime: number | Deprecated in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager.ResourceType | enum | export enum ResourceType | This API is changed in API version 9 and migrated to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.| | backgroundTaskManager.ResourceType | enum | export enum ResourceType | Changed in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager.ResourceType | enum | CPU = 1 | This API is changed in API version 9 and migrated to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.| | backgroundTaskManager.ResourceType | enum | CPU = 1 | Changed in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager.ResourceType | enum | COMMON_EVENT = 1 << 1 | This API is changed in API version 9 and migrated to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.| | backgroundTaskManager.ResourceType | enum | COMMON_EVENT = 1 << 1 | Changed in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager.ResourceType | enum | TIMER = 1 << 2 | This API is changed in API version 9 and migrated to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.| | backgroundTaskManager.ResourceType | enum | TIMER = 1 << 2 | Changed in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager.ResourceType | enum | WORK_SCHEDULER = 1 << 3 | This API is changed in API version 9 and migrated to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.| | backgroundTaskManager.ResourceType | enum | WORK_SCHEDULER = 1 << 3 | Changed in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager.ResourceType | enum | BLUETOOTH = 1 << 4 | This API is changed in API version 9 and migrated to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.| | backgroundTaskManager.ResourceType | enum | BLUETOOTH = 1 << 4 | Changed in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager.ResourceType | enum | GPS = 1 << 5 | This API is changed in API version 9 and migrated to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.| | backgroundTaskManager.ResourceType | enum | GPS = 1 << 5 | Changed in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager.ResourceType | enum | AUDIO = 1 << 6 | This API is changed in API version 9 and migrated to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.| | backgroundTaskManager.ResourceType | enum | AUDIO = 1 << 6 | Changed in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager.EfficiencyResourcesRequest | interface | export interface EfficiencyResourcesRequest | This API is changed in API version 9 and migrated to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.| | backgroundTaskManager.EfficiencyResourcesRequest | interface | export interface EfficiencyResourcesRequest | Changed in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager.EfficiencyResourcesRequest | field | reason: string | This API is changed in API version 9 and migrated to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.| | backgroundTaskManager.EfficiencyResourcesRequest | field | reason: string | Changed in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager.EfficiencyResourcesRequest | field | isProcess?: bool | This API is changed in API version 9 and migrated to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.| | backgroundTaskManager.EfficiencyResourcesRequest | field | isProcess?: bool | Changed in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager.EfficiencyResourcesRequest | field | isPersist?: bool | This API is changed in API version 9 and migrated to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.| | backgroundTaskManager.EfficiencyResourcesRequest | field | isPersist?: bool | Changed in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager.EfficiencyResourcesRequest | field | timeOut: number | This API is changed in API version 9 and migrated to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.| | backgroundTaskManager.EfficiencyResourcesRequest | field | timeOut: number | Changed in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager.EfficiencyResourcesRequest | field | isApply: bool | This API is changed in API version 9 and migrated to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.| | backgroundTaskManager.EfficiencyResourcesRequest | field | isApply: bool | Changed in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
| backgroundTaskManager.EfficiencyResourcesRequest | field | resourceTypes: number | This API is changed in API version 9 and migrated to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.| | backgroundTaskManager.EfficiencyResourcesRequest | field | resourceTypes: number | Changed in API version 9 and moved to the **ohos.resourceschedule.backgroundTaskManager.d.ts** file.|
**Adaptation Guide**<br> **Adaptation Guide**
Import the **backgroundTaskManager** module. Import the **backgroundTaskManager** module.
``` ```
...@@ -63,107 +62,106 @@ import bundle form '@ohos.resourceschedule.backgroundTaskManager' ...@@ -63,107 +62,106 @@ import bundle form '@ohos.resourceschedule.backgroundTaskManager'
``` ```
Exception handling also needs to be adapted. For details, see the [backgroundTaskManager API reference](../../../application-dev/reference/apis/js-apis-resourceschedule-backgroundTaskManager.md). Exception handling also needs to be adapted. For details, see the [backgroundTaskManager API reference](../../../application-dev/reference/apis/js-apis-resourceschedule-backgroundTaskManager.md).
## c2.resourceschedule.usageStatistics ## c2.resourceschedule.usageStatistics
Rectified original APIs of **deviceUsageStatistics** of the resource scheduler subsystem. All APIs in API version 8 and earlier versions are deprecated, and original APIs in API version 9 are deleted. New APIs in API version 9 need to be used. The new APIs in API version 9 comply with the error code specifications. Rectified original APIs of **deviceUsageStatistics** of the resource scheduler subsystem. All APIs in API version 8 and earlier versions are deprecated, and original APIs in API version 9 are deleted. New APIs in API version 9 need to be used. The new APIs in API version 9 comply with the error code specifications.
**Change Impacts** **Change Impact**
The application developed based on the SDK versions of OpenHarmony 3.2.8.2 and later needs to adapt the modules and APIs in API version 9 and their methods for returning API error information. Otherwise, the original service logic will be affected. The application developed based on the SDK versions of OpenHarmony 3.2.8.2 and later needs to adapt the modules and APIs in API version 9 and their methods for returning API error information. Otherwise, the original service logic will be affected.
**Key API/Component Changes** **Key API/Component Changes**
The following methods, attributes, enumerations, and constants are changed in API version 9 and later versions. The **@ohos.bundleState.d.ts** file is deprecated, the **@ohos.resourceschedule.usageStatistics.d.ts** file is added, and the class name is changed from **bundleState** to **usageStatistics**. The following methods, attributes, enums, and constants are changed in API version 9 and later versions. The **@ohos.bundleState.d.ts** file is deprecated, the **@ohos.resourceschedule.usageStatistics.d.ts** file is added, and the class name is changed from **bundleState** to **usageStatistics**.
| Class | API Type | Method/Attribute/Enumeration/Constant | Change Type | | Class | API Type | Method/Attribute/Enum/Constant | Change Type |
| ----------------------------------------- | --------- | ------------------------------------------------------------ | ------------------------------------------------------------ | | ----------------------------------------- | --------- | ------------------------------------------------------------ | ------------------------------------------------------------ |
| bundleState | method | function isIdleState(bundleName: string, callback: AsyncCallback<boolean>): void; | Deprecated and migrated to **usageStatistics.isIdleState** | | bundleState | method | function isIdleState(bundleName: string, callback: AsyncCallback<boolean>): void; | Deprecated and moved to **usageStatistics.isIdleState**. |
| bundleState | method | function isIdleState(bundleName: string): Promise<boolean>; | Deprecated and migrated to **usageStatistics.isIdleState** | | bundleState | method | function isIdleState(bundleName: string): Promise<boolean>; | Deprecated and moved to **usageStatistics.isIdleState**. |
| bundleState | method | function queryAppUsagePriorityGroup(callback: AsyncCallback<number>): void; | Deprecated and changed to **function queryAppGroup(callback: AsyncCallback<number>): void;**| | bundleState | method | function queryAppUsagePriorityGroup(callback: AsyncCallback<number>): void; | Deprecated and changed to **function queryAppGroup(callback: AsyncCallback<number>): void;**.|
| bundleState | method | function queryAppUsagePriorityGroup(): Promise<number>; | Deprecated and changed to **function queryAppGroup(): Promise<number>;** | | bundleState | method | function queryAppUsagePriorityGroup(): Promise<number>; | Deprecated and changed to **function queryAppGroup(): Promise<number>;**. |
| bundleState | method | function queryBundleStateInfos(begin: number, end: number, callback: AsyncCallback<BundleActiveInfoResponse>): void; | Deprecated and changed to **function queryBundleStatsInfos(begin: number, end: number, callback: AsyncCallback<BundleStatsMap>): void;**| | bundleState | method | function queryBundleStateInfos(begin: number, end: number, callback: AsyncCallback<BundleActiveInfoResponse>): void; | Deprecated and changed to **function queryBundleStatsInfos(begin: number, end: number, callback: AsyncCallback<BundleStatsMap>): void;**.|
| bundleState | method | function queryBundleStateInfos(begin: number, end: number): Promise<BundleActiveInfoResponse>; | Deprecated and changed to **function queryBundleStatsInfos(begin: number, end: number): Promise<BundleStatsMap>;**| | bundleState | method | function queryBundleStateInfos(begin: number, end: number): Promise<BundleActiveInfoResponse>; | Deprecated and changed to **function queryBundleStatsInfos(begin: number, end: number): Promise<BundleStatsMap>;**.|
| bundleState | method | function queryBundleStateInfoByInterval(byInterval: IntervalType, begin: number, end: number): Promise<Array<BundleStateInfo>>; | Deprecated and changed to **function queryBundleStatsInfoByInterval(byInterval: IntervalType, begin: number, end: number): Promise<Array<BundleStatsInfo>>;**| | bundleState | method | function queryBundleStateInfoByInterval(byInterval: IntervalType, begin: number, end: number): Promise<Array<BundleStateInfo>>; | Deprecated and changed to **function queryBundleStatsInfoByInterval(byInterval: IntervalType, begin: number, end: number): Promise<Array<BundleStatsInfo>>;**.|
| bundleState | method | function queryBundleStateInfoByInterval(byInterval: IntervalType, begin: number, end: number, callback: AsyncCallback<Array<BundleStateInfo>>): void; | Deprecated and changed to **function queryBundleStatsInfoByInterval(byInterval: IntervalType, begin: number, end: number, callback: AsyncCallback<Array<BundleStatsInfo>>): void;**| | bundleState | method | function queryBundleStateInfoByInterval(byInterval: IntervalType, begin: number, end: number, callback: AsyncCallback<Array<BundleStateInfo>>): void; | Deprecated and changed to **function queryBundleStatsInfoByInterval(byInterval: IntervalType, begin: number, end: number, callback: AsyncCallback<Array<BundleStatsInfo>>): void;**.|
| bundleState | method | function queryBundleActiveStates(begin: number, end: number): Promise<Array<BundleActiveState>>; | Deprecated and changed to **function queryBundleEvents(begin: number, end: number): Promise<Array<BundleEvents>>;**| | bundleState | method | function queryBundleActiveStates(begin: number, end: number): Promise<Array<BundleActiveState>>; | Deprecated and changed to **function queryBundleEvents(begin: number, end: number): Promise<Array<BundleEvents>>;**.|
| bundleState | method | function queryBundleActiveStates(begin: number, end: number, callback: AsyncCallback<Array<BundleActiveState>>): void; | Deprecated and changed to **function queryBundleEvents(begin: number, end: number, callback: AsyncCallback<Array<BundleEvents>>): void;**| | bundleState | method | function queryBundleActiveStates(begin: number, end: number, callback: AsyncCallback<Array<BundleActiveState>>): void; | Deprecated and changed to **function queryBundleEvents(begin: number, end: number, callback: AsyncCallback<Array<BundleEvents>>): void;**.|
| bundleState | method | function queryCurrentBundleActiveStates(begin: number, end: number): Promise<Array<BundleActiveState>>; | Deprecated and changed to **function queryCurrentBundleEvents(begin: number, end: number): Promise<Array<BundleEvents>>;**| | bundleState | method | function queryCurrentBundleActiveStates(begin: number, end: number): Promise<Array<BundleActiveState>>; | Deprecated and changed to **function queryCurrentBundleEvents(begin: number, end: number): Promise<Array<BundleEvents>>;**.|
| bundleState | method | function queryCurrentBundleActiveStates(begin: number, end: number, callback: AsyncCallback<Array<BundleActiveState>>): void; | Deprecated and changed to **function queryCurrentBundleEvents(begin: number, end: number, callback: AsyncCallback<Array<BundleEvents>>): void;**| | bundleState | method | function queryCurrentBundleActiveStates(begin: number, end: number, callback: AsyncCallback<Array<BundleActiveState>>): void; | Deprecated and changed to **function queryCurrentBundleEvents(begin: number, end: number, callback: AsyncCallback<Array<BundleEvents>>): void;**.|
| bundleState | method | function getRecentlyUsedModules(maxNum?: number): Promise<Array<BundleActiveModuleInfo>>; | Deprecated and changed to the following two APIs: **function QueryModuleUsageRecords(maxNum: number): Promise<Array<HapModuleInfo>>;** and **function QueryModuleUsageRecords(): Promise<Array<HapModuleInfo>>;**| | bundleState | method | function getRecentlyUsedModules(maxNum?: number): Promise<Array<BundleActiveModuleInfo>>; | Deprecated and changed to **function QueryModuleUsageRecords(maxNum: number): Promise<Array<HapModuleInfo>>;** and **function QueryModuleUsageRecords(): Promise<Array<HapModuleInfo>>;**.|
| bundleState | method | function getRecentlyUsedModules(maxNum?: number, callback: AsyncCallback<Array<BundleActiveModuleInfo>>): void; | Deprecated and changed to the following two APIs: **function QueryModuleUsageRecords(maxNum: number, callback: AsyncCallback<Array<HapModuleInfo>>): void;** and **function QueryModuleUsageRecords(callback: AsyncCallback<Array<HapModuleInfo>>): void;**| | bundleState | method | function getRecentlyUsedModules(maxNum?: number, callback: AsyncCallback<Array<BundleActiveModuleInfo>>): void; | Deprecated and changed to **function QueryModuleUsageRecords(maxNum: number, callback: AsyncCallback<Array<HapModuleInfo>>): void;** and **function QueryModuleUsageRecords(callback: AsyncCallback<Array<HapModuleInfo>>): void;**.|
| bundleState | method | function queryAppUsagePriorityGroup(bundleName? : string): Promise<number>; | Deprecated and changed to **function queryAppGroup(bundleName: string): Promise<number>;**| | bundleState | method | function queryAppUsagePriorityGroup(bundleName? : string): Promise<number>; | Deprecated and changed to **function queryAppGroup(bundleName: string): Promise<number>;**.|
| bundleState | method | function queryAppUsagePriorityGroup(bundleName? : string, callback: AsyncCallback<number>): void; | Deprecated and changed to **function queryAppGroup(bundleName: string, callback: AsyncCallback<number>): void;**| | bundleState | method | function queryAppUsagePriorityGroup(bundleName? : string, callback: AsyncCallback<number>): void; | Deprecated and changed to **function queryAppGroup(bundleName: string, callback: AsyncCallback<number>): void;**.|
| bundleState | method | function setBundleGroup(bundleName: string, newGroup: GroupType, callback: AsyncCallback<void>): void; | Deprecated and changed to **function setAppGroup(bundleName: string, newGroup: GroupType, callback: AsyncCallback<void>): void;**| | bundleState | method | function setBundleGroup(bundleName: string, newGroup: GroupType, callback: AsyncCallback<void>): void; | Deprecated and changed to **function setAppGroup(bundleName: string, newGroup: GroupType, callback: AsyncCallback<void>): void;**.|
| bundleState | method | function setBundleGroup(bundleName: string, newGroup: GroupType): Promise<void>; | Deprecated and changed to **function setAppGroup(bundleName: string, newGroup: GroupType): Promise<void>;**| | bundleState | method | function setBundleGroup(bundleName: string, newGroup: GroupType): Promise<void>; | Deprecated and changed to **function setAppGroup(bundleName: string, newGroup: GroupType): Promise<void>;**.|
| bundleState | method | function registerGroupCallBack(callback: Callback<BundleActiveGroupCallbackInfo>, callback: AsyncCallback<void>): void; | Deprecated and changed to **function registerAppGroupCallBack(callback: Callback<AppGroupCallbackInfo>, callback: AsyncCallback<void>): void;**| | bundleState | method | function registerGroupCallBack(callback: Callback<BundleActiveGroupCallbackInfo>, callback: AsyncCallback<void>): void; | Deprecated and changed to **function registerAppGroupCallBack(callback: Callback<AppGroupCallbackInfo>, callback: AsyncCallback<void>): void;**.|
| bundleState | method | function registerGroupCallBack(callback: Callback<BundleActiveGroupCallbackInfo>): Promise<void>; | Deprecated and changed to **function registerAppGroupCallBack(callback: Callback<AppGroupCallbackInfo>): Promise<void>;**| | bundleState | method | function registerGroupCallBack(callback: Callback<BundleActiveGroupCallbackInfo>): Promise<void>; | Deprecated and changed to **function registerAppGroupCallBack(callback: Callback<AppGroupCallbackInfo>): Promise<void>;**.|
| bundleState | method | function unRegisterGroupCallBack(callback: AsyncCallback<void>): void; | Deprecated and changed to **function unregisterAppGroupCallBack(): Promise<void>;**| | bundleState | method | function unRegisterGroupCallBack(callback: AsyncCallback<void>): void; | Changed to **function unregisterAppGroupCallBack(): Promise<void>;**.|
| bundleState | method | function unRegisterGroupCallBack(): Promise<void>; | Deprecated and changed to **function unregisterAppGroupCallBack(): Promise<void>;**| | bundleState | method | function unRegisterGroupCallBack(): Promise<void>; | Changed to **function unregisterAppGroupCallBack(): Promise<void>;**.|
| bundleState | method | function queryBundleActiveEventStates(begin: number, end: number, callback: AsyncCallback<Array<BundleActiveEventState>>): void; | Changed to **function queryDeviceEventStats(begin: number, end: number, callback: AsyncCallback<Array<DeviceEventStats>>): void;**| | bundleState | method | function queryBundleActiveEventStates(begin: number, end: number, callback: AsyncCallback<Array<BundleActiveEventState>>): void; | Changed to **function queryDeviceEventStats(begin: number, end: number, callback: AsyncCallback<Array<DeviceEventStats>>): void;**|
| bundleState | method | function queryBundleActiveEventStates(begin: number, end: number): Promise<Array<BundleActiveEventState>>; | Changed in API version 9 and later versions to **function queryDeviceEventStats(begin: number, end: number): Promise<Array<DeviceEventStats>>;**| | bundleState | method | function queryBundleActiveEventStates(begin: number, end: number): Promise<Array<BundleActiveEventState>>; | Changed in API version 9 to **function queryDeviceEventStats(begin: number, end: number): Promise<Array<DeviceEventStats>>;**.|
| bundleState | method | function queryAppNotificationNumber(begin: number, end: number, callback: AsyncCallback<Array<BundleActiveEventState>>): void; | Changed in API version 9 and later versions to **function queryNotificationEventStats(begin: number, end: number, callback: AsyncCallback<Array<NotificationEventStats >>): void;**| | bundleState | method | function queryAppNotificationNumber(begin: number, end: number, callback: AsyncCallback<Array<BundleActiveEventState>>): void; | Changed in API version 9 to **function queryNotificationEventStats(begin: number, end: number, callback: AsyncCallback<Array<NotificationEventStats >>): void;**.|
| bundleState | method | function queryAppNotificationNumber(begin: number, end: number): Promise<Array<BundleActiveEventState>>; | Changed in API version 9 and later versions to **function queryNotificationEventStats(begin: number, end: number): Promise<Array<NotificationEventStats >>;**| | bundleState | method | function queryAppNotificationNumber(begin: number, end: number): Promise<Array<BundleActiveEventState>>; | Changed in API version 9 to **function queryNotificationEventStats(begin: number, end: number): Promise<Array<NotificationEventStats >>;**.|
| bundleState.BundleActiveGroupCallbackInfo | interface | interface BundleActiveGroupCallbackInfo | Changed to **usageStatistics.AppGroupCallbackInfo** | | bundleState.BundleActiveGroupCallbackInfo | interface | interface BundleActiveGroupCallbackInfo | Moved to **usageStatistics.AppGroupCallbackInfo**. |
| bundleState.BundleActiveGroupCallbackInfo | field | bundleName: string | Changed and migrated to **usageStatistics.AppGroupCallbackInfo** | | bundleState.BundleActiveGroupCallbackInfo | field | bundleName: string | Moved to **usageStatistics.AppGroupCallbackInfo**. |
| bundleState.BundleActiveGroupCallbackInfo | field | changeReason: number | Changed and migrated to **usageStatistics.AppGroupCallbackInfo** | | bundleState.BundleActiveGroupCallbackInfo | field | changeReason: number | Moved to **usageStatistics.AppGroupCallbackInfo**. |
| bundleState.BundleActiveGroupCallbackInfo | field | userId: number | Changed and migrated to **usageStatistics.AppGroupCallbackInfo** | | bundleState.BundleActiveGroupCallbackInfo | field | userId: number | Moved to **usageStatistics.AppGroupCallbackInfo**. |
| bundleState.BundleActiveGroupCallbackInfo | field | appUsageNewGroup: number | Deprecated and changed to **appNewGroup** | | bundleState.BundleActiveGroupCallbackInfo | field | appUsageNewGroup: number | Deprecated and changed to **appNewGroup**. |
| bundleState.BundleActiveGroupCallbackInfo | field | appUsageOldGroup: number | Deprecated and changed to **appOldGroup** | | bundleState.BundleActiveGroupCallbackInfo | field | appUsageOldGroup: number | Deprecated and changed to **appOldGroup**. |
| bundleState.BundleActiveEventState | interface | interface BundleActiveEventState | Deprecated and changed to **usageStatistics.DeviceEventStats** | | bundleState.BundleActiveEventState | interface | interface BundleActiveEventState | Deprecated and changed to **usageStatistics.DeviceEventStats**. |
| bundleState.BundleActiveEventState | field | count: number | Changed and migrated to **usageStatistics.DeviceEventStats** | | bundleState.BundleActiveEventState | field | count: number | Moved to **usageStatistics.DeviceEventStats**. |
| bundleState.BundleActiveEventState | field | eventId: number | Changed and migrated to **usageStatistics.DeviceEventStats** | | bundleState.BundleActiveEventState | field | eventId: number | Moved to **usageStatistics.DeviceEventStats**. |
| bundleState.BundleActiveEventState | field | name: string | Changed and migrated to **usageStatistics.DeviceEventStats** | | bundleState.BundleActiveEventState | field | name: string | Moved to **usageStatistics.DeviceEventStats**. |
| bundleState.BundleActiveModuleInfo | interface | interface BundleActiveModuleInfo | Changed in API version 9 and later versions to **usageStatistics.HapModuleInfo** | | bundleState.BundleActiveModuleInfo | interface | interface BundleActiveModuleInfo | Changed in API version 9 to **usageStatistics.HapModuleInfo**. |
| bundleState.BundleActiveModuleInfo | field | formRecords: Array<BundleActiveFormInfo> | Changed to **formRecords: Array<HapModuleInfo>** | | bundleState.BundleActiveModuleInfo | field | formRecords: Array<BundleActiveFormInfo> | Changed to **formRecords: Array<HapModuleInfo>**. |
| bundleState.BundleActiveModuleInfo | field | lastModuleUsedTime: number | Changed and migrated to **usageStatistics.HapModuleInfo** | | bundleState.BundleActiveModuleInfo | field | lastModuleUsedTime: number | Moved to **usageStatistics.HapModuleInfo**. |
| bundleState.BundleActiveModuleInfo | field | launchedCount: number | Changed and migrated to **usageStatistics.HapModuleInfo** | | bundleState.BundleActiveModuleInfo | field | launchedCount: number | Moved to **usageStatistics.HapModuleInfo**. |
| bundleState.BundleActiveModuleInfo | field | abilityIconId?: number | Changed and migrated to **usageStatistics.HapModuleInfo** | | bundleState.BundleActiveModuleInfo | field | abilityIconId?: number | Moved to **usageStatistics.HapModuleInfo**. |
| bundleState.BundleActiveModuleInfo | field | abilityDescriptionId?: number | Changed and migrated to **usageStatistics.HapModuleInfo** | | bundleState.BundleActiveModuleInfo | field | abilityDescriptionId?: number | Moved to **usageStatistics.HapModuleInfo**. |
| bundleState.BundleActiveModuleInfo | field | abilityLableId?: number | Changed and migrated to **usageStatistics.HapModuleInfo** | | bundleState.BundleActiveModuleInfo | field | abilityLableId?: number | Moved to **usageStatistics.HapModuleInfo**. |
| bundleState.BundleActiveModuleInfo | field | descriptionId?: number; | Changed and migrated to **usageStatistics.HapModuleInfo** | | bundleState.BundleActiveModuleInfo | field | descriptionId?: number; | Moved to **usageStatistics.HapModuleInfo**. |
| bundleState.BundleActiveModuleInfo | field | labelId?: number | Changed and migrated to **usageStatistics.HapModuleInfo** | | bundleState.BundleActiveModuleInfo | field | labelId?: number | Moved to **usageStatistics.HapModuleInfo**. |
| bundleState.BundleActiveModuleInfo | field | appLabelId?: number | Changed and migrated to **usageStatistics.HapModuleInfo** | | bundleState.BundleActiveModuleInfo | field | appLabelId?: number | Moved to **usageStatistics.HapModuleInfo**. |
| bundleState.BundleActiveModuleInfo | field | abilityName?: string | Changed and migrated to **usageStatistics.HapModuleInfo** | | bundleState.BundleActiveModuleInfo | field | abilityName?: string | Moved to **usageStatistics.HapModuleInfo**. |
| bundleState.BundleActiveModuleInfo | field | moduleName: string | Changed and migrated to **usageStatistics.HapModuleInfo** | | bundleState.BundleActiveModuleInfo | field | moduleName: string | Moved to **usageStatistics.HapModuleInfo**. |
| bundleState.BundleActiveModuleInfo | field | bundleName: string | Changed and migrated to **usageStatistics.HapModuleInfo** | | bundleState.BundleActiveModuleInfo | field | bundleName: string | Moved to **usageStatistics.HapModuleInfo**. |
| bundleState.BundleActiveModuleInfo | field | deviceId?: string | Changed and migrated to **usageStatistics.HapModuleInfo** | | bundleState.BundleActiveModuleInfo | field | deviceId?: string | Moved to **usageStatistics.HapModuleInfo**. |
| bundleState.GroupType | enum | enum GroupType | Changed and migrated to **usageStatistics.GroupType** | | bundleState.GroupType | enum | enum GroupType | Moved to **usageStatistics.GroupType**. |
| bundleState.GroupType | enum | ACTIVE_GROUP_ALIVE | Deprecated and changed to **ALIVE_GROUP** | | bundleState.GroupType | enum | ACTIVE_GROUP_ALIVE | Deprecated and changed to **ALIVE_GROUP**. |
| bundleState.GroupType | enum | ACTIVE_GROUP_DAILY | Deprecated and changed to **DAILY_GROUP** | | bundleState.GroupType | enum | ACTIVE_GROUP_DAILY | Deprecated and changed to **DAILY_GROUP**. |
| bundleState.GroupType | enum | ACTIVE_GROUP_FIXED | Deprecated and changed to **FIXED_GROUP** | | bundleState.GroupType | enum | ACTIVE_GROUP_FIXED | Deprecated and changed to **FIXED_GROUP**. |
| bundleState.GroupType | enum | ACTIVE_GROUP_RARE | Deprecated and changed to **RARE_GROUP** | | bundleState.GroupType | enum | ACTIVE_GROUP_RARE | Deprecated and changed to **RARE_GROUP**. |
| bundleState.GroupType | enum | ACTIVE_GROUP_LIMIT | Deprecated and changed to **LIMITED_GROUP** | | bundleState.GroupType | enum | ACTIVE_GROUP_LIMIT | Deprecated and changed to **LIMITED_GROUP**. |
| bundleState.GroupType | enum | ACTIVE_GROUP_NEVER | Deprecated and changed to **NEVER_GROUP** | | bundleState.GroupType | enum | ACTIVE_GROUP_NEVER | Deprecated and changed to **NEVER_GROUP**. |
| bundleState.IntervalType | enum | enum IntervalType | Deprecated and migrated to **usageStatistics.IntervalType** | | bundleState.IntervalType | enum | enum IntervalType | Deprecated and moved to **usageStatistics.IntervalType**. |
| bundleState.IntervalType | enum | BY_OPTIMIZED | Deprecated and migrated to **usageStatistics.IntervalType** | | bundleState.IntervalType | enum | BY_OPTIMIZED | Deprecated and moved to **usageStatistics.IntervalType**. |
| bundleState.IntervalType | enum | BY_DAILY | Deprecated and migrated to **usageStatistics.IntervalType** | | bundleState.IntervalType | enum | BY_DAILY | Deprecated and moved to **usageStatistics.IntervalType**. |
| bundleState.IntervalType | enum | BY_WEEKLY | Deprecated and migrated to **usageStatistics.IntervalType** | | bundleState.IntervalType | enum | BY_WEEKLY | Deprecated and moved to **usageStatistics.IntervalType**. |
| bundleState.IntervalType | enum | BY_MONTHLY | Deprecated and migrated to **usageStatistics.IntervalType** | | bundleState.IntervalType | enum | BY_MONTHLY | Deprecated and moved to **usageStatistics.IntervalType**. |
| bundleState.IntervalType | enum | BY_ANNUALLY | Deprecated and migrated to **usageStatistics.IntervalType** | | bundleState.IntervalType | enum | BY_ANNUALLY | Deprecated and moved to **usageStatistics.IntervalType**. |
| bundleState.BundleActiveInfoResponse | interface | interface BundleActiveInfoResponse | Deprecated and changed to **usageStatistics.BundleStatsMap** | | bundleState.BundleActiveInfoResponse | interface | interface BundleActiveInfoResponse | Deprecated and changed to **usageStatistics.BundleStatsMap**. |
| bundleState.BundleActiveState | interface | interface BundleActiveState | Deprecated and changed to **usageStatistics.BundleEvents** | | bundleState.BundleActiveState | interface | interface BundleActiveState | Deprecated and changed to **usageStatistics.BundleEvents**. |
| bundleState.BundleActiveState | field | stateType?: number | Deprecated and changed to **eventId** | | bundleState.BundleActiveState | field | stateType?: number | Deprecated and changed to **eventId**. |
| bundleState.BundleActiveState | field | stateOccurredTime?: number | Deprecated and changed to **eventOccurredTime** | | bundleState.BundleActiveState | field | stateOccurredTime?: number | Deprecated and changed to **eventOccurredTime**. |
| bundleState.BundleActiveState | field | nameOfClass?: string | Deprecated and migrated to **usageStatistics.BundleEvents** | | bundleState.BundleActiveState | field | nameOfClass?: string | Deprecated and moved to **usageStatistics.BundleEvents**. |
| bundleState.BundleActiveState | field | indexOfLink?: string | Deprecated and migrated to **usageStatistics.BundleEvents** | | bundleState.BundleActiveState | field | indexOfLink?: string | Deprecated and moved to **usageStatistics.BundleEvents**. |
| bundleState.BundleActiveState | field | bundleName?: string | Deprecated and migrated to **usageStatistics.BundleEvents** | | bundleState.BundleActiveState | field | bundleName?: string | Deprecated and moved to **usageStatistics.BundleEvents**. |
| bundleState.BundleActiveState | field | appUsagePriorityGroup?: number | Deprecated and changed to **appGroup** | | bundleState.BundleActiveState | field | appUsagePriorityGroup?: number | Deprecated and changed to **appGroup**. |
| bundleState.BundleStateInfo | interface | interface BundleStateInfo | Deprecated and changed to **usageStatistics.BundleStatsInfo** | | bundleState.BundleStateInfo | interface | interface BundleStateInfo | Deprecated and changed to **usageStatistics.BundleStatsInfo**. |
| bundleState.BundleStateInfo | method | merge(toMerge: BundleStateInfo): void | Deprecated | | bundleState.BundleStateInfo | method | merge(toMerge: BundleStateInfo): void | Deprecated. |
| bundleState.BundleStateInfo | field | infosEndTime?: number | Deprecated and migrated to **usageStatistics.BundleStatsInfo** | | bundleState.BundleStateInfo | field | infosEndTime?: number | Deprecated and moved to **usageStatistics.BundleStatsInfo**. |
| bundleState.BundleStateInfo | field | infosBeginTime?: number | Deprecated and migrated to **usageStatistics.BundleStatsInfo** | | bundleState.BundleStateInfo | field | infosBeginTime?: number | Deprecated and moved to **usageStatistics.BundleStatsInfo**. |
| bundleState.BundleStateInfo | field | fgAbilityPrevAccessTime?: number | Deprecated and migrated to **usageStatistics.BundleStatsInfo** | | bundleState.BundleStateInfo | field | fgAbilityPrevAccessTime?: number | Deprecated and moved to **usageStatistics.BundleStatsInfo**. |
| bundleState.BundleStateInfo | field | fgAbilityAccessTotalTime?: number | Deprecated and migrated to **usageStatistics.BundleStatsInfo** | | bundleState.BundleStateInfo | field | fgAbilityAccessTotalTime?: number | Deprecated and moved to **usageStatistics.BundleStatsInfo**. |
| bundleState.BundleStateInfo | field | bundleName?: string | Deprecated and migrated to **usageStatistics.BundleStatsInfo** | | bundleState.BundleStateInfo | field | bundleName?: string | Deprecated and moved to **usageStatistics.BundleStatsInfo**. |
| bundleState.BundleStateInfo | field | abilitySeenTotalTime?: number | Deprecated and migrated to **usageStatistics.BundleStatsInfo** | | bundleState.BundleStateInfo | field | abilitySeenTotalTime?: number | Deprecated and moved to **usageStatistics.BundleStatsInfo**. |
| bundleState.BundleStateInfo | field | abilityPrevSeenTime?: number | Deprecated and migrated to **usageStatistics.BundleStatsInfo** | | bundleState.BundleStateInfo | field | abilityPrevSeenTime?: number | Deprecated and moved to **usageStatistics.BundleStatsInfo**. |
| bundleState.BundleStateInfo | field | abilityPrevAccessTime?: number | Deprecated and migrated to **usageStatistics.BundleStatsInfo** | | bundleState.BundleStateInfo | field | abilityPrevAccessTime?: number | Deprecated and moved to **usageStatistics.BundleStatsInfo**. |
| bundleState.BundleStateInfo | field | abilityInFgTotalTime?: number | Deprecated and migrated to **usageStatistics.BundleStatsInfo** | | bundleState.BundleStateInfo | field | abilityInFgTotalTime?: number | Deprecated and moved to **usageStatistics.BundleStatsInfo**. |
| bundleState.BundleStateInfo | field | id: number | Deprecated and migrated to **usageStatistics.BundleStatsInfo** | | bundleState.BundleStateInfo | field | id: number | Deprecated and moved to **usageStatistics.BundleStatsInfo**. |
| bundleState | namespace | declare namespace bundleState | Deprecated and changed to **usageStatistics**, and migrated to **ohos.resourceschedule.usageStatistics.d.ts**| | bundleState | namespace | declare namespace bundleState | Deprecated and changed to **usageStatistics**, and moved to **ohos.resourceschedule.usageStatistics.d.ts**.|
**Adaptation Guide**<br> **Adaptation Guide**
Import the **usageStatistics** module. Import the **usageStatistics** module.
``` ```
...@@ -172,70 +170,69 @@ import bundle form '@ohos.resourceschedule.usageStatistics' ...@@ -172,70 +170,69 @@ import bundle form '@ohos.resourceschedule.usageStatistics'
Exception handling also needs to be adapted. For details, see the [usageStatistics API reference](../../../application-dev/reference/apis/js-apis-resourceschedule-deviceUsageStatistics.md). Exception handling also needs to be adapted. For details, see the [usageStatistics API reference](../../../application-dev/reference/apis/js-apis-resourceschedule-deviceUsageStatistics.md).
## c3.resourceschedule.workScheduler ## c3.resourceschedule.workScheduler
Rectified original APIs of **workScheduler** of the resource scheduler subsystem. The original APIs in API version 9 are changed to new APIs in API version 9. The new APIs in API version 9 comply with the error code specifications. Rectified original APIs of **workScheduler** of the resource scheduler subsystem. The original APIs in API version 9 are changed to new APIs in API version 9. The new APIs in API version 9 comply with the error code specifications.
**Change Impacts** **Change Impact**
The application developed based on the SDK versions of OpenHarmony 3.2.8.2 and later needs to adapt the modules and APIs in API version 9 and their methods for returning API error information. Otherwise, the original service logic will be affected. The application developed based on the SDK versions of OpenHarmony 3.2.8.2 and later needs to adapt the modules and APIs in API version 9 and their methods for returning API error information. Otherwise, the original service logic will be affected.
**Key API/Component Changes** **Key API/Component Changes**
The following methods, attributes, enumerations, and constants are changed in API version 9 and later versions. The **@ohos.workScheduler.d.ts** file is deprecated and related APIs are migrated to the newly added **@ohos.resourceschedule.workScheduler.d.ts** file. The following methods, attributes, enums, and constants are changed in API version 9 and later versions. The **@ohos.workScheduler.d.ts** file is deprecated and related APIs are moved to the newly added **@ohos.resourceschedule.workScheduler.d.ts** file.
| Class| API Type| Declaration| Change Type| | Class| API Type| Declaration| Change Type|
| -- | -- | -- | -- | | -- | -- | -- | -- |
| workScheduler | namespace | declare namespace workScheduler | Changed in API version 9 and migrated to the **ohos.resourceschedule.workScheduler.d.ts** file| | workScheduler | namespace | declare namespace workScheduler | Changed in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.WorkInfo | interface | export interface WorkInfo | Changed in API version 9 and migrated to the **ohos.resourceschedule.workScheduler.d.ts** file| | workScheduler.WorkInfo | interface | export interface WorkInfo | Changed in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.WorkInfo | field | parameters?: {[key: string]: any} | Changed in API version 9 and migrated to the **ohos.resourceschedule.workScheduler.d.ts** file| | workScheduler.WorkInfo | field | parameters?: {[key: string]: any} | Changed in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.WorkInfo | field | idleWaitTime?: number | Changed in API version 9 and migrated to the **ohos.resourceschedule.workScheduler.d.ts** file| | workScheduler.WorkInfo | field | idleWaitTime?: number | Changed in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.WorkInfo | field | isDeepIdle?: boolean | Changed in API version 9 and migrated to the **ohos.resourceschedule.workScheduler.d.ts** file| | workScheduler.WorkInfo | field | isDeepIdle?: boolean | Changed in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.WorkInfo | field | repeatCount?: number | Changed in API version 9 and migrated to the **ohos.resourceschedule.workScheduler.d.ts** file| | workScheduler.WorkInfo | field | repeatCount?: number | Changed in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.WorkInfo | field | isRepeat?: boolean | Changed in API version 9 and migrated to the **ohos.resourceschedule.workScheduler.d.ts** file| | workScheduler.WorkInfo | field | isRepeat?: boolean | Changed in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.WorkInfo | field | repeatCycleTime?: number | Changed in API version 9 and migrated to the **ohos.resourceschedule.workScheduler.d.ts** file| | workScheduler.WorkInfo | field | repeatCycleTime?: number | Changed in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.WorkInfo | field | storageRequest?: StorageRequest | Changed in API version 9 and migrated to the **ohos.resourceschedule.workScheduler.d.ts** file| | workScheduler.WorkInfo | field | storageRequest?: StorageRequest | Changed in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.WorkInfo | field | batteryStatus?: BatteryStatus | Changed in API version 9 and migrated to the **ohos.resourceschedule.workScheduler.d.ts** file| | workScheduler.WorkInfo | field | batteryStatus?: BatteryStatus | Changed in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.WorkInfo | field | batteryLevel?: number | Changed in API version 9 and migrated to the **ohos.resourceschedule.workScheduler.d.ts** file| | workScheduler.WorkInfo | field | batteryLevel?: number | Changed in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.WorkInfo | field | chargerType?: ChargingType | Changed in API version 9 and migrated to the **ohos.resourceschedule.workScheduler.d.ts** file| | workScheduler.WorkInfo | field | chargerType?: ChargingType | Changed in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.WorkInfo | field | isCharging?: boolean | Changed in API version 9 and migrated to the **ohos.resourceschedule.workScheduler.d.ts** file| | workScheduler.WorkInfo | field | isCharging?: boolean | Changed in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.WorkInfo | field | networkType?: NetworkType | Changed in API version 9 and migrated to the **ohos.resourceschedule.workScheduler.d.ts** file| | workScheduler.WorkInfo | field | networkType?: NetworkType | Changed in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.WorkInfo | field | isPersisted?: boolean | Changed in API version 9 and migrated to the **ohos.resourceschedule.workScheduler.d.ts** file| | workScheduler.WorkInfo | field | isPersisted?: boolean | Changed in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.WorkInfo | field | abilityName: string | Changed in API version 9 and migrated to the **ohos.resourceschedule.workScheduler.d.ts** file| | workScheduler.WorkInfo | field | abilityName: string | Changed in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.WorkInfo | field | bundleName: string | Changed in API version 9 and migrated to the **ohos.resourceschedule.workScheduler.d.ts** file| | workScheduler.WorkInfo | field | bundleName: string | Changed in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.WorkInfo | field | workId: number | Changed in API version 9 and migrated to the **ohos.resourceschedule.workScheduler.d.ts** file| | workScheduler.WorkInfo | field | workId: number | Changed in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler | method | function isLastWorkTimeOut(workId: number): Promise; | Changed in API version 9 and migrated to the **ohos.resourceschedule.workScheduler.d.ts** file| | workScheduler | method | function isLastWorkTimeOut(workId: number): Promise; | Changed in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler | method | function isLastWorkTimeOut(workId: number, callback: AsyncCallback<void>): boolean; | Changed in API version 9 and migrated to the **ohos.resourceschedule.workScheduler.d.ts** file| | workScheduler | method | function isLastWorkTimeOut(workId: number, callback: AsyncCallback<void>): boolean; | Changed in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler | method | function stopAndClearWorks(): boolean; | Changed in API version 8 to **function stopAndClearWorks(): boolean;** and migrated to the **ohos.resourceschedule.workScheduler.d.ts** file| | workScheduler | method | function stopAndClearWorks(): boolean; | Changed in API version 8 to **function stopAndClearWorks(): boolean;** and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler | method | function obtainAllWorks(): Promise<Array<WorkInfo>>; | Changed in API version 9 and migrated to the **ohos.resourceschedule.workScheduler.d.ts** file| | workScheduler | method | function obtainAllWorks(): Promise<Array<WorkInfo>>; | Changed in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler | method | function obtainAllWorks(callback: AsyncCallback<void>): Array<WorkInfo>; | Changed in API version 9 and migrated to the **ohos.resourceschedule.workScheduler.d.ts** file| | workScheduler | method | function obtainAllWorks(callback: AsyncCallback<void>): Array<WorkInfo>; | Changed in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler | method | function getWorkStatus(workId: number): Promise<WorkInfo>; | Changed in API version 9 and migrated to the **ohos.resourceschedule.workScheduler.d.ts** file| | workScheduler | method | function getWorkStatus(workId: number): Promise<WorkInfo>; | Changed in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler | method | function getWorkStatus(workId: number, callback: AsyncCallback<WorkInfo>): void; | Changed in API version 9 and migrated to the **ohos.resourceschedule.workScheduler.d.ts** file| | workScheduler | method | function getWorkStatus(workId: number, callback: AsyncCallback<WorkInfo>): void; | Changed in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler | method | function stopWork(work: WorkInfo, needCancel?: boolean): boolean; | Changed in API version 8 to **function stopWork(work: WorkInfo, needCancel?: boolean): void;** and migrated to the **ohos.resourceschedule.workScheduler.d.ts** file| | workScheduler | method | function stopWork(work: WorkInfo, needCancel?: boolean): boolean; | Changed in API version 8 to **function stopWork(work: WorkInfo, needCancel?: boolean): void;** and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler | method | function startWork(work: WorkInfo): boolean; | Changed in API version 9 to **function startWork(work: WorkInfo): void;** and migrated to the **ohos.resourceschedule.workScheduler.d.ts** file| | workScheduler | method | function startWork(work: WorkInfo): boolean; | Changed in API version 9 to **function startWork(work: WorkInfo): void;** and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.NetworkType | enum | export enum NetworkType | Changed in API version 9 and migrated to the **ohos.resourceschedule.workScheduler.d.ts** file| | workScheduler.NetworkType | enum | export enum NetworkType | Changed in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.NetworkType | enum | NETWORK_TYPE_ANY = 0 | Changed in API version 9 and migrated to the **ohos.resourceschedule.workScheduler.d.ts** file| | workScheduler.NetworkType | enum | NETWORK_TYPE_ANY = 0 | Changed in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.NetworkType | enum | NETWORK_TYPE_MOBILE | Changed in API version 9 and migrated to the **ohos.resourceschedule.workScheduler.d.ts** file| | workScheduler.NetworkType | enum | NETWORK_TYPE_MOBILE | Changed in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.NetworkType | enum | NETWORK_TYPE_WIFI | Changed in API version 9 and migrated to the **ohos.resourceschedule.workScheduler.d.ts** file| | workScheduler.NetworkType | enum | NETWORK_TYPE_WIFI | Changed in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.NetworkType | enum | NETWORK_TYPE_BLUETOOTH | Changed in API version 9 and migrated to the **ohos.resourceschedule.workScheduler.d.ts** file| | workScheduler.NetworkType | enum | NETWORK_TYPE_BLUETOOTH | Changed in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.NetworkType | enum | NETWORK_TYPE_WIFI_P2P | Changed in API version 9 and migrated to the **ohos.resourceschedule.workScheduler.d.ts** file| | workScheduler.NetworkType | enum | NETWORK_TYPE_WIFI_P2P | Changed in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.NetworkType | enum | NETWORK_TYPE_ETHERNET | Changed in API version 9 and migrated to the **ohos.resourceschedule.workScheduler.d.ts** file| | workScheduler.NetworkType | enum | NETWORK_TYPE_ETHERNET | Changed in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.ChargingType | enum | export enum ChargingType | Changed in API version 9 and migrated to the **ohos.resourceschedule.workScheduler.d.ts** file| | workScheduler.ChargingType | enum | export enum ChargingType | Changed in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.ChargingType | enum | CHARGING_PLUGGED_ANY = 0 | Changed in API version 9 and migrated to the **ohos.resourceschedule.workScheduler.d.ts** file| | workScheduler.ChargingType | enum | CHARGING_PLUGGED_ANY = 0 | Changed in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.ChargingType | enum | CHARGING_PLUGGED_AC | Changed in API version 9 and migrated to the **ohos.resourceschedule.workScheduler.d.ts** file| | workScheduler.ChargingType | enum | CHARGING_PLUGGED_AC | Changed in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.ChargingType | enum | CHARGING_PLUGGED_USB | Changed in API version 9 and migrated to the **ohos.resourceschedule.workScheduler.d.ts** file| | workScheduler.ChargingType | enum | CHARGING_PLUGGED_USB | Changed in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.ChargingType | enum | CHARGING_PLUGGED_WIRELESS | Changed in API version 9 and migrated to the **ohos.resourceschedule.workScheduler.d.ts** file| | workScheduler.ChargingType | enum | CHARGING_PLUGGED_WIRELESS | Changed in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.BatteryStatus | enum | export enum BatteryStatus | Changed in API version 9 and migrated to the **ohos.resourceschedule.workScheduler.d.ts** file| | workScheduler.BatteryStatus | enum | export enum BatteryStatus | Changed in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.BatteryStatus | enum | BATTERY_STATUS_LOW = 0 | Changed in API version 9 and migrated to the **ohos.resourceschedule.workScheduler.d.ts** file| | workScheduler.BatteryStatus | enum | BATTERY_STATUS_LOW = 0 | Changed in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.BatteryStatus | enum | BATTERY_STATUS_OKAY | Changed in API version 9 and migrated to the **ohos.resourceschedule.workScheduler.d.ts** file| | workScheduler.BatteryStatus | enum | BATTERY_STATUS_OKAY | Changed in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.BatteryStatus | enum | BATTERY_STATUS_LOW_OR_OKAY | Changed in API version 9 and migrated to the **ohos.resourceschedule.workScheduler.d.ts** file| | workScheduler.BatteryStatus | enum | BATTERY_STATUS_LOW_OR_OKAY | Changed in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.StorageRequest | enum | export enum StorageRequest | Changed in API version 9 and migrated to the **ohos.resourceschedule.workScheduler.d.ts** file| | workScheduler.StorageRequest | enum | export enum StorageRequest | Changed in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.BatteryStatus | enum | STORAGE_LEVEL_LOW = 0 | Changed in API version 9 and migrated to the **ohos.resourceschedule.workScheduler.d.ts** file| | workScheduler.BatteryStatus | enum | STORAGE_LEVEL_LOW = 0 | Changed in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.BatteryStatus | enum | STORAGE_LEVEL_OKAY | Changed in API version 9 and migrated to the **ohos.resourceschedule.workScheduler.d.ts** file| | workScheduler.BatteryStatus | enum | STORAGE_LEVEL_OKAY | Changed in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
| workScheduler.BatteryStatus | enum | STORAGE_LEVEL_LOW_OR_OKAY | Changed in API version 9 and migrated to the **ohos.resourceschedule.workScheduler.d.ts** file| | workScheduler.BatteryStatus | enum | STORAGE_LEVEL_LOW_OR_OKAY | Changed in API version 9 and moved to the **ohos.resourceschedule.workScheduler.d.ts** file.|
**Adaptation Guide**<br> **Adaptation Guide**
Import the **workScheduler** module. Import the **workScheduler** module.
``` ```
...@@ -245,71 +242,70 @@ Exception handling also needs to be adapted. For details, see the [workScheduler ...@@ -245,71 +242,70 @@ Exception handling also needs to be adapted. For details, see the [workScheduler
## c4.resourceschedule.reminderAgent ## c4.resourceschedule.reminderAgent
Rectified original APIs of **reminderAgent** of the resource scheduler subsystem. All APIs in API version 8 and earlier versions are deprecated, and original APIs in API version 9 are deleted. New APIs in API version 9 need to be used. The new APIs in API version 9 comply with the error code specifications. Rectified original APIs of **reminderAgent** of the resource scheduler subsystem. All APIs in API version 8 and earlier versions are deprecated, and original APIs in API version 9 are deleted. New APIs in API version 9 need to be used. The new APIs in API version 9 comply with the error code specifications.
**Change Impacts** **Change Impact**
The application developed based on the SDK versions of OpenHarmony 3.2.8.2 and later needs to adapt the modules and APIs in API version 9 and their methods for returning API error information. Otherwise, the original service logic will be affected. The application developed based on the SDK versions of OpenHarmony 3.2.8.2 and later needs to adapt the modules and APIs in API version 9 and their methods for returning API error information. Otherwise, the original service logic will be affected.
**Key API/Component Changes** **Key API/Component Changes**
The following methods, attributes, enumerations, and constants are changed in API version 9 and later versions. The **@ohos.reminderAgent.d.ts** file is deprecated, the **@ohos.reminderAgentManager.d.ts** file is added, and the class name is changed from **reminderAgent** to **reminderAgentManager**. The following methods, attributes, enums, and constants are changed in API version 9 and later versions. The **@ohos.reminderAgent.d.ts** file is deprecated, the **@ohos.reminderAgentManager.d.ts** file is added, and the class name is changed from **reminderAgent** to **reminderAgentManager**.
| Class | API Type | Method/Attribute/Enumeration/Constant | Change Type | | Class | API Type | Method/Attribute/Enum/Constant | Change Type |
| --------------------- | ----------- | ------------------------------------------------------------ | ------------------------------------------------------------ | | --------------------- | ----------- | ------------------------------------------------------------ | ------------------------------------------------------------ |
| reminderAgent | method | publishReminder(reminderReq: ReminderRequest, callback: AsyncCallback<number>): void; | Deprecated and migrated to **reminderAgentManager**| | reminderAgent | method | publishReminder(reminderReq: ReminderRequest, callback: AsyncCallback<number>): void; | Deprecated and moved to **reminderAgentManager**.|
| reminderAgent | method | publishReminder(reminderReq: ReminderRequest): Promise<number>; | Deprecated and migrated to **reminderAgentManager**| | reminderAgent | method | publishReminder(reminderReq: ReminderRequest): Promise<number>; | Deprecated and moved to **reminderAgentManager**.|
| reminderAgent | method | cancelReminder(reminderId: number, callback: AsyncCallback<void>): void; | Deprecated and migrated to **reminderAgentManager**| | reminderAgent | method | cancelReminder(reminderId: number, callback: AsyncCallback<void>): void; | Deprecated and moved to **reminderAgentManager**.|
| reminderAgent | method | cancelReminder(reminderId: number): Promise<void>; | Deprecated and migrated to **reminderAgentManager**| | reminderAgent | method | cancelReminder(reminderId: number): Promise<void>; | Deprecated and moved to **reminderAgentManager**.|
| reminderAgent | method | getValidReminders(callback: AsyncCallback<Array<ReminderRequest>>): void; | Deprecated and migrated to **reminderAgentManager**| | reminderAgent | method | getValidReminders(callback: AsyncCallback<Array<ReminderRequest>>): void; | Deprecated and moved to **reminderAgentManager**.|
| reminderAgent | method | getValidReminders(): Promise<Array<ReminderRequest>>; | Deprecated and migrated to **reminderAgentManager**| | reminderAgent | method | getValidReminders(): Promise<Array<ReminderRequest>>; | Deprecated and moved to **reminderAgentManager**.|
| reminderAgent | method | cancelAllReminders(callback: AsyncCallback<void>): void; | Deprecated and migrated to **reminderAgentManager**| | reminderAgent | method | cancelAllReminders(callback: AsyncCallback<void>): void; | Deprecated and moved to **reminderAgentManager**.|
| reminderAgent | method | cancelAllReminders(): Promise<void>; | Deprecated and migrated to **reminderAgentManager**| | reminderAgent | method | cancelAllReminders(): Promise<void>; | Deprecated and moved to **reminderAgentManager**.|
| reminderAgent | method | addNotificationSlot(slot: NotificationSlot, callback: AsyncCallback<void>): void; | Deprecated and migrated to **reminderAgentManager**| | reminderAgent | method | addNotificationSlot(slot: NotificationSlot, callback: AsyncCallback<void>): void; | Deprecated and moved to **reminderAgentManager**.|
| reminderAgent | method | addNotificationSlot(slot: NotificationSlot): Promise<void>; | Deprecated and migrated to **reminderAgentManager**| | reminderAgent | method | addNotificationSlot(slot: NotificationSlot): Promise<void>; | Deprecated and moved to **reminderAgentManager**.|
| reminderAgent | method | removeNotificationSlot(slotType: notification.SlotType, callback: AsyncCallback<void>): void; | Deprecated and migrated to **reminderAgentManager**| | reminderAgent | method | removeNotificationSlot(slotType: notification.SlotType, callback: AsyncCallback<void>): void; | Deprecated and moved to **reminderAgentManager**.|
| reminderAgent | method | removeNotificationSlot(slotType: notification.SlotType): Promise<void>; | Deprecated and migrated to **reminderAgentManager**| | reminderAgent | method | removeNotificationSlot(slotType: notification.SlotType): Promise<void>; | Deprecated and moved to **reminderAgentManager**.|
| reminderAgent.ActionButtonType | enum | ACTION_BUTTON_TYPE_CLOSE | Deprecated and migrated to **reminderAgentManager.ActionButtonType**| | reminderAgent.ActionButtonType | enum | ACTION_BUTTON_TYPE_CLOSE | Deprecated and moved to **reminderAgentManager.ActionButtonType**.|
| reminderAgent.ActionButtonType | enum | ACTION_BUTTON_TYPE_SNOOZE | Deprecated and migrated to **reminderAgentManager.ActionButtonType**| | reminderAgent.ActionButtonType | enum | ACTION_BUTTON_TYPE_SNOOZE | Deprecated and moved to **reminderAgentManager.ActionButtonType**.|
| reminderAgent.ReminderType | enum | REMINDER_TYPE_TIMER | Deprecated and migrated to **reminderAgentManager.ReminderType**| | reminderAgent.ReminderType | enum | REMINDER_TYPE_TIMER | Deprecated and moved to **reminderAgentManager.ReminderType**.|
| reminderAgent.ReminderType | enum | REMINDER_TYPE_CALENDAR | Deprecated and migrated to **reminderAgentManager.ReminderType**| | reminderAgent.ReminderType | enum | REMINDER_TYPE_CALENDAR | Deprecated and moved to **reminderAgentManager.ReminderType**.|
| reminderAgent.ReminderType | enum | REMINDER_TYPE_CALENDAR | Deprecated and migrated to **reminderAgentManager.ReminderType**| | reminderAgent.ReminderType | enum | REMINDER_TYPE_CALENDAR | Deprecated and moved to **reminderAgentManager.ReminderType**.|
| reminderAgent.ActionButton | field | title:string | Deprecated and migrated to **reminderAgentManager.ActionButton**| | reminderAgent.ActionButton | field | title:string | Deprecated and moved to **reminderAgentManager.ActionButton**.|
| reminderAgent.ActionButton | field | type:ActionButtonType | Deprecated and migrated to **reminderAgentManager.ActionButton**| | reminderAgent.ActionButton | field | type:ActionButtonType | Deprecated and moved to **reminderAgentManager.ActionButton**.|
| reminderAgent.WantAgent | field | pkgName:string | Deprecated and migrated to **reminderAgentManager.WantAgent**| | reminderAgent.WantAgent | field | pkgName:string | Deprecated and moved to **reminderAgentManager.WantAgent**.|
| reminderAgent.WantAgent | field | abilityName:string | Deprecated and migrated to **reminderAgentManager.WantAgent**| | reminderAgent.WantAgent | field | abilityName:string | Deprecated and moved to **reminderAgentManager.WantAgent**.|
| reminderAgent.MaxScreenWantAgent | field | pkgName:string | Deprecated and migrated to **reminderAgentManager.MaxScreenWantAgent**| | reminderAgent.MaxScreenWantAgent | field | pkgName:string | Deprecated and moved to **reminderAgentManager.MaxScreenWantAgent**.|
| reminderAgent.MaxScreenWantAgent | field | abilityName:string | Deprecated and migrated to **reminderAgentManager.MaxScreenWantAgent**| | reminderAgent.MaxScreenWantAgent | field | abilityName:string | Deprecated and moved to **reminderAgentManager.MaxScreenWantAgent**.|
| reminderAgent.ReminderRequest | field | reminderType:ReminderType | Deprecated and migrated to **reminderAgentManager.ReminderRequest**| | reminderAgent.ReminderRequest | field | reminderType:ReminderType | Deprecated and moved to **reminderAgentManager.ReminderRequest**.|
| reminderAgent.ReminderRequest | field | actionButton?:ActionButton | Deprecated and migrated to **reminderAgentManager.ReminderRequest**| | reminderAgent.ReminderRequest | field | actionButton?:ActionButton | Deprecated and moved to **reminderAgentManager.ReminderRequest**.|
| reminderAgent.ReminderRequest | field | wantAgent?:WantAgent | Deprecated and migrated to **reminderAgentManager.ReminderRequest**| | reminderAgent.ReminderRequest | field | wantAgent?:WantAgent | Deprecated and moved to **reminderAgentManager.ReminderRequest**.|
| reminderAgent.ReminderRequest | field | maxScreenWantAgent?:MaxScreenWantAgent | Deprecated and migrated to **reminderAgentManager.ReminderRequest**| | reminderAgent.ReminderRequest | field | maxScreenWantAgent?:MaxScreenWantAgent | Deprecated and moved to **reminderAgentManager.ReminderRequest**.|
| reminderAgent.ReminderRequest | field | ringDuration?:number | Deprecated and migrated to **reminderAgentManager.ReminderRequest**| | reminderAgent.ReminderRequest | field | ringDuration?:number | Deprecated and moved to **reminderAgentManager.ReminderRequest**.|
| reminderAgent.ReminderRequest | field | snoozeTimes?:number | Deprecated and migrated to **reminderAgentManager.ReminderRequest**| | reminderAgent.ReminderRequest | field | snoozeTimes?:number | Deprecated and moved to **reminderAgentManager.ReminderRequest**.|
| reminderAgent.ReminderRequest | field | timeInterval?:number | Deprecated and migrated to **reminderAgentManager.ReminderRequest**| | reminderAgent.ReminderRequest | field | timeInterval?:number | Deprecated and moved to **reminderAgentManager.ReminderRequest**.|
| reminderAgent.ReminderRequest | field | title?:string | Deprecated and migrated to **reminderAgentManager.ReminderRequest**| | reminderAgent.ReminderRequest | field | title?:string | Deprecated and moved to **reminderAgentManager.ReminderRequest**.|
| reminderAgent.ReminderRequest | field | content?:string | Deprecated and migrated to **reminderAgentManager.ReminderRequest**| | reminderAgent.ReminderRequest | field | content?:string | Deprecated and moved to **reminderAgentManager.ReminderRequest**.|
| reminderAgent.ReminderRequest | field | expiredContent?:string | Deprecated and migrated to **reminderAgentManager.ReminderRequest**| | reminderAgent.ReminderRequest | field | expiredContent?:string | Deprecated and moved to **reminderAgentManager.ReminderRequest**.|
| reminderAgent.ReminderRequest | field | snoozeContent?:string | Deprecated and migrated to **reminderAgentManager.ReminderRequest**| | reminderAgent.ReminderRequest | field | snoozeContent?:string | Deprecated and moved to **reminderAgentManager.ReminderRequest**.|
| reminderAgent.ReminderRequest | field | notificationId?:number | Deprecated and migrated to **reminderAgentManager.ReminderRequest**| | reminderAgent.ReminderRequest | field | notificationId?:number | Deprecated and moved to **reminderAgentManager.ReminderRequest**.|
| reminderAgent.ReminderRequest | field | slotType?: notification.SlotType | Deprecated and migrated to **reminderAgentManager.ReminderRequest**| | reminderAgent.ReminderRequest | field | slotType?: notification.SlotType | Deprecated and moved to **reminderAgentManager.ReminderRequest**.|
| reminderAgent.ReminderRequestCalendar | field | dateTime:LocalDateTime | Deprecated and migrated to **reminderAgentManager.ReminderRequestCalendar**| | reminderAgent.ReminderRequestCalendar | field | dateTime:LocalDateTime | Deprecated and moved to **reminderAgentManager.ReminderRequestCalendar**.|
| reminderAgent.ReminderRequestCalendar | field | repeatMonths?:Array<number> | Deprecated and migrated to **reminderAgentManager.ReminderRequestCalendar**| | reminderAgent.ReminderRequestCalendar | field | repeatMonths?:Array<number> | Deprecated and moved to **reminderAgentManager.ReminderRequestCalendar**.|
| reminderAgent.ReminderRequestCalendar | field | repeatDays?:Array<number> | Deprecated and migrated to **reminderAgentManager.ReminderRequestCalendar**| | reminderAgent.ReminderRequestCalendar | field | repeatDays?:Array<number> | Deprecated and moved to **reminderAgentManager.ReminderRequestCalendar**.|
| reminderAgent.ReminderRequestAlarm | field | hour:number | Deprecated and migrated to **reminderAgentManager.ReminderRequestAlarm**| | reminderAgent.ReminderRequestAlarm | field | hour:number | Deprecated and moved to **reminderAgentManager.ReminderRequestAlarm**.|
| reminderAgent.ReminderRequestAlarm | field | minute:number | Deprecated and migrated to **reminderAgentManager.ReminderRequestAlarm**| | reminderAgent.ReminderRequestAlarm | field | minute:number | Deprecated and moved to **reminderAgentManager.ReminderRequestAlarm**.|
| reminderAgent.ReminderRequestAlarm | field | daysOfWeek?:Array<number> | Deprecated and migrated to **reminderAgentManager.ReminderRequestAlarm**| | reminderAgent.ReminderRequestAlarm | field | daysOfWeek?:Array<number> | Deprecated and moved to **reminderAgentManager.ReminderRequestAlarm**.|
| reminderAgent.ReminderRequestTimer | field | triggerTimeInSeconds:number | Deprecated and migrated to **reminderAgentManager.ReminderRequestTimer**| | reminderAgent.ReminderRequestTimer | field | triggerTimeInSeconds:number | Deprecated and moved to **reminderAgentManager.ReminderRequestTimer**.|
| reminderAgent.LocalDateTime | field | year:number | Deprecated and migrated to **reminderAgentManager.LocalDateTime**| | reminderAgent.LocalDateTime | field | year:number | Deprecated and moved to **reminderAgentManager.LocalDateTime**.|
| reminderAgent.LocalDateTime | field | month:number | Deprecated and migrated to **reminderAgentManager.LocalDateTime**| | reminderAgent.LocalDateTime | field | month:number | Deprecated and moved to **reminderAgentManager.LocalDateTime**.|
| reminderAgent.LocalDateTime | field | day:number | Deprecated and migrated to **reminderAgentManager.LocalDateTime**| | reminderAgent.LocalDateTime | field | day:number | Deprecated and moved to **reminderAgentManager.LocalDateTime**.|
| reminderAgent.LocalDateTime | field | hour:number | Deprecated and migrated to **reminderAgentManager.LocalDateTime**| | reminderAgent.LocalDateTime | field | hour:number | Deprecated and moved to **reminderAgentManager.LocalDateTime**.|
| reminderAgent.LocalDateTime | field | minute:number | Deprecated and migrated to **reminderAgentManager.LocalDateTime**| | reminderAgent.LocalDateTime | field | minute:number | Deprecated and moved to **reminderAgentManager.LocalDateTime**.|
| reminderAgent.LocalDateTime | field | second?:number | Deprecated and migrated to **reminderAgentManager.LocalDateTime**| | reminderAgent.LocalDateTime | field | second?:number | Deprecated and moved to **reminderAgentManager.LocalDateTime**.|
**Adaptation Guide**<br> **Adaptation Guide**
Import the **reminderAgentManager** module. Import the **reminderAgentManager** module.
``` ```
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
## cl.testfwk_arkxtest.1 Exception Handling Support of On, Driver, and Component APIs ## cl.testfwk_arkxtest.1 Exception Handling Support of On, Driver, and Component APIs
The original APIs in API version 8 are deprecated, and substitute APIs that support exception handling are introduced in API version 9. You must use **try catch** to capture exceptions thrown by the APIs. Deprecated the original APIs in API version 8, and introduced substitute APIs that support exception handling in API version 9. You must use **try catch** to capture exceptions thrown by the APIs.
## Change Impacts ## Change Impacts
...@@ -17,25 +17,25 @@ This change affects the JS APIs in API version 9 provided by **@ohos.uitest**. I ...@@ -17,25 +17,25 @@ This change affects the JS APIs in API version 9 provided by **@ohos.uitest**. I
## Adaptation Guide ## Adaptation Guide
1. Adapt to the API name changes. ### 1. Adapt to the API name changes.
You can replace the class name according to the following rules: You can replace the class name according to the following rules:
- `By-->On` - `By-->On`
- `BY-->ON` - `BY-->ON`
- `UiDriver-->Driver` - `UiDriver-->Driver`
- `UiComponent-->Component` - `UiComponent-->Component`
2. Catch and handle exceptions. ### 2. Catch and handle exceptions.
Use **try-catch** to catch and handle exceptions thrown by the APIs. Below is the sample code: Use **try-catch** to catch and handle exceptions thrown by the APIs. Below is the sample code:
```typescript ```typescript
import {Driver,ON,Component} from '@ohos.uitest' import {Driver,ON,Component} from '@ohos.uitest'
try { try {
let driver = Driver.create(); let driver = Driver.create();
} catch (error) { } catch (error) {
// error handle; error.code indicates the error code. // error handle; error.code indicates the error code.
} }
``` ```
\ No newline at end of file
# User IAM Subsystem ChangeLog # User IAM Subsystem Changelog
## cl.useriam.1 API Exception Handling Method Change ## cl.useriam.1 API Exception Handling Change in APIs
Certain APIs of user IAM use service logic return values to indicate error information, which does not comply with the API error code specifications of OpenHarmony. The following changes are made in API version 9 and later: Certain user IAM APIs use service logic return values to indicate error information, which does not comply with the API error code specifications of OpenHarmony. The following changes are made in API version 9:
An error message is returned via an exception. An error message is returned by throwing an exception.
**Change Impacts** **Change Impact**
Applications developed based on earlier versions are not affected. If your application uses API version 9 or later, you need to adapt the change in the way for APIs to return the error information. Otherwise, service logic will be affected. Applications developed based on earlier versions are not affected. If your application uses API version 9 or later, you need to adapt the change in the way for APIs to return error information. Otherwise, service logic will be affected.
**Key API/Component Changes** **Key API/Component Changes**
For adaptation to the unified API exception handling mode, certain APIs of user IAM are deprecated (original APIs in the following table) and corresponding new APIs in the following table are added. The newly added APIs support unified error code handling specifications and function the same as the original APIs. For easy use, related user IAM APIs are deprecated, and new APIs are added to implement unified error code handling. The functionalities of these APIs remain unchanged.
| Module | Class | Method/Attribute/Enumeration/Constant | Change Type | | Module | Class | Method/Attribute/Enum/Constant | Change Type |
| ---------------------- | ------------------- | ------------------------- | ------------------------ | | ---------------------- | ------------------- | ------------------------- | ------------------------ |
| ohos.userIAM.userAuth | UserAuth | constructor() | Deprecated| | ohos.userIAM.userAuth | UserAuth | constructor() | Deprecated|
| ohos.userIAM.userAuth | UserAuth | getVersion() : number | Deprecated| | ohos.userIAM.userAuth | UserAuth | getVersion() : number | Deprecated|
...@@ -24,18 +24,18 @@ For adaptation to the unified API exception handling mode, certain APIs of user ...@@ -24,18 +24,18 @@ For adaptation to the unified API exception handling mode, certain APIs of user
| ohos.userIAM.userAuth | IUserAuthCallback | onResult: (result : number, extraInfo : AuthResult) => void | Deprecated| | ohos.userIAM.userAuth | IUserAuthCallback | onResult: (result : number, extraInfo : AuthResult) => void | Deprecated|
| ohos.userIAM.userAuth | IUserAuthCallback | onAcquireInfo ?: (module : number, acquire : number, extraInfo : any) => void | Deprecated| | ohos.userIAM.userAuth | IUserAuthCallback | onAcquireInfo ?: (module : number, acquire : number, extraInfo : any) => void | Deprecated|
| ohos.userIAM.userAuth | AuthResult | AuthResult {<br>token ?: Uint8Array; <br>remainTimes ?: number; <br>freezingTime ?: number;} | Deprecated| | ohos.userIAM.userAuth | AuthResult | AuthResult {<br>token ?: Uint8Array; <br>remainTimes ?: number; <br>freezingTime ?: number;} | Deprecated|
| ohos.userIAM.userAuth | Enumeration| ResultCode {<br>SUCCESS = 0, <br>FAIL = 1, <br>GENERAL_ERROR = 2, <br>CANCELED = 3, <br>TIMEOUT = 4, <br>TYPE_NOT_SUPPORT = 5, <br>TRUST_LEVEL_NOT_SUPPORT = 6, <br>BUSY = 7, <br>INVALID_PARAMETERS = 8, <br>LOCKED = 9, <br>NOT_ENROLLED = 10,} | Deprecated| | ohos.userIAM.userAuth | Enum| ResultCode {<br>SUCCESS = 0, <br>FAIL = 1, <br>GENERAL_ERROR = 2, <br>CANCELED = 3, <br>TIMEOUT = 4, <br>TYPE_NOT_SUPPORT = 5, <br>TRUST_LEVEL_NOT_SUPPORT = 6, <br>BUSY = 7, <br>INVALID_PARAMETERS = 8, <br>LOCKED = 9, <br>NOT_ENROLLED = 10,} | Deprecated|
| ohos.userIAM.userAuth | type | AuthEventKey = "result" | Added| | ohos.userIAM.userAuth | type | AuthEventKey = "result" | Added|
| ohos.userIAM.userAuth | type | EventInfo = AuthResultInfo | Added| | ohos.userIAM.userAuth | type | EventInfo = AuthResultInfo | Added|
| ohos.userIAM.userAuth | AuthResultInfo | AuthResultInfo {<br>result : number; <br>token ?: Uint8Array; <br>remainAttempts ?: number; <br>lockoutDuration ?: number;} | Added| | ohos.userIAM.userAuth | AuthResultInfo | AuthResultInfo {<br>result : number; <br>token ?: Uint8Array; <br>remainAttempts ?: number; <br>lockoutDuration ?: number;} | Added|
| ohos.userIAM.userAuth | TipInfo | TipInfo {<br>module : number; <br>tip : number;} | Added| | ohos.userIAM.userAuth | TipInfo | TipInfo {<br>module : number; <br>tip : number;} | Added|
| ohos.userIAM.userAuth | AuthInstance | AuthInstance {<br>on: (name: AuthEventKey, callback: AuthEvent) => void; <br>off: (name: AuthEventKey) => void; <br>start: () => void; <br>cancel: () => void;} | Added| | ohos.userIAM.userAuth | AuthInstance | AuthInstance {<br>on: (name: AuthEventKey, callback: AuthEvent) => void; <br>off: (name: AuthEventKey) => void; <br>start: () => void; <br>cancel: () => void;} | Added|
| ohos.userIAM.userAuth | Enumeration| ResultCodeV9 {<br>SUCCESS = 12500000, <br>FAIL = 12500001, <br>GENERAL_ERROR = 12500002, <br>CANCELED = 12500003, <br>TIMEOUT = 12500004, <br>TYPE_NOT_SUPPORT = 12500005, <br>TRUST_LEVEL_NOT_SUPPORT = 12500006, <br>BUSY = 12500007, <br>LOCKED = 12500009, <br>NOT_ENROLLED = 12500010,} | Added| | ohos.userIAM.userAuth | Enum| ResultCodeV9 {<br>SUCCESS = 12500000, <br>FAIL = 12500001, <br>GENERAL_ERROR = 12500002, <br>CANCELED = 12500003, <br>TIMEOUT = 12500004, <br>TYPE_NOT_SUPPORT = 12500005, <br>TRUST_LEVEL_NOT_SUPPORT = 12500006, <br>BUSY = 12500007, <br>LOCKED = 12500009, <br>NOT_ENROLLED = 12500010,} | Added|
| ohos.userIAM.userAuth | function | getAuthInstance(challenge : Uint8Array, authType : UserAuthType, authTrustLevel : AuthTrustLevel) : AuthInstance | Added| | ohos.userIAM.userAuth | function | getAuthInstance(challenge : Uint8Array, authType : UserAuthType, authTrustLevel : AuthTrustLevel) : AuthInstance | Added|
| ohos.userIAM.userAuth | function | getVersion() : number | Added| | ohos.userIAM.userAuth | function | getVersion() : number | Added|
| ohos.userIAM.userAuth | function | getAvailableStatus(authType : UserAuthType, authTrustLevel : AuthTrustLevel) : void | Added| | ohos.userIAM.userAuth | function | getAvailableStatus(authType : UserAuthType, authTrustLevel : AuthTrustLevel) : void | Added|
| ohos.userIAM.faceAuth | FaceAuthManager | setSurfaceId(surfaceId : string) : ResultCode | Deleted| | ohos.userIAM.faceAuth | FaceAuthManager | setSurfaceId(surfaceId : string) : ResultCode | Deleted|
| ohos.userIAM.faceAuth | Enumeration| ResultCode {<br>SUCCESS = 0, <br>FAIL = 1,} | Deleted| | ohos.userIAM.faceAuth | Enum| ResultCode {<br>SUCCESS = 0, <br>FAIL = 1,} | Deleted|
| ohos.userIAM.faceAuth | FaceAuthManager | setSurfaceId(surfaceId: string) : void | Added| | ohos.userIAM.faceAuth | FaceAuthManager | setSurfaceId(surfaceId: string) : void | Added|
**Adaptation Guide** **Adaptation Guide**
...@@ -53,22 +53,22 @@ try { ...@@ -53,22 +53,22 @@ try {
} }
``` ```
For sample code of more APIs, see the [user authentication API reference](../../../application-dev/reference/apis/js-apis-useriam-userauth.md) and [face authentication API reference](../../../application-dev/reference/apis/js-apis-useriam-faceauth.md). For more information about the APIs, see [User Authentication](../../../application-dev/reference/apis/js-apis-useriam-userauth.md) and [Facial Authentication](../../../application-dev/reference/apis/js-apis-useriam-faceauth.md).
## cl.useriam.2 API Call Permission Change ## cl.useriam.2 API Invoking Permission Change
Some APIs of user IAM can only be called by system applications, and system application runtime authentication is required. The following changes are made in API version 9 and later: Some user IAM APIs can only be called by system applications, and system application runtime authentication is required. The following changes are made in API version 9:
The service logic for checking whether an application is a system application is added for the **setSurfaceId** API of the face authentication module. Non-system applications cannot call this API. Added the service logic for checking whether an application is a system application to the **setSurfaceId** API of the facial authentication module. Non-system applications cannot call this API.
**Change Impacts** **Change Impact**
Applications developed based on earlier versions are not affected. If your application uses API version 9 or later and wants to call this API, your application must be a system application. Applications developed based on earlier versions are not affected.
**Key API/Component Changes** **Key API/Component Changes**
The service logic for checking whether an application is a system application is added for the **setSurfaceId** API. Error code **202** will be returned if the API is called by a non-system application. The service logic for checking whether an application is a system application is added to **setSurfaceId()** . Error code **202** will be returned if the API is called by a non-system application.
**Adaptation Guide** **Adaptation Guide**
Modify the **UnsgnedReleasedProfileTemplate.json** file related to [app signing](https://gitee.com/openharmony/developtools_hapsigner/tree/master/dist) to change the **app-feature** field to **hos_system_app**, so that the signed application is a system application. Change the **app-feature** field to **hos_system_app** in the **UnsgnedReleasedProfileTemplate.json** file in [developtools_hapsigner](https://gitee.com/openharmony/developtools_hapsigner/tree/master/dist). Then, the signed application is a system application.
# ChangeLog of JS API Changes in the WantAgent # WantAgent JS API Changelog
This document describes the WantAgent API changes in OpenHarmony 3.2.9.1 SP8 when compared with OpenHarmony 3.2.8.1.
## cl.url.1 Trigger API Changes ## cl.url.1 Trigger API Changes
trigger(agent: WantAgent, triggerInfo: TriggerInfo, callback?: Callback<CompleteData>): void ; trigger(agent: WantAgent, triggerInfo: TriggerInfo, callback?: Callback<CompleteData>): void ;
...@@ -9,7 +7,7 @@ This API has been deleted, because some functions have not been implemented. You ...@@ -9,7 +7,7 @@ This API has been deleted, because some functions have not been implemented. You
trigger(agent: WantAgent, triggerInfo: TriggerInfo, callback?: AsyncCallback<CompleteData>): void trigger(agent: WantAgent, triggerInfo: TriggerInfo, callback?: AsyncCallback<CompleteData>): void
**Change Impacts** **Change Impact**
Released JS APIs are affected. The application needs to adapt these APIs so that it can be properly compiled in the SDK environment of the new version. Released JS APIs are affected. The application needs to adapt these APIs so that it can be properly compiled in the SDK environment of the new version.
...@@ -71,7 +69,7 @@ function getWantAgentCallback(err, data) { ...@@ -71,7 +69,7 @@ function getWantAgentCallback(err, data) {
// getUid callback // getUid callback
function triggerCallback(err, data) { function triggerCallback(err, data) {
if(err) { if(err) {
console.info('getUid failed!' + err.code + err.message); console.info('getUid failed!' + JSON.stringify(err.code) + JSON.stringify(err.message));
} else { } else {
console.info('getUid ok!' + JSON.stringify(data)); console.info('getUid ok!' + JSON.stringify(data));
} }
...@@ -79,12 +77,12 @@ function getWantAgentCallback(err, data) { ...@@ -79,12 +77,12 @@ function getWantAgentCallback(err, data) {
try { try {
WantAgent.trigger(wantAgent, triggerInfo, triggerCallback); WantAgent.trigger(wantAgent, triggerInfo, triggerCallback);
} catch(err) { } catch(err) {
console.info('getUid failed!' + err.code + err.message); console.info('getUid failed!' + JSON.stringify(err.code) + JSON.stringify(err.message));
} }
} }
try{ try{
WantAgent.getWantAgent(wantAgentInfo, getWantAgentCallback); WantAgent.getWantAgent(wantAgentInfo, getWantAgentCallback);
} catch(err){ } catch(err){
console.info('getWantAgent failed!' + err.code + err.message); console.info('getWantAgent failed!' + JSON.stringify(err.code) + JSON.stringify(err.message));
} }
``` ```
# Web Subsystem ChangeLog # Web Subsystem ChangeLog
This document describes the web API changes in OpenHarmony 3.2.9.1 SP8 when compared with OpenHarmony 3.2.8.1.
## cl.web.1 Deletion of Unnecessary Error Codes ## cl.web.1 Deletion of Unnecessary Error Codes
APIs in the webviewController component of the web subsystem are changed: APIs in the webviewController component of the web subsystem are changed:
......
# Wi-Fi Subsystem Changelog
## cl.wifi.1 Change of System APIs and APIs of Version 9
Moved all system APIs and APIs of version 9 from **@ohos.wifi.d.ts** to the newly added **@ohos.wifiManager.d.ts**, and added error code description. The **@ohos.wifi.d.ts** APIs do not support error code handling.
To use these APIs, import the **@ohos.wifiManager.d.ts** module as follows:
import wifiManager from '@ohos.wifiManager';
**Change Impact**
System APIs and APIs of version 9 are affected. To use these APIs, import **@ohos.wifiManager** as follows:
import wifiManager from '@ohos.wifiManager';
Other APIs are not affected.
**Key API/Component Changes**
| Class| API Type| Declaration| Change Type|
| -- | -- | -- | -- |
| wifi | namespace | declare namespace wifi | Moved to **@ohos.wifiManager.d.ts**|
| wifi | method | function enableWifi(): void | Moved to **@ohos.wifiManager.d.ts**, with the return value changed to **void**|
| wifi | method | function disableWifi(): void | Moved to **@ohos.wifiManager.d.ts**, with the return value changed to **void**|
| wifi | method | function scan(): void | Moved to **@ohos.wifiManager.d.ts**, with the return value changed to **void**|
| wifi | method | function getScanResults(): Promise&lt;Array&lt;WifiScanInfo&gt;&gt; | Changed from **getScanInfos** to **getScanResults** and moved to **@ohos.wifiManager.d.ts**|
| wifi | method | function getScanResults(callback: AsyncCallback&lt;Array&lt;WifiScanInfo&gt;&gt;): void | Changed from **getScanInfos** to **getScanResults** and moved to **@ohos.wifiManager.d.ts**|
| wifi | method | function getScanResultsSync(): &nbsp;Array&lt;[WifiScanInfo]&gt; | Moved to **@ohos.wifiManager.d.ts**|
| wifi | method | function addCandidateConfig(config: WifiDeviceConfig): Promise&lt;number&gt; | Moved to **@ohos.wifiManager.d.ts**|
| wifi | method | function addCandidateConfig(config: WifiDeviceConfig, callback: AsyncCallback&lt;number&gt;): void | Moved to **@ohos.wifiManager.d.ts**|
| wifi | method | function removeCandidateConfig(networkId: number): Promise&lt;void&gt; | Moved to **@ohos.wifiManager.d.ts**|
| wifi | method | function removeCandidateConfig(networkId: number, callback: AsyncCallback&lt;void&gt;): void | Moved to **@ohos.wifiManager.d.ts**|
| wifi | method | function addUntrustedConfig(config: WifiDeviceConfig): Promise&lt;boolean&gt; | Deleted|
| wifi | method | function addUntrustedConfig(config: WifiDeviceConfig, callback: AsyncCallback&lt;boolean&gt;): void | Deleted|
| wifi | method | function removeUntrustedConfig(config: WifiDeviceConfig): Promise&lt;boolean&gt; | Deleted|
| wifi | method | function removeUntrustedConfig(config: WifiDeviceConfig, callback: AsyncCallback&lt;boolean&gt;): void | Deleted|
| wifi | method | function getCandidateConfigs(): &nbsp;Array&lt;[WifiDeviceConfig]&gt; | Moved to **@ohos.wifiManager.d.ts**|
| wifi | method | function connectToCandidateConfig(networkId: number): void | Moved to **@ohos.wifiManager.d.ts**|
| wifi | method | function connectToNetwork(networkId: number): void | Moved to **@ohos.wifiManager.d.ts**, with the return value changed to **void**|
| wifi | method | function connectToDevice(config: WifiDeviceConfig): void | Moved to **@ohos.wifiManager.d.ts**, with the return value changed to **void**|
| wifi | method | function disconnect(): void | Moved to **@ohos.wifiManager.d.ts**, with the return value changed to **void**|
| wifi | method | function reassociate(): void | Moved to **@ohos.wifiManager.d.ts**, with the return value changed to **void**|
| wifi | method | function reconnect(): void | Moved to **@ohos.wifiManager.d.ts**, with the return value changed to **void**|
| wifi | method | function disableNetwork(netId: number): void | Moved to **@ohos.wifiManager.d.ts**, with the return value changed to **void**|
| wifi | method | function removeAllNetwork(): void | Moved to **@ohos.wifiManager.d.ts**, with the return value changed to **void**|
| wifi | method | function removeDevice(id: number): void | Moved to **@ohos.wifiManager.d.ts**, with the return value changed to **void**|
| wifi | method | function enableHotspot(): void | Moved to **@ohos.wifiManager.d.ts**, with the return value changed to **void**|
| wifi | method | function disableHotspot(): void | Moved to **@ohos.wifiManager.d.ts**, with the return value changed to **void**|
| wifi | method | function setHotspotConfig(config: HotspotConfig): void | Moved to **@ohos.wifiManager.d.ts**, with the return value changed to **void**|
| wifi | method | function getP2pLocalDevice(): Promise&lt;WifiP2pDevice&gt; | Moved to **@ohos.wifiManager.d.ts**|
| wifi | method | function getP2pLocalDevice(callback: AsyncCallback&lt;WifiP2pDevice&gt;): void | Moved to **@ohos.wifiManager.d.ts**|
| wifi | method | function getP2pGroups(): Promise&lt;Array&lt;WifiP2pGroupInfo&gt;&gt; | Moved to **@ohos.wifiManager.d.ts**|
| wifi | method | function getP2pGroups(callback: AsyncCallback&lt;Array&lt;WifiP2pGroupInfo&gt;&gt;): void | Moved to **@ohos.wifiManager.d.ts**|
| wifi | method | function createGroup(config: WifiP2PConfig): void | Moved to **@ohos.wifiManager.d.ts**, with the return value changed to **void**|
| wifi | method | function removeGroup(): void | Moved to **@ohos.wifiManager.d.ts**, with the return value changed to **void**|
| wifi | method | function p2pConnect(config: WifiP2PConfig): void | Moved to **@ohos.wifiManager.d.ts**, with the return value changed to **void**|
| wifi | method | function p2pCancelConnect(): void | Moved to **@ohos.wifiManager.d.ts**, with the return value changed to **void**|
| wifi | method | function startDiscoverDevices(): void | Moved to **@ohos.wifiManager.d.ts**, with the return value changed to **void**|
| wifi | method | function stopDiscoverDevices(): void | Moved to **@ohos.wifiManager.d.ts**, with the return value changed to **void**|
| wifi | method | function deletePersistentGroup(netId: number): void | Moved to **@ohos.wifiManager.d.ts**, with the return value changed to **void**|
| wifi | method | function setDeviceName(devName: string): void | Moved to **@ohos.wifiManager.d.ts**, with the return value changed to **void**|
| wifi | interface | export interface WifiEapConfig | Moved to **@ohos.wifiManager.d.ts**|
| wifi | enum | export enum EapMethod | Moved to **@ohos.wifiManager.d.ts**|
| wifi | enum | export enum Phase2Method | Moved to **@ohos.wifiManager.d.ts**|
| wifi | interface | export interface WifiDeviceConfig | Added with the **eapConfig** parameter and moved to **@ohos.wifiManager.d.ts**|
| wifi | interface | export interface IpConfig | Added with the **prefixLength** parameter and moved to **@ohos.wifiManager.d.ts**|
| wifi | interface | export interface WifiInfoElem | Moved to **@ohos.wifiManager.d.ts**|
| wifi | enum | export enum WifiChannelWidth | Moved to **@ohos.wifiManager.d.ts**|
| wifi | interface | export interface WifiScanInfo | Added with the **centerFrequency0**, **centerFrequency1**, and **infoElems** parameters and moved to **@ohos.wifiManager.d.ts**|
| wifi | enum | export enum WifiSecurityType | Added with four encryption types and moved to **@ohos.wifiManager.d.ts**|
| wifi | interface | export interface WifiLinkedInfo | Added with the **MacType** parameter and moved to **@ohos.wifiManager.d.ts**|
**Adaptation Guide**
The following uses **getLinkedInfo** as an example:
```
import wifiManager from '@ohos.wifiManager'
wifiManager.getLinkedInfo((err, data) => {
if (err) {
console.error("get linked info error");
return;
}
console.info("get linked info: " + JSON.stringify(data));
});
wifiManager.getLinkedInfo().then(data => {
console.info("get linked info: " + JSON.stringify(data));
}).catch(error => {
console.info("get linked info error");
});
```
## cl.wifiext.1 Change of System APIs and APIs of Version 9
Moved all system APIs and APIs of version 9 from **@ohos.wifiext.d.ts** to the newly added **@ohos.wifiManagerExt.d.ts**, and added error code description.
To use these APIs, import the **@ohos.wifiManagerExt.d.ts** module as follows:
import wifiManagerExt from '@ohos.wifiManagerExt';
**Change Impact**
System APIs and APIs of version 9 are affected. Import **@ohos.wifiManagerExt** and use it together with **wifiManager**.
import wifiManagerExt from '@ohos.wifiManagerExt';
Other APIs are not affected.
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册