From 16345200e53b5174f629b4bd68709157f12f908b Mon Sep 17 00:00:00 2001 From: XC106102 <1061028507@qq.com> Date: Wed, 16 Jul 2025 10:50:39 +0800 Subject: [PATCH 1/2] ceshi Signed-off-by: XC106102 <1061028507@qq.com> --- api/@ohos.app.ability.Want.d.ts | 177 ++++++++++++++++++++++++++++---- 1 file changed, 157 insertions(+), 20 deletions(-) diff --git a/api/@ohos.app.ability.Want.d.ts b/api/@ohos.app.ability.Want.d.ts index 315ef9b506..0e153a08f4 100644 --- a/api/@ohos.app.ability.Want.d.ts +++ b/api/@ohos.app.ability.Want.d.ts @@ -1,5 +1,5 @@ /* - * Copyright (c) 2022-2023 Huawei Device Co., Ltd. + * Copyright (c) 2022-2024 Huawei Device Co., Ltd. * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at @@ -32,12 +32,18 @@ * @since 10 */ /** - * Want is the basic communication component of the system. + * Want is a carrier for information transfer between objects (application components). + * Want can be used as a parameter of startAbility to specify a startup target and information that needs to be carried + * during startup, for example, bundleName and abilityName, which respectively indicate the bundle name of the target + * ability and the ability name in the bundle. + * When UIAbilityA needs to start UIAbilityB and transfer some data to UIAbilityB, it can use Want a carrier to + * transfer the data. * * @syscap SystemCapability.Ability.AbilityBase * @crossplatform * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ export default class Want { /** @@ -55,12 +61,14 @@ export default class Want { * @since 10 */ /** - * bundle name + * Bundle name of the ability. * + * @type { ?string } * @syscap SystemCapability.Ability.AbilityBase * @crossplatform * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ bundleName?: string; @@ -79,12 +87,19 @@ export default class Want { * @since 10 */ /** - * ability name + * Name of the ability. + * If both bundleName and abilityName are specified in a Want object, the Want object can match a specific ability. + * + *

**NOTE**: + *
The value of abilityName must be unique in an application. + *

* + * @type { ?string } * @syscap SystemCapability.Ability.AbilityBase * @crossplatform * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ abilityName?: string; @@ -96,12 +111,17 @@ export default class Want { * @since 9 */ /** - * device id + * ID of the device running the ability. + * + *

**NOTE**: + *
If this field is unspecified, the local device is used. + *

* * @type { ?string } * @syscap SystemCapability.Ability.AbilityBase * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ deviceId?: string; @@ -113,12 +133,16 @@ export default class Want { * @since 9 */ /** - * The description of a URI in a Want. + * Data carried. + * This field is used together with type to specify the data type. + * If uri is specified in a Want, the Want will match the specified URI information, including scheme, + * schemeSpecificPart, authority, and path. * * @type { ?string } * @syscap SystemCapability.Ability.AbilityBase * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ uri?: string; @@ -137,6 +161,21 @@ export default class Want { * @atomicservice * @since 11 */ + /** + * MIME type, that is, the type of the file to open, for example, 'text/xml' and 'image/*'. + * + *

**NOTE**: + *
For details about the MIME type definition, + * see {@link https://www.iana.org/assignments/media-types/media-types.xhtml?utm_source=ld246.com}. + *

+ * + * @type { ?string } + * @syscap SystemCapability.Ability.AbilityBase + * @crossplatform + * @atomicservice + * @since arkts {'1.1':'18', '1.2':'20'} + * @arkts 1.1&1.2 + */ type?: string; /** @@ -147,7 +186,9 @@ export default class Want { * @since 9 */ /** - * The options of the flags in this Want. + * How the Want object will be handled. By default, a number is passed in. + * For example, wantConstant.Flags.FLAG_ABILITY_CONTINUATION specifies whether to start the ability in cross-device + * migration scenarios. * * @type { ?number } * @syscap SystemCapability.Ability.AbilityBase @@ -164,12 +205,15 @@ export default class Want { * @since 9 */ /** - * The description of an action in an want. + * Action to take, such as viewing and sharing application details. + * In implicit Want, you can define this field and use it together with uri or parameters to specify the operation + * to be performed on the data. * * @type { ?string } * @syscap SystemCapability.Ability.AbilityBase * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ action?: string; @@ -189,13 +233,73 @@ export default class Want { * @since 10 */ /** - * The description of the WantParams object in an Want + * List of parameters in the Want object. + * + *

**NOTE**: + *
1. The values of the following keys are assigned by the system. Manual settings do not take effect, since the + * system automatically changes the values to the actual values during data transfer. + * -ohos.aafwk.param.callerPid: PID of the caller. The value is a string. + * -ohos.aafwk.param.callerBundleName: bundle name of the caller. The value is a string. + * -ohos.aafwk.param.callerAbilityName: ability name of the caller. The value is a string. + * -ohos.aafwk.param.callerNativeName: process name of the caller when the native method is called. The value is + * a string. + * -ohos.aafwk.param.callerAppId: appId of the caller. The value is a string. + * -ohos.aafwk.param.callerAppIdentifier: appIdentifier of the caller. The value is a string. + * -ohos.aafwk.param.callerToken: token of the caller. The value is a string. + * -ohos.aafwk.param.callerUid: UID in BundleInfo, that is, the application's UID in the bundle information. The + * value is a number. + * -ohos.param.callerAppCloneIndex: clone index of the caller. The value is of the numeric type. + * -component.startup.newRules: enabled status of the new control rule. The value is of the Boolean type. + * -moduleName: module name of the caller. The value is a string. + * -ability.params.backToOtherMissionStack: support for redirection back across mission stacks. The value is of + * the Boolean type. + * -ohos.ability.params.abilityRecoveryRestart: support for ability restart upon fault recovery. The value is of + * the Boolean type. + * -ohos.extra.param.key.contentTitle: title that can be shared by the atomic service. The value is a string. + * -ohos.extra.param.key.shareAbstract: content that can be shared by the atomic service. The value is a string. + * -ohos.extra.param.key.shareUrl: URL of the content that can be shared by the atomic service. The value is + * a string. + * -ohos.extra.param.key.supportContinuePageStack: support for migration of page stack information during + * cross-device migration. The value is of the Boolean type. The default value is true, indicating that page stack + * information is automatically migrated. + * -ohos.extra.param.key.supportContinueSourceExit: support for application exit on the source device during + * cross-device migration. The value is of the Boolean type. The default value is true, indicating that the + * application on the source device automatically exits. + * -ohos.extra.param.key.showMode: mode to show the atomic service startup. The value is an enumerated value of + * wantConstant.ShowMode. + * -ohos.dlp.params.sandbox: available only for DLP files. This key is involved only in system applications. + * -ohos.dlp.params.bundleName: bundle name of DLP. The value is a string. This key is involved only in system + * applications. + * -ohos.dlp.params.moduleName: module name of DLP. The value is a string. This key is involved only in system + * applications. + * -ohos.dlp.params.abilityName: ability name of DLP. The value is a string. This key is involved only in system + * applications. + * -ohos.dlp.params.index: DLP index. The value is a number. This key is involved only in system applications. + * -ohos.ability.params.asssertFaultSessionId: session ID of the fault assertion. The value is a string. This key + * is involved only in system applications. + * + *
2. The following keys are defined by the system, and their values need to be manually assigned. + * -ability.params.stream: File URIs to be authorized to the target ability. The value is a file URI array of the + * string type. + * -ohos.extra.param.key.appCloneIndex: index of the application clone. + * + *
3. In addition to the foregoing cases, applications may further agree on the key-value pairs to transfer. + *

+ * + *

**NOTE**: + *
For details about the constants of Params in want, see wantConstant. + *
Note that a maximum of 200 KB data that can be transferred by using WantParams. If the data volume exceeds + * 200 KB, transfer data in WriteRawDataBuffer or uri mode. + *
The values of parameters must be of the following basic data types: String, Number, Boolean, Object, + * undefined, and null. Functions in an object cannot be transferred. + *

* * @type { ?Record } * @syscap SystemCapability.Ability.AbilityBase * @crossplatform * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ parameters?: Record; @@ -207,12 +311,14 @@ export default class Want { * @since 9 */ /** - * The description of a entities in a Want. + * Additional category information (such as browser and video player) of the ability. + * It is a supplement to the action field for implicit Want. and is used to filter ability types. * * @type { ?Array } * @syscap SystemCapability.Ability.AbilityBase * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ entities?: Array; @@ -231,12 +337,43 @@ export default class Want { * @since 10 */ /** - * The description of an module name in an want. + * Name of the module to which the ability belongs. + * + *

**NOTE**: + *
If the ability belongs to a HAR module, moduleName must be set to the name of the HAP or HSP module that + * depends on this HAR. + *

* + * @type { ?string } * @syscap SystemCapability.Ability.AbilityBase * @crossplatform * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ moduleName?: string; + + /** + * Want file descriptor (FD), which is used to identify the Want file opened. + * You can obtain the FD from fs.open. When the FD is no longer needed, you must call fs.close to destroy the FD in a + * timely manner to prevent FD leakage. + * + * @type { ?Record } + * @readonly + * @syscap SystemCapability.Ability.AbilityBase + * @atomicservice + * @since 15 + */ + readonly fds?: Record; } + +/** + * [Abstract, brief description of the class function] [Mandatory]. + * [Detailed description of the API function and behavior characteristics] [Optional] + * [API comments: constraints or restrictions and usage suggestions] [Mandatory if available] + * Writing format: Use appropriate HTML tags such as

,
, , and . Inline tags @ + * @syscap SystemCapability.Ability.AbilityBase + * @since 18 + * @arkts 1.2 + */ +class ClassNameThree {} \ No newline at end of file -- Gitee From 25fa98e0dd2494bc8dc4495bbd5eb2eaf0c00703 Mon Sep 17 00:00:00 2001 From: XC106102 <1061028507@qq.com> Date: Mon, 8 Sep 2025 12:00:07 +0800 Subject: [PATCH 2/2] ok Signed-off-by: XC106102 <1061028507@qq.com> --- .../component/ets/checkbox.static.d.ets | 32 +++++++++++++++++++ 1 file changed, 32 insertions(+) create mode 100644 api/@internal/component/ets/checkbox.static.d.ets diff --git a/api/@internal/component/ets/checkbox.static.d.ets b/api/@internal/component/ets/checkbox.static.d.ets new file mode 100644 index 0000000000..b6b70828d2 --- /dev/null +++ b/api/@internal/component/ets/checkbox.static.d.ets @@ -0,0 +1,32 @@ + +/* + * Copyright (c) 2025 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"), + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * @file + * @kit ArkUI + * @arkts 1.2 + */ + +/** + * Defines a Checkbox callback when onChange. + * Anonymous Object Rectification. + * + * @typedef { function } OnCheckboxChangeCallback + * @param { boolean } value - selected status + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @since 20 + */ +export type OnCheckboxChangeCallback = (value: boolean) => void; \ No newline at end of file -- Gitee