From 0d11cf834c5a9a624d89e1fffa3d9913d264857a Mon Sep 17 00:00:00 2001 From: Gloria Date: Thu, 18 May 2023 15:46:57 +0800 Subject: [PATCH] Update docs against 17485+17436+17339+17816+17836 Signed-off-by: wusongqing --- .../reference/apis/Readme-EN.md | 6 +-- .../reference/apis/js-apis-audio.md | 4 +- .../js-apis-bundleManager-AppProvisionInfo.md | 36 ++++++++++++++ .../reference/apis/js-apis-bundleManager.md | 47 +++++-------------- .../reference/apis/js-apis-uiappearance.md | 2 +- 5 files changed, 54 insertions(+), 41 deletions(-) create mode 100644 en/application-dev/reference/apis/js-apis-bundleManager-AppProvisionInfo.md diff --git a/en/application-dev/reference/apis/Readme-EN.md b/en/application-dev/reference/apis/Readme-EN.md index d4984c913c..08f33bdb2b 100644 --- a/en/application-dev/reference/apis/Readme-EN.md +++ b/en/application-dev/reference/apis/Readme-EN.md @@ -152,6 +152,7 @@ - bundleManager - [abilityInfo](js-apis-bundleManager-abilityInfo.md) - [applicationInfo](js-apis-bundleManager-applicationInfo.md) + - [AppProvisionInfo](js-apis-bundleManager-AppProvisionInfo.md) - [bundleInfo](js-apis-bundleManager-bundleInfo.md) - [BundlePackInfo](js-apis-bundleManager-BundlePackInfo.md) - [dispatchInfo](js-apis-bundleManager-dispatchInfo.md) @@ -166,6 +167,7 @@ - UI Page - [@ohos.animator (Animator)](js-apis-animator.md) + - [@ohos.arkui.drawableDescriptor (DrawableDescriptor)](js-apis-arkui-drawableDescriptor.md) - [@ohos.curves (Interpolation Calculation)](js-apis-curve.md) - [@ohos.matrix4 (Matrix Transformation)](js-apis-matrix4.md) - [@ohos.mediaquery (Media Query)](js-apis-mediaquery.md) @@ -312,8 +314,6 @@ - [Timer](js-apis-timer.md) - application - [AccessibilityExtensionContext (Accessibility Extension Context)](js-apis-inner-application-accessibilityExtensionContext.md) - - imf - - [InputMethodCommon](js-apis-inputmethod-InputMethodCommon.md) - Device Management - [@ohos.batteryInfo (Battery Information)](js-apis-battery-info.md) @@ -354,8 +354,8 @@ - Customization - [@ohos.configPolicy (Configuration Policy)](js-apis-configPolicy.md) - [@ohos.enterprise.accountManager (Account Management)](js-apis-enterprise-accountManager.md) - - [@ohos.enterprise.bundleManager (Bundle Management)](js-apis-enterprise-bundleManager.md) - [@ohos.enterprise.adminManager (Enterprise Device Management)](js-apis-enterprise-adminManager.md) + - [@ohos.enterprise.bundleManager (Bundle Management)](js-apis-enterprise-bundleManager.md) - [@ohos.enterprise.dateTimeManager (System Time Management)](js-apis-enterprise-dateTimeManager.md) - [@ohos.enterprise.deviceControl (Device Control Management)](js-apis-enterprise-deviceControl.md) - [@ohos.enterprise.deviceInfo (Device Information Management)](js-apis-enterprise-deviceInfo.md) diff --git a/en/application-dev/reference/apis/js-apis-audio.md b/en/application-dev/reference/apis/js-apis-audio.md index 1b41dfffac..83c2d59e85 100644 --- a/en/application-dev/reference/apis/js-apis-audio.md +++ b/en/application-dev/reference/apis/js-apis-audio.md @@ -486,8 +486,8 @@ Enumerates the audio channels. | Name | Value | Description | | --------- | -------- | -------- | -| CHANNEL_1 | 0x1 << 0 | Mono.| -| CHANNEL_2 | 0x1 << 1 | Dual-channel.| +| CHANNEL_1 | 0x1 << 0 | Channel 1. | +| CHANNEL_2 | 0x1 << 1 | Channel 2. | ## AudioSamplingRate8+ diff --git a/en/application-dev/reference/apis/js-apis-bundleManager-AppProvisionInfo.md b/en/application-dev/reference/apis/js-apis-bundleManager-AppProvisionInfo.md new file mode 100644 index 0000000000..b2e9cd3663 --- /dev/null +++ b/en/application-dev/reference/apis/js-apis-bundleManager-AppProvisionInfo.md @@ -0,0 +1,36 @@ +# AppProvisionInfo + +The **AppProvisionInfo** module provides information in the [HarmonyAppProvision configuration file](../../security/app-provision-structure.md). The information can be obtained through [getAppProvisionInfo](js-apis-bundleManager.md#bundlemanagergetappprovisioninfo10). + +> **NOTE** +> The initial APIs of this module are supported since API version 10. Newly added APIs will be marked with a superscript to indicate their earliest API version. + +## AppProvisionInfo + +**System capability**: SystemCapability.BundleManager.BundleFramework.Core + +**System API**: This is a system API. + +| Name | Type | Readable| Writable| Description | +| ------------------------- | ------ | ---- | ---- | -------------------- | +| versionCode | number | Yes | No | Version number of the configuration file.| +| versionName | string | Yes | No | Version name of the configuration file. | +| uuid | string | Yes | No | UUID in the configuration file.| +| type | string | Yes | No | Type of the configuration file, which can be **debug** or **release**.| +| appDistributionType | string | Yes | No | Distribution type in the configuration file, which can be **app_gallery**, **enterprise**, **os_integration**, or **crowdtesting**.| +| validity | [Validity](#validity) | Yes | No | Validity period in the configuration file.| +| developerId | string | Yes | No | Developer ID in the configuration file.| +| certificate | string | Yes | No | Certificate public key in the configuration file.| +| apl | string | Yes | No | APL in the configuration file, which can be **normal**, **system_basic**, or **system_core**.| +| issuer | string | Yes | No | Issuer name in the configuration file.| + +## Validity + +**System capability**: SystemCapability.BundleManager.BundleFramework.Core + +**System API**: This is a system API. + +| Name | Type | Readable| Writable| Description | +| ------------------------- | ------ | ---- | ---- | -------------------- | +| notBefore | number | Yes | No | Earliest validity date of the configuration file.| +| notAfter | number | Yes | No | Latest validity date of the configuration file.| diff --git a/en/application-dev/reference/apis/js-apis-bundleManager.md b/en/application-dev/reference/apis/js-apis-bundleManager.md index d5d0ff10e3..7962d8ae77 100644 --- a/en/application-dev/reference/apis/js-apis-bundleManager.md +++ b/en/application-dev/reference/apis/js-apis-bundleManager.md @@ -401,7 +401,6 @@ For details about the error codes, see [Bundle Error Codes](../errorcodes/errorc | ID| Error Message | | -------- | ------------------------------------- | | 17700001 | The specified bundleName is not found. | -| 17700004 | The specified user ID is not found. | | 17700026 | The specified bundle is disabled. | **Example** @@ -446,7 +445,7 @@ No permission is required for obtaining the caller's own information. | ----------- | ------ | ---- | ---------------------------- | | bundleName | string | Yes | Bundle name.| | bundleFlags | [number](#bundleflag) | Yes | Type of the bundle information to obtain. | -| userId | number | No | User ID. | +| userId | number | No | User ID. The default value is the user ID of the caller. The value must be greater than or equal to 0. | **Return value** @@ -587,7 +586,6 @@ For details about the error codes, see [Bundle Error Codes](../errorcodes/errorc | ID| Error Message | | -------- | --------------------------------------| | 17700001 | The specified bundleName is not found. | -| 17700004 | The specified user ID is not found. | | 17700026 | The specified bundle is disabled. | **Example** @@ -631,7 +629,7 @@ No permission is required for obtaining the caller's own information. | ---------- | ------ | ---- | ---------------------------- | | bundleName | string | Yes | Bundle name.| | appFlags | [number](#applicationflag) | Yes | Type of the application information to obtain. | -| userId | number | No | User ID.| +| userId | number | No | User ID. The default value is the user ID of the caller. The value must be greater than or equal to 0.| **Return value** @@ -737,14 +735,6 @@ Obtains the information about all bundles based on the given bundle flags. This | bundleFlags | [number](#bundleflag) | Yes | Type of the bundle information to obtain. | | callback | AsyncCallback> | Yes| Callback used to return the result. If the operation is successful, **err** is **null** and **data** is the array of bundle information obtained. Otherwise, **err** is an error object.| -**Error codes** - -For details about the error codes, see [Bundle Error Codes](../errorcodes/errorcode-bundle.md). - -| ID| Error Message | -| -------- | ---------------------------------- | -| 17700004 | The specified user ID is not found. | - **Example** ```ts @@ -782,7 +772,7 @@ Obtains the information about all bundles based on the given bundle flags and us | Name | Type | Mandatory| Description | | ----------- | ------ | ---- | -------------------------------------------------- | | bundleFlags | [number](#bundleflag) | Yes | Type of the bundle information to obtain. | -| userId | number | No | User ID. | +| userId | number | No | User ID. The default value is the user ID of the caller. The value must be greater than or equal to 0. | **Return value** @@ -884,14 +874,6 @@ Obtains the information about all applications based on the given application fl | appFlags | [number](#applicationflag) | Yes | Type of the application information to obtain. | | callback | AsyncCallback> | Yes| Callback used to return the result. If the operation is successful, **err** is **null** and **data** is the array of application information obtained. Otherwise, **err** is an error object.| -**Error codes** - -For details about the error codes, see [Bundle Error Codes](../errorcodes/errorcode-bundle.md). - -| ID| Error Message | -| -------- | ---------------------------------- | -| 17700004 | The specified user ID is not found. | - **Example** ```ts @@ -929,7 +911,7 @@ Obtains the information about all applications based on the given application fl | Name | Type | Mandatory| Description | | -------- | ------ | ---- | ---------------------------------------------------------- | | appFlags | [number](#applicationflag) | Yes | Type of the application information to obtain. | -| userId | number | No | User ID. | +| userId | number | No | User ID. The default value is the user ID of the caller. The value must be greater than or equal to 0. | **Return value** @@ -1050,7 +1032,6 @@ For details about the error codes, see [Bundle Error Codes](../errorcodes/errorc | -------- | -------------------------------------- | | 17700001 | The specified bundleName is not found. | | 17700003 | The specified ability is not found. | -| 17700004 | The specified userId is invalid. | | 17700026 | The specified bundle is disabled. | | 17700029 | The specified ability is disabled. | @@ -1096,7 +1077,7 @@ Obtains the ability information based on the given want, ability flags, and user | ------------ | ------ | ---- | ------------------------------------------------------- | | want | Want | Yes | Want containing the bundle name to query. | | abilityFlags | [number](#abilityflag) | Yes | Type of the ability information to obtain.| -| userId | number | No | User ID. | +| userId | number | No | User ID. The default value is the user ID of the caller. The value must be greater than or equal to 0. | **Return value** @@ -1247,7 +1228,6 @@ For details about the error codes, see [Bundle Error Codes](../errorcodes/errorc | -------- | -------------------------------------------- | | 17700001 | The specified bundleName is not found. | | 17700003 | The specified extensionAbility is not found. | -| 17700004 | The specified userId is invalid. | | 17700026 | The specified bundle is disabled. | **Example** @@ -1294,7 +1274,7 @@ Obtains the Extension ability information based on the given want, Extension abi | want | Want | Yes | Want containing the bundle name to query. | | extensionAbilityType | [ExtensionAbilityType](#extensionabilitytype) | Yes | Type of the Extension ability. | | extensionAbilityFlags | [number](#extensionabilityflag) | Yes | Type of the Extension ability information to obtain.| -| userId | number | No | User ID. | +| userId | number | No | User ID. The default value is the user ID of the caller. The value must be greater than or equal to 0. | **Return value** @@ -2171,7 +2151,6 @@ For details about the error codes, see [Bundle Error Codes](../errorcodes/errorc | ID| Error Message | | -------- | --------------------------------------| | 17700001 | The specified bundleName is not found. | -| 17700004 | The specified user ID is not found. | | 17700026 | The specified bundle is disabled. | **Example** @@ -2211,7 +2190,7 @@ Obtains the Want used to launch the bundle based on the given bundle name and us | Name | Type | Mandatory| Description | | ---------- | ------ | ---- | ------------------------- | | bundleName | string | Yes | Bundle name.| -| userId | number | No | User ID. | +| userId | number | No | User ID. The default value is the user ID of the caller. The value must be greater than or equal to 0. | **Return value** @@ -2313,7 +2292,7 @@ Obtains the JSON strings of the configuration file based on the given module ame | ------------ | ------ | ---- | -------------------------- | | moduleName | string | Yes | Module name. | | abilityName | string | Yes | Ability name. | -| metadataName | string | No | Metadata name.| +| metadataName | string | No | Metadata name. By default, no value is passed.| **Return value** @@ -2433,7 +2412,7 @@ Obtains the JSON strings of the configuration file based on the given module ame | -------------------- | ------ | ---- | ---------------------------------- | | moduleName | string | Yes | Module name. | | extensionAbilityName | string | Yes | Extension ability name.| -| metadataName | string | No | Metadata name. | +| metadataName | string | No | Metadata name. By default, no value is passed. | **Return value** @@ -2948,7 +2927,7 @@ try { ### bundleManager.getSharedBundleInfo10+ -function getSharedBundleInfo(bundleName: string, moduleName: string): Promise\\>; +getSharedBundleInfo(bundleName: string, moduleName: string): Promise\\>; Obtains the shared bundle information based on the given bundle name. This API uses a promise to return the result. @@ -3038,7 +3017,7 @@ try { ### bundleManager.getAllSharedBundleInfo10+ -function getAllSharedBundleInfo(): Promise\\>; +getAllSharedBundleInfo(): Promise\\>; Obtains the information about all shared bundles. This API uses a promise to return the result. @@ -3186,7 +3165,7 @@ Obtains the provision configuration file information based on the given bundle n | Name | Type | Mandatory| Description | | -------- | ------------------------------------------------------------ | ---- | ------------------------------------------------------------ | | bundleName | string | Yes| Bundle name.| -| userId | number | No| User ID, which can be obtained by calling [getOsAccountLocalId](js-apis-osAccount.md#getosaccountlocalid9).| +| userId | number | No| User ID. The default value is the user ID of the caller. The value must be greater than or equal to 0. You can call [getOsAccountLocalId](js-apis-osAccount.md#getosaccountlocalid9) to obtain the user ID on the current device.| **Return value** @@ -3232,5 +3211,3 @@ try { hilog.error(0x0000, 'testTag', 'getAppProvisionInfo failed. Cause: %{public}s', err.message); } ``` - - \ No newline at end of file diff --git a/en/application-dev/reference/apis/js-apis-uiappearance.md b/en/application-dev/reference/apis/js-apis-uiappearance.md index ebbdc97184..20d4807d83 100644 --- a/en/application-dev/reference/apis/js-apis-uiappearance.md +++ b/en/application-dev/reference/apis/js-apis-uiappearance.md @@ -4,7 +4,7 @@ The **uiAppearance** module provides basic capabilities for managing the system > **NOTE** > -> The APIs of this module are supported since API version 9. Updates will be marked with a superscript to indicate their earliest API version. +> The APIs of this module are supported since API version 10. Updates will be marked with a superscript to indicate their earliest API version. > > The APIs provided by this module are system APIs. -- GitLab