diff --git a/api/@internal/component/ets/form_component.d.ts b/api/@internal/component/ets/form_component.d.ts index a0a4f51d1660d4a8b47e78dcabb4facfc9256c4a..3e9d4c6c3de7db22c733a5940009c217452ce57d 100644 --- a/api/@internal/component/ets/form_component.d.ts +++ b/api/@internal/component/ets/form_component.d.ts @@ -17,14 +17,20 @@ * @file * @kit ArkUI */ - +/*** if arkts 1.2 */ +import { CommonMethod,Callback } from './common'; +import Want from '../../@ohos.app.ability.Want'; +import { Visibility } from './enums' +import { VoidCallback } from './units'; +/*** endif */ /** * Defines the FormDimension enum. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since 7 + * @since arkts {'1.1':'7','1.2':'20'} + * @arkts 1.1&1.2 */ declare enum FormDimension { /** @@ -32,36 +38,40 @@ declare enum FormDimension { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since 7 + * @since arkts {'1.1':'7','1.2':'20'} + * @arkts 1.1&1.2 */ - Dimension_1_2, + Dimension_1_2 = 0, /** * 2 x 2 cards * * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since 7 + * @since arkts {'1.1':'7','1.2':'20'} + * @arkts 1.1&1.2 */ - Dimension_2_2, + Dimension_2_2 = 1, /** * 2 x 4 cards * * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since 7 + * @since arkts {'1.1':'7','1.2':'20'} + * @arkts 1.1&1.2 */ - Dimension_2_4, + Dimension_2_4 = 2, /** * 4 x 4 cards * * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since 7 + * @since arkts {'1.1':'7','1.2':'20'} + * @arkts 1.1&1.2 */ - Dimension_4_4, + Dimension_4_4 = 3, /** * 2 x 1 cards @@ -69,8 +79,9 @@ declare enum FormDimension { * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi * @since 9 + * @deprecated since 20 */ - Dimension_2_1, + Dimension_2_1 = 4, /** * 1 x 1 cards @@ -78,7 +89,8 @@ declare enum FormDimension { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since 11 + * @since arkts {'1.1':'11','1.2':'20'} + * @arkts 1.1&1.2 */ DIMENSION_1_1 = 6, @@ -87,16 +99,18 @@ declare enum FormDimension { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ - DIMENSION_6_4, + DIMENSION_6_4 = 7, /** * 2 x 3 cards used for wearable devices * * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since 18 + * @since arkts {'1.1':'18','1.2':'20'} + * @arkts 1.1&1.2 */ DIMENSION_2_3 = 8, @@ -105,27 +119,20 @@ declare enum FormDimension { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since 18 - */ - DIMENSION_3_3 = 9, - - /** - * 3 x 4 cards used for tv devices - * - * @syscap SystemCapability.ArkUI.ArkUI.Full - * @systemapi - * @since 18 + * @since arkts {'1.1':'18','1.2':'20'} + * @arkts 1.1&1.2 */ - DIMENSION_3_4 = 10, + DIMENSION_3_3 = 9 } /** * Defines the FormRenderingMode enum. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since 11 + * @since arkts {'1.1':'11','1.2':'20'} + * @arkts 1.1&1.2 */ declare enum FormRenderingMode { @@ -134,7 +141,8 @@ declare enum FormRenderingMode { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since 11 + * @since arkts {'1.1':'11','1.2':'20'} + * @arkts 1.1&1.2 */ FULL_COLOR, @@ -143,7 +151,8 @@ declare enum FormRenderingMode { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since 11 + * @since arkts {'1.1':'11','1.2':'20'} + * @arkts 1.1&1.2 */ SINGLE_COLOR, } @@ -151,10 +160,11 @@ declare enum FormRenderingMode { /** * Defines the FormShape enum. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ declare enum FormShape { /** @@ -162,7 +172,8 @@ declare enum FormShape { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ RECT = 1, @@ -171,7 +182,8 @@ declare enum FormShape { * * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ CIRCLE, } @@ -182,18 +194,20 @@ declare enum FormShape { * @interface FormInfo * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ declare interface FormInfo { /** * The id the form. * - * @type { number | string } + * @type { long | string } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ - id: number | string; + id: long | string; /** * The name of the form. @@ -201,7 +215,8 @@ declare interface FormInfo { * @type { string } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ name: string; @@ -211,7 +226,8 @@ declare interface FormInfo { * @type { string } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ bundle: string; @@ -221,7 +237,8 @@ declare interface FormInfo { * @type { string } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ ability: string; @@ -231,7 +248,8 @@ declare interface FormInfo { * @type { string } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ module: string; @@ -241,7 +259,8 @@ declare interface FormInfo { * @type { ?FormDimension } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ dimension?: FormDimension; @@ -251,7 +270,8 @@ declare interface FormInfo { * @type { ?boolean } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ temporary?: boolean; @@ -265,13 +285,25 @@ declare interface FormInfo { */ want?: import('../api/@ohos.app.ability.Want').default; + /** + * The want of the form. + * + * @type { ?Want } + * @syscap SystemCapability.ArkUI.ArkUI.Full + * @systemapi + * @since 20 + * @arkts 1.2 + */ + want?: Want; + /** * The renderingMode of the form. * * @type { ?FormRenderingMode } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ renderingMode?: FormRenderingMode; @@ -281,7 +313,8 @@ declare interface FormInfo { * @type { ?FormShape } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ shape?: FormShape; } @@ -292,14 +325,15 @@ declare interface FormInfo { * @interface FormComponentInterface * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since 7 + * @since arkts {'1.1':'7','1.2':'20'} + * @arkts 1.1&1.2 */ interface FormComponentInterface { /** * Set a new value. * * @param { { - * id: number; + * id: long; * name: string; * bundle: string; * ability: string; @@ -338,7 +372,8 @@ interface FormComponentInterface { * @returns { FormComponentAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ (value: FormInfo): FormComponentAttribute; } @@ -349,18 +384,20 @@ interface FormComponentInterface { * @interface FormCallbackInfo * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ interface FormCallbackInfo { /** * The id of the form. * - * @type { number } + * @type { long } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ - id: number; + id: long; /** * The string id of the form. @@ -368,7 +405,8 @@ interface FormCallbackInfo { * @type { string } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ idString: string; } @@ -376,33 +414,35 @@ interface FormCallbackInfo { /** * Defines the size of Form. * - * @typedef FormSize + * @interface FormSize * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since 18 + * @since arkts{ '1.1':'18','1.2':'20'} + * @arkts 1.1&1.2 */ interface FormSize { /** * The width of the form. * Anonymous Object Rectification * - * @type { number } + * @type { double } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since 18 + * @since arkts{ '1.1':'18','1.2':'20'} + * @arkts 1.1&1.2 */ - width: number; - + width: double; /** * The height of the form. * Anonymous Object Rectification * - * @type { number } + * @type { double } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since 18 + * @since arkts{ '1.1':'18','1.2':'20'} + * @arkts 1.1&1.2 */ - height: number; + height: double; } /** @@ -411,19 +451,21 @@ interface FormSize { * @typedef ErrorInformation * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since 18 + * @since arkts{ '1.1':'18','1.2':'20'} + * @arkts 1.1&1.2 */ interface ErrorInformation { /** * Error code. * Anonymous Object Rectification * - * @type { number } + * @type { int } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since 18 + * @since arkts{ '1.1':'18','1.2':'20'} + * @arkts 1.1&1.2 */ - errcode: number; + errcode: int; /** * Error information. @@ -432,7 +474,8 @@ interface ErrorInformation { * @type { string } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since 18 + * @since arkts{ '1.1':'18','1.2':'20'} + * @arkts 1.1&1.2 */ msg: string; } @@ -441,7 +484,8 @@ interface ErrorInformation { * @extends CommonMethod * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since 7 + * @since arkts {'1.1':'7','1.2':'20'} + * @arkts 1.1&1.2 */ declare class FormComponentAttribute extends CommonMethod { /** @@ -455,13 +499,13 @@ declare class FormComponentAttribute extends CommonMethod): FormComponentAttribute; @@ -542,13 +591,13 @@ declare class FormComponentAttribute extends CommonMethod } callback * @returns { FormComponentAttribute } * @syscap SystemCapability.ArkUI.ArkUI.Full * @systemapi - * @since 18 + * @since arkts {'1.1':'18','1.2':'20'} + * @arkts 1.1&1.2 */ onError(callback: Callback): FormComponentAttribute; @@ -569,7 +618,8 @@ declare class FormComponentAttribute extends CommonMethod): FormComponentAttribute; @@ -589,7 +639,8 @@ declare class FormComponentAttribute extends CommonMethod): FormComponentAttribute; @@ -604,13 +655,13 @@ declare class FormComponentAttribute extends CommonMethod): FormComponentAttribute; } diff --git a/api/@internal/component/ets/form_link.d.ts b/api/@internal/component/ets/form_link.d.ts index 86479323501246859e6f83569e0ccbabde92fcf2..700211a7b821455ff4ea0cb067e6e741d61ad59c 100644 --- a/api/@internal/component/ets/form_link.d.ts +++ b/api/@internal/component/ets/form_link.d.ts @@ -17,7 +17,9 @@ * @file * @kit ArkUI */ - +/*** if arkts 1.2 */ +import { CommonMethod} from './common'; +/*** endif */ /** * Defines the FormLink options. * @@ -25,7 +27,7 @@ * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @since 10 -*/ + */ /** * Defines the FormLink options. * @@ -33,8 +35,9 @@ * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @atomicservice - * @since 11 -*/ + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 + */ declare interface FormLinkOptions { /** * Action types: "router" and "message". @@ -51,7 +54,8 @@ declare interface FormLinkOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ action: string; @@ -70,7 +74,8 @@ declare interface FormLinkOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ moduleName?: string; @@ -89,7 +94,8 @@ declare interface FormLinkOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ bundleName?: string; @@ -108,7 +114,8 @@ declare interface FormLinkOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ abilityName?: string; @@ -119,7 +126,8 @@ declare interface FormLinkOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ uri?: string; @@ -138,7 +146,8 @@ declare interface FormLinkOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ params?: Object; } @@ -158,7 +167,8 @@ declare interface FormLinkOptions { * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ interface FormLinkInterface { /** @@ -178,7 +188,8 @@ interface FormLinkInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ (options: FormLinkOptions): FormLinkAttribute; } @@ -198,10 +209,10 @@ interface FormLinkInterface { * @syscap SystemCapability.ArkUI.ArkUI.Full * @form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ -declare class FormLinkAttribute extends CommonMethod { -} +declare class FormLinkAttribute extends CommonMethod {} /** * Defines FormLink component. diff --git a/api/@ohos.UiTest.d.ts b/api/@ohos.UiTest.d.ts index 7ffdeef4a48152cce565178019ac00ed12167bd2..5f7b7fdf429f1646972164794772ca5a7a7dce2d 100755 --- a/api/@ohos.UiTest.d.ts +++ b/api/@ohos.UiTest.d.ts @@ -1078,14 +1078,14 @@ declare interface Point { /** * The x-coordinate of the coordinate point. * - * @type { number } + * @type { int } * @syscap SystemCapability.Test.UiTest * @crossplatform * @atomicservice * @since arkts {'1.1':'20','1.2':'20'} * @arkts 1.1&1.2 */ - x: number; + x: int; /** * The y-coordinate of the coordinate point. * @@ -1116,14 +1116,14 @@ declare interface Point { /** * The y-coordinate of the coordinate point. * - * @type { number } + * @type { int } * @syscap SystemCapability.Test.UiTest * @crossplatform * @atomicservice * @since arkts {'1.1':'20','1.2':'20'} * @arkts 1.1&1.2 */ - y: number; + y: int; /** * The displayId to which the coordinate point belongs, default is the displayId of the main scrren. * @@ -1191,14 +1191,14 @@ declare interface Rect { /** * The x-coordinate of the top left corner of the rectangle. * - * @type { number } + * @type { int } * @syscap SystemCapability.Test.UiTest * @crossplatform * @atomicservice * @since arkts {'1.1':'20','1.2':'20'} * @arkts 1.1&1.2 */ - left: number; + left: int; /** * The y-coordinate of the top left corner of the rectangle. * @@ -1229,14 +1229,14 @@ declare interface Rect { /** * The y-coordinate of the top left corner of the rectangle. * - * @type { number } + * @type { int } * @syscap SystemCapability.Test.UiTest * @crossplatform * @atomicservice * @since arkts {'1.1':'20','1.2':'20'} * @arkts 1.1&1.2 */ - top: number; + top: int; /** * The x-coordinate at the bottom right corner of the rectangle. * @@ -1267,14 +1267,14 @@ declare interface Rect { /** * The x-coordinate at the bottom right corner of the rectangle. * - * @type { number } + * @type { int } * @syscap SystemCapability.Test.UiTest * @crossplatform * @atomicservice * @since arkts {'1.1':'20','1.2':'20'} * @arkts 1.1&1.2 */ - right: number; + right: int; /** * The y-coordinate at the bottom right corner of the rectangle. * @@ -1305,14 +1305,14 @@ declare interface Rect { /** * The y-coordinate at the bottom right corner of the rectangle. * - * @type { number } + * @type { int } * @syscap SystemCapability.Test.UiTest * @crossplatform * @atomicservice * @since arkts {'1.1':'20','1.2':'20'} * @arkts 1.1&1.2 */ - bottom: number; + bottom: int; /** * The displayId to which the rect belongs, default is the displayId of the main screen. * @@ -1423,7 +1423,7 @@ declare interface WindowFilter { * @arkts 1.1&1.2 */ active?: boolean; - + /** * Find the window in the specified ID display. By default, it searches all displays. * @@ -1807,14 +1807,14 @@ declare interface TouchPadSwipeOptions { /** * Speed(pixels per second) of touchpad multi-finger swipe, default is 2000, the value ranges from 200 to 40000,set it 2000 if out of range. - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Test.UiTest * @atomicservice * @since arkts {'1.1':'18','1.2':'20'} * @test * @arkts 1.1&1.2 */ - speed?: number; + speed?: int; } /** @@ -3128,7 +3128,7 @@ declare class Component { /** * Scroll on this {@link Component} to the top,applicable to scrollable one. * - * @param { number } [speed] - the speed of swipe(pixels per second),ranges from 200 to 40000.Set it default 600 if out of range or null or undefined. + * @param { int } [speed] - the speed of swipe(pixels per second),ranges from 200 to 40000.Set it default 600 if out of range or null or undefined. * @returns { Promise } * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Incorrect parameter types; 2. Parameter verification failed. * @throws { BusinessError } 17000002 - The async function is not called with await. @@ -3140,7 +3140,7 @@ declare class Component { * @test * @arkts 1.1&1.2 */ - scrollToTop(speed?: number): Promise; + scrollToTop(speed?: int): Promise; /** * Scroll on this {@link Component} to the bottom,applicable to scrollable one. @@ -3170,7 +3170,7 @@ declare class Component { /** * Scroll on this {@link Component} to the bottom,applicable to scrollable one. * - * @param { number } [speed] - the speed of swipe(pixels per second),ranges from 200 to 40000. Set it default 600 if out of range or null or undefined. + * @param { int } [speed] - the speed of swipe(pixels per second),ranges from 200 to 40000. Set it default 600 if out of range or null or undefined. * @returns { Promise } * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Incorrect parameter types; 2. Parameter verification failed. * @throws { BusinessError } 17000002 - The async function is not called with await. @@ -3182,7 +3182,7 @@ declare class Component { * @test * @arkts 1.1&1.2 */ - scrollToBottom(speed?: number): Promise; + scrollToBottom(speed?: int): Promise; /** * Get the bounds rect of this {@link Component}. @@ -3219,6 +3219,7 @@ declare class Component { * @arkts 1.1&1.2 */ getBounds(): Promise; + /** * Scroll on this {@link Component}to find matched {@link Component},applicable to scrollable one. * @@ -3323,64 +3324,65 @@ declare class Component { * @arkts 1.1&1.2 */ dragTo(target: Component): Promise; + + /** + * Pinch enlarge this {@link Component} to the target scale. + * + * @param { number } scale The scale of the pinch enlarge this {@link Component}'s size. + * @returns { Promise } + * @throws { BusinessError } 401 - if the input parameters are invalid. + * @throws { BusinessError } 17000002 - if the async function was not called with await. + * @throws { BusinessError } 17000004 - if the component is invisible or destroyed. + * @syscap SystemCapability.Test.UiTest + * @since 9 + * @test + */ + /** + * Pinch enlarge this {@link Component} to the target scale. + * + * @param { double } scale - the scale of the pinch enlarge this {@link Component}'s size, ranges greater than 1. + * @returns { Promise } + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; 2. Incorrect parameter types; 3. Parameter verification failed. + * @throws { BusinessError } 17000002 - The async function is not called with await. + * @throws { BusinessError } 17000004 - The window or component is invisible or destroyed. + * @syscap SystemCapability.Test.UiTest + * @crossplatform + * @atomicservice + * @since arkts {'1.1':'11','1.2':'20'} + * @test + * @arkts 1.1&1.2 + */ + pinchOut(scale: double): Promise; + /** + * Pinch shrink this {@link Component} to the target scale. + * + * @param { number } scale The scale of the pinch shrink this {@link Component}'s size. + * @returns { Promise } + * @throws { BusinessError } 401 - if the input parameters are invalid. + * @throws { BusinessError } 17000002 - if the async function was not called with await. + * @throws { BusinessError } 17000004 - if the component is invisible or destroyed. + * @syscap SystemCapability.Test.UiTest + * @since 9 + * @test + */ + /** + * Pinch shrink this {@link Component} to the target scale. + * + * @param { double } scale - the scale of the pinch shrink this {@link Component}'s size, ranges from 0 to 1. + * @returns { Promise } + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; 2. Incorrect parameter types; 3. Parameter verification failed. + * @throws { BusinessError } 17000002 - The async function is not called with await. + * @throws { BusinessError } 17000004 - The window or component is invisible or destroyed. + * @syscap SystemCapability.Test.UiTest + * @crossplatform + * @atomicservice + * @since arkts {'1.1':'11','1.2':'20'} + * @test + * @arkts 1.1&1.2 + */ + pinchIn(scale: double): Promise; - /** - * Pinch enlarge this {@link Component} to the target scale. - * - * @param { number } scale The scale of the pinch enlarge this {@link Component}'s size. - * @returns { Promise } - * @throws { BusinessError } 401 - if the input parameters are invalid. - * @throws { BusinessError } 17000002 - if the async function was not called with await. - * @throws { BusinessError } 17000004 - if the component is invisible or destroyed. - * @syscap SystemCapability.Test.UiTest - * @since 9 - * @test - */ - /** - * Pinch enlarge this {@link Component} to the target scale. - * - * @param { number } scale - the scale of the pinch enlarge this {@link Component}'s size, ranges greater than 1. - * @returns { Promise } - * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; 2. Incorrect parameter types; 3. Parameter verification failed. - * @throws { BusinessError } 17000002 - The async function is not called with await. - * @throws { BusinessError } 17000004 - The window or component is invisible or destroyed. - * @syscap SystemCapability.Test.UiTest - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @test - * @arkts 1.1&1.2 - */ - pinchOut(scale: number): Promise; - /** - * Pinch shrink this {@link Component} to the target scale. - * - * @param { number } scale The scale of the pinch shrink this {@link Component}'s size. - * @returns { Promise } - * @throws { BusinessError } 401 - if the input parameters are invalid. - * @throws { BusinessError } 17000002 - if the async function was not called with await. - * @throws { BusinessError } 17000004 - if the component is invisible or destroyed. - * @syscap SystemCapability.Test.UiTest - * @since 9 - * @test - */ - /** - * Pinch shrink this {@link Component} to the target scale. - * - * @param { number } scale - the scale of the pinch shrink this {@link Component}'s size, ranges from 0 to 1. - * @returns { Promise } - * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; 2. Incorrect parameter types; 3. Parameter verification failed. - * @throws { BusinessError } 17000002 - The async function is not called with await. - * @throws { BusinessError } 17000004 - The window or component is invisible or destroyed. - * @syscap SystemCapability.Test.UiTest - * @crossplatform - * @atomicservice - * @since arkts {'1.1':'11','1.2':'20'} - * @test - * @arkts 1.1&1.2 - */ - pinchIn(scale: number): Promise; /** * Scroll on this {@link Component}to find matched {@link Component},applicable to scrollable one. * @@ -3390,8 +3392,6 @@ declare class Component { * @throws { BusinessError } 17000002 - The async function is not called with await. * @throws { BusinessError } 17000004 - The window or component is invisible or destroyed. * @syscap SystemCapability.Test.UiTest - * @crossplatform - * @atomicservice * @since 20 * @test * @arkts 1.2 @@ -3444,18 +3444,17 @@ declare class Component { * * @param { On } on - the attribute requirements of the target {@link Component}. * @param { boolean } [vertical] - Whether the swipe direction is vertical, default is true. - * @param { number } [offset] - Offset from the swipe start/end point to the component border, default is 80. + * @param { int } [offset] - Offset from the swipe start/end point to the component border, default is 80. * @returns { Promise } the found result,or null if not found. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; 2. Incorrect parameter types; 3. Parameter verification failed. * @throws { BusinessError } 17000002 - The async function is not called with await. * @throws { BusinessError } 17000004 - The window or component is invisible or destroyed. * @syscap SystemCapability.Test.UiTest - * @atomicservice * @since 20 * @test * @arkts 1.2 */ - scrollSearch(on: On, vertical?: boolean, offset?: number): Promise; + scrollSearch(on: On, vertical?: boolean, offset?: int): Promise; /** * Get the original text attribute value. * If the accessibility property 'accessibilityLevel' of a component is set to 'no' or 'no-hide-descendants', @@ -3561,7 +3560,7 @@ declare class Driver { /** * Delay with specified duration. * - * @param { number } duration - the delay duration in milliseconds, not less than 0. + * @param { int } duration - the delay duration in milliseconds, not less than 0. * @returns { Promise } * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; 2. Incorrect parameter types; 3. Parameter verification failed. * @throws { BusinessError } 17000002 - The async function is not called with await. @@ -3572,7 +3571,7 @@ declare class Driver { * @test * @arkts 1.1&1.2 */ - delayMs(duration: number): Promise; + delayMs(duration: int): Promise; /** * Find the first matched {@link Component} on current UI. @@ -3619,7 +3618,6 @@ declare class Driver { * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; 2. Incorrect parameter types; 3. Parameter verification failed. * @throws { BusinessError } 17000002 - The async function is not called with await. * @syscap SystemCapability.Test.UiTest - * @atomicservice * @since 20 * @test * @arkts 1.2 @@ -3657,7 +3655,6 @@ declare class Driver { * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; 2. Incorrect parameter types; 3. Parameter verification failed. * @throws { BusinessError } 17000002 - The async function is not called with await. * @syscap SystemCapability.Test.UiTest - * @atomicservice * @since 20 * @test * @arkts 1.2 @@ -3693,17 +3690,16 @@ declare class Driver { * Find the first matched {@link Component} on current UI during the time given. * * @param { On } on - the attribute requirements of the target {@link Component}. - * @param { number } time - duration of finding in milliseconds, not less than 0. + * @param { int } time - duration of finding in milliseconds, not less than 0. * @returns { Promise } the first matched {@link Component} or undefined. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; 2. Incorrect parameter types; 3. Parameter verification failed. * @throws { BusinessError } 17000002 - The async function is not called with await. * @syscap SystemCapability.Test.UiTest - * @atomicservice * @since 20 * @test * @arkts 1.2 */ - waitForComponent(on: On, time: number): Promise; + waitForComponent(on: On, time: int): Promise; /** * Find all the matched {@link Component}s on current UI. * @@ -3749,7 +3745,6 @@ declare class Driver { * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; 2. Incorrect parameter types; 3. Parameter verification failed. * @throws { BusinessError } 17000002 - The async function is not called with await. * @syscap SystemCapability.Test.UiTest - * @atomicservice * @since 20 * @test * @arkts 1.2 @@ -3858,7 +3853,7 @@ declare class Driver { /** * Press the specified key. * - * @param { number } keyCode - the target keyCode. + * @param { int } keyCode - the target keyCode. * @returns { Promise } * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; 2. Incorrect parameter types; 3. Parameter verification failed. * @throws { BusinessError } 17000002 - The async function is not called with await. @@ -3869,7 +3864,7 @@ declare class Driver { * @test * @arkts 1.1&1.2 */ - triggerKey(keyCode: number): Promise; + triggerKey(keyCode: int): Promise; /** * Press the specified key on the specified display. @@ -3902,9 +3897,9 @@ declare class Driver { /** * Press two or three key combinations * - * @param { number } key0 - the first keyCode. - * @param { number } key1 - the second keyCode. - * @param { number } [key2] - the third keyCode,set it default 0 if null or undefined. + * @param { int } key0 - the first keyCode. + * @param { int } key1 - the second keyCode. + * @param { int } [key2] - the third keyCode,set it default 0 if null or undefined. * @returns { Promise } * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; 2. Incorrect parameter types; 3. Parameter verification failed. * @throws { BusinessError } 17000002 - The async function is not called with await. @@ -3915,7 +3910,7 @@ declare class Driver { * @test * @arkts 1.1&1.2 */ - triggerCombineKeys(key0: number, key1: number, key2?: number): Promise; + triggerCombineKeys(key0: int, key1: int, key2?: int): Promise; /** * Press two or three key combinations on the specified display. @@ -3962,8 +3957,8 @@ declare class Driver { /** * Click on the specified location on the screen. * - * @param { number } x - the x-coordinate, not less than 0. - * @param { number } y - the y-coordinate, not less than 0. + * @param { int } x - the x-coordinate, not less than 0. + * @param { int } y - the y-coordinate, not less than 0. * @returns { Promise } * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; 2. Incorrect parameter types; 3. Parameter verification failed. * @throws { BusinessError } 17000002 - The async function is not called with await. @@ -3974,7 +3969,7 @@ declare class Driver { * @test * @arkts 1.1&1.2 */ - click(x: number, y: number): Promise; + click(x: int, y: int): Promise; /** * DoubleClick on the specified location on the screen. @@ -4004,8 +3999,8 @@ declare class Driver { /** * DoubleClick on the specified location on the screen. * - * @param { number } x - the x-coordinate, not less than 0. - * @param { number } y - the y-coordinate, not less than 0. + * @param { int } x - the x-coordinate, not less than 0. + * @param { int } y - the y-coordinate, not less than 0. * @returns { Promise } * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; 2. Incorrect parameter types; 3. Parameter verification failed. * @throws { BusinessError } 17000002 - The async function is not called with await. @@ -4016,7 +4011,7 @@ declare class Driver { * @test * @arkts 1.1&1.2 */ - doubleClick(x: number, y: number): Promise; + doubleClick(x: int, y: int): Promise; /** * LongClick on the specified location on the screen. @@ -4046,8 +4041,8 @@ declare class Driver { /** * LongClick on the specified location on the screen. * - * @param { number } x - the x-coordinate, not less than 0. - * @param { number } y - the y-coordinate, not less than 0. + * @param { int } x - the x-coordinate, not less than 0. + * @param { int } y - the y-coordinate, not less than 0. * @returns { Promise } * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; 2. Incorrect parameter types; 3. Parameter verification failed. * @throws { BusinessError } 17000002 - The async function is not called with await. @@ -4058,7 +4053,7 @@ declare class Driver { * @test * @arkts 1.1&1.2 */ - longClick(x: number, y: number): Promise; + longClick(x: int, y: int): Promise; /** * Swipe on the screen between the specified points. @@ -4094,11 +4089,11 @@ declare class Driver { /** * Swipe on the screen between the specified points. * - * @param { number } startx - the x-coordinate of the starting point, not less than 0. - * @param { number } starty - the y-coordinate of the starting point, not less than 0. - * @param { number } endx - the x-coordinate of the ending point, not less than 0. - * @param { number } endy - the y-coordinate of the ending point, not less than 0. - * @param { number } [speed] - the speed of swipe(pixels per second),ranges from 200 to 40000. Set it default 600 if out of range or null or undefined. + * @param { int } startx - the x-coordinate of the starting point, not less than 0. + * @param { int } starty - the y-coordinate of the starting point, not less than 0. + * @param { int } endx - the x-coordinate of the ending point, not less than 0. + * @param { int } endy - the y-coordinate of the ending point, not less than 0. + * @param { int } [speed] - the speed of swipe(pixels per second),ranges from 200 to 40000. Set it default 600 if out of range or null or undefined. * @returns { Promise } * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; 2. Incorrect parameter types; 3. Parameter verification failed. * @throws { BusinessError } 17000002 - The async function is not called with await. @@ -4109,7 +4104,7 @@ declare class Driver { * @test * @arkts 1.1&1.2 */ - swipe(startx: number, starty: number, endx: number, endy: number, speed?: number): Promise; + swipe(startx: int, starty: int, endx: int, endy: int, speed?: int): Promise; /** * Drag on the screen between the specified points. @@ -4129,11 +4124,11 @@ declare class Driver { /** * Drag on the screen between the specified points. * - * @param { number } startx - the x-coordinate of the starting point, not less than 0. - * @param { number } starty - the y-coordinate of the starting point, not less than 0. - * @param { number } endx - the x-coordinate of the ending point, not less than 0. - * @param { number } endy - the y-coordinate of the ending point, not less than 0. - * @param { number } [speed] the speed of drag(pixels per second),ranges from 200 to 40000. Set it default 600 if out of range or null or undefined. + * @param { int } startx - the x-coordinate of the starting point, not less than 0. + * @param { int } starty - the y-coordinate of the starting point, not less than 0. + * @param { int } endx - the x-coordinate of the ending point, not less than 0. + * @param { int } endy - the y-coordinate of the ending point, not less than 0. + * @param { int } [speed] the speed of drag(pixels per second),ranges from 200 to 40000. Set it default 600 if out of range or null or undefined. * @returns { Promise } * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; 2. Incorrect parameter types; 3. Parameter verification failed. * @throws { BusinessError } 17000002 - The async function is not called with await. @@ -4143,7 +4138,7 @@ declare class Driver { * @test * @arkts 1.1&1.2 */ - drag(startx: number, starty: number, endx: number, endy: number, speed?: number): Promise; + drag(startx: int, starty: int, endx: int, endy: int, speed?: int): Promise; /** * Click on the specified location on the screen. @@ -4495,8 +4490,8 @@ declare class Driver { /** * Wait for the UI become idle. * - * @param { number } idleTime - the threshold of UI idle time, in millisecond, not less than 0. - * @param { number } timeout - the maximum time to wait for idle, in millisecond, not less than 0. + * @param { int } idleTime - the threshold of UI idle time, in millisecond, not less than 0. + * @param { int } timeout - the maximum time to wait for idle, in millisecond, not less than 0. * @returns { Promise } true if wait for idle succeed in the timeout, false otherwise. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; 2. Incorrect parameter types; 3. Parameter verification failed. * @throws { BusinessError } 17000002 - The async function is not called with await. @@ -4506,7 +4501,7 @@ declare class Driver { * @test * @arkts 1.1&1.2 */ - waitForIdle(idleTime: number, timeout: number): Promise; + waitForIdle(idleTime: int, timeout: int): Promise; /** * Inject fling on the device display. @@ -4542,8 +4537,8 @@ declare class Driver { * * @param { Point } from - the coordinate point where the finger touches the screen. * @param { Point } to - the coordinate point where the finger leaves the screen. - * @param { number } stepLen - the length of each step, in pixels. - * @param { number } [speed] - the speed of fling(pixels per second),ranges from 200 to 40000. Set it default 600 if out of range or null or undefined. + * @param { int } stepLen - the length of each step, in pixels. + * @param { int } [speed] - the speed of fling(pixels per second),ranges from 200 to 40000. Set it default 600 if out of range or null or undefined. * @returns { Promise } * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; 2. Incorrect parameter types; 3. Parameter verification failed. * @throws { BusinessError } 17000002 - The async function is not called with await. @@ -4554,7 +4549,7 @@ declare class Driver { * @test * @arkts 1.1&1.2 */ - fling(from: Point, to: Point, stepLen: number, speed: number): Promise; + fling(from: Point, to: Point, stepLen: int, speed: int): Promise; /** * Inject multi-pointer action on the device display. @@ -4572,7 +4567,7 @@ declare class Driver { * Inject multi-pointer action on the device display. * * @param { PointerMatrix } pointers - the two-dimensional array of pointers to inject. - * @param { number } [speed] - the speed of swipe(pixels per second),ranges from 200 to 40000. Set it default 600 if out of range or null or undefined. + * @param { int } [speed] - the speed of swipe(pixels per second),ranges from 200 to 40000. Set it default 600 if out of range or null or undefined. * @returns { Promise } true if the operation finished, false * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; 2. Incorrect parameter types; 3. Parameter verification failed. * @throws { BusinessError } 17000002 - The async function is not called with await. @@ -4583,7 +4578,7 @@ declare class Driver { * @test * @arkts 1.1&1.2 */ - injectMultiPointerAction(pointers: PointerMatrix, speed?: number): Promise; + injectMultiPointerAction(pointers: PointerMatrix, speed?: int): Promise; /** * Inject fling on the device display. @@ -4614,7 +4609,7 @@ declare class Driver { * Inject fling on the device display. * * @param { UiDirection } direction - the direction of this action. - * @param { number } speed - the speed of fling (pixels per second),default is 600,the value ranges from 200 to 40000,set it 600 if out of range. + * @param { int } speed - the speed of fling (pixels per second),default is 600,the value ranges from 200 to 40000,set it 600 if out of range. * @returns { Promise } * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; 2. Incorrect parameter types; 3. Parameter verification failed. * @throws { BusinessError } 17000002 - The async function is not called with await. @@ -4625,7 +4620,7 @@ declare class Driver { * @test * @arkts 1.1&1.2 */ - fling(direction: UiDirection, speed: number): Promise; + fling(direction: UiDirection, speed: int): Promise; /** * Inject fling on the specified device display. @@ -4633,7 +4628,7 @@ declare class Driver { * @param { UiDirection } direction - the direction of this action. * @param { number } speed - the speed of fling (pixels per second),default is 600,the value ranges from 200 to 40000,set it 600 if out of range. * @param { number } displayId - the Id of the specified display. - * @returns { Promise } + * @returns { Promise } * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; 2. Incorrect parameter types; 3. Parameter verification failed. * @throws { BusinessError } 17000002 - The async function is not called with await. * @syscap SystemCapability.Test.UiTest @@ -4662,8 +4657,8 @@ declare class Driver { * * @param { Point } p - the coordinate of the specified location. * @param { MouseButton } btnId - the button of Mouse. - * @param { number } [key1] - the first keyCode,set it default 0 if null or undefined. - * @param { number } [key2] - the second keyCode,set it default 0 if null or undefined. + * @param { int } [key1] - the first keyCode,set it default 0 if null or undefined. + * @param { int } [key2] - the second keyCode,set it default 0 if null or undefined. * @returns { Promise } * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; 2. Incorrect parameter types; 3. Parameter verification failed. * @throws { BusinessError } 17000002 - The async function is not called with await. @@ -4673,7 +4668,7 @@ declare class Driver { * @test * @arkts 1.1&1.2 */ - mouseClick(p: Point, btnId: MouseButton, key1?: number, key2?: number): Promise; + mouseClick(p: Point, btnId: MouseButton, key1?: int, key2?: int): Promise; /** * Move the mouse cursor to the specified location. @@ -4721,9 +4716,9 @@ declare class Driver { * * @param { Point } p - the coordinate of the specified location. * @param { boolean } down - whether the mouse wheel rolls down. - * @param { number } d - the number of cells that the mouse wheel scrolls, each cell will make the target point shift 120 pixels. - * @param { number } [key1] - the first keyCode,set it default 0 if null or undefined. - * @param { number } [key2] - the second keyCode,set it default 0 if null or undefined. + * @param { int } d - the number of cells that the mouse wheel scrolls, each cell will make the target point shift 120 pixels. + * @param { int } [key1] - the first keyCode,set it default 0 if null or undefined. + * @param { int } [key2] - the second keyCode,set it default 0 if null or undefined. * @returns { Promise } * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; 2. Incorrect parameter types; 3. Parameter verification failed. * @throws { BusinessError } 17000002 - The async function is not called with await. @@ -4733,17 +4728,17 @@ declare class Driver { * @test * @arkts 1.1&1.2 */ - mouseScroll(p: Point, down: boolean, d: number, key1?: number, key2?: number): Promise; + mouseScroll(p: Point, down: boolean, d: int, key1?: int, key2?: int): Promise; /** * The mouse wheel scrolls the specified cell at the specified position, and press the specified key simultaneously if necessary. * * @param { Point } p - the coordinate of the specified location. * @param { boolean } down - whether the mouse wheel rolls down. - * @param { number } d - the number of cells that the mouse wheel scrolls, each cell will make the target point shift 120 pixels. - * @param { number } [key1] - the first keyCode,set it default 0 if null or undefined. - * @param { number } [key2] - the second keyCode,set it default 0 if null or undefined. - * @param { number } [speed] - The Speed of mouse wheel rolls(cells per second),ranges from 1 to 500.Set it default 20 if out of range or null or undefined. + * @param { int } d - the number of cells that the mouse wheel scrolls, each cell will make the target point shift 120 pixels. + * @param { int } [key1] - the first keyCode,set it default 0 if null or undefined. + * @param { int } [key2] - the second keyCode,set it default 0 if null or undefined. + * @param { int } [speed] - The Speed of mouse wheel rolls(cells per second),ranges from 1 to 500.Set it default 20 if out of range or null or undefined. * @returns { Promise } * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; 2. Incorrect parameter types; 3. Parameter verification failed. * @throws { BusinessError } 17000002 - The async function is not called with await. @@ -4753,7 +4748,7 @@ declare class Driver { * @test * @arkts 1.1&1.2 */ - mouseScroll(p: Point, down: boolean, d: number, key1?: number, key2?: number, speed?: number): Promise; + mouseScroll(p: Point, down: boolean, d: int, key1?: int, key2?: int, speed?: int): Promise; /** * Capture the specified area of current screen and save as picture which PNG format. @@ -4810,8 +4805,8 @@ declare class Driver { * * @param { Point } p - the coordinate of the specified location. * @param { MouseButton } btnId - the button of Mouse. - * @param { number } [key1] - the first keyCode,set it default 0 if null or undefined. - * @param { number } [key2] - the second keyCode,set it default 0 if null or undefined. + * @param { int } [key1] - the first keyCode,set it default 0 if null or undefined. + * @param { int } [key2] - the second keyCode,set it default 0 if null or undefined. * @returns { Promise } * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; 2. Incorrect parameter types; 3. Parameter verification failed. * @throws { BusinessError } 17000002 - The async function is not called with await. @@ -4821,15 +4816,15 @@ declare class Driver { * @test * @arkts 1.1&1.2 */ - mouseDoubleClick(p: Point, btnId: MouseButton, key1?: number, key2?: number): Promise; + mouseDoubleClick(p: Point, btnId: MouseButton, key1?: int, key2?: int): Promise; /** * Long click on the specified location on the screen with the specified mouse button, and press the specified key simultaneously if necessary. * * @param { Point } p - the coordinate of the specified location. * @param { MouseButton } btnId - the button of Mouse. - * @param { number } [key1] - the first keyCode,set it default 0 if null or undefined. - * @param { number } [key2] - the second keyCode,set it default 0 if null or undefined. + * @param { int } [key1] - the first keyCode,set it default 0 if null or undefined. + * @param { int } [key2] - the second keyCode,set it default 0 if null or undefined. * @returns { Promise } * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; 2. Incorrect parameter types; 3. Parameter verification failed. * @throws { BusinessError } 17000002 - The async function is not called with await. @@ -4839,7 +4834,7 @@ declare class Driver { * @test * @arkts 1.1&1.2 */ - mouseLongClick(p: Point, btnId: MouseButton, key1?: number, key2?: number): Promise; + mouseLongClick(p: Point, btnId: MouseButton, key1?: int, key2?: int): Promise; /** * Long click on the specified location on the screen with the specified mouse button, and press the specified key simultaneously if necessary. @@ -4864,7 +4859,7 @@ declare class Driver { * * @param { Point } from - the starting point. * @param { Point } to - the ending point. - * @param { number } [speed] - speed of swipe (pixels per second),the value ranges from 200 to 40000.Set it default 600 if out of range or null or undefined. + * @param { int } [speed] - speed of swipe (pixels per second),the value ranges from 200 to 40000.Set it default 600 if out of range or null or undefined. * @returns { Promise } * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; 2. Incorrect parameter types; 3. Parameter verification failed. * @throws { BusinessError } 17000002 - The async function is not called with await. @@ -4874,14 +4869,14 @@ declare class Driver { * @test * @arkts 1.1&1.2 */ - mouseMoveWithTrack(from: Point, to: Point, speed?: number): Promise; + mouseMoveWithTrack(from: Point, to: Point, speed?: int): Promise; /** * Hold down the left mouse button and drag on the screen between the specified points. * * @param { Point } from - the starting point. * @param { Point } to - the ending point. - * @param { number } [speed] - speed of drag (pixels per second),the value ranges from 200 to 40000,Set it default 600 if out of range or null or undefined. + * @param { int } [speed] - speed of drag (pixels per second),the value ranges from 200 to 40000,Set it default 600 if out of range or null or undefined. * @returns { Promise } * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; 2. Incorrect parameter types; 3. Parameter verification failed. * @throws { BusinessError } 17000002 - The async function is not called with await. @@ -4891,7 +4886,7 @@ declare class Driver { * @test * @arkts 1.1&1.2 */ - mouseDrag(from: Point, to: Point, speed?: number): Promise; + mouseDrag(from: Point, to: Point, speed?: int): Promise; /** * Hold down the left mouse button and drag on the screen between the specified points. @@ -4945,7 +4940,7 @@ declare class Driver { /** * Simulate touchpad multi-finger swipe gestures. - * @param { number } fingers Finger count of touchpad multi-finger swipe, ranges from 3 to 4. + * @param { int } fingers Finger count of touchpad multi-finger swipe, ranges from 3 to 4. * @param { UiDirection } direction Direction of touchpad multi-finger swipe. * @param { TouchPadSwipeOptions } [options] Additional options touchpad multi-finger swipe gestures, set its parameters to default values if null or undefined. * @returns { Promise } @@ -4958,7 +4953,7 @@ declare class Driver { * @test * @arkts 1.1&1.2 */ - touchPadMultiFingerSwipe(fingers: number, direction: UiDirection, options?: TouchPadSwipeOptions): Promise; + touchPadMultiFingerSwipe(fingers: int, direction: UiDirection, options?: TouchPadSwipeOptions): Promise; /** * Simulate pen click operation. @@ -4977,7 +4972,7 @@ declare class Driver { /** * Simulate pen long click operation. * @param { Point } point Coordinate of the specified location. - * @param { number } [pressure] Pressure of pen long click operation, default is 1.0, the value ranges from 0.0 to 1.0. + * @param { double } [pressure] Pressure of pen long click operation, default is 1.0, the value ranges from 0.0 to 1.0. * @returns { Promise } * @throws { BusinessError } 401 Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; 2. Incorrect parameter types; 3. Parameter verification failed. * @throws { BusinessError } 17000002 The async function is not called with await. @@ -4987,7 +4982,7 @@ declare class Driver { * @test * @arkts 1.1&1.2 */ - penLongClick(point: Point, pressure?: number): Promise; + penLongClick(point: Point, pressure?: double): Promise; /** * Simulate pen double click operation. @@ -5007,8 +5002,8 @@ declare class Driver { * Simulate pen swipe operation. * @param { Point } startPoint Coordinate of the specified location. * @param { Point } endPoint Coordinate of the specified location. - * @param { number } [speed] Speed(pixels per second) of pen swipe, default is 600,the value ranges from 200 to 40000,set it 600 if out of range. - * @param { number } [pressure] Pressure of pen swipe operation, default is 1.0, the value ranges from 0.0 to 1.0. + * @param { int } [speed] Speed(pixels per second) of pen swipe, default is 600,the value ranges from 200 to 40000,set it 600 if out of range. + * @param { double } [pressure] Pressure of pen swipe operation, default is 1.0, the value ranges from 0.0 to 1.0. * @returns { Promise } * @throws { BusinessError } 401 Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; 2. Incorrect parameter types; 3. Parameter verification failed. * @throws { BusinessError } 17000002 The async function is not called with await. @@ -5018,13 +5013,13 @@ declare class Driver { * @test * @arkts 1.1&1.2 */ - penSwipe(startPoint: Point, endPoint: Point, speed?: number, pressure?: number): Promise; + penSwipe(startPoint: Point, endPoint: Point, speed?: int, pressure?: double): Promise; /** * Inject pen multi-pointer action on the device display. * @param { PointerMatrix } pointers The two-dimensional array of pointers to inject. - * @param { number } [speed] Speed(pixels per second) of inject pen pointer action, default is 600,the value ranges from 200 to 40000,set it 600 if out of range. - * @param { number } [pressure] Pressure of inject pen pointer action operation, default is 1.0, the value ranges from 0.0 to 1.0. + * @param { int } [speed] Speed(pixels per second) of inject pen pointer action, default is 600,the value ranges from 200 to 40000,set it 600 if out of range. + * @param { double } [pressure] Pressure of inject pen pointer action operation, default is 1.0, the value ranges from 0.0 to 1.0. * @returns { Promise } * @throws { BusinessError } 401 Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; 2. Incorrect parameter types; 3. Parameter verification failed. * @throws { BusinessError } 17000002 The async function is not called with await. @@ -5034,7 +5029,7 @@ declare class Driver { * @test * @arkts 1.1&1.2 */ - injectPenPointerAction(pointers: PointerMatrix, speed?: number, pressure?: number): Promise; + injectPenPointerAction(pointers: PointerMatrix, speed?: int, pressure?: double): Promise; /** * Inject a watch crown rotation event, specifies the rotation speed if necessary. @@ -5254,8 +5249,8 @@ declare class UiWindow { /** * Move this {@link UiWindow} to the specified points. * - * @param { number } x - the x coordinate of destination, not less than 0. - * @param { number } y - the y coordinate of destination, not less than 0. + * @param { int } x - the x coordinate of destination, not less than 0. + * @param { int } y - the y coordinate of destination, not less than 0. * @returns { Promise } * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; 2. Incorrect parameter types; 3. Parameter verification failed. * @throws { BusinessError } 17000002 - The async function is not called with await. @@ -5267,7 +5262,7 @@ declare class UiWindow { * @test * @arkts 1.1&1.2 */ - moveTo(x: number, y: number): Promise; + moveTo(x: int, y: int): Promise; /** * Resize this {@link UiWindow} to the specified size for the specified direction. @@ -5287,8 +5282,8 @@ declare class UiWindow { /** * Resize this {@link UiWindow} to the specified size for the specified direction. * - * @param { number } wide - the expected wide of the window after resizing. - * @param { number } height - the expected height of the window after resizing. + * @param { int } wide - the expected wide of the window after resizing. + * @param { int } height - the expected height of the window after resizing. * @param { ResizeDirection } direction - the expected direction of the window after resizing. * @returns { Promise } * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; 2. Incorrect parameter types; 3. Parameter verification failed. @@ -5301,7 +5296,7 @@ declare class UiWindow { * @test * @arkts 1.1&1.2 */ - resize(wide: number, height: number, direction: ResizeDirection): Promise; + resize(wide: int, height: int, direction: ResizeDirection): Promise; /** * Change this {@link UiWindow} into split screen mode. @@ -5495,8 +5490,8 @@ declare class PointerMatrix { /** * Create an {@link PointerMatrix} object. * - * @param { number } fingers - The number of fingers, ranges from 1 to 10. - * @param { number } steps - The number of steps of each finger trace, ranges from 1 to 1000. + * @param { int } fingers - The number of fingers, ranges from 1 to 10. + * @param { int } steps - The number of steps of each finger trace, ranges from 1 to 1000. * @returns { PointerMatrix } the {@link PointerMatrix} object. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; 2. Incorrect parameter types; 3. Parameter verification failed. * @syscap SystemCapability.Test.UiTest @@ -5506,7 +5501,7 @@ declare class PointerMatrix { * @test * @arkts 1.1&1.2 */ - static create(fingers: number, steps: number): PointerMatrix; + static create(fingers: int, steps: int): PointerMatrix; /** * Set the point value of an element in the PointerMatrix. @@ -5522,8 +5517,8 @@ declare class PointerMatrix { /** * Set the point value of an element in the PointerMatrix. * - * @param { number } finger - the index of target finger to set. - * @param { number } step - the index of target step to set. + * @param { int } finger - the index of target finger to set. + * @param { int } step - the index of target step to set. * @param { Point } point - the coordinate of target step to set. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; 2. Incorrect parameter types; 3. Parameter verification failed. * @syscap SystemCapability.Test.UiTest @@ -5533,7 +5528,7 @@ declare class PointerMatrix { * @test * @arkts 1.1&1.2 */ - setPoint(finger: number, step: number, point: Point): void; + setPoint(finger: int, step: int, point: Point): void; } /** diff --git a/api/@ohos.WorkSchedulerExtensionAbility.d.ts b/api/@ohos.WorkSchedulerExtensionAbility.d.ts index 7b64c003c98732a2f75785c8c8d290a642b3e913..4f2eedcb5f52067581ade32b7518c6ab61b8c0d5 100644 --- a/api/@ohos.WorkSchedulerExtensionAbility.d.ts +++ b/api/@ohos.WorkSchedulerExtensionAbility.d.ts @@ -19,7 +19,7 @@ */ import workScheduler from './@ohos.resourceschedule.workScheduler'; -import { WorkSchedulerExtensionContext as _WorkSchedulerExtensionContext } from './application/WorkSchedulerExtensionContext'; +import _WorkSchedulerExtensionContext from './application/WorkSchedulerExtensionContext'; /** * The context of work scheduler extension. It allows access to diff --git a/api/@ohos.app.ability.AbilityConstant.d.ts b/api/@ohos.app.ability.AbilityConstant.d.ts index 1f7273212581ebc63d42829b88f39347446b1b35..5fa367af1ed17a30742a1bd7d09cd6c8e2d9491e 100644 --- a/api/@ohos.app.ability.AbilityConstant.d.ts +++ b/api/@ohos.app.ability.AbilityConstant.d.ts @@ -172,7 +172,8 @@ declare namespace AbilityConstant { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ lastExitMessage: string; @@ -183,7 +184,8 @@ declare namespace AbilityConstant { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly * @atomicservice - * @since 18 + * @since arkts {'1.1':'18', '1.2':'20'} + * @arkts 1.1&1.2 */ lastExitDetailInfo?: LastExitDetailInfo; } @@ -195,7 +197,8 @@ declare namespace AbilityConstant { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly * @atomicservice - * @since 18 + * @since arkts {'1.1':'18', '1.2':'20'} + * @arkts 1.1&1.2 */ export interface LastExitDetailInfo { /** @@ -205,7 +208,8 @@ declare namespace AbilityConstant { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly * @atomicservice - * @since 18 + * @since arkts {'1.1':'18', '1.2':'20'} + * @arkts 1.1&1.2 */ pid: number; @@ -216,7 +220,8 @@ declare namespace AbilityConstant { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly * @atomicservice - * @since 18 + * @since arkts {'1.1':'18', '1.2':'20'} + * @arkts 1.1&1.2 */ processName: string; @@ -227,7 +232,8 @@ declare namespace AbilityConstant { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly * @atomicservice - * @since 18 + * @since arkts {'1.1':'18', '1.2':'20'} + * @arkts 1.1&1.2 */ uid: number; @@ -238,7 +244,8 @@ declare namespace AbilityConstant { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly * @atomicservice - * @since 18 + * @since arkts {'1.1':'18', '1.2':'20'} + * @arkts 1.1&1.2 */ exitSubReason: number; @@ -249,7 +256,8 @@ declare namespace AbilityConstant { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly * @atomicservice - * @since 18 + * @since arkts {'1.1':'18', '1.2':'20'} + * @arkts 1.1&1.2 */ exitMsg: string; @@ -260,7 +268,8 @@ declare namespace AbilityConstant { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly * @atomicservice - * @since 18 + * @since arkts {'1.1':'18', '1.2':'20'} + * @arkts 1.1&1.2 */ rss: number; @@ -271,7 +280,8 @@ declare namespace AbilityConstant { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly * @atomicservice - * @since 18 + * @since arkts {'1.1':'18', '1.2':'20'} + * @arkts 1.1&1.2 */ pss: number; @@ -282,7 +292,8 @@ declare namespace AbilityConstant { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly * @atomicservice - * @since 18 + * @since arkts {'1.1':'18', '1.2':'20'} + * @arkts 1.1&1.2 */ timestamp: number; diff --git a/api/@ohos.app.ability.Configuration.d.ts b/api/@ohos.app.ability.Configuration.d.ts index b9a204339502a0fc993818ee22e94b00cb900ee5..e8139c14bc5cfb41c8e5788bb1948de0cb78e1d2 100644 --- a/api/@ohos.app.ability.Configuration.d.ts +++ b/api/@ohos.app.ability.Configuration.d.ts @@ -122,7 +122,8 @@ export interface Configuration { * @syscap SystemCapability.Ability.AbilityBase * @crossplatform * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ direction?: ConfigurationConstant.Direction; @@ -148,7 +149,8 @@ export interface Configuration { * @syscap SystemCapability.Ability.AbilityBase * @crossplatform * @atomicservice - * @since 18 + * @since arkts {'1.1':'18', '1.2':'20'} + * @arkts 1.1&1.2 */ screenDensity?: ConfigurationConstant.ScreenDensity; @@ -165,7 +167,8 @@ export interface Configuration { * @type { ?number } * @syscap SystemCapability.Ability.AbilityBase * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ displayId?: number; @@ -182,7 +185,8 @@ export interface Configuration { * @type { ?boolean } * @syscap SystemCapability.Ability.AbilityBase * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ hasPointerDevice?: boolean; @@ -222,7 +226,8 @@ export interface Configuration { * @type { ?number } * @syscap SystemCapability.Ability.AbilityBase * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ fontWeightScale?: number; @@ -232,7 +237,8 @@ export interface Configuration { * @type { ?string } * @syscap SystemCapability.Ability.AbilityBase * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ mcc?: string; @@ -242,7 +248,8 @@ export interface Configuration { * @type { ?string } * @syscap SystemCapability.Ability.AbilityBase * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ mnc?: string; diff --git a/api/@ohos.app.ability.InsightIntentContext.d.ts b/api/@ohos.app.ability.InsightIntentContext.d.ts index 9f2de2d357adb48adc035aba503fe59a6ee0f12c..89e087146f0fe30a9a60e21849c2ada767e3b3e0 100644 --- a/api/@ohos.app.ability.InsightIntentContext.d.ts +++ b/api/@ohos.app.ability.InsightIntentContext.d.ts @@ -27,9 +27,10 @@ import type Want from './@ohos.app.ability.Want'; * @syscap SystemCapability.Ability.AbilityRuntime.Core * @StageModelOnly * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ -export default class InsightIntentContext { +declare class InsightIntentContext { /** * Starts a new ability. * This interface only allows you to start abilities within the same bundle and specify the bundleName. @@ -90,3 +91,5 @@ export default class InsightIntentContext { */ startAbility(want: Want): Promise; } + +export default InsightIntentContext; \ No newline at end of file diff --git a/api/@ohos.app.ability.InsightIntentExecutor.d.ts b/api/@ohos.app.ability.InsightIntentExecutor.d.ts index 69a71decc5906491b95e21bd8d0456cdfcacd261..1e753f499569cb56e1c0f718df9e73bfbd082aee 100644 --- a/api/@ohos.app.ability.InsightIntentExecutor.d.ts +++ b/api/@ohos.app.ability.InsightIntentExecutor.d.ts @@ -29,9 +29,10 @@ import type UIExtensionContentSession from './@ohos.app.ability.UIExtensionConte * @syscap SystemCapability.Ability.AbilityRuntime.Core * @StageModelOnly * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ -export default class InsightIntentExecutor { +declare class InsightIntentExecutor { /** * Indicates context of insight intent. * @@ -39,7 +40,8 @@ export default class InsightIntentExecutor { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @StageModelOnly * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ context: InsightIntentContext; @@ -53,7 +55,8 @@ export default class InsightIntentExecutor { * @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore * @StageModelOnly * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ onExecuteInUIAbilityForegroundMode(name: string, param: Record, pageLoader: window.WindowStage): insightIntent.ExecuteResult | Promise; @@ -67,7 +70,8 @@ export default class InsightIntentExecutor { * @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore * @StageModelOnly * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ onExecuteInUIAbilityBackgroundMode(name: string, param: Record): insightIntent.ExecuteResult | Promise; @@ -81,7 +85,8 @@ export default class InsightIntentExecutor { * @returns { insightIntent.ExecuteResult | Promise } The result of insight intent execution, support promise. * @syscap SystemCapability.Ability.AbilityRuntime.Core * @StageModelOnly - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ onExecuteInUIExtensionAbility(name: string, param: Record, pageLoader: UIExtensionContentSession): insightIntent.ExecuteResult | Promise; @@ -94,8 +99,11 @@ export default class InsightIntentExecutor { * @returns { insightIntent.ExecuteResult | Promise } The result of insight intent execution, support promise. * @syscap SystemCapability.Ability.AbilityRuntime.Core * @StageModelOnly - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ onExecuteInServiceExtensionAbility(name: string, param: Record): insightIntent.ExecuteResult | Promise; } + +export default InsightIntentContext; \ No newline at end of file diff --git a/api/@ohos.app.ability.OpenLinkOptions.d.ts b/api/@ohos.app.ability.OpenLinkOptions.d.ts index e93d8ff2a737a88ceb1db1895ebff86469ef7dff..63873b4f2c5d3eedc833a89db84a6641e0c077fe 100644 --- a/api/@ohos.app.ability.OpenLinkOptions.d.ts +++ b/api/@ohos.app.ability.OpenLinkOptions.d.ts @@ -25,7 +25,8 @@ * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ export default interface OpenLinkOptions { /** @@ -36,7 +37,8 @@ export default interface OpenLinkOptions { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ appLinkingOnly?: boolean; @@ -47,7 +49,8 @@ export default interface OpenLinkOptions { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ parameters?: Record; } diff --git a/api/@ohos.app.ability.ServiceExtensionAbility.d.ts b/api/@ohos.app.ability.ServiceExtensionAbility.d.ts index 0d678b9f424a7118b6f4df8de7b7f9f99ff24f80..9fb19d970b90c60f6b803e15176137b68f65b738 100644 --- a/api/@ohos.app.ability.ServiceExtensionAbility.d.ts +++ b/api/@ohos.app.ability.ServiceExtensionAbility.d.ts @@ -155,7 +155,8 @@ declare class ServiceExtensionAbility { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi * @StageModelOnly - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ onConfigurationUpdate(newConfig: Configuration): void; diff --git a/api/@ohos.app.ability.StartOptions.d.ts b/api/@ohos.app.ability.StartOptions.d.ts index 8526689c432230d3b00fc41900f663a3e29a9361..07b51995b51eff0d532425c16e6f8a39584d3142 100644 --- a/api/@ohos.app.ability.StartOptions.d.ts +++ b/api/@ohos.app.ability.StartOptions.d.ts @@ -17,11 +17,10 @@ * @file * @kit AbilityKit */ - -/*** if arkts 1.1 */ import contextConstant from "./@ohos.app.ability.contextConstant"; import image from "./@ohos.multimedia.image"; import bundleManager from './@ohos.bundle.bundleManager'; +/*** if arkts 1.1 */ import CompletionHandler from './@ohos.app.ability.CompletionHandler'; /*** endif */ @@ -51,7 +50,8 @@ export default class StartOptions { * @type { ?number } * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ windowMode?: number; @@ -81,7 +81,8 @@ export default class StartOptions { * @type { ?boolean } * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ withAnimation?: boolean; @@ -91,7 +92,8 @@ export default class StartOptions { * @type { ?number } * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ windowLeft?: number; @@ -101,7 +103,8 @@ export default class StartOptions { * @type { ?number } * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ windowTop?: number; @@ -111,7 +114,8 @@ export default class StartOptions { * @type { ?number } * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ windowWidth?: number; @@ -121,7 +125,8 @@ export default class StartOptions { * @type { ?number } * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ windowHeight?: number; @@ -132,7 +137,8 @@ export default class StartOptions { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi * @stagemodelonly - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ windowFocused?: boolean; @@ -144,7 +150,8 @@ export default class StartOptions { * @type { ?contextConstant.ProcessMode } * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ processMode?: contextConstant.ProcessMode; @@ -156,7 +163,8 @@ export default class StartOptions { * @type { ?contextConstant.StartupVisibility } * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ startupVisibility?: contextConstant.StartupVisibility; @@ -166,7 +174,8 @@ export default class StartOptions { * @type { ?image.PixelMap } * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ startWindowIcon?: image.PixelMap; @@ -176,7 +185,8 @@ export default class StartOptions { * @type { ?string } * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ startWindowBackgroundColor?: string; @@ -186,7 +196,8 @@ export default class StartOptions { * @type { ?Array } * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ supportWindowModes?: Array; @@ -196,7 +207,8 @@ export default class StartOptions { * @type { ?number } * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly - * @since 17 + * @since arkts{ '1.1':'17','1.2':'20'} + * @arkts 1.1&1.2 */ minWindowWidth?: number; @@ -206,7 +218,8 @@ export default class StartOptions { * @type { ?number } * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly - * @since 17 + * @since arkts{ '1.1':'17','1.2':'20'} + * @arkts 1.1&1.2 */ minWindowHeight?: number; @@ -216,7 +229,8 @@ export default class StartOptions { * @type { ?number } * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly - * @since 17 + * @since arkts{ '1.1':'17','1.2':'20'} + * @arkts 1.1&1.2 */ maxWindowWidth?: number; @@ -226,7 +240,8 @@ export default class StartOptions { * @type { ?number } * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly - * @since 17 + * @since arkts{ '1.1':'17','1.2':'20'} + * @arkts 1.1&1.2 */ maxWindowHeight?: number; diff --git a/api/@ohos.app.ability.UIAbility.d.ts b/api/@ohos.app.ability.UIAbility.d.ts index f7680dd63e5efbd15144595b5025ac5084532fe7..f0ee7fa13b633dd6947c8ec9d3f4a8c1c1bca948 100644 --- a/api/@ohos.app.ability.UIAbility.d.ts +++ b/api/@ohos.app.ability.UIAbility.d.ts @@ -47,6 +47,20 @@ export interface OnReleaseCallback { (msg: string): void; } +/** + * The prototype of the listener function interface registered by the Caller. + * Defines the callback of OnRelease. + * + * @typedef OnReleaseCallback + * @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore + * @param { string } msg - The notification event string listened to by the OnRelease. + * @stagemodelonly + * @since 20 + * @arkts 1.2 + */ +export type OnReleaseCallback = (msg: string)=> void; + + /** * The prototype of the listener function interface registered by the Caller. * @@ -94,7 +108,8 @@ export interface CalleeCallback { * @interface Caller * @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore * @stagemodelonly - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ export interface Caller { /** @@ -155,7 +170,8 @@ export interface Caller { * @throws { BusinessError } 16200001 - The caller has been released. * @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore * @stagemodelonly - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ onRelease(callback: OnReleaseCallback): void; @@ -336,7 +352,8 @@ declare class UIAbility extends Ability { * @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore * @stagemodelonly * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ launchWant: Want; @@ -355,7 +372,8 @@ declare class UIAbility extends Ability { * @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore * @stagemodelonly * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ lastRequestWant: Want; @@ -442,7 +460,8 @@ declare class UIAbility extends Ability { * @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore * @stagemodelonly * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ onWindowStageWillDestroy(windowStage: window.WindowStage): void; @@ -488,7 +507,8 @@ declare class UIAbility extends Ability { * @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore * @stagemodelonly * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ onWindowStageRestore(windowStage: window.WindowStage): void; @@ -950,7 +970,8 @@ declare class UIAbility extends Ability { * @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore * @stagemodelonly * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ onBackPressed(): boolean; diff --git a/api/@ohos.app.ability.UIExtensionContentSession.d.ts b/api/@ohos.app.ability.UIExtensionContentSession.d.ts index 146c2971a77ebef44f36c72fb29ac472a2b4fb7d..8f9f41357a03236a59e4d0d3d10c8bcd15b9d098 100644 --- a/api/@ohos.app.ability.UIExtensionContentSession.d.ts +++ b/api/@ohos.app.ability.UIExtensionContentSession.d.ts @@ -97,7 +97,8 @@ declare class UIExtensionContentSession { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi * @stagemodelonly - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ setReceiveDataForResultCallback(callback: (data: Record) => Record): void; diff --git a/api/@ohos.app.ability.Want.d.ts b/api/@ohos.app.ability.Want.d.ts index c02d8ccd5b74588f25ef809f5c0a94c6c650656d..ae262892e81296f6f3d3ab4e9df5b957d738e20d 100644 --- a/api/@ohos.app.ability.Want.d.ts +++ b/api/@ohos.app.ability.Want.d.ts @@ -362,7 +362,8 @@ export default class Want { * @readonly * @syscap SystemCapability.Ability.AbilityBase * @atomicservice - * @since 15 + * @since arkts {'1.1':'15', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly fds?: Record; } diff --git a/api/@ohos.app.ability.abilityDelegatorRegistry.d.ts b/api/@ohos.app.ability.abilityDelegatorRegistry.d.ts index 3fa78db0916e5a06e03c695528b2b4be9592827e..c927cbc29ec467a090869658867ac317a83b559b 100644 --- a/api/@ohos.app.ability.abilityDelegatorRegistry.d.ts +++ b/api/@ohos.app.ability.abilityDelegatorRegistry.d.ts @@ -21,10 +21,8 @@ import { AbilityDelegator as _AbilityDelegator } from './application/AbilityDelegator'; import { AbilityDelegatorArgs as _AbilityDelegatorArgs } from './application/abilityDelegatorArgs'; import { AbilityMonitor as _AbilityMonitor } from './application/AbilityMonitor'; -/*** if arkts 1.1 */ import { AbilityStageMonitor as _AbilityStageMonitor } from './application/AbilityStageMonitor'; import { ShellCmdResult as _ShellCmdResult } from './application/shellCmdResult'; -/*** endif */ /** * A global register used to store the AbilityDelegator and AbilityDelegatorArgs objects registered @@ -131,7 +129,8 @@ declare namespace abilityDelegatorRegistry { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @crossplatform * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ export enum AbilityLifecycleState { /** @@ -153,7 +152,8 @@ declare namespace abilityDelegatorRegistry { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @crossplatform * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ UNINITIALIZED, @@ -176,7 +176,8 @@ declare namespace abilityDelegatorRegistry { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @crossplatform * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ CREATE, @@ -199,7 +200,8 @@ declare namespace abilityDelegatorRegistry { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @crossplatform * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ FOREGROUND, @@ -222,7 +224,8 @@ declare namespace abilityDelegatorRegistry { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @crossplatform * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ BACKGROUND, @@ -245,7 +248,8 @@ declare namespace abilityDelegatorRegistry { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @crossplatform * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ DESTROY } @@ -340,7 +344,8 @@ declare namespace abilityDelegatorRegistry { * @typedef { _ShellCmdResult } * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ export type ShellCmdResult = _ShellCmdResult; @@ -352,7 +357,8 @@ declare namespace abilityDelegatorRegistry { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @crossplatform * @atomicservice - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ export type AbilityStageMonitor = _AbilityStageMonitor; } diff --git a/api/@ohos.app.ability.abilityManager.d.ts b/api/@ohos.app.ability.abilityManager.d.ts index 1acdb5ed8168b6e4865100682d9962b741bce023..5c02f6c9e2b3d2c495bf45bd2f70dc6b60753a09 100644 --- a/api/@ohos.app.ability.abilityManager.d.ts +++ b/api/@ohos.app.ability.abilityManager.d.ts @@ -18,15 +18,20 @@ * @kit AbilityKit */ -import { AbilityResult } from './ability/abilityResult'; import { AsyncCallback } from './@ohos.base'; +import { ElementName } from './bundleManager/ElementName'; +/*** if arkts 1.1 */ +import { AbilityResult } from './ability/abilityResult'; import { Configuration } from './@ohos.app.ability.Configuration'; import Context from './application/Context'; import { AbilityRunningInfo as _AbilityRunningInfo } from './application/AbilityRunningInfo'; import { ExtensionRunningInfo as _ExtensionRunningInfo } from './application/ExtensionRunningInfo'; -import { ElementName } from './bundleManager/ElementName'; import * as _AbilityForegroundStateObserver from './application/AbilityForegroundStateObserver'; import * as _AbilityStateData from './application/AbilityStateData'; +/*** endif */ +/*** if arkts 1.2 */ +import _AbilityStateData from './application/AbilityStateData'; +/*** endif */ /** * The class of an ability manager. @@ -42,6 +47,7 @@ import * as _AbilityStateData from './application/AbilityStateData'; * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice * @since 20 + * @arkts 1.1&1.2 */ declare namespace abilityManager { /** @@ -313,7 +319,8 @@ declare namespace abilityManager { * @throws { BusinessError } 16000050 - Internal error. * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getTopAbility(): Promise; @@ -327,7 +334,8 @@ declare namespace abilityManager { * @throws { BusinessError } 16000050 - Internal error. * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getTopAbility(callback: AsyncCallback): void; @@ -435,7 +443,8 @@ declare namespace abilityManager { * @throws { BusinessError } 16000050 - Internal error. * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ function getForegroundUIAbilities(callback: AsyncCallback>): void; @@ -449,7 +458,8 @@ declare namespace abilityManager { * @throws { BusinessError } 16000050 - Internal error. * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ function getForegroundUIAbilities(): Promise>; @@ -556,6 +566,17 @@ declare namespace abilityManager { */ export type AbilityStateData = _AbilityStateData.default; + /** + * The ability state data. + * + * @typedef { _AbilityStateData } + * @syscap SystemCapability.Ability.AbilityRuntime.Core + * @since 20 + * @arkts 1.2 + */ + export type AbilityStateData = _AbilityStateData; + + /** * The class of an extension running information. * diff --git a/api/@ohos.app.ability.appManager.d.ts b/api/@ohos.app.ability.appManager.d.ts index 0dd30a6d143eaa3f187c8c954cb92e932df7ca89..1ebed985abd49be5b16984fc961a8aca5c5827b0 100644 --- a/api/@ohos.app.ability.appManager.d.ts +++ b/api/@ohos.app.ability.appManager.d.ts @@ -19,16 +19,23 @@ */ import { AsyncCallback } from './@ohos.base'; +import { ProcessInformation as _ProcessInformation } from './application/ProcessInformation'; +import bundleManager from './@ohos.bundle.bundleManager'; +import { RunningMultiAppInfo as _RunningMultiAppInfo } from './application/RunningMultiAppInfo'; +/*** if arkts 1.1 */ import * as _ApplicationStateObserver from './application/ApplicationStateObserver'; import type * as _AppForegroundStateObserver from './application/AppForegroundStateObserver'; import * as _AbilityStateData from './application/AbilityStateData'; -import * as _AppStateData from './application/AppStateData'; +import * as _AppStateData from './application/AppStateData'; import type * as _ProcessData from './application/ProcessData'; -import { ProcessInformation as _ProcessInformation } from './application/ProcessInformation'; import * as _AbilityFirstFrameStateObserver from './application/AbilityFirstFrameStateObserver'; import * as _AbilityFirstFrameStateData from './application/AbilityFirstFrameStateData'; -import bundleManager from './@ohos.bundle.bundleManager'; -import { RunningMultiAppInfo as _RunningMultiAppInfo } from './application/RunningMultiAppInfo'; +/*** endif */ +/*** if arkts 1.2 */ +import _ApplicationStateObserver from './application/ApplicationStateObserver'; +import _AbilityStateData from './application/AbilityStateData'; +import _AppStateData from './application/AppStateData'; +/*** endif */ /** * This module provides the function of app manager service. @@ -43,7 +50,8 @@ import { RunningMultiAppInfo as _RunningMultiAppInfo } from './application/Runni * @namespace appManager * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ declare namespace appManager { /** @@ -52,7 +60,8 @@ declare namespace appManager { * @enum { number } * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ export enum ApplicationState { /** @@ -60,7 +69,8 @@ declare namespace appManager { * * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ STATE_CREATE, @@ -69,7 +79,8 @@ declare namespace appManager { * * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ STATE_FOREGROUND, @@ -87,7 +98,8 @@ declare namespace appManager { * * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ STATE_BACKGROUND, @@ -96,7 +108,8 @@ declare namespace appManager { * * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ STATE_DESTROY } @@ -114,7 +127,8 @@ declare namespace appManager { * @enum { number } * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ export enum ProcessState { /** @@ -128,7 +142,8 @@ declare namespace appManager { * * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ STATE_CREATE, @@ -143,7 +158,8 @@ declare namespace appManager { * * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ STATE_FOREGROUND, @@ -158,7 +174,8 @@ declare namespace appManager { * * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ STATE_ACTIVE, @@ -173,7 +190,8 @@ declare namespace appManager { * * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ STATE_BACKGROUND, @@ -188,7 +206,8 @@ declare namespace appManager { * * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ STATE_DESTROY } @@ -200,7 +219,8 @@ declare namespace appManager { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi * @stagemodelonly - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ export enum PreloadMode { /** @@ -209,7 +229,8 @@ declare namespace appManager { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi * @stagemodelonly - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ PRESS_DOWN } @@ -483,7 +504,8 @@ declare namespace appManager { * @throws { BusinessError } 16000050 - Internal error. * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getForegroundApplications(callback: AsyncCallback>): void; @@ -497,7 +519,8 @@ declare namespace appManager { * @throws { BusinessError } 16000050 - Internal error. * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getForegroundApplications(): Promise>; @@ -849,7 +872,8 @@ declare namespace appManager { * @throws { BusinessError } 16000050 - Internal error. * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ function getRunningProcessInformation(): Promise>; @@ -892,7 +916,8 @@ declare namespace appManager { * @throws { BusinessError } 16000050 - Internal error. * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ function getRunningProcessInformation(callback: AsyncCallback>): void; @@ -974,7 +999,8 @@ declare namespace appManager { * @throws { BusinessError } 16000050 - Internal error. * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ function getRunningProcessInfoByBundleName(bundleName: string, callback: AsyncCallback>): void; @@ -990,7 +1016,8 @@ declare namespace appManager { * @throws { BusinessError } 16000050 - Internal error. * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ function getRunningProcessInfoByBundleName(bundleName: string, userId: number, callback: AsyncCallback>): void; @@ -1005,7 +1032,8 @@ declare namespace appManager { * @throws { BusinessError } 16000050 - Internal error. * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ function getRunningProcessInfoByBundleName(bundleName: string): Promise>; @@ -1021,7 +1049,8 @@ declare namespace appManager { * @throws { BusinessError } 16000050 - Internal error. * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ function getRunningProcessInfoByBundleName(bundleName: string, userId: number): Promise>; @@ -1097,7 +1126,8 @@ declare namespace appManager { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi * @stagemodelonly - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ function getRunningMultiAppInfo(bundleName: string): Promise; @@ -1288,6 +1318,16 @@ declare namespace appManager { */ export type AppStateData = _AppStateData.default; + /** + * The application state data. + * + * @typedef { _AppStateData } + * @syscap SystemCapability.Ability.AbilityRuntime.Core + * @since 20 + * @arkts 1.2 + */ + export type AppStateData = _AppStateData; + /** * The application state observer. * @@ -1319,7 +1359,8 @@ declare namespace appManager { * @typedef { _ProcessInformation } * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ export type ProcessInformation = _ProcessInformation; @@ -1358,7 +1399,8 @@ declare namespace appManager { * @typedef { _RunningMultiAppInfo } * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ export type RunningMultiAppInfo = _RunningMultiAppInfo; } diff --git a/api/@ohos.app.ability.application.d.ts b/api/@ohos.app.ability.application.d.ts index 37e58fa584adf1b195dba1ea5be8e3b2e3ede103..9f2e8f15fa7689771308c2142257160034aad82a 100644 --- a/api/@ohos.app.ability.application.d.ts +++ b/api/@ohos.app.ability.application.d.ts @@ -28,7 +28,8 @@ import Context from './application/Context'; * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ declare namespace application { /** @@ -41,7 +42,8 @@ declare namespace application { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ export function createModuleContext(context: Context, moduleName: string): Promise; @@ -59,7 +61,8 @@ declare namespace application { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi * @stagemodelonly - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ export function createModuleContext(context: Context, bundleName: string, moduleName: string): Promise; @@ -89,7 +92,8 @@ declare namespace application { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi * @stagemodelonly - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ export function createBundleContext(context: Context, bundleName: string): Promise; diff --git a/api/@ohos.app.ability.insightIntent.d.ts b/api/@ohos.app.ability.insightIntent.d.ts index 15573c0ef29db9410e5eebf11538039d6216eead..c8f75ce1d14eba4cf3b5c1c8ec002ac1902b6776 100644 --- a/api/@ohos.app.ability.insightIntent.d.ts +++ b/api/@ohos.app.ability.insightIntent.d.ts @@ -28,7 +28,8 @@ import type wantConstant from './@ohos.app.ability.wantConstant'; * @syscap SystemCapability.Ability.AbilityRuntime.Core * @StageModelOnly * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ declare namespace insightIntent { /** @@ -38,7 +39,8 @@ declare namespace insightIntent { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @StageModelOnly * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ enum ExecuteMode { /** @@ -47,7 +49,8 @@ declare namespace insightIntent { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @StageModelOnly * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ UI_ABILITY_FOREGROUND = 0, @@ -57,7 +60,8 @@ declare namespace insightIntent { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @StageModelOnly * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ UI_ABILITY_BACKGROUND = 1, @@ -66,7 +70,8 @@ declare namespace insightIntent { * * @syscap SystemCapability.Ability.AbilityRuntime.Core * @StageModelOnly - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ UI_EXTENSION_ABILITY = 2, @@ -76,7 +81,8 @@ declare namespace insightIntent { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi * @StageModelOnly - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ SERVICE_EXTENSION_ABILITY = 3, } @@ -88,7 +94,8 @@ declare namespace insightIntent { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @StageModelOnly * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ interface ExecuteResult { /** @@ -98,7 +105,8 @@ declare namespace insightIntent { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @StageModelOnly * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ code: number; @@ -109,7 +117,8 @@ declare namespace insightIntent { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @StageModelOnly * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ result?: Record; @@ -120,7 +129,8 @@ declare namespace insightIntent { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly * @atomicservice - * @since 18 + * @since arkts {'1.1':'18', '1.2':'20'} + * @arkts 1.1&1.2 */ uris?: Array; @@ -135,7 +145,8 @@ declare namespace insightIntent { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly * @atomicservice - * @since 18 + * @since arkts {'1.1':'18', '1.2':'20'} + * @arkts 1.1&1.2 */ flags?: number; } diff --git a/api/@ohos.app.ability.insightIntentDriver.d.ts b/api/@ohos.app.ability.insightIntentDriver.d.ts index df8657ac8f734fc3013c48cc0bc649ee2db3b102..239235e18339309f3d9a64329524577e9ef3f6ce 100644 --- a/api/@ohos.app.ability.insightIntentDriver.d.ts +++ b/api/@ohos.app.ability.insightIntentDriver.d.ts @@ -30,7 +30,8 @@ import type insightIntent from './@ohos.app.ability.insightIntent'; * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi * @StageModelOnly - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ declare namespace insightIntentDriver { /** @@ -40,7 +41,8 @@ declare namespace insightIntentDriver { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi * @StageModelOnly - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ interface ExecuteParam { /** @@ -50,7 +52,8 @@ declare namespace insightIntentDriver { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi * @StageModelOnly - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ bundleName: string; @@ -61,7 +64,8 @@ declare namespace insightIntentDriver { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi * @StageModelOnly - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ moduleName: string; @@ -72,7 +76,8 @@ declare namespace insightIntentDriver { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi * @StageModelOnly - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ abilityName: string; @@ -83,7 +88,8 @@ declare namespace insightIntentDriver { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi * @StageModelOnly - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ insightIntentName: string; @@ -94,7 +100,8 @@ declare namespace insightIntentDriver { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi * @StageModelOnly - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ insightIntentParam: Record; @@ -105,7 +112,8 @@ declare namespace insightIntentDriver { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi * @StageModelOnly - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ executeMode: insightIntent.ExecuteMode; @@ -116,7 +124,8 @@ declare namespace insightIntentDriver { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi * @StageModelOnly - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ displayId?: number; @@ -127,7 +136,8 @@ declare namespace insightIntentDriver { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi * @stagemodelonly - * @since 18 + * @since arkts {'1.1':'18', '1.2':'20'} + * @arkts 1.1&1.2 */ uris?: Array; @@ -142,7 +152,8 @@ declare namespace insightIntentDriver { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi * @stagemodelonly - * @since 18 + * @since arkts {'1.1':'18', '1.2':'20'} + * @arkts 1.1&1.2 */ flags?: number; } @@ -177,7 +188,8 @@ declare namespace insightIntentDriver { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi * @StageModelOnly - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ function execute(param: ExecuteParam, callback: AsyncCallback): void; @@ -211,7 +223,8 @@ declare namespace insightIntentDriver { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi * @StageModelOnly - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ function execute(param: ExecuteParam): Promise; diff --git a/api/@ohos.app.ability.wantAgent.d.ts b/api/@ohos.app.ability.wantAgent.d.ts index 7f6e272894901edcf76f0032dbbbf8b8d0658876..f61ab3080be00821d2ca6533c43c768ba5645028 100644 --- a/api/@ohos.app.ability.wantAgent.d.ts +++ b/api/@ohos.app.ability.wantAgent.d.ts @@ -20,9 +20,12 @@ import { AsyncCallback, Callback } from './@ohos.base'; import Want from './@ohos.app.ability.Want'; -import { WantAgentInfo as _WantAgentInfo, LocalWantAgentInfo as _LocalWantAgentInfo } from './wantAgent/wantAgentInfo'; +import { WantAgentInfo as _WantAgentInfo } from './wantAgent/wantAgentInfo'; import { TriggerInfo as _TriggerInfo } from './wantAgent/triggerInfo'; import Context from './application/Context'; +/*** if arkts 1.1 */ +import { LocalWantAgentInfo as _LocalWantAgentInfo } from './wantAgent/wantAgentInfo'; +/*** endif */ /** * Provide the method obtain trigger, cancel, and compare and to obtain @@ -45,7 +48,8 @@ import Context from './application/Context'; * @namespace wantAgent * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ declare namespace wantAgent { /** @@ -72,7 +76,8 @@ declare namespace wantAgent { * @throws { BusinessError } 16000151 - Invalid wantAgent object. * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ function getBundleName(agent: WantAgent, callback: AsyncCallback): void; @@ -100,7 +105,8 @@ declare namespace wantAgent { * @throws { BusinessError } 16000151 - Invalid wantAgent object. * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ function getBundleName(agent: WantAgent): Promise; @@ -173,7 +179,8 @@ declare namespace wantAgent { * @throws { BusinessError } 16000151 - Invalid wantAgent object. * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getWant(agent: WantAgent, callback: AsyncCallback): void; @@ -190,7 +197,8 @@ declare namespace wantAgent { * @throws { BusinessError } 16000151 - Invalid wantAgent object. * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getWant(agent: WantAgent): Promise; @@ -218,7 +226,8 @@ declare namespace wantAgent { * @throws { BusinessError } 16000151 - Invalid wantAgent object. * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ function cancel(agent: WantAgent, callback: AsyncCallback): void; @@ -246,7 +255,8 @@ declare namespace wantAgent { * @throws { BusinessError } 16000151 - Invalid wantAgent object. * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ function cancel(agent: WantAgent): Promise; @@ -272,7 +282,8 @@ declare namespace wantAgent { * 2. Incorrect parameter types. * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ function trigger(agent: WantAgent, triggerInfo: TriggerInfo, callback?: AsyncCallback): void; @@ -322,7 +333,8 @@ declare namespace wantAgent { * 2. Incorrect parameter types. * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ function equal(agent: WantAgent, otherAgent: WantAgent, callback: AsyncCallback): void; @@ -350,7 +362,8 @@ declare namespace wantAgent { * 2. Incorrect parameter types. * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ function equal(agent: WantAgent, otherAgent: WantAgent): Promise; @@ -383,7 +396,8 @@ declare namespace wantAgent { * @throws { BusinessError } 16000151 - Invalid wantAgent object. * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ function getWantAgent(info: WantAgentInfo, callback: AsyncCallback): void; @@ -416,7 +430,8 @@ declare namespace wantAgent { * @throws { BusinessError } 16000151 - Invalid wantAgent object. * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ function getWantAgent(info: WantAgentInfo): Promise; @@ -446,7 +461,8 @@ declare namespace wantAgent { * @throws { BusinessError } 16000151 - Invalid wantAgent object. * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ function getOperationType(agent: WantAgent, callback: AsyncCallback): void; @@ -476,7 +492,8 @@ declare namespace wantAgent { * @throws { BusinessError } 16000151 - Invalid wantAgent object. * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ function getOperationType(agent: WantAgent): Promise; @@ -509,7 +526,6 @@ declare namespace wantAgent { * @systemapi * @stagemodelonly * @since 20 - * @arkts 1.1&1.2 */ function createLocalWantAgent(info: LocalWantAgentInfo): WantAgent; @@ -540,7 +556,8 @@ declare namespace wantAgent { * @enum { number } * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ export enum WantAgentFlags { /** @@ -555,7 +572,8 @@ declare namespace wantAgent { * * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ ONE_TIME_FLAG = 0, @@ -571,7 +589,8 @@ declare namespace wantAgent { * * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ NO_BUILD_FLAG, @@ -587,7 +606,8 @@ declare namespace wantAgent { * * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ CANCEL_PRESENT_FLAG, @@ -603,7 +623,8 @@ declare namespace wantAgent { * * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ UPDATE_PRESENT_FLAG, @@ -618,7 +639,8 @@ declare namespace wantAgent { * * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ CONSTANT_FLAG, @@ -638,7 +660,8 @@ declare namespace wantAgent { * * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ REPLACE_ELEMENT, @@ -658,7 +681,8 @@ declare namespace wantAgent { * * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ REPLACE_ACTION, @@ -678,7 +702,8 @@ declare namespace wantAgent { * * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ REPLACE_URI, @@ -698,7 +723,8 @@ declare namespace wantAgent { * * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ REPLACE_ENTITIES, @@ -718,7 +744,8 @@ declare namespace wantAgent { * * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ REPLACE_BUNDLE } @@ -736,7 +763,8 @@ declare namespace wantAgent { * @enum { number } * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ export enum OperationType { /** @@ -750,7 +778,8 @@ declare namespace wantAgent { * * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ UNKNOWN_TYPE = 0, @@ -765,7 +794,8 @@ declare namespace wantAgent { * * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ START_ABILITY, @@ -780,7 +810,8 @@ declare namespace wantAgent { * * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ START_ABILITIES, @@ -795,7 +826,8 @@ declare namespace wantAgent { * * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ START_SERVICE, @@ -810,7 +842,8 @@ declare namespace wantAgent { * * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ SEND_COMMON_EVENT, @@ -820,7 +853,8 @@ declare namespace wantAgent { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi * @stagemodelonly - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ START_SERVICE_EXTENSION = 6 } @@ -838,7 +872,8 @@ declare namespace wantAgent { * @typedef CompleteData * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ export interface CompleteData { /** @@ -947,7 +982,8 @@ declare namespace wantAgent { * @typedef { _TriggerInfo } * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ export type TriggerInfo = _TriggerInfo; @@ -964,7 +1000,8 @@ declare namespace wantAgent { * @typedef { _WantAgentInfo } * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ export type WantAgentInfo = _WantAgentInfo; @@ -975,7 +1012,6 @@ declare namespace wantAgent { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi * @since 20 - * @arkts 1.1&1.2 */ export type LocalWantAgentInfo = _LocalWantAgentInfo; @@ -986,7 +1022,8 @@ declare namespace wantAgent { * * @typedef { object } * @syscap SystemCapability.Ability.AbilityRuntime.Core - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ export type WantAgent = object; diff --git a/api/@ohos.app.ability.wantConstant.d.ts b/api/@ohos.app.ability.wantConstant.d.ts index 93fd9775fb6c54b4b5d96f8df256c52ed85579f2..3d81cfacb4f5681852bcce9e84e4a5d57125b781 100644 --- a/api/@ohos.app.ability.wantConstant.d.ts +++ b/api/@ohos.app.ability.wantConstant.d.ts @@ -48,7 +48,8 @@ declare namespace wantConstant { * @enum { string } * @syscap SystemCapability.Ability.AbilityBase * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ export enum Params { /** @@ -56,7 +57,8 @@ declare namespace wantConstant { * * @syscap SystemCapability.Ability.AbilityBase * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ DLP_PARAMS_SANDBOX = 'ohos.dlp.params.sandbox', @@ -65,7 +67,8 @@ declare namespace wantConstant { * * @syscap SystemCapability.Ability.AbilityBase * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ DLP_PARAMS_BUNDLE_NAME = 'ohos.dlp.params.bundleName', @@ -74,7 +77,8 @@ declare namespace wantConstant { * * @syscap SystemCapability.Ability.AbilityBase * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ DLP_PARAMS_MODULE_NAME = 'ohos.dlp.params.moduleName', @@ -83,7 +87,8 @@ declare namespace wantConstant { * * @syscap SystemCapability.Ability.AbilityBase * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ DLP_PARAMS_ABILITY_NAME = 'ohos.dlp.params.abilityName', @@ -92,7 +97,8 @@ declare namespace wantConstant { * * @syscap SystemCapability.Ability.AbilityBase * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ DLP_PARAMS_INDEX = 'ohos.dlp.params.index', @@ -101,7 +107,8 @@ declare namespace wantConstant { * * @syscap SystemCapability.Ability.AbilityBase * @systemapi - * @since 15 + * @since arkts {'1.1':'15', '1.2':'20'} + * @arkts 1.1&1.2 */ HIDE_SENSITIVE_TYPE = 'ohos.media.params.hideSensitiveType', @@ -118,7 +125,8 @@ declare namespace wantConstant { * * @syscap SystemCapability.Ability.AbilityBase * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ ABILITY_BACK_TO_OTHER_MISSION_STACK = 'ability.params.backToOtherMissionStack', @@ -133,7 +141,8 @@ declare namespace wantConstant { * * @syscap SystemCapability.Ability.AbilityBase * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ ABILITY_RECOVERY_RESTART = 'ohos.ability.params.abilityRecoveryRestart', @@ -148,7 +157,8 @@ declare namespace wantConstant { * * @syscap SystemCapability.Ability.AbilityBase * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ CONTENT_TITLE_KEY = 'ohos.extra.param.key.contentTitle', @@ -163,7 +173,8 @@ declare namespace wantConstant { * * @syscap SystemCapability.Ability.AbilityBase * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ SHARE_ABSTRACT_KEY = 'ohos.extra.param.key.shareAbstract', @@ -178,7 +189,8 @@ declare namespace wantConstant { * * @syscap SystemCapability.Ability.AbilityBase * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ SHARE_URL_KEY = 'ohos.extra.param.key.shareUrl', @@ -197,7 +209,8 @@ declare namespace wantConstant { * * @syscap SystemCapability.Ability.AbilityBase * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ SUPPORT_CONTINUE_PAGE_STACK_KEY = 'ohos.extra.param.key.supportContinuePageStack', @@ -216,7 +229,8 @@ declare namespace wantConstant { * * @syscap SystemCapability.Ability.AbilityBase * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ SUPPORT_CONTINUE_SOURCE_EXIT_KEY = 'ohos.extra.param.key.supportContinueSourceExit', @@ -226,7 +240,8 @@ declare namespace wantConstant { * @syscap SystemCapability.Ability.AbilityBase * @systemapi * @stagemodelonly - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ ASSERT_FAULT_SESSION_ID = 'ohos.ability.params.asssertFaultSessionId', @@ -235,7 +250,8 @@ declare namespace wantConstant { * * @syscap SystemCapability.Ability.AbilityBase * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ SHOW_MODE_KEY = 'ohos.extra.param.key.showMode', @@ -244,7 +260,8 @@ declare namespace wantConstant { * * @syscap SystemCapability.Ability.AbilityBase * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ PARAMS_STREAM = 'ability.params.stream', @@ -253,7 +270,8 @@ declare namespace wantConstant { * * @syscap SystemCapability.Ability.AbilityBase * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ APP_CLONE_INDEX_KEY = 'ohos.extra.param.key.appCloneIndex', @@ -262,7 +280,8 @@ declare namespace wantConstant { * * @syscap SystemCapability.Ability.AbilityBase * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ CALLER_REQUEST_CODE = 'ohos.extra.param.key.callerRequestCode', @@ -271,7 +290,8 @@ declare namespace wantConstant { * * @syscap SystemCapability.Ability.AbilityBase * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ PAGE_PATH = 'ohos.param.atomicservice.pagePath', @@ -280,7 +300,8 @@ declare namespace wantConstant { * * @syscap SystemCapability.Ability.AbilityBase * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ ROUTER_NAME = 'ohos.param.atomicservice.routerName', @@ -289,7 +310,8 @@ declare namespace wantConstant { * * @syscap SystemCapability.Ability.AbilityBase * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ PAGE_SOURCE_FILE = 'ohos.param.atomicservice.pageSourceFile', @@ -298,7 +320,8 @@ declare namespace wantConstant { * * @syscap SystemCapability.Ability.AbilityBase * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ BUILD_FUNCTION = 'ohos.param.atomicservice.buildFunction', @@ -307,7 +330,8 @@ declare namespace wantConstant { * * @syscap SystemCapability.Ability.AbilityBase * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ SUB_PACKAGE_NAME = 'ohos.param.atomicservice.subpackageName', @@ -315,7 +339,8 @@ declare namespace wantConstant { * Indicates the param of app instance key. * * @syscap SystemCapability.Ability.AbilityBase - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ APP_INSTANCE_KEY = 'ohos.extra.param.key.appInstance', @@ -323,7 +348,8 @@ declare namespace wantConstant { * Indicates the param of creating a new instance. * * @syscap SystemCapability.Ability.AbilityBase - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ CREATE_APP_INSTANCE_KEY = 'ohos.extra.param.key.createAppInstance', @@ -331,7 +357,8 @@ declare namespace wantConstant { * Indicates the app clone index of caller. * * @syscap SystemCapability.Ability.AbilityBase - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ CALLER_APP_CLONE_INDEX = 'ohos.param.callerAppCloneIndex', @@ -342,7 +369,8 @@ declare namespace wantConstant { * * @syscap SystemCapability.Ability.AbilityBase * @atomicservice - * @since 18 + * @since arkts {'1.1':'18', '1.2':'20'} + * @arkts 1.1&1.2 */ LAUNCH_REASON_MESSAGE = 'ohos.params.launchReasonMessage', @@ -434,7 +462,8 @@ declare namespace wantConstant { /** * Indicates that the URI can be persisted by the callee. * @syscap SystemCapability.Ability.AbilityBase - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ FLAG_AUTH_PERSISTABLE_URI_PERMISSION = 0x00000040, @@ -449,7 +478,8 @@ declare namespace wantConstant { * * @syscap SystemCapability.Ability.AbilityBase * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ FLAG_INSTALL_ON_DEMAND = 0x00000800, @@ -457,7 +487,8 @@ declare namespace wantConstant { * Collaborative target applications in the distributed scheduling system can be pulled up. * * @syscap SystemCapability.Ability.AbilityBase - * @since 18 + * @since arkts {'1.1':'18', '1.2':'20'} + * @arkts 1.1&1.2 */ FLAG_ABILITY_ON_COLLABORATE = 0x00002000, @@ -465,7 +496,8 @@ declare namespace wantConstant { * Indicates that if implicit start ability couldn't match any application, no tip dialog will be pulled up. * * @syscap SystemCapability.Ability.AbilityBase - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ FLAG_START_WITHOUT_TIPS = 0x40000000 } @@ -476,7 +508,8 @@ declare namespace wantConstant { * @enum { number } * @syscap SystemCapability.Ability.AbilityBase * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ export enum ShowMode { /** @@ -484,7 +517,8 @@ declare namespace wantConstant { * * @syscap SystemCapability.Ability.AbilityBase * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ WINDOW = 0, @@ -493,7 +527,8 @@ declare namespace wantConstant { * * @syscap SystemCapability.Ability.AbilityBase * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ EMBEDDED_FULL = 1 } diff --git a/api/@ohos.app.form.FormEditExtensionAbility.d.ts b/api/@ohos.app.form.FormEditExtensionAbility.d.ts index a89e2c08d055ead32fd028be7d9b66b2242c9b21..975799bfc661000fea2aab8c593f8ccf93ae5784 100644 --- a/api/@ohos.app.form.FormEditExtensionAbility.d.ts +++ b/api/@ohos.app.form.FormEditExtensionAbility.d.ts @@ -28,7 +28,7 @@ import FormEditExtensionContext from './application/FormEditExtensionContext'; * @stagemodelonly * @since 18 */ -export default class FormEditExtensionAbility extends UIExtensionAbility { +declare class FormEditExtensionAbility extends UIExtensionAbility { /** * Indicates configuration infomation about an form edit extension ability context. * @@ -39,3 +39,4 @@ export default class FormEditExtensionAbility extends UIExtensionAbility { */ context: FormEditExtensionContext; } +export default FormEditExtensionAbility; diff --git a/api/@ohos.app.form.FormExtensionAbility.d.ts b/api/@ohos.app.form.FormExtensionAbility.d.ts index f106f0c109bdec3c311236b84e249dbbf4de4c99..c7321cf67fcb8562c6c27f5983a87aa4f9773a0b 100644 --- a/api/@ohos.app.form.FormExtensionAbility.d.ts +++ b/api/@ohos.app.form.FormExtensionAbility.d.ts @@ -24,7 +24,21 @@ import formInfo from './@ohos.app.form.formInfo'; /*** endif */ import FormExtensionContext from './application/FormExtensionContext'; import Want from './@ohos.app.ability.Want'; +/*** if arkts 1.1 */ import { Configuration } from './@ohos.app.ability.Configuration'; +/*** endif */ + +/** + * Called when this ability breaks the last link, notifying the provider that the provider process is about to stop. + * + * @typedef { function } + * @syscap SystemCapability.Ability.Form + * @stagemodelonly + * @atomicservice + * @since 20 + * @arkts 1.2 + */ +type OnStopFn = () => void; /** * class of form extension. @@ -159,7 +173,7 @@ declare class FormExtensionAbility { /** * Called when the form provider receives form events from the system. * - * @param { Record } newStatus - Indicates the form events occurred. The key in the {@code Map} + * @param { Record } newStatus - Indicates the form events occurred. The key in the {@code Map} * object indicates the form ID, and the value indicates the event * type, which can be either * {@link formInfo#VisibilityType#FORM_VISIBLE} or @@ -173,7 +187,7 @@ declare class FormExtensionAbility { * @since arkts {'1.1':'11', '1.2':'20'} * @arkts 1.1&1.2 */ - onChangeFormVisibility(newStatus: Record): void; + onChangeFormVisibility(newStatus: Record): void; /** * Called when a specified message event defined by the form provider is triggered. This method is valid only for @@ -327,6 +341,18 @@ declare class FormExtensionAbility { */ onStop?(): void; + /** + * Called when this ability breaks the last link, notifying the provider that the provider process is about to stop. + * + * @type { ?OnStopFn } + * @syscap SystemCapability.Ability.Form + * @stagemodelonly + * @atomicservice + * @since 20 + * @arkts 1.2 + */ + onStop?: OnStopFn; + /** * Called to notify the form provider that the form location of the form has been changed. * diff --git a/api/@ohos.app.form.LiveFormExtensionAbility.d.ts b/api/@ohos.app.form.LiveFormExtensionAbility.d.ts index 88ad4daeaac08d994b22cb9c941b8fd20f32eb62..8a47a1405c87d992c52837c2f560b3e4fbf8e2b4 100644 --- a/api/@ohos.app.form.LiveFormExtensionAbility.d.ts +++ b/api/@ohos.app.form.LiveFormExtensionAbility.d.ts @@ -75,7 +75,7 @@ export interface LiveFormInfo { * @atomicservice * @since 20 */ -export default class LiveFormExtensionAbility extends ExtensionAbility { +declare class LiveFormExtensionAbility extends ExtensionAbility { /** * Indicates configuration information about a live form extension ability context. * @@ -109,4 +109,5 @@ export default class LiveFormExtensionAbility extends ExtensionAbility { * @since 20 */ onLiveFormDestroy(liveFormInfo: LiveFormInfo): void; -} \ No newline at end of file +} +export default LiveFormExtensionAbility; diff --git a/api/@ohos.app.form.formBindingData.d.ts b/api/@ohos.app.form.formBindingData.d.ts index 3cdd10aaac65dc01c36e412f979adbf9212d8771..356ef5858a53dec459c75e34a69037bc4622cc86 100644 --- a/api/@ohos.app.form.formBindingData.d.ts +++ b/api/@ohos.app.form.formBindingData.d.ts @@ -16,12 +16,9 @@ /** * @file * @kit FormKit + * @arkts 1.1&1.2 */ -/*** if arkts 1.1 */ -import { BusinessError } from './@ohos.base'; -/*** endif */ - /** * Interface of formBindingData. * @@ -93,7 +90,8 @@ declare namespace formBindingData { * @type { Object } * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ data: Object; @@ -112,7 +110,8 @@ declare namespace formBindingData { * @syscap SystemCapability.Ability.Form * @StageModelOnly * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ proxies?: Array; } @@ -132,7 +131,8 @@ declare namespace formBindingData { * @syscap SystemCapability.Ability.Form * @StageModelOnly * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ interface ProxyData { /** @@ -150,7 +150,8 @@ declare namespace formBindingData { * @syscap SystemCapability.Ability.Form * @StageModelOnly * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ key: string; @@ -169,7 +170,8 @@ declare namespace formBindingData { * @syscap SystemCapability.Ability.Form * @StageModelOnly * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ subscriberId?: string; } diff --git a/api/@ohos.app.form.formHost.d.ts b/api/@ohos.app.form.formHost.d.ts index ab3638953eb2a52dc57fe6f15789690767741b8b..12eb8ddc62f26ade4aa735d4ca31223d546c263a 100644 --- a/api/@ohos.app.form.formHost.d.ts +++ b/api/@ohos.app.form.formHost.d.ts @@ -617,7 +617,7 @@ declare namespace formHost { * * @permission ohos.permission.REQUIRE_FORM * @param { Array } formIds - Indicates the specified form id. - * @param { AsyncCallback } callback - The callback is used to return the number of invalid forms deleted + * @param { AsyncCallback } callback - The callback is used to return the number of invalid forms deleted * by the Form Manager Service. * @throws { BusinessError } 201 - Permissions denied. * @throws { BusinessError } 202 - The application is not a system application. @@ -630,7 +630,7 @@ declare namespace formHost { * @systemapi * @since 9 */ - function deleteInvalidForms(formIds: Array, callback: AsyncCallback): void; + function deleteInvalidForms(formIds: Array, callback: AsyncCallback): void; /** * Deletes invalid forms of the application in the Form Manager Service based on the list of. @@ -638,7 +638,7 @@ declare namespace formHost { * * @permission ohos.permission.REQUIRE_FORM * @param { Array } formIds - Indicates the specified form id. - * @returns { Promise } Returns the number of invalid forms deleted by the Form Manager Service. + * @returns { Promise } Returns the number of invalid forms deleted by the Form Manager Service. * @throws { BusinessError } 201 - Permissions denied. * @throws { BusinessError } 202 - The application is not a system application. * @throws { BusinessError } 401 - Parameter error. Possible causes: @@ -650,7 +650,7 @@ declare namespace formHost { * @systemapi * @since 9 */ - function deleteInvalidForms(formIds: Array): Promise; + function deleteInvalidForms(formIds: Array): Promise; /** * Obtains the Form state. diff --git a/api/@ohos.app.form.formInfo.d.ts b/api/@ohos.app.form.formInfo.d.ts index 72db9a2b3740f901e686d0defb46db5ba577c51a..a1d033a4df471ee276132b6fa398069705cdbce0 100644 --- a/api/@ohos.app.form.formInfo.d.ts +++ b/api/@ohos.app.form.formInfo.d.ts @@ -33,7 +33,8 @@ import Want from './@ohos.app.ability.Want'; * @namespace formInfo * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ declare namespace formInfo { /** @@ -49,7 +50,8 @@ declare namespace formInfo { * @typedef FormInfo * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ interface FormInfo { /** @@ -65,7 +67,8 @@ declare namespace formInfo { * @type { string } * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ bundleName: string; @@ -82,7 +85,8 @@ declare namespace formInfo { * @type { string } * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ moduleName: string; @@ -99,7 +103,8 @@ declare namespace formInfo { * @type { string } * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ abilityName: string; @@ -116,7 +121,8 @@ declare namespace formInfo { * @type { string } * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ name: string; @@ -126,19 +132,21 @@ declare namespace formInfo { * @type { string } * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ displayName: string; /** * Obtains the displayName resource id of this form. * - * @type { number } + * @type { int } * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ - displayNameId: number; + displayNameId: int; /** * Obtains the description of this form. @@ -153,26 +161,28 @@ declare namespace formInfo { * @type { string } * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ description: string; /** * Obtains the description id of this form. * - * @type { number } + * @type { int } * @syscap SystemCapability.Ability.Form * @since 10 */ /** * Obtains the description id of this form. * - * @type { number } + * @type { int } * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ - descriptionId: number; + descriptionId: int; /** * Obtains the type of this form. Currently, JS forms are supported. @@ -187,7 +197,8 @@ declare namespace formInfo { * @type { FormType } * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ type: FormType; @@ -204,7 +215,8 @@ declare namespace formInfo { * @type { string } * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ jsComponentName: string; @@ -226,17 +238,6 @@ declare namespace formInfo { */ colorMode: ColorMode; - /** - * Obtains the rendering mode of the form. - * - * @type { ?RenderingMode } - * @readonly - * @syscap SystemCapability.Ability.Form - * @systemapi - * @since 18 - */ - readonly renderingMode?: RenderingMode; - /** * Checks whether this form is a default form. * @@ -250,7 +251,8 @@ declare namespace formInfo { * @type { boolean } * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ isDefault: boolean; @@ -267,7 +269,8 @@ declare namespace formInfo { * @type { boolean } * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ updateEnabled: boolean; @@ -284,7 +287,8 @@ declare namespace formInfo { * @type { boolean } * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ formVisibleNotify: boolean; @@ -301,7 +305,8 @@ declare namespace formInfo { * @type { string } * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ scheduledUpdateTime: string; @@ -318,60 +323,64 @@ declare namespace formInfo { * @type { string } * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ formConfigAbility: string; /** * Obtains the updateDuration. * - * @type { number } + * @type { int } * @syscap SystemCapability.Ability.Form * @since 9 */ /** * Obtains the updateDuration. * - * @type { number } + * @type { int } * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ - updateDuration: number; + updateDuration: int; /** * Obtains the default grid style of this form. * - * @type { number } + * @type { int } * @syscap SystemCapability.Ability.Form * @since 9 */ /** * Obtains the default grid style of this form. * - * @type { number } + * @type { int } * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ - defaultDimension: number; + defaultDimension: int; /** * Obtains the grid styles supported by this form. * - * @type { Array } + * @type { Array } * @syscap SystemCapability.Ability.Form * @since 9 */ /** * Obtains the grid styles supported by this form. * - * @type { Array } + * @type { Array } * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ - supportDimensions: Array; + supportDimensions: Array; /** * Obtains the custom data defined in this form. @@ -386,7 +395,8 @@ declare namespace formInfo { * @type { Record } * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ customizeData: Record; @@ -403,7 +413,8 @@ declare namespace formInfo { * @type { boolean } * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ isDynamic: boolean; @@ -414,31 +425,34 @@ declare namespace formInfo { * @default false * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ transparencyEnabled: boolean; /** * Obtains the shape supported by this form. * - * @type { Array } + * @type { Array } * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ - supportedShapes: Array; + supportedShapes: Array; /** * Indicates the form previewImage IDs map corresponds to the \"supportDimensions\". * - * @type { ?Array } + * @type { ?Array } * @readonly * @syscap SystemCapability.Ability.Form * @systemapi * @atomicservice - * @since 18 + * @since arkts {'1.1':'18', '1.2':'20'} + * @arkts 1.1&1.2 */ - readonly previewImages?: Array; + readonly previewImages?: Array; /** * Indicates whether the form uses a blur background provided by the form host. @@ -447,47 +461,78 @@ declare namespace formInfo { * @readonly * @syscap SystemCapability.Ability.Form * @systemapi - * @since 18 + * @since arkts {'1.1':'18', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly enableBlurBackground?: boolean; /** - * Indicates the fun interaction form params + * Obtains the rendering mode of the form. * - * @type { ?FunInteractionParams } + * @type { ?RenderingMode } * @readonly * @syscap SystemCapability.Ability.Form * @systemapi - * @since 20 + * @since arkts {'1.1':'18', '1.2':'20'} + * @arkts 1.1&1.2 */ - readonly funInteractionParams?: FunInteractionParams; + readonly renderingMode?: RenderingMode; + } + /** + * Rendering mode. + * + * @enum { int } + * @syscap SystemCapability.Ability.Form + * @systemapi + * @since arkts {'1.1':'18', '1.2':'20'} + * @arkts 1.1&1.2 + */ + enum RenderingMode { /** - * Indicates the scene animation form params + * Auto color mode. * - * @type { ?SceneAnimationParams } - * @readonly * @syscap SystemCapability.Ability.Form * @systemapi - * @since 20 + * @since arkts {'1.1':'18', '1.2':'20'} + * @arkts 1.1&1.2 */ - readonly sceneAnimationParams?: SceneAnimationParams; + AUTO_COLOR = 0, + /** + * Full color mode. + * + * @syscap SystemCapability.Ability.Form + * @systemapi + * @since arkts {'1.1':'18', '1.2':'20'} + * @arkts 1.1&1.2 + */ + FULL_COLOR = 1, + /** + * Single color mode. + * + * @syscap SystemCapability.Ability.Form + * @systemapi + * @since arkts {'1.1':'18', '1.2':'20'} + * @arkts 1.1&1.2 + */ + SINGLE_COLOR = 2 } /** * Type of form. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Ability.Form * @since 9 */ /** * Type of form. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ enum FormType { /** @@ -501,7 +546,8 @@ declare namespace formInfo { * * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ JS = 1, @@ -516,7 +562,8 @@ declare namespace formInfo { * * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ eTS = 2 } @@ -524,14 +571,14 @@ declare namespace formInfo { /** * Color mode. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Ability.Form * @since 9 */ /** * Color mode. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Ability.Form * @atomicservice * @since 11 @@ -550,6 +597,7 @@ declare namespace formInfo { * @syscap SystemCapability.Ability.Form * @atomicservice * @since 11 + * @deprecated since 20 */ MODE_AUTO = -1, @@ -565,6 +613,7 @@ declare namespace formInfo { * @syscap SystemCapability.Ability.Form * @atomicservice * @since 11 + * @deprecated since 20 */ MODE_DARK = 0, @@ -580,47 +629,11 @@ declare namespace formInfo { * @syscap SystemCapability.Ability.Form * @atomicservice * @since 11 + * @deprecated since 20 */ MODE_LIGHT = 1 } - /** - * Rendering mode. - * - * @enum { number } - * @syscap SystemCapability.Ability.Form - * @systemapi - * @since 18 - */ - enum RenderingMode { - /** - * Auto color mode. - * - * @syscap SystemCapability.Ability.Form - * @systemapi - * @since 18 - */ - AUTO_COLOR = 0, - - /** - * Full color mode. - * - * @syscap SystemCapability.Ability.Form - * @systemapi - * @since 18 - */ - FULL_COLOR = 1, - - /** - * Single color mode. - * - * @syscap SystemCapability.Ability.Form - * @systemapi - * @since 18 - */ - SINGLE_COLOR = 2 - } - /** * Provides state information about a form. * @@ -634,7 +647,8 @@ declare namespace formInfo { * @typedef FormStateInfo * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ interface FormStateInfo { /** @@ -650,7 +664,8 @@ declare namespace formInfo { * @type { FormState } * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ formState: FormState; @@ -667,7 +682,8 @@ declare namespace formInfo { * @type { Want } * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ want: Want; } @@ -675,17 +691,18 @@ declare namespace formInfo { /** * Provides state about a form. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Ability.Form * @since 9 */ /** * Provides state about a form. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ enum FormState { /** @@ -699,7 +716,8 @@ declare namespace formInfo { * * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ UNKNOWN = -1, @@ -714,7 +732,8 @@ declare namespace formInfo { * * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ DEFAULT = 0, @@ -729,7 +748,8 @@ declare namespace formInfo { * * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ READY = 1 } @@ -747,7 +767,8 @@ declare namespace formInfo { * @enum { string } * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ enum FormParam { /** @@ -771,9 +792,10 @@ declare namespace formInfo { * * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ - IDENTITY_KEY = 'ohos.extra.param.key.form_identity', + IDENTITY_KEY = "ohos.extra.param.key.form_identity", /** * Indicates the key specifying the grid style of the form to be obtained, which is represented as @@ -796,9 +818,10 @@ declare namespace formInfo { * * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ - DIMENSION_KEY = 'ohos.extra.param.key.form_dimension', + DIMENSION_KEY = "ohos.extra.param.key.form_dimension", /** * Indicates the key specifying the name of the form to be obtained, which is represented as @@ -821,9 +844,10 @@ declare namespace formInfo { * * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ - NAME_KEY = 'ohos.extra.param.key.form_name', + NAME_KEY = "ohos.extra.param.key.form_name", /** * Indicates the key specifying the name of the module to which the form to be obtained belongs, which is @@ -850,9 +874,10 @@ declare namespace formInfo { * * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ - MODULE_NAME_KEY = 'ohos.extra.param.key.module_name', + MODULE_NAME_KEY = "ohos.extra.param.key.module_name", /** * Indicates the key specifying the width of the form to be obtained, which is represented as @@ -875,9 +900,10 @@ declare namespace formInfo { * * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ - WIDTH_KEY = 'ohos.extra.param.key.form_width', + WIDTH_KEY = "ohos.extra.param.key.form_width", /** * Indicates the key specifying the height of the form to be obtained, which is represented as @@ -900,9 +926,10 @@ declare namespace formInfo { * * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ - HEIGHT_KEY = 'ohos.extra.param.key.form_height', + HEIGHT_KEY = "ohos.extra.param.key.form_height", /** * Indicates the key specifying whether a form is temporary, which is represented as @@ -925,9 +952,10 @@ declare namespace formInfo { * * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ - TEMPORARY_KEY = 'ohos.extra.param.key.form_temporary', + TEMPORARY_KEY = "ohos.extra.param.key.form_temporary", /** * Indicates the key specifying the name of the bundle to be obtained, which is represented as @@ -950,9 +978,10 @@ declare namespace formInfo { * * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ - BUNDLE_NAME_KEY = 'ohos.extra.param.key.bundle_name', + BUNDLE_NAME_KEY = "ohos.extra.param.key.bundle_name", /** * Indicates the key specifying the name of the ability to be obtained, which is represented as @@ -975,9 +1004,10 @@ declare namespace formInfo { * * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ - ABILITY_NAME_KEY = 'ohos.extra.param.key.ability_name', + ABILITY_NAME_KEY = "ohos.extra.param.key.ability_name", /** * Indicates the key specifying whether a form type is theme, which is represented as @@ -989,7 +1019,8 @@ declare namespace formInfo { * * @syscap SystemCapability.Ability.Form * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ THEME_KEY = 'ohos.extra.param.key.form_is_theme', @@ -1003,9 +1034,10 @@ declare namespace formInfo { * * @syscap SystemCapability.Ability.Form * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ - DEVICE_ID_KEY = 'ohos.extra.param.key.device_id', + DEVICE_ID_KEY = "ohos.extra.param.key.device_id", /** * Indicates the key specifying the launch reason of the form to be obtained, which is represented as @@ -1028,9 +1060,10 @@ declare namespace formInfo { * * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ - LAUNCH_REASON_KEY = 'ohos.extra.param.key.form_launch_reason', + LAUNCH_REASON_KEY = "ohos.extra.param.key.form_launch_reason", /** * Indicates the key specifying the custom data of the form to be obtained, which is represented as @@ -1057,9 +1090,10 @@ declare namespace formInfo { * * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ - PARAM_FORM_CUSTOMIZE_KEY = 'ohos.extra.param.key.form_customize', + PARAM_FORM_CUSTOMIZE_KEY = "ohos.extra.param.key.form_customize", /** * Indicates the key specifying the form location, which is represented as @@ -1070,7 +1104,8 @@ declare namespace formInfo { * }. * * @syscap SystemCapability.Ability.Form - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ FORM_LOCATION_KEY = 'ohos.extra.param.key.form_location', @@ -1095,7 +1130,8 @@ declare namespace formInfo { * * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ FORM_RENDERING_MODE_KEY = 'ohos.extra.param.key.form_rendering_mode', @@ -1109,7 +1145,8 @@ declare namespace formInfo { * * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ HOST_BG_INVERSE_COLOR_KEY = 'ohos.extra.param.key.host_bg_inverse_color', @@ -1123,7 +1160,8 @@ declare namespace formInfo { * * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ FORM_PERMISSION_NAME_KEY = 'ohos.extra.param.key.permission_name', @@ -1137,7 +1175,8 @@ declare namespace formInfo { * * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ FORM_PERMISSION_GRANTED_KEY = 'ohos.extra.param.key.permission_granted', } @@ -1157,7 +1196,8 @@ declare namespace formInfo { * @typedef FormInfoFilter * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ interface FormInfoFilter { /** @@ -1167,7 +1207,8 @@ declare namespace formInfo { * @type { ?string } * @syscap SystemCapability.Ability.Form * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ bundleName?: string; @@ -1186,7 +1227,8 @@ declare namespace formInfo { * @type { ?string } * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ moduleName?: string; @@ -1194,39 +1236,42 @@ declare namespace formInfo { * optional supportedDimensions that used to ask getFormsInfo to return * form infos with the same supportedDimensions. * - * @type { ?Array } + * @type { ?Array } * @syscap SystemCapability.Ability.Form * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ - supportedDimensions?: Array; + supportedDimensions?: Array; /** * optional supportedShapes that used to ask getFormsInfo to return * form infos with the same supportedShapes. * - * @type { ?Array } + * @type { ?Array } * @syscap SystemCapability.Ability.Form * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ - supportedShapes?: Array; + supportedShapes?: Array; } /** * Defines the FormDimension enum. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Ability.Form * @since 9 */ /** * Defines the FormDimension enum. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ enum FormDimension { /** @@ -1240,7 +1285,8 @@ declare namespace formInfo { * * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ Dimension_1_2 = 1, @@ -1255,9 +1301,10 @@ declare namespace formInfo { * * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ - Dimension_2_2, + Dimension_2_2 = 2, /** * 2 x 4 form @@ -1270,9 +1317,10 @@ declare namespace formInfo { * * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ - Dimension_2_4, + Dimension_2_4 = 3, /** * 4 x 4 form @@ -1285,9 +1333,10 @@ declare namespace formInfo { * * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ - Dimension_4_4, + Dimension_4_4 = 4, /** * 2 x 1 form @@ -1301,33 +1350,37 @@ declare namespace formInfo { * @syscap SystemCapability.Ability.Form * @atomicservice * @since 11 + * @deprecated since 20 */ - Dimension_2_1, + Dimension_2_1 = 5, /** * 1 x 1 form * * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ - DIMENSION_1_1, + DIMENSION_1_1 = 6, /** * 6 x 4 form * * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ - DIMENSION_6_4, + DIMENSION_6_4 = 7, /** * 2 x 3 form used for wearable devices * * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 18 + * @since arkts {'1.1':'18', '1.2':'20'} + * @arkts 1.1&1.2 */ DIMENSION_2_3 = 8, @@ -1336,27 +1389,20 @@ declare namespace formInfo { * * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 18 + * @since arkts {'1.1':'18', '1.2':'20'} + * @arkts 1.1&1.2 */ - DIMENSION_3_3 = 9, - - /** - * 3 x 4 form used for tv devices - * - * @syscap SystemCapability.Ability.Form - * @atomicservice - * @since 18 - */ - DIMENSION_3_4 = 10, + DIMENSION_3_3 = 9 } - /** + /** * Defines the FormShape enum. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ enum FormShape { /** @@ -1364,7 +1410,8 @@ declare namespace formInfo { * * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ RECT = 1, @@ -1373,25 +1420,27 @@ declare namespace formInfo { * * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ - CIRCLE, + CIRCLE = 2 } /** * The visibility of a form. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Ability.Form * @since 9 */ /** * The visibility of a form. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ enum VisibilityType { /** @@ -1409,7 +1458,8 @@ declare namespace formInfo { * * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ UNKNOWN = 0, /** @@ -1427,7 +1477,8 @@ declare namespace formInfo { * * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ FORM_VISIBLE = 1, /** @@ -1445,25 +1496,27 @@ declare namespace formInfo { * * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ - FORM_INVISIBLE + FORM_INVISIBLE = 2 } /** * Indicates the launch reason of a form. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Ability.Form * @since 10 */ /** * Indicates the launch reason of a form. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ enum LaunchReason { /** @@ -1477,7 +1530,8 @@ declare namespace formInfo { * * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ FORM_DEFAULT = 1, /** @@ -1491,9 +1545,10 @@ declare namespace formInfo { * * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ - FORM_SHARE + FORM_SHARE = 2 } /** @@ -1503,7 +1558,8 @@ declare namespace formInfo { * @syscap SystemCapability.Ability.Form * @systemapi * @stagemodelonly - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ interface PublishFormResult { /** @@ -1513,7 +1569,8 @@ declare namespace formInfo { * @syscap SystemCapability.Ability.Form * @systemapi * @stagemodelonly - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ code: PublishFormErrorCode; @@ -1524,7 +1581,8 @@ declare namespace formInfo { * @syscap SystemCapability.Ability.Form * @systemapi * @stagemodelonly - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ message: string; } @@ -1532,11 +1590,12 @@ declare namespace formInfo { /** * The error code of publish form. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Ability.Form * @systemapi * @stagemodelonly - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ enum PublishFormErrorCode { /** @@ -1545,9 +1604,10 @@ declare namespace formInfo { * @syscap SystemCapability.Ability.Form * @systemapi * @stagemodelonly - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ - SUCCESS, + SUCCESS = 0, /** * Host has no space to publish form. @@ -1555,9 +1615,10 @@ declare namespace formInfo { * @syscap SystemCapability.Ability.Form * @systemapi * @stagemodelonly - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ - NO_SPACE, + NO_SPACE = 1, /** * Check param failed. @@ -1565,9 +1626,10 @@ declare namespace formInfo { * @syscap SystemCapability.Ability.Form * @systemapi * @stagemodelonly - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ - PARAM_ERROR, + PARAM_ERROR = 2, /** * Internal error occurs during form processing. @@ -1575,9 +1637,10 @@ declare namespace formInfo { * @syscap SystemCapability.Ability.Form * @systemapi * @stagemodelonly - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ - INTERNAL_ERROR, + INTERNAL_ERROR = 3 } /** @@ -1587,7 +1650,8 @@ declare namespace formInfo { * @syscap SystemCapability.Ability.Form * @systemapi * @stagemodelonly - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ interface FormProviderFilter { /** @@ -1597,7 +1661,8 @@ declare namespace formInfo { * @syscap SystemCapability.Ability.Form * @systemapi * @stagemodelonly - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ bundleName: string; @@ -1608,9 +1673,10 @@ declare namespace formInfo { * @syscap SystemCapability.Ability.Form * @systemapi * @stagemodelonly - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ - formName?: string; + formName ?: string; /** * Obtains the module name of the provider application module. @@ -1619,9 +1685,10 @@ declare namespace formInfo { * @syscap SystemCapability.Ability.Form * @systemapi * @stagemodelonly - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ - moduleName?: string; + moduleName ?: string; /** * Obtains the ability name of the provider application module. @@ -1630,9 +1697,10 @@ declare namespace formInfo { * @syscap SystemCapability.Ability.Form * @systemapi * @stagemodelonly - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ - abilityName?: string; + abilityName ?: string; /** * Indicates whether to include unused form. @@ -1642,7 +1710,8 @@ declare namespace formInfo { * @syscap SystemCapability.Ability.Form * @systemapi * @stagemodelonly - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ isUnusedIncluded?: boolean; } @@ -1653,7 +1722,8 @@ declare namespace formInfo { * @typedef RunningFormInfo * @syscap SystemCapability.Ability.Form * @systemapi hide this for inner system use - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ interface RunningFormInfo { /** @@ -1664,7 +1734,8 @@ declare namespace formInfo { * @default - * @syscap SystemCapability.Ability.Form * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly formId: string; @@ -1676,7 +1747,8 @@ declare namespace formInfo { * @default - * @syscap SystemCapability.Ability.Form * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly bundleName: string; @@ -1688,7 +1760,8 @@ declare namespace formInfo { * @default - * @syscap SystemCapability.Ability.Form * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly hostBundleName: string; @@ -1700,7 +1773,8 @@ declare namespace formInfo { * @default - * @syscap SystemCapability.Ability.Form * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly formLocation: FormLocation; @@ -1712,7 +1786,8 @@ declare namespace formInfo { * @default - * @syscap SystemCapability.Ability.Form * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly visibilityType: VisibilityType; @@ -1724,7 +1799,8 @@ declare namespace formInfo { * @default - * @syscap SystemCapability.Ability.Form * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly moduleName: string; @@ -1736,7 +1812,8 @@ declare namespace formInfo { * @default - * @syscap SystemCapability.Ability.Form * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly abilityName: string; @@ -1748,21 +1825,23 @@ declare namespace formInfo { * @default - * @syscap SystemCapability.Ability.Form * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly formName: string; /** * Obtains the grid style of this form. * - * @type { number } - * @readonly + * @type { int } * @default - + * @readonly * @syscap SystemCapability.Ability.Form * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ - readonly dimension: number; + readonly dimension: int; /** * Obtains the stage of form use. @@ -1772,7 +1851,8 @@ declare namespace formInfo { * @readonly * @syscap SystemCapability.Ability.Form * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly formUsageState: FormUsageState; @@ -1783,7 +1863,8 @@ declare namespace formInfo { * @readonly * @syscap SystemCapability.Ability.Form * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly formDescription: string; @@ -1795,7 +1876,8 @@ declare namespace formInfo { * @readonly * @syscap SystemCapability.Ability.Form * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly extraData?: Record; } @@ -1803,10 +1885,11 @@ declare namespace formInfo { /** * The stage of form use. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Ability.Form * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ enum FormUsageState { /** @@ -1814,7 +1897,8 @@ declare namespace formInfo { * * @syscap SystemCapability.Ability.Form * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ USED = 0, /** @@ -1822,15 +1906,16 @@ declare namespace formInfo { * * @syscap SystemCapability.Ability.Form * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ - UNUSED = 1, + UNUSED = 1 } /** * Defines the FormLocation enum. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Ability.Form * @systemapi * @since 12 @@ -1838,9 +1923,10 @@ declare namespace formInfo { /** * Defines the FormLocation enum. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Ability.Form * @since 20 + * @arkts 1.1&1.2 */ enum FormLocation { /** @@ -1848,7 +1934,8 @@ declare namespace formInfo { * * @syscap SystemCapability.Ability.Form * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ OTHER = -1, @@ -1864,6 +1951,7 @@ declare namespace formInfo { * * @syscap SystemCapability.Ability.Form * @since 20 + * @arkts 1.1&1.2 */ DESKTOP = 0, @@ -1879,6 +1967,7 @@ declare namespace formInfo { * * @syscap SystemCapability.Ability.Form * @since 20 + * @arkts 1.1&1.2 */ FORM_CENTER = 1, @@ -1894,6 +1983,7 @@ declare namespace formInfo { * * @syscap SystemCapability.Ability.Form * @since 20 + * @arkts 1.1&1.2 */ FORM_MANAGER = 2, @@ -1909,6 +1999,7 @@ declare namespace formInfo { * * @syscap SystemCapability.Ability.Form * @since 20 + * @arkts 1.1&1.2 */ NEGATIVE_SCREEN = 3, @@ -1917,7 +2008,8 @@ declare namespace formInfo { * * @syscap SystemCapability.Ability.Form * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ FORM_CENTER_NEGATIVE_SCREEN = 4, @@ -1926,7 +2018,8 @@ declare namespace formInfo { * * @syscap SystemCapability.Ability.Form * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ FORM_MANAGER_NEGATIVE_SCREEN = 5, @@ -1942,6 +2035,7 @@ declare namespace formInfo { * * @syscap SystemCapability.Ability.Form * @since 20 + * @arkts 1.1&1.2 */ SCREEN_LOCK = 6, @@ -1957,6 +2051,7 @@ declare namespace formInfo { * * @syscap SystemCapability.Ability.Form * @since 20 + * @arkts 1.1&1.2 */ AI_SUGGESTION = 7, } diff --git a/api/@ohos.app.form.formProvider.d.ts b/api/@ohos.app.form.formProvider.d.ts index 7bd2de5b9bae2f9b673b8df69291575c701182f0..02cf9ea01f3c56d0ee78677ad9452993c014fc1f 100644 --- a/api/@ohos.app.form.formProvider.d.ts +++ b/api/@ohos.app.form.formProvider.d.ts @@ -20,7 +20,9 @@ import { AsyncCallback } from './@ohos.base'; import formBindingData from './@ohos.app.form.formBindingData'; +/*** if arkts 1.1 */ import formInfo from './@ohos.app.form.formInfo'; +/*** endif */ import Want from './@ohos.app.ability.Want'; /** @@ -36,14 +38,15 @@ import Want from './@ohos.app.ability.Want'; * @namespace formProvider * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ declare namespace formProvider { /** * Set next update time for a specified form. * * @param { string } formId - Indicates the form ID. - * @param { number } minute - Indicates duration minute before next update. + * @param { int } minute - Indicates duration minute before next update. * @param { AsyncCallback } callback - The callback of setFormNextRefreshTime. * @throws { BusinessError } 401 - Parameter error. Possible causes: * 1.Mandatory parameters are left unspecified; 2.Incorrect parameter types; 3.Parameter verification failed. @@ -61,7 +64,7 @@ declare namespace formProvider { * Set next update time for a specified form. * * @param { string } formId - Indicates the form ID. - * @param { number } minute - Indicates duration minute before next update. + * @param { int } minute - Indicates duration minute before next update. * @param { AsyncCallback } callback - The callback of setFormNextRefreshTime. * @throws { BusinessError } 401 - Parameter error. Possible causes: * 1.Mandatory parameters are left unspecified; 2.Incorrect parameter types; 3.Parameter verification failed. @@ -74,15 +77,16 @@ declare namespace formProvider { * @throws { BusinessError } 16501003 - The form cannot be operated by the current application. * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ - function setFormNextRefreshTime(formId: string, minute: number, callback: AsyncCallback): void; + function setFormNextRefreshTime(formId: string, minute: int, callback: AsyncCallback): void; /** * Set next update time for a specified form. * * @param { string } formId - Indicates the form ID. - * @param { number } minute - Indicates duration minute before next update. + * @param { int } minute - Indicates duration minute before next update. * @returns { Promise } The promise returned by the function. * @throws { BusinessError } 401 - Parameter error. Possible causes: * 1.Mandatory parameters are left unspecified; 2.Incorrect parameter types; 3.Parameter verification failed. @@ -100,7 +104,7 @@ declare namespace formProvider { * Set next update time for a specified form. * * @param { string } formId - Indicates the form ID. - * @param { number } minute - Indicates duration minute before next update. + * @param { int } minute - Indicates duration minute before next update. * @returns { Promise } The promise returned by the function. * @throws { BusinessError } 401 - Parameter error. Possible causes: * 1.Mandatory parameters are left unspecified; 2.Incorrect parameter types; 3.Parameter verification failed. @@ -113,9 +117,10 @@ declare namespace formProvider { * @throws { BusinessError } 16501003 - The form cannot be operated by the current application. * @syscap SystemCapability.Ability.Form * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ - function setFormNextRefreshTime(formId: string, minute: number): Promise; + function setFormNextRefreshTime(formId: string, minute: int): Promise; /** * Update a specified form. diff --git a/api/@ohos.application.formError.d.ts b/api/@ohos.application.formError.d.ts index 41eedb71973c5f15a64929c1e5b46699e83f3878..e0a3fd46986364447a2bbfb5b2823dcc6172f300 100644 --- a/api/@ohos.application.formError.d.ts +++ b/api/@ohos.application.formError.d.ts @@ -23,22 +23,25 @@ * * @namespace formError * @syscap SystemCapability.Ability.Form - * @since 8 + * @since arkts {'1.1':'8', '1.2':'20'} + * @arkts 1.1&1.2 */ declare namespace formError { /** * Error of form. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Ability.Form - * @since 8 + * @since arkts {'1.1':'8', '1.2':'20'} + * @arkts 1.1&1.2 */ enum FormError { /** * A common internal error occurs during form processing. * * @syscap SystemCapability.Ability.Form - * @since 8 + * @since arkts {'1.1':'8', '1.2':'20'} + * @arkts 1.1&1.2 */ ERR_COMMON = 1, @@ -48,7 +51,8 @@ declare namespace formError { * and ohos.permission.GET_BUNDLE_INFO_PRIVILEGED permissions. * * @syscap SystemCapability.Ability.Form - * @since 8 + * @since arkts {'1.1':'8', '1.2':'20'} + * @arkts 1.1&1.2 */ ERR_PERMISSION_DENY = 2, @@ -58,7 +62,8 @@ declare namespace formError { * consistent with those provided by the form provider. * * @syscap SystemCapability.Ability.Form - * @since 8 + * @since arkts {'1.1':'8', '1.2':'20'} + * @arkts 1.1&1.2 */ ERR_GET_INFO_FAILED = 4, @@ -67,7 +72,8 @@ declare namespace formError { * Ensure that the bundle to which the form to be added belongs is available. * * @syscap SystemCapability.Ability.Form - * @since 8 + * @since arkts {'1.1':'8', '1.2':'20'} + * @arkts 1.1&1.2 */ ERR_GET_BUNDLE_FAILED = 5, @@ -76,7 +82,8 @@ declare namespace formError { * Ensure that the grid style of the form is supported by the form provider. * * @syscap SystemCapability.Ability.Form - * @since 8 + * @since arkts {'1.1':'8', '1.2':'20'} + * @arkts 1.1&1.2 */ ERR_GET_LAYOUT_FAILED = 6, @@ -85,7 +92,8 @@ declare namespace formError { * parameters are valid. * * @syscap SystemCapability.Ability.Form - * @since 8 + * @since arkts {'1.1':'8', '1.2':'20'} + * @arkts 1.1&1.2 */ ERR_ADD_INVALID_PARAM = 7, @@ -94,7 +102,8 @@ declare namespace formError { * different from that obtained for the first time. * * @syscap SystemCapability.Ability.Form - * @since 8 + * @since arkts {'1.1':'8', '1.2':'20'} + * @arkts 1.1&1.2 */ ERR_CFG_NOT_MATCH_ID = 8, @@ -102,7 +111,8 @@ declare namespace formError { * The ID of the form to be operated does not exist in the Form Manager Service. * * @syscap SystemCapability.Ability.Form - * @since 8 + * @since arkts {'1.1':'8', '1.2':'20'} + * @arkts 1.1&1.2 */ ERR_NOT_EXIST_ID = 9, @@ -110,7 +120,8 @@ declare namespace formError { * Failed to bind the Form Manager Service to the provider service. * * @syscap SystemCapability.Ability.Form - * @since 8 + * @since arkts {'1.1':'8', '1.2':'20'} + * @arkts 1.1&1.2 */ ERR_BIND_PROVIDER_FAILED = 10, @@ -118,7 +129,8 @@ declare namespace formError { * The total number of added forms exceeds the maximum allowed by the system. * * @syscap SystemCapability.Ability.Form - * @since 8 + * @since arkts {'1.1':'8', '1.2':'20'} + * @arkts 1.1&1.2 */ ERR_MAX_SYSTEM_FORMS = 11, @@ -127,7 +139,8 @@ declare namespace formError { * exceeds the maximum allowed by the system. * * @syscap SystemCapability.Ability.Form - * @since 8 + * @since arkts {'1.1':'8', '1.2':'20'} + * @arkts 1.1&1.2 */ ERR_MAX_INSTANCES_PER_FORM = 12, @@ -136,7 +149,8 @@ declare namespace formError { * operated by the current application. * * @syscap SystemCapability.Ability.Form - * @since 8 + * @since arkts {'1.1':'8', '1.2':'20'} + * @arkts 1.1&1.2 */ ERR_OPERATION_FORM_NOT_SELF = 13, @@ -144,7 +158,8 @@ declare namespace formError { * The Form Manager Service failed to instruct the form provider to delete the form. * * @syscap SystemCapability.Ability.Form - * @since 8 + * @since arkts {'1.1':'8', '1.2':'20'} + * @arkts 1.1&1.2 */ ERR_PROVIDER_DEL_FAIL = 14, @@ -152,7 +167,8 @@ declare namespace formError { * The total number of added forms exceeds the maximum per client. * * @syscap SystemCapability.Ability.Form - * @since 8 + * @since arkts {'1.1':'8', '1.2':'20'} + * @arkts 1.1&1.2 */ ERR_MAX_FORMS_PER_CLIENT = 15, @@ -160,7 +176,8 @@ declare namespace formError { * The total number of added temp forms exceeds the maximum in system. * * @syscap SystemCapability.Ability.Form - * @since 8 + * @since arkts {'1.1':'8', '1.2':'20'} + * @arkts 1.1&1.2 */ ERR_MAX_SYSTEM_TEMP_FORMS = 16, @@ -168,7 +185,8 @@ declare namespace formError { * The module can not be find in system. * * @syscap SystemCapability.Ability.Form - * @since 8 + * @since arkts {'1.1':'8', '1.2':'20'} + * @arkts 1.1&1.2 */ ERR_FORM_NO_SUCH_MODULE = 17, @@ -176,7 +194,8 @@ declare namespace formError { * The ability can not be find in system. * * @syscap SystemCapability.Ability.Form - * @since 8 + * @since arkts {'1.1':'8', '1.2':'20'} + * @arkts 1.1&1.2 */ ERR_FORM_NO_SUCH_ABILITY = 18, @@ -184,7 +203,8 @@ declare namespace formError { * The dimension is not exist in the form. * * @syscap SystemCapability.Ability.Form - * @since 8 + * @since arkts {'1.1':'8', '1.2':'20'} + * @arkts 1.1&1.2 */ ERR_FORM_NO_SUCH_DIMENSION = 19, @@ -192,7 +212,8 @@ declare namespace formError { * The ability is not installed. * * @syscap SystemCapability.Ability.Form - * @since 8 + * @since arkts {'1.1':'8', '1.2':'20'} + * @arkts 1.1&1.2 */ ERR_FORM_FA_NOT_INSTALLED = 20, @@ -201,7 +222,8 @@ declare namespace formError { * the service is not started.Please try again after the service is started. * * @syscap SystemCapability.Ability.Form - * @since 8 + * @since arkts {'1.1':'8', '1.2':'20'} + * @arkts 1.1&1.2 */ ERR_SYSTEM_RESPONSES_FAILED = 30, @@ -213,7 +235,8 @@ declare namespace formError { * the request parameters. * * @syscap SystemCapability.Ability.Form - * @since 8 + * @since arkts {'1.1':'8', '1.2':'20'} + * @arkts 1.1&1.2 */ ERR_FORM_DUPLICATE_ADDED = 31, @@ -222,7 +245,8 @@ declare namespace formError { * the restoration is complete. * * @syscap SystemCapability.Ability.Form - * @since 8 + * @since arkts {'1.1':'8', '1.2':'20'} + * @arkts 1.1&1.2 */ ERR_IN_RECOVERY = 36, @@ -231,7 +255,8 @@ declare namespace formError { * * @syscap SystemCapability.Ability.Form * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ ERR_DISTRIBUTED_SCHEDULE_FAILED = 37 } diff --git a/api/@ohos.base.d.ets b/api/@ohos.base.d.ets index 39f9d3995fd8fcee34650181e05a732a7468c206..0f7d42b99c200e99227ddb41516bb7ab0e64cea3 100644 --- a/api/@ohos.base.d.ets +++ b/api/@ohos.base.d.ets @@ -51,7 +51,7 @@ export type ErrorCallback = (err: T)=> void; * @atomicservice * @since 20 */ -export type AsyncCallback = (err: BusinessError, data: T)=> void; +export type AsyncCallback = (err: BusinessError | null, data: T | undefined)=> void; /** * Defines the error interface. diff --git a/api/@ohos.bundle.appControl.d.ts b/api/@ohos.bundle.appControl.d.ts index d57d3694f7e01d75f06f4af04b4d85ceeb154f94..b7f6ac7d90d233d2141584973742c83720c58ca0 100644 --- a/api/@ohos.bundle.appControl.d.ts +++ b/api/@ohos.bundle.appControl.d.ts @@ -19,7 +19,12 @@ */ import { AsyncCallback } from './@ohos.base'; +/*** if arkts 1.1 */ import type { ElementName } from './bundleManager/ElementName'; +/*** endif */ +/*** if arkts 1.2 */ +import { ElementName } from './bundleManager/ElementName'; +/*** endif */ import Want from './@ohos.app.ability.Want'; /** @@ -28,7 +33,8 @@ import Want from './@ohos.app.ability.Want'; * @namespace appControl * @syscap SystemCapability.BundleManager.BundleFramework.AppControl * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ declare namespace appControl { /** @@ -37,7 +43,8 @@ declare namespace appControl { * @enum { number } * @syscap SystemCapability.BundleManager.BundleFramework.AppControl * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ export enum ComponentType { /** @@ -45,7 +52,8 @@ declare namespace appControl { * * @syscap SystemCapability.BundleManager.BundleFramework.AppControl * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ UI_ABILITY = 1, @@ -54,7 +62,8 @@ declare namespace appControl { * * @syscap SystemCapability.BundleManager.BundleFramework.AppControl * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ UI_EXTENSION = 2 } @@ -65,7 +74,8 @@ declare namespace appControl { * @enum { number } * @syscap SystemCapability.BundleManager.BundleFramework.AppControl * @systemapi - * @since 15 + * @since arkts {'1.1':'15', '1.2':'20'} + * @arkts 1.1&1.2 */ export enum UninstallComponentType { /** @@ -73,7 +83,8 @@ declare namespace appControl { * * @syscap SystemCapability.BundleManager.BundleFramework.AppControl * @systemapi - * @since 15 + * @since arkts {'1.1':'15', '1.2':'20'} + * @arkts 1.1&1.2 */ EXTENSION = 1, } @@ -84,7 +95,8 @@ declare namespace appControl { * @enum { number } * @syscap SystemCapability.BundleManager.BundleFramework.AppControl * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ export enum DisposedType { /** @@ -92,7 +104,8 @@ declare namespace appControl { * * @syscap SystemCapability.BundleManager.BundleFramework.AppControl * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ BLOCK_APPLICATION = 1, /** @@ -100,7 +113,8 @@ declare namespace appControl { * * @syscap SystemCapability.BundleManager.BundleFramework.AppControl * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ BLOCK_ABILITY = 2, /** @@ -108,7 +122,8 @@ declare namespace appControl { * * @syscap SystemCapability.BundleManager.BundleFramework.AppControl * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ NON_BLOCK = 3 } @@ -119,7 +134,8 @@ declare namespace appControl { * @enum { number } * @syscap SystemCapability.BundleManager.BundleFramework.AppControl * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ export enum ControlType { /** @@ -127,7 +143,8 @@ declare namespace appControl { * * @syscap SystemCapability.BundleManager.BundleFramework.AppControl * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ ALLOWED_LIST = 1, /** @@ -135,7 +152,8 @@ declare namespace appControl { * * @syscap SystemCapability.BundleManager.BundleFramework.AppControl * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ DISALLOWED_LIST = 2 } @@ -146,7 +164,8 @@ declare namespace appControl { * @typedef DisposedRule * @syscap SystemCapability.BundleManager.BundleFramework.AppControl * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ export interface DisposedRule { /** @@ -155,7 +174,8 @@ declare namespace appControl { * @type { Want } * @syscap SystemCapability.BundleManager.BundleFramework.AppControl * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ want: Want; @@ -165,7 +185,8 @@ declare namespace appControl { * @type { ComponentType } * @syscap SystemCapability.BundleManager.BundleFramework.AppControl * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ componentType: ComponentType; @@ -175,7 +196,8 @@ declare namespace appControl { * @type { DisposedType } * @syscap SystemCapability.BundleManager.BundleFramework.AppControl * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ disposedType: DisposedType; @@ -185,7 +207,8 @@ declare namespace appControl { * @type { ControlType } * @syscap SystemCapability.BundleManager.BundleFramework.AppControl * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ controlType: ControlType; @@ -195,9 +218,10 @@ declare namespace appControl { * @type { Array } * @syscap SystemCapability.BundleManager.BundleFramework.AppControl * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ - elementList: Array ; + elementList: Array; /** * Indicates priority of the rule. @@ -205,7 +229,8 @@ declare namespace appControl { * @type { number } * @syscap SystemCapability.BundleManager.BundleFramework.AppControl * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ priority: number; } @@ -216,7 +241,8 @@ declare namespace appControl { * @typedef UninstallDisposedRule * @syscap SystemCapability.BundleManager.BundleFramework.AppControl * @systemapi - * @since 15 + * @since arkts {'1.1':'15', '1.2':'20'} + * @arkts 1.1&1.2 */ export interface UninstallDisposedRule { /** @@ -225,7 +251,8 @@ declare namespace appControl { * @type { Want } * @syscap SystemCapability.BundleManager.BundleFramework.AppControl * @systemapi - * @since 15 + * @since arkts {'1.1':'15', '1.2':'20'} + * @arkts 1.1&1.2 */ want: Want; @@ -235,7 +262,8 @@ declare namespace appControl { * @type { UninstallComponentType } * @syscap SystemCapability.BundleManager.BundleFramework.AppControl * @systemapi - * @since 15 + * @since arkts {'1.1':'15', '1.2':'20'} + * @arkts 1.1&1.2 */ uninstallComponentType: UninstallComponentType; @@ -245,7 +273,8 @@ declare namespace appControl { * @type { number } * @syscap SystemCapability.BundleManager.BundleFramework.AppControl * @systemapi - * @since 15 + * @since arkts {'1.1':'15', '1.2':'20'} + * @arkts 1.1&1.2 */ priority: number; } @@ -304,7 +333,8 @@ declare namespace appControl { * @throws { BusinessError } 17700005 - The specified app ID is empty string. * @syscap SystemCapability.BundleManager.BundleFramework.AppControl * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function setDisposedStatus(appId: string, disposedWant: Want, callback: AsyncCallback): void; @@ -322,7 +352,8 @@ declare namespace appControl { * @throws { BusinessError } 17700005 - The specified app ID is empty string. * @syscap SystemCapability.BundleManager.BundleFramework.AppControl * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function setDisposedStatus(appId: string, disposedWant: Want): Promise; @@ -339,7 +370,8 @@ declare namespace appControl { * @throws { BusinessError } 17700005 - The specified app ID is empty string. * @syscap SystemCapability.BundleManager.BundleFramework.AppControl * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ function setDisposedStatusSync(appId: string, disposedWant: Want): void; @@ -356,7 +388,8 @@ declare namespace appControl { * @throws { BusinessError } 17700005 - The specified app ID is empty string. * @syscap SystemCapability.BundleManager.BundleFramework.AppControl * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getDisposedStatus(appId: string, callback: AsyncCallback): void; @@ -373,7 +406,8 @@ declare namespace appControl { * @throws { BusinessError } 17700005 - The specified app ID is empty string. * @syscap SystemCapability.BundleManager.BundleFramework.AppControl * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getDisposedStatus(appId: string): Promise; @@ -390,7 +424,8 @@ declare namespace appControl { * @throws { BusinessError } 17700005 - The specified app ID is empty string. * @syscap SystemCapability.BundleManager.BundleFramework.AppControl * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ function getDisposedStatusSync(appId: string): Want; @@ -407,7 +442,8 @@ declare namespace appControl { * @throws { BusinessError } 17700005 - The specified app ID is empty string. * @syscap SystemCapability.BundleManager.BundleFramework.AppControl * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function deleteDisposedStatus(appId: string, callback: AsyncCallback): void; @@ -424,7 +460,8 @@ declare namespace appControl { * @throws { BusinessError } 17700005 - The specified app ID is empty string. * @syscap SystemCapability.BundleManager.BundleFramework.AppControl * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function deleteDisposedStatus(appId: string): Promise; @@ -456,7 +493,8 @@ declare namespace appControl { * @throws { BusinessError } 17700061 - AppIndex is not in the valid range. * @syscap SystemCapability.BundleManager.BundleFramework.AppControl * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ function deleteDisposedStatusSync(appId: string, appIndex?: number): void; @@ -490,7 +528,8 @@ declare namespace appControl { * @throws { BusinessError } 17700061 - AppIndex is not in the valid range. * @syscap SystemCapability.BundleManager.BundleFramework.AppControl * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ function getDisposedRule(appId: string, appIndex?: number): DisposedRule; @@ -524,9 +563,10 @@ declare namespace appControl { * @throws { BusinessError } 17700061 - AppIndex is not in the valid range. * @syscap SystemCapability.BundleManager.BundleFramework.AppControl * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ - function setDisposedRule(appId: string, rule: DisposedRule, appIndex?: number): void; + function setDisposedRule(appId: string, rule: DisposedRule, appIndex?: number): void; /** * Sets the uninstall disposed rule of a specified bundle. @@ -544,7 +584,8 @@ declare namespace appControl { * @throws { BusinessError } 17700075 - The specified bundleName of want is not the same with caller. * @syscap SystemCapability.BundleManager.BundleFramework.AppControl * @systemapi - * @since 15 + * @since arkts {'1.1':'15', '1.2':'20'} + * @arkts 1.1&1.2 */ function setUninstallDisposedRule(appIdentifier: string, rule: UninstallDisposedRule, appIndex?: number): void; @@ -563,7 +604,8 @@ declare namespace appControl { * @throws { BusinessError } 17700074 - The specified appIdentifier is invalid. * @syscap SystemCapability.BundleManager.BundleFramework.AppControl * @systemapi - * @since 15 + * @since arkts {'1.1':'15', '1.2':'20'} + * @arkts 1.1&1.2 */ function getUninstallDisposedRule(appIdentifier: string, appIndex?: number): UninstallDisposedRule; @@ -581,7 +623,8 @@ declare namespace appControl { * @throws { BusinessError } 17700074 - The specified appIdentifier is invalid. * @syscap SystemCapability.BundleManager.BundleFramework.AppControl * @systemapi - * @since 15 + * @since arkts {'1.1':'15', '1.2':'20'} + * @arkts 1.1&1.2 */ function deleteUninstallDisposedRule(appIdentifier: string, appIndex?: number): void; diff --git a/api/@ohos.bundle.bundleManager.d.ts b/api/@ohos.bundle.bundleManager.d.ts index 1e26e7c6bb27da32d7d20b8c37c71e9bf425a6b8..525a06ae37d33dcf451f68cd6805edf8f6d7b020 100644 --- a/api/@ohos.bundle.bundleManager.d.ts +++ b/api/@ohos.bundle.bundleManager.d.ts @@ -21,14 +21,14 @@ import { AsyncCallback } from './@ohos.base'; import { Metadata as _Metadata } from './bundleManager/Metadata'; import { ElementName as _ElementName } from './bundleManager/ElementName'; -/*** if arkts 1.1 */ -import type { ApplicationInfo as _ApplicationInfo, ModuleMetadata as _ModuleMetadata, - PreinstalledApplicationInfo as _PreinstalledApplicationInfo } from './bundleManager/ApplicationInfo'; +import Want from './@ohos.app.ability.Want'; import { PermissionDef as _PermissionDef } from './bundleManager/PermissionDef'; import { PluginBundleInfo as _PluginBundleInfo, PluginModuleInfo as _PluginModuleInfo} from './bundleManager/PluginBundleInfo'; import { SharedBundleInfo as _SharedBundleInfo } from './bundleManager/SharedBundleInfo'; +/*** if arkts 1.1 */ +import type { ApplicationInfo as _ApplicationInfo, ModuleMetadata as _ModuleMetadata, + PreinstalledApplicationInfo as _PreinstalledApplicationInfo } from './bundleManager/ApplicationInfo'; import type { RecoverableApplicationInfo as _RecoverableApplicationInfo } from './bundleManager/RecoverableApplicationInfo'; -import Want from './@ohos.app.ability.Want'; import * as _AbilityInfo from './bundleManager/AbilityInfo'; import * as _AppProvisionInfo from './bundleManager/AppProvisionInfo'; import * as _BundleInfo from './bundleManager/BundleInfo'; @@ -39,7 +39,9 @@ import * as _Skill from './bundleManager/Skill'; /*** if arkts 1.2 */ import { ApplicationInfo as _ApplicationInfo, ModuleMetadata as _ModuleMetadata, PreinstalledApplicationInfo as _PreinstalledApplicationInfo } from './bundleManager/ApplicationInfo'; +import { RecoverableApplicationInfo as _RecoverableApplicationInfo } from './bundleManager/RecoverableApplicationInfo'; import { AbilityInfo as _AbilityInfo, WindowSize as _WindowSize } from './bundleManager/AbilityInfo'; +import { AppProvisionInfo as _AppProvisionInfo, Validity as _Validity } from './bundleManager/AppProvisionInfo'; import { BundleInfo as _BundleInfo, UsedScene as _UsedScene, ReqPermissionDetail as _ReqPermissionDetail, SignatureInfo as _SignatureInfo, AppCloneIdentity as _AppCloneIdentity } from './bundleManager/BundleInfo'; import { HapModuleInfo as _HapModuleInfo, PreloadItem as _PreloadItem, Dependency as _Dependency, @@ -397,7 +399,7 @@ declare namespace bundleManager { GET_BUNDLE_INFO_ONLY_WITH_LAUNCHER_ABILITY = 0x00001000, /** * Used to obtain the bundle information of an application installed by any user. - * It must be used together with GET_BUNDLE_INFO_WITH_APPLICATION. + * It must be used together with GET_BUNDLE_INFO_WITH_APPLICATION. * It is valid only in the {@link getBundleInfo} and {@link getAllBundleInfo} APIs. * * @syscap SystemCapability.BundleManager.BundleFramework.Core @@ -704,8 +706,7 @@ declare namespace bundleManager { * Indicates extension info with type of form * * @syscap SystemCapability.BundleManager.BundleFramework.Core - * @since arkts {'1.1':'9', '1.2':'20'} - * @arkts 1.1&1.2 + * @since 9 */ /** * Indicates extension info with type of form @@ -2191,7 +2192,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700026 - The specified bundle is disabled. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getApplicationInfo(bundleName: string, appFlags: number, callback: AsyncCallback): void; @@ -2211,7 +2213,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700026 - The specified bundle is disabled. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getApplicationInfo(bundleName: string, appFlags: number, userId: number, callback: AsyncCallback): void; @@ -2232,7 +2235,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700026 - The specified bundle is disabled. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getApplicationInfo(bundleName: string, appFlags: number, userId?: number): Promise; @@ -2247,7 +2251,8 @@ declare namespace bundleManager { * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; 2. Incorrect parameter types. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getAllBundleInfo(bundleFlags: number, callback: AsyncCallback>): void; @@ -2264,7 +2269,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700004 - The specified user ID is not found. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getAllBundleInfo(bundleFlags: number, userId: number, callback: AsyncCallback>): void; @@ -2281,7 +2287,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700004 - The specified user ID is not found. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getAllBundleInfo(bundleFlags: number, userId?: number): Promise>; @@ -2296,7 +2303,8 @@ declare namespace bundleManager { * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; 2. Incorrect parameter types. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getAllApplicationInfo(appFlags: number, callback: AsyncCallback>): void; @@ -2313,7 +2321,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700004 - The specified user ID is not found. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getAllApplicationInfo(appFlags: number, userId: number, callback: AsyncCallback>): void; @@ -2331,7 +2340,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700004 - The specified user ID is not found. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getAllApplicationInfo(appFlags: number, userId?: number): Promise>; @@ -2352,7 +2362,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700029 - The specified ability is disabled. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function queryAbilityInfo(want: Want, abilityFlags: number, callback: AsyncCallback>): void; @@ -2375,7 +2386,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700029 - The specified ability is disabled. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function queryAbilityInfo(want: Want, abilityFlags: number, userId: number, callback: AsyncCallback>): void; @@ -2399,7 +2411,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700029 - The specified ability is disabled. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function queryAbilityInfo(want: Want, abilityFlags: number, userId?: number): Promise>; @@ -2422,7 +2435,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700029 - The specified ability is disabled. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ function queryAbilityInfo(wants: Array, abilityFlags: number, userId?: number): Promise>; @@ -2445,7 +2459,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700029 - The specified ability is disabled. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ function queryAbilityInfoSync(want: Want, abilityFlags: number, userId?: number): Array; @@ -2482,7 +2497,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700026 - The specified bundle is disabled. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function queryExtensionAbilityInfo(want: Want, extensionAbilityType: ExtensionAbilityType, extensionAbilityFlags: number, callback: AsyncCallback>): void; @@ -2507,7 +2523,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700026 - The specified bundle is disabled. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function queryExtensionAbilityInfo(want: Want, extensionAbilityType: ExtensionAbilityType, extensionAbilityFlags: number, userId: number, callback: AsyncCallback>): void; @@ -2532,7 +2549,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700026 - The specified bundle is disabled. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function queryExtensionAbilityInfo(want: Want, extensionAbilityType: ExtensionAbilityType, extensionAbilityFlags: number, userId?: number): Promise>; @@ -2557,7 +2575,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700026 - The specified bundle is disabled. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ function queryExtensionAbilityInfoSync(want: Want, extensionAbilityType: ExtensionAbilityType, extensionAbilityFlags: number, userId?: number): Array; @@ -2582,7 +2601,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700026 - The specified bundle is disabled. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ function queryExtensionAbilityInfoSync(want: Want, extensionAbilityType: string, extensionAbilityFlags: number, userId?: number): Array; @@ -2604,7 +2624,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700004 - The specified userId is invalid. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ function queryExtensionAbilityInfoSync(extensionAbilityType: string, extensionAbilityFlags: number, userId?: number): Array; @@ -2619,7 +2640,8 @@ declare namespace bundleManager { * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; 2. Incorrect parameter types. * @throws { BusinessError } 17700021 - The uid is not found. * @syscap SystemCapability.BundleManager.BundleFramework.Core - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ function getBundleNameByUid(uid: number, callback: AsyncCallback): void; @@ -2633,7 +2655,8 @@ declare namespace bundleManager { * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; 2. Incorrect parameter types. * @throws { BusinessError } 17700021 - The uid is not found. * @syscap SystemCapability.BundleManager.BundleFramework.Core - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ function getBundleNameByUid(uid: number): Promise; @@ -2647,7 +2670,8 @@ declare namespace bundleManager { * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; 2. Incorrect parameter types. * @throws { BusinessError } 17700021 - The uid is not found. * @syscap SystemCapability.BundleManager.BundleFramework.Core - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ function getBundleNameByUidSync(uid: number): string; @@ -2665,7 +2689,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700022 - The hapFilePath is invalid. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getBundleArchiveInfo(hapFilePath: string, bundleFlags: number, callback: AsyncCallback): void; @@ -2683,7 +2708,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700022 - The hapFilePath is invalid. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getBundleArchiveInfo(hapFilePath: string, bundleFlags: number): Promise; @@ -2701,7 +2727,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700022 - The hapFilePath is invalid. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ function getBundleArchiveInfoSync(hapFilePath: string, bundleFlags: number): BundleInfo; @@ -2718,7 +2745,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700030 - The specified bundle does not support clearing of cache files. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function cleanBundleCacheFiles(bundleName: string, callback: AsyncCallback): void; @@ -2735,7 +2763,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700030 - The specified bundle does not support clearing of cache files. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function cleanBundleCacheFiles(bundleName: string): Promise; @@ -2754,7 +2783,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700061 - AppIndex not in valid range. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 15 + * @since arkts {'1.1':'15', '1.2':'20'} + * @arkts 1.1&1.2 */ function cleanBundleCacheFiles(bundleName: string, appIndex: number): Promise; @@ -2767,7 +2797,8 @@ declare namespace bundleManager { * @throws { BusinessError } 202 - Permission denied, non-system app called system api. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 15 + * @since arkts {'1.1':'15', '1.2':'20'} + * @arkts 1.1&1.2 */ function getAllBundleCacheSize(): Promise; @@ -2780,7 +2811,8 @@ declare namespace bundleManager { * @throws { BusinessError } 202 - Permission denied, non-system app called system api. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 15 + * @since arkts {'1.1':'15', '1.2':'20'} + * @arkts 1.1&1.2 */ function cleanAllBundleCache(): Promise; @@ -2799,7 +2831,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700061 - AppIndex not in valid range. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ function setApplicationEnabled(bundleName: string, appIndex: number, isEnabled: boolean): Promise; @@ -2816,7 +2849,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700001 - The specified bundleName is not found. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function setApplicationEnabled(bundleName: string, isEnabled: boolean, callback: AsyncCallback): void; @@ -2833,7 +2867,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700001 - The specified bundleName is not found. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function setApplicationEnabled(bundleName: string, isEnabled: boolean): Promise; @@ -2849,7 +2884,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700001 - The specified bundleName is not found. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ function setApplicationEnabledSync(bundleName: string, isEnabled: boolean): void; @@ -2869,7 +2905,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700061 - AppIndex not in valid range. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ function setAbilityEnabled(info: AbilityInfo, appIndex: number, isEnabled: boolean): Promise; @@ -2887,7 +2924,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700003 - The specified abilityInfo is not found. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function setAbilityEnabled(info: AbilityInfo, isEnabled: boolean, callback: AsyncCallback): void; @@ -2905,7 +2943,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700003 - The specified abilityInfo is not found. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function setAbilityEnabled(info: AbilityInfo, isEnabled: boolean): Promise; @@ -2922,7 +2961,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700003 - The specified abilityInfo is not found. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ function setAbilityEnabledSync(info: AbilityInfo, isEnabled: boolean): void; @@ -2938,7 +2978,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700061 - AppIndex not in valid range. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ function isApplicationEnabled(bundleName: string, appIndex: number): Promise; @@ -2952,7 +2993,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700001 - The specified bundleName is not found. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function isApplicationEnabled(bundleName: string, callback: AsyncCallback): void; @@ -2966,7 +3008,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700001 - The specified bundleName is not found. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function isApplicationEnabled(bundleName: string): Promise; @@ -2998,7 +3041,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700061 - AppIndex not in valid range. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ function isAbilityEnabled(info: AbilityInfo, appIndex: number): Promise; @@ -3013,7 +3057,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700003 - The specified abilityName is not found. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function isAbilityEnabled(info: AbilityInfo, callback: AsyncCallback): void; @@ -3028,7 +3073,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700003 - The specified abilityName is not found. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function isAbilityEnabled(info: AbilityInfo): Promise; @@ -3043,7 +3089,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700003 - The specified abilityName is not found. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ function isAbilityEnabledSync(info: AbilityInfo): boolean; @@ -3064,7 +3111,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700026 - The specified bundle is disabled. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getLaunchWantForBundle(bundleName: string, userId: number, callback: AsyncCallback): void; @@ -3083,7 +3131,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700026 - The specified bundle is disabled. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getLaunchWantForBundle(bundleName: string, callback: AsyncCallback): void; @@ -3104,7 +3153,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700026 - The specified bundle is disabled. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getLaunchWantForBundle(bundleName: string, userId?: number): Promise; @@ -3125,7 +3175,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700026 - The specified bundle is disabled. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ function getLaunchWantForBundleSync(bundleName: string, userId?: number): Want; @@ -3138,7 +3189,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700072 - The launch want is not found. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @atomicservice - * @since 13 + * @since arkts {'1.1':'13', '1.2':'20'} + * @arkts 1.1&1.2 */ function getLaunchWant(): Want; @@ -3171,7 +3223,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700029 - The specified ability is disabled. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ function getProfileByAbility(moduleName: string, abilityName: string, metadataName: string, callback: AsyncCallback>): void; @@ -3204,7 +3257,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700029 - The specified ability is disabled. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ function getProfileByAbility(moduleName: string, abilityName: string, metadataName?: string): Promise>; @@ -3237,7 +3291,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700029 - The specified ability is disabled. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ function getProfileByAbilitySync(moduleName: string, abilityName: string, metadataName?: string): Array; @@ -3268,7 +3323,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700024 - Failed to get the profile because there is no profile in the HAP. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ function getProfileByExtensionAbility(moduleName: string, extensionAbilityName: string, metadataName: string, callback: AsyncCallback>): void; @@ -3299,7 +3355,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700024 - Failed to get the profile because there is no profile in the HAP. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ function getProfileByExtensionAbility(moduleName: string, extensionAbilityName: string, metadataName?: string): Promise>; @@ -3330,7 +3387,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700024 - Failed to get the profile because there is no profile in the HAP. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ function getProfileByExtensionAbilitySync(moduleName: string, extensionAbilityName: string, metadataName?: string): Array; @@ -3346,7 +3404,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700006 - The specified permission is not found. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getPermissionDef(permissionName: string, callback: AsyncCallback): void; @@ -3362,7 +3421,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700006 - The specified permission is not found. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getPermissionDef(permissionName: string): Promise; @@ -3378,7 +3438,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700006 - The specified permission is not found. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ function getPermissionDefSync(permissionName: string): PermissionDef; @@ -3401,7 +3462,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700029 - The specified ability is disabled. * @syscap SystemCapability.BundleManager.BundleFramework.Resource * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getAbilityLabel(bundleName: string, moduleName: string, abilityName: string, callback: AsyncCallback): void; @@ -3424,7 +3486,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700029 - The specified ability is disabled. * @syscap SystemCapability.BundleManager.BundleFramework.Resource * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getAbilityLabel(bundleName: string, moduleName: string, abilityName: string): Promise; @@ -3447,7 +3510,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700029 - The specified ability is disabled. * @syscap SystemCapability.BundleManager.BundleFramework.Resource * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ function getAbilityLabelSync(bundleName: string, moduleName: string, abilityName: string): string; @@ -3536,7 +3600,8 @@ declare namespace bundleManager { * @throws { BusinessError } 202 - Permission denied, non-system app called system api. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ function getAllSharedBundleInfo(callback: AsyncCallback>): void; @@ -3549,7 +3614,8 @@ declare namespace bundleManager { * @throws { BusinessError } 202 - Permission denied, non-system app called system api. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ function getAllSharedBundleInfo(): Promise>; @@ -3567,7 +3633,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700002 - The specified moduleName is not found. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ function getSharedBundleInfo(bundleName: string, moduleName: string, callback: AsyncCallback>): void; @@ -3585,7 +3652,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700002 - The specified moduleName is not found. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ function getSharedBundleInfo(bundleName: string, moduleName: string): Promise>; @@ -3602,7 +3670,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700001 - The specified bundleName is not found. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ function getAppProvisionInfo(bundleName: string, callback: AsyncCallback): void; @@ -3621,7 +3690,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700004 - The specified user ID is not found. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ function getAppProvisionInfo(bundleName: string, userId: number, callback: AsyncCallback): void; @@ -3640,7 +3710,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700004 - The specified user ID is not found. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ function getAppProvisionInfo(bundleName: string, userId?: number): Promise; @@ -3659,7 +3730,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700004 - The specified user ID is not found. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ function getAppProvisionInfoSync(bundleName: string, userId?: number): AppProvisionInfo; @@ -3675,7 +3747,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700001 - The specified bundleName is not found. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ function getSpecifiedDistributionType(bundleName: string): string; @@ -3692,7 +3765,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700001 - The specified bundleName is not found. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ function getAdditionalInfo(bundleName: string): string; @@ -3734,7 +3808,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700026 - The specified bundle is disabled. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ function getJsonProfile(profileType: ProfileType, bundleName: string, moduleName?: string, userId?: number): string; @@ -3751,7 +3826,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700303 - Failed to obtain extended resources. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ function getExtResource(bundleName: string): Promise>; @@ -3789,6 +3865,7 @@ declare namespace bundleManager { * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi * @since 20 + * @arkts 1.1&1.2 */ function enableDynamicIcon(bundleName: string, moduleName: string): Promise; @@ -3831,7 +3908,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700305 - Failed to disable the dynamic icon. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ function disableDynamicIcon(bundleName: string): Promise; @@ -3871,7 +3949,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700306 - Failed to obtain the dynamic icon. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ function getDynamicIcon(bundleName: string): Promise; @@ -3937,7 +4016,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700201 - Failed to verify the abc file. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ function verifyAbc(abcPaths: Array, deleteOriginalFiles: boolean, callback: AsyncCallback): void; @@ -3967,7 +4047,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700201 - Failed to verify the abc file. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ function verifyAbc(abcPaths: Array, deleteOriginalFiles: boolean): Promise; @@ -3980,7 +4061,8 @@ declare namespace bundleManager { * @throws { BusinessError } 202 - Permission denied, non-system app called system api. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ function getRecoverableApplicationInfo(callback: AsyncCallback>): void; @@ -3993,7 +4075,8 @@ declare namespace bundleManager { * @throws { BusinessError } 202 - Permission denied, non-system app called system api. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ function getRecoverableApplicationInfo(): Promise>; @@ -4011,7 +4094,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700053 - The caller is not AppGallery. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ function setAdditionalInfo(bundleName: string, additionalInfo: string): void; @@ -4039,7 +4123,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700202 - Failed to delete the abc file. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ function deleteAbc(abcPath: string): Promise; @@ -4053,7 +4138,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700056 - The scheme of the specified link is not in the querySchemes. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ function canOpenLink(link: string): boolean; @@ -4066,7 +4152,8 @@ declare namespace bundleManager { * @throws { BusinessError } 202 - Permission denied, non-system app called system api. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ function getAllPreinstalledApplicationInfo(): Promise>; @@ -4083,7 +4170,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700059 - The specified developerId is invalid. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ function getAllBundleInfoByDeveloperId(developerId: string): Array; @@ -4098,7 +4186,8 @@ declare namespace bundleManager { * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; 2. Incorrect parameter types. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ function getDeveloperIds(appDistributionType?: number): Array; @@ -4115,7 +4204,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700060 - The specified application cannot be uninstalled. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ function switchUninstallState(bundleName: string, state: boolean): void; @@ -4128,7 +4218,8 @@ declare namespace bundleManager { * @throws { BusinessError } 201 - Permission denied. * @throws { BusinessError } 17700021 - The uid is not found. * @syscap SystemCapability.BundleManager.BundleFramework.Core - * @since 18 + * @since arkts {'1.1':'18', '1.2':'20'} + * @arkts 1.1&1.2 */ function getSignatureInfo(uid: number): SignatureInfo; @@ -4150,7 +4241,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700061 - AppIndex not in valid range. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ function getAppCloneBundleInfo(bundleName: string, appIndex: number, bundleFlags: number, userId?: number): Promise; @@ -4170,7 +4262,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700026 - The specified bundle and clone apps are all disabled. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ function getAllAppCloneBundleInfo(bundleName: string, bundleFlags: number, userId?: number): Promise>; @@ -4184,7 +4277,8 @@ declare namespace bundleManager { * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; 2. Incorrect parameter types. * @throws { BusinessError } 17700021 - The uid is not found. * @syscap SystemCapability.BundleManager.BundleFramework.Core - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ function getAppCloneIdentity(uid: number): Promise; @@ -4201,13 +4295,14 @@ declare namespace bundleManager { * @throws { BusinessError } 17700004 - The specified user ID is not found. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 19 + * @since arkts {'1.1':'19', '1.2':'20'} + * @arkts 1.1&1.2 */ function getAllPluginInfo(hostBundleName: string, userId?: number): Promise>; /** * Migrate files from the source paths to the destination path. - * + * * @permission ohos.permission.MIGRATE_DATA * @param { Array } sourcePaths - Indicates the source paths to be migrated. * @param { string } destinationPath - Target path for data migration. @@ -4223,7 +4318,8 @@ declare namespace bundleManager { * @throws { BusinessError } 17700086 - System error occurred during copy execution. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 18 + * @since arkts {'1.1':'18', '1.2':'20'} + * @arkts 1.1&1.2 */ function migrateData(sourcePaths: Array, destinationPath: string): Promise; @@ -4748,7 +4844,8 @@ declare namespace bundleManager { * @typedef { _PermissionDef } * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ export type PermissionDef = _PermissionDef; @@ -4776,7 +4873,8 @@ declare namespace bundleManager { * @typedef { _SharedBundleInfo } * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ export type SharedBundleInfo = _SharedBundleInfo; @@ -4790,6 +4888,17 @@ declare namespace bundleManager { */ export type AppProvisionInfo = _AppProvisionInfo.AppProvisionInfo; + /** + * Obtains profile file information about a bundle. + * + * @typedef { _AppProvisionInfo } + * @syscap SystemCapability.BundleManager.BundleFramework.Core + * @systemapi + * @since 20 + * @arkts 1.2 + */ + export type AppProvisionInfo = _AppProvisionInfo; + /** * Obtains profile file validity about a bundle. * @@ -4800,13 +4909,25 @@ declare namespace bundleManager { */ export type Validity = _AppProvisionInfo.Validity; + /** + * Obtains profile file validity about a bundle. + * + * @typedef { _Validity } + * @syscap SystemCapability.BundleManager.BundleFramework.Core + * @systemapi + * @since 20 + * @arkts 1.2 + */ + export type Validity = _Validity; + /** * Obtains information about a recoverable preinstalled application. * * @typedef { _RecoverableApplicationInfo } * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ export type RecoverableApplicationInfo = _RecoverableApplicationInfo; @@ -4869,7 +4990,8 @@ declare namespace bundleManager { * @typedef { _PluginBundleInfo } * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 19 + * @since arkts {'1.1':'19', '1.2':'20'} + * @arkts 1.1&1.2 */ export type PluginBundleInfo = _PluginBundleInfo; @@ -4879,7 +5001,8 @@ declare namespace bundleManager { * @typedef { _PluginModuleInfo } * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 19 + * @since arkts {'1.1':'19', '1.2':'20'} + * @arkts 1.1&1.2 */ export type PluginModuleInfo = _PluginModuleInfo; diff --git a/api/@ohos.bundle.bundleMonitor.d.ts b/api/@ohos.bundle.bundleMonitor.d.ts index 8e63401b2695b4ac97055b2e17d627c6c3e90621..a9f1ed5e4f025ca52092b3b0cbbba04e9367d453 100644 --- a/api/@ohos.bundle.bundleMonitor.d.ts +++ b/api/@ohos.bundle.bundleMonitor.d.ts @@ -26,7 +26,8 @@ import { Callback } from './@ohos.base'; * @namespace bundleMonitor * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ declare namespace bundleMonitor { /** @@ -35,7 +36,8 @@ declare namespace bundleMonitor { * @typedef BundleChangedInfo * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ interface BundleChangedInfo { /** @@ -45,7 +47,8 @@ declare namespace bundleMonitor { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly bundleName: string; /** @@ -55,7 +58,8 @@ declare namespace bundleMonitor { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly userId: number; /** @@ -65,7 +69,8 @@ declare namespace bundleMonitor { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly appIndex: number; } @@ -76,7 +81,8 @@ declare namespace bundleMonitor { * @typedef { 'add' | 'update' | 'remove' } * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ type BundleChangedEvent = 'add' | 'update' | 'remove'; @@ -91,7 +97,8 @@ declare namespace bundleMonitor { * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; 2. Incorrect parameter types. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function on(type: BundleChangedEvent, callback: Callback): void; @@ -106,7 +113,8 @@ declare namespace bundleMonitor { * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; 2. Incorrect parameter types. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function off(type: BundleChangedEvent, callback?: Callback): void; } diff --git a/api/@ohos.bundle.bundleResourceManager.d.ts b/api/@ohos.bundle.bundleResourceManager.d.ts index a4b4608c5db19a5047adece86db434d667b6d033..20cbf30fd312edf4a31c6af1725cf76d17fcd2a4 100644 --- a/api/@ohos.bundle.bundleResourceManager.d.ts +++ b/api/@ohos.bundle.bundleResourceManager.d.ts @@ -24,7 +24,9 @@ import type { BundleResourceInfo as _BundleResourceInfo } from './bundleManager/ import type { LauncherAbilityResourceInfo as _LauncherAbilityResourceInfo } from './bundleManager/LauncherAbilityResourceInfo'; /*** endif */ /*** if arkts 1.2 */ +import { AsyncCallback } from './@ohos.base'; import { BundleResourceInfo as _BundleResourceInfo } from './bundleManager/BundleResourceInfo'; +import { LauncherAbilityResourceInfo as _LauncherAbilityResourceInfo } from './bundleManager/LauncherAbilityResourceInfo'; /*** endif */ /** @@ -123,7 +125,8 @@ declare namespace bundleResourceManager { * @throws { BusinessError } 17700001 - The specified bundleName is not found. * @syscap SystemCapability.BundleManager.BundleFramework.Resource * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ function getBundleResourceInfo(bundleName: string, resourceFlags?: number): BundleResourceInfo; @@ -160,7 +163,8 @@ declare namespace bundleResourceManager { * @throws { BusinessError } 17700001 - The specified bundleName is not found. * @syscap SystemCapability.BundleManager.BundleFramework.Resource * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ function getLauncherAbilityResourceInfo(bundleName: string, resourceFlags?: number): Array; @@ -180,7 +184,8 @@ declare namespace bundleResourceManager { * @throws { BusinessError } 17700061 - AppIndex not in valid range or not found. * @syscap SystemCapability.BundleManager.BundleFramework.Resource * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ function getLauncherAbilityResourceInfo(bundleName: string, resourceFlags?: number, appIndex?: number): Array; @@ -195,7 +200,8 @@ declare namespace bundleResourceManager { * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; 2. Incorrect parameter types. * @syscap SystemCapability.BundleManager.BundleFramework.Resource * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ function getAllBundleResourceInfo(resourceFlags: number, callback: AsyncCallback>): void; @@ -210,7 +216,8 @@ declare namespace bundleResourceManager { * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; 2. Incorrect parameter types. * @syscap SystemCapability.BundleManager.BundleFramework.Resource * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ function getAllBundleResourceInfo(resourceFlags: number): Promise>; @@ -225,7 +232,8 @@ declare namespace bundleResourceManager { * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; 2. Incorrect parameter types. * @syscap SystemCapability.BundleManager.BundleFramework.Resource * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ function getAllLauncherAbilityResourceInfo(resourceFlags: number, callback: AsyncCallback>): void; @@ -240,7 +248,8 @@ declare namespace bundleResourceManager { * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; 2. Incorrect parameter types. * @syscap SystemCapability.BundleManager.BundleFramework.Resource * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ function getAllLauncherAbilityResourceInfo(resourceFlags: number): Promise>; @@ -282,7 +291,8 @@ declare namespace bundleResourceManager { * @typedef { _LauncherAbilityResourceInfo } * @syscap SystemCapability.BundleManager.BundleFramework.Resource * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ export type LauncherAbilityResourceInfo = _LauncherAbilityResourceInfo; } diff --git a/api/@ohos.bundle.defaultAppManager.d.ts b/api/@ohos.bundle.defaultAppManager.d.ts index 7ee73e02f674e32312dc319b69c6e9256a749071..358a1d920b190107ebb907fd24a5377470b9d87c 100644 --- a/api/@ohos.bundle.defaultAppManager.d.ts +++ b/api/@ohos.bundle.defaultAppManager.d.ts @@ -27,7 +27,8 @@ import { ElementName } from './bundleManager/ElementName'; * * @namespace defaultAppManager * @syscap SystemCapability.BundleManager.BundleFramework.DefaultApp - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ declare namespace defaultAppManager { /** @@ -35,70 +36,80 @@ declare namespace defaultAppManager { * * @enum { number } * @syscap SystemCapability.BundleManager.BundleFramework.DefaultApp - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ export enum ApplicationType { /** * Default browser identifier. * * @syscap SystemCapability.BundleManager.BundleFramework.DefaultApp - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ BROWSER = 'Web Browser', /** * Default image identifier. * * @syscap SystemCapability.BundleManager.BundleFramework.DefaultApp - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ IMAGE = 'Image Gallery', /** * Default audio identifier. * * @syscap SystemCapability.BundleManager.BundleFramework.DefaultApp - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ AUDIO = 'Audio Player', /** * Default video identifier. * * @syscap SystemCapability.BundleManager.BundleFramework.DefaultApp - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ VIDEO = 'Video Player', /** * Default PDF identifier. * * @syscap SystemCapability.BundleManager.BundleFramework.DefaultApp - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ PDF = 'PDF Viewer', /** * Default word identifier. * * @syscap SystemCapability.BundleManager.BundleFramework.DefaultApp - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ WORD = 'Word Viewer', /** * Default excel identifier. * * @syscap SystemCapability.BundleManager.BundleFramework.DefaultApp - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ EXCEL = 'Excel Viewer', /** * Default PPT identifier. * * @syscap SystemCapability.BundleManager.BundleFramework.DefaultApp - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ PPT = 'PPT Viewer', /** * Default email identifier. * * @syscap SystemCapability.BundleManager.BundleFramework.DefaultApp - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ EMAIL = 'Email' } @@ -111,7 +122,8 @@ declare namespace defaultAppManager { * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; 2. Incorrect parameter types. * @throws { BusinessError } 801 - Capability not supported. * @syscap SystemCapability.BundleManager.BundleFramework.DefaultApp - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function isDefaultApplication(type: string, callback: AsyncCallback): void; @@ -123,7 +135,8 @@ declare namespace defaultAppManager { * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; 2. Incorrect parameter types. * @throws { BusinessError } 801 - Capability not supported. * @syscap SystemCapability.BundleManager.BundleFramework.DefaultApp - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function isDefaultApplication(type: string): Promise; @@ -135,7 +148,8 @@ declare namespace defaultAppManager { * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; 2. Incorrect parameter types. * @throws { BusinessError } 801 - Capability not supported. * @syscap SystemCapability.BundleManager.BundleFramework.DefaultApp - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ function isDefaultApplicationSync(type: string): boolean; @@ -155,7 +169,8 @@ declare namespace defaultAppManager { * @throws { BusinessError } 17700025 - The specified type is invalid. * @syscap SystemCapability.BundleManager.BundleFramework.DefaultApp * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getDefaultApplication(type: string, userId: number, callback: AsyncCallback): void; @@ -173,7 +188,8 @@ declare namespace defaultAppManager { * @throws { BusinessError } 17700025 - The specified type is invalid. * @syscap SystemCapability.BundleManager.BundleFramework.DefaultApp * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getDefaultApplication(type: string, callback: AsyncCallback): void; @@ -193,7 +209,8 @@ declare namespace defaultAppManager { * @throws { BusinessError } 17700025 - The specified type is invalid. * @syscap SystemCapability.BundleManager.BundleFramework.DefaultApp * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getDefaultApplication(type: string, userId?: number): Promise; @@ -213,7 +230,8 @@ declare namespace defaultAppManager { * @throws { BusinessError } 17700025 - The specified type is invalid. * @syscap SystemCapability.BundleManager.BundleFramework.DefaultApp * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ function getDefaultApplicationSync(type: string, userId?: number): BundleInfo; @@ -234,7 +252,8 @@ declare namespace defaultAppManager { * @throws { BusinessError } 17700028 - The specified ability does not match the type. * @syscap SystemCapability.BundleManager.BundleFramework.DefaultApp * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function setDefaultApplication(type: string, elementName: ElementName, userId: number, callback: AsyncCallback): void; @@ -254,7 +273,8 @@ declare namespace defaultAppManager { * @throws { BusinessError } 17700028 - The specified ability does not match the type. * @syscap SystemCapability.BundleManager.BundleFramework.DefaultApp * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function setDefaultApplication(type: string, elementName: ElementName, callback: AsyncCallback): void; @@ -275,7 +295,8 @@ declare namespace defaultAppManager { * @throws { BusinessError } 17700028 - The specified ability does not match the type. * @syscap SystemCapability.BundleManager.BundleFramework.DefaultApp * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function setDefaultApplication(type: string, elementName: ElementName, userId?: number): Promise; @@ -295,7 +316,8 @@ declare namespace defaultAppManager { * @throws { BusinessError } 17700028 - The specified ability does not match the type. * @syscap SystemCapability.BundleManager.BundleFramework.DefaultApp * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ function setDefaultApplicationSync(type: string, elementName: ElementName, userId?: number): void; @@ -314,7 +336,8 @@ declare namespace defaultAppManager { * @throws { BusinessError } 17700025 - The specified type is invalid. * @syscap SystemCapability.BundleManager.BundleFramework.DefaultApp * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function resetDefaultApplication(type: string, userId: number, callback: AsyncCallback): void; @@ -331,7 +354,8 @@ declare namespace defaultAppManager { * @throws { BusinessError } 17700025 - The specified type is invalid. * @syscap SystemCapability.BundleManager.BundleFramework.DefaultApp * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function resetDefaultApplication(type: string, callback: AsyncCallback): void; @@ -350,7 +374,8 @@ declare namespace defaultAppManager { * @throws { BusinessError } 17700025 - The specified type is invalid. * @syscap SystemCapability.BundleManager.BundleFramework.DefaultApp * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function resetDefaultApplication(type: string, userId?: number): Promise; @@ -368,7 +393,8 @@ declare namespace defaultAppManager { * @throws { BusinessError } 17700025 - The specified type is invalid. * @syscap SystemCapability.BundleManager.BundleFramework.DefaultApp * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ function resetDefaultApplicationSync(type: string, userId?: number): void; } diff --git a/api/@ohos.bundle.distributedBundleManager.d.ts b/api/@ohos.bundle.distributedBundleManager.d.ts index bc13c960d8325e75f9821afb61046652ef04f563..a85231f931b605c07ccf6ffea065375f785df553 100644 --- a/api/@ohos.bundle.distributedBundleManager.d.ts +++ b/api/@ohos.bundle.distributedBundleManager.d.ts @@ -28,7 +28,8 @@ import { RemoteAbilityInfo as _RemoteAbilityInfo } from './bundleManager/RemoteA * @namespace distributedBundleManager * @syscap SystemCapability.BundleManager.DistributedBundleFramework * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ declare namespace distributedBundleManager { /** @@ -47,7 +48,8 @@ declare namespace distributedBundleManager { * @throws { BusinessError } 17700027 - The distributed service is not running. * @syscap SystemCapability.BundleManager.DistributedBundleFramework * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getRemoteAbilityInfo(elementName: ElementName, callback: AsyncCallback): void; @@ -67,7 +69,8 @@ declare namespace distributedBundleManager { * @throws { BusinessError } 17700027 - The distributed service is not running. * @syscap SystemCapability.BundleManager.DistributedBundleFramework * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getRemoteAbilityInfo(elementName: ElementName): Promise; @@ -87,7 +90,8 @@ declare namespace distributedBundleManager { * @throws { BusinessError } 17700027 - The distributed service is not running. * @syscap SystemCapability.BundleManager.DistributedBundleFramework * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getRemoteAbilityInfo(elementNames: Array, callback: AsyncCallback>): void; @@ -108,7 +112,8 @@ declare namespace distributedBundleManager { * @throws { BusinessError } 17700027 - The distributed service is not running. * @syscap SystemCapability.BundleManager.DistributedBundleFramework * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getRemoteAbilityInfo(elementNames: Array): Promise>; @@ -129,7 +134,8 @@ declare namespace distributedBundleManager { * @throws { BusinessError } 17700027 - The distributed service is not running. * @syscap SystemCapability.BundleManager.DistributedBundleFramework * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getRemoteAbilityInfo(elementName: ElementName, locale: string, callback: AsyncCallback): void; @@ -151,7 +157,8 @@ declare namespace distributedBundleManager { * @throws { BusinessError } 17700027 - The distributed service is not running. * @syscap SystemCapability.BundleManager.DistributedBundleFramework * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getRemoteAbilityInfo(elementName: ElementName, locale: string): Promise; @@ -172,7 +179,8 @@ declare namespace distributedBundleManager { * @throws { BusinessError } 17700027 - The distributed service is not running. * @syscap SystemCapability.BundleManager.DistributedBundleFramework * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getRemoteAbilityInfo(elementNames: Array, locale: string, callback: AsyncCallback>): void; @@ -194,7 +202,8 @@ declare namespace distributedBundleManager { * @throws { BusinessError } 17700027 - The distributed service is not running. * @syscap SystemCapability.BundleManager.DistributedBundleFramework * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getRemoteAbilityInfo(elementNames: Array, locale: string): Promise>; @@ -204,7 +213,8 @@ declare namespace distributedBundleManager { * @typedef { _RemoteAbilityInfo } * @syscap SystemCapability.BundleManager.DistributedBundleFramework * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ export type RemoteAbilityInfo = _RemoteAbilityInfo; } diff --git a/api/@ohos.bundle.freeInstall.d.ts b/api/@ohos.bundle.freeInstall.d.ts index 1a2aae8686d3ed7fd5d7621b03e5b783f7862dce..a156bc3015f1c7f48abd3b21740b3d7a72a65a83 100644 --- a/api/@ohos.bundle.freeInstall.d.ts +++ b/api/@ohos.bundle.freeInstall.d.ts @@ -20,7 +20,15 @@ import { AsyncCallback } from './@ohos.base'; import { DispatchInfo as _DispatchInfo } from './bundleManager/DispatchInfo'; +/*** if arkts 1.1 */ import * as _PackInfo from './bundleManager/BundlePackInfo'; +/*** endif */ +/*** if arkts 1.2 */ +import { BundlePackInfo as _BundlePackInfo, PackageConfig as _PackageConfig, PackageSummary as _PackageSummary, + BundleConfigInfo as _BundleConfigInfo, ExtensionAbility as _ExtensionAbility, ModuleConfigInfo as _ModuleConfigInfo, + ModuleDistroInfo as _ModuleDistroInfo, ModuleAbilityInfo as _ModuleAbilityInfo, AbilityFormInfo as _AbilityFormInfo, + Version as _Version, ApiVersion as _ApiVersion } from './bundleManager/BundlePackInfo'; +/*** endif */ /** * Free install bundle manager. @@ -28,7 +36,8 @@ import * as _PackInfo from './bundleManager/BundlePackInfo'; * @namespace freeInstall * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ declare namespace freeInstall { /** @@ -37,7 +46,8 @@ declare namespace freeInstall { * @enum { number } * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ export enum UpgradeFlag { /** @@ -45,7 +55,8 @@ declare namespace freeInstall { * * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ NOT_UPGRADE = 0, /** @@ -53,7 +64,8 @@ declare namespace freeInstall { * * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ SINGLE_UPGRADE = 1, /** @@ -61,7 +73,8 @@ declare namespace freeInstall { * * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ RELATION_UPGRADE = 2 } @@ -73,7 +86,8 @@ declare namespace freeInstall { * @enum { number } * @syscap SystemCapability.BundleManager.BundleFramework * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ export enum BundlePackFlag { /** @@ -81,7 +95,8 @@ declare namespace freeInstall { * * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ GET_PACK_INFO_ALL = 0x00000000, /** @@ -89,7 +104,8 @@ declare namespace freeInstall { * * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ GET_PACKAGES = 0x00000001, /** @@ -97,7 +113,8 @@ declare namespace freeInstall { * * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ GET_BUNDLE_SUMMARY = 0x00000002, /** @@ -105,7 +122,8 @@ declare namespace freeInstall { * * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ GET_MODULE_SUMMARY = 0x00000004 } @@ -126,7 +144,8 @@ declare namespace freeInstall { * @throws { BusinessError } 17700002 - The specified module name is not found. * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function setHapModuleUpgradeFlag(bundleName: string, moduleName: string, upgradeFlag: UpgradeFlag, callback: AsyncCallback): void; @@ -147,7 +166,8 @@ declare namespace freeInstall { * @throws { BusinessError } 17700002 - The specified module name is not found. * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function setHapModuleUpgradeFlag(bundleName: string, moduleName: string, upgradeFlag: UpgradeFlag): Promise; @@ -167,7 +187,8 @@ declare namespace freeInstall { * @throws { BusinessError } 17700002 - The specified module name is not found. * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function isHapModuleRemovable(bundleName: string, moduleName: string, callback: AsyncCallback): void; @@ -186,7 +207,8 @@ declare namespace freeInstall { * @throws { BusinessError } 17700002 - The specified module name is not found. * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function isHapModuleRemovable(bundleName: string, moduleName: string): Promise; @@ -204,7 +226,8 @@ declare namespace freeInstall { * @throws { BusinessError } 17700001 - The specified bundle name is not found. * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getBundlePackInfo(bundleName: string, bundlePackFlag: BundlePackFlag, callback: AsyncCallback): void; @@ -223,7 +246,8 @@ declare namespace freeInstall { * @throws { BusinessError } 17700001 - The specified bundle name is not found. * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getBundlePackInfo(bundleName: string, bundlePackFlag: BundlePackFlag): Promise; @@ -237,7 +261,8 @@ declare namespace freeInstall { * @throws { BusinessError } 801 - Capability not supported. * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getDispatchInfo(callback: AsyncCallback): void; @@ -251,7 +276,8 @@ declare namespace freeInstall { * @throws { BusinessError } 801 - Capability not supported. * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getDispatchInfo(): Promise; @@ -261,7 +287,8 @@ declare namespace freeInstall { * @typedef { _DispatchInfo } * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ export type DispatchInfo = _DispatchInfo; @@ -275,6 +302,17 @@ declare namespace freeInstall { */ export type BundlePackInfo = _PackInfo.BundlePackInfo; + /** + * The bundle pack info class. + * + * @typedef { _BundlePackInfo } + * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall + * @systemapi + * @since 20 + * @arkts 1.2 + */ + export type BundlePackInfo = _BundlePackInfo; + /** * The package info class. * @@ -285,6 +323,17 @@ declare namespace freeInstall { */ export type PackageConfig = _PackInfo.PackageConfig; + /** + * The package info class. + * + * @typedef { _PackageConfig } + * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall + * @systemapi + * @since 20 + * @arkts 1.2 + */ + export type PackageConfig = _PackageConfig; + /** * The package summary class. * @@ -295,6 +344,17 @@ declare namespace freeInstall { */ export type PackageSummary = _PackInfo.PackageSummary; + /** + * The package summary class. + * + * @typedef { _PackageSummary } + * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall + * @systemapi + * @since 20 + * @arkts 1.2 + */ + export type PackageSummary = _PackageSummary; + /** * The bundle summary class. * @@ -305,6 +365,17 @@ declare namespace freeInstall { */ export type BundleConfigInfo = _PackInfo.BundleConfigInfo; + /** + * The bundle summary class. + * + * @typedef { _BundleConfigInfo } + * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall + * @systemapi + * @since 20 + * @arkts 1.2 + */ + export type BundleConfigInfo = _BundleConfigInfo; + /** * The extension ability forms class. * @@ -315,6 +386,17 @@ declare namespace freeInstall { */ export type ExtensionAbility = _PackInfo.ExtensionAbility; + /** + * The extension ability forms class. + * + * @typedef { _ExtensionAbility } + * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall + * @systemapi + * @since 20 + * @arkts 1.2 + */ + export type ExtensionAbility = _ExtensionAbility; + /** * The module summary of a bundle. * @@ -325,6 +407,17 @@ declare namespace freeInstall { */ export type ModuleConfigInfo = _PackInfo.ModuleConfigInfo; + /** + * The module summary of a bundle. + * + * @typedef { _ModuleConfigInfo } + * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall + * @systemapi + * @since 20 + * @arkts 1.2 + */ + export type ModuleConfigInfo = _ModuleConfigInfo; + /** * The bundle info summary class. * @@ -335,6 +428,17 @@ declare namespace freeInstall { */ export type ModuleDistroInfo = _PackInfo.ModuleDistroInfo; + /** + * The bundle info summary class. + * + * @typedef { _ModuleDistroInfo } + * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall + * @systemapi + * @since 20 + * @arkts 1.2 + */ + export type ModuleDistroInfo = _ModuleDistroInfo; + /** * The ability info of a module. * @@ -345,6 +449,17 @@ declare namespace freeInstall { */ export type ModuleAbilityInfo = _PackInfo.ModuleAbilityInfo; + /** + * The ability info of a module. + * + * @typedef { _ModuleAbilityInfo } + * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall + * @systemapi + * @since 20 + * @arkts 1.2 + */ + export type ModuleAbilityInfo = _ModuleAbilityInfo; + /** * The form info of an ability. * @@ -355,6 +470,17 @@ declare namespace freeInstall { */ export type AbilityFormInfo = _PackInfo.AbilityFormInfo; + /** + * The form info of an ability. + * + * @typedef { _AbilityFormInfo } + * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall + * @systemapi + * @since 20 + * @arkts 1.2 + */ + export type AbilityFormInfo = _AbilityFormInfo; + /** * The bundle version class. * @@ -365,6 +491,17 @@ declare namespace freeInstall { */ export type Version = _PackInfo.Version; + /** + * The bundle version class. + * + * @typedef { _Version } + * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall + * @systemapi + * @since 20 + * @arkts 1.2 + */ + export type Version = _Version; + /** * The bundle Api version class. * @@ -374,6 +511,17 @@ declare namespace freeInstall { * @since 9 */ export type ApiVersion = _PackInfo.ApiVersion; + + /** + * The bundle Api version class. + * + * @typedef { _ApiVersion } + * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall + * @systemapi + * @since 20 + * @arkts 1.2 + */ + export type ApiVersion = _ApiVersion; } export default freeInstall; diff --git a/api/@ohos.bundle.installer.d.ts b/api/@ohos.bundle.installer.d.ts index 6f0fc7461faa38eb547fad67df3bd431f2bcaddb..e3623e7de418b378adaf7dc5b182c6a51a266cb2 100644 --- a/api/@ohos.bundle.installer.d.ts +++ b/api/@ohos.bundle.installer.d.ts @@ -26,7 +26,8 @@ import { AsyncCallback } from './@ohos.base'; * @namespace installer * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ declare namespace installer { /** @@ -37,7 +38,8 @@ declare namespace installer { * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Incorrect parameter types. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getBundleInstaller(callback: AsyncCallback): void; @@ -48,7 +50,8 @@ declare namespace installer { * @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getBundleInstaller(): Promise; @@ -59,7 +62,8 @@ declare namespace installer { * @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ function getBundleInstallerSync(): BundleInstaller; @@ -69,7 +73,8 @@ declare namespace installer { * @interface BundleInstaller * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ interface BundleInstaller { /** @@ -363,7 +368,8 @@ declare namespace installer { * @throws { BusinessError } 17700077 - Failed to install the HAP and restore to preinstalled bundle. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 18 + * @since arkts {'1.1':'18', '1.2':'20'} + * @arkts 1.1&1.2 */ install(hapFilePaths: Array, installParam: InstallParam, callback: AsyncCallback): void; @@ -640,7 +646,8 @@ declare namespace installer { * @throws { BusinessError } 17700077 - Failed to install the HAP and restore to preinstalled bundle. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 18 + * @since arkts {'1.1':'18', '1.2':'20'} + * @arkts 1.1&1.2 */ install(hapFilePaths: Array, callback: AsyncCallback): void; @@ -935,7 +942,8 @@ declare namespace installer { * @throws { BusinessError } 17700077 - Failed to install the HAP and restore to preinstalled bundle. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 18 + * @since arkts {'1.1':'18', '1.2':'20'} + * @arkts 1.1&1.2 */ install(hapFilePaths: Array, installParam?: InstallParam): Promise; @@ -1019,7 +1027,8 @@ declare namespace installer { * @throws { BusinessError } 17700067 - Failed to uninstall the HAP because uninstalling the native package failed. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 15 + * @since arkts {'1.1':'15', '1.2':'20'} + * @arkts 1.1&1.2 */ uninstall(bundleName: string, installParam: InstallParam, callback: AsyncCallback): void; @@ -1075,7 +1084,8 @@ declare namespace installer { * @throws { BusinessError } 17700067 - Failed to uninstall the HAP because uninstalling the native package failed. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 13 + * @since arkts {'1.1':'13', '1.2':'20'} + * @arkts 1.1&1.2 */ uninstall(bundleName: string, callback: AsyncCallback): void; @@ -1159,7 +1169,8 @@ declare namespace installer { * @throws { BusinessError } 17700067 - Failed to uninstall the HAP because uninstalling the native package failed. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 15 + * @since arkts {'1.1':'15', '1.2':'20'} + * @arkts 1.1&1.2 */ uninstall(bundleName: string, installParam?: InstallParam): Promise; @@ -1215,7 +1226,8 @@ declare namespace installer { *
bundle name but different signature information exists on the device. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ recover(bundleName: string, installParam: InstallParam, callback: AsyncCallback): void; @@ -1265,7 +1277,8 @@ declare namespace installer { *
bundle name but different signature information exists on the device. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ recover(bundleName: string, callback: AsyncCallback): void; @@ -1321,7 +1334,8 @@ declare namespace installer { *
bundle name but different signature information exists on the device. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ recover(bundleName: string, installParam?: InstallParam): Promise; @@ -1339,7 +1353,8 @@ declare namespace installer { * @throws { BusinessError } 17700038 - The specified shared bundle does not exist. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ uninstall(uninstallParam: UninstallParam, callback: AsyncCallback): void; @@ -1357,7 +1372,8 @@ declare namespace installer { * @throws { BusinessError } 17700038 - The specified shared bundle does not exist. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ uninstall(uninstallParam: UninstallParam): Promise; @@ -1429,7 +1445,8 @@ declare namespace installer { * @throws { BusinessError } 17700051 - Failed to install the HAP because the distribution type of caller application is not enterprise_mdm. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ updateBundleForSelf(hapFilePaths: Array, installParam: InstallParam, callback: AsyncCallback): void; @@ -1493,7 +1510,8 @@ declare namespace installer { * @throws { BusinessError } 17700051 - Failed to install the HAP because the distribution type of caller application is not enterprise_mdm. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ updateBundleForSelf(hapFilePaths: Array, callback: AsyncCallback): void; @@ -1565,7 +1583,8 @@ declare namespace installer { * @throws { BusinessError } 17700051 - Failed to install the HAP because the distribution type of caller application is not enterprise_mdm. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ updateBundleForSelf(hapFilePaths: Array, installParam?: InstallParam): Promise; @@ -1605,7 +1624,8 @@ declare namespace installer { *
bundle name but different signature information exists on the device. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 13 + * @since arkts {'1.1':'13', '1.2':'20'} + * @arkts 1.1&1.2 */ uninstallUpdates(bundleName: string, installParam?: InstallParam): Promise; @@ -1623,7 +1643,8 @@ declare namespace installer { * @throws { BusinessError } 17700301 - AddExtResource failed due to parse file failed. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ addExtResource(bundleName: string, filePaths: Array): Promise; @@ -1641,7 +1662,8 @@ declare namespace installer { * @throws { BusinessError } 17700302 - RemoveExtResource failed due to module does not exist. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ removeExtResource(bundleName: string, moduleNames: Array): Promise; @@ -1661,7 +1683,8 @@ declare namespace installer { * @throws { BusinessError } 17700069 - The app does not support the creation of an appClone instance. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ createAppClone(bundleName: string, createAppCloneParam?: CreateAppCloneParam): Promise; @@ -1706,6 +1729,28 @@ declare namespace installer { */ destroyAppClone(bundleName: string, appIndex: number, destroyAppCloneParam?: DestroyAppCloneParam): Promise; + /** + * Destroy clone instance for an application. + * + * @permission ohos.permission.UNINSTALL_CLONE_BUNDLE + * @param { string } bundleName - Indicates the bundleName of clone app. + * @param { number } appIndex - Indicates the clone application's index. + * @param { number | DestroyAppCloneParam } [options] - Indicates other parameters required for the uninstallation. + * @returns { Promise } the promise returned by the function. + * @throws { BusinessError } 201 - Calling interface without permission 'ohos.permission.UNINSTALL_CLONE_BUNDLE'. + * @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API. + * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; 2. Incorrect parameter types. + * @throws { BusinessError } 17700001 - The specified bundleName cannot be found or the bundle is not installed by the specified user. + * @throws { BusinessError } 17700004 - The userId is invalid. + * @throws { BusinessError } 17700061 - AppIndex not in valid range. + * @throws { BusinessError } 17700062 - Failed to uninstall the app because the app is locked. + * @syscap SystemCapability.BundleManager.BundleFramework.Core + * @systemapi + * @since 20 + * @arkts 1.2 + */ + destroyAppClone(bundleName: string, appIndex: number, options?: number | DestroyAppCloneParam): Promise; + /** * Install application by bundle name with specified user. * @@ -1740,7 +1785,8 @@ declare namespace installer { *
from being installed on this device or by specified users. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ installPreexistingApp(bundleName: string, userId?: number): Promise; @@ -1773,7 +1819,8 @@ declare namespace installer { * @throws { BusinessError } 17700091 - Failed to install the plugin because the plugin name is same as host bundle name. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 19 + * @since arkts {'1.1':'19', '1.2':'20'} + * @arkts 1.1&1.2 */ installPlugin(hostBundleName: string, pluginFilePaths: Array, pluginParam?: PluginParam): Promise; @@ -1792,7 +1839,8 @@ declare namespace installer { * @throws { BusinessError } 17700092 - Failed to uninstall the plugin because the specified plugin is not found. * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 19 + * @since arkts {'1.1':'19', '1.2':'20'} + * @arkts 1.1&1.2 */ uninstallPlugin(hostBundleName: string, pluginBundleName: string, pluginParam?: PluginParam): Promise; } @@ -1803,7 +1851,8 @@ declare namespace installer { * @typedef HashParam * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ export interface HashParam { /** @@ -1812,7 +1861,8 @@ declare namespace installer { * @type { string } * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ moduleName: string; @@ -1822,7 +1872,8 @@ declare namespace installer { * @type { string } * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ hashValue: string; } @@ -1866,7 +1917,8 @@ declare namespace installer { * @typedef PGOParam * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ export interface PGOParam { /** @@ -1875,7 +1927,8 @@ declare namespace installer { * @type { string } * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ moduleName: string; @@ -1885,7 +1938,8 @@ declare namespace installer { * @type { string } * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ pgoFilePath: string; } @@ -1896,7 +1950,8 @@ declare namespace installer { * @typedef Parameters * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 15 + * @since arkts {'1.1':'15', '1.2':'20'} + * @arkts 1.1&1.2 */ export interface Parameters { /** @@ -1905,7 +1960,8 @@ declare namespace installer { * @type { string } * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 15 + * @since arkts {'1.1':'15', '1.2':'20'} + * @arkts 1.1&1.2 */ key: string; @@ -1915,7 +1971,8 @@ declare namespace installer { * @type { string } * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 15 + * @since arkts {'1.1':'15', '1.2':'20'} + * @arkts 1.1&1.2 */ value: string; } @@ -1926,7 +1983,8 @@ declare namespace installer { * @typedef InstallParam * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ export interface InstallParam { /** @@ -1935,7 +1993,8 @@ declare namespace installer { * @type { ?number } * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ userId?: number; @@ -1945,7 +2004,8 @@ declare namespace installer { * @type { ?number } * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ installFlag?: number; @@ -1955,7 +2015,8 @@ declare namespace installer { * @type { ?boolean } * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ isKeepData?: boolean; @@ -1965,7 +2026,8 @@ declare namespace installer { * @type { ?Array } * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ hashParams?: Array; @@ -1975,7 +2037,8 @@ declare namespace installer { * @type { ?number } * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ crowdtestDeadline?: number; @@ -1985,7 +2048,8 @@ declare namespace installer { * @type { ?Array } * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ sharedBundleDirPaths?: Array; @@ -1995,7 +2059,8 @@ declare namespace installer { * @type { ?string } * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ specifiedDistributionType?: string; @@ -2005,7 +2070,8 @@ declare namespace installer { * @type { ?string } * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ additionalInfo?: string; @@ -2026,7 +2092,8 @@ declare namespace installer { * @type { ?Array } * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ pgoParams?: Array; @@ -2036,7 +2103,8 @@ declare namespace installer { * @type { ?Array } * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 15 + * @since arkts {'1.1':'15', '1.2':'20'} + * @arkts 1.1&1.2 */ parameters?: Array; } @@ -2047,7 +2115,8 @@ declare namespace installer { * @typedef UninstallParam * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ export interface UninstallParam { /** @@ -2056,7 +2125,8 @@ declare namespace installer { * @type { string } * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ bundleName: string; @@ -2066,7 +2136,8 @@ declare namespace installer { * @type { ?number } * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ versionCode?: number; } @@ -2077,7 +2148,8 @@ declare namespace installer { * @typedef CreateAppCloneParam * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ export interface CreateAppCloneParam { /** @@ -2086,7 +2158,8 @@ declare namespace installer { * @type { ?number } * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ userId?: number; /** @@ -2095,7 +2168,8 @@ declare namespace installer { * @type { ?number } * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ appIndex?: number; } @@ -2106,7 +2180,8 @@ declare namespace installer { * @typedef DestroyAppCloneParam * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 15 + * @since arkts {'1.1':'15', '1.2':'20'} + * @arkts 1.1&1.2 */ export interface DestroyAppCloneParam { /** @@ -2115,7 +2190,8 @@ declare namespace installer { * @type { ?number } * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 15 + * @since arkts {'1.1':'15', '1.2':'20'} + * @arkts 1.1&1.2 */ userId?: number; /** @@ -2124,7 +2200,8 @@ declare namespace installer { * @type { ?Array } * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 15 + * @since arkts {'1.1':'15', '1.2':'20'} + * @arkts 1.1&1.2 */ parameters?: Array; } @@ -2135,7 +2212,8 @@ declare namespace installer { * @typedef PluginParam * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 19 + * @since arkts {'1.1':'19', '1.2':'20'} + * @arkts 1.1&1.2 */ export interface PluginParam { /** @@ -2144,7 +2222,8 @@ declare namespace installer { * @type { ?number } * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 19 + * @since arkts {'1.1':'19', '1.2':'20'} + * @arkts 1.1&1.2 */ userId?: number; @@ -2154,7 +2233,8 @@ declare namespace installer { * @type { ?Array } * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 19 + * @since arkts {'1.1':'19', '1.2':'20'} + * @arkts 1.1&1.2 */ parameters?: Array; } diff --git a/api/@ohos.bundle.launcherBundleManager.d.ts b/api/@ohos.bundle.launcherBundleManager.d.ts index 04a2b525eb088ff1f5fa8d0b7f8d30d4f69dc011..d6d897bb7386f67851583a24b19e9a31b7288c29 100644 --- a/api/@ohos.bundle.launcherBundleManager.d.ts +++ b/api/@ohos.bundle.launcherBundleManager.d.ts @@ -18,9 +18,9 @@ * @kit AbilityKit */ -/*** if arkts 1.1 */ import { AsyncCallback } from './@ohos.base'; import { LauncherAbilityInfo as _LauncherAbilityInfo } from './bundleManager/LauncherAbilityInfo'; +/*** if arkts 1.1 */ import AbilityConstant from './@ohos.app.ability.AbilityConstant'; /*** endif */ import { ShortcutInfo as _ShortcutInfo, ShortcutWant as _ShortcutWant, ParameterItem as _ParameterItem } from './bundleManager/ShortcutInfo'; @@ -50,7 +50,8 @@ declare namespace launcherBundleManager { * @throws { BusinessError } 17700004 - The specified user ID is not found. * @syscap SystemCapability.BundleManager.BundleFramework.Launcher * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getLauncherAbilityInfo(bundleName: string, userId: number, callback: AsyncCallback>): void; @@ -70,7 +71,8 @@ declare namespace launcherBundleManager { * @throws { BusinessError } 17700004 - The specified user ID is not found. * @syscap SystemCapability.BundleManager.BundleFramework.Launcher * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getLauncherAbilityInfo(bundleName: string, userId: number): Promise>; @@ -86,7 +88,8 @@ declare namespace launcherBundleManager { * @throws { BusinessError } 17700001 - The specified bundle name is not found. * @throws { BusinessError } 17700004 - The specified user ID is not found. * @syscap SystemCapability.BundleManager.BundleFramework.Launcher - * @since 18 + * @since arkts {'1.1':'18', '1.2':'20'} + * @arkts 1.1&1.2 */ function getLauncherAbilityInfoSync(bundleName: string, userId: number): Array; @@ -103,7 +106,8 @@ declare namespace launcherBundleManager { * @throws { BusinessError } 17700004 - The specified user ID is not found. * @syscap SystemCapability.BundleManager.BundleFramework.Launcher * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getAllLauncherAbilityInfo(userId: number, callback: AsyncCallback>): void; @@ -120,7 +124,8 @@ declare namespace launcherBundleManager { * @throws { BusinessError } 17700004 - The specified user ID is not found. * @syscap SystemCapability.BundleManager.BundleFramework.Launcher * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getAllLauncherAbilityInfo(userId: number): Promise>; @@ -137,7 +142,8 @@ declare namespace launcherBundleManager { * @throws { BusinessError } 17700001 - The specified bundle name is not found. * @syscap SystemCapability.BundleManager.BundleFramework.Launcher * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getShortcutInfo(bundleName: string, callback: AsyncCallback>): void; @@ -154,7 +160,8 @@ declare namespace launcherBundleManager { * @throws { BusinessError } 17700001 - The specified bundle name is not found. * @syscap SystemCapability.BundleManager.BundleFramework.Launcher * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ function getShortcutInfo(bundleName: string): Promise>; @@ -258,7 +265,8 @@ declare namespace launcherBundleManager { * * @typedef { _LauncherAbilityInfo } * @syscap SystemCapability.BundleManager.BundleFramework.Launcher - * @since 18 + * @since arkts {'1.1':'18', '1.2':'20'} + * @arkts 1.1&1.2 */ export type LauncherAbilityInfo = _LauncherAbilityInfo; diff --git a/api/@ohos.bundle.overlay.d.ts b/api/@ohos.bundle.overlay.d.ts index 56f0b171e9dfc5c821d63d75142d85d84d2d6bbc..f4bcece3b431ce1b9c80ccbb7041a6bda3a6821c 100755 --- a/api/@ohos.bundle.overlay.d.ts +++ b/api/@ohos.bundle.overlay.d.ts @@ -19,14 +19,20 @@ */ import { AsyncCallback } from './@ohos.base'; +/*** if arkts 1.1 */ import * as _OverlayModuleInfo from './bundleManager/OverlayModuleInfo'; +/*** endif */ +/*** if arkts 1.2 */ +import { OverlayModuleInfo as _OverlayModuleInfo } from './bundleManager/OverlayModuleInfo'; +/*** endif */ /** * Used for application interception overlay * * @namespace overlay * @syscap SystemCapability.BundleManager.BundleFramework.Overlay - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ declare namespace overlay { /** @@ -39,7 +45,8 @@ declare namespace overlay { * @throws { BusinessError } 17700002 - The specified module name is not found. * @throws { BusinessError } 17700033 - The specified module is not an overlay module. * @syscap SystemCapability.BundleManager.BundleFramework.Overlay - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ function setOverlayEnabled(moduleName: string, isEnabled: boolean, callback: AsyncCallback): void; @@ -53,7 +60,8 @@ declare namespace overlay { * @throws { BusinessError } 17700002 - The specified module name is not found. * @throws { BusinessError } 17700033 - The specified module is not an overlay module. * @syscap SystemCapability.BundleManager.BundleFramework.Overlay - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ function setOverlayEnabled(moduleName: string, isEnabled: boolean): Promise; @@ -74,7 +82,8 @@ declare namespace overlay { * @throws { BusinessError } 17700033 - The specified module is not an overlay module. * @syscap SystemCapability.BundleManager.BundleFramework.Overlay * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ function setOverlayEnabledByBundleName(bundleName: string, moduleName: string, isEnabled: boolean, callback: AsyncCallback): void; @@ -96,7 +105,8 @@ declare namespace overlay { * @throws { BusinessError } 17700033 - The specified module is not an overlay module. * @syscap SystemCapability.BundleManager.BundleFramework.Overlay * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ function setOverlayEnabledByBundleName(bundleName: string, moduleName: string, isEnabled: boolean): Promise; @@ -110,7 +120,8 @@ declare namespace overlay { * @throws { BusinessError } 17700032 - The specified bundle does not contain any overlay module. * @throws { BusinessError } 17700033 - The specified module is not an overlay module. * @syscap SystemCapability.BundleManager.BundleFramework.Overlay - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ function getOverlayModuleInfo(moduleName: string, callback: AsyncCallback): void; @@ -124,7 +135,8 @@ declare namespace overlay { * @throws { BusinessError } 17700032 - The specified bundle does not contain any overlay module. * @throws { BusinessError } 17700033 - The specified module is not an overlay module. * @syscap SystemCapability.BundleManager.BundleFramework.Overlay - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ function getOverlayModuleInfo(moduleName: string): Promise; @@ -137,7 +149,8 @@ declare namespace overlay { * @throws { BusinessError } 17700002 - The specified module name is not found. * @throws { BusinessError } 17700034 - The specified module is an overlay module. * @syscap SystemCapability.BundleManager.BundleFramework.Overlay - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ function getTargetOverlayModuleInfos(targetModuleName: string, callback: AsyncCallback>): void; @@ -151,7 +164,8 @@ declare namespace overlay { * @throws { BusinessError } 17700002 - The specified module name is not found. * @throws { BusinessError } 17700034 - The specified module is an overlay module. * @syscap SystemCapability.BundleManager.BundleFramework.Overlay - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ function getTargetOverlayModuleInfos(targetModuleName: string): Promise>; @@ -168,7 +182,8 @@ declare namespace overlay { * @throws { BusinessError } 17700032 - The specified bundle does not contain any overlay module. * @syscap SystemCapability.BundleManager.BundleFramework.Overlay * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ function getOverlayModuleInfoByBundleName(bundleName: string, callback: AsyncCallback>): void; @@ -189,7 +204,8 @@ declare namespace overlay { * @throws { BusinessError } 17700033 - The specified module is not an overlay module. * @syscap SystemCapability.BundleManager.BundleFramework.Overlay * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ function getOverlayModuleInfoByBundleName(bundleName: string, moduleName: string, callback: AsyncCallback>): void; @@ -210,7 +226,8 @@ declare namespace overlay { * @throws { BusinessError } 17700033 - The specified module is not an overlay module. * @syscap SystemCapability.BundleManager.BundleFramework.Overlay * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ function getOverlayModuleInfoByBundleName(bundleName: string, moduleName?: string): Promise>; @@ -228,7 +245,8 @@ declare namespace overlay { * @throws { BusinessError } 17700035 - The specified bundle is an overlay bundle. * @syscap SystemCapability.BundleManager.BundleFramework.Overlay * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ function getTargetOverlayModuleInfosByBundleName(targetBundleName: string, callback: AsyncCallback>): void; @@ -249,7 +267,8 @@ declare namespace overlay { * @throws { BusinessError } 17700035 - The specified bundle is an overlay bundle. * @syscap SystemCapability.BundleManager.BundleFramework.Overlay * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ function getTargetOverlayModuleInfosByBundleName(targetBundleName: string, moduleName: string, callback: AsyncCallback>): void; @@ -270,7 +289,8 @@ declare namespace overlay { * @throws { BusinessError } 17700035 - The specified bundle is an overlay bundle. * @syscap SystemCapability.BundleManager.BundleFramework.Overlay * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ function getTargetOverlayModuleInfosByBundleName(targetBundleName: string, moduleName?: string): Promise>; @@ -283,6 +303,16 @@ declare namespace overlay { * @since 10 */ export type OverlayModuleInfo = _OverlayModuleInfo.OverlayModuleInfo; + + /** + * Obtains configuration information about a overlay hap module. + * + * @typedef { _OverlayModuleInfo } + * @syscap SystemCapability.BundleManager.BundleFramework.Overlay + * @since 20 + * @arkts 1.2 + */ + export type OverlayModuleInfo = _OverlayModuleInfo; } export default overlay; diff --git a/api/@ohos.configPolicy.d.ts b/api/@ohos.configPolicy.d.ts index 30a15b2ab8421e2a160ed76c3d283e9a151ba42d..2bffaa511e3ed6ecf2ec479ed921aab40a669bd2 100644 --- a/api/@ohos.configPolicy.d.ts +++ b/api/@ohos.configPolicy.d.ts @@ -16,6 +16,7 @@ /** * @file * @kit BasicServicesKit + * @arkts 1.1&1.2 */ import { AsyncCallback } from './@ohos.base'; @@ -26,7 +27,7 @@ import { AsyncCallback } from './@ohos.base'; * @namespace configPolicy * @syscap SystemCapability.Customization.ConfigPolicy * @systemapi - * @since 8 + * @since arkts {'1.1':'8','1.2':'20'} */ declare namespace configPolicy { /** @@ -35,7 +36,7 @@ declare namespace configPolicy { * @enum { number } * @syscap SystemCapability.Customization.ConfigPolicy * @systemapi - * @since 11 + * @since arkts {'1.1':'11','1.2':'20'} */ export enum FollowXMode { /** @@ -43,7 +44,7 @@ declare namespace configPolicy { * * @syscap SystemCapability.Customization.ConfigPolicy * @systemapi - * @since 11 + * @since arkts {'1.1':'11','1.2':'20'} */ DEFAULT = 0, @@ -52,7 +53,7 @@ declare namespace configPolicy { * * @syscap SystemCapability.Customization.ConfigPolicy * @systemapi - * @since 11 + * @since arkts {'1.1':'11','1.2':'20'} */ NO_RULE_FOLLOWED = 1, @@ -61,7 +62,7 @@ declare namespace configPolicy { * * @syscap SystemCapability.Customization.ConfigPolicy * @systemapi - * @since 11 + * @since arkts {'1.1':'11','1.2':'20'} */ SIM_DEFAULT = 10, @@ -70,7 +71,7 @@ declare namespace configPolicy { * * @syscap SystemCapability.Customization.ConfigPolicy * @systemapi - * @since 11 + * @since arkts {'1.1':'11','1.2':'20'} */ SIM_1 = 11, @@ -79,7 +80,7 @@ declare namespace configPolicy { * * @syscap SystemCapability.Customization.ConfigPolicy * @systemapi - * @since 11 + * @since arkts {'1.1':'11','1.2':'20'} */ SIM_2 = 12, @@ -89,7 +90,7 @@ declare namespace configPolicy { * * @syscap SystemCapability.Customization.ConfigPolicy * @systemapi - * @since 11 + * @since arkts {'1.1':'11','1.2':'20'} */ USER_DEFINED = 100 } @@ -103,9 +104,9 @@ declare namespace configPolicy { *
2.Incorrect parameter types. * @syscap SystemCapability.Customization.ConfigPolicy * @systemapi Hide this for inner system use. - * @since 8 + * @since arkts {'1.1':'8','1.2':'20'} */ - function getOneCfgFile(relPath: string, callback: AsyncCallback); + function getOneCfgFile(relPath: string, callback: AsyncCallback): void; /** * Gets the file from the highest priority config path containing the given file name in follow mode. @@ -117,9 +118,9 @@ declare namespace configPolicy { *
2.Incorrect parameter types. * @syscap SystemCapability.Customization.ConfigPolicy * @systemapi Hide this for inner system use. - * @since 11 + * @since arkts {'1.1':'11','1.2':'20'} */ - function getOneCfgFile(relPath: string, followMode: FollowXMode, callback: AsyncCallback); + function getOneCfgFile(relPath: string, followMode: FollowXMode, callback: AsyncCallback): void; /** * Gets the file from the highest priority config path containing the given file name in follow mode. @@ -132,9 +133,9 @@ declare namespace configPolicy { *
2.Incorrect parameter types. * @syscap SystemCapability.Customization.ConfigPolicy * @systemapi Hide this for inner system use. - * @since 11 + * @since arkts {'1.1':'11','1.2':'20'} */ - function getOneCfgFile(relPath: string, followMode: FollowXMode, extra: string, callback: AsyncCallback); + function getOneCfgFile(relPath: string, followMode: FollowXMode, extra: string, callback: AsyncCallback): void; /** * Gets the file from the highest priority config path containing the given file name. @@ -145,7 +146,7 @@ declare namespace configPolicy { *
2.Incorrect parameter types. * @syscap SystemCapability.Customization.ConfigPolicy * @systemapi Hide this for inner system use. - * @since 8 + * @since arkts {'1.1':'8','1.2':'20'} */ function getOneCfgFile(relPath: string): Promise; @@ -160,7 +161,7 @@ declare namespace configPolicy { *
2.Incorrect parameter types; 3.Parameter verification failed. * @syscap SystemCapability.Customization.ConfigPolicy * @systemapi Hide this for inner system use. - * @since 11 + * @since arkts {'1.1':'11','1.2':'20'} */ function getOneCfgFile(relPath: string, followMode: FollowXMode, extra?: string): Promise; @@ -175,7 +176,7 @@ declare namespace configPolicy { *
2.Incorrect parameter types; 3.Parameter verification failed. * @syscap SystemCapability.Customization.ConfigPolicy * @systemapi Hide this for inner system use. - * @since 11 + * @since arkts {'1.1':'11','1.2':'20'} */ function getOneCfgFileSync(relPath: string, followMode?: FollowXMode, extra?: string): string; @@ -188,9 +189,9 @@ declare namespace configPolicy { *
2.Incorrect parameter types. * @syscap SystemCapability.Customization.ConfigPolicy * @systemapi Hide this for inner system use. - * @since 8 + * @since arkts {'1.1':'8','1.2':'20'} */ - function getCfgFiles(relPath: string, callback: AsyncCallback>); + function getCfgFiles(relPath: string, callback: AsyncCallback>): void; /** * Gets the config files in device architecture in follow mode, ordered by priority from low to high. @@ -202,9 +203,9 @@ declare namespace configPolicy { *
2.Incorrect parameter types. * @syscap SystemCapability.Customization.ConfigPolicy * @systemapi Hide this for inner system use. - * @since 11 + * @since arkts {'1.1':'11','1.2':'20'} */ - function getCfgFiles(relPath: string, followMode: FollowXMode, callback: AsyncCallback>); + function getCfgFiles(relPath: string, followMode: FollowXMode, callback: AsyncCallback>): void; /** * Gets the config files in device architecture in follow mode, ordered by priority from low to high. @@ -217,9 +218,9 @@ declare namespace configPolicy { *
2.Incorrect parameter types. * @syscap SystemCapability.Customization.ConfigPolicy * @systemapi Hide this for inner system use. - * @since 11 + * @since arkts {'1.1':'11','1.2':'20'} */ - function getCfgFiles(relPath: string, followMode: FollowXMode, extra: string, callback: AsyncCallback>); + function getCfgFiles(relPath: string, followMode: FollowXMode, extra: string, callback: AsyncCallback>): void; /** * Gets the config files in device architecture, ordered by priority from low to high. @@ -230,7 +231,7 @@ declare namespace configPolicy { *
2.Incorrect parameter types. * @syscap SystemCapability.Customization.ConfigPolicy * @systemapi Hide this for inner system use. - * @since 8 + * @since arkts {'1.1':'8','1.2':'20'} */ function getCfgFiles(relPath: string): Promise>; @@ -245,7 +246,7 @@ declare namespace configPolicy { *
2.Incorrect parameter types; 3.Parameter verification failed. * @syscap SystemCapability.Customization.ConfigPolicy * @systemapi Hide this for inner system use. - * @since 11 + * @since arkts {'1.1':'11','1.2':'20'} */ function getCfgFiles(relPath: string, followMode: FollowXMode, extra?: string): Promise>; @@ -260,7 +261,7 @@ declare namespace configPolicy { *
2.Incorrect parameter types; 3.Parameter verification failed. * @syscap SystemCapability.Customization.ConfigPolicy * @systemapi Hide this for inner system use. - * @since 11 + * @since arkts {'1.1':'11','1.2':'20'} */ function getCfgFilesSync(relPath: string, followMode?: FollowXMode, extra?: string): Array; @@ -272,9 +273,9 @@ declare namespace configPolicy { *
2.Incorrect parameter types. * @syscap SystemCapability.Customization.ConfigPolicy * @systemapi Hide this for inner system use. - * @since 8 + * @since arkts {'1.1':'8','1.2':'20'} */ - function getCfgDirList(callback: AsyncCallback>); + function getCfgDirList(callback: AsyncCallback>): void; /** * Gets the config directory in the device architecture, ordered by priority from low to high. @@ -291,7 +292,7 @@ declare namespace configPolicy { * @returns { Promise> } the promise returns the list of configuration level directories. * @syscap SystemCapability.Customization.ConfigPolicy * @systemapi Hide this for inner system use. - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} */ function getCfgDirList(): Promise>; @@ -310,7 +311,7 @@ declare namespace configPolicy { * @returns { Array } the list of configuration level directories. * @syscap SystemCapability.Customization.ConfigPolicy * @systemapi Hide this for inner system use. - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} */ function getCfgDirListSync(): Array; } diff --git a/api/@ohos.customization.customConfig.d.ts b/api/@ohos.customization.customConfig.d.ts index 2717e051140dbc2b2b91b469c40262e380d3d857..0dfc711b0c4124d7305b9db15f95ff0bb55d7210 100644 --- a/api/@ohos.customization.customConfig.d.ts +++ b/api/@ohos.customization.customConfig.d.ts @@ -16,6 +16,7 @@ /** * @file * @kit BasicServicesKit + * @arkts 1.1&1.2 */ /** @@ -31,7 +32,7 @@ * @namespace customConfig * @syscap SystemCapability.Customization.CustomConfig * @atomicservice - * @since 13 + * @since arkts {'1.1':'13','1.2':'20'} */ declare namespace customConfig { @@ -48,7 +49,7 @@ declare namespace customConfig { * @returns { string } the channelId or empty if not exist. * @syscap SystemCapability.Customization.CustomConfig * @atomicservice - * @since 13 + * @since arkts {'1.1':'13','1.2':'20'} */ function getChannelId(): string; diff --git a/api/@ohos.effectKit.d.ts b/api/@ohos.effectKit.d.ts index 6d5954d3c841b396bdbfc9a4c4cb41fe5bf269df..507f0c73b87caa61f0c1e72090127a260c370f06 100644 --- a/api/@ohos.effectKit.d.ts +++ b/api/@ohos.effectKit.d.ts @@ -18,13 +18,10 @@ * @kit ArkGraphics2D */ -/*** if arkts 1.1 */ + import { AsyncCallback } from './@ohos.base'; import image from './@ohos.multimedia.image'; -/*** endif */ -/*** if arkts 1.2 */ -import image from './@ohos.multimedia.image'; -/*** endif */ + /** * @namespace effectKit @@ -62,7 +59,7 @@ declare namespace effectKit { * @since 12 */ /** - * A class used to add a specified effect to an image. Before calling any method of Filter, use createEffect to create a Filter instance. + * The Filter of FilterChain. * @typedef Filter * @syscap SystemCapability.Multimedia.Image.Core * @crossplatform @@ -90,28 +87,26 @@ declare namespace effectKit { * @since 12 */ /** - * Adds the blur effect to the filter linked list, and returns the head node of the linked list. - * @param { number } radius - Blur radius, in pixels. The blur effect is proportional to the configured value. - * A larger value indicates a more obvious effect. - * @returns { Filter } Final image effect. + * A blur effect is added to the image. + * @param { number } radius - The degree of blur, the value is measured in pixels. + * @returns { Filter } Filters for the current effect have been added. * @syscap SystemCapability.Multimedia.Image.Core * @crossplatform * @form * @atomicservice * @since arkts {'1.1':'14', '1.2':'20'} - * @arkts 1.1&1.2 + * @arkts 1.1&1.2 */ blur(radius: number): Filter; /** - * Adds the blur effect to the filter linked list, and returns the head node of the linked list. - * @param { number } radius - Blur radius, in pixels. The blur effect is proportional to the configured value. - * A larger value indicates a more obvious effect. - * @param { TileMode } tileMode - Tile mode of the shader effect. The blur effect of image edges is affected. Currently, - * only CPU rendering is supported. Therefore, the tile mode supports only DECAL. - * @returns { Filter } Final image effect. + * A blur effect is added to the image. + * @param { number } radius - The degree of blur, the value is measured in pixels. + * @param { TileMode } tileMode - The tile mode of blur. + * @returns { Filter } Filters for the current effect have been added. * @syscap SystemCapability.Multimedia.Image.Core - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ blur(radius: number, tileMode: TileMode): Filter; @@ -132,14 +127,15 @@ declare namespace effectKit { * @since 12 */ /** - * Adds the brightness effect to the filter linked list, and returns the head node of the linked list. - * @param { number } bright - Brightness value, ranging from 0 to 1. When the value is 0, the image brightness remains unchanged. - * @returns { Filter } Final image effect. + * A Brightness effect is added to the image. + * @param { number } bright - The degree of light and darkness,the value range is 0 to 1. + * @returns { Filter } Filters for the current effect have been added. * @syscap SystemCapability.Multimedia.Image.Core * @crossplatform * @form * @atomicservice - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ brightness(bright: number): Filter; @@ -158,13 +154,14 @@ declare namespace effectKit { * @since 12 */ /** - * Adds the grayscale effect to the filter linked list, and returns the head node of the linked list. - * @returns { Filter } Final image effect. + * A Grayscale effect is added to the image. + * @returns { Filter } Filters for the current effect have been added. * @syscap SystemCapability.Multimedia.Image.Core * @crossplatform * @form * @atomicservice - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ grayscale(): Filter; @@ -175,11 +172,12 @@ declare namespace effectKit { * @since 12 */ /** - * Adds the inversion effect to the filter linked list, and returns the head node of the linked list. - * @returns { Filter } Final image effect. + * A invert effect is added to the image. + * @returns { Filter } Filters for the current effect have been added. * @syscap SystemCapability.Multimedia.Image.Core * @crossplatform - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ invert(): Filter; @@ -193,22 +191,20 @@ declare namespace effectKit { * @since 12 */ /** - * Adds a custom effect to the filter linked list, and returns the head node of the linked list. + * A custom effect is added to the image. * - * @param { Array } colorMatrix - Custom color matrix. - * A 5 x 4 matrix can be created. The value range of the matrix element is [0, 1], - * where 0 indicates that the color channel is not involved in the calculation, - * and 1 indicates that the color channel is involved in the calculation and retains the original weight. - * @returns { Filter } Final image effect. + * @param { Array } colorMatrix - A matrix of 5x4 size for create effect filter. + * @returns { Filter } Filters for the current effect have been added. * @throws { BusinessError } 401 - Input parameter error. * @syscap SystemCapability.Multimedia.Image.Core * @crossplatform - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ setColorMatrix(colorMatrix: Array): Filter; /** - * Obtains image.PixelMap of the source image to which the filter linked list is added. + * Gets the PixelMap where all filter effects have been added to the image. * @returns { image.PixelMap } image.PixelMap. * @syscap SystemCapability.Multimedia.Image.Core * @since 9 @@ -232,14 +228,14 @@ declare namespace effectKit { * @since 12 */ /** - * Obtains image.PixelMap of the source image to which the filter linked list is added. This API uses a promise to return the result. - * @returns { Promise } - Promise used to return image.PixelMap of the source image. + * Gets the PixelMap where all filter effects have been added to the image. + * @returns { Promise } - returns the PixelMap generated. * @syscap SystemCapability.Multimedia.Image.Core * @crossplatform * @form * @atomicservice * @since arkts {'1.1':'14', '1.2':'20'} - * @arkts 1.1&1.2 + * @arkts 1.1&1.2 */ getEffectPixelMap(): Promise; } @@ -259,13 +255,14 @@ declare namespace effectKit { * @since 12 */ /** - * A class used to obtain the color from an image. Before calling any method of ColorPicker, use createColorPicker to create a ColorPicker instance. + * The color picker of an image. * @typedef ColorPicker * @syscap SystemCapability.Multimedia.Image.Core * @crossplatform * @form * @atomicservice - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ interface ColorPicker { @@ -284,13 +281,14 @@ declare namespace effectKit { * @since 12 */ /** - * Obtains the main color from the image and writes the result to a Color instance. This API uses a promise to return the result. - * @returns { Promise } Promise used to return the color value of the main color. If the operation fails, an error message is returned. + * get main color of an image + * @returns { Promise } returns the MainColor generated. * @syscap SystemCapability.Multimedia.Image.Core * @crossplatform * @form * @atomicservice - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ getMainColor(): Promise; @@ -309,13 +307,14 @@ declare namespace effectKit { * @since 12 */ /** - * Obtains the main color from the image and writes the result to a Color instance. This API returns the result synchronously. - * @returns { Color } Color value of the main color. If the operation fails, null is returned. + * get main color of an image + * @returns { Color } Main color picked in the image. * @syscap SystemCapability.Multimedia.Image.Core * @crossplatform * @form * @atomicservice - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ getMainColorSync(): Color; @@ -334,13 +333,14 @@ declare namespace effectKit { * @since 12 */ /** - * Obtains the color with the largest proportion from the image and writes the result to a Color instance. This API returns the result synchronously. - * @returns { Color } Color value of the color with the largest proportion. If the operation fails, null is returned. + * Get largest proportion color of an image + * @returns { Color } Largest proportion color picked in the image. * @syscap SystemCapability.Multimedia.Image.Core * @crossplatform * @form * @atomicservice - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ getLargestProportionColor(): Color; @@ -355,17 +355,16 @@ declare namespace effectKit { * @since 12 */ /** - * Obtains a given number of colors with the top proportions in the image. This API returns the result synchronously. - * @param { number } colorCount - Number of colors to obtain. The value range is [1, 10]. If a non-integer is passed in, the value will be rounded down. - * @returns { Array } Array of colors, sorted by proportion. - * - If the number of colors obtained is less than the value of colorCount, the array size is the actual number obtained. - * - If the colors fail to be obtained or the number of colors obtained is less than 1, [null] is returned. - * - If the value of colorCount is greater than 10, an array holding the first 10 colors with the top proportions is returned. + * Get top proportion color of an image + * @param { number } colorCount - The number of colors to require, the value is 1 to 10. + * @returns { Array } An array of feature colors sorted by proportion, with a size equal to + * the minimum of colorCount and the actual number of extracted feature colors. * @syscap SystemCapability.Multimedia.Image.Core * @crossplatform * @form * @atomicservice - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ getTopProportionColors(colorCount: number): Array; @@ -384,13 +383,14 @@ declare namespace effectKit { * @since 12 */ /** - * Obtains the color with the highest saturation from the image and writes the result to a Color instance. This API returns the result synchronously. - * @returns { Color } Color value of the color with the highest saturation. If the operation fails, null is returned. + * Get highest saturation color of an image + * @returns { Color } Highest saturation color picked in the image. * @syscap SystemCapability.Multimedia.Image.Core * @crossplatform * @form * @atomicservice - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ getHighestSaturationColor(): Color; @@ -409,13 +409,14 @@ declare namespace effectKit { * @since 12 */ /** - * Obtains the average color from the image and writes the result to a Color instance. This API returns the result synchronously. - * @returns { Color } Average color value. If the operation fails, null is returned. + * Get average color of an image + * @returns { Color } Average color calculated in the image. * @syscap SystemCapability.Multimedia.Image.Core * @crossplatform * @form * @atomicservice - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ getAverageColor(): Color; @@ -436,14 +437,15 @@ declare namespace effectKit { * @since 12 */ /** - * Checks whether a color is black, white, and gray. - * @param { number } color - Color to check. The value range is [0x0, 0xFFFFFFFF]. - * @returns { boolean } Returns true if the image is black, white, and gray; returns false otherwise. + * Determine whether the color is black or white or gray + * @param { number } color - The 32 bit ARGB color to discriminate. + * @returns { boolean } Result of judging black, white and gray. * @syscap SystemCapability.Multimedia.Image.Core * @crossplatform * @form * @atomicservice - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ isBlackOrWhiteOrGrayColor(color: number): boolean; } @@ -463,13 +465,14 @@ declare namespace effectKit { * @since 12 */ /** - * A class that stores the color picked. + * The color param. * @typedef Color * @syscap SystemCapability.Multimedia.Image.Core * @crossplatform * @form * @atomicservice - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ interface Color { @@ -488,13 +491,14 @@ declare namespace effectKit { * @since 12 */ /** - * Value of the red component. The value range is [0x0, 0xFF]. + * Red * @type { number } * @syscap SystemCapability.Multimedia.Image.Core * @crossplatform * @form * @atomicservice - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ red: number; @@ -513,13 +517,14 @@ declare namespace effectKit { * @since 12 */ /** - * Value of the green component. The value range is [0x0, 0xFF]. + * Green * @type { number } * @syscap SystemCapability.Multimedia.Image.Core * @crossplatform * @form * @atomicservice - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ green: number; @@ -538,13 +543,14 @@ declare namespace effectKit { * @since 12 */ /** - * Value of the blue component. The value range is [0x0, 0xFF]. + * Blue * @type { number } * @syscap SystemCapability.Multimedia.Image.Core * @crossplatform * @form * @atomicservice - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ blue: number; @@ -563,13 +569,14 @@ declare namespace effectKit { * @since 12 */ /** - * Value of the alpha component. The value range is [0x0, 0xFF]. + * Alpha * @type { number } * @syscap SystemCapability.Multimedia.Image.Core * @crossplatform * @form * @atomicservice - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ alpha: number; } @@ -591,10 +598,9 @@ declare namespace effectKit { * @since 12 */ /** - * Creates a Filter instance based on a pixel map. - * @param { image.PixelMap } source - PixelMap instance created by the image module. An instance can be obtained - * by decoding an image or directly created. For details, see Image Overview. - * @returns { Filter } Head node of the filter linked list without any effect. If the operation fails, null is returned. + * Create a FilterChain to add multiple effects to an image. + * @param { image.PixelMap } source - the source pixelmap. + * @returns { Filter } Returns the head node of FilterChain. * @syscap SystemCapability.Multimedia.Image.Core * @crossplatform * @form @@ -623,16 +629,16 @@ declare namespace effectKit { * @since 12 */ /** - * Creates a ColorPicker instance based on a pixel map. This API uses a promise to return the result. - * @param { image.PixelMap } source - PixelMap instance created by the image module. An instance can be - * obtained by decoding an image or directly created. For details, see Image Overview. - * @returns { Promise } - Promise used to return the ColorPicker instance created. + * Create a color picker to get color of an image. + * @param { image.PixelMap } source - the source pixelmap. + * @returns { Promise } - returns the ColorPicker generated. * @throws { BusinessError } 401 - Input parameter error. * @syscap SystemCapability.Multimedia.Image.Core * @crossplatform * @form * @atomicservice - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ function createColorPicker(source: image.PixelMap): Promise; @@ -659,21 +665,18 @@ declare namespace effectKit { * @since 12 */ /** - * Creates a ColorPicker instance for the selected region based on a pixel map. This API uses a promise to return the result. - * @param { image.PixelMap } source - PixelMap instance created by the image module. An instance can be obtained by decoding - * an image or directly created. For details, see Image Overview. - * @param { Array } region - Region of the image from which the color is picked. - * The array consists of four elements, representing the left, top, right, and bottom positions of the image, respectively. - * The value of each element must be in the range [0, 1]. The leftmost and topmost positions of the image correspond to 0, - * and the rightmost and bottom positions correspond to 1. In the array, the third element must be greater than the first element, - * and the fourth element must be greater than the second element. - * @returns { Promise } - Promise used to return the ColorPicker instance created. + * Create a color picker to get color of an image. + * @param { image.PixelMap } source - the source pixelmap. + * @param { Array } region - contains 4 elements, represents the region's left, top, right, bottom coordinates, + * default is [0, 0, 1, 1], represents the region of color picker is the whole pixelMap. + * @returns { Promise } - returns the ColorPicker generated. * @throws { BusinessError } 401 - Input parameter error. * @syscap SystemCapability.Multimedia.Image.Core * @crossplatform * @form * @atomicservice - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ function createColorPicker(source: image.PixelMap, region: Array): Promise; @@ -696,16 +699,16 @@ declare namespace effectKit { * @since 12 */ /** - * Creates a ColorPicker instance based on a pixel map. This API uses an asynchronous callback to return the result. - * @param { image.PixelMap } source - PixelMap instance created by the image module. An instance can be obtained by - * decoding an image or directly created. For details, see Image Overview. + * Create a color picker to get color of an image. + * @param { image.PixelMap } source - the source pixelmap. * @param { AsyncCallback } callback - the callback of createColorPicker. * @throws { BusinessError } 401 - Input parameter error. * @syscap SystemCapability.Multimedia.Image.Core * @crossplatform * @form * @atomicservice - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ function createColorPicker(source: image.PixelMap, callback: AsyncCallback): void; @@ -732,62 +735,63 @@ declare namespace effectKit { * @since 12 */ /** - * Creates a ColorPicker instance for the selected region based on a pixel map. This API uses an asynchronous callback to return the result. - * @param { image.PixelMap } source - PixelMap instance created by the image module. An instance can be obtained by decoding an - * image or directly created. For details, see Image Overview.PixelMap instance created by the image module. An instance can be - * obtained by decoding an image or directly created. For details, see Image Overview. - * @param { Array } region - Region of the image from which the color is picked. - * The array consists of four elements, representing the left, top, right, and bottom positions of the image, respectively. - * The value of each element must be in the range [0, 1]. The leftmost and topmost positions of the image correspond to 0, - * and the rightmost and bottom positions correspond to 1. In the array, the third element must be greater than the first element, - * and the fourth element must be greater than the second element. - * @param { AsyncCallback } callback - Callback used to return the ColorPicker instance created. + * Create a color picker to get color of an image. + * @param { image.PixelMap } source - the source pixelmap. + * @param { Array } region - contains 4 elements, represents the region's left, top, right, bottom coordinates, + * default is [0, 0, 1, 1], represents the region of color picker is the whole pixelMap. + * @param { AsyncCallback } callback - the callback of createColorPicker. * @throws { BusinessError } 401 - Input parameter error. * @syscap SystemCapability.Multimedia.Image.Core * @crossplatform * @form * @atomicservice - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ function createColorPicker(source: image.PixelMap, region: Array, callback: AsyncCallback): void; /** - * Enumerates the tile modes of the shader effect. + * TileMode enumeration description * * @enum { number } * @syscap SystemCapability.Multimedia.Image.Core - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ enum TileMode { /** - * Replicates the edge color if the shader effect draws outside of its original boundary. + * Clamp mode. * * @syscap SystemCapability.Multimedia.Image.Core - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ CLAMP = 0, /** - * Repeats the shader effect in both horizontal and vertical directions. + * Repeat mode. * * @syscap SystemCapability.Multimedia.Image.Core - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ REPEAT = 1, /** - * Repeats the shader effect in both horizontal and vertical directions, alternating mirror images. + * Mirror mode. * * @syscap SystemCapability.Multimedia.Image.Core - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ MIRROR = 2, /** - * Renders the shader effect only within the original boundary. + * Decal mode. * * @syscap SystemCapability.Multimedia.Image.Core - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ DECAL = 3, } diff --git a/api/@ohos.geoLocationManager.d.ts b/api/@ohos.geoLocationManager.d.ts index d5413e5ba80581a42ab472f4701195a744a2580c..691626a3e3f5b5614c94bc52b258e1003232c8d7 100644 --- a/api/@ohos.geoLocationManager.d.ts +++ b/api/@ohos.geoLocationManager.d.ts @@ -20,11 +20,12 @@ import { AsyncCallback, Callback } from './@ohos.base'; /*** if arkts 1.1 */ -import { WantAgent } from './@ohos.wantAgent'; +import { WantAgent } from '@ohos.wantAgent'; /*** endif */ -/*** if arkts 1.1 */ -import { NotificationRequest } from './notification/notificationRequest'; +/*** if arkts 1.2 */ +import { WantAgent } from '@ohos.app.ability.wantAgent'; /*** endif */ +import { NotificationRequest } from './notification/notificationRequest'; /** * Provides interfaces for acquiring location information, managing location switches, @@ -108,7 +109,8 @@ declare namespace geoLocationManager { * @throws { BusinessError } 3301100 - The location switch is off. * @syscap SystemCapability.Location.Location.Core * @atomicservice - * @since 18 + * @since arkts {'1.1':'18','1.2':'20'} + * @arkts 1.1&1.2 */ function on(type: 'locationChange', request: LocationRequest | ContinuousLocationRequest, callback: Callback): void; @@ -156,7 +158,8 @@ declare namespace geoLocationManager { * @throws { BusinessError } 3301000 - The location service is unavailable. * @syscap SystemCapability.Location.Location.Core * @atomicservice - * @since 18 + * @since arkts {'1.1':'18','1.2':'20'} + * @arkts 1.1&1.2 */ function off(type: 'locationChange', callback?: Callback): void; @@ -172,7 +175,8 @@ declare namespace geoLocationManager { * @throws { BusinessError } 3301000 - The location service is unavailable. * @syscap SystemCapability.Location.Location.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ function on(type: 'locationError', callback: Callback): void; @@ -188,7 +192,8 @@ declare namespace geoLocationManager { * @throws { BusinessError } 3301000 - The location service is unavailable. * @syscap SystemCapability.Location.Location.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ function off(type: 'locationError', callback?: Callback): void; @@ -201,7 +206,8 @@ declare namespace geoLocationManager { * @throws { BusinessError } 801 - Capability not supported. Failed to call ${geoLocationManager.on('locationEnabledChange')} due to limited device capabilities. * @throws { BusinessError } 3301000 - The location service is unavailable. * @syscap SystemCapability.Location.Location.Core - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ function on(type: 'locationEnabledChange', callback: Callback): void; @@ -214,7 +220,8 @@ declare namespace geoLocationManager { * @throws { BusinessError } 801 - Capability not supported. Failed to call ${geoLocationManager.off('locationEnabledChange')} due to limited device capabilities. * @throws { BusinessError } 3301000 - The location service is unavailable. * @syscap SystemCapability.Location.Location.Core - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ function off(type: 'locationEnabledChange', callback?: Callback): void; @@ -247,7 +254,8 @@ declare namespace geoLocationManager { * @throws { BusinessError } 3301000 - The location service is unavailable. * @throws { BusinessError } 3301100 - The location switch is off. * @syscap SystemCapability.Location.Location.Gnss - * @since 18 + * @since arkts {'1.1':'18','1.2':'20'} + * @arkts 1.1&1.2 */ function on(type: 'cachedGnssLocationsChange', request: CachedGnssLocationsRequest, callback: Callback>): void; @@ -278,7 +286,8 @@ declare namespace geoLocationManager { * @throws { BusinessError } 3301000 - The location service is unavailable. * @throws { BusinessError } 3301100 - The location switch is off. * @syscap SystemCapability.Location.Location.Gnss - * @since 18 + * @since arkts {'1.1':'18','1.2':'20'} + * @arkts 1.1&1.2 */ function off(type: 'cachedGnssLocationsChange', callback?: Callback>): void; @@ -294,7 +303,8 @@ declare namespace geoLocationManager { * @throws { BusinessError } 3301000 - The location service is unavailable. * @throws { BusinessError } 3301100 - The location switch is off. * @syscap SystemCapability.Location.Location.Gnss - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ function on(type: 'satelliteStatusChange', callback: Callback): void; @@ -310,7 +320,8 @@ declare namespace geoLocationManager { * @throws { BusinessError } 3301000 - The location service is unavailable. * @throws { BusinessError } 3301100 - The location switch is off. * @syscap SystemCapability.Location.Location.Gnss - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ function off(type: 'satelliteStatusChange', callback?: Callback): void; @@ -326,7 +337,8 @@ declare namespace geoLocationManager { * @throws { BusinessError } 3301000 - The location service is unavailable. * @throws { BusinessError } 3301100 - The location switch is off. * @syscap SystemCapability.Location.Location.Gnss - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ function on(type: 'nmeaMessage', callback: Callback): void; @@ -342,7 +354,8 @@ declare namespace geoLocationManager { * @throws { BusinessError } 3301000 - The location service is unavailable. * @throws { BusinessError } 3301100 - The location switch is off. * @syscap SystemCapability.Location.Location.Gnss - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ function off(type: 'nmeaMessage', callback?: Callback): void; @@ -392,7 +405,8 @@ declare namespace geoLocationManager { * @throws { BusinessError } 3301000 - The location service is unavailable. * @throws { BusinessError } 3301500 - Failed to query the area information. * @syscap SystemCapability.Location.Location.Core - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ function on(type: 'countryCodeChange', callback: Callback): void; @@ -406,7 +420,8 @@ declare namespace geoLocationManager { * @throws { BusinessError } 3301000 - The location service is unavailable. * @throws { BusinessError } 3301500 - Failed to query the area information. * @syscap SystemCapability.Location.Location.Core - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ function off(type: 'countryCodeChange', callback?: Callback): void; @@ -425,7 +440,8 @@ declare namespace geoLocationManager { * @throws { BusinessError } 3301800 - Failed to start WiFi or Bluetooth scanning. * @syscap SystemCapability.Location.Location.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10','1.2':'20'} + * @arkts 1.1&1.2 */ function on(type: 'locatingRequiredDataChange', config: LocatingRequiredDataConfig, callback: Callback>): void; @@ -441,7 +457,8 @@ declare namespace geoLocationManager { * @throws { BusinessError } 801 - Capability not supported. Failed to call ${geoLocationManager.off('locatingRequiredDataChange')} due to limited device capabilities. * @syscap SystemCapability.Location.Location.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10','1.2':'20'} + * @arkts 1.1&1.2 */ function off(type: 'locatingRequiredDataChange', callback?: Callback>): void; @@ -456,7 +473,8 @@ declare namespace geoLocationManager { * @throws { BusinessError } 3301000 - The location service is unavailable. * @syscap SystemCapability.Location.Location.Core * @systemapi - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ function on(type: 'locationIconStatusChange', callback: Callback): void; @@ -471,7 +489,8 @@ declare namespace geoLocationManager { * @throws { BusinessError } 3301000 - The location service is unavailable. * @syscap SystemCapability.Location.Location.Core * @systemapi - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ function off(type: 'locationIconStatusChange', callback?: Callback): void; @@ -487,7 +506,8 @@ declare namespace geoLocationManager { * @throws { BusinessError } 3301000 - The location service is unavailable. * @throws { BusinessError } 3301100 - The location switch is off. * @syscap SystemCapability.Location.Location.Core - * @since 16 + * @since arkts {'1.1':'16','1.2':'20'} + * @arkts 1.1&1.2 */ function on(type: 'bluetoothScanResultChange', callback: Callback): void; @@ -502,7 +522,8 @@ declare namespace geoLocationManager { * @throws { BusinessError } 801 - Capability not supported. Failed to call ${geoLocationManager.off('bluetoothScanResultChange')} due to limited device capabilities. * @throws { BusinessError } 3301000 - The location service is unavailable. * @syscap SystemCapability.Location.Location.Core - * @since 16 + * @since arkts {'1.1':'16','1.2':'20'} + * @arkts 1.1&1.2 */ function off(type: 'bluetoothScanResultChange', callback?: Callback): void; @@ -665,7 +686,8 @@ declare namespace geoLocationManager { * @throws { BusinessError } 3301200 - Failed to obtain the geographical location. * @syscap SystemCapability.Location.Location.Core * @atomicservice - * @since 11 + * @since arkts {'1.1':'11','1.2':'20'} + * @arkts 1.1&1.2 */ function getLastLocation(): Location; @@ -686,7 +708,8 @@ declare namespace geoLocationManager { * @throws { BusinessError } 3301000 - The location service is unavailable. * @syscap SystemCapability.Location.Location.Core * @atomicservice - * @since 11 + * @since arkts {'1.1':'11','1.2':'20'} + * @arkts 1.1&1.2 */ function isLocationEnabled(): boolean; @@ -730,7 +753,8 @@ declare namespace geoLocationManager { * @throws { BusinessError } 3301000 - The location service is unavailable. * @syscap SystemCapability.Location.Location.Core * @systemapi - * @since 20 + * @since arkts {'1.1':'20','1.2':'20'} + * @arkts 1.1&1.2 */ function enableLocation(callback: AsyncCallback): void; @@ -758,7 +782,8 @@ declare namespace geoLocationManager { * @throws { BusinessError } 3301000 - The location service is unavailable. * @syscap SystemCapability.Location.Location.Core * @systemapi - * @since 20 + * @since arkts {'1.1':'20','1.2':'20'} + * @arkts 1.1&1.2 */ function enableLocation(): Promise; @@ -800,7 +825,8 @@ declare namespace geoLocationManager { * @throws { BusinessError } 3301000 - The location service is unavailable. * @syscap SystemCapability.Location.Location.Core * @systemapi - * @since 20 + * @since arkts {'1.1':'20','1.2':'20'} + * @arkts 1.1&1.2 */ function disableLocation(): void; @@ -845,7 +871,8 @@ declare namespace geoLocationManager { * @throws { BusinessError } 3301000 - The location service is unavailable. * @throws { BusinessError } 3301300 - Reverse geocoding query failed. * @syscap SystemCapability.Location.Location.Geocoder - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ function getAddressesFromLocation(request: ReverseGeoCodeRequest, callback: AsyncCallback>): void; @@ -859,7 +886,8 @@ declare namespace geoLocationManager { * @throws { BusinessError } 3301000 - The location service is unavailable. * @throws { BusinessError } 3301300 - Reverse geocoding query failed. * @syscap SystemCapability.Location.Location.Geocoder - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ function getAddressesFromLocation(request: ReverseGeoCodeRequest): Promise>; @@ -1190,7 +1218,8 @@ declare namespace geoLocationManager { * @throws { BusinessError } 3301000 - The location service is unavailable. * @syscap SystemCapability.Location.Location.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ function isLocationPrivacyConfirmed(type: LocationPrivacyType): boolean; @@ -1403,7 +1432,8 @@ declare namespace geoLocationManager { * * @typedef SatelliteStatusInfo * @syscap SystemCapability.Location.Location.Gnss - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ export interface SatelliteStatusInfo { /** @@ -1411,7 +1441,8 @@ declare namespace geoLocationManager { * * @type { number } * @syscap SystemCapability.Location.Location.Gnss - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ satellitesNumber: number; @@ -1420,7 +1451,8 @@ declare namespace geoLocationManager { * * @type { Array } * @syscap SystemCapability.Location.Location.Gnss - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ satelliteIds: Array; @@ -1429,7 +1461,8 @@ declare namespace geoLocationManager { * * @type { Array } * @syscap SystemCapability.Location.Location.Gnss - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ carrierToNoiseDensitys: Array; @@ -1438,7 +1471,8 @@ declare namespace geoLocationManager { * * @type { Array } * @syscap SystemCapability.Location.Location.Gnss - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ altitudes: Array; @@ -1447,7 +1481,8 @@ declare namespace geoLocationManager { * * @type { Array } * @syscap SystemCapability.Location.Location.Gnss - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ azimuths: Array; @@ -1456,7 +1491,8 @@ declare namespace geoLocationManager { * * @type { Array } * @syscap SystemCapability.Location.Location.Gnss - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ carrierFrequencies: Array; @@ -1465,7 +1501,8 @@ declare namespace geoLocationManager { * * @type { ?Array } * @syscap SystemCapability.Location.Location.Gnss - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ satelliteConstellation?: Array; @@ -1474,7 +1511,8 @@ declare namespace geoLocationManager { * * @type { ?Array } * @syscap SystemCapability.Location.Location.Gnss - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ satelliteAdditionalInfo?: Array; } @@ -1484,7 +1522,8 @@ declare namespace geoLocationManager { * * @typedef CachedGnssLocationsRequest * @syscap SystemCapability.Location.Location.Gnss - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ export interface CachedGnssLocationsRequest { /** @@ -1492,7 +1531,8 @@ declare namespace geoLocationManager { * * @type { number } * @syscap SystemCapability.Location.Location.Gnss - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ reportingPeriodSec: number; @@ -1501,7 +1541,8 @@ declare namespace geoLocationManager { * * @type { boolean } * @syscap SystemCapability.Location.Location.Gnss - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ wakeUpCacheQueueFull: boolean; } @@ -1637,7 +1678,8 @@ declare namespace geoLocationManager { * * @typedef ReverseGeoCodeRequest * @syscap SystemCapability.Location.Location.Geocoder - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ export interface ReverseGeoCodeRequest { /** @@ -1645,7 +1687,8 @@ declare namespace geoLocationManager { * * @type { ?string } * @syscap SystemCapability.Location.Location.Geocoder - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ locale?: string; @@ -1654,7 +1697,8 @@ declare namespace geoLocationManager { * * @type { ?string } * @syscap SystemCapability.Location.Location.Geocoder - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ country?: string; @@ -1663,7 +1707,8 @@ declare namespace geoLocationManager { * * @type { number } * @syscap SystemCapability.Location.Location.Geocoder - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ latitude: number; @@ -1672,7 +1717,8 @@ declare namespace geoLocationManager { * * @type { number } * @syscap SystemCapability.Location.Location.Geocoder - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ longitude: number; @@ -1681,7 +1727,8 @@ declare namespace geoLocationManager { * * @type { ?number } * @syscap SystemCapability.Location.Location.Geocoder - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ maxItems?: number; } @@ -1691,7 +1738,8 @@ declare namespace geoLocationManager { * * @typedef GeoCodeRequest * @syscap SystemCapability.Location.Location.Geocoder - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ export interface GeoCodeRequest { /** @@ -1699,7 +1747,8 @@ declare namespace geoLocationManager { * * @type { ?string } * @syscap SystemCapability.Location.Location.Geocoder - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ locale?: string; @@ -1708,7 +1757,8 @@ declare namespace geoLocationManager { * * @type { ?string } * @syscap SystemCapability.Location.Location.Geocoder - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ country?: string; @@ -1717,7 +1767,8 @@ declare namespace geoLocationManager { * * @type { string } * @syscap SystemCapability.Location.Location.Geocoder - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ description: string; @@ -1726,7 +1777,8 @@ declare namespace geoLocationManager { * * @type { ?number } * @syscap SystemCapability.Location.Location.Geocoder - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ maxItems?: number; @@ -1735,7 +1787,8 @@ declare namespace geoLocationManager { * * @type { ?number } * @syscap SystemCapability.Location.Location.Geocoder - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ minLatitude?: number; @@ -1744,7 +1797,8 @@ declare namespace geoLocationManager { * * @type { ?number } * @syscap SystemCapability.Location.Location.Geocoder - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ minLongitude?: number; @@ -1753,7 +1807,8 @@ declare namespace geoLocationManager { * * @type { ?number } * @syscap SystemCapability.Location.Location.Geocoder - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ maxLatitude?: number; @@ -1762,7 +1817,8 @@ declare namespace geoLocationManager { * * @type { ?number } * @syscap SystemCapability.Location.Location.Geocoder - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ maxLongitude?: number; } @@ -1772,7 +1828,8 @@ declare namespace geoLocationManager { * * @typedef GeoAddress * @syscap SystemCapability.Location.Location.Geocoder - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ export interface GeoAddress { /** @@ -1782,7 +1839,8 @@ declare namespace geoLocationManager { * * @type { ?number } * @syscap SystemCapability.Location.Location.Geocoder - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ latitude?: number; @@ -1793,7 +1851,8 @@ declare namespace geoLocationManager { * * @type { ?number } * @syscap SystemCapability.Location.Location.Geocoder - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ longitude?: number; @@ -1803,7 +1862,8 @@ declare namespace geoLocationManager { * * @type { ?string } * @syscap SystemCapability.Location.Location.Geocoder - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ locale?: string; @@ -1812,7 +1872,8 @@ declare namespace geoLocationManager { * * @type { ?string } * @syscap SystemCapability.Location.Location.Geocoder - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ placeName?: string; @@ -1821,7 +1882,8 @@ declare namespace geoLocationManager { * * @type { ?string } * @syscap SystemCapability.Location.Location.Geocoder - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ countryCode?: string; @@ -1830,7 +1892,8 @@ declare namespace geoLocationManager { * * @type { ?string } * @syscap SystemCapability.Location.Location.Geocoder - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ countryName?: string; @@ -1839,7 +1902,8 @@ declare namespace geoLocationManager { * * @type { ?string } * @syscap SystemCapability.Location.Location.Geocoder - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ administrativeArea?: string; @@ -1848,7 +1912,8 @@ declare namespace geoLocationManager { * * @type { ?string } * @syscap SystemCapability.Location.Location.Geocoder - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ subAdministrativeArea?: string; @@ -1857,7 +1922,8 @@ declare namespace geoLocationManager { * * @type { ?string } * @syscap SystemCapability.Location.Location.Geocoder - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ locality?: string; @@ -1866,7 +1932,8 @@ declare namespace geoLocationManager { * * @type { ?string } * @syscap SystemCapability.Location.Location.Geocoder - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ subLocality?: string; @@ -1875,7 +1942,8 @@ declare namespace geoLocationManager { * * @type { ?string } * @syscap SystemCapability.Location.Location.Geocoder - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ roadName?: string; @@ -1884,7 +1952,8 @@ declare namespace geoLocationManager { * * @type { ?string } * @syscap SystemCapability.Location.Location.Geocoder - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ subRoadName?: string; @@ -1893,7 +1962,8 @@ declare namespace geoLocationManager { * * @type { ?string } * @syscap SystemCapability.Location.Location.Geocoder - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ premises?: string; @@ -1902,7 +1972,8 @@ declare namespace geoLocationManager { * * @type { ?string } * @syscap SystemCapability.Location.Location.Geocoder - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ postalCode?: string; @@ -1911,7 +1982,8 @@ declare namespace geoLocationManager { * * @type { ?string } * @syscap SystemCapability.Location.Location.Geocoder - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ phoneNumber?: string; @@ -1920,7 +1992,8 @@ declare namespace geoLocationManager { * * @type { ?string } * @syscap SystemCapability.Location.Location.Geocoder - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ addressUrl?: string; @@ -1929,7 +2002,8 @@ declare namespace geoLocationManager { * * @type { ?Array } * @syscap SystemCapability.Location.Location.Geocoder - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ descriptions?: Array; @@ -1938,7 +2012,8 @@ declare namespace geoLocationManager { * * @type { ?number } * @syscap SystemCapability.Location.Location.Geocoder - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ descriptionsSize?: number; @@ -1948,7 +2023,8 @@ declare namespace geoLocationManager { * @type { ?Boolean } * @syscap SystemCapability.Location.Location.Geocoder * @systemapi - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ isFromMock?: Boolean; } @@ -1966,7 +2042,8 @@ declare namespace geoLocationManager { * @typedef LocationRequest * @syscap SystemCapability.Location.Location.Core * @atomicservice - * @since 11 + * @since arkts {'1.1':'11','1.2':'20'} + * @arkts 1.1&1.2 */ export interface LocationRequest { /** @@ -1982,7 +2059,8 @@ declare namespace geoLocationManager { * @type { ?LocationRequestPriority } * @syscap SystemCapability.Location.Location.Core * @atomicservice - * @since 11 + * @since arkts {'1.1':'11','1.2':'20'} + * @arkts 1.1&1.2 */ priority?: LocationRequestPriority; @@ -1999,7 +2077,8 @@ declare namespace geoLocationManager { * @type { ?LocationRequestScenario } * @syscap SystemCapability.Location.Location.Core * @atomicservice - * @since 11 + * @since arkts {'1.1':'11','1.2':'20'} + * @arkts 1.1&1.2 */ scenario?: LocationRequestScenario; @@ -2016,7 +2095,8 @@ declare namespace geoLocationManager { * @type { ?number } * @syscap SystemCapability.Location.Location.Core * @atomicservice - * @since 11 + * @since arkts {'1.1':'11','1.2':'20'} + * @arkts 1.1&1.2 */ timeInterval?: number; @@ -2033,7 +2113,8 @@ declare namespace geoLocationManager { * @type { ?number } * @syscap SystemCapability.Location.Location.Core * @atomicservice - * @since 11 + * @since arkts {'1.1':'11','1.2':'20'} + * @arkts 1.1&1.2 */ distanceInterval?: number; @@ -2050,7 +2131,8 @@ declare namespace geoLocationManager { * @type { ?number } * @syscap SystemCapability.Location.Location.Core * @atomicservice - * @since 11 + * @since arkts {'1.1':'11','1.2':'20'} + * @arkts 1.1&1.2 */ maxAccuracy?: number; } @@ -2071,7 +2153,7 @@ declare namespace geoLocationManager { * @since arkts {'1.1':'11','1.2':'20'} * @arkts 1.1&1.2 */ - export interface CurrentLocationRequest { + export interface CurrentLocationRequest { /** * Priority of the location request. * @@ -2178,7 +2260,8 @@ declare namespace geoLocationManager { * @typedef ContinuousLocationRequest * @syscap SystemCapability.Location.Location.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ export interface ContinuousLocationRequest { /** @@ -2187,7 +2270,8 @@ declare namespace geoLocationManager { * @type { number } * @syscap SystemCapability.Location.Location.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ interval: number; @@ -2197,7 +2281,8 @@ declare namespace geoLocationManager { * @type { UserActivityScenario | PowerConsumptionScenario } * @syscap SystemCapability.Location.Location.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ locationScenario: UserActivityScenario | PowerConsumptionScenario; @@ -2209,10 +2294,12 @@ declare namespace geoLocationManager { * @syscap SystemCapability.Location.Location.Core * @systemapi * @atomicservice - * @since 18 + * @since arkts {'1.1':'18','1.2':'20'} + * @arkts 1.1&1.2 */ sportsType?: SportsType; + /** * Indicates whether to obtain POI information near the current location. * @@ -2221,7 +2308,7 @@ declare namespace geoLocationManager { * @atomicservice * @since 19 */ - needPoi?: boolean; + needPoi?: boolean; } /** @@ -2264,7 +2351,8 @@ declare namespace geoLocationManager { * @atomicservice * @since 19 */ - needPoi?: boolean; + needPoi?: boolean; + } } /** @@ -2565,7 +2653,8 @@ declare namespace geoLocationManager { * @typedef LocatingRequiredDataConfig * @syscap SystemCapability.Location.Location.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10','1.2':'20'} + * @arkts 1.1&1.2 */ export interface LocatingRequiredDataConfig { /** @@ -2574,7 +2663,8 @@ declare namespace geoLocationManager { * @type {LocatingRequiredDataType} * @syscap SystemCapability.Location.Location.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10','1.2':'20'} + * @arkts 1.1&1.2 */ type: LocatingRequiredDataType; @@ -2584,7 +2674,8 @@ declare namespace geoLocationManager { * @type {boolean} * @syscap SystemCapability.Location.Location.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10','1.2':'20'} + * @arkts 1.1&1.2 */ needStartScan: boolean; @@ -2595,7 +2686,8 @@ declare namespace geoLocationManager { * @type {?number} * @syscap SystemCapability.Location.Location.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10','1.2':'20'} + * @arkts 1.1&1.2 */ scanInterval?: number; @@ -2606,7 +2698,8 @@ declare namespace geoLocationManager { * @type {?number} * @syscap SystemCapability.Location.Location.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10','1.2':'20'} + * @arkts 1.1&1.2 */ scanTimeout?: number; } @@ -2616,7 +2709,8 @@ declare namespace geoLocationManager { * @typedef LocatingRequiredData * @syscap SystemCapability.Location.Location.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10','1.2':'20'} + * @arkts 1.1&1.2 */ export interface LocatingRequiredData { /** @@ -2625,7 +2719,8 @@ declare namespace geoLocationManager { * @type {?WifiScanInfo} * @syscap SystemCapability.Location.Location.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10','1.2':'20'} + * @arkts 1.1&1.2 */ wifiData?: WifiScanInfo; @@ -2635,7 +2730,8 @@ declare namespace geoLocationManager { * @type {?BluetoothScanInfo} * @syscap SystemCapability.Location.Location.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10','1.2':'20'} + * @arkts 1.1&1.2 */ bluetoothData?: BluetoothScanInfo; } @@ -2645,7 +2741,8 @@ declare namespace geoLocationManager { * @typedef WifiScanInfo * @syscap SystemCapability.Location.Location.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10','1.2':'20'} + * @arkts 1.1&1.2 */ export interface WifiScanInfo { /** @@ -2654,7 +2751,8 @@ declare namespace geoLocationManager { * @type {string} * @syscap SystemCapability.Location.Location.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10','1.2':'20'} + * @arkts 1.1&1.2 */ ssid: string; @@ -2664,7 +2762,8 @@ declare namespace geoLocationManager { * @type {string} * @syscap SystemCapability.Location.Location.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10','1.2':'20'} + * @arkts 1.1&1.2 */ bssid: string; @@ -2674,7 +2773,8 @@ declare namespace geoLocationManager { * @type {number} * @syscap SystemCapability.Location.Location.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10','1.2':'20'} + * @arkts 1.1&1.2 */ rssi: number; @@ -2684,7 +2784,8 @@ declare namespace geoLocationManager { * @type {number} * @syscap SystemCapability.Location.Location.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10','1.2':'20'} + * @arkts 1.1&1.2 */ frequency: number; @@ -2694,7 +2795,8 @@ declare namespace geoLocationManager { * @type {number} * @syscap SystemCapability.Location.Location.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10','1.2':'20'} + * @arkts 1.1&1.2 */ timestamp: number; } @@ -2705,7 +2807,8 @@ declare namespace geoLocationManager { * @typedef BluetoothScanInfo * @syscap SystemCapability.Location.Location.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10','1.2':'20'} + * @arkts 1.1&1.2 */ export interface BluetoothScanInfo { /** @@ -2714,7 +2817,8 @@ declare namespace geoLocationManager { * @type {string} * @syscap SystemCapability.Location.Location.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10','1.2':'20'} + * @arkts 1.1&1.2 */ deviceName: string; @@ -2724,7 +2828,8 @@ declare namespace geoLocationManager { * @type {string} * @syscap SystemCapability.Location.Location.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10','1.2':'20'} + * @arkts 1.1&1.2 */ macAddress: string; @@ -2734,7 +2839,8 @@ declare namespace geoLocationManager { * @type {number} * @syscap SystemCapability.Location.Location.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10','1.2':'20'} + * @arkts 1.1&1.2 */ rssi: number; @@ -2744,7 +2850,8 @@ declare namespace geoLocationManager { * @type {number} * @syscap SystemCapability.Location.Location.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10','1.2':'20'} + * @arkts 1.1&1.2 */ timestamp: number; } @@ -2754,7 +2861,8 @@ declare namespace geoLocationManager { * * @typedef BluetoothScanResult * @syscap SystemCapability.Location.Location.Core - * @since 16 + * @since arkts {'1.1':'16','1.2':'20'} + * @arkts 1.1&1.2 */ export interface BluetoothScanResult { /** @@ -2762,7 +2870,8 @@ declare namespace geoLocationManager { * * @type { string } * @syscap SystemCapability.Location.Location.Core - * @since 16 + * @since arkts {'1.1':'16','1.2':'20'} + * @arkts 1.1&1.2 */ deviceId: string; @@ -2771,7 +2880,8 @@ declare namespace geoLocationManager { * * @type { number } * @syscap SystemCapability.Location.Location.Core - * @since 16 + * @since arkts {'1.1':'16','1.2':'20'} + * @arkts 1.1&1.2 */ rssi: number; @@ -2780,7 +2890,8 @@ declare namespace geoLocationManager { * * @type { ?ArrayBuffer } * @syscap SystemCapability.Location.Location.Core - * @since 16 + * @since arkts {'1.1':'16','1.2':'20'} + * @arkts 1.1&1.2 */ data?: ArrayBuffer; @@ -2789,7 +2900,8 @@ declare namespace geoLocationManager { * * @type { string } * @syscap SystemCapability.Location.Location.Core - * @since 16 + * @since arkts {'1.1':'16','1.2':'20'} + * @arkts 1.1&1.2 */ deviceName: string; @@ -2798,7 +2910,8 @@ declare namespace geoLocationManager { * * @type { boolean } * @syscap SystemCapability.Location.Location.Core - * @since 16 + * @since arkts {'1.1':'16','1.2':'20'} + * @arkts 1.1&1.2 */ connectable: boolean; } @@ -3000,14 +3113,16 @@ declare namespace geoLocationManager { * * @enum { number } * @syscap SystemCapability.Location.Location.Geofence - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ export enum CoordinateSystemType { /** * WGS84 coordinates system. * * @syscap SystemCapability.Location.Location.Geofence - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ WGS84 = 1, @@ -3015,7 +3130,8 @@ declare namespace geoLocationManager { * GCJ-02 coordinates system. * * @syscap SystemCapability.Location.Location.Geofence - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ GCJ02 = 2 } @@ -3026,7 +3142,8 @@ declare namespace geoLocationManager { * @enum { number } * @syscap SystemCapability.Location.Location.Core * @systemapi - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ export enum LocationIconStatus { /** @@ -3034,7 +3151,8 @@ declare namespace geoLocationManager { * * @syscap SystemCapability.Location.Location.Core * @systemapi - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ LOCATING_NOT_STARTED = 0, @@ -3043,7 +3161,8 @@ declare namespace geoLocationManager { * * @syscap SystemCapability.Location.Location.Core * @systemapi - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ LOCATING_STARTED = 1, @@ -3052,7 +3171,8 @@ declare namespace geoLocationManager { * * @syscap SystemCapability.Location.Location.Core * @systemapi - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ HD_LOCATING_STARTED = 2 } @@ -3063,7 +3183,8 @@ declare namespace geoLocationManager { * @enum { number } * @syscap SystemCapability.Location.Location.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ export enum LocationError { /** @@ -3071,7 +3192,8 @@ declare namespace geoLocationManager { * * @syscap SystemCapability.Location.Location.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ LOCATING_FAILED_DEFAULT = -1, @@ -3080,7 +3202,8 @@ declare namespace geoLocationManager { * * @syscap SystemCapability.Location.Location.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ LOCATING_FAILED_LOCATION_PERMISSION_DENIED = -2, @@ -3089,7 +3212,8 @@ declare namespace geoLocationManager { * * @syscap SystemCapability.Location.Location.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ LOCATING_FAILED_BACKGROUND_PERMISSION_DENIED = -3, @@ -3098,7 +3222,8 @@ declare namespace geoLocationManager { * * @syscap SystemCapability.Location.Location.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ LOCATING_FAILED_LOCATION_SWITCH_OFF = -4, @@ -3107,7 +3232,8 @@ declare namespace geoLocationManager { * * @syscap SystemCapability.Location.Location.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ LOCATING_FAILED_INTERNET_ACCESS_FAILURE = -5 } @@ -3150,14 +3276,16 @@ declare namespace geoLocationManager { * * @enum { number } * @syscap SystemCapability.Location.Location.Gnss - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ export enum SatelliteConstellationCategory { /** * Invalid value. * * @syscap SystemCapability.Location.Location.Gnss - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ CONSTELLATION_CATEGORY_UNKNOWN = 0, @@ -3165,7 +3293,8 @@ declare namespace geoLocationManager { * GPS. * * @syscap SystemCapability.Location.Location.Gnss - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ CONSTELLATION_CATEGORY_GPS = 1, @@ -3173,7 +3302,8 @@ declare namespace geoLocationManager { * SBAS. * * @syscap SystemCapability.Location.Location.Gnss - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ CONSTELLATION_CATEGORY_SBAS = 2, @@ -3181,7 +3311,8 @@ declare namespace geoLocationManager { * GLONASS. * * @syscap SystemCapability.Location.Location.Gnss - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ CONSTELLATION_CATEGORY_GLONASS = 3, @@ -3189,7 +3320,8 @@ declare namespace geoLocationManager { * QZSS. * * @syscap SystemCapability.Location.Location.Gnss - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ CONSTELLATION_CATEGORY_QZSS = 4, @@ -3197,7 +3329,8 @@ declare namespace geoLocationManager { * BEIDOU. * * @syscap SystemCapability.Location.Location.Gnss - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ CONSTELLATION_CATEGORY_BEIDOU = 5, @@ -3205,7 +3338,8 @@ declare namespace geoLocationManager { * GALILEO. * * @syscap SystemCapability.Location.Location.Gnss - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ CONSTELLATION_CATEGORY_GALILEO = 6, @@ -3213,7 +3347,8 @@ declare namespace geoLocationManager { * IRNSS. * * @syscap SystemCapability.Location.Location.Gnss - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ CONSTELLATION_CATEGORY_IRNSS = 7 } @@ -3223,14 +3358,16 @@ declare namespace geoLocationManager { * * @enum { number } * @syscap SystemCapability.Location.Location.Gnss - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ export enum SatelliteAdditionalInfo { /** * Default value. * * @syscap SystemCapability.Location.Location.Gnss - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ SATELLITES_ADDITIONAL_INFO_NULL = 0, @@ -3238,7 +3375,8 @@ declare namespace geoLocationManager { * Ephemeris data exist. * * @syscap SystemCapability.Location.Location.Gnss - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ SATELLITES_ADDITIONAL_INFO_EPHEMERIS_DATA_EXIST = 1, @@ -3246,7 +3384,8 @@ declare namespace geoLocationManager { * Almanac data exist. * * @syscap SystemCapability.Location.Location.Gnss - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ SATELLITES_ADDITIONAL_INFO_ALMANAC_DATA_EXIST = 2, @@ -3254,7 +3393,8 @@ declare namespace geoLocationManager { * This satellite is being used in location fix. * * @syscap SystemCapability.Location.Location.Gnss - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ SATELLITES_ADDITIONAL_INFO_USED_IN_FIX = 4, @@ -3262,7 +3402,8 @@ declare namespace geoLocationManager { * Carrier frequency exist. * * @syscap SystemCapability.Location.Location.Gnss - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ SATELLITES_ADDITIONAL_INFO_CARRIER_FREQUENCY_EXIST = 8 } @@ -3273,7 +3414,8 @@ declare namespace geoLocationManager { * @enum { number } * @syscap SystemCapability.Location.Location.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ export enum UserActivityScenario { /** @@ -3281,7 +3423,8 @@ declare namespace geoLocationManager { * * @syscap SystemCapability.Location.Location.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ NAVIGATION = 0x401, @@ -3290,7 +3433,8 @@ declare namespace geoLocationManager { * * @syscap SystemCapability.Location.Location.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ SPORT = 0x402, @@ -3299,7 +3443,8 @@ declare namespace geoLocationManager { * * @syscap SystemCapability.Location.Location.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ TRANSPORT = 0x403, @@ -3308,7 +3453,8 @@ declare namespace geoLocationManager { * * @syscap SystemCapability.Location.Location.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ DAILY_LIFE_SERVICE = 0x404 } @@ -3546,7 +3692,8 @@ declare namespace geoLocationManager { * @enum { number } * @syscap SystemCapability.Location.Location.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ export enum PowerConsumptionScenario { /** @@ -3554,7 +3701,8 @@ declare namespace geoLocationManager { * * @syscap SystemCapability.Location.Location.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ HIGH_POWER_CONSUMPTION = 0x601, @@ -3563,7 +3711,8 @@ declare namespace geoLocationManager { * * @syscap SystemCapability.Location.Location.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ LOW_POWER_CONSUMPTION = 0x602, @@ -3572,7 +3721,8 @@ declare namespace geoLocationManager { * * @syscap SystemCapability.Location.Location.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12','1.2':'20'} + * @arkts 1.1&1.2 */ NO_POWER_CONSUMPTION = 0x603 } @@ -3583,7 +3733,8 @@ declare namespace geoLocationManager { * @enum { number } * @syscap SystemCapability.Location.Location.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ export enum LocationPrivacyType { /** @@ -3591,7 +3742,8 @@ declare namespace geoLocationManager { * * @syscap SystemCapability.Location.Location.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ OTHERS = 0, @@ -3600,7 +3752,8 @@ declare namespace geoLocationManager { * * @syscap SystemCapability.Location.Location.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ STARTUP, @@ -3609,7 +3762,8 @@ declare namespace geoLocationManager { * * @syscap SystemCapability.Location.Location.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ CORE_LOCATION } @@ -3620,7 +3774,8 @@ declare namespace geoLocationManager { * @enum { number } * @syscap SystemCapability.Location.Location.Core * @atomicservice - * @since 18 + * @since arkts {'1.1':'18','1.2':'20'} + * @arkts 1.1&1.2 */ export enum SportsType { /** @@ -3628,7 +3783,8 @@ declare namespace geoLocationManager { * * @syscap SystemCapability.Location.Location.Core * @atomicservice - * @since 18 + * @since arkts {'1.1':'18','1.2':'20'} + * @arkts 1.1&1.2 */ RUNNING = 1, @@ -3637,7 +3793,8 @@ declare namespace geoLocationManager { * * @syscap SystemCapability.Location.Location.Core * @atomicservice - * @since 18 + * @since arkts {'1.1':'18','1.2':'20'} + * @arkts 1.1&1.2 */ WALKING, @@ -3646,7 +3803,8 @@ declare namespace geoLocationManager { * * @syscap SystemCapability.Location.Location.Core * @atomicservice - * @since 18 + * @since arkts {'1.1':'18','1.2':'20'} + * @arkts 1.1&1.2 */ CYCLING } @@ -3683,7 +3841,8 @@ declare namespace geoLocationManager { * * @typedef CountryCode * @syscap SystemCapability.Location.Location.Core - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ export interface CountryCode { /** @@ -3691,7 +3850,8 @@ declare namespace geoLocationManager { * * @type { string } * @syscap SystemCapability.Location.Location.Core - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ country: string; @@ -3700,7 +3860,8 @@ declare namespace geoLocationManager { * * @type { CountryCodeType } * @syscap SystemCapability.Location.Location.Core - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ type: CountryCodeType; } @@ -3710,14 +3871,16 @@ declare namespace geoLocationManager { * * @enum { number } * @syscap SystemCapability.Location.Location.Core - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ export enum CountryCodeType { /** * Country code obtained from the locale setting. * * @syscap SystemCapability.Location.Location.Core - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ COUNTRY_CODE_FROM_LOCALE = 1, @@ -3725,7 +3888,8 @@ declare namespace geoLocationManager { * Country code obtained from the SIM information. * * @syscap SystemCapability.Location.Location.Core - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ COUNTRY_CODE_FROM_SIM, @@ -3733,7 +3897,8 @@ declare namespace geoLocationManager { * Query the country code information from the reverse geocoding result. * * @syscap SystemCapability.Location.Location.Core - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ COUNTRY_CODE_FROM_LOCATION, @@ -3741,7 +3906,8 @@ declare namespace geoLocationManager { * Obtain the country code from the cell registration information. * * @syscap SystemCapability.Location.Location.Core - * @since 9 + * @since arkts {'1.1':'9','1.2':'20'} + * @arkts 1.1&1.2 */ COUNTRY_CODE_FROM_NETWORK } @@ -3752,7 +3918,8 @@ declare namespace geoLocationManager { * @enum { number } * @syscap SystemCapability.Location.Location.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10','1.2':'20'} + * @arkts 1.1&1.2 */ export enum LocatingRequiredDataType { /** @@ -3760,7 +3927,8 @@ declare namespace geoLocationManager { * * @syscap SystemCapability.Location.Location.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10','1.2':'20'} + * @arkts 1.1&1.2 */ WIFI = 1, @@ -3769,7 +3937,8 @@ declare namespace geoLocationManager { * * @syscap SystemCapability.Location.Location.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10','1.2':'20'} + * @arkts 1.1&1.2 */ BLUETOOTH } diff --git a/api/@ohos.graphics.common2D.d.ts b/api/@ohos.graphics.common2D.d.ts index ea035d27bd19322de502af069eb0554ac12a710a..3795b8afdeb1c71eda0df0636182a5f642130fda 100644 --- a/api/@ohos.graphics.common2D.d.ts +++ b/api/@ohos.graphics.common2D.d.ts @@ -22,42 +22,48 @@ * * @namespace common2D * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ declare namespace common2D { /** * Describes a color in ARGB format. * @typedef Color * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ interface Color { /** * Alpha component of the color. The value is an integer ranging from 0 to 255. * @type { number } * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ alpha: number; /** * Red component of the color. The value is an integer ranging from 0 to 255. * @type { number } * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ red: number; /** * Green component of the color. The value is an integer ranging from 0 to 255. * @type { number } * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ green: number; /** * Blue component of the color. The value is an integer ranging from 0 to 255. * @type { number } * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ blue: number; } @@ -66,35 +72,40 @@ declare namespace common2D { * Describes a rectangle, which can be defined by two coordinate points: upper left corner point and lower right corner point. * @typedef Rect * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ interface Rect { /** * X coordinate of the upper left corner of the rectangle. The value is a floating point number. * @type { number } * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ left: number; /** * Y coordinate of the upper left corner of the rectangle. The value is a floating point number. * @type { number } * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ top: number; /** * X coordinate of the lower right corner of the rectangle. The value is a floating point number. * @type { number } * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ right: number; /** * Y coordinate of the lower right corner of the rectangle. The value is a floating point number. * @type { number } * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ bottom: number; } @@ -103,14 +114,16 @@ declare namespace common2D { * Describes a coordinate point. * @typedef Point * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ interface Point { /** * Horizontal coordinate. The value is a floating point number. * @type { number } * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ x: number; @@ -118,7 +131,8 @@ declare namespace common2D { * Vertical coordinate. The value is a floating point number. * @type { number } * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ y: number; } diff --git a/api/@ohos.graphics.displaySync.d.ts b/api/@ohos.graphics.displaySync.d.ts index 64492f0336280453755cfa140c410a7d45eb7a0f..2faa399873506e3301e3f49d65e78a637dac8d6c 100644 --- a/api/@ohos.graphics.displaySync.d.ts +++ b/api/@ohos.graphics.displaySync.d.ts @@ -16,6 +16,7 @@ /** * @file * @kit ArkGraphics2D + * @arkts 1.1&1.2 */ import type { Callback } from './@ohos.base'; @@ -25,21 +26,21 @@ import type { Callback } from './@ohos.base'; * * @namespace displaySync * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 11 + * @since arkts {'1.1': '11', '1.2': '20'} */ declare namespace displaySync { /** * Provides the IntervalInfo interface, which includes timestamp and targetTimestamp. * @interface IntervalInfo * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 11 + * @since arkts {'1.1': '11', '1.2': '20'} */ interface IntervalInfo { /** * The timestamp means the current drawing frame time. * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 11 + * @since arkts {'1.1': '11', '1.2': '20'} */ timestamp: number; @@ -47,7 +48,7 @@ declare namespace displaySync { * The timestamp means the next drawing frame time. * @type { number } * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 11 + * @since arkts {'1.1': '11', '1.2': '20'} */ targetTimestamp: number; } @@ -57,7 +58,7 @@ declare namespace displaySync { * the frequency of triggering callback function. * @interface DisplaySync * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 11 + * @since arkts {'1.1': '11', '1.2': '20'} */ interface DisplaySync { /** @@ -71,7 +72,7 @@ declare namespace displaySync { *
3. Parameter verification failed. * or check ExpectedFrameRateRange if valid. * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 11 + * @since arkts {'1.1': '11', '1.2': '20'} */ setExpectedFrameRateRange(rateRange: ExpectedFrameRateRange) : void; @@ -81,7 +82,7 @@ declare namespace displaySync { * @param { 'frame' } type - The type of event to remove the listener for. Must be 'frame'. * @param { Callback } callback - The callback function to be called when DisplaySync dispatching. * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 11 + * @since arkts {'1.1': '11', '1.2': '20'} */ on(type: 'frame', callback: Callback): void; @@ -92,7 +93,7 @@ declare namespace displaySync { * @param { Callback } [callback] - The callback function to remove. If not provided, all callbacks for the given event type * will be removed. * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 11 + * @since arkts {'1.1': '11', '1.2': '20'} */ off(type: 'frame', callback?: Callback): void; @@ -100,7 +101,7 @@ declare namespace displaySync { * Add DisplaySync to Pipeline. It means that * the callback function be enabled. * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 11 + * @since arkts {'1.1': '11', '1.2': '20'} */ start(): void; @@ -108,7 +109,7 @@ declare namespace displaySync { * Delete DisplaySync from Pipeline. It means that * the callback function be disabled. * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 11 + * @since arkts {'1.1': '11', '1.2': '20'} */ stop(): void; } @@ -117,7 +118,7 @@ declare namespace displaySync { * Create a new DisplaySync object. * @returns { DisplaySync } DisplaySync * @syscap SystemCapability.ArkUI.ArkUI.Full - * @since 11 + * @since arkts {'1.1': '11', '1.2': '20'} */ function create(): DisplaySync; } diff --git a/api/@ohos.graphics.drawing.d.ts b/api/@ohos.graphics.drawing.d.ts index 01ab26aafa2ab71f291ab0998ee70e59d3c7f851..3f52a32d8040d7b369180345290040a404fcdc87 100644 --- a/api/@ohos.graphics.drawing.d.ts +++ b/api/@ohos.graphics.drawing.d.ts @@ -28,7 +28,8 @@ import { Resource } from './global/resource'; * * @namespace drawing * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ declare namespace drawing { /** @@ -52,182 +53,212 @@ declare namespace drawing { * * @enum { number } * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ enum BlendMode { /** * r = 0, sets the the destination pixels to fully transparent. * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ CLEAR = 0, /** * r = s (all channels of the result equal those of the source), replaces the destination pixels with the source pixels. * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ SRC = 1, /** * r = d (all channels of the result equal those of the destination), keeps the destination pixels unchanged. * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ DST = 2, /** * r = s + (1 - sa) * d, draws the source pixels over the destination pixels, considering the source's transparency. * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ SRC_OVER = 3, /** * r = d + (1 - da) * s, draws the destination pixels over the source pixels, considering the destination's transparency. * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ DST_OVER = 4, /** * r = s * da, retains only the intersection of the source pixels with the opaque parts of the destination. * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ SRC_IN = 5, /** * r = d * sa, retains only the intersection of the destination pixels with the opaque parts of the source. * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ DST_IN = 6, /** * r = s * (1 - da), retains the parts of the source pixels that do not overlap with the destination. * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ SRC_OUT = 7, /** * r = d * (1 - sa), retains the parts of the destination pixels that do not overlap with the source. * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ DST_OUT = 8, /** * r = s * da + d * (1 - sa), covers the destination pixels with the source pixels, showing the source only in the opaque parts of the destination. * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ SRC_ATOP = 9, /** * r = d * sa + s * (1 - da), covers the source pixels with the destination pixels, showing the destination only in the opaque parts of the source. * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ DST_ATOP = 10, /** * r = s * (1 - da) + d * (1 - sa), shows only the non-overlapping parts of the source and destination pixels. * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ XOR = 11, /** * r = min(s + d, 1), adds the color values of the source and destination pixels. * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ PLUS = 12, /** * r = s * d, multiplies the color values of the source and destination pixels. * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ MODULATE = 13, /** * r = s + d - s * d, inverts the color values of the source and destination pixels, multiplies them, * and then inverts the result, typically producing a brighter outcome. * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ SCREEN = 14, /** * Selectively applies MULTIPLY or SCREEN based on the brightness of the destination pixels, enhancing contrast. * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ OVERLAY = 15, /** * rc = s + d - max(s * da, d * sa), ra = s + (1 - sa) * d, takes the darker color values between the source and destination pixels. * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ DARKEN = 16, /** * rc = s + d - min(s * da, d * sa), ra = s + (1 - sa) * d, takes the lighter color values between the source and destination pixels. * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ LIGHTEN = 17, /** * Brightens the destination pixels by reducing contrast to reflect the source pixels. * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ COLOR_DODGE = 18, /** * Darkens the destination pixels by increasing contrast to reflect the source pixels. * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ COLOR_BURN = 19, /** * Selectively applies MULTIPLY or SCREEN based on the brightness of the source pixels. * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ HARD_LIGHT = 20, /** * Softly brightens or darkens the destination pixels based on the brightness of the source pixels. * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ SOFT_LIGHT = 21, /** * rc = s + d - 2 * (min(s * da, d * sa)), ra = s + (1 - sa) * d, calculates the difference between the color values of the source and destination pixels. * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ DIFFERENCE = 22, /** * rc = s + d - two(s * d), ra = s + (1 - sa) * d, similar to DIFFERENCE but with lower contrast. * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ EXCLUSION = 23, /** * r = s * (1 - da) + d * (1 - sa) + s * d, multiplies the color values of the source and destination pixels, typically resulting in a darker outcome. * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ MULTIPLY = 24, /** * Uses the hue of the source pixels and the saturation and brightness of the destination pixels. * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ HUE = 25, /** * Uses the saturation of the source pixels and the hue and brightness of the destination pixels. * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ SATURATION = 26, /** * Uses the hue and saturation of the source pixels and the brightness of the destination pixels. * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ COLOR = 27, /** * Uses the brightness of the source pixels and the hue and saturation of the destination pixels. * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ LUMINOSITY = 28, } @@ -328,7 +359,8 @@ declare namespace drawing { * Implements a rounded rectangle. * * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ class RoundRect { @@ -350,7 +382,8 @@ declare namespace drawing { * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ constructor(rect: common2D.Rect, xRadii: number, yRadii: number); @@ -396,41 +429,47 @@ declare namespace drawing { * Enumerates the path operation types. It is often used in path combination and clipping scenarios. * @enum { number } * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ enum PathOp { /** * Difference operation. * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ DIFFERENCE = 0, /** * Intersection operation. * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ INTERSECT = 1, /** * Union operation. * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ UNION = 2, /** * XOR operation. * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ XOR = 3, /** * Reverse difference operation. * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ REVERSE_DIFFERENCE = 4, } @@ -496,14 +535,16 @@ declare namespace drawing { * Implements a path operation iterator. You can read path operation instructions by traversing the iterator. * * @syscap SystemCapability.Graphics.Drawing - * @since 18 + * @since arkts {'1.1':'18', '1.2':'20'} + * @arkts 1.1&1.2 */ class PathIterator { /** * Creates an iterator and binds it with a path. * @param { Path } path - Path object bound to the iterator. * @syscap SystemCapability.Graphics.Drawing - * @since 18 + * @since arkts {'1.1':'18', '1.2':'20'} + * @arkts 1.1&1.2 */ constructor(path: Path); @@ -540,13 +581,15 @@ declare namespace drawing { * A compound geometric path consisting of line segments, arcs, quadratic Bezier curves, and cubic Bezier curves. * * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ class Path { /** * Constructs a path. * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ constructor(); @@ -554,7 +597,8 @@ declare namespace drawing { * Constructs a copy of an existing path. * @param { Path } path - Path to copy. * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ constructor(path: Path); @@ -603,7 +647,8 @@ declare namespace drawing { * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ arcTo(x1: number, y1: number, x2: number, y2: number, startDeg: number, sweepDeg: number): void; @@ -931,7 +976,8 @@ declare namespace drawing { /** * Resets the path data. * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ reset(): void; @@ -1136,20 +1182,23 @@ declare namespace drawing { * Enumerates the filter modes. * @enum { number } * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ enum FilterMode { /** * Nearest filter mode. * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ FILTER_MODE_NEAREST = 0, /** * Linear filter mode. * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ FILTER_MODE_LINEAR = 1, } @@ -1193,13 +1242,15 @@ declare namespace drawing { /** * Implements sampling options. * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ class SamplingOptions { /** * Creates a SamplingOptions object. The default value of FilterMode is FILTER_MODE_NEAREST. * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ constructor(); /** @@ -1208,7 +1259,8 @@ declare namespace drawing { * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ constructor(filterMode: FilterMode); } @@ -1216,7 +1268,8 @@ declare namespace drawing { /** * A carrier that carries the drawn content and drawing status. * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ class Canvas { /** @@ -1225,7 +1278,8 @@ declare namespace drawing { * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ constructor(pixelmap: image.PixelMap); @@ -1235,7 +1289,8 @@ declare namespace drawing { * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ drawRect(rect: common2D.Rect): void; @@ -1248,7 +1303,8 @@ declare namespace drawing { * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ drawRect(left: number, top: number, right: number, bottom: number): void; @@ -1398,7 +1454,8 @@ declare namespace drawing { * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ drawImageRect(pixelmap: image.PixelMap, dstRect: common2D.Rect, samplingOptions?: SamplingOptions): void; @@ -1595,7 +1652,8 @@ declare namespace drawing { * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ drawPixelMapMesh(pixelmap: image.PixelMap, meshWidth: number, meshHeight: number, vertices: Array, vertOffset: number, colors: Array, colorOffset: number): void; @@ -1626,7 +1684,8 @@ declare namespace drawing { * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ attachBrush(brush: Brush): void; @@ -1640,7 +1699,8 @@ declare namespace drawing { /** * Detaches the brush from the canvas. When you draw on the canvas, the brush is no longer used to fill the interior of shapes. * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ detachBrush(): void; @@ -1662,7 +1722,8 @@ declare namespace drawing { * @returns { number } Number of canvas statuses that have been saved. The value is a positive integer. * @throws { BusinessError } 401 - Parameter error. Possible causes: Mandatory parameters are left unspecified. * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ saveLayer(rect?: common2D.Rect | null, brush?: Brush | null): number; @@ -1687,7 +1748,8 @@ declare namespace drawing { /** * Restores the canvas state (canvas matrix and clipping area) saved on the top of the stack. * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ restore(): void; @@ -1781,7 +1843,8 @@ declare namespace drawing { * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ rotate(degrees: number, sx: number, sy: number) : void; @@ -1907,19 +1970,22 @@ declare namespace drawing { * * @enum { number } * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ enum ClipOp { /** * Clips a specified area. That is, the difference set is obtained. * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ DIFFERENCE = 0, /** * Retains a specified area. That is, the intersection is obtained. * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ INTERSECT = 1, } @@ -2089,7 +2155,8 @@ declare namespace drawing { * Describes the style of a typeface, such as SimSun or KaiTi. * * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ class Typeface { /** @@ -2117,7 +2184,8 @@ declare namespace drawing { * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ static makeFromFile(filePath: string): Typeface; @@ -2230,7 +2298,8 @@ declare namespace drawing { * Describes the attributes used for text rendering, such as size and typeface. * * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ class Font { /** @@ -2273,7 +2342,8 @@ declare namespace drawing { * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types; 3. Parameter verification failed. * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ setSize(textSize: number): void; @@ -2291,7 +2361,8 @@ declare namespace drawing { * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ setTypeface(typeface: Typeface): void; @@ -2307,7 +2378,8 @@ declare namespace drawing { * Obtains the font metrics of the typeface. * @returns { FontMetrics } The fontMetrics value returned to the caller. * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ getMetrics(): FontMetrics; @@ -2631,7 +2703,8 @@ declare namespace drawing { * Describes the attributes that describe the font size and layout. A typeface has similar font metrics. * @typedef FontMetrics * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ interface FontMetrics { /** @@ -2646,28 +2719,32 @@ declare namespace drawing { * Maximum distance from the baseline to the highest coordinate of the text. The value is a floating point number. * @type { number } * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ top: number; /** * Distance from the baseline to the highest coordinate of the text. The value is a floating point number. * @type { number } * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ ascent: number; /** * Distance from the baseline to the lowest coordinate of the text. The value is a floating point number. * @type { number } * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ descent: number; /** * Maximum distance from the baseline to the lowest coordinate of the text. The value is a floating point number. * @type { number } * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ bottom: number; /** @@ -2675,7 +2752,8 @@ declare namespace drawing { * The value is a floating point number. * @type { number } * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ leading: number; /** @@ -2764,7 +2842,8 @@ declare namespace drawing { /** * Implements a lattice object, which is used to divide an image by lattice. * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ class Lattice { /** @@ -2788,7 +2867,8 @@ declare namespace drawing { *
2. Incorrect parameter types; 3. Parameter verification failed. * @static * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ static createImageLattice(xDivs: Array, yDivs: Array, fXCount: number, fYCount: number, fBounds?: common2D.Rect | null, fRectTypes?: Array | null, fColors?: Array | null): Lattice; @@ -2825,27 +2905,31 @@ declare namespace drawing { * Enumerates the types of rectangles used to fill the lattices. This enum is used only in Lattice. * @enum { number } * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ enum RectType { /** * Draws an image into the lattice. * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ DEFAULT = 0, /** * Sets the lattice to transparent. * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ TRANSPARENT = 1, /** * Draws the colors in the fColors array in Lattice into the lattice. * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ FIXEDCOLOR = 2 } @@ -3216,7 +3300,8 @@ declare namespace drawing { * Defines a color filter. * * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ class ColorFilter { /** @@ -3228,7 +3313,8 @@ declare namespace drawing { *
2. Incorrect parameter types; 3. Parameter verification failed. * @static * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ static createBlendModeColorFilter(color: common2D.Color, mode: BlendMode): ColorFilter; @@ -3241,7 +3327,8 @@ declare namespace drawing { *
2. Incorrect parameter types; 3. Parameter verification failed. * @static * @syscap SystemCapability.Graphics.Drawing - * @since 18 + * @since arkts {'1.1':'18', '1.2':'20'} + * @arkts 1.1&1.2 */ static createBlendModeColorFilter(color: common2D.Color | number, mode: BlendMode): ColorFilter; @@ -3512,13 +3599,15 @@ declare namespace drawing { /** * Defines a pen, which is used to describe the style and color to outline a shape. * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ class Pen { /** * A constructor used to create a Pen object. * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ constructor(); @@ -3528,7 +3617,8 @@ declare namespace drawing { * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ constructor(pen: Pen); @@ -3761,7 +3851,8 @@ declare namespace drawing { * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types; 3. Parameter verification failed. * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ setBlendMode(mode: BlendMode): void; @@ -3819,7 +3910,8 @@ declare namespace drawing { /** * Resets this pen to the initial state. * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ reset(): void; /** @@ -3839,13 +3931,15 @@ declare namespace drawing { /** * Defines a brush, which is used to describe the style and color to fill in a shape. * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ class Brush { /** * A constructor used to create a Brush object. * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ constructor(); @@ -3855,7 +3949,8 @@ declare namespace drawing { * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types. * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ constructor(brush: Brush); @@ -4033,14 +4128,16 @@ declare namespace drawing { * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; *
2. Incorrect parameter types; 3. Parameter verification failed. * @syscap SystemCapability.Graphics.Drawing - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ setBlendMode(mode: BlendMode): void; /** * Resets this brush to the initial state. * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ reset(): void; } @@ -4049,13 +4146,15 @@ declare namespace drawing { * Implements a matrix. * * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ class Matrix { /** * Creates a Matrix object. * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ constructor(); @@ -4360,7 +4459,8 @@ declare namespace drawing { /** * Resets this matrix to an identity matrix. * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ reset(): void; /** @@ -4476,7 +4576,8 @@ declare namespace drawing { /** * Describes a region, which is used to describe the region where the shape can be drawn. * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ class Region { /** @@ -4675,48 +4776,55 @@ declare namespace drawing { * Enumerates the operations for combining two regions. * @enum { number } * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ enum RegionOp { /** * Difference operation. * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ DIFFERENCE = 0, /** * Intersect operation. * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ INTERSECT = 1, /** * Union operation. * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ UNION = 2, /** * Xor operation. * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ XOR = 3, /** * Reverse difference operation. * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ REVERSE_DIFFERENCE = 4, /** * Replace operation. * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ REPLACE = 5 } diff --git a/api/@ohos.graphics.uiEffect.d.ts b/api/@ohos.graphics.uiEffect.d.ts index 929fbdc1dbde733fbc6ded31ea5204e6fe17dbeb..daa434171b69c0fbad11f02ced417bd61ff63faa 100644 --- a/api/@ohos.graphics.uiEffect.d.ts +++ b/api/@ohos.graphics.uiEffect.d.ts @@ -19,10 +19,7 @@ */ import { AsyncCallback } from './@ohos.base'; -/*** if arkts 1.1 */ -import type common2D from './@ohos.graphics.common2D'; -import type image from './@ohos.multimedia.image'; -/*** endif */ + /** * @namespace uiEffect @@ -31,7 +28,6 @@ import type image from './@ohos.multimedia.image'; * @arkts 1.1&1.2 */ declare namespace uiEffect { - /** * The Filter for Component. * @typedef Filter @@ -48,7 +44,8 @@ declare namespace uiEffect { * @returns { Filter } * @syscap SystemCapability.Graphics.Drawing * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ pixelStretch(stretchSizes: Array, tileMode: TileMode): Filter; @@ -58,7 +55,8 @@ declare namespace uiEffect { * @param { number } blurRadius * @returns { Filter } * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ blur(blurRadius: number): Filter; @@ -75,7 +73,8 @@ declare namespace uiEffect { * @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API. * @syscap SystemCapability.Graphics.Drawing * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ waterRipple(progress: number, waveCount: number, x: number, y: number, rippleMode: WaterRippleMode): Filter; @@ -89,7 +88,8 @@ declare namespace uiEffect { * @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API. * @syscap SystemCapability.Graphics.Drawing * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ flyInFlyOutEffect(degree: number, flyMode: FlyMode): Filter; @@ -104,123 +104,10 @@ declare namespace uiEffect { * @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API. * @syscap SystemCapability.Graphics.Drawing * @systemapi - * @since 13 + * @since arkts {'1.1':'13', '1.2':'20'} + * @arkts 1.1&1.2 */ distort(distortionK: number): Filter; - - /** - * Adds the content radius gradient blurring effect for the current component. The input parameter is the blurring radius. - * - * @param { number } value - the blurring radius. - * The larger the blurring radius, the more blurring the content, and if the value is 0, the content blurring effect is not blurring. - * @param { LinearGradientBlurOptions } options - the radius gradient blur options. - * @returns { Filter } - Returns radius gradient blur Filter. - * @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API. - * @syscap SystemCapability.Graphics.Drawing - * @systemapi - * @since 19 - */ - radiusGradientBlur(value: number, options: LinearGradientBlurOptions): Filter; - - /** - * Sets the deformation effect controlled by bezier curves of the component. - * - * @param { Array } controlPoints - The bezier control points, 12 points needed. - * @returns { Filter } - Returns the Filter that the current effect have been added. - * @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API. - * @syscap SystemCapability.Graphics.Drawing - * @systemapi - * @since 20 - */ - bezierWarp(controlPoints: Array): Filter; - - /** - * Sets the content light filter. - * - * @param { common2D.Point3d } lightPosition - * @param { common2D.Color } lightColor - * @param { number } lightIntensity - * @param { Mask } [displacementMap] - * @returns { Filter } - Returns the Filter that the current effect have been added. - * @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API. - * @syscap SystemCapability.Graphics.Drawing - * @systemapi - * @since 20 - */ - contentLight(lightPosition: common2D.Point3d, lightColor: common2D.Color, lightIntensity: number, - displacementMap?: Mask): Filter; - - /** - * Sets the color gradient filter, may blend with alpha mask. - * - * @param { Array } colors - * @param { Array } positions - * @param { Array } strengths - * @param { Mask } [alphaMask] - * @returns { Filter } - Returns the Filter that the current effect have been added. - * @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API. - * @syscap SystemCapability.Graphics.Drawing - * @systemapi - * @since 20 - */ - colorGradient(colors: Array, positions: Array, strengths: Array, - alphaMask?: Mask): Filter; - - /** - * Detects and glows edges of contents. - * - * @param { number } alpha - * @param { Color } [color] - * @param { Mask } [mask] - * @param { boolean } [bloom] - * @returns { Filter } - Returns the Filter that the current effect have been added. - * @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API. - * @syscap SystemCapability.Graphics.Drawing - * @systemapi - * @since 20 - */ - edgeLight(alpha: number, color?: Color, mask?: Mask, bloom?: boolean): Filter; - - /** - * Sets distort effect with displacement map. - * - * @param { Mask } displacementMap - * @param { [number, number] } [factor] - * @returns { Filter } - Returns the Filter that the current effect have been added. - * @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API. - * @syscap SystemCapability.Graphics.Drawing - * @systemapi - * @since 20 - */ - displacementDistort(displacementMap: Mask, factor?: [number, number]): Filter; - - /** - * Sets dispersion effect with mask map. - * - * @param { Mask } dispersionMap - * @param { number } alpha - * @param { [number, number] } [rFactor] - * @param { [number, number] } [gFactor] - * @param { [number, number] } [bFactor] - * @returns { Filter } - Returns the Filter that the current effect have been added. - * @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API. - * @syscap SystemCapability.Graphics.Drawing - * @systemapi - * @since 20 - */ - maskDispersion(dispersionMap: Mask, alpha: number, rFactor?: [number, number], gFactor?: [number, number], - bFactor?: [number, number]): Filter; - - /** - * Applies a high dynamic range (HDR) brightness enhancement filter to the component. - * @param { number } ratio - The brightness multiplier ratio (1.0 = original, >1.0 = brighter). - * @returns { Filter } - Returns hdr brightness Filter. - * @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API. - * @syscap SystemCapability.Graphics.Drawing - * @systemapi - * @since 20 - */ - hdrBrightnessRatio(ratio: number): Filter; } /** @@ -229,7 +116,8 @@ declare namespace uiEffect { * @enum { number } * @syscap SystemCapability.Graphics.Drawing * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ enum TileMode { /** @@ -237,7 +125,8 @@ declare namespace uiEffect { * * @syscap SystemCapability.Graphics.Drawing * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ CLAMP = 0, @@ -246,7 +135,8 @@ declare namespace uiEffect { * * @syscap SystemCapability.Graphics.Drawing * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ REPEAT = 1, @@ -255,7 +145,8 @@ declare namespace uiEffect { * * @syscap SystemCapability.Graphics.Drawing * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ MIRROR = 2, @@ -264,7 +155,8 @@ declare namespace uiEffect { * * @syscap SystemCapability.Graphics.Drawing * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ DECAL = 3, } @@ -275,7 +167,8 @@ declare namespace uiEffect { * @enum { number } * @syscap SystemCapability.Graphics.Drawing * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ enum WaterRippleMode { /** @@ -283,7 +176,8 @@ declare namespace uiEffect { * * @syscap SystemCapability.Graphics.Drawing * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ SMALL2MEDIUM_RECV = 0, @@ -292,7 +186,8 @@ declare namespace uiEffect { * * @syscap SystemCapability.Graphics.Drawing * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ SMALL2MEDIUM_SEND = 1, @@ -301,7 +196,8 @@ declare namespace uiEffect { * * @syscap SystemCapability.Graphics.Drawing * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ SMALL2SMALL = 2, @@ -310,7 +206,8 @@ declare namespace uiEffect { * * @syscap SystemCapability.Graphics.Drawing * @systemapi - * @since 17 + * @since arkts {'1.1':'17', '1.2':'20'} + * @arkts 1.1&1.2 */ MINI_RECV = 3, } @@ -321,7 +218,8 @@ declare namespace uiEffect { * @enum { number } * @syscap SystemCapability.Graphics.Drawing * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ enum FlyMode { /** @@ -329,7 +227,8 @@ declare namespace uiEffect { * * @syscap SystemCapability.Graphics.Drawing * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ BOTTOM = 0, @@ -338,7 +237,8 @@ declare namespace uiEffect { * * @syscap SystemCapability.Graphics.Drawing * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ TOP = 1, } @@ -361,22 +261,6 @@ declare namespace uiEffect { * @arkts 1.1&1.2 */ backgroundColorBlender(blender: BrightnessBlender): VisualEffect; - - /** - * Sets the border light effect. - * - * @param { common2D.Point3d } lightPosition - * @param { common2D.Color } lightColor - * @param { number } lightIntensity - * @param { number } borderWidth - * @returns { VisualEffect } - Returns the VisualEffect that the current effect have been added. - * @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API. - * @syscap SystemCapability.Graphics.Drawing - * @systemapi - * @since 20 - */ - borderLight(lightPosition: common2D.Point3d, lightColor: common2D.Color, lightIntensity: number, - borderWidth: number): VisualEffect; } /** @@ -487,109 +371,12 @@ declare namespace uiEffect { fraction: number; } - /** - * The Color of Light. - * @typedef Color - * @syscap SystemCapability.Graphics.Drawing - * @systemapi - * @since 20 - */ - interface Color { - /** - * Red component of color. - * @type { number } - * @syscap SystemCapability.Graphics.Drawing - * @systemapi - * @since 20 - */ - red: number; - /** - * Green component of color. - * @type { number } - * @syscap SystemCapability.Graphics.Drawing - * @systemapi - * @since 20 - */ - green: number; - /** - * Blue component of color - * @type { number } - * @syscap SystemCapability.Graphics.Drawing - * @systemapi - * @since 20 - */ - blue: number; - /** - * Alpha component of color. - * @type { number } - * @syscap SystemCapability.Graphics.Drawing - * @systemapi - * @since 20 - */ - alpha: number; - } - - /** - * Defines the mask for Filter or VisualEffect. - * @typedef { Mask } - * @syscap SystemCapability.Graphics.Drawing - * @systemapi - * @since 20 - */ - class Mask { - /** - * Create a Mask of ripple. - * @param { common2D.Point } center - * @param { number } radius - * @param { number } width - * @param { number } [offset] - * @returns { Mask } - * @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API. - * @static - * @syscap SystemCapability.Graphics.Drawing - * @systemapi - * @since 20 - */ - static createRippleMask(center: common2D.Point, radius: number, width: number, offset?: number): Mask; - - /** - * Create a Mask of pixelmap. - * @param { image.PixelMap } pixelMap - * @param { common2D.Rect } srcRect - * @param { common2D.Rect } dstRect - * @param { Color } [fillColor] - * @returns { Mask } - * @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API. - * @static - * @syscap SystemCapability.Graphics.Drawing - * @systemapi - * @since 20 - */ - static createPixelMapMask(pixelMap: image.PixelMap, srcRect: common2D.Rect, dstRect: common2D.Rect, - fillColor?: Color): Mask; - - /** - * Create a Mask of radial gradient. - * @param { common2D.Point } center - * @param { number } radiusX - * @param { number } radiusY - * @param { Array<[number, number]> } values - * @returns { Mask } - * @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API. - * @static - * @syscap SystemCapability.Graphics.Drawing - * @systemapi - * @since 20 - */ - static createRadialGradientMask(center: common2D.Point, radiusX: number, radiusY: number, - values: Array<[number, number]>): Mask; - } - /** * Create a Filter to add multiple effects to the component. * @returns { Filter } Returns the head node of Filter. * @syscap SystemCapability.Graphics.Drawing - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ function createFilter(): Filter; diff --git a/api/@ohos.hiTraceChain.d.ts b/api/@ohos.hiTraceChain.d.ts index 0e3c01da192dbe54f4b2216657b8ea4fcbf8e550..e10a356cdc279dee30f1673d4919fa9a35f63ab9 100644 --- a/api/@ohos.hiTraceChain.d.ts +++ b/api/@ohos.hiTraceChain.d.ts @@ -26,7 +26,8 @@ * * @namespace hiTraceChain * @syscap SystemCapability.HiviewDFX.HiTrace - * @since 8 + * @since arkts {'1.1':'8','1.2':'20'} + * @arkts 1.1&1.2 */ declare namespace hiTraceChain { /** @@ -34,14 +35,16 @@ declare namespace hiTraceChain { * * @enum { number } * @syscap SystemCapability.HiviewDFX.HiTrace - * @since 8 + * @since arkts {'1.1':'8','1.2':'20'} + * @arkts 1.1&1.2 */ enum HiTraceFlag { /** * Default value * * @syscap SystemCapability.HiviewDFX.HiTrace - * @since 8 + * @since arkts {'1.1':'8','1.2':'20'} + * @arkts 1.1&1.2 */ DEFAULT = 0, @@ -49,7 +52,8 @@ declare namespace hiTraceChain { * Trace sync and async call. default: trace sync call only. * * @syscap SystemCapability.HiviewDFX.HiTrace - * @since 8 + * @since arkts {'1.1':'8','1.2':'20'} + * @arkts 1.1&1.2 */ INCLUDE_ASYNC = 1, @@ -57,7 +61,8 @@ declare namespace hiTraceChain { * Do not create child span. default: create child span. * * @syscap SystemCapability.HiviewDFX.HiTrace - * @since 8 + * @since arkts {'1.1':'8','1.2':'20'} + * @arkts 1.1&1.2 */ DONOT_CREATE_SPAN = 1 << 1, @@ -65,7 +70,8 @@ declare namespace hiTraceChain { * Output tracepoint info in span. default: do not output tracepoint info. * * @syscap SystemCapability.HiviewDFX.HiTrace - * @since 8 + * @since arkts {'1.1':'8','1.2':'20'} + * @arkts 1.1&1.2 */ TP_INFO = 1 << 2, @@ -73,7 +79,8 @@ declare namespace hiTraceChain { * Do not output begin and end info. default: output begin and end info. * * @syscap SystemCapability.HiviewDFX.HiTrace - * @since 8 + * @since arkts {'1.1':'8','1.2':'20'} + * @arkts 1.1&1.2 */ NO_BE_INFO = 1 << 3, @@ -81,7 +88,8 @@ declare namespace hiTraceChain { * Do not add id to log. default: add id to log. * * @syscap SystemCapability.HiviewDFX.HiTrace - * @since 8 + * @since arkts {'1.1':'8','1.2':'20'} + * @arkts 1.1&1.2 */ DISABLE_LOG = 1 << 4, @@ -89,7 +97,8 @@ declare namespace hiTraceChain { * The trace is triggered by fault. * * @syscap SystemCapability.HiviewDFX.HiTrace - * @since 8 + * @since arkts {'1.1':'8','1.2':'20'} + * @arkts 1.1&1.2 */ FAILURE_TRIGGER = 1 << 5, @@ -97,7 +106,8 @@ declare namespace hiTraceChain { * Output device-to-device tracepoint info in span only. default: do not output device-to-device tracepoint info. * * @syscap SystemCapability.HiviewDFX.HiTrace - * @since 8 + * @since arkts {'1.1':'8','1.2':'20'} + * @arkts 1.1&1.2 */ D2D_TP_INFO = 1 << 6 } @@ -107,14 +117,16 @@ declare namespace hiTraceChain { * * @enum { number } * @syscap SystemCapability.HiviewDFX.HiTrace - * @since 8 + * @since arkts {'1.1':'8','1.2':'20'} + * @arkts 1.1&1.2 */ enum HiTraceTracepointType { /** * Client send * * @syscap SystemCapability.HiviewDFX.HiTrace - * @since 8 + * @since arkts {'1.1':'8','1.2':'20'} + * @arkts 1.1&1.2 */ CS = 0, @@ -122,7 +134,8 @@ declare namespace hiTraceChain { * Client receive * * @syscap SystemCapability.HiviewDFX.HiTrace - * @since 8 + * @since arkts {'1.1':'8','1.2':'20'} + * @arkts 1.1&1.2 */ CR = 1, @@ -130,7 +143,8 @@ declare namespace hiTraceChain { * Server send * * @syscap SystemCapability.HiviewDFX.HiTrace - * @since 8 + * @since arkts {'1.1':'8','1.2':'20'} + * @arkts 1.1&1.2 */ SS = 2, @@ -138,7 +152,8 @@ declare namespace hiTraceChain { * Server receive * * @syscap SystemCapability.HiviewDFX.HiTrace - * @since 8 + * @since arkts {'1.1':'8','1.2':'20'} + * @arkts 1.1&1.2 */ SR = 3, @@ -146,7 +161,8 @@ declare namespace hiTraceChain { * General info * * @syscap SystemCapability.HiviewDFX.HiTrace - * @since 8 + * @since arkts {'1.1':'8','1.2':'20'} + * @arkts 1.1&1.2 */ GENERAL = 4 } @@ -156,14 +172,16 @@ declare namespace hiTraceChain { * * @enum { number } * @syscap SystemCapability.HiviewDFX.HiTrace - * @since 8 + * @since arkts {'1.1':'8','1.2':'20'} + * @arkts 1.1&1.2 */ enum HiTraceCommunicationMode { /** * Unspecified * * @syscap SystemCapability.HiviewDFX.HiTrace - * @since 8 + * @since arkts {'1.1':'8','1.2':'20'} + * @arkts 1.1&1.2 */ DEFAULT = 0, @@ -171,7 +189,8 @@ declare namespace hiTraceChain { * Thread-to-thread * * @syscap SystemCapability.HiviewDFX.HiTrace - * @since 8 + * @since arkts {'1.1':'8','1.2':'20'} + * @arkts 1.1&1.2 */ THREAD = 1, @@ -179,7 +198,8 @@ declare namespace hiTraceChain { * Process-to-process * * @syscap SystemCapability.HiviewDFX.HiTrace - * @since 8 + * @since arkts {'1.1':'8','1.2':'20'} + * @arkts 1.1&1.2 */ PROCESS = 2, @@ -187,7 +207,8 @@ declare namespace hiTraceChain { * Device-to-device * * @syscap SystemCapability.HiviewDFX.HiTrace - * @since 8 + * @since arkts {'1.1':'8','1.2':'20'} + * @arkts 1.1&1.2 */ DEVICE = 3 } @@ -197,7 +218,8 @@ declare namespace hiTraceChain { * * @interface HiTraceId * @syscap SystemCapability.HiviewDFX.HiTrace - * @since 8 + * @since arkts {'1.1':'8','1.2':'20'} + * @arkts 1.1&1.2 */ interface HiTraceId { /** @@ -205,7 +227,8 @@ declare namespace hiTraceChain { * * @type { bigint } * @syscap SystemCapability.HiviewDFX.HiTrace - * @since 8 + * @since arkts {'1.1':'8','1.2':'20'} + * @arkts 1.1&1.2 */ chainId: bigint; @@ -214,7 +237,8 @@ declare namespace hiTraceChain { * * @type { ?number } * @syscap SystemCapability.HiviewDFX.HiTrace - * @since 8 + * @since arkts {'1.1':'8','1.2':'20'} + * @arkts 1.1&1.2 */ spanId?: number; @@ -223,7 +247,8 @@ declare namespace hiTraceChain { * * @type { ?number } * @syscap SystemCapability.HiviewDFX.HiTrace - * @since 8 + * @since arkts {'1.1':'8','1.2':'20'} + * @arkts 1.1&1.2 */ parentSpanId?: number; @@ -232,7 +257,8 @@ declare namespace hiTraceChain { * * @type { ?number } * @syscap SystemCapability.HiviewDFX.HiTrace - * @since 8 + * @since arkts {'1.1':'8','1.2':'20'} + * @arkts 1.1&1.2 */ flags?: number; } @@ -244,7 +270,8 @@ declare namespace hiTraceChain { * @param { number } flags Trace function flag. * @returns { HiTraceId } Valid if first call, otherwise invalid. * @syscap SystemCapability.HiviewDFX.HiTrace - * @since 8 + * @since arkts {'1.1':'8','1.2':'20'} + * @arkts 1.1&1.2 */ function begin(name: string, flags?: number): HiTraceId; @@ -254,7 +281,8 @@ declare namespace hiTraceChain { * * @param { HiTraceId } id The trace id that need to stop. * @syscap SystemCapability.HiviewDFX.HiTrace - * @since 8 + * @since arkts {'1.1':'8','1.2':'20'} + * @arkts 1.1&1.2 */ function end(id: HiTraceId): void; @@ -264,7 +292,8 @@ declare namespace hiTraceChain { * * @returns { HiTraceId } Valid if current thread have a trace id, otherwise invalid. * @syscap SystemCapability.HiviewDFX.HiTrace - * @since 8 + * @since arkts {'1.1':'8','1.2':'20'} + * @arkts 1.1&1.2 */ function getId(): HiTraceId; @@ -273,7 +302,8 @@ declare namespace hiTraceChain { * * @param { HiTraceId } id Set id as trace id of current thread. * @syscap SystemCapability.HiviewDFX.HiTrace - * @since 8 + * @since arkts {'1.1':'8','1.2':'20'} + * @arkts 1.1&1.2 */ function setId(id: HiTraceId): void; @@ -281,7 +311,8 @@ declare namespace hiTraceChain { * Clear trace id of current thread and set it invalid. * * @syscap SystemCapability.HiviewDFX.HiTrace - * @since 8 + * @since arkts {'1.1':'8','1.2':'20'} + * @arkts 1.1&1.2 */ function clearId(): void; @@ -290,7 +321,8 @@ declare namespace hiTraceChain { * * @returns { HiTraceId } A valid span trace id. Otherwise trace id of current thread if do not allow create span. * @syscap SystemCapability.HiviewDFX.HiTrace - * @since 8 + * @since arkts {'1.1':'8','1.2':'20'} + * @arkts 1.1&1.2 */ function createSpan(): HiTraceId; @@ -302,7 +334,8 @@ declare namespace hiTraceChain { * @param { HiTraceId } id Trace id that need to print. * @param { string } msg Customized info that need to print. * @syscap SystemCapability.HiviewDFX.HiTrace - * @since 8 + * @since arkts {'1.1':'8','1.2':'20'} + * @arkts 1.1&1.2 */ function tracepoint(mode: HiTraceCommunicationMode, type: HiTraceTracepointType, id: HiTraceId, msg?: string): void; @@ -312,7 +345,8 @@ declare namespace hiTraceChain { * @param { HiTraceId } id Trace id that need to judge. * @returns { boolean } True for a valid trace id, otherwise false. * @syscap SystemCapability.HiviewDFX.HiTrace - * @since 8 + * @since arkts {'1.1':'8','1.2':'20'} + * @arkts 1.1&1.2 */ function isValid(id: HiTraceId): boolean; @@ -323,7 +357,8 @@ declare namespace hiTraceChain { * @param { HiTraceFlag } flag Trace flag that need to judge. * @returns { boolean } true if the trace id has enabled the flag. * @syscap SystemCapability.HiviewDFX.HiTrace - * @since 8 + * @since arkts {'1.1':'8','1.2':'20'} + * @arkts 1.1&1.2 */ function isFlagEnabled(id: HiTraceId, flag: HiTraceFlag): boolean; @@ -333,7 +368,8 @@ declare namespace hiTraceChain { * @param { HiTraceId } id Trace id that need to enable a flag. * @param { HiTraceFlag } flag the designative trace flag that need to be enabled in the trace id. * @syscap SystemCapability.HiviewDFX.HiTrace - * @since 8 + * @since arkts {'1.1':'8','1.2':'20'} + * @arkts 1.1&1.2 */ function enableFlag(id: HiTraceId, flag: HiTraceFlag): void; } diff --git a/api/@ohos.hiTraceMeter.d.ts b/api/@ohos.hiTraceMeter.d.ts index 47b2820207864e15f14ebd668c453eefd80d8cf3..6b1a88c15141555ae526611a4f0f109ae8544ab0 100644 --- a/api/@ohos.hiTraceMeter.d.ts +++ b/api/@ohos.hiTraceMeter.d.ts @@ -135,6 +135,7 @@ declare namespace hiTraceMeter { * @crossplatform * @atomicservice * @since 20 + * @arkts 1.1&1.2 */ enum HiTraceOutputLevel { /** @@ -151,6 +152,7 @@ declare namespace hiTraceMeter { * @crossplatform * @atomicservice * @since 20 + * @arkts 1.1&1.2 */ DEBUG = 0, @@ -168,6 +170,7 @@ declare namespace hiTraceMeter { * @crossplatform * @atomicservice * @since 20 + * @arkts 1.1&1.2 */ INFO = 1, @@ -185,6 +188,7 @@ declare namespace hiTraceMeter { * @crossplatform * @atomicservice * @since 20 + * @arkts 1.1&1.2 */ CRITICAL = 2, @@ -202,6 +206,7 @@ declare namespace hiTraceMeter { * @crossplatform * @atomicservice * @since 20 + * @arkts 1.1&1.2 */ COMMERCIAL = 3, @@ -219,6 +224,7 @@ declare namespace hiTraceMeter { * @crossplatform * @atomicservice * @since 20 + * @arkts 1.1&1.2 */ MAX = COMMERCIAL } @@ -336,6 +342,7 @@ declare namespace hiTraceMeter { * @crossplatform * @atomicservice * @since 20 + * @arkts 1.1&1.2 */ function traceByValue(name: string, count: number): void; @@ -348,7 +355,7 @@ declare namespace hiTraceMeter { * * @param { HiTraceOutputLevel } level Indicates trace output priority level. * @param { string } name Indicates the task name. - * @param { string } customArgs Indicates key=value pair to be output in trace; multiple pairs should use comma + * @param { string } [customArgs] Indicates key=value pair to be output in trace; multiple pairs should use comma * as separator. * @syscap SystemCapability.HiviewDFX.HiTrace * @atomicservice @@ -363,12 +370,13 @@ declare namespace hiTraceMeter { * * @param { HiTraceOutputLevel } level Indicates trace output priority level. * @param { string } name Indicates the task name. - * @param { string } customArgs Indicates key=value pair to be output in trace; multiple pairs should use comma + * @param { string } [customArgs] Indicates key=value pair to be output in trace; multiple pairs should use comma * as separator. * @syscap SystemCapability.HiviewDFX.HiTrace * @crossplatform * @atomicservice * @since 20 + * @arkts 1.1&1.2 */ function startSyncTrace(level: HiTraceOutputLevel, name: string, customArgs?: string): void; @@ -396,6 +404,7 @@ declare namespace hiTraceMeter { * @crossplatform * @atomicservice * @since 20 + * @arkts 1.1&1.2 */ function finishSyncTrace(level: HiTraceOutputLevel): void; @@ -411,7 +420,7 @@ declare namespace hiTraceMeter { * @param { number } taskId The unique id used to distinguish the task and match with the id of the * corresponding finishAsyncTrace. * @param { string } customCategory Indicates the label to aggregate asynchronous task display. - * @param { string } customArgs Indicates key=value pair to be output in trace; multiple pairs should use comma + * @param { string } [customArgs] Indicates key=value pair to be output in trace; multiple pairs should use comma * as Separator. * @syscap SystemCapability.HiviewDFX.HiTrace * @atomicservice @@ -429,12 +438,13 @@ declare namespace hiTraceMeter { * @param { number } taskId The unique id used to distinguish the task and match with the id of the * corresponding finishAsyncTrace. * @param { string } customCategory Indicates the label to aggregate asynchronous task display. - * @param { string } customArgs Indicates key=value pair to be output in trace; multiple pairs should use comma + * @param { string } [customArgs] Indicates key=value pair to be output in trace; multiple pairs should use comma * as Separator. * @syscap SystemCapability.HiviewDFX.HiTrace * @crossplatform * @atomicservice * @since 20 + * @arkts 1.1&1.2 */ function startAsyncTrace(level: HiTraceOutputLevel, name: string, taskId: number, customCategory: string, customArgs?: string): void; @@ -469,6 +479,7 @@ declare namespace hiTraceMeter { * @crossplatform * @atomicservice * @since 20 + * @arkts 1.1&1.2 */ function finishAsyncTrace(level: HiTraceOutputLevel, name: string, taskId: number): void; @@ -492,6 +503,7 @@ declare namespace hiTraceMeter { * @crossplatform * @atomicservice * @since 20 + * @arkts 1.1&1.2 */ function traceByValue(level: HiTraceOutputLevel, name: string, count: number): void; @@ -511,9 +523,9 @@ declare namespace hiTraceMeter { * @crossplatform * @atomicservice * @since 20 + * @arkts 1.1&1.2 */ function isTraceEnabled(): boolean; - } export default hiTraceMeter; diff --git a/api/@ohos.i18n.d.ts b/api/@ohos.i18n.d.ts index 6b78d6c6d72aaa58e35acfcd4e7ed187715f06de..268888210f634b8fc6661759be4960fbe8de5899 100644 --- a/api/@ohos.i18n.d.ts +++ b/api/@ohos.i18n.d.ts @@ -508,34 +508,38 @@ declare namespace i18n { * * @permission ohos.permission.UPDATE_CONFIGURATION * @param { string } language - Valid ID of the language to be added as a preferred language. - * @param { number } [index] - Position to which the preferred language is added. The default value is the length + * @param { int } [index] - Position to which the preferred language is added. The default value is the length * of the preferred language list. * @throws { BusinessError } 201 - Permission verification failed. The application does not have the permission * required to call the API. + * @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; * 2.Incorrect parameter types. * @throws { BusinessError } 890001 - Invalid parameter. Possible causes: Parameter verification failed. + * @static * @syscap SystemCapability.Global.I18n * @systemapi Hide this for inner system use. * @since 9 */ - static addPreferredLanguage(language: string, index?: number): void; + static addPreferredLanguage(language: string, index?: int): void; /** * Removes a preferred language from the specified position on the preferred language list. * * @permission ohos.permission.UPDATE_CONFIGURATION - * @param { number } index - Position of the preferred language to delete. + * @param { int } index - Position of the preferred language to delete. * @throws { BusinessError } 201 - Permission verification failed. The application does not have the permission * required to call the API. + * @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; * 2.Incorrect parameter types. * @throws { BusinessError } 890001 - Invalid parameter. Possible causes: Parameter verification failed. + * @static * @syscap SystemCapability.Global.I18n * @systemapi Hide this for inner system use. * @since 9 */ - static removePreferredLanguage(index: number): void; + static removePreferredLanguage(index: int): void; /** * Access the system preferred language list. @@ -953,7 +957,7 @@ declare namespace i18n { /** * Enumerates the first day of a week. The value ranges from Monday to Sunday. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Global.I18n * @atomicservice * @since 18 @@ -1026,7 +1030,7 @@ declare namespace i18n { /** * Enumerates temperature units. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Global.I18n * @atomicservice * @since 18 @@ -1075,7 +1079,7 @@ declare namespace i18n { * * @param { UnitInfo } fromUnit - Measurement unit to be converted. * @param { UnitInfo } toUnit - Measurement unit to be converted to. - * @param { number } value - Value of the measurement unit to be converted. + * @param { double } value - Value of the measurement unit to be converted. * @param { string } locale - Locale ID used for formatting, for example, "zh-Hans-CN". * @param { string } [style] - Style used for formatting. The value can be "long", "short", or "narrow". The * default value is short. @@ -1085,7 +1089,7 @@ declare namespace i18n { * @deprecated since 9 * @useinstead ohos.i18n/i18n.I18NUtil#unitConvert */ - unitConvert(fromUnit: UnitInfo, toUnit: UnitInfo, value: number, locale: string, style?: string): string; + unitConvert(fromUnit: UnitInfo, toUnit: UnitInfo, value: double, locale: string, style?: string): string; } /** @@ -1115,7 +1119,7 @@ declare namespace i18n { * * @param { UnitInfo } fromUnit - Information of the unit to be converted. * @param { UnitInfo } toUnit - Information about the unit to be converted to. - * @param { number } value - Indicates the number to be formatted. + * @param { double } value - Indicates the number to be formatted. * @param { string } locale - The locale to be used. * @param { string } [style] - The style of format. * @returns { string } converted number and unit. @@ -1127,18 +1131,19 @@ declare namespace i18n { * * @param { UnitInfo } fromUnit - Measurement unit to be converted. * @param { UnitInfo } toUnit - Measurement unit to be converted to. - * @param { number } value - Value of the measurement unit to be converted. + * @param { double } value - Value of the measurement unit to be converted. * @param { string } locale - Locale ID, which consists of the language, script, and country/region, for example, * "zh-Hans-CN". * @param { string } [style] - Style used for formatting. The value can be long, short, or narrow. The default * value is short. For details about the meaning or display effect of different values, * see Number and Unit of Measurement Formatting. * @returns { string } String converted to the measurement unit after formatting. + * @static * @syscap SystemCapability.Global.I18n * @atomicservice * @since 12 */ - static unitConvert(fromUnit: UnitInfo, toUnit: UnitInfo, value: number, locale: string, style?: string): string; + static unitConvert(fromUnit: UnitInfo, toUnit: UnitInfo, value: double, locale: string, style?: string): string; /** * Get the order of year, month, day in the specified locale. Year, month, day are separated by '-'. @@ -1176,7 +1181,7 @@ declare namespace i18n { /** * Get the time period name for the specified hour. * - * @param { number } hour - the hour value. + * @param { int } hour - the hour value. * @param { string } [locale] - specified the locale. Use current app locale by default. It must be a valid locale. * @returns { string } the string of time period name. The return value may be empty string * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; 2.Incorrect parameter types. @@ -1187,18 +1192,19 @@ declare namespace i18n { /** * Obtains the localized expression of the specified time in the specified locale. * - * @param { number } hour - Specified time, for example, 16. + * @param { int } hour - Specified time, for example, 16. * @param { string } [locale] - System locale, which consists of the language, script, and country/region. for * example, "zh-Hans-CN". The default value is the current system locale. * @returns { string } Localized expression of the specified time in the specified locale. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; * 2.Incorrect parameter types. * @throws { BusinessError } 890001 - Invalid parameter. Possible causes: Parameter verification failed. + * @static * @syscap SystemCapability.Global.I18n * @atomicservice * @since 12 */ - static getTimePeriodName(hour:number, locale?: string): string; + static getTimePeriodName(hour:int, locale?: string): string; /** * Obtains the locale that best matches a region from the specified locale list. @@ -1628,14 +1634,14 @@ declare namespace i18n { /** * set the time. * - * @param { number } time - Indicates the elapsed milliseconds from 1970.1.1 00:00:00 GMT. + * @param { double } time - Indicates the elapsed milliseconds from 1970.1.1 00:00:00 GMT. * @syscap SystemCapability.Global.I18n * @since 8 */ /** * set the time. * - * @param { number } time - Indicates the elapsed milliseconds from 1970.1.1 00:00:00 GMT. + * @param { double } time - Indicates the elapsed milliseconds from 1970.1.1 00:00:00 GMT. * @syscap SystemCapability.Global.I18n * @crossplatform * @since 10 @@ -1643,36 +1649,36 @@ declare namespace i18n { /** * Sets the date and time for a Calendar object. * - * @param { number } time - Unix timestamp, which indicates the number of milliseconds that have elapsed since the + * @param { double } time - Unix timestamp, which indicates the number of milliseconds that have elapsed since the * Unix epoch. * @syscap SystemCapability.Global.I18n * @crossplatform * @atomicservice * @since 12 */ - setTime(time: number): void; + setTime(time: double): void; /** * Set the time * - * @param { number } year - The year field of the calendar, ranges from 0 to 9999. - * @param { number } month - The month field of the calendar, ranges from 0 to 11. - * @param { number } date - The day field of the calendar, ranges from 1 to 31. - * @param { number } hour - The hour field of the calendar, ranges from 0 to 23. - * @param { number } minute - The minute field of the calendar, ranges from 0 to 59. - * @param { number } second - the second field of the calendar, ranges from 0 to 59. + * @param { int } year - The year field of the calendar, ranges from 0 to 9999. + * @param { int } month - The month field of the calendar, ranges from 0 to 11. + * @param { int } date - The day field of the calendar, ranges from 1 to 31. + * @param { int } hour - The hour field of the calendar, ranges from 0 to 23. + * @param { int } minute - The minute field of the calendar, ranges from 0 to 59. + * @param { int } second - the second field of the calendar, ranges from 0 to 59. * @syscap SystemCapability.Global.I18n * @since 8 */ /** * Set the time * - * @param { number } year - The year field of the calendar, ranges from 0 to 9999. - * @param { number } month - The month field of the calendar, ranges from 0 to 11. - * @param { number } date - The day field of the calendar, ranges from 1 to 31. - * @param { number } hour - The hour field of the calendar, ranges from 0 to 23. - * @param { number } minute - The minute field of the calendar, ranges from 0 to 59. - * @param { number } second - the second field of the calendar, ranges from 0 to 59. + * @param { int } year - The year field of the calendar, ranges from 0 to 9999. + * @param { int } month - The month field of the calendar, ranges from 0 to 11. + * @param { int } date - The day field of the calendar, ranges from 1 to 31. + * @param { int } hour - The hour field of the calendar, ranges from 0 to 23. + * @param { int } minute - The minute field of the calendar, ranges from 0 to 59. + * @param { int } second - the second field of the calendar, ranges from 0 to 59. * @syscap SystemCapability.Global.I18n * @crossplatform * @since 10 @@ -1680,18 +1686,18 @@ declare namespace i18n { /** * Sets the year, month, day, hour, minute, and second for this Calendar object. * - * @param { number } year - Year to set. - * @param { number } month - Month to set. Note: The month starts from 0. For example, 0 indicates January. - * @param { number } date - Day to set. - * @param { number } hour - Hour to set. The default value is the current system time. - * @param { number } minute - Minute to set. The default value is the current system time. - * @param { number } second - Second to set. The default value is the current system time. + * @param { int } year - Year to set. + * @param { int } month - Month to set. Note: The month starts from 0. For example, 0 indicates January. + * @param { int } date - Day to set. + * @param { int } hour - Hour to set. The default value is the current system time. + * @param { int } minute - Minute to set. The default value is the current system time. + * @param { int } second - Second to set. The default value is the current system time. * @syscap SystemCapability.Global.I18n * @crossplatform * @atomicservice * @since 12 */ - set(year: number, month: number, date: number, hour?: number, minute?: number, second?: number): void; + set(year: int, month: int, date: int, hour?: int, minute?: int, second?: int): void; /** * Set the timezone of this calendar. @@ -1749,14 +1755,14 @@ declare namespace i18n { /** * Get the start day of a week. 1 indicates Sunday, 7 indicates Saturday. * - * @returns { number } start day of a week. + * @returns { int } start day of a week. * @syscap SystemCapability.Global.I18n * @since 8 */ /** * Get the start day of a week. 1 indicates Sunday, 7 indicates Saturday. * - * @returns { number } start day of a week. + * @returns { int } start day of a week. * @syscap SystemCapability.Global.I18n * @crossplatform * @since 10 @@ -1764,25 +1770,25 @@ declare namespace i18n { /** * Obtains the first day of a week for this Calendar object. * - * @returns { number } First day of a week. The value 1 indicates Sunday, and the value 7 indicates Saturday. + * @returns { int } First day of a week. The value 1 indicates Sunday, and the value 7 indicates Saturday. * @syscap SystemCapability.Global.I18n * @crossplatform * @atomicservice * @since 12 */ - getFirstDayOfWeek(): number; + getFirstDayOfWeek(): int; /** * Set the start day of a week. 1 indicates Sunday, 7 indicates Saturday. * - * @param { number } value - Indicates the start day of a week. 1 indicates Sunday, 7 indicates Saturday. + * @param { int } value - Indicates the start day of a week. 1 indicates Sunday, 7 indicates Saturday. * @syscap SystemCapability.Global.I18n * @since 8 */ /** * Set the start day of a week. 1 indicates Sunday, 7 indicates Saturday. * - * @param { number } value - Indicates the start day of a week. 1 indicates Sunday, 7 indicates Saturday. + * @param { int } value - Indicates the start day of a week. 1 indicates Sunday, 7 indicates Saturday. * @syscap SystemCapability.Global.I18n * @crossplatform * @since 10 @@ -1790,25 +1796,25 @@ declare namespace i18n { /** * Sets the first day of a week for this Calendar object. * - * @param { number } value - Start day of a week. The value 1 indicates Sunday, and the value 7 indicates Saturday. + * @param { int } value - Start day of a week. The value 1 indicates Sunday, and the value 7 indicates Saturday. * @syscap SystemCapability.Global.I18n * @crossplatform * @atomicservice * @since 12 */ - setFirstDayOfWeek(value: number): void; + setFirstDayOfWeek(value: int): void; /** * Get the minimal days of a week, which is needed for the first day of a year. * - * @returns { number } the minimal days of a week. + * @returns { int } the minimal days of a week. * @syscap SystemCapability.Global.I18n * @since 8 */ /** * Get the minimal days of a week, which is needed for the first day of a year. * - * @returns { number } the minimal days of a week. + * @returns { int } the minimal days of a week. * @syscap SystemCapability.Global.I18n * @crossplatform * @since 10 @@ -1816,25 +1822,25 @@ declare namespace i18n { /** * Obtains the minimum number of days in the first week for this Calendar object. * - * @returns { number } Minimum number of days in the first week of a year. + * @returns { int } Minimum number of days in the first week of a year. * @syscap SystemCapability.Global.I18n * @crossplatform * @atomicservice * @since 12 */ - getMinimalDaysInFirstWeek(): number; + getMinimalDaysInFirstWeek(): int; /** * Set the minimal days of a week, which is needed for the first week of a year. * - * @param { number } value - The value to be set. + * @param { int } value - The value to be set. * @syscap SystemCapability.Global.I18n * @since 8 */ /** * Set the minimal days of a week, which is needed for the first week of a year. * - * @param { number } value - The value to be set. + * @param { int } value - The value to be set. * @syscap SystemCapability.Global.I18n * @crossplatform * @since 10 @@ -1842,13 +1848,13 @@ declare namespace i18n { /** * Sets the minimum number of days in the first week for this Calendar object. * - * @param { number } value - Minimum number of days in the first week of a year. + * @param { int } value - Minimum number of days in the first week of a year. * @syscap SystemCapability.Global.I18n * @crossplatform * @atomicservice * @since 12 */ - setMinimalDaysInFirstWeek(value: number): void; + setMinimalDaysInFirstWeek(value: int): void; /** * Get the associated value with the field. @@ -1856,7 +1862,7 @@ declare namespace i18n { * @param { string } field - Field values such as era, year, month, week_of_year, week_of_month, date, day_of_year, day_of_week * day_of_week_in_month, hour, hour_of_day, minute, second, millisecond, zone_offset, dst_offset, year_woy, * dow_local, extended_year, julian_day, milliseconds_in_day, is_leap_month. - * @returns { number } the associated value. + * @returns { int } the associated value. * @syscap SystemCapability.Global.I18n * @since 8 */ @@ -1866,7 +1872,7 @@ declare namespace i18n { * @param { string } field - Field values such as era, year, month, week_of_year, week_of_month, date, day_of_year, day_of_week * day_of_week_in_month, hour, hour_of_day, minute, second, millisecond, zone_offset, dst_offset, year_woy, * dow_local, extended_year, julian_day, milliseconds_in_day, is_leap_month. - * @returns { number } the associated value. + * @returns { int } the associated value. * @syscap SystemCapability.Global.I18n * @crossplatform * @since 10 @@ -1875,7 +1881,7 @@ declare namespace i18n { * Obtains the values of the calendar attributes in this Calendar object. * * @param { string } field - Calendar attributes. The following table lists the supported attribute values. - * @returns { number } Value of the calendar attribute. For example, if the year of the internal date of the + * @returns { int } Value of the calendar attribute. For example, if the year of the internal date of the * current Calendar object is 1990, get('year') returns 1990. * @syscap SystemCapability.Global.I18n * @crossplatform @@ -1883,7 +1889,7 @@ declare namespace i18n { * @since arkts {'1.1':'12', '1.2':'20'} * @arkts 1.1&1.2 */ - get(field: string): number; + get(field: string): int; /** * Get calendar's name localized for display in the given locale. @@ -1943,7 +1949,7 @@ declare namespace i18n { * * @param { string } field - field values such as year, month, week_of_year, week_of_month, date, day_of_year, day_of_week * day_of_week_in_month, hour, hour_of_day, minute, second, millisecond - * @param { number } amount - the amount of date or time to be added to the field. + * @param { int } amount - the amount of date or time to be added to the field. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; 2.Incorrect parameter types. * @throws { BusinessError } 890001 - Invalid parameter. Possible causes: Parameter verification failed. * @syscap SystemCapability.Global.I18n @@ -1956,7 +1962,7 @@ declare namespace i18n { * @param { string } field - Calendar attribute. The value can be any of the following: year, month, week_of_year, * week_of_month, date, day_of_year, day_of_week, day_of_week_in_month, hour, * hour_of_day, minute, second, millisecond. For details about the values, see get. - * @param { number } amount - Addition or subtraction amount. + * @param { int } amount - Addition or subtraction amount. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; * 2.Incorrect parameter types. * @throws { BusinessError } 890001 - Invalid parameter. Possible causes: Parameter verification failed. @@ -1965,12 +1971,12 @@ declare namespace i18n { * @atomicservice * @since 12 */ - add(field: string, amount: number): void; + add(field: string, amount: int): void; /** * Get the UTC milliseconds. * - * @returns { number } the calendar time as UTC milliseconds. + * @returns { long } the calendar time as UTC milliseconds. * @syscap SystemCapability.Global.I18n * @crossplatform * @since 11 @@ -1978,20 +1984,20 @@ declare namespace i18n { /** * Obtains the timestamp of this Calendar object. * - * @returns { number } Unix timestamp, which indicates the number of milliseconds that have elapsed since the + * @returns { long } Unix timestamp, which indicates the number of milliseconds that have elapsed since the * Unix epoch. * @syscap SystemCapability.Global.I18n * @crossplatform * @atomicservice * @since 12 */ - getTimeInMillis(): number; + getTimeInMillis(): long; /** * Returns days comparison result. * * @param { Date } date - Date object to be compared. - * @returns { number } value of of the comparison result. A positive value indicates that the date is later, + * @returns { int } value of of the comparison result. A positive value indicates that the date is later, * and a negative value indicates that the date is earlier. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; 2.Incorrect parameter types. * @syscap SystemCapability.Global.I18n @@ -2003,7 +2009,7 @@ declare namespace i18n { * days. * * @param { Date } date - Date and time. Note: The month starts from 0. For example, 0 indicates January. - * @returns { number } Difference in the number of days. A positive number indicates that the calendar date is + * @returns { int } Difference in the number of days. A positive number indicates that the calendar date is * earlier, and a negative number indicates the opposite. The value is accurate to * milliseconds. If the value is less than one day, it is considered as one day. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; @@ -2013,7 +2019,7 @@ declare namespace i18n { * @atomicservice * @since 12 */ - compareDays(date: Date): number; + compareDays(date: Date): int; } /** @@ -2085,43 +2091,43 @@ declare namespace i18n { /** * Obtains the current position of the BreakIterator instance. * - * @returns { number } the current position of the BreakIterator instance. + * @returns { int } the current position of the BreakIterator instance. * @syscap SystemCapability.Global.I18n * @since 8 */ /** * Obtains the position of the break iterator in the text. * - * @returns { number } Position of the break iterator in the text. + * @returns { int } Position of the break iterator in the text. * @syscap SystemCapability.Global.I18n * @atomicservice * @since 12 */ - current(): number; + current(): int; /** * Set the BreakIterator's position to the first break point, the first break point is always the beginning of the * processed text. * - * @returns { number } the index of the first break point. + * @returns { int } the index of the first break point. * @syscap SystemCapability.Global.I18n * @since 8 */ /** * Moves the break iterator to the first line break point, which is always at the beginning of the processed text. * - * @returns { number } Offset of the first line break point in the processed text. + * @returns { int } Offset of the first line break point in the processed text. * @syscap SystemCapability.Global.I18n * @atomicservice * @since 12 */ - first(): number; + first(): int; /** * Set the BreakIterator's position to the last break point. the last break point is always the index beyond the * last character of the processed text. * - * @returns { number } the index of the last break point. + * @returns { int } the index of the last break point. * @syscap SystemCapability.Global.I18n * @since 8 */ @@ -2129,52 +2135,52 @@ declare namespace i18n { * Moves the break iterator to the last line break point, which is always the next position after the end of the * processed text. * - * @returns { number } Offset of the last line break point in the processed text. + * @returns { int } Offset of the last line break point in the processed text. * @syscap SystemCapability.Global.I18n * @atomicservice * @since 12 */ - last(): number; + last(): int; /** * Set the BreakIterator's position to the nth break point from the current break point. * - * @param { number } [index] - indicates the number of break points to advance. If index is not given, n is treated as 1. - * @returns { number } the index of the BreakIterator after moving. If there is not enough break points, returns -1. + * @param { int } [index] - indicates the number of break points to advance. If index is not given, n is treated as 1. + * @returns { int } the index of the BreakIterator after moving. If there is not enough break points, returns -1. * @syscap SystemCapability.Global.I18n * @since 8 */ /** * Moves the break iterator backward by the specified number of line break points. * - * @param { number } [index] - Number of line break points for moving the break iterator. The value is an integer. + * @param { int } [index] - Number of line break points for moving the break iterator. The value is an integer. * A positive number means to move the break iterator backward, and a negative number * means to move the break iterator forward. The default value is 1. - * @returns { number } Position of the break iterator in the text after movement. The value -1 is returned if the + * @returns { int } Position of the break iterator in the text after movement. The value -1 is returned if the * position of the break iterator is outside of the processed text after movement. * @syscap SystemCapability.Global.I18n * @atomicservice * @since 12 */ - next(index?: number): number; + next(index?: int): int; /** * Set the BreakIterator's position to the break point preceding the current break point. * - * @returns { number } the index of the BreakIterator after moving. If there is not enough break points, returns -1. + * @returns { int } the index of the BreakIterator after moving. If there is not enough break points, returns -1. * @syscap SystemCapability.Global.I18n * @since 8 */ /** * Moves the break iterator foreward by one line break point. * - * @returns { number } Position of the break iterator in the text after movement. The value -1 is returned if the + * @returns { int } Position of the break iterator in the text after movement. The value -1 is returned if the * position of the break iterator is outside of the processed text after movement. * @syscap SystemCapability.Global.I18n * @atomicservice * @since 12 */ - previous(): number; + previous(): int; /** * Set the text to be processed. @@ -2196,22 +2202,22 @@ declare namespace i18n { /** * Set the BreakIterator's position to the first break point following the specified offset. * - * @param { number } offset - * @returns { number } the index of the BreakIterator after moving. If there is not enough break points, returns -1. + * @param { int } offset + * @returns { int } the index of the BreakIterator after moving. If there is not enough break points, returns -1. * @syscap SystemCapability.Global.I18n * @since 8 */ /** * Moves the line break iterator to the line break point after the specified position. * - * @param { number } offset - Offset of the line break point. - * @returns { number } Position of the break iterator in the text after movement. The value -1 is returned if the + * @param { int } offset - Offset of the line break point. + * @returns { int } Position of the break iterator in the text after movement. The value -1 is returned if the * position of the break iterator is outside of the processed text after movement. * @syscap SystemCapability.Global.I18n * @atomicservice * @since 12 */ - following(offset: number): number; + following(offset: int): int; /** * Obtains the text being processed. @@ -2235,7 +2241,7 @@ declare namespace i18n { * position will be set to the position indicated by the offset if it returns true, otherwise the BreakIterator * will be moved to the break point following the offset. * - * @param { number } offset The offset to be checked. + * @param { int } offset The offset to be checked. * @returns { boolean } true if the offset is a break point. * @syscap SystemCapability.Global.I18n * @since 8 @@ -2243,7 +2249,7 @@ declare namespace i18n { /** * Checks whether the specified position is a line break point. * - * @param { number } offset - Specified position in the text. + * @param { int } offset - Specified position in the text. * @returns { boolean } Whether the specified position is a line break point. The value "true" indicates that the * specified position is a line break point, and the value "false" indicates the opposite. * If true is returned, the break iterator is moved to the position specified by offset. @@ -2253,7 +2259,7 @@ declare namespace i18n { * @atomicservice * @since 12 */ - isBoundary(offset: number): boolean; + isBoundary(offset: int): boolean; } /** @@ -2800,7 +2806,7 @@ declare namespace i18n { * * @permission ohos.permission.UPDATE_CONFIGURATION * @param { string } language - Preferred language to add. - * @param { number } [index] - Position to which the preferred language is added. The default value is the length of + * @param { int } [index] - Position to which the preferred language is added. The default value is the length of * the preferred language list. * @returns { boolean } true if the operation is successful, and false otherwise. * @syscap SystemCapability.Global.I18n @@ -2808,13 +2814,13 @@ declare namespace i18n { * @deprecated since 9 * @useinstead ohos.i18n/i18n.System#addPreferredLanguage */ - export function addPreferredLanguage(language: string, index?: number): boolean; + export function addPreferredLanguage(language: string, index?: int): boolean; /** * Removes a preferred language from the specified position on the preferred language list. * * @permission ohos.permission.UPDATE_CONFIGURATION - * @param { number } index - Position of the preferred language to delete. + * @param { int } index - Position of the preferred language to delete. * @returns { boolean } Whether the operation is successful. The value "true" indicates that the operation is * successful, and the value "false" indicates the opposite. * @syscap SystemCapability.Global.I18n @@ -2822,7 +2828,7 @@ declare namespace i18n { * @deprecated since 9 * @useinstead ohos.i18n/i18n.System#removePreferredLanguage */ - export function removePreferredLanguage(index: number): boolean; + export function removePreferredLanguage(index: int): boolean; /** * Obtains the list of preferred languages. @@ -2952,14 +2958,14 @@ declare namespace i18n { /** * Get the raw offset of the TimeZone object. * - * @returns { number } a number represents the raw offset. + * @returns { int } a number represents the raw offset. * @syscap SystemCapability.Global.I18n * @since 7 */ /** * Get the raw offset of the TimeZone object. * - * @returns { number } a number represents the raw offset. + * @returns { int } a number represents the raw offset. * @syscap SystemCapability.Global.I18n * @crossplatform * @since 10 @@ -2967,27 +2973,27 @@ declare namespace i18n { /** * Obtains the raw offset of the specified time zone. * - * @returns { number } Raw offset of the time zone, in milliseconds. + * @returns { int } Raw offset of the time zone, in milliseconds. * @syscap SystemCapability.Global.I18n * @crossplatform * @atomicservice * @since 12 */ - getRawOffset(): number; + getRawOffset(): int; /** * Get the offset of the TimeZone object. * - * @param { number } [date] - Indicates a date use to compute offset. - * @returns { number } a number represents the offset with date. + * @param { double } [date] - Indicates a date use to compute offset. + * @returns { int } a number represents the offset with date. * @syscap SystemCapability.Global.I18n * @since 7 */ /** * Get the offset of the TimeZone object. * - * @param { number } [date] - Indicates a date use to compute offset. - * @returns { number } a number represents the offset with date. + * @param { double } [date] - Indicates a date use to compute offset. + * @returns { int } a number represents the offset with date. * @syscap SystemCapability.Global.I18n * @crossplatform * @since 10 @@ -2995,15 +3001,15 @@ declare namespace i18n { /** * Obtains the offset of the specified time zone at the specified time. * - * @param { number } [date] - Specified time, in milliseconds. The default value is the system time. - * @returns { number } Time zone offset, in milliseconds. When the DST is used, the time zone offset + * @param { double } [date] - Specified time, in milliseconds. The default value is the system time. + * @returns { int } Time zone offset, in milliseconds. When the DST is used, the time zone offset * is the raw time zone offset plus the DST offset. * @syscap SystemCapability.Global.I18n * @crossplatform * @atomicservice * @since 12 */ - getOffset(date?: number): number; + getOffset(date?: double): int; /** * Get available TimeZone ID list. @@ -3091,8 +3097,8 @@ declare namespace i18n { /** * Get the possible time zones from the specified longitude and latitude. * - * @param { number } longitude value - * @param { number } latitude value + * @param { double } longitude value + * @param { double } latitude value * @returns { Array } Returns a TimeZone array from the specified longitude and latitude. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; 2.Incorrect parameter types. * @throws { BusinessError } 890001 - Invalid parameter. Possible causes: Parameter verification failed. @@ -3103,19 +3109,20 @@ declare namespace i18n { /** * Creates an array of TimeZone objects corresponding to the specified location. * - * @param { number } longitude - Longitude. The value range is [-180, 179.9). A positive value is used for east + * @param { double } longitude - Longitude. The value range is [-180, 179.9). A positive value is used for east * longitude and a negative value is used for west longitude. - * @param { number } latitude - Latitude. The value range is [-90, 89.9). A positive value is used for north + * @param { double } latitude - Latitude. The value range is [-90, 89.9). A positive value is used for north * latitude and a negative value is used for south latitude. * @returns { Array } TimeZone objects corresponding to the specified location. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; * 2.Incorrect parameter types. * @throws { BusinessError } 890001 - Invalid parameter. Possible causes: Parameter verification failed. + * @static * @syscap SystemCapability.Global.I18n * @atomicservice * @since 12 */ - static getTimezonesByLocation(longitude: number, latitude: number): Array; + static getTimezonesByLocation(longitude: double, latitude: double): Array; /** * Get the zone rules object corresponds to the timezone objects. @@ -3139,13 +3146,13 @@ declare namespace i18n { /** * Get the next timezone offset transition after date. * - * @param { number } [ date ] - Indicates milliseconds. + * @param { double } [ date ] - Indicates milliseconds. * @returns { ZoneOffsetTransition } Returns a timezone offset transition after date. * @syscap SystemCapability.Global.I18n * @atomicservice * @since 20 */ - public nextTransition(date?: number): ZoneOffsetTransition; + public nextTransition(date?: double): ZoneOffsetTransition; } /** @@ -3159,32 +3166,32 @@ declare namespace i18n { /** * Obtains the timestamp of the change in the time zone offset. * - * @returns { number } Timestamp of the change in the time zone offset. + * @returns { double } Timestamp of the change in the time zone offset. * @syscap SystemCapability.Global.I18n * @atomicservice * @since 20 */ - public getMilliseconds(): number; + public getMilliseconds(): double; /** * Get the offset after time zone offset trasition. * - * @returns { number } Returns the offset after time zone offset trasition. + * @returns { int } Returns the offset after time zone offset trasition. * @syscap SystemCapability.Global.I18n * @atomicservice * @since 20 */ - public getOffsetAfter(): number; + public getOffsetAfter(): int; /** * Get the offset before time zone offset trasition. * - * @returns { number } Returns the offset before time zone offset trasition. + * @returns { int } Returns the offset before time zone offset trasition. * @syscap SystemCapability.Global.I18n * @atomicservice * @since 20 */ - public getOffsetBefore(): number; + public getOffsetBefore(): int; } /** @@ -3262,14 +3269,14 @@ declare namespace i18n { /** * Enumerates the Normalizer modes. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Global.I18n * @since 10 */ /** * Enumerates text normalization modes. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Global.I18n * @atomicservice * @since 12 @@ -3395,7 +3402,7 @@ declare namespace i18n { /** * Represents the language or country/region suggestion type. * - * @enum { number } + * @enum { int } * @syscap SystemCapability.Global.I18n * @systemapi Hide this for inner system use. * @since 10 @@ -3563,12 +3570,12 @@ declare namespace i18n { /** * Offset of the time zone ID. * - * @type { number } + * @type { int } * @syscap SystemCapability.Global.I18n * @systemapi Hide this for inner system use. * @since 10 */ - offset: number; + offset: int; /** * Time zone display name in the system locale. @@ -3583,12 +3590,12 @@ declare namespace i18n { /** * Fixed offset of the time zone ID. * - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Global.I18n * @systemapi Hide this for inner system use. * @since 10 */ - rawOffset?: number; + rawOffset?: int; } /** @@ -3721,53 +3728,53 @@ declare namespace i18n { /** * Holiday start year. * - * @type { number } + * @type { int } * @syscap SystemCapability.Global.I18n * @since 11 */ /** * Year of the holiday. * - * @type { number } + * @type { int } * @syscap SystemCapability.Global.I18n * @atomicservice * @since 12 */ - year: number; + year: int; /** * Holiday start month. * - * @type { number } + * @type { int } * @syscap SystemCapability.Global.I18n * @since 11 */ /** * Month of the holiday. * - * @type { number } + * @type { int } * @syscap SystemCapability.Global.I18n * @atomicservice * @since 12 */ - month: number; + month: int; /** * Holiday start day. * - * @type { number } + * @type { int } * @syscap SystemCapability.Global.I18n * @since 11 */ /** * Day of the holiday. * - * @type { number } + * @type { int } * @syscap SystemCapability.Global.I18n * @atomicservice * @since 12 */ - day: number; + day: int; /** * Holiday local name array. @@ -3901,7 +3908,7 @@ declare namespace i18n { /** * Obtains holiday info array for a specified year * - * @param { number } [year] - specified holiday year. If the year is not given, + * @param { int } [year] - specified holiday year. If the year is not given, * the current year is used. * @returns { Array } holiday information array for one year. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; 2.Incorrect parameter types. @@ -3912,7 +3919,7 @@ declare namespace i18n { /** * Obtains the holiday information list of the specified year. * - * @param { number } [year] - Specified year, for example, 2023.
The default value is the current year. + * @param { int } [year] - Specified year, for example, 2023.
The default value is the current year. * @returns { Array } Holiday information list. * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified; * 2.Incorrect parameter types. @@ -3921,7 +3928,7 @@ declare namespace i18n { * @atomicservice * @since 12 */ - getHolidayInfoItemArray(year?: number): Array; + getHolidayInfoItemArray(year?: int): Array; } /** @@ -3943,36 +3950,36 @@ declare namespace i18n { /** * Entity begin position. * - * @type { number } + * @type { int } * @syscap SystemCapability.Global.I18n * @since 11 */ /** * Start position of the entity in the input string. * - * @type { number } + * @type { int } * @syscap SystemCapability.Global.I18n * @atomicservice * @since 12 */ - begin: number; + begin: int; /** * Entity end position. * - * @type { number } + * @type { int } * @syscap SystemCapability.Global.I18n * @since 11 */ /** * End position of the entity the input string. * - * @type { number } + * @type { int } * @syscap SystemCapability.Global.I18n * @atomicservice * @since 12 */ - end: number; + end: int; /** * Entity type. Field values such as phone_number, date @@ -4180,13 +4187,13 @@ declare namespace i18n { /** * Formats a number. * - * @param { number } value - Number to be formatted. + * @param { double } value - Number to be formatted. * @returns { string } Formatted number. * @syscap SystemCapability.Global.I18n * @atomicservice * @since 18 */ - format(value: number): string; + format(value: double): string; } /** @@ -4225,13 +4232,13 @@ declare namespace i18n { /** * Formats a number as a rich text object. * - * @param { number } value - Number to be formatted. + * @param { double } value - Number to be formatted. * @returns { StyledString } Rich text object after formatting. * @syscap SystemCapability.Global.I18n * @atomicservice * @since 18 */ - format(value: number): StyledString; + format(value: double): StyledString; } /** diff --git a/api/@ohos.intl.d.ts b/api/@ohos.intl.d.ts index 445c96bea50d0b0c9bfd8a39e9dfc02f552a60e6..06133a40b540f3325d0a17001474aaa0160bf59c 100644 --- a/api/@ohos.intl.d.ts +++ b/api/@ohos.intl.d.ts @@ -2952,21 +2952,21 @@ declare namespace intl { /** * Indicates the minimumIntegerDigits. * - * @type { number } + * @type { int } * @syscap SystemCapability.Global.I18n * @since 6 */ /** * Indicates the minimumIntegerDigits. * - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Global.I18n * @since 9 */ /** * Indicates the minimumIntegerDigits. * - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Global.I18n * @crossplatform * @since 10 @@ -2975,35 +2975,35 @@ declare namespace intl { * Minimum number of digits allowed in the integer part of a number. The value ranges from 1 to 21. * The default value is 1. * - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Global.I18n * @crossplatform * @atomicservice * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 * @deprecated since 20 * @useinstead Intl.NumberOptions.minimumIntegerDigits + * @arkts 1.1&1.2 */ - minimumIntegerDigits?: number; + minimumIntegerDigits?: int; /** * Indicates the minimumFractionDigits. * - * @type { number } + * @type { int } * @syscap SystemCapability.Global.I18n * @since 6 */ /** * Indicates the minimumFractionDigits. * - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Global.I18n * @since 9 */ /** * Indicates the minimumFractionDigits. * - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Global.I18n * @crossplatform * @since 10 @@ -3012,35 +3012,35 @@ declare namespace intl { * Minimum number of digits in the fraction part of a number. The value ranges from 0 to 20. * The default value is 0. * - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Global.I18n * @crossplatform * @atomicservice * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 * @deprecated since 20 * @useinstead Intl.NumberOptions.minimumFractionDigits + * @arkts 1.1&1.2 */ - minimumFractionDigits?: number; + minimumFractionDigits?: int; /** * Indicates the maximumFractionDigits. * - * @type { number } + * @type { int } * @syscap SystemCapability.Global.I18n * @since 6 */ /** * Indicates the maximumFractionDigits. * - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Global.I18n * @since 9 */ /** * Indicates the maximumFractionDigits. * - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Global.I18n * @crossplatform * @since 10 @@ -3049,35 +3049,35 @@ declare namespace intl { * Maximum number of digits in the fraction part of a number. The value ranges from 1 to 21. * The default value is 3. * - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Global.I18n * @crossplatform - * @atomicservice - * @since arkts {'1.1':'12', '1.2':'20'} + * @atomicservices * @arkts 1.1&1.2 + * @since arkts {'1.1':'12', '1.2':'20'} * @deprecated since 20 * @useinstead Intl.NumberOptions.maximumFractionDigits */ - maximumFractionDigits?: number; + maximumFractionDigits?: int; /** * Indicates the minimumSignificantDigits. * - * @type { number } + * @type { int } * @syscap SystemCapability.Global.I18n * @since 6 */ /** * Indicates the minimumSignificantDigits. * - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Global.I18n * @since 9 */ /** * Indicates the minimumSignificantDigits. * - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Global.I18n * @crossplatform * @since 10 @@ -3085,35 +3085,35 @@ declare namespace intl { /** * Minimum number of the least significant digits. The value ranges from 1 to 21. The default value is 1. * - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Global.I18n * @crossplatform * @atomicservice * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 * @deprecated since 20 * @useinstead Intl.NumberOptions.minimumSignificantDigits + * @arkts 1.1&1.2 */ - minimumSignificantDigits?: number; + minimumSignificantDigits?: int; /** * Indicates the maximumSignificantDigits. * - * @type { number } + * @type { int } * @syscap SystemCapability.Global.I18n * @since 6 */ /** * Indicates the maximumSignificantDigits. * - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Global.I18n * @since 9 */ /** * Indicates the maximumSignificantDigits. * - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Global.I18n * @crossplatform * @since 10 @@ -3121,16 +3121,16 @@ declare namespace intl { /** * Maximum number of the least significant digits. The value ranges from 1 to 21. The default value is 21. * - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Global.I18n * @crossplatform * @atomicservice * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 * @deprecated since 20 * @useinstead Intl.NumberOptions.maximumSignificantDigits + * @arkts 1.1&1.2 */ - maximumSignificantDigits?: number; + maximumSignificantDigits?: int; /** * Rounding priority used when both the maximum number of fraction digits and the maximum number of valid digits @@ -3151,14 +3151,14 @@ declare namespace intl { * Rounding increment. The value can be: 1, 2, 5, 10, 20, 25, 50, 100, 200, 250, 500, 1000, 2000, 2500, or 5000. * The default value is 1. * - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Global.I18n * @atomicservice * @since 18 * @deprecated since 20 * @useinstead Intl.NumberOptions.roundingIncrement */ - roundingIncrement?: number; + roundingIncrement?: int; /** * Rounding mode. The value can be: @@ -3277,7 +3277,7 @@ declare namespace intl { /** * Obtains the formatted number string. * - * @param { number } number Indicates the number to be formatted. + * @param { double } number Indicates the number to be formatted. * @returns { string } a number string formatted based on the specified locale. * @syscap SystemCapability.Global.I18n * @since 6 @@ -3285,7 +3285,7 @@ declare namespace intl { /** * Obtains the formatted number string. * - * @param { number } number Indicates the number to be formatted. + * @param { double } number Indicates the number to be formatted. * @returns { string } a number string formatted based on the specified locale. * @syscap SystemCapability.Global.I18n * @crossplatform @@ -3294,23 +3294,23 @@ declare namespace intl { /** * Formats a number. * - * @param { number } number - Number to be formatted. + * @param { double } number - Number to be formatted. * @returns { string } Formatted number. * @syscap SystemCapability.Global.I18n * @crossplatform * @atomicservice * @since arkts {'1.1':'12', '1.2':'20'} - * @arkts 1.1&1.2 * @deprecated since 20 * @useinstead Intl.NumberFormat.format + * @arkts 1.1&1.2 */ - format(number: number): string; + format(number: double): string; /** * Formats a number range. * - * @param { number } startRange - Start number. - * @param { number } endRange - End number. + * @param { double } startRange - Start number. + * @param { double } endRange - End number. * @returns { string } Formatted number range. * @syscap SystemCapability.Global.I18n * @atomicservice @@ -3318,7 +3318,7 @@ declare namespace intl { * @deprecated since 20 * @useinstead Intl.NumberFormat.formatRange */ - formatRange(startRange: number, endRange: number): string; + formatRange(startRange: double, endRange: double): string; /** * Obtains the options of the NumberFormat object. @@ -3743,7 +3743,7 @@ declare namespace intl { * * @param { string } first - The first string to compare. * @param { string } second - The second string to compare. - * @returns { number } a number indicating how first compare to second: + * @returns { int } a number indicating how first compare to second: * a negative value if string1 comes before string2; * a positive value if string1 comes after string2; * 0 if they are considered equal. @@ -3755,7 +3755,7 @@ declare namespace intl { * * @param { string } first - The first string to compare. * @param { string } second - The second string to compare. - * @returns { number } a number indicating how first compare to second: + * @returns { int } a number indicating how first compare to second: * a negative value if string1 comes before string2; * a positive value if string1 comes after string2; * 0 if they are considered equal. @@ -3768,7 +3768,7 @@ declare namespace intl { * * @param { string } first - First string to compare. * @param { string } second - Second string to compare. - * @returns { number } Comparison result. If the value is a negative number, the first string comes before the + * @returns { int } Comparison result. If the value is a negative number, the first string comes before the * second string. If the value is 0, the first and second strings are in the same sequence. * If the value is a positive number, the first string is comes after the second string. * @syscap SystemCapability.Global.I18n @@ -3778,7 +3778,7 @@ declare namespace intl { * @deprecated since 20 * @useinstead Intl.Collator.compare */ - compare(first: string, second: string): number; + compare(first: string, second: string): int; /** * Returns a new object with properties that reflect the locale and collation options computed @@ -3914,7 +3914,7 @@ declare namespace intl { * The minimum number of integer digits to use. * Possible values are from 1 to 21; the default is 1. * - * @type { number } + * @type { int } * @syscap SystemCapability.Global.I18n * @since 8 */ @@ -3922,7 +3922,7 @@ declare namespace intl { * The minimum number of integer digits to use. * Possible values are from 1 to 21; the default is 1. * - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Global.I18n * @since 9 */ @@ -3930,7 +3930,7 @@ declare namespace intl { * The minimum number of integer digits to use. * Possible values are from 1 to 21; the default is 1. * - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Global.I18n * @crossplatform * @since 10 @@ -3939,7 +3939,7 @@ declare namespace intl { * Minimum number of digits allowed in the integer part of a number. The value ranges from 1 to 21. * The default value is 1. * - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Global.I18n * @crossplatform * @atomicservice @@ -3947,13 +3947,13 @@ declare namespace intl { * @deprecated since 20 * @useinstead Intl.PluralRulesOptions.minimumIntegerDigits */ - minimumIntegerDigits?: number; + minimumIntegerDigits?: int; /** * The minimum number of fraction digits to use. * Possible values are from 0 to 20; the default for plain number and percent formatting is 0; * - * @type { number } + * @type { int } * @syscap SystemCapability.Global.I18n * @since 8 */ @@ -3961,7 +3961,7 @@ declare namespace intl { * The minimum number of fraction digits to use. * Possible values are from 0 to 20; the default for plain number and percent formatting is 0; * - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Global.I18n * @since 9 */ @@ -3969,7 +3969,7 @@ declare namespace intl { * The minimum number of fraction digits to use. * Possible values are from 0 to 20; the default for plain number and percent formatting is 0; * - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Global.I18n * @crossplatform * @since 10 @@ -3978,7 +3978,7 @@ declare namespace intl { * Minimum number of digits in the fraction part of a number. The value ranges from 0 to 20. * The default value is 0. * - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Global.I18n * @crossplatform * @atomicservice @@ -3986,14 +3986,14 @@ declare namespace intl { * @deprecated since 20 * @useinstead Intl.PluralRulesOptions.minimumFractionDigits */ - minimumFractionDigits?: number; + minimumFractionDigits?: int; /** * The maximum number of fraction digits to use. * Possible values are from 0 to 20; * the default for plain number formatting is the larger of minimumFractionDigits and 3; * - * @type { number } + * @type { int } * @syscap SystemCapability.Global.I18n * @since 8 */ @@ -4002,7 +4002,7 @@ declare namespace intl { * Possible values are from 0 to 20; * the default for plain number formatting is the larger of minimumFractionDigits and 3; * - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Global.I18n * @since 9 */ @@ -4011,7 +4011,7 @@ declare namespace intl { * Possible values are from 0 to 20; * the default for plain number formatting is the larger of minimumFractionDigits and 3; * - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Global.I18n * @crossplatform * @since 10 @@ -4020,7 +4020,7 @@ declare namespace intl { * Maximum number of digits in the fraction part of a number. The value ranges from 1 to 21. * The default value is 3. * - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Global.I18n * @crossplatform * @atomicservice @@ -4028,13 +4028,13 @@ declare namespace intl { * @deprecated since 20 * @useinstead Intl.PluralRulesOptions.maximumFractionDigits */ - maximumFractionDigits?: number; + maximumFractionDigits?: int; /** * The minimum number of significant digits to use. * Possible values are from 1 to 21; the default is 1. * - * @type { number } + * @type { int } * @syscap SystemCapability.Global.I18n * @since 8 */ @@ -4042,7 +4042,7 @@ declare namespace intl { * The minimum number of significant digits to use. * Possible values are from 1 to 21; the default is 1. * - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Global.I18n * @since 9 */ @@ -4050,7 +4050,7 @@ declare namespace intl { * The minimum number of significant digits to use. * Possible values are from 1 to 21; the default is 1. * - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Global.I18n * @crossplatform * @since 10 @@ -4058,7 +4058,7 @@ declare namespace intl { /** * Minimum number of the least significant digits. The value ranges from 1 to 21. The default value is 1. * - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Global.I18n * @crossplatform * @atomicservice @@ -4066,13 +4066,13 @@ declare namespace intl { * @deprecated since 20 * @useinstead Intl.PluralRulesOptions.minimumSignificantDigits */ - minimumSignificantDigits?: number; + minimumSignificantDigits?: int; /** * The maximum number of significant digits to use. * Possible values are from 1 to 21; the default is 21. * - * @type { number } + * @type { int } * @syscap SystemCapability.Global.I18n * @since 8 */ @@ -4080,7 +4080,7 @@ declare namespace intl { * The maximum number of significant digits to use. * Possible values are from 1 to 21; the default is 21. * - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Global.I18n * @since 9 */ @@ -4088,7 +4088,7 @@ declare namespace intl { * The maximum number of significant digits to use. * Possible values are from 1 to 21; the default is 21. * - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Global.I18n * @crossplatform * @since 10 @@ -4096,7 +4096,7 @@ declare namespace intl { /** * Maximum number of the least significant digits. The value ranges from 1 to 21. The default value is 21. * - * @type { ?number } + * @type { ?int } * @syscap SystemCapability.Global.I18n * @crossplatform * @atomicservice @@ -4104,7 +4104,7 @@ declare namespace intl { * @deprecated since 20 * @useinstead Intl.PluralRulesOptions.maximumSignificantDigits */ - maximumSignificantDigits?: number; + maximumSignificantDigits?: int; } /** @@ -4191,7 +4191,7 @@ declare namespace intl { /** * Returns a string indicating which plural rule to use for locale-aware formatting. * - * @param { number } n - The number to get a plural rule for. + * @param { double } n - The number to get a plural rule for. * @returns { string } A string representing the pluralization category of the number, * can be one of zero, one, two, few, many or other. * @syscap SystemCapability.Global.I18n @@ -4200,7 +4200,7 @@ declare namespace intl { /** * Returns a string indicating which plural rule to use for locale-aware formatting. * - * @param { number } n - The number to get a plural rule for. + * @param { double } n - The number to get a plural rule for. * @returns { string } A string representing the pluralization category of the number, * can be one of zero, one, two, few, many or other. * @syscap SystemCapability.Global.I18n @@ -4210,7 +4210,7 @@ declare namespace intl { /** * Obtains the singular-plural type of the specified number. * - * @param { number } n - Number for which the singular-plural type is to be obtained. + * @param { double } n - Number for which the singular-plural type is to be obtained. * @returns { string } Singular-plural type. The value can be any of the following: "zero", "one", "two", "few", * "many", "others". For details about the meanings of different values, see * [Language Plural Rules](https://www.unicode.org/cldr/charts/45/supplemental/language_plural_rules.html). @@ -4221,7 +4221,7 @@ declare namespace intl { * @deprecated since 20 * @useinstead Intl.PluralRules.select */ - select(n: number): string; + select(n: double): string; } /** @@ -4591,7 +4591,7 @@ declare namespace intl { /** * formats a value and unit according to the locale and formatting options of this object. * - * @param { number } value - Numeric value to use in the internationalized relative time message. + * @param { double } value - Numeric value to use in the internationalized relative time message. * @param { string } unit - Unit to use in the relative time internationalized message. * Possible values are: year, quarter, month, week, day, hour, minute, second. * @returns { string } formatted language-sensitive relative time. @@ -4601,7 +4601,7 @@ declare namespace intl { /** * formats a value and unit according to the locale and formatting options of this object. * - * @param { number } value - Numeric value to use in the internationalized relative time message. + * @param { double } value - Numeric value to use in the internationalized relative time message. * @param { string } unit - Unit to use in the relative time internationalized message. * Possible values are: year, quarter, month, week, day, hour, minute, second. * @returns { string } formatted language-sensitive relative time. @@ -4612,7 +4612,7 @@ declare namespace intl { /** * Formats a relative time. * - * @param { number } value - Value to format. + * @param { double } value - Value to format. * @param { string } unit - Unit of the relative time.
The value can be any of the following: "year", "quarter", * "month", "week", "day", "hour", "minute", or "second". * @returns { string } Relative time after formatting. @@ -4623,13 +4623,13 @@ declare namespace intl { * @deprecated since 20 * @useinstead Intl.RelativeTimeFormat.format */ - format(value: number, unit: string): string; + format(value: double, unit: string): string; /** * returns an Array of objects representing the relative time format in parts that can be used for * custom locale-aware formatting * - * @param { number } value - Numeric value to use in the internationalized relative time message. + * @param { double } value - Numeric value to use in the internationalized relative time message. * @param { string } unit - to use in the relative time internationalized message. * Possible values are: year, quarter, month, week, day, hour, minute, second. * @returns { Array } an Array of objects representing the relative time format in parts @@ -4640,7 +4640,7 @@ declare namespace intl { * returns an Array of objects representing the relative time format in parts that can be used for * custom locale-aware formatting * - * @param { number } value - Numeric value to use in the internationalized relative time message. + * @param { double } value - Numeric value to use in the internationalized relative time message. * @param { string } unit - to use in the relative time internationalized message. * Possible values are: year, quarter, month, week, day, hour, minute, second. * @returns { Array } an Array of objects representing the relative time format in parts @@ -4651,7 +4651,7 @@ declare namespace intl { /** * Formats the relative time. * - * @param { number } value - Value to format. + * @param { double } value - Value to format. * @param { string } unit - Unit of the relative time.
The value can be any of the following: "year", "quarter", * "month", "week", "day", "hour", "minute", or "second". * @returns { Array } to parts. @@ -4662,7 +4662,7 @@ declare namespace intl { * @deprecated since 20 * @useinstead Intl.RelativeTimeFormat.formatToParts */ - formatToParts(value: number, unit: string): Array; + formatToParts(value: double, unit: string): Array; /** * Returns a new object with properties that reflect the locale and formatting options computed during diff --git a/api/@ohos.logLibrary.d.ts b/api/@ohos.logLibrary.d.ts index e73e661afa5b3855155c5924d6a7a5e407619940..f6ce0a56bcc9bad5932eee6360696d235cf55bd4 100644 --- a/api/@ohos.logLibrary.d.ts +++ b/api/@ohos.logLibrary.d.ts @@ -24,7 +24,8 @@ import type { AsyncCallback } from './@ohos.base'; * @namespace logLibrary * @syscap SystemCapability.HiviewDFX.Hiview.LogLibrary * @systemapi - * @since 10 + * @since arkts {'1.1':'10','1.2':'20'} + * @arkts 1.1&1.2 */ declare namespace logLibrary { /** @@ -33,7 +34,8 @@ declare namespace logLibrary { * @typedef LogEntry * @syscap SystemCapability.HiviewDFX.Hiview.LogLibrary * @systemapi - * @since 10 + * @since arkts {'1.1':'10','1.2':'20'} + * @arkts 1.1&1.2 */ interface LogEntry { /** @@ -42,7 +44,8 @@ declare namespace logLibrary { * @type { string } * @syscap SystemCapability.HiviewDFX.Hiview.LogLibrary * @systemapi - * @since 10 + * @since arkts {'1.1':'10','1.2':'20'} + * @arkts 1.1&1.2 */ name: string; @@ -52,7 +55,8 @@ declare namespace logLibrary { * @type { number } * @syscap SystemCapability.HiviewDFX.Hiview.LogLibrary * @systemapi - * @since 10 + * @since arkts {'1.1':'10','1.2':'20'} + * @arkts 1.1&1.2 */ mtime: number; @@ -62,7 +66,8 @@ declare namespace logLibrary { * @type { number } * @syscap SystemCapability.HiviewDFX.Hiview.LogLibrary * @systemapi - * @since 10 + * @since arkts {'1.1':'10','1.2':'20'} + * @arkts 1.1&1.2 */ size: number; } @@ -81,7 +86,8 @@ declare namespace logLibrary { *
3. Parameter verification failed. * @syscap SystemCapability.HiviewDFX.Hiview.LogLibrary * @systemapi - * @since 10 + * @since arkts {'1.1':'10','1.2':'20'} + * @arkts 1.1&1.2 */ function list(logType: string): LogEntry[]; @@ -102,7 +108,8 @@ declare namespace logLibrary { * @throws { BusinessError } 21300001 - Source file does not exists * @syscap SystemCapability.HiviewDFX.Hiview.LogLibrary * @systemapi - * @since 10 + * @since arkts {'1.1':'10','1.2':'20'} + * @arkts 1.1&1.2 */ function copy(logType: string, logName: string, dest: string): Promise; @@ -123,7 +130,8 @@ declare namespace logLibrary { * @throws { BusinessError } 21300001 - Source file does not exists * @syscap SystemCapability.HiviewDFX.Hiview.LogLibrary * @systemapi - * @since 10 + * @since arkts {'1.1':'10','1.2':'20'} + * @arkts 1.1&1.2 */ function copy(logType: string, logName: string, dest: string, callback: AsyncCallback): void; @@ -144,7 +152,8 @@ declare namespace logLibrary { * @throws { BusinessError } 21300001 - Source file does not exists * @syscap SystemCapability.HiviewDFX.Hiview.LogLibrary * @systemapi - * @since 10 + * @since arkts {'1.1':'10','1.2':'20'} + * @arkts 1.1&1.2 */ function move(logType: string, logName: string, dest: string): Promise; @@ -165,7 +174,8 @@ declare namespace logLibrary { * @throws { BusinessError } 21300001 - Source file does not exists * @syscap SystemCapability.HiviewDFX.Hiview.LogLibrary * @systemapi - * @since 10 + * @since arkts {'1.1':'10','1.2':'20'} + * @arkts 1.1&1.2 */ function move(logType: string, logName: string, dest: string, callback: AsyncCallback): void; @@ -184,7 +194,8 @@ declare namespace logLibrary { * @throws { BusinessError } 21300001 - Source file does not exists * @syscap SystemCapability.HiviewDFX.Hiview.LogLibrary * @systemapi - * @since 10 + * @since arkts {'1.1':'10','1.2':'20'} + * @arkts 1.1&1.2 */ function remove(logType: string, logName: string): void; } diff --git a/api/@ohos.resourceschedule.systemload.d.ts b/api/@ohos.resourceschedule.systemload.d.ts index 53ff2a57c5d4b95b9a98e50f7c316d7b3f788cad..ea6bf44d8c1d714f8d9510254049d9c37da8ad12 100644 --- a/api/@ohos.resourceschedule.systemload.d.ts +++ b/api/@ohos.resourceschedule.systemload.d.ts @@ -25,7 +25,8 @@ import type { Callback } from './@ohos.base'; * * @namespace systemLoad * @syscap SystemCapability.ResourceSchedule.SystemLoad - * @since 12 + * @since arkts{ '1.1':'12', '1.2':'20' } + * @arkts 1.1&1.2 */ declare namespace systemLoad { /** @@ -33,63 +34,72 @@ declare namespace systemLoad { * * @enum {number} * @syscap SystemCapability.ResourceSchedule.SystemLoad - * @since 12 + * @since arkts{ '1.1':'12', '1.2':'20' } + * @arkts 1.1&1.2 */ export enum SystemLoadLevel { /** * level low * * @syscap SystemCapability.ResourceSchedule.SystemLoad - * @since 12 + * @since arkts{ '1.1':'12', '1.2':'20' } + * @arkts 1.1&1.2 */ LOW = 0, /** * level NORMAL * * @syscap SystemCapability.ResourceSchedule.SystemLoad - * @since 12 + * @since arkts{ '1.1':'12', '1.2':'20' } + * @arkts 1.1&1.2 */ NORMAL = 1, /** * level MEDIUM * * @syscap SystemCapability.ResourceSchedule.SystemLoad - * @since 12 + * @since arkts{ '1.1':'12', '1.2':'20' } + * @arkts 1.1&1.2 */ MEDIUM = 2, /** * level HIGH * * @syscap SystemCapability.ResourceSchedule.SystemLoad - * @since 12 + * @since arkts{ '1.1':'12', '1.2':'20' } + * @arkts 1.1&1.2 */ HIGH = 3, /** * level OVERHEATED * * @syscap SystemCapability.ResourceSchedule.SystemLoad - * @since 12 + * @since arkts{ '1.1':'12', '1.2':'20' } + * @arkts 1.1&1.2 */ OVERHEATED = 4, /** * level WARNING * * @syscap SystemCapability.ResourceSchedule.SystemLoad - * @since 12 + * @since arkts{ '1.1':'12', '1.2':'20' } + * @arkts 1.1&1.2 */ WARNING = 5, /** * level EMERGENCY * * @syscap SystemCapability.ResourceSchedule.SystemLoad - * @since 12 + * @since arkts{ '1.1':'12', '1.2':'20' } + * @arkts 1.1&1.2 */ EMERGENCY = 6, /** * level ESCAPE * * @syscap SystemCapability.ResourceSchedule.SystemLoad - * @since 12 + * @since arkts{ '1.1':'12', '1.2':'20' } + * @arkts 1.1&1.2 */ ESCAPE = 7 } @@ -101,7 +111,8 @@ declare namespace systemLoad { * @throws { BusinessError } 401 - Parameter error. Possible cause: 1. Callback parameter error; *
2. Register a exist callback type; 3. Parameter verification failed. * @syscap SystemCapability.ResourceSchedule.SystemLoad - * @since 12 + * @since arkts{ '1.1':'12', '1.2':'20' } + * @arkts 1.1&1.2 */ function on(type: 'systemLoadChange', callback: Callback): void; @@ -112,7 +123,8 @@ declare namespace systemLoad { * @throws { BusinessError } 401 - Parameter error. Possible cause: 1. Callback parameter error; *
2. Unregister type has not register; 3. Parameter verification failed. * @syscap SystemCapability.ResourceSchedule.SystemLoad - * @since 12 + * @since arkts{ '1.1':'12', '1.2':'20' } + * @arkts 1.1&1.2 */ function off(type: 'systemLoadChange', callback?: Callback): void; @@ -120,7 +132,8 @@ declare namespace systemLoad { * @returns { Promise } The promise form returns the SystemLoadLevel result * Queries the current system level * @syscap SystemCapability.ResourceSchedule.SystemLoad - * @since 12 + * @since arkts{ '1.1':'12', '1.2':'20' } + * @arkts 1.1&1.2 */ function getLevel(): Promise; } diff --git a/api/@ohos.window.d.ts b/api/@ohos.window.d.ts index cb45fd3b218dcfa1df00100d426bba90b30b647c..07741a8a50ff4cb973cfebab2ce6e34b73cb56e5 100644 --- a/api/@ohos.window.d.ts +++ b/api/@ohos.window.d.ts @@ -33,7 +33,6 @@ import bundleManager from './@ohos.bundle.bundleManager'; import { LocalStorage } from '@ohos.arkui.stateManagement'; import { UIContext } from '@ohos.arkui.UIContext'; import { ColorMetrics } from '@ohos.arkui.node'; -import { Callback } from './@ohos.base'; /*** endif */ /*** if arkts 1.1 */ @@ -59,6 +58,17 @@ declare interface Callback { } /*** endif */ +/** + * Defines the window callback. + * + * @typedef {function} + * @syscap SystemCapability.Window.SessionManager + * @atomicservice + * @since 20 + * @arkts 1.2 + */ +type Callback = (data: T) => V; + /** * Defines the window animation curve param. * @@ -2097,7 +2107,8 @@ declare namespace window { * @type { ?colorMode } * @syscap SystemCapability.Window.SessionManager * @atomicservice - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ colorMode?: ConfigurationConstant.ColorMode; @@ -2107,7 +2118,8 @@ declare namespace window { * @type { ?number } * @syscap SystemCapability.Window.SessionManager * @atomicservice - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ buttonBackgroundSize? : number; @@ -2117,7 +2129,8 @@ declare namespace window { * @type { ?number } * @syscap SystemCapability.Window.SessionManager * @atomicservice - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ spacingBetweenButtons? : number; @@ -2127,7 +2140,8 @@ declare namespace window { * @type { ?number } * @syscap SystemCapability.Window.SessionManager * @atomicservice - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ closeButtonRightMargin? : number; @@ -7587,7 +7601,8 @@ declare namespace window { * @throws { BusinessError } 1300004 - Unauthorized operation. * @syscap SystemCapability.Window.SessionManager * @atomicservice - * @since 15 + * @since arkts {'1.1':'15', '1.2':'20'} + * @arkts 1.1&1.2 */ on(type: 'windowWillClose', callback: Callback>): void; @@ -7607,7 +7622,8 @@ declare namespace window { * @throws { BusinessError } 1300004 - Unauthorized operation. * @syscap SystemCapability.Window.SessionManager * @atomicservice - * @since 15 + * @since arkts {'1.1':'15', '1.2':'20'} + * @arkts 1.1&1.2 */ off(type: 'windowWillClose', callback?: Callback>): void; @@ -9516,7 +9532,8 @@ declare namespace window { * @throws { BusinessError } 1300003 - This window manager service works abnormally. * @syscap SystemCapability.Window.SessionManager * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ minimize(callback: AsyncCallback): void; @@ -9540,7 +9557,8 @@ declare namespace window { * @throws { BusinessError } 1300003 - This window manager service works abnormally. * @syscap SystemCapability.Window.SessionManager * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ minimize(): Promise; @@ -10018,7 +10036,8 @@ declare namespace window { * @throws { BusinessError } 1300004 - Unauthorized operation. * @syscap SystemCapability.Window.SessionManager * @atomicservice - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ setDecorButtonStyle(dectorStyle: DecorButtonStyle): void; @@ -10108,7 +10127,8 @@ declare namespace window { * @throws { BusinessError } 1300004 - Unauthorized operation. * @syscap SystemCapability.Window.SessionManager * @atomicservice - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ setWindowTitleButtonVisible(isMaximizeButtonVisible: boolean, isMinimizeButtonVisible: boolean, isCloseButtonVisible?: boolean): void; @@ -10136,7 +10156,8 @@ declare namespace window { * @throws { BusinessError } 1300004 - Unauthorized operation. * @syscap SystemCapability.Window.SessionManager * @atomicservice - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ startMoving(): Promise; @@ -10160,7 +10181,8 @@ declare namespace window { * @throws { BusinessError } 1300004 - Unauthorized operation. * @syscap SystemCapability.Window.SessionManager * @atomicservice - * @since 15 + * @since arkts {'1.1':'15', '1.2':'20'} + * @arkts 1.1&1.2 */ startMoving(offsetX: number, offsetY: number): Promise; @@ -10282,7 +10304,8 @@ declare namespace window { * @throws { BusinessError } 1300002 - This window state is abnormal. * @syscap SystemCapability.Window.SessionManager * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ on(type: 'windowTitleButtonRectChange', callback: Callback): void; @@ -10311,7 +10334,8 @@ declare namespace window { * @throws { BusinessError } 1300002 - This window state is abnormal. * @syscap SystemCapability.Window.SessionManager * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ off(type: 'windowTitleButtonRectChange', callback?: Callback): void; @@ -10548,7 +10572,8 @@ declare namespace window { * @throws { BusinessError } 1300002 - This window state is abnormal. * @syscap SystemCapability.Window.SessionManager * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ getWindowStatus(): WindowStatusType; @@ -11762,7 +11787,8 @@ declare namespace window { * @syscap SystemCapability.Window.SessionManager * @stagemodelonly * @atomicservice - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ on(eventType: 'windowStageClose', callback: Callback): void; @@ -11782,7 +11808,8 @@ declare namespace window { * @syscap SystemCapability.Window.SessionManager * @stagemodelonly * @atomicservice - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ off(eventType: 'windowStageClose', callback?: Callback): void; diff --git a/api/@ohos.zlib.d.ts b/api/@ohos.zlib.d.ts index 6b2429d312a653489e29e0f371239e16721f85f9..3378c2d3ea7c05cf8b27dbc94e140e6f6f6b7a99 100644 --- a/api/@ohos.zlib.d.ts +++ b/api/@ohos.zlib.d.ts @@ -1028,7 +1028,8 @@ declare namespace zlib { * @syscap SystemCapability.BundleManager.Zlib * @crossplatform * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ function compressFile(inFile: string, outFile: string, options: Options, callback: AsyncCallback): void; @@ -1058,7 +1059,8 @@ declare namespace zlib { * @syscap SystemCapability.BundleManager.Zlib * @crossplatform * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ function compressFile(inFile: string, outFile: string, options: Options): Promise; @@ -1074,7 +1076,8 @@ declare namespace zlib { * @throws { BusinessError } 900002 - The input destination file is invalid. * @syscap SystemCapability.BundleManager.Zlib * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ function compressFiles(inFiles: Array, outFile: string, options: Options): Promise; @@ -1212,7 +1215,8 @@ declare namespace zlib { * @syscap SystemCapability.BundleManager.Zlib * @crossplatform * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ function getOriginalSize(compressedFile: string): Promise; @@ -1222,7 +1226,8 @@ declare namespace zlib { * @returns { Promise } Returns verification objects. * @syscap SystemCapability.BundleManager.Zlib * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ function createChecksum(): Promise; @@ -1232,7 +1237,8 @@ declare namespace zlib { * @returns { Checksum } Returns verification objects. * @syscap SystemCapability.BundleManager.Zlib * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ function createChecksumSync(): Checksum; @@ -1282,7 +1288,8 @@ declare namespace zlib { * @typedef Checksum * @syscap SystemCapability.BundleManager.Zlib * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ interface Checksum { /** @@ -1295,7 +1302,8 @@ declare namespace zlib { *
2. Incorrect parameter types; 3. Parameter verification failed. * @syscap SystemCapability.BundleManager.Zlib * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ adler32(adler: number, buf: ArrayBuffer): Promise; @@ -1310,7 +1318,8 @@ declare namespace zlib { *
2. Incorrect parameter types; 3. Parameter verification failed. * @syscap SystemCapability.BundleManager.Zlib * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ adler32Combine(adler1: number, adler2: number, len2: number): Promise; @@ -1324,7 +1333,8 @@ declare namespace zlib { *
2. Incorrect parameter types; 3. Parameter verification failed. * @syscap SystemCapability.BundleManager.Zlib * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ crc32(crc: number, buf: ArrayBuffer): Promise; @@ -1339,7 +1349,8 @@ declare namespace zlib { *
2. Incorrect parameter types; 3. Parameter verification failed. * @syscap SystemCapability.BundleManager.Zlib * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ crc32Combine(crc1: number, crc2: number, len2: number): Promise; @@ -1363,7 +1374,8 @@ declare namespace zlib { * @returns { Promise> } Return a array to the CRC-32 table. * @syscap SystemCapability.BundleManager.Zlib * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ getCrcTable(): Promise>; diff --git a/api/application/AbilityDelegator.d.ts b/api/application/AbilityDelegator.d.ts index 1408bd24e45c5bd82d777b341f9b35e36b7036c0..d7a91d0bf75b39ceff7ed9a8d674814f5a59ebf3 100644 --- a/api/application/AbilityDelegator.d.ts +++ b/api/application/AbilityDelegator.d.ts @@ -23,11 +23,9 @@ import { AbilityMonitor } from './AbilityMonitor'; import Context from './Context'; import Want from '../@ohos.app.ability.Want'; import { ShellCmdResult } from './shellCmdResult'; -/*** if arkts 1.1 */ import UIAbility from '../@ohos.app.ability.UIAbility'; import AbilityStage from '../@ohos.app.ability.AbilityStage'; import { AbilityStageMonitor } from './AbilityStageMonitor'; -/*** endif */ /** * A global test utility interface used for adding AbilityMonitor objects and control lifecycle states of abilities. @@ -146,7 +144,8 @@ export interface AbilityDelegator { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @crossplatform * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ addAbilityMonitorSync(monitor: AbilityMonitor): void; @@ -181,7 +180,8 @@ export interface AbilityDelegator { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @crossplatform * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ addAbilityStageMonitor(monitor: AbilityStageMonitor, callback: AsyncCallback): void; @@ -216,7 +216,8 @@ export interface AbilityDelegator { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @crossplatform * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ addAbilityStageMonitor(monitor: AbilityStageMonitor): Promise; @@ -239,7 +240,8 @@ export interface AbilityDelegator { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @crossplatform * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ addAbilityStageMonitorSync(monitor: AbilityStageMonitor): void; @@ -274,7 +276,8 @@ export interface AbilityDelegator { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @crossplatform * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ removeAbilityMonitor(monitor: AbilityMonitor, callback: AsyncCallback): void; @@ -309,7 +312,8 @@ export interface AbilityDelegator { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @crossplatform * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ removeAbilityMonitor(monitor: AbilityMonitor): Promise; @@ -332,7 +336,8 @@ export interface AbilityDelegator { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @crossplatform * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ removeAbilityMonitorSync(monitor: AbilityMonitor): void; @@ -367,7 +372,8 @@ export interface AbilityDelegator { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @crossplatform * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ removeAbilityStageMonitor(monitor: AbilityStageMonitor, callback: AsyncCallback): void; @@ -402,7 +408,8 @@ export interface AbilityDelegator { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @crossplatform * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ removeAbilityStageMonitor(monitor: AbilityStageMonitor): Promise; @@ -425,7 +432,8 @@ export interface AbilityDelegator { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @crossplatform * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ removeAbilityStageMonitorSync(monitor: AbilityStageMonitor): void; @@ -460,7 +468,8 @@ export interface AbilityDelegator { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @crossplatform * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ waitAbilityMonitor(monitor: AbilityMonitor, callback: AsyncCallback): void; @@ -498,7 +507,8 @@ export interface AbilityDelegator { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @crossplatform * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ waitAbilityMonitor(monitor: AbilityMonitor, timeout: number, callback: AsyncCallback): void; @@ -536,7 +546,8 @@ export interface AbilityDelegator { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @crossplatform * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ waitAbilityMonitor(monitor: AbilityMonitor, timeout?: number): Promise; @@ -571,7 +582,8 @@ export interface AbilityDelegator { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @crossplatform * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ waitAbilityStageMonitor(monitor: AbilityStageMonitor, callback: AsyncCallback): void; @@ -609,7 +621,8 @@ export interface AbilityDelegator { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @crossplatform * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ waitAbilityStageMonitor(monitor: AbilityStageMonitor, timeout: number, callback: AsyncCallback): void; @@ -647,7 +660,8 @@ export interface AbilityDelegator { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @crossplatform * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ waitAbilityStageMonitor(monitor: AbilityStageMonitor, timeout?: number): Promise; @@ -706,7 +720,8 @@ export interface AbilityDelegator { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @crossplatform * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ getAbilityState(ability: UIAbility): number; @@ -738,7 +753,8 @@ export interface AbilityDelegator { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @crossplatform * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ getCurrentTopAbility(callback: AsyncCallback): void; @@ -767,7 +783,8 @@ export interface AbilityDelegator { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @crossplatform * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ getCurrentTopAbility(): Promise; @@ -954,7 +971,8 @@ export interface AbilityDelegator { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @crossplatform * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ doAbilityForeground(ability: UIAbility, callback: AsyncCallback): void; @@ -989,7 +1007,8 @@ export interface AbilityDelegator { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @crossplatform * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ doAbilityForeground(ability: UIAbility): Promise; @@ -1024,7 +1043,8 @@ export interface AbilityDelegator { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @crossplatform * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ doAbilityBackground(ability: UIAbility, callback: AsyncCallback): void; @@ -1059,7 +1079,8 @@ export interface AbilityDelegator { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @crossplatform * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ doAbilityBackground(ability: UIAbility): Promise; @@ -1091,7 +1112,8 @@ export interface AbilityDelegator { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @crossplatform * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ print(msg: string, callback: AsyncCallback): void; @@ -1123,7 +1145,8 @@ export interface AbilityDelegator { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @crossplatform * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ print(msg: string): Promise; diff --git a/api/application/AbilityStageContext.d.ts b/api/application/AbilityStageContext.d.ts index 7ba6723754bab9c82a5340cda99f2e885a504310..d66ced481c6afe0d2d4f8f42de6276b1bbbc886e 100644 --- a/api/application/AbilityStageContext.d.ts +++ b/api/application/AbilityStageContext.d.ts @@ -77,7 +77,8 @@ declare class AbilityStageContext extends Context { * @StageModelOnly * @crossplatform * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ currentHapModuleInfo: HapModuleInfo; diff --git a/api/application/AbilityStageMonitor.d.ts b/api/application/AbilityStageMonitor.d.ts index 4ad19aa35ce0c5c8c3ecbc5b43bb4977a959d703..3ae8640147ea88417d3c4573b6b0ef41ebdf056c 100644 --- a/api/application/AbilityStageMonitor.d.ts +++ b/api/application/AbilityStageMonitor.d.ts @@ -43,7 +43,8 @@ * @syscap SystemCapability.Ability.AbilityRuntime.Core * @crossplatform * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ export interface AbilityStageMonitor { /** @@ -68,7 +69,8 @@ export interface AbilityStageMonitor { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @crossplatform * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ moduleName: string; @@ -94,9 +96,12 @@ export interface AbilityStageMonitor { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @crossplatform * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ srcEntrance: string; } +/*** if arkts 1.1 */ export default AbilityStageMonitor; +/*** endif */ \ No newline at end of file diff --git a/api/application/AbilityStateData.d.ts b/api/application/AbilityStateData.d.ts index a7fe4b7901732cd69385be6207b0d08f6a8155a4..fad8201ea1b4a990275ad6c5da3ed3075db1e5bc 100644 --- a/api/application/AbilityStateData.d.ts +++ b/api/application/AbilityStateData.d.ts @@ -22,7 +22,8 @@ * The ability or extension state data. * * @syscap SystemCapability.Ability.AbilityRuntime.Core - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ export default class AbilityStateData { /** @@ -30,7 +31,8 @@ export default class AbilityStateData { * * @type { string } * @syscap SystemCapability.Ability.AbilityRuntime.Core - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ moduleName: string; @@ -39,7 +41,8 @@ export default class AbilityStateData { * * @type { string } * @syscap SystemCapability.Ability.AbilityRuntime.Core - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ bundleName: string; @@ -48,7 +51,8 @@ export default class AbilityStateData { * * @type { string } * @syscap SystemCapability.Ability.AbilityRuntime.Core - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ abilityName: string; @@ -57,7 +61,8 @@ export default class AbilityStateData { * * @type { number } * @syscap SystemCapability.Ability.AbilityRuntime.Core - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ pid: number; @@ -66,7 +71,8 @@ export default class AbilityStateData { * * @type { number } * @syscap SystemCapability.Ability.AbilityRuntime.Core - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ uid: number; @@ -75,7 +81,8 @@ export default class AbilityStateData { * * @type { number } * @syscap SystemCapability.Ability.AbilityRuntime.Core - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ state: number; @@ -84,7 +91,8 @@ export default class AbilityStateData { * * @type { number } * @syscap SystemCapability.Ability.AbilityRuntime.Core - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ abilityType: number; @@ -93,7 +101,8 @@ export default class AbilityStateData { * * @type { boolean } * @syscap SystemCapability.Ability.AbilityRuntime.Core - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ isAtomicService: boolean; @@ -101,7 +110,8 @@ export default class AbilityStateData { * The app clone index of ability instance. * @type { ?number } * @syscap SystemCapability.Ability.AbilityRuntime.Core - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ appCloneIndex?: number; } diff --git a/api/application/AppStateData.d.ts b/api/application/AppStateData.d.ts index 154b10fa8118ea5a9ab1fafae75f350d24613a2d..8031f673551360f0a4d8343a9d9962736a0f0a79 100644 --- a/api/application/AppStateData.d.ts +++ b/api/application/AppStateData.d.ts @@ -22,15 +22,17 @@ * The application state data. * * @syscap SystemCapability.Ability.AbilityRuntime.Core - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ -export default class AppStateData { +declare class AppStateData { /** * The bundle name. * * @type { string } * @syscap SystemCapability.Ability.AbilityRuntime.Core - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ bundleName: string; @@ -39,7 +41,8 @@ export default class AppStateData { * * @type { number } * @syscap SystemCapability.Ability.AbilityRuntime.Core - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ uid: number; @@ -48,7 +51,8 @@ export default class AppStateData { * * @type { number } * @syscap SystemCapability.Ability.AbilityRuntime.Core - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ state: number; @@ -57,7 +61,8 @@ export default class AppStateData { * * @type { boolean } * @syscap SystemCapability.Ability.AbilityRuntime.Core - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ isSplitScreenMode: boolean; @@ -66,7 +71,10 @@ export default class AppStateData { * * @type { boolean } * @syscap SystemCapability.Ability.AbilityRuntime.Core - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ isFloatingWindowMode: boolean; } + +export default AppStateData; \ No newline at end of file diff --git a/api/application/ApplicationContext.d.ts b/api/application/ApplicationContext.d.ts index b90f46c56a8fbb63119ef1980850a8dc127b439d..e4777379ad5c0ff3384a9735a5fbb707486294f6 100644 --- a/api/application/ApplicationContext.d.ts +++ b/api/application/ApplicationContext.d.ts @@ -19,15 +19,14 @@ */ import Context from './Context'; - -/*** if arkts 1.1 */ import { AsyncCallback } from '../@ohos.base'; -import AbilityLifecycleCallback from '../@ohos.app.ability.AbilityLifecycleCallback'; -import EnvironmentCallback from '../@ohos.app.ability.EnvironmentCallback'; -import type ApplicationStateChangeCallback from '../@ohos.app.ability.ApplicationStateChangeCallback'; import { ProcessInformation } from './ProcessInformation'; import type ConfigurationConstant from '../@ohos.app.ability.ConfigurationConstant'; import Want from '../@ohos.app.ability.Want'; +/*** if arkts 1.1 */ +import AbilityLifecycleCallback from '../@ohos.app.ability.AbilityLifecycleCallback'; +import EnvironmentCallback from '../@ohos.app.ability.EnvironmentCallback'; +import type ApplicationStateChangeCallback from '../@ohos.app.ability.ApplicationStateChangeCallback'; /*** endif */ /** @@ -413,7 +412,8 @@ declare class ApplicationContext extends Context { * @stagemodelonly * @crossplatform * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ getRunningProcessInformation(): Promise>; @@ -454,7 +454,8 @@ declare class ApplicationContext extends Context { * @stagemodelonly * @crossplatform * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ getRunningProcessInformation(callback: AsyncCallback>): void; @@ -486,7 +487,8 @@ declare class ApplicationContext extends Context { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ killAllProcesses(): Promise; @@ -509,7 +511,8 @@ declare class ApplicationContext extends Context { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly * @atomicservice - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ killAllProcesses(clearPageStack: boolean): Promise; @@ -573,7 +576,8 @@ declare class ApplicationContext extends Context { * @stagemodelonly * @crossplatform * @atomicservice - * @since 18 + * @since arkts {'1.1':'18', '1.2':'20'} + * @arkts 1.1&1.2 */ setColorMode(colorMode: ConfigurationConstant.ColorMode): void; @@ -592,7 +596,8 @@ declare class ApplicationContext extends Context { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ setLanguage(language: string): void; @@ -611,7 +616,8 @@ declare class ApplicationContext extends Context { * @throws { BusinessError } 16000050 - Internal error. * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ clearUpApplicationData(): Promise; @@ -633,7 +639,8 @@ declare class ApplicationContext extends Context { * @throws { BusinessError } 16000050 - Internal error. * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ clearUpApplicationData(callback: AsyncCallback): void; @@ -656,7 +663,8 @@ declare class ApplicationContext extends Context { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ restartApp(want: Want): void; @@ -682,7 +690,8 @@ declare class ApplicationContext extends Context { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi * @stagemodelonly - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ preloadUIExtensionAbility(want: Want): Promise; @@ -728,7 +737,8 @@ declare class ApplicationContext extends Context { * @throws { BusinessError } 16000050 - Internal error. * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ setFont(font: string): void; @@ -759,7 +769,8 @@ declare class ApplicationContext extends Context { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly * @atomicservice - * @since 13 + * @since arkts {'1.1':'13', '1.2':'20'} + * @arkts 1.1&1.2 */ setFontSizeScale(fontSizeScale: number): void; diff --git a/api/application/ApplicationStateObserver.d.ts b/api/application/ApplicationStateObserver.d.ts index ff86fd03c2c126f55847821eac7aedd3ab524a38..4b9eed7a3c88b3415fe4f6593702a166ae90239a 100644 --- a/api/application/ApplicationStateObserver.d.ts +++ b/api/application/ApplicationStateObserver.d.ts @@ -19,16 +19,20 @@ */ import AppStateData from './AppStateData'; +/*** if arkts 1.1 */ import AbilityStateData from './AbilityStateData'; import * as _ProcessData from './ProcessData'; +/*** endif */ /** * The application state observer. * + * @typedef ApplicationStateObserver * @syscap SystemCapability.Ability.AbilityRuntime.Core - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ -export default class ApplicationStateObserver { +declare interface ApplicationStateObserver { /** * Will be called when foreground or background application changed. * @@ -100,3 +104,5 @@ export default class ApplicationStateObserver { * @since 14 */ export type ProcessData = _ProcessData.default; + +export default ApplicationStateObserver; \ No newline at end of file diff --git a/api/application/Context.d.ts b/api/application/Context.d.ts index 29648a92b662bece23f8d3ae998425d9d0ecab50..b226b367193ebfd2d3c959463781b09b532b97b3 100644 --- a/api/application/Context.d.ts +++ b/api/application/Context.d.ts @@ -145,7 +145,8 @@ declare class Context extends BaseContext { * @stagemodelonly * @crossplatform * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ cacheDir: string; @@ -264,7 +265,8 @@ declare class Context extends BaseContext { * @stagemodelonly * @crossplatform * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ preferencesDir: string; @@ -639,7 +641,8 @@ declare class Context extends BaseContext { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi * @stagemodelonly - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ createModuleResourceManager(bundleName: string, moduleName: string): resmgr.ResourceManager; diff --git a/api/application/ExtensionContext.d.ts b/api/application/ExtensionContext.d.ts index cdb9df42a73618ec0d4eae889ee7fb5e33a4e30a..fee3759ff5942fd609f01ae51a73511cd3085ccb 100644 --- a/api/application/ExtensionContext.d.ts +++ b/api/application/ExtensionContext.d.ts @@ -18,10 +18,9 @@ * @kit AbilityKit */ -/*** if arkts 1.1 */ + import { HapModuleInfo } from '../bundleManager/HapModuleInfo'; import { Configuration } from '../@ohos.app.ability.Configuration'; -/*** endif */ import Context from './Context'; import { ExtensionAbilityInfo } from '../bundleManager/ExtensionAbilityInfo'; @@ -59,7 +58,8 @@ declare class ExtensionContext extends Context { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @StageModelOnly * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ currentHapModuleInfo: HapModuleInfo; @@ -78,7 +78,8 @@ declare class ExtensionContext extends Context { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @StageModelOnly * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ config: Configuration; diff --git a/api/application/FormEditExtensionContext.d.ts b/api/application/FormEditExtensionContext.d.ts index c236f8d1a06fa865b3e9de1412abb65092042def..86daad8f29bd9f183401dea3fcb9d8f070c8b7a9 100644 --- a/api/application/FormEditExtensionContext.d.ts +++ b/api/application/FormEditExtensionContext.d.ts @@ -31,7 +31,7 @@ import type { AbilityResult } from '../ability/abilityResult'; * @stagemodelonly * @since 18 */ -export default class FormEditExtensionContext extends UIExtensionContext { +declare class FormEditExtensionContext extends UIExtensionContext { /** * Start second editor extension ability. * @@ -47,3 +47,5 @@ export default class FormEditExtensionContext extends UIExtensionContext { */ startSecondPage(want: Want): Promise; } +export default FormEditExtensionContext; + diff --git a/api/application/FormExtensionContext.d.ts b/api/application/FormExtensionContext.d.ts index a07bd0a86d1830bc243139fa733bd123043a1725..17b56c331fff86a26cf7b0a6601f9e977b97d508 100644 --- a/api/application/FormExtensionContext.d.ts +++ b/api/application/FormExtensionContext.d.ts @@ -21,11 +21,9 @@ /*** if arkts 1.1 */ import { AsyncCallback } from '../@ohos.base'; import type { ConnectOptions } from '../ability/connectOptions'; -/*** endif */ -import ExtensionContext from './ExtensionContext'; -/*** if arkts 1.1 */ import Want from '../@ohos.app.ability.Want'; /*** endif */ +import ExtensionContext from './ExtensionContext'; /** * The context of form extension. It allows access to @@ -47,7 +45,7 @@ import Want from '../@ohos.app.ability.Want'; * @since arkts {'1.1':'11', '1.2':'20'} * @arkts 1.1&1.2 */ -export default class FormExtensionContext extends ExtensionContext { +declare class FormExtensionContext extends ExtensionContext { /** * Start an ability within the same bundle. * @@ -136,7 +134,7 @@ export default class FormExtensionContext extends ExtensionContext { * 1.Mandatory parameters are left unspecified; 2.Incorrect parameter types; 3.Parameter verification failed. * @throws { BusinessError } 16000001 - The specified ability does not exist. * @throws { BusinessError } 16000002 - Incorrect ability type. - * @throws { BusinessError } 16000004 - Cannot start an invisible component. + * @throws { BusinessError } 16000004 - Can not start invisible component. * @throws { BusinessError } 16000005 - The specified process does not have the permission. * @throws { BusinessError } 16000006 - Cross-user operations are not allowed. * @throws { BusinessError } 16000008 - The crowdtesting application expires. @@ -183,3 +181,5 @@ export default class FormExtensionContext extends ExtensionContext { */ disconnectServiceExtensionAbility(connection: number): Promise; } + +export default FormExtensionContext; \ No newline at end of file diff --git a/api/application/LiveFormExtensionContext.d.ts b/api/application/LiveFormExtensionContext.d.ts index dbc3bab3d58ff771de042235a60b9bef56c725f4..9dbc7890d557adfecc3216dfcddc1c7ab41fd586 100644 --- a/api/application/LiveFormExtensionContext.d.ts +++ b/api/application/LiveFormExtensionContext.d.ts @@ -30,7 +30,7 @@ import ExtensionContext from './ExtensionContext'; * @atomicservice * @since 20 */ -export default class LiveFormExtensionContext extends ExtensionContext { +declare class LiveFormExtensionContext extends ExtensionContext { /** * Set the background image of the live form. * @@ -44,4 +44,5 @@ export default class LiveFormExtensionContext extends ExtensionContext { * @since 20 */ setBackgroundImage(res: Resource): Promise; -} \ No newline at end of file +} +export default LiveFormExtensionContext; diff --git a/api/application/MultiAppMode.d.ts b/api/application/MultiAppMode.d.ts index af50f66357e4874a95596a509738605b66434eb2..8b821e9f21e374049f342c7c27d8b8595314bc8b 100644 --- a/api/application/MultiAppMode.d.ts +++ b/api/application/MultiAppMode.d.ts @@ -24,7 +24,8 @@ * @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore * @systemapi * @stagemodelonly - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ export enum MultiAppMode { /** @@ -33,7 +34,8 @@ export enum MultiAppMode { * @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore * @systemapi * @stagemodelonly - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ NOT_SUPPORTED = 0, @@ -43,7 +45,8 @@ export enum MultiAppMode { * @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore * @systemapi * @stagemodelonly - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ MULTI_INSTANCE = 1, @@ -53,7 +56,8 @@ export enum MultiAppMode { * @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore * @systemapi * @stagemodelonly - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ APP_CLONE = 2 } \ No newline at end of file diff --git a/api/application/ProcessInformation.d.ts b/api/application/ProcessInformation.d.ts index 15fe488e7153adc46b63f2ed18e85c7f8d5c7f58..8f64c790d66fd7e83a38a4b3841040b06904c5b3 100644 --- a/api/application/ProcessInformation.d.ts +++ b/api/application/ProcessInformation.d.ts @@ -18,7 +18,12 @@ * @kit AbilityKit */ +/*** if arkts 1.1 */ import type appManager from '../@ohos.app.ability.appManager'; +/*** endif */ +/*** if arkts 1.2 */ +import appManager from '../@ohos.app.ability.appManager'; +/*** endif */ import bundleManager from '../@ohos.bundle.bundleManager'; /** @@ -43,7 +48,8 @@ import bundleManager from '../@ohos.bundle.bundleManager'; * @syscap SystemCapability.Ability.AbilityRuntime.Core * @crossplatform * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ export interface ProcessInformation { /** @@ -66,7 +72,8 @@ export interface ProcessInformation { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @crossplatform * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ pid: number; @@ -81,7 +88,8 @@ export interface ProcessInformation { * @default user id * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ uid: number; @@ -105,7 +113,8 @@ export interface ProcessInformation { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @crossplatform * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ processName: string; @@ -129,7 +138,8 @@ export interface ProcessInformation { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @crossplatform * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ bundleNames: Array; @@ -146,7 +156,8 @@ export interface ProcessInformation { * @type { appManager.ProcessState } * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ state: appManager.ProcessState; @@ -156,7 +167,8 @@ export interface ProcessInformation { * @type { bundleManager.BundleType } * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ bundleType: bundleManager.BundleType; @@ -165,7 +177,8 @@ export interface ProcessInformation { * @type { ?number } * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ appCloneIndex?: number; } diff --git a/api/application/RunningAppClone.d.ts b/api/application/RunningAppClone.d.ts index b85dcbadecc68115fad3487bede0fa195c59bc61..261cb1d15ab7804913898229678934892a6b2597 100644 --- a/api/application/RunningAppClone.d.ts +++ b/api/application/RunningAppClone.d.ts @@ -24,7 +24,8 @@ * @typedef RunningAppClone * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ export interface RunningAppClone { /** @@ -33,7 +34,8 @@ export interface RunningAppClone { * @type { number } * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ appCloneIndex: number; @@ -43,7 +45,8 @@ export interface RunningAppClone { * @type { number } * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ uid: number; @@ -53,7 +56,8 @@ export interface RunningAppClone { * @type { Array } * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ pids: Array; } \ No newline at end of file diff --git a/api/application/RunningMultiAppInfo.d.ts b/api/application/RunningMultiAppInfo.d.ts index 29447ea549103f141a5d3356ec58f949365e0327..cb77e92feb76f6e4a8633f3d389d72b3e6cfa0a8 100644 --- a/api/application/RunningMultiAppInfo.d.ts +++ b/api/application/RunningMultiAppInfo.d.ts @@ -28,7 +28,8 @@ import { RunningMultiInstanceInfo } from './RunningMultiInstanceInfo'; * @typedef RunningMultiAppInfo * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ export interface RunningMultiAppInfo { @@ -39,7 +40,8 @@ export interface RunningMultiAppInfo { * @type { string } * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ bundleName: string; @@ -59,7 +61,8 @@ export interface RunningMultiAppInfo { * @type { ?Array } * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ runningMultiInstances?: Array; diff --git a/api/application/RunningMultiInstanceInfo.d.ts b/api/application/RunningMultiInstanceInfo.d.ts index fc279f303149c8006c5a11d3dbf96f2e801489ba..1645db4051150699348f31ddabb10c8ac71a571a 100644 --- a/api/application/RunningMultiInstanceInfo.d.ts +++ b/api/application/RunningMultiInstanceInfo.d.ts @@ -24,7 +24,8 @@ * @typedef RunningMultiInstanceInfo * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ export interface RunningMultiInstanceInfo { /** @@ -33,7 +34,8 @@ export interface RunningMultiInstanceInfo { * @type { string } * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ instanceKey: string; diff --git a/api/application/ServiceExtensionContext.d.ts b/api/application/ServiceExtensionContext.d.ts index 20a60d8e882684141a7b2c2dbfae8e669e035c15..d133113da903b814b9138fc5c16af5b4ab178b77 100644 --- a/api/application/ServiceExtensionContext.d.ts +++ b/api/application/ServiceExtensionContext.d.ts @@ -19,15 +19,15 @@ */ /*** if arkts 1.1 */ -import { AsyncCallback } from '../@ohos.base'; import { ConnectOptions } from '../ability/connectOptions'; import { Caller } from '../@ohos.app.ability.UIAbility'; -import Want from '../@ohos.app.ability.Want'; -import StartOptions from '../@ohos.app.ability.StartOptions'; import OpenLinkOptions from '../@ohos.app.ability.OpenLinkOptions'; import type AtomicServiceOptions from '../@ohos.app.ability.AtomicServiceOptions'; /*** endif */ +import { AsyncCallback } from '../@ohos.base'; import ExtensionContext from './ExtensionContext'; +import StartOptions from '../@ohos.app.ability.StartOptions'; +import Want from '../@ohos.app.ability.Want'; /** * The context of service extension. It allows access to @@ -40,7 +40,7 @@ import ExtensionContext from './ExtensionContext'; * @since arkts {'1.1':'9', '1.2':'20'} * @arkts 1.1&1.2 */ -export default class ServiceExtensionContext extends ExtensionContext { +declare class ServiceExtensionContext extends ExtensionContext { /** * Service extension uses this method to start a specific ability. * @@ -174,7 +174,8 @@ export default class ServiceExtensionContext extends ExtensionContext { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi * @stagemodelonly - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ startAbility(want: Want, callback: AsyncCallback): void; @@ -309,7 +310,8 @@ export default class ServiceExtensionContext extends ExtensionContext { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi * @stagemodelonly - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ startAbility(want: Want, options: StartOptions, callback: AsyncCallback): void; @@ -450,7 +452,8 @@ export default class ServiceExtensionContext extends ExtensionContext { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi * @stagemodelonly - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ startAbility(want: Want, options?: StartOptions): Promise; @@ -1300,7 +1303,8 @@ export default class ServiceExtensionContext extends ExtensionContext { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi * @stagemodelonly - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ startServiceExtensionAbility(want: Want, callback: AsyncCallback): void; @@ -1383,7 +1387,8 @@ export default class ServiceExtensionContext extends ExtensionContext { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi * @stagemodelonly - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ startServiceExtensionAbility(want: Want): Promise; @@ -1796,7 +1801,8 @@ export default class ServiceExtensionContext extends ExtensionContext { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi * @stagemodelonly - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ terminateSelf(callback: AsyncCallback): void; @@ -1825,7 +1831,8 @@ export default class ServiceExtensionContext extends ExtensionContext { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi * @stagemodelonly - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ terminateSelf(): Promise; @@ -2526,3 +2533,5 @@ export default class ServiceExtensionContext extends ExtensionContext { */ openAtomicService(appId: string, options?: AtomicServiceOptions): Promise; } + +export default ServiceExtensionContext; \ No newline at end of file diff --git a/api/application/UIAbilityContext.d.ts b/api/application/UIAbilityContext.d.ts index b0ff546dd7553bb75ba9a06ce34e60986d2a441e..73cf76d55b168a0b913a311699d98d8ba0e37a96 100644 --- a/api/application/UIAbilityContext.d.ts +++ b/api/application/UIAbilityContext.d.ts @@ -20,8 +20,6 @@ /*** if arkts 1.1 */ import { ConnectOptions } from '../ability/connectOptions'; -import { HapModuleInfo } from '../bundleManager/HapModuleInfo'; -import OpenLinkOptions from '../@ohos.app.ability.OpenLinkOptions'; import { Caller } from '../@ohos.app.ability.UIAbility'; import image from '../@ohos.multimedia.image'; import dialogRequest from '../@ohos.app.ability.dialogRequest'; @@ -36,6 +34,8 @@ import { AbilityInfo } from '../bundleManager/AbilityInfo'; import { AbilityResult } from '../ability/abilityResult'; import { AsyncCallback } from '../@ohos.base'; import Context from './Context'; +import { HapModuleInfo } from '../bundleManager/HapModuleInfo'; +import OpenLinkOptions from '../@ohos.app.ability.OpenLinkOptions'; import Want from '../@ohos.app.ability.Want'; import StartOptions from '../@ohos.app.ability.StartOptions'; import { Configuration } from '../@ohos.app.ability.Configuration'; @@ -125,7 +125,8 @@ declare class UIAbilityContext extends Context { * @stagemodelonly * @crossplatform * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ currentHapModuleInfo: HapModuleInfo; @@ -803,7 +804,8 @@ declare class UIAbilityContext extends Context { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ openLink(link: string, options?: OpenLinkOptions, callback?: AsyncCallback): Promise; @@ -2908,7 +2910,8 @@ declare class UIAbilityContext extends Context { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi * @stagemodelonly - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ startServiceExtensionAbility(want: Want, callback: AsyncCallback): void; @@ -2988,7 +2991,8 @@ declare class UIAbilityContext extends Context { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi * @stagemodelonly - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ startServiceExtensionAbility(want: Want): Promise; @@ -3892,7 +3896,8 @@ declare class UIAbilityContext extends Context { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly * @atomicservice - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ isTerminating(): boolean; @@ -4577,7 +4582,8 @@ declare class UIAbilityContext extends Context { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi * @stagemodelonly - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ requestModalUIExtension(pickerWant: Want, callback: AsyncCallback): void; @@ -4618,7 +4624,8 @@ declare class UIAbilityContext extends Context { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi * @stagemodelonly - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ requestModalUIExtension(pickerWant: Want): Promise; @@ -4657,7 +4664,8 @@ declare class UIAbilityContext extends Context { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ moveAbilityToBackground(): Promise; diff --git a/api/application/UIExtensionContext.d.ts b/api/application/UIExtensionContext.d.ts index c06fd20f13be2e209e758703095c5020f1f38124..9d577273b37f40c766095f5488f70a8639b25541 100755 --- a/api/application/UIExtensionContext.d.ts +++ b/api/application/UIExtensionContext.d.ts @@ -18,22 +18,23 @@ * @kit AbilityKit */ -/*** if arkts 1.2 */ -import { AbilityResult } from '../ability/abilityResult'; -/*** endif */ + import type { AsyncCallback } from '../@ohos.base'; import ExtensionContext from './ExtensionContext'; +import type Want from '../@ohos.app.ability.Want'; +import type StartOptions from '../@ohos.app.ability.StartOptions'; /*** if arkts 1.1 */ import type { AbilityResult } from '../ability/abilityResult'; import type { ConnectOptions } from '../ability/connectOptions'; -import type Want from '../@ohos.app.ability.Want'; -import type StartOptions from '../@ohos.app.ability.StartOptions'; import type AtomicServiceOptions from '../@ohos.app.ability.AtomicServiceOptions'; import OpenLinkOptions from '../@ohos.app.ability.OpenLinkOptions'; import type ConfigurationConstant from '../@ohos.app.ability.ConfigurationConstant'; import type UIServiceProxy from './UIServiceProxy'; import type UIServiceExtensionConnectCallback from './UIServiceExtensionConnectCallback'; /*** endif */ +/*** if arkts 1.2 */ +import { AbilityResult } from '../ability/abilityResult'; +/*** endif */ /** * The context of UI extension. It allows access to UIExtension-specific resources. @@ -153,7 +154,8 @@ declare class UIExtensionContext extends ExtensionContext { * @throws { BusinessError } 16200001 - The caller has been released. * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ startAbility(want: Want, callback: AsyncCallback): void; @@ -262,7 +264,8 @@ declare class UIExtensionContext extends ExtensionContext { * @throws { BusinessError } 16200001 - The caller has been released. * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ startAbility(want: Want, options: StartOptions, callback: AsyncCallback): void; @@ -377,7 +380,8 @@ declare class UIExtensionContext extends ExtensionContext { * @throws { BusinessError } 16200001 - The caller has been released. * @syscap SystemCapability.Ability.AbilityRuntime.Core * @stagemodelonly - * @since 14 + * @since arkts {'1.1':'14', '1.2':'20'} + * @arkts 1.1&1.2 */ startAbility(want: Want, options?: StartOptions): Promise; diff --git a/api/bundleManager/AppProvisionInfo.d.ts b/api/bundleManager/AppProvisionInfo.d.ts index 43351d69711788ef08b3eed30200afc995544215..98ed464fce7ebae2432c06aa1c0a48abd219d560 100644 --- a/api/bundleManager/AppProvisionInfo.d.ts +++ b/api/bundleManager/AppProvisionInfo.d.ts @@ -24,7 +24,8 @@ * @typedef AppProvisionInfo * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ export interface AppProvisionInfo { /** @@ -34,7 +35,8 @@ export interface AppProvisionInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly versionCode: number; @@ -45,7 +47,8 @@ export interface AppProvisionInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly versionName: string; @@ -56,7 +59,8 @@ export interface AppProvisionInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly uuid: string; @@ -67,7 +71,8 @@ export interface AppProvisionInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly type: string; @@ -78,7 +83,8 @@ export interface AppProvisionInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly appDistributionType: string; @@ -89,7 +95,8 @@ export interface AppProvisionInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly validity: Validity; @@ -100,7 +107,8 @@ export interface AppProvisionInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly developerId: string; @@ -111,7 +119,8 @@ export interface AppProvisionInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly certificate: string; @@ -122,7 +131,8 @@ export interface AppProvisionInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly apl: string; @@ -133,7 +143,8 @@ export interface AppProvisionInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly issuer: string; @@ -146,7 +157,8 @@ export interface AppProvisionInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly appIdentifier: string; @@ -157,7 +169,8 @@ export interface AppProvisionInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly organization: string; } @@ -168,7 +181,8 @@ export interface AppProvisionInfo { * @typedef Validity * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ export interface Validity { /** @@ -178,7 +192,8 @@ export interface Validity { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly notBefore: number; @@ -189,7 +204,8 @@ export interface Validity { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly notAfter: number; } diff --git a/api/bundleManager/BundlePackInfo.d.ts b/api/bundleManager/BundlePackInfo.d.ts index ad82c132717b4e4d43c0a72d438c8b39029e3789..e8ea4a275cc09f3759fafc4a4653de1eaef176d8 100644 --- a/api/bundleManager/BundlePackInfo.d.ts +++ b/api/bundleManager/BundlePackInfo.d.ts @@ -24,7 +24,8 @@ * @typedef BundlePackInfo * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ export interface BundlePackInfo { /** @@ -34,7 +35,8 @@ export interface BundlePackInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly packages: Array; @@ -45,7 +47,8 @@ export interface BundlePackInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly summary: PackageSummary; } @@ -56,7 +59,8 @@ export interface BundlePackInfo { * @typedef PackageConfig * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ export interface PackageConfig { /** @@ -66,7 +70,8 @@ export interface PackageConfig { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly deviceTypes: Array; @@ -77,7 +82,8 @@ export interface PackageConfig { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly name: string; @@ -88,7 +94,8 @@ export interface PackageConfig { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly moduleType: string; @@ -99,7 +106,8 @@ export interface PackageConfig { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly deliveryWithInstall: boolean; } @@ -110,7 +118,8 @@ export interface PackageConfig { * @typedef PackageSummary * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ export interface PackageSummary { /** @@ -120,7 +129,8 @@ export interface PackageSummary { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly app: BundleConfigInfo; @@ -131,7 +141,8 @@ export interface PackageSummary { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly modules: Array; } @@ -142,7 +153,8 @@ export interface PackageSummary { * @typedef BundleConfigInfo * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ export interface BundleConfigInfo { /** @@ -152,7 +164,8 @@ export interface BundleConfigInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly bundleName: string; @@ -163,7 +176,8 @@ export interface BundleConfigInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly version: Version; } @@ -174,7 +188,8 @@ export interface BundleConfigInfo { * @typedef ExtensionAbility * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ export interface ExtensionAbility { /** @@ -184,7 +199,8 @@ export interface ExtensionAbility { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly name: string; @@ -195,7 +211,8 @@ export interface ExtensionAbility { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly forms: Array; } @@ -206,7 +223,8 @@ export interface ExtensionAbility { * @typedef ModuleConfigInfo * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ export interface ModuleConfigInfo { /** @@ -216,7 +234,8 @@ export interface ModuleConfigInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly mainAbility: string; @@ -227,7 +246,8 @@ export interface ModuleConfigInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly apiVersion: ApiVersion; @@ -238,7 +258,8 @@ export interface ModuleConfigInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly deviceTypes: Array; @@ -249,7 +270,8 @@ export interface ModuleConfigInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly distro: ModuleDistroInfo; @@ -260,7 +282,8 @@ export interface ModuleConfigInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly abilities: Array; @@ -271,7 +294,8 @@ export interface ModuleConfigInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly extensionAbilities: Array; } @@ -282,7 +306,8 @@ export interface ModuleConfigInfo { * @typedef ModuleDistroInfo * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ export interface ModuleDistroInfo { /** @@ -292,7 +317,8 @@ export interface ModuleDistroInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly deliveryWithInstall: boolean; @@ -303,7 +329,8 @@ export interface ModuleDistroInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly installationFree: boolean; @@ -314,7 +341,8 @@ export interface ModuleDistroInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly moduleName: string; @@ -325,7 +353,8 @@ export interface ModuleDistroInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly moduleType: string; } @@ -336,7 +365,8 @@ export interface ModuleDistroInfo { * @typedef ModuleAbilityInfo * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ export interface ModuleAbilityInfo { /** @@ -346,7 +376,8 @@ export interface ModuleAbilityInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly name: string; @@ -357,7 +388,8 @@ export interface ModuleAbilityInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly label: string; @@ -368,7 +400,8 @@ export interface ModuleAbilityInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly exported: boolean; @@ -379,7 +412,8 @@ export interface ModuleAbilityInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly forms: Array; } @@ -390,7 +424,8 @@ export interface ModuleAbilityInfo { * @typedef AbilityFormInfo * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ export interface AbilityFormInfo { /** @@ -400,7 +435,8 @@ export interface AbilityFormInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly name: string; @@ -411,7 +447,8 @@ export interface AbilityFormInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly type: string; @@ -422,7 +459,8 @@ export interface AbilityFormInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly updateEnabled: boolean; @@ -433,7 +471,8 @@ export interface AbilityFormInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly scheduledUpdateTime: string; @@ -444,7 +483,8 @@ export interface AbilityFormInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly updateDuration: number; @@ -455,7 +495,8 @@ export interface AbilityFormInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly supportDimensions: Array; @@ -466,7 +507,8 @@ export interface AbilityFormInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly defaultDimension: string; } @@ -477,7 +519,8 @@ export interface AbilityFormInfo { * @typedef Version * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ export interface Version { /** @@ -487,7 +530,8 @@ export interface Version { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly minCompatibleVersionCode: number; @@ -498,7 +542,8 @@ export interface Version { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly name: string; @@ -509,7 +554,8 @@ export interface Version { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly code: number; } @@ -520,7 +566,8 @@ export interface Version { * @typedef ApiVersion * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ export interface ApiVersion { /** @@ -530,7 +577,8 @@ export interface ApiVersion { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly releaseType: string; @@ -541,7 +589,8 @@ export interface ApiVersion { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly compatible: number; @@ -552,7 +601,8 @@ export interface ApiVersion { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly target: number; } diff --git a/api/bundleManager/DispatchInfo.d.ts b/api/bundleManager/DispatchInfo.d.ts index 601b9d2382b6c4a14f44ddac3448faf59eb4c7af..779cc44c4e786af38cf0881243a44ab1190fc7fa 100644 --- a/api/bundleManager/DispatchInfo.d.ts +++ b/api/bundleManager/DispatchInfo.d.ts @@ -24,7 +24,8 @@ * @typedef DispatchInfo * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ export interface DispatchInfo { /** @@ -34,7 +35,8 @@ export interface DispatchInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly version: string; @@ -45,7 +47,8 @@ export interface DispatchInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.FreeInstall * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly dispatchAPIVersion: string; } diff --git a/api/bundleManager/LauncherAbilityInfo.d.ts b/api/bundleManager/LauncherAbilityInfo.d.ts index 5544a7347bb705468b9fa34a07da8d6cf2b65848..de21df51c03b956c2faaed879ddd7729fae0bf5b 100644 --- a/api/bundleManager/LauncherAbilityInfo.d.ts +++ b/api/bundleManager/LauncherAbilityInfo.d.ts @@ -26,7 +26,8 @@ import { ElementName } from './ElementName'; * * @typedef LauncherAbilityInfo * @syscap SystemCapability.BundleManager.BundleFramework.Launcher - * @since 18 + * @since arkts {'1.1':'18', '1.2':'20'} + * @arkts 1.1&1.2 */ export interface LauncherAbilityInfo { /** @@ -35,7 +36,8 @@ export interface LauncherAbilityInfo { * @type { ApplicationInfo } * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Launcher - * @since 18 + * @since arkts {'1.1':'18', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly applicationInfo: ApplicationInfo; @@ -45,7 +47,8 @@ export interface LauncherAbilityInfo { * @type { ElementName } * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Launcher - * @since 18 + * @since arkts {'1.1':'18', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly elementName: ElementName; @@ -55,7 +58,8 @@ export interface LauncherAbilityInfo { * @type { number } * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Launcher - * @since 18 + * @since arkts {'1.1':'18', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly labelId: number; @@ -65,7 +69,8 @@ export interface LauncherAbilityInfo { * @type { number } * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Launcher - * @since 18 + * @since arkts {'1.1':'18', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly iconId: number; @@ -75,7 +80,8 @@ export interface LauncherAbilityInfo { * @type { number } * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Launcher - * @since 18 + * @since arkts {'1.1':'18', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly userId: number; @@ -85,7 +91,8 @@ export interface LauncherAbilityInfo { * @type { number } * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Launcher - * @since 18 + * @since arkts {'1.1':'18', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly installTime: number; } diff --git a/api/bundleManager/LauncherAbilityResourceInfo.d.ts b/api/bundleManager/LauncherAbilityResourceInfo.d.ts index 0210a04e1b467f956a7717ee30cad93f1443537f..bd303e501a6dcd3b7f359dde00ac1bd6567f78a2 100644 --- a/api/bundleManager/LauncherAbilityResourceInfo.d.ts +++ b/api/bundleManager/LauncherAbilityResourceInfo.d.ts @@ -18,7 +18,9 @@ * @kit AbilityKit */ +/*** if arkts 1.1 */ import { DrawableDescriptor } from './../@ohos.arkui.drawableDescriptor'; +/*** endif */ /** * Obtains resource information about a launcher ability @@ -26,7 +28,8 @@ import { DrawableDescriptor } from './../@ohos.arkui.drawableDescriptor'; * @typedef LauncherAbilityResourceInfo * @syscap SystemCapability.BundleManager.BundleFramework.Resource * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ export interface LauncherAbilityResourceInfo { /** @@ -36,7 +39,8 @@ export interface LauncherAbilityResourceInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Resource * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly bundleName: string; @@ -47,7 +51,8 @@ export interface LauncherAbilityResourceInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Resource * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly moduleName: string; @@ -58,7 +63,8 @@ export interface LauncherAbilityResourceInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Resource * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly abilityName: string; @@ -69,7 +75,8 @@ export interface LauncherAbilityResourceInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Resource * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly icon: string; @@ -80,7 +87,8 @@ export interface LauncherAbilityResourceInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Resource * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly label: string; @@ -102,7 +110,8 @@ export interface LauncherAbilityResourceInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Resource * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly appIndex: number; } diff --git a/api/bundleManager/OverlayModuleInfo.d.ts b/api/bundleManager/OverlayModuleInfo.d.ts old mode 100755 new mode 100644 index 39621a9515cb6855e6344aaba8d768ef570b665c..aa2b660c735da319af4dd9fb5ce87de77e1713bc --- a/api/bundleManager/OverlayModuleInfo.d.ts +++ b/api/bundleManager/OverlayModuleInfo.d.ts @@ -23,7 +23,8 @@ * * @typedef OverlayModuleInfo * @syscap SystemCapability.BundleManager.BundleFramework.Core - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ export interface OverlayModuleInfo { /** @@ -32,7 +33,8 @@ export interface OverlayModuleInfo { * @type { string } * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Core - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly bundleName: string; @@ -42,7 +44,8 @@ export interface OverlayModuleInfo { * @type { string } * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Core - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly moduleName: string; @@ -52,7 +55,8 @@ export interface OverlayModuleInfo { * @type { string } * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Core - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly targetModuleName: string; @@ -62,7 +66,8 @@ export interface OverlayModuleInfo { * @type { number } * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Core - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly priority: number; @@ -72,7 +77,8 @@ export interface OverlayModuleInfo { * @type { number } * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Core - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly state: number; } diff --git a/api/bundleManager/PermissionDef.d.ts b/api/bundleManager/PermissionDef.d.ts index 6d6634bea9aabf9520a258799cb697c175521af9..4b93792ec675c1ebacd79a6152419828ff7e2631 100644 --- a/api/bundleManager/PermissionDef.d.ts +++ b/api/bundleManager/PermissionDef.d.ts @@ -24,7 +24,8 @@ * @typedef PermissionDef * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ export interface PermissionDef { /** @@ -34,7 +35,8 @@ export interface PermissionDef { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly permissionName: string; @@ -45,7 +47,8 @@ export interface PermissionDef { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly grantMode: number; @@ -56,7 +59,8 @@ export interface PermissionDef { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly labelId: number; @@ -67,7 +71,8 @@ export interface PermissionDef { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly descriptionId: number; } diff --git a/api/bundleManager/PluginBundleInfo.d.ts b/api/bundleManager/PluginBundleInfo.d.ts index d3bc13ecb843cb5ef97de64838d467dac0e63eee..40933b54af0cb31a4194857be225fb36ca3c593c 100644 --- a/api/bundleManager/PluginBundleInfo.d.ts +++ b/api/bundleManager/PluginBundleInfo.d.ts @@ -24,7 +24,8 @@ * @typedef PluginBundleInfo * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 19 + * @since arkts {'1.1':'19', '1.2':'20'} + * @arkts 1.1&1.2 */ export interface PluginBundleInfo { /** @@ -34,7 +35,8 @@ export interface PluginBundleInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 19 + * @since arkts {'1.1':'19', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly label: string; @@ -45,7 +47,8 @@ export interface PluginBundleInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 19 + * @since arkts {'1.1':'19', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly labelId: number; @@ -56,7 +59,8 @@ export interface PluginBundleInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 19 + * @since arkts {'1.1':'19', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly icon: string; @@ -67,7 +71,8 @@ export interface PluginBundleInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 19 + * @since arkts {'1.1':'19', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly iconId: number; @@ -78,7 +83,8 @@ export interface PluginBundleInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 19 + * @since arkts {'1.1':'19', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly pluginBundleName: string; @@ -89,7 +95,8 @@ export interface PluginBundleInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 19 + * @since arkts {'1.1':'19', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly versionCode: number; @@ -100,7 +107,8 @@ export interface PluginBundleInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 19 + * @since arkts {'1.1':'19', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly versionName: string; @@ -111,7 +119,8 @@ export interface PluginBundleInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 19 + * @since arkts {'1.1':'19', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly pluginModuleInfos: Array; } @@ -122,7 +131,8 @@ export interface PluginBundleInfo { * @typedef PluginModuleInfo * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 19 + * @since arkts {'1.1':'19', '1.2':'20'} + * @arkts 1.1&1.2 */ export interface PluginModuleInfo { /** @@ -132,7 +142,8 @@ export interface PluginModuleInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 19 + * @since arkts {'1.1':'19', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly moduleName: string; @@ -143,7 +154,8 @@ export interface PluginModuleInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 19 + * @since arkts {'1.1':'19', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly descriptionId: number; @@ -154,7 +166,8 @@ export interface PluginModuleInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 19 + * @since arkts {'1.1':'19', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly description: string; } \ No newline at end of file diff --git a/api/bundleManager/RecoverableApplicationInfo.d.ts b/api/bundleManager/RecoverableApplicationInfo.d.ts index 62b36b0eac89ca695f7b0fe81762180d208b8a60..29b78aed38c2ec1f43d096496f15c79d9fa534c7 100644 --- a/api/bundleManager/RecoverableApplicationInfo.d.ts +++ b/api/bundleManager/RecoverableApplicationInfo.d.ts @@ -26,7 +26,8 @@ import bundleManager from './../@ohos.bundle.bundleManager'; * @typedef RecoverableApplicationInfo * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ export interface RecoverableApplicationInfo { /** @@ -36,7 +37,8 @@ export interface RecoverableApplicationInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly bundleName: string; @@ -47,7 +49,8 @@ export interface RecoverableApplicationInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly moduleName: string; @@ -58,7 +61,8 @@ export interface RecoverableApplicationInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly labelId: number; @@ -69,7 +73,8 @@ export interface RecoverableApplicationInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 11 + * @since arkts {'1.1':'11', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly iconId: number; @@ -80,7 +85,8 @@ export interface RecoverableApplicationInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly systemApp: boolean; @@ -91,7 +97,8 @@ export interface RecoverableApplicationInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly bundleType: bundleManager.BundleType; @@ -102,7 +109,8 @@ export interface RecoverableApplicationInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly codePaths: Array; } diff --git a/api/bundleManager/RemoteAbilityInfo.d.ts b/api/bundleManager/RemoteAbilityInfo.d.ts index efd294bc3f887446a5136dc8408e2dc6a68bdb4e..217b88d0408fb5975a5980b2a84a9ce1d2911546 100644 --- a/api/bundleManager/RemoteAbilityInfo.d.ts +++ b/api/bundleManager/RemoteAbilityInfo.d.ts @@ -26,7 +26,8 @@ import { ElementName } from './ElementName'; * @typedef RemoteAbilityInfo * @syscap SystemCapability.BundleManager.DistributedBundleFramework * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ export interface RemoteAbilityInfo { /** @@ -36,7 +37,8 @@ export interface RemoteAbilityInfo { * @readonly * @syscap SystemCapability.BundleManager.DistributedBundleFramework * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly elementName: ElementName; @@ -47,7 +49,8 @@ export interface RemoteAbilityInfo { * @readonly * @syscap SystemCapability.BundleManager.DistributedBundleFramework * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly label: string; @@ -58,7 +61,8 @@ export interface RemoteAbilityInfo { * @readonly * @syscap SystemCapability.BundleManager.DistributedBundleFramework * @systemapi - * @since 9 + * @since arkts {'1.1':'9', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly icon: string; } diff --git a/api/bundleManager/SharedBundleInfo.d.ts b/api/bundleManager/SharedBundleInfo.d.ts index 3e8078810f795ae4566294206336dadaeeaa1252..4065fc39254595bcfdbc8e7ea2e1809b680a7b02 100644 --- a/api/bundleManager/SharedBundleInfo.d.ts +++ b/api/bundleManager/SharedBundleInfo.d.ts @@ -27,7 +27,8 @@ import bundleManager from '../@ohos.bundle.bundleManager'; * @typedef SharedBundleInfo * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ export interface SharedBundleInfo { /** @@ -37,7 +38,8 @@ export interface SharedBundleInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly name: string; @@ -48,7 +50,8 @@ export interface SharedBundleInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly compatiblePolicy: bundleManager.CompatiblePolicy; @@ -59,7 +62,8 @@ export interface SharedBundleInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly sharedModuleInfo: Array; } @@ -70,7 +74,8 @@ export interface SharedBundleInfo { * @typedef SharedModuleInfo * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ export interface SharedModuleInfo { /** @@ -80,7 +85,8 @@ export interface SharedModuleInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly name: string; @@ -91,7 +97,8 @@ export interface SharedModuleInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly versionCode: number; @@ -102,7 +109,8 @@ export interface SharedModuleInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly versionName: string; @@ -113,7 +121,8 @@ export interface SharedModuleInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly description: string; @@ -124,7 +133,8 @@ export interface SharedModuleInfo { * @readonly * @syscap SystemCapability.BundleManager.BundleFramework.Core * @systemapi - * @since 10 + * @since arkts {'1.1':'10', '1.2':'20'} + * @arkts 1.1&1.2 */ readonly descriptionId: number; } diff --git a/api/wantAgent/triggerInfo.d.ts b/api/wantAgent/triggerInfo.d.ts index 97daf1c0de1dffb5ac5a6270f56e5e71ef901f3b..b487d2f2f71243fbd1058d6a5f915983b9cd1f20 100644 --- a/api/wantAgent/triggerInfo.d.ts +++ b/api/wantAgent/triggerInfo.d.ts @@ -34,7 +34,8 @@ import StartOptions from '../@ohos.app.ability.StartOptions'; * @typedef TriggerInfo * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ export interface TriggerInfo { /** @@ -50,7 +51,8 @@ export interface TriggerInfo { * @type { number } * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ code: number; @@ -77,7 +79,8 @@ export interface TriggerInfo { * @type { ?Want } * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ want?: Want; @@ -98,7 +101,8 @@ export interface TriggerInfo { * @type { ?string } * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ permission?: string; @@ -119,6 +123,17 @@ export interface TriggerInfo { */ extraInfo?: { [key: string]: any }; + /** + * Custom extra data you want to add for triggering a WantAgent. + * + * @type { ?object } + * @syscap SystemCapability.Ability.AbilityRuntime.Core + * @atomicservice + * @since 20 + * @arkts 1.2 + */ + extraInfo?: Record; + /** * Custom extra data you want to add for triggering a WantAgent. * The ability of this property is same as extraInfo. If both are set, this property will be used. @@ -134,7 +149,8 @@ export interface TriggerInfo { * @type { ?Record } * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ extraInfos?: Record; @@ -145,7 +161,8 @@ export interface TriggerInfo { * @syscap SystemCapability.Ability.AbilityRuntime.Core * @systemapi * @stagemodelonly - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ startOptions?: StartOptions; } diff --git a/api/wantAgent/wantAgentInfo.d.ts b/api/wantAgent/wantAgentInfo.d.ts index baefab4368775e78ae4a9fd6f1a19294cfd14002..862c11200342264a640677ce74acf4ca0580adf6 100644 --- a/api/wantAgent/wantAgentInfo.d.ts +++ b/api/wantAgent/wantAgentInfo.d.ts @@ -19,9 +19,12 @@ */ import Want from '../@ohos.app.ability.Want'; +/*** if arkts 1.1 */ import wantAgent from '../@ohos.wantAgent'; +/*** endif */ import type abilityWantAgent from '../@ohos.app.ability.wantAgent'; + /** * Provides the information required for triggering a WantAgent. * @@ -35,7 +38,8 @@ import type abilityWantAgent from '../@ohos.app.ability.wantAgent'; * @typedef WantAgentInfo * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ export interface WantAgentInfo { /** @@ -51,7 +55,8 @@ export interface WantAgentInfo { * @type { Array } * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ wants: Array; @@ -89,7 +94,8 @@ export interface WantAgentInfo { * @type { ?abilityWantAgent.OperationType } * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ actionType?: abilityWantAgent.OperationType; @@ -144,7 +150,8 @@ export interface WantAgentInfo { * @type { ?Array } * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ actionFlags?: Array; @@ -167,6 +174,18 @@ export interface WantAgentInfo { */ extraInfo?: { [key: string]: any }; + /** + * Extra information about how the Want starts an ability. + * If there is no extra information to set, this constant can be left empty. + * + * @type { ?object } + * @syscap SystemCapability.Ability.AbilityRuntime.Core + * @atomicservice + * @since 20 + * @arkts 1.2 + */ + extraInfo?: Record; + /** * Extra information about how the Want starts an ability. * If there is no extra information to set, this constant can be left empty. @@ -184,7 +203,8 @@ export interface WantAgentInfo { * @type { ?Record } * @syscap SystemCapability.Ability.AbilityRuntime.Core * @atomicservice - * @since 12 + * @since arkts {'1.1':'12', '1.2':'20'} + * @arkts 1.1&1.2 */ extraInfos?: Record; } @@ -197,7 +217,6 @@ export interface WantAgentInfo { * @systemapi * @stagemodelonly * @since 20 - * @arkts 1.1&1.2 */ export interface LocalWantAgentInfo { /** @@ -208,7 +227,6 @@ export interface LocalWantAgentInfo { * @systemapi * @stagemodelonly * @since 20 - * @arkts 1.1&1.2 */ wants: Array; @@ -220,7 +238,6 @@ export interface LocalWantAgentInfo { * @systemapi * @stagemodelonly * @since 20 - * @arkts 1.1&1.2 */ operationType?: abilityWantAgent.OperationType; @@ -232,7 +249,6 @@ export interface LocalWantAgentInfo { * @systemapi * @stagemodelonly * @since 20 - * @arkts 1.1&1.2 */ requestCode: number; } diff --git a/arkui_transformer.py b/arkui_transformer.py index 0d00f1b74d9927acec37aaab6dc2df0be6e4567d..0f6919fd6e0a4127f2e6bfaa83d7606070e19c7e 100755 --- a/arkui_transformer.py +++ b/arkui_transformer.py @@ -30,6 +30,10 @@ def compile_package(options): nodejs = os.path.abspath(options.node_js) input_dir = os.path.abspath(options.input) output = os.path.abspath(options.output) + config_path = '' + if (len(options.config_path) > 0): + config_path = os.path.abspath(options.config_path) + custom_env = { 'PATH': f"{os.path.dirname(os.path.abspath(options.node_js))}:{os.environ.get('PATH')}", 'NODE_HOME': os.path.dirname(os.path.abspath(options.node_js)), @@ -38,7 +42,10 @@ def compile_package(options): process = subprocess.run([npm, "run", "compile:arkui"], env=custom_env, cwd=tool_path, shell=False) if os.path.exists(package_path): - p = subprocess.run([nodejs, package_path, "--input-dir", input_dir, "--target-dir", output], cwd=tool_path, shell=False) + if (len(config_path) > 0): + p = subprocess.run([nodejs, package_path, "--input-dir", input_dir, "--target-dir", output, "--config-path", config_path], cwd=tool_path, shell=False) + else: + p = subprocess.run([nodejs, package_path, "--input-dir", input_dir, "--target-dir", output], cwd=tool_path, shell=False) else: print("arkui_transformer: tool path does not exist") @@ -49,6 +56,7 @@ def main(): parser = argparse.ArgumentParser() parser.add_argument('--input', required=True) parser.add_argument('--output', required=True) + parser.add_argument('--config_path', required=False, default='') parser.add_argument('--source_root_dir', required=True) parser.add_argument('--npm-path', required=True) parser.add_argument('--node-js', required=True) diff --git a/build-tools/delete_systemapi_plugin.js b/build-tools/delete_systemapi_plugin.js index 82a3eb989a5102b1103f882faa8972c67afa36db..984f48874909dd8f1ea46c9d78c41d3219f1b020 100644 --- a/build-tools/delete_systemapi_plugin.js +++ b/build-tools/delete_systemapi_plugin.js @@ -327,6 +327,9 @@ function tsTransform(utFiles, callback) { isTransformer = false; } } + if (/\.static\.d\.ets$/.test(apiBaseName)) { + isTransformer = false; + } if (!isTransformer) { writeFile(url, content); return; diff --git a/build-tools/handleApiFiles.js b/build-tools/handleApiFiles.js index eab1ffd3d5402b502943092bada38394744dec1e..d12bbacff8753c2adba2d188ada21c0fcf5acc89 100755 --- a/build-tools/handleApiFiles.js +++ b/build-tools/handleApiFiles.js @@ -30,6 +30,15 @@ const DirType = { 'typeThree': 'noTagInEts2', }; +const NotNullFilePath = [ + 'api', + 'api/@internal/ets', + 'api/@internal/component/ets', + 'api/arkui/component', + 'arkts', + 'kits', +]; + const NOT_COPY_DIR = ['build-tools', '.git', '.gitee']; function isEtsFile(path) { @@ -103,6 +112,20 @@ function handleApiFiles(rootPath, type, output) { console.log('error===>', error); } } + if (type === DirType.typeTwo) { + NotNullFilePath.forEach((dir) => { + const outDir = path.join(output, dir); + if (!fs.existsSync(outDir)) { + fs.mkdirSync(outDir, { recursive: true }); + writeFile(path.join(outDir, '.keep'), ' '); + return; + } + const fileNames = fs.readdirSync(outDir); + if (fileNames.length === 0) { + writeFile(path.join(outDir, '.keep'), ' '); + } + }); + } } diff --git a/build-tools/intToNumber.js b/build-tools/intToNumber.js new file mode 100644 index 0000000000000000000000000000000000000000..37c448abb16d7c36c36df8c4a4998b10e802ed6f --- /dev/null +++ b/build-tools/intToNumber.js @@ -0,0 +1,490 @@ +/* + * 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. + */ + +const ts = require('typescript'); +const fs = require('fs'); +const path = require('path'); +const commander = require('commander'); + +const typeArray = ['long', 'double', 'int']; + +let inputDir = ''; +let outputDir = ''; +let jsDocContent = ''; +let tagDataList = []; + +function main() { + const program = new commander.Command(); + program + .name('intToNumber') + .version('0.0.1'); + program + .option('--path ', 'input path') + .option('--output ', 'output path') + .action((opts) => { + if (!opts.path || !opts.output) { + console.error('Error: Must provide --path and --output parameters'); + process.exit(1); + } + + // 将相对路径解析为绝对路径 + inputDir = path.resolve(opts.path); + outputDir = path.resolve(opts.output); + + // 检查输入目录是否存在 + if (!fs.existsSync(inputDir)) { + console.error(`Error: Input directory does not exist: ${inputDir}`); + process.exit(1); + } + + const apiUtFiles1 = []; + readFile(inputDir + '/api', apiUtFiles1); + readFile(inputDir + '/arkts', apiUtFiles1); + tsTransform(apiUtFiles1, recursionAstCallback); + const apiUtFiles2 = []; + readFile(outputDir + '/api', apiUtFiles2); + readFile(outputDir + '/arkts', apiUtFiles2); + tsTransform(apiUtFiles2, recursionAstCallback2); + + const jsDocUtFiles1 = []; + readFile(outputDir + '/api', jsDocUtFiles1); + readFile(outputDir + '/arkts', jsDocUtFiles1); + tsTransform(jsDocUtFiles1, parseJSDocCallback); + const jsDocUtFiles2 = []; + readFile(outputDir + '/api', jsDocUtFiles2); + readFile(outputDir + '/arkts', jsDocUtFiles2); + tsTransform(jsDocUtFiles2, parseJSDocCallback2); + }); + program.parse(process.argv); +} + +/** + * 读取目录下所有文件 + * @param {string} dir 文件目录 + * @param {Array} utFiles 所有文件 + */ +function readFile(dir, utFiles) { + try { + const files = fs.readdirSync(dir); + files.forEach((element) => { + if (element === 'build-tools') { + return; + } + const filePath = path.join(dir, element); + const status = fs.statSync(filePath); + if (status.isDirectory()) { + readFile(filePath, utFiles); + } else { + utFiles.push(filePath); + } + }); + } catch (e) { + console.error('Error reading files: ' + e.message); + } +} + + +/** + * 遍历所有文件进行处理 + * @param {Array} utFiles 所有文件 + * @param {recursionAstCallback} callback 回调函数 + */ +function tsTransform(utFiles, callback) { + utFiles.forEach((url) => { + let content = fs.readFileSync(url, 'utf-8'); + jsDocContent = content; + const apiBaseName = path.basename(url); + tagDataList = []; + if (/\.d\.ts/.test(apiBaseName) || /\.d\.ets/.test(apiBaseName)) { + const fileName = processFileName(url); + ts.transpileModule(content, { + compilerOptions: { + target: ts.ScriptTarget.ES2017, + }, + fileName: fileName, + transformers: { before: [callback(url)] } + }); + } else { + const outputPath = replaceInputDirWithOutputDir(url, inputDir, outputDir); + ensureDirectoryExists(outputPath); + fs.writeFileSync(outputPath, content); + } + }); +} + +/** + * 统一处理文件名称,修改后缀等 + * @param {string} filePath 文件路径 + * @returns {string} filename 文件名称 + */ +function processFileName(filePath) { + return path + .basename(filePath) + .replace(/\.d\.ts$/g, '.ts') + .replace(/\.d\.ets$/g, '.ets'); +} + +/** + * 每个文件处理签回调函数第一个 + * @callback recursionAstCallback + * @param {string} url 文件路径 + * @returns {Function} + */ +function recursionAstCallback(url) { + return (context) => { + return (sourceFile) => { + node = processVisitEachChild1(context, sourceFile); + const printer = ts.createPrinter({ newLine: ts.NewLineKind.LineFeed }); + const result = printer.printNode(ts.EmitHint.Unspecified, node, sourceFile); + const outputPath = replaceInputDirWithOutputDir(url, inputDir, outputDir); + ensureDirectoryExists(outputPath); + fs.writeFileSync(outputPath, result); + return ts.factory.createSourceFile([], ts.SyntaxKind.EndOfFileToken, ts.NodeFlags.None); + }; + }; +} + +/** + * 每个文件处理签回调函数第一个 + * @callback recursionAstCallback + * @param {string} url 文件路径 + * @returns {Function} + */ +function recursionAstCallback2(url) { + return (context) => { + return (sourceFile) => { + node = processVisitEachChild2(context, sourceFile); + const printer = ts.createPrinter({ newLine: ts.NewLineKind.LineFeed }); + const result = printer.printNode(ts.EmitHint.Unspecified, node, sourceFile); + fs.writeFileSync(url, result); + return ts.factory.createSourceFile([], ts.SyntaxKind.EndOfFileToken, ts.NodeFlags.None); + }; + }; +} + +/** + * 每个文件处理签回调函数第一个 + * @callback parseJSDocCallback + * @param {string} url 文件路径 + * @returns {Function} + */ +function parseJSDocCallback(url) { + return (context) => { + return (sourceFile) => { + node = parseJSDocVisitEachChild1(context, sourceFile); + changeContent(tagDataList); + fs.writeFileSync(url, jsDocContent); + return ts.factory.createSourceFile([], ts.SyntaxKind.EndOfFileToken, ts.NodeFlags.None); + }; + }; +} + +/** + * 每个文件处理签回调函数第一个 + * @callback parseJSDocCallback + * @param {string} url 文件路径 + * @returns {Function} + */ +function parseJSDocCallback2(url) { + return (context) => { + return (sourceFile) => { + const contents = fs.readFileSync(url, 'utf-8'); + node = parseJSDocVisitEachChild2(context, sourceFile, contents); + changeContent(tagDataList); + fs.writeFileSync(url, jsDocContent); + return ts.factory.createSourceFile([], ts.SyntaxKind.EndOfFileToken, ts.NodeFlags.None); + }; + }; +} + +/** + * 遍历处理tsnode节点 + * @param {context} 解下过后的内容 + * @param {node} 解下过后的节点 + * @returns ts.node + */ +function parseJSDocVisitEachChild1(context, node) { + return ts.visitEachChild(node, processAllNodes, context); + function processAllNodes(node) { + if (node.jsDoc) { + processAllNodesJSDoc(node.jsDoc); + } + return ts.visitEachChild(node, processAllNodes, context); + } + function jsDocNodeForeach(tags) { + tags.forEach(tag => { + if (!tag.typeExpression) { + return; + } + const typeExpr = tag.typeExpression; + const newTypeExpr = parseTypeExpr(typeExpr); + applJSDocTransformations(typeExpr.type, newTypeExpr, tagDataList); + }); + } + function processAllNodesJSDoc(jsDocNode) { + jsDocNode.forEach(doc => { + if (!doc.tags) { + return; + } + if (/(long|double|int)/g.test(doc.getText())) { + jsDocNodeForeach(doc.tags); + } + }); + } + function parseTypeExpr(typeExpr) { + let newTypeExpr = typeExpr; + if (typeExpr.type.kind === ts.SyntaxKind.JSDocNullableType) { + newTypeExpr = judgeKind(typeExpr.type); + } else { + newTypeExpr = parseTypeExpression(typeExpr.type); + } + return newTypeExpr; + } + function judgeKind(typeExprType) { + if (typeExprType.type.kind && typeExprType.type.kind === ts.SyntaxKind.ParenthesizedType) { + return parseTypeExpression(typeExprType.type.type); + } else { + return parseTypeExpression(typeExprType.type); + } + } + function parseTypeExpression(node) { + if (ts.isTypeReferenceNode(node) && ts.isIdentifier(node.typeName) && typeArray.includes(node.typeName.getText())) { + node = ts.factory.createKeywordTypeNode(ts.SyntaxKind.NumberKeyword); + } + return ts.visitEachChild(node, parseTypeExpression, context); + } +} + +/** + * + * @param {typeExpr} 原始typeExpr + * @param {newTypeExpr} 新typeExpr + * @param {content} 文本内容 + */ +function applJSDocTransformations(typeExpr, newTypeExpr, tagDataList) { + const printer = ts.createPrinter({ newLine: ts.NewLineKind.LineFeed }); + const finalContent = printer.printNode(ts.EmitHint.Unspecified, newTypeExpr); + if (finalContent.includes('number')) { + const data = { + pos: typeExpr.pos, + end: typeExpr.end, + convertedText: finalContent + }; + tagDataList.push(data); + } +} + +/** + * + * @param {typeExpr} 原始typeExpr + * @param {newTypeExpr} 新typeExpr + * @param {content} 文本内容 + */ +function changeContent(tagDataList) { + tagDataList.sort((a, b) => b.pos - a.pos); + for (const data of tagDataList) { + const before = jsDocContent.substring(0, data.pos); + const after = jsDocContent.substring(data.end); + jsDocContent = before + ` ${data.convertedText}` + after; + } +} + +/** + * 遍历处理tsnode节点 + * @param {context} 解下过后的内容 + * @param {node} 解下过后的节点 + * @returns ts.node + */ +function parseJSDocVisitEachChild2(context, node) { + return ts.visitEachChild(node, processAllNodes, context); + function processAllNodes(node) { + if (node.jsDoc) { + removeChangeData(node.jsDoc); + } + return ts.visitEachChild(node, processAllNodes, context); + } + function jsDocNodeForeach(tags) { + tags.forEach(tag => { + if (!tag.typeExpression) { + return; + } + writeDataToFile(tag); + }); + } + function removeChangeData(node) { + node.forEach(doc => { + if (!doc.tags) { + return; + } + jsDocNodeForeach(doc.tags); + }); + } + function writeDataToFile(tag) { + const typeExpr = tag.typeExpression; + const newTypeExpr = parseTypeExpression(typeExpr.type); + applJSDocTransformations(typeExpr.type, newTypeExpr, tagDataList); + } + function parseTypeExpression(node) { + if (ts.isUnionTypeNode(node)) { + const types = node.types; + const newTypes1 = []; + let newTypes2 = []; + types.forEach(type => { + newTypes1.push(collectNewTypes(type)); + }); + newTypes1.forEach(type => { + newTypes2 = duplicateRemoval(type); + }); + node = ts.factory.updateUnionTypeNode(node, newTypes2); + } + return ts.visitEachChild(node, parseTypeExpression, context); + } +} + + +/** + * @param {type} 需要去重的节点 + */ +function collectNewTypes(type) { + if (ts.isTypeReferenceNode(type) && ts.isIdentifier(type.typeName) && typeArray.includes(type.typeName.getText())) { + return ts.factory.createKeywordTypeNode(ts.SyntaxKind.NumberKeyword); + } else { + return type; + } +} + + +/** + * + * @param {type} 解析过后的节点 + * @returns + */ +function duplicateRemoval(type) { + let newTypes2 = []; + let hasNumberKeyWorld = false; + if (type.kind === ts.SyntaxKind.NumberKeyword) { + if (!hasNumberKeyWorld) { + newTypes2.push(type); + hasNumberKeyWorld = true; + } + } else { + newTypes2.push(type); + } + return newTypes2; +} + +/** + * 遍历处理tsnode节点 + * @param {context} 解下过后的内容 + * @param {node} 解下过后的节点 + * @returns ts.node + */ +function processVisitEachChild1(context, node) { + return ts.visitEachChild(node, processAllNodes, context); + function processAllNodes(node) { + if (ts.isTypeReferenceNode(node) && ts.isIdentifier(node.typeName) && typeArray.includes(node.typeName.getText())) { + node = ts.factory.createKeywordTypeNode(ts.SyntaxKind.NumberKeyword); + } + if (ts.isStructDeclaration(node)) { + node = processStructDeclaration(node); + } + return ts.visitEachChild(node, processAllNodes, context); + }; +} + +/** + * 处理struct子节点 + */ +function processStructDeclaration(node) { + const newMembers = []; + node.members.forEach((member, index) => { + if (index >= 1) { + newMembers.push(member); + } + }); + node = ts.factory.updateStructDeclaration( + node, + node.modifiers, + node.name, + node.typeParameters, + node.heritageClauses, + newMembers + ); + return node; +} + + +/** + * 遍历处理tsnode节点去重 + * @param {context} 解下过后的内容 + * @param {node} 解下过后的节点 + * @returns ts.node + */ +function processVisitEachChild2(context, node) { + const printer = ts.createPrinter({ newLine: ts.NewLineKind.LineFeed }); + return ts.visitEachChild(node, processAllNodes, context); + function processAllNodes(node) { + if (ts.isUnionTypeNode(node)) { + node = apiDuplicateRemoval(node); + } + if (ts.isStructDeclaration(node)) { + node = processStructDeclaration(node); + } + return ts.visitEachChild(node, processAllNodes, context); + }; + + function apiDuplicateRemoval(node) { + const types = node.types; + const newTypes = []; + const newTypesText = new Set([]); + types.forEach(type => { + const text = printer.printNode(ts.EmitHint.Unspecified, type); + if (!newTypesText.has(text)) { + newTypes.push(type); + newTypesText.add(text); + } + }); + node = ts.factory.updateUnionTypeNode(node, newTypes); + return node; + } +} + +/** + * 将输入路径替换为输出路径 + * @param {string} inputFilePath 输入文件的绝对路径 + * @param {string} inputDir 输入目录的绝对路径 + * @param {string} outputDir 输出目录的绝对路径 + * @returns {string} 输出文件的绝对路径 + */ +function replaceInputDirWithOutputDir(inputFilePath, inputDir, outputDir) { + return inputFilePath.replace(inputDir, outputDir); +} + +/** + * 确保目录结构存在,如果不存在则创建 + * @param {string} filePath 文件路径 + */ +function ensureDirectoryExists(filePath) { + try { + const dir = path.dirname(filePath); + if (!fs.existsSync(dir)) { + fs.mkdirSync(dir, { recursive: true }); + } + } catch (error) { + console.error(`Error creating directory: ${error.message}`); + } +} + +main(); \ No newline at end of file diff --git a/kits/@kit.AbilityKit.d.ts b/kits/@kit.AbilityKit.d.ts index f3a1822121372751c6c01270cc295f43e85bf75b..793da982bf730fb000530f2796de0677cc78220c 100644 --- a/kits/@kit.AbilityKit.d.ts +++ b/kits/@kit.AbilityKit.d.ts @@ -135,12 +135,20 @@ export { }; /*** if arkts 1.2 */ +import appControl from '@ohos.bundle.appControl'; import bundleManager from '@ohos.bundle.bundleManager'; +import bundleMonitor from '@ohos.bundle.bundleMonitor'; import bundleResourceManager from '@ohos.bundle.bundleResourceManager'; +import defaultAppManager from '@ohos.bundle.defaultAppManager'; +import distributedBundleManager from '@ohos.bundle.distributedBundleManager'; +import freeInstall from '@ohos.bundle.freeInstall'; +import installer from '@ohos.bundle.installer'; import launcherBundleManager from '@ohos.bundle.launcherBundleManager'; +import overlay from '@ohos.bundle.overlay'; import shortcutManager from '@ohos.bundle.shortcutManager'; export { - bundleManager, bundleResourceManager, launcherBundleManager, shortcutManager + appControl, bundleManager, bundleMonitor, bundleResourceManager, defaultAppManager, distributedBundleManager, + freeInstall, installer, launcherBundleManager, overlay, shortcutManager }; /*** endif */ diff --git a/kits/@kit.BasicServicesKit.d.ts b/kits/@kit.BasicServicesKit.d.ts index e53bf72584abd432a9b804956941685a459e88bf..dff33e1ea941250bea3ed8f2c5f2747d7b5be75c 100644 --- a/kits/@kit.BasicServicesKit.d.ts +++ b/kits/@kit.BasicServicesKit.d.ts @@ -87,3 +87,11 @@ export { StaticSubscriberExtensionContext, systemLoad, intelligentVoice, selectionManager, SelectionExtensionAbility, PanelInfo, PanelType }; + +/*** if arkts 1.2 */ +import zlib from '@ohos.zlib'; + +export { + zlib +}; +/*** endif */