diff --git a/api/@ohos.ability.errorCode.d.ts b/api/@ohos.ability.errorCode.d.ts
index bf6f1e727c9e094263d2a2759a2b13e80e4951d6..83418a702bb201adf2f760c34ef91791292029a8 100644
--- a/api/@ohos.ability.errorCode.d.ts
+++ b/api/@ohos.ability.errorCode.d.ts
@@ -23,14 +23,16 @@
*
* @enum { number }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
- * @since 6
+ * @since arkts {'1.1':'6', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
export enum ErrorCode {
/**
* Permission denied.
*
* @syscap SystemCapability.Ability.AbilityRuntime.Core
- * @since 6
+ * @since arkts {'1.1':'6', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
PERMISSION_DENY = -3,
@@ -38,7 +40,8 @@ export enum ErrorCode {
* Ability not found.
*
* @syscap SystemCapability.Ability.AbilityRuntime.Core
- * @since 6
+ * @since arkts {'1.1':'6', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
ABILITY_NOT_FOUND = -2,
@@ -46,7 +49,8 @@ export enum ErrorCode {
* Invalid parameter.
*
* @syscap SystemCapability.Ability.AbilityRuntime.Core
- * @since 6
+ * @since arkts {'1.1':'6', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
INVALID_PARAMETER = -1,
@@ -54,7 +58,8 @@ export enum ErrorCode {
* No error.
*
* @syscap SystemCapability.Ability.AbilityRuntime.Core
- * @since 6
+ * @since arkts {'1.1':'6', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
NO_ERROR = 0
}
diff --git a/api/@ohos.app.ability.Ability.d.ts b/api/@ohos.app.ability.Ability.d.ts
index 5c7161352dc0b708532ac2df525341ce198b56bd..64786d80b512b74f541644aefa09e1c4ead93478 100644
--- a/api/@ohos.app.ability.Ability.d.ts
+++ b/api/@ohos.app.ability.Ability.d.ts
@@ -18,10 +18,8 @@
* @kit AbilityKit
*/
-/*** if arkts 1.1 */
import AbilityConstant from './@ohos.app.ability.AbilityConstant';
import { Configuration } from './@ohos.app.ability.Configuration';
-/*** endif */
/**
* The class of an ability.
@@ -39,7 +37,7 @@ import { Configuration } from './@ohos.app.ability.Configuration';
* @since arkts {'1.1':'11', '1.2':'20'}
* @arkts 1.1&1.2
*/
-export default class Ability {
+declare class Ability {
/**
* Called when the system configuration is updated.
*
@@ -55,7 +53,8 @@ export default class Ability {
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @StageModelOnly
* @atomicservice
- * @since 11
+ * @since arkts{'1.1':'11', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
onConfigurationUpdate(newConfig: Configuration): void;
@@ -78,7 +77,10 @@ export default class Ability {
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @StageModelOnly
* @atomicservice
- * @since 11
+ * @since arkts{'1.1':'11', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
onMemoryLevel(level: AbilityConstant.MemoryLevel): void;
}
+
+export default Ability;
\ No newline at end of file
diff --git a/api/@ohos.app.ability.AbilityConstant.d.ts b/api/@ohos.app.ability.AbilityConstant.d.ts
index 7cb205beed24e2286e4b9ffa2ae4071cc98ed116..6e9cebcddabd7725cf9a169b1a81fc81e0857e84 100644
--- a/api/@ohos.app.ability.AbilityConstant.d.ts
+++ b/api/@ohos.app.ability.AbilityConstant.d.ts
@@ -204,14 +204,14 @@ declare namespace AbilityConstant {
/**
* ID of the process where the ability is running when it exits last time.
*
- * @type { number }
+ * @type { int }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @stagemodelonly
* @atomicservice
* @since arkts {'1.1':'18', '1.2':'20'}
* @arkts 1.1&1.2
*/
- pid: number;
+ pid: int;
/**
* Name of the process.
@@ -228,26 +228,26 @@ declare namespace AbilityConstant {
/**
* UID of the application.
*
- * @type { number }
+ * @type { int }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @stagemodelonly
* @atomicservice
* @since arkts {'1.1':'18', '1.2':'20'}
* @arkts 1.1&1.2
*/
- uid: number;
+ uid: int;
/**
* Specific reason for the last exit of the ability.
*
- * @type { number }
+ * @type { int }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @stagemodelonly
* @atomicservice
* @since arkts {'1.1':'18', '1.2':'20'}
* @arkts 1.1&1.2
*/
- exitSubReason: number;
+ exitSubReason: int;
/**
* Reason why the process was killed.
@@ -264,38 +264,38 @@ declare namespace AbilityConstant {
/**
* RSS value of the process.
*
- * @type { number }
+ * @type { int }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @stagemodelonly
* @atomicservice
* @since arkts {'1.1':'18', '1.2':'20'}
* @arkts 1.1&1.2
*/
- rss: number;
+ rss: int;
/**
* PSS value of the process.
*
- * @type { number }
+ * @type { int }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @stagemodelonly
* @atomicservice
* @since arkts {'1.1':'18', '1.2':'20'}
* @arkts 1.1&1.2
*/
- pss: number;
+ pss: int;
/**
* Exact time when the ability last exits.
*
- * @type { number }
+ * @type { long }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @stagemodelonly
* @atomicservice
* @since arkts {'1.1':'18', '1.2':'20'}
* @arkts 1.1&1.2
*/
- timestamp: number;
+ timestamp: long;
/**
* The process state when the process exits.
diff --git a/api/@ohos.app.ability.ApplicationStateChangeCallback.d.ts b/api/@ohos.app.ability.ApplicationStateChangeCallback.d.ts
index 18504ab7ef9499cfcdad1748bbb21574adb66679..2bcbc1885c28151f6e50321272f74ee1ce7866be 100644
--- a/api/@ohos.app.ability.ApplicationStateChangeCallback.d.ts
+++ b/api/@ohos.app.ability.ApplicationStateChangeCallback.d.ts
@@ -18,6 +18,7 @@
* @kit AbilityKit
*/
+/*** if arkts 1.1 */
/**
* The application state change callback.
*
@@ -43,6 +44,39 @@
* @since 18
*/
export default class ApplicationStateChangeCallback {
+/*** endif */
+
+/*** if arkts 1.2 */
+/**
+ * The application state change callback.
+ *
+ * @typedef ApplicationStateChangeCallback
+ * @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
+ * @StageModelOnly
+ * @since 10
+ */
+/**
+ * The application state change callback.
+ *
+ * @typedef ApplicationStateChangeCallback
+ * @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
+ * @StageModelOnly
+ * @atomicservice
+ * @since 11
+ */
+/**
+ * The application state change callback.
+ *
+ * @typedef ApplicationStateChangeCallback
+ * @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
+ * @StageModelOnly
+ * @crossplatform
+ * @atomicservice
+ * @since 20
+ * @arkts 1.2
+ */
+declare interface ApplicationStateChangeCallback {
+/*** endif */
/**
* Called back when the state of the application changes to foreground.
*
@@ -65,7 +99,8 @@ export default class ApplicationStateChangeCallback {
* @StageModelOnly
* @crossplatform
* @atomicservice
- * @since 18
+ * @since arkts {'1.1':'18', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
onApplicationForeground(): void;
@@ -91,7 +126,12 @@ export default class ApplicationStateChangeCallback {
* @StageModelOnly
* @crossplatform
* @atomicservice
- * @since 18
+ * @since arkts {'1.1':'18', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
onApplicationBackground(): void;
}
+
+/*** if arkts 1.2 */
+export default ApplicationStateChangeCallback;
+/*** endif */
\ No newline at end of file
diff --git a/api/@ohos.app.ability.AtomicServiceOptions.d.ts b/api/@ohos.app.ability.AtomicServiceOptions.d.ts
index 9168a95e277acd57828d82cda8ff058518f902e3..11e0f24b8c577f79578e530497cb87669a0c9589 100644
--- a/api/@ohos.app.ability.AtomicServiceOptions.d.ts
+++ b/api/@ohos.app.ability.AtomicServiceOptions.d.ts
@@ -27,19 +27,21 @@ import StartOptions from './@ohos.app.ability.StartOptions';
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @stagemodelonly
* @atomicservice
- * @since 12
+ * @since arkts {'1.1':'12', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
export default class AtomicServiceOptions extends StartOptions {
/**
* The options of the flags in this AtomicServiceOptions.
*
- * @type { ?number }
+ * @type { ?int }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @stagemodelonly
* @atomicservice
- * @since 12
+ * @since arkts {'1.1':'12', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
- flags?: number;
+ flags?: int;
/**
* The description of the WantParams object in an AtomicServiceOptions
@@ -48,7 +50,8 @@ export default class AtomicServiceOptions extends StartOptions {
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @stagemodelonly
* @atomicservice
- * @since 12
+ * @since arkts {'1.1':'12', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
parameters?: Record;
}
\ No newline at end of file
diff --git a/api/@ohos.app.ability.ChildProcessArgs.d.ts b/api/@ohos.app.ability.ChildProcessArgs.d.ts
index 95fbe68e3cbd751a535a66bc4dfb238e6b867bfc..dd2473aedff9281922acccf109dfdde9a2d0fb5b 100644
--- a/api/@ohos.app.ability.ChildProcessArgs.d.ts
+++ b/api/@ohos.app.ability.ChildProcessArgs.d.ts
@@ -41,10 +41,10 @@ export interface ChildProcessArgs {
/**
* Indicates file descriptors that use to communicate between two processes.
*
- * @type { ?Record }
+ * @type { ?Record }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @stagemodelonly
* @since 12
*/
- fds?: Record;
+ fds?: Record;
}
\ No newline at end of file
diff --git a/api/@ohos.app.ability.Configuration.d.ts b/api/@ohos.app.ability.Configuration.d.ts
index e8139c14bc5cfb41c8e5788bb1948de0cb78e1d2..94322a7f338c7a43467efbac407e0cfaded4da79 100644
--- a/api/@ohos.app.ability.Configuration.d.ts
+++ b/api/@ohos.app.ability.Configuration.d.ts
@@ -164,13 +164,13 @@ export interface Configuration {
/**
* Indicates the displayId of the current device.
*
- * @type { ?number }
+ * @type { ?long }
* @syscap SystemCapability.Ability.AbilityBase
* @atomicservice
* @since arkts {'1.1':'11', '1.2':'20'}
* @arkts 1.1&1.2
*/
- displayId?: number;
+ displayId?: long;
/**
* Indicates whether a pointer type device has connected.
@@ -211,25 +211,25 @@ export interface Configuration {
/**
* Indicates the font size scale.
*
- * @type { ?number }
+ * @type { ?double }
* @syscap SystemCapability.Ability.AbilityBase
* @crossplatform
* @atomicservice
* @since arkts {'1.1':'18', '1.2':'20'}
* @arkts 1.1&1.2
*/
- fontSizeScale?: number;
+ fontSizeScale?: double;
/**
* Indicates the font weight scale.
*
- * @type { ?number }
+ * @type { ?double }
* @syscap SystemCapability.Ability.AbilityBase
* @atomicservice
* @since arkts {'1.1':'12', '1.2':'20'}
* @arkts 1.1&1.2
*/
- fontWeightScale?: number;
+ fontWeightScale?: double;
/**
* Indicates the mobile country code.
diff --git a/api/@ohos.app.ability.EnvironmentCallback.d.ts b/api/@ohos.app.ability.EnvironmentCallback.d.ts
index 7eaea804e905e5eeac25c1362c9b40743843305f..9f5a4b9013c2287b8169a418a834a043fbc281ed 100644
--- a/api/@ohos.app.ability.EnvironmentCallback.d.ts
+++ b/api/@ohos.app.ability.EnvironmentCallback.d.ts
@@ -21,6 +21,7 @@
import AbilityConstant from './@ohos.app.ability.AbilityConstant';
import { Configuration } from './@ohos.app.ability.Configuration';
+/*** if arkts 1.1 */
/**
* The environment callback.
*
@@ -35,6 +36,27 @@ import { Configuration } from './@ohos.app.ability.Configuration';
* @since 11
*/
export default class EnvironmentCallback {
+/*** endif */
+
+/*** if arkts 1.2 */
+/**
+ * The environment callback.
+ *
+ * @typedef EnvironmentCallback
+ * @syscap SystemCapability.Ability.AbilityRuntime.Core
+ * @since 9
+ */
+/**
+ * The environment callback.
+ *
+ * @typedef EnvironmentCallback
+ * @syscap SystemCapability.Ability.AbilityRuntime.Core
+ * @atomicservice
+ * @since 20
+ * @arkts 1.2
+ */
+declare interface EnvironmentCallback {
+/*** endif */
/**
* Called when the system configuration is updated.
*
@@ -50,7 +72,8 @@ export default class EnvironmentCallback {
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @StageModelOnly
* @atomicservice
- * @since 11
+ * @since arkts {'1.1':'11', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
onConfigurationUpdated(config: Configuration): void;
@@ -71,7 +94,12 @@ export default class EnvironmentCallback {
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @StageModelOnly
* @atomicservice
- * @since 11
+ * @since arkts {'1.1':'11', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
onMemoryLevel(level: AbilityConstant.MemoryLevel): void;
}
+
+/*** if arkts 1.2 */
+export default EnvironmentCallback;
+/*** endif */
\ No newline at end of file
diff --git a/api/@ohos.app.ability.InsightIntentContext.d.ts b/api/@ohos.app.ability.InsightIntentContext.d.ts
index 89e087146f0fe30a9a60e21849c2ada767e3b3e0..d60333a7279cc3735f0d4dd6327c022ebb92ac56 100644
--- a/api/@ohos.app.ability.InsightIntentContext.d.ts
+++ b/api/@ohos.app.ability.InsightIntentContext.d.ts
@@ -57,7 +57,8 @@ declare class InsightIntentContext {
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @StageModelOnly
* @atomicservice
- * @since 11
+ * @since arkts {'1.1':'11', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
startAbility(want: Want, callback: AsyncCallback): void;
@@ -87,7 +88,8 @@ declare class InsightIntentContext {
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @StageModelOnly
* @atomicservice
- * @since 11
+ * @since arkts {'1.1':'11', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
startAbility(want: Want): Promise;
}
diff --git a/api/@ohos.app.ability.ServiceExtensionAbility.d.ts b/api/@ohos.app.ability.ServiceExtensionAbility.d.ts
index 9fb19d970b90c60f6b803e15176137b68f65b738..11b9aeb82a3a4d20fe94efb04a4c85635cb6dcc9 100644
--- a/api/@ohos.app.ability.ServiceExtensionAbility.d.ts
+++ b/api/@ohos.app.ability.ServiceExtensionAbility.d.ts
@@ -72,7 +72,7 @@ declare class ServiceExtensionAbility {
* Called back when a service extension is started.
*
* @param { Want } want - Indicates the want of service extension to start.
- * @param { number } startId - Indicates the number of times the service extension has been started.
+ * @param { int } startId - Indicates the number of times the service extension has been started.
* The {@code startId} is incremented by 1 every time the service extension is started.
* For example, if the service extension has been started for six times.
* @syscap SystemCapability.Ability.AbilityRuntime.Core
@@ -81,7 +81,7 @@ declare class ServiceExtensionAbility {
* @since arkts {'1.1':'9', '1.2':'20'}
* @arkts 1.1&1.2
*/
- onRequest(want: Want, startId: number): void;
+ onRequest(want: Want, startId: int): void;
/**
* Called back when a service extension is first connected to an ability.
@@ -169,7 +169,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
*/
onDump(params: Array): Array;
}
diff --git a/api/@ohos.app.ability.StartOptions.d.ts b/api/@ohos.app.ability.StartOptions.d.ts
index 662b8f961f7c778673842f49d8fb00e704150497..fa2ed142893f8f0259389b9d78aec0b63dfd8b85 100644
--- a/api/@ohos.app.ability.StartOptions.d.ts
+++ b/api/@ohos.app.ability.StartOptions.d.ts
@@ -48,13 +48,13 @@ export default class StartOptions {
* {@link ohos.app.ability.AbilityConstant#WindowMode.WINDOW_MODE_SPLIT_SECONDARY} are
* valid only in intra-app redirection scenarios.
*
- * @type { ?number }
+ * @type { ?int }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @stagemodelonly
* @since arkts {'1.1':'12', '1.2':'20'}
* @arkts 1.1&1.2
*/
- windowMode?: number;
+ windowMode?: int;
/**
* The type of displayId
@@ -67,14 +67,14 @@ export default class StartOptions {
/**
* The type of displayId
*
- * @type { ?number }
+ * @type { ?long }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @stagemodelonly
* @atomicservice
* @since arkts {'1.1':'11', '1.2':'20'}
* @arkts 1.1&1.2
*/
- displayId?: number;
+ displayId?: long;
/**
* The target ability with animation or without
@@ -90,46 +90,46 @@ export default class StartOptions {
/**
* The left position of window rectangle
*
- * @type { ?number }
+ * @type { ?int }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @stagemodelonly
* @since arkts {'1.1':'11', '1.2':'20'}
* @arkts 1.1&1.2
*/
- windowLeft?: number;
+ windowLeft?: int;
/**
* The top position of window rectangle
*
- * @type { ?number }
+ * @type { ?int }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @stagemodelonly
* @since arkts {'1.1':'11', '1.2':'20'}
* @arkts 1.1&1.2
*/
- windowTop?: number;
+ windowTop?: int;
/**
* The width of window rectangle
*
- * @type { ?number }
+ * @type { ?int }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @stagemodelonly
* @since arkts {'1.1':'11', '1.2':'20'}
* @arkts 1.1&1.2
*/
- windowWidth?: number;
+ windowWidth?: int;
/**
* The height of window rectangle
*
- * @type { ?number }
+ * @type { ?int }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @stagemodelonly
* @since arkts {'1.1':'11', '1.2':'20'}
* @arkts 1.1&1.2
*/
- windowHeight?: number;
+ windowHeight?: int;
/**
* Indicates the cold startup window is focused.
@@ -205,46 +205,46 @@ export default class StartOptions {
/**
* The min width of window rectangle.
*
- * @type { ?number }
+ * @type { ?int }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @stagemodelonly
* @since arkts{ '1.1':'17','1.2':'20'}
* @arkts 1.1&1.2
*/
- minWindowWidth?: number;
+ minWindowWidth?: int;
/**
* The min height of window rectangle.
*
- * @type { ?number }
+ * @type { ?int }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @stagemodelonly
* @since arkts{ '1.1':'17','1.2':'20'}
* @arkts 1.1&1.2
*/
- minWindowHeight?: number;
+ minWindowHeight?: int;
/**
* The max width of window rectangle.
*
- * @type { ?number }
+ * @type { ?int }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @stagemodelonly
* @since arkts{ '1.1':'17','1.2':'20'}
* @arkts 1.1&1.2
*/
- maxWindowWidth?: number;
+ maxWindowWidth?: int;
/**
* The max height of window rectangle.
*
- * @type { ?number }
+ * @type { ?int }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @stagemodelonly
* @since arkts{ '1.1':'17','1.2':'20'}
* @arkts 1.1&1.2
*/
- maxWindowHeight?: number;
+ maxWindowHeight?: int;
/**
* The completion handler of StartAbility.
diff --git a/api/@ohos.app.ability.UIAbility.d.ts b/api/@ohos.app.ability.UIAbility.d.ts
index 0f6b0cc85f1d5fca88808914a80d3012d258835d..fc62562a60ad334d5dff279dcd600dc0947604a4 100644
--- a/api/@ohos.app.ability.UIAbility.d.ts
+++ b/api/@ohos.app.ability.UIAbility.d.ts
@@ -823,7 +823,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
*/
onDump(params: Array): Array;
diff --git a/api/@ohos.app.ability.UIExtensionContentSession.d.ts b/api/@ohos.app.ability.UIExtensionContentSession.d.ts
index 8f9f41357a03236a59e4d0d3d10c8bcd15b9d098..4a0bd9c5612d8ecbca991e55d71f9e405806806e 100644
--- a/api/@ohos.app.ability.UIExtensionContentSession.d.ts
+++ b/api/@ohos.app.ability.UIExtensionContentSession.d.ts
@@ -19,7 +19,6 @@
*/
/*** if arkts 1.1 */
-import type AbilityStartCallback from './application/AbilityStartCallback';
import type Want from './@ohos.app.ability.Want';
import type StartOptions from './@ohos.app.ability.StartOptions';
import type uiExtension from './@ohos.arkui.uiExtension';
@@ -27,6 +26,7 @@ import type { AbilityResult } from './ability/abilityResult';
/*** endif */
import type { AsyncCallback } from './@ohos.base';
import type uiExtensionHost from './@ohos.uiExtensionHost';
+import type AbilityStartCallback from './application/AbilityStartCallback';
/*** if arkts 1.2 */
import { AbilityResult } from './ability/abilityResult';
import { LocalStorage } from '@ohos.arkui.stateManagement';
@@ -587,7 +587,8 @@ declare class UIExtensionContentSession {
* @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
*/
startAbilityByType(type: string, wantParam: Record,
abilityStartCallback: AbilityStartCallback, callback: AsyncCallback): void;
@@ -626,7 +627,8 @@ declare class UIExtensionContentSession {
* @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
*/
startAbilityByType(type: string, wantParam: Record,
abilityStartCallback: AbilityStartCallback): Promise;
diff --git a/api/@ohos.app.ability.Want.d.ts b/api/@ohos.app.ability.Want.d.ts
index ae262892e81296f6f3d3ab4e9df5b957d738e20d..3f97d2f34cfd195d3061e8bc90abcce50481422e 100644
--- a/api/@ohos.app.ability.Want.d.ts
+++ b/api/@ohos.app.ability.Want.d.ts
@@ -190,12 +190,12 @@ export default class Want {
* For example, wantConstant.Flags.FLAG_ABILITY_CONTINUATION specifies whether to start the ability in cross-device
* migration scenarios.
*
- * @type { ?number }
+ * @type { ?int }
* @syscap SystemCapability.Ability.AbilityBase
* @atomicservice
* @since 11
*/
- flags?: number;
+ flags?: int;
/**
* The description of an action in an want.
@@ -358,12 +358,12 @@ export default class Want {
* You can obtain the FD from fs.open. When the FD is no longer needed, you must call fs.close to destroy the FD in a
* timely manner to prevent FD leakage.
*
- * @type { ?Record }
+ * @type { ?Record }
* @readonly
* @syscap SystemCapability.Ability.AbilityBase
* @atomicservice
* @since arkts {'1.1':'15', '1.2':'20'}
* @arkts 1.1&1.2
*/
- readonly fds?: Record;
+ readonly fds?: Record;
}
diff --git a/api/@ohos.app.ability.abilityManager.d.ts b/api/@ohos.app.ability.abilityManager.d.ts
index ad7c405cd42591525ae79545115a978980321f7e..0283fc91a2a9b141c5b1ebefdfbda00f992523f9 100644
--- a/api/@ohos.app.ability.abilityManager.d.ts
+++ b/api/@ohos.app.ability.abilityManager.d.ts
@@ -20,16 +20,17 @@
import { AsyncCallback } from './@ohos.base';
import { ElementName } from './bundleManager/ElementName';
+import { AbilityRunningInfo as _AbilityRunningInfo } from './application/AbilityRunningInfo';
+import { ExtensionRunningInfo as _ExtensionRunningInfo } from './application/ExtensionRunningInfo';
+import Context from './application/Context';
/*** 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 * as _AbilityForegroundStateObserver from './application/AbilityForegroundStateObserver';
import * as _AbilityStateData from './application/AbilityStateData';
/*** endif */
/*** if arkts 1.2 */
+import _AbilityForegroundStateObserver from './application/AbilityForegroundStateObserver';
import _AbilityStateData from './application/AbilityStateData';
/*** endif */
@@ -55,14 +56,16 @@ declare namespace abilityManager {
*
* @enum { number }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
- * @since 14
+ * @since arkts {'1.1':'14', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
export enum AbilityState {
/**
* Ability is initialized.
*
* @syscap SystemCapability.Ability.AbilityRuntime.Core
- * @since 14
+ * @since arkts {'1.1':'14', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
INITIAL = 0,
@@ -70,7 +73,8 @@ declare namespace abilityManager {
* Ability is in the state of getting focus.
*
* @syscap SystemCapability.Ability.AbilityRuntime.Core
- * @since 14
+ * @since arkts {'1.1':'14', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
FOCUS = 2,
@@ -78,7 +82,8 @@ declare namespace abilityManager {
* Ability is in the foreground state.
*
* @syscap SystemCapability.Ability.AbilityRuntime.Core
- * @since 14
+ * @since arkts {'1.1':'14', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
FOREGROUND = 9,
@@ -86,7 +91,8 @@ declare namespace abilityManager {
* Ability is in the background state.
*
* @syscap SystemCapability.Ability.AbilityRuntime.Core
- * @since 14
+ * @since arkts {'1.1':'14', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
BACKGROUND = 10,
@@ -94,7 +100,8 @@ declare namespace abilityManager {
* Ability is in the process of scheduling at the foreground.
*
* @syscap SystemCapability.Ability.AbilityRuntime.Core
- * @since 14
+ * @since arkts {'1.1':'14', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
FOREGROUNDING = 11,
@@ -102,7 +109,8 @@ declare namespace abilityManager {
* Ability is in the process of scheduling in the background.
*
* @syscap SystemCapability.Ability.AbilityRuntime.Core
- * @since 14
+ * @since arkts {'1.1':'14', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
BACKGROUNDING = 12
}
@@ -114,7 +122,8 @@ declare namespace abilityManager {
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @systemapi
* @stagemodelonly
- * @since 12
+ * @since arkts {'1.1':'12', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
export enum UserStatus {
/**
@@ -123,7 +132,8 @@ declare namespace abilityManager {
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @systemapi
* @stagemodelonly
- * @since 12
+ * @since arkts {'1.1':'12', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
ASSERT_TERMINATE = 0,
@@ -133,7 +143,8 @@ declare namespace abilityManager {
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @systemapi
* @stagemodelonly
- * @since 12
+ * @since arkts {'1.1':'12', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
ASSERT_CONTINUE = 1,
@@ -143,7 +154,8 @@ declare namespace abilityManager {
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @systemapi
* @stagemodelonly
- * @since 12
+ * @since arkts {'1.1':'12', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
ASSERT_RETRY = 2
}
@@ -192,7 +204,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 on(type: 'abilityForegroundState', observer: AbilityForegroundStateObserver): void;
@@ -209,7 +222,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 off(type: 'abilityForegroundState', observer?: AbilityForegroundStateObserver): void;
@@ -255,7 +269,8 @@ declare namespace abilityManager {
* @returns { Promise> } Returns the array of AbilityRunningInfo.
* @throws { BusinessError } 16000050 - Internal error.
* @syscap SystemCapability.Ability.AbilityRuntime.Core
- * @since 14
+ * @since arkts {'1.1':'14', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
function getAbilityRunningInfos(): Promise>;
@@ -272,7 +287,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 getAbilityRunningInfos(callback: AsyncCallback>): void;
@@ -281,7 +297,7 @@ declare namespace abilityManager {
* obtain information about the current extension.
*
* @permission ohos.permission.GET_RUNNING_INFO
- * @param { number } upperLimit - Get the maximum limit of the number of messages.
+ * @param { int } upperLimit - Get the maximum limit of the number of messages.
* @returns { Promise> } Returns the array of ExtensionRunningInfo.
* @throws { BusinessError } 202 - Not system application.
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
@@ -291,14 +307,14 @@ declare namespace abilityManager {
* @systemapi
* @since 9
*/
- function getExtensionRunningInfos(upperLimit: number): Promise>;
+ function getExtensionRunningInfos(upperLimit: int): Promise>;
/**
* If you apply for permission, you can obtain information about all extensions. If you do not apply, you can only
* obtain information about the current extension.
*
* @permission ohos.permission.GET_RUNNING_INFO
- * @param { number } upperLimit - Get the maximum limit of the number of messages.
+ * @param { int } upperLimit - Get the maximum limit of the number of messages.
* @param { AsyncCallback> } callback - The callback is used to return the array of
* ExtensionRunningInfo.
* @throws { BusinessError } 202 - Not system application.
@@ -309,7 +325,7 @@ declare namespace abilityManager {
* @systemapi
* @since 9
*/
- function getExtensionRunningInfos(upperLimit: number, callback: AsyncCallback>): void;
+ function getExtensionRunningInfos(upperLimit: int, callback: AsyncCallback>): void;
/**
* Get the top ability information of the display.
@@ -356,7 +372,7 @@ declare namespace abilityManager {
/**
* Acquire the shared data from target ability.
*
- * @param { number } missionId - The missionId of target ability.
+ * @param { int } missionId - The missionId of target ability.
* @param { AsyncCallback> } callback - The callback is used to return the params of sharing
* data and result code.
* @throws { BusinessError } 202 - Not system application.
@@ -367,7 +383,7 @@ declare namespace abilityManager {
* @systemapi
* @since 11
*/
- function acquireShareData(missionId: number, callback: AsyncCallback>): void;
+ function acquireShareData(missionId: int, callback: AsyncCallback>): void;
/**
* Acquire the shared data from target ability.
@@ -385,7 +401,7 @@ declare namespace abilityManager {
/**
* Acquire the shared data from target ability.
*
- * @param { number } missionId - The missionId of target ability.
+ * @param { int } missionId - The missionId of target ability.
* @returns { Promise> } The promise returned by the function.
* @throws { BusinessError } 202 - Not system application.
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
@@ -395,12 +411,12 @@ declare namespace abilityManager {
* @systemapi
* @since 11
*/
- function acquireShareData(missionId: number): Promise>;
+ function acquireShareData(missionId: int): Promise>;
/**
* Notify the result of save as to target ability.
* @param { AbilityResult } parameter - Indicates the result to return.
- * @param { number } requestCode - Request code defined by the user.
+ * @param { int } requestCode - Request code defined by the user.
* @param { AsyncCallback } callback - The callback of the function.
* @throws { BusinessError } 201 - Permission denied.
* @throws { BusinessError } 202 - Not system application.
@@ -412,12 +428,12 @@ declare namespace abilityManager {
* @StageModelOnly
* @since 10
*/
- function notifySaveAsResult(parameter: AbilityResult, requestCode: number, callback: AsyncCallback): void;
+ function notifySaveAsResult(parameter: AbilityResult, requestCode: int, callback: AsyncCallback): void;
/**
* Notify the result of save as to target ability.
* @param { AbilityResult } parameter - Indicates the result to return.
- * @param { number } requestCode - Request code defined by the user.
+ * @param { int } requestCode - Request code defined by the user.
* @returns { Promise } The promise returned by the function.
* @throws { BusinessError } 201 - Permission denied.
* @throws { BusinessError } 202 - Not system application.
@@ -429,7 +445,7 @@ declare namespace abilityManager {
* @StageModelOnly
* @since 10
*/
- function notifySaveAsResult(parameter: AbilityResult, requestCode: number): Promise;
+ function notifySaveAsResult(parameter: AbilityResult, requestCode: int): Promise;
/**
* Get the foreground ui abilities.
@@ -554,7 +570,8 @@ declare namespace abilityManager {
*
* @typedef { _AbilityRunningInfo }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
- * @since 14
+ * @since arkts {'1.1':'14', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
export type AbilityRunningInfo = _AbilityRunningInfo;
@@ -577,14 +594,14 @@ declare namespace abilityManager {
*/
export type AbilityStateData = _AbilityStateData;
-
/**
* The class of an extension running information.
*
* @typedef { _ExtensionRunningInfo }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @systemapi
- * @since 9
+ * @since arkts {'1.1':'9', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
export type ExtensionRunningInfo = _ExtensionRunningInfo;
@@ -597,6 +614,17 @@ declare namespace abilityManager {
* @since 11
*/
export type AbilityForegroundStateObserver = _AbilityForegroundStateObserver.default;
+
+ /**
+ * The ability foreground state observer.
+ *
+ * @typedef { _AbilityForegroundStateObserver }
+ * @syscap SystemCapability.Ability.AbilityRuntime.Core
+ * @systemapi
+ * @since 20
+ * @arkts 1.2
+ */
+ export type AbilityForegroundStateObserver = _AbilityForegroundStateObserver;
}
export default abilityManager;
diff --git a/api/@ohos.app.ability.appManager.d.ts b/api/@ohos.app.ability.appManager.d.ts
index 4fa135881501bdb6b5258f6b67f65f4c37570eb0..21c5744d73262e38aa1f0c8fd250bb8fed6a5312 100644
--- a/api/@ohos.app.ability.appManager.d.ts
+++ b/api/@ohos.app.ability.appManager.d.ts
@@ -26,14 +26,19 @@ import { RunningMultiAppInfo as _RunningMultiAppInfo } from './application/Runni
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 * as _AbilityFirstFrameStateObserver from './application/AbilityFirstFrameStateObserver';
import * as _AbilityFirstFrameStateData from './application/AbilityFirstFrameStateData';
/*** endif */
/*** if arkts 1.2 */
+import _ApplicationStateObserver from './application/ApplicationStateObserver';
import _AbilityStateData from './application/AbilityStateData';
import _AppStateData from './application/AppStateData';
+import _ProcessData from './application/ProcessData';
+import _AppForegroundStateObserver from './application/AppForegroundStateObserver';
+import { AbilityFirstFrameStateObserver as _AbilityFirstFrameStateObserver } from './application/AbilityFirstFrameStateObserver';
+import { AbilityFirstFrameStateData as _AbilityFirstFrameStateData } from './application/AbilityFirstFrameStateData';
/*** endif */
/**
@@ -88,7 +93,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_ACTIVE,
@@ -239,7 +245,8 @@ declare namespace appManager {
* @enum { number }
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @systemapi
- * @since 14
+ * @since arkts {'1.1':'14', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
export enum KeepAliveAppType {
/**
@@ -247,7 +254,8 @@ declare namespace appManager {
*
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @systemapi
- * @since 14
+ * @since arkts {'1.1':'14', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
ALL = 0,
@@ -256,7 +264,8 @@ declare namespace appManager {
*
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @systemapi
- * @since 14
+ * @since arkts {'1.1':'14', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
THIRD_PARTY = 1,
@@ -265,7 +274,8 @@ declare namespace appManager {
*
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @systemapi
- * @since 14
+ * @since arkts {'1.1':'14', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
SYSTEM = 2
}
@@ -275,7 +285,8 @@ declare namespace appManager {
* @enum { number }
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @systemapi
- * @since 14
+ * @since arkts {'1.1':'14', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
export enum KeepAliveSetter {
/**
@@ -283,7 +294,8 @@ declare namespace appManager {
*
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @systemapi
- * @since 14
+ * @since arkts {'1.1':'14', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
SYSTEM = 0,
@@ -292,7 +304,8 @@ declare namespace appManager {
*
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @systemapi
- * @since 14
+ * @since arkts {'1.1':'14', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
USER = 1
}
@@ -303,7 +316,8 @@ declare namespace appManager {
* @typedef KeepAliveBundleInfo
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @systemapi
- * @since 14
+ * @since arkts {'1.1':'14', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
export interface KeepAliveBundleInfo {
/**
@@ -312,7 +326,8 @@ declare namespace appManager {
* @type { string }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @systemapi
- * @since 14
+ * @since arkts {'1.1':'14', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
bundleName: string;
@@ -322,7 +337,8 @@ declare namespace appManager {
* @type { KeepAliveAppType }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @systemapi
- * @since 14
+ * @since arkts {'1.1':'14', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
type: KeepAliveAppType;
@@ -332,19 +348,20 @@ declare namespace appManager {
* @type { KeepAliveSetter }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @systemapi
- * @since 14
+ * @since arkts {'1.1':'14', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
setter: KeepAliveSetter;
/**
* The user id of setter.
*
- * @type { ?number }
+ * @type { ?int }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @systemapi
* @since 20
*/
- setterUserId?: number;
+ setterUserId?: int;
/**
* Weather allow user to cancel keep-alive status.
@@ -363,15 +380,16 @@ declare namespace appManager {
* @permission ohos.permission.RUNNING_STATE_OBSERVER
* @param { 'applicationState' } type - applicationState.
* @param { ApplicationStateObserver } observer - The application state observer.
- * @returns { number } Returns the number code of the observer.
+ * @returns { int } Returns the number code of the observer.
* @throws { BusinessError } 201 - Permission denied.
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
* 2. Incorrect parameter types; 3. Parameter verification failed.
* @throws { BusinessError } 16000050 - Internal error.
* @syscap SystemCapability.Ability.AbilityRuntime.Core
- * @since 14
+ * @since arkts {'1.1':'14', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
- function on(type: 'applicationState', observer: ApplicationStateObserver): number;
+ function on(type: 'applicationState', observer: ApplicationStateObserver): int;
/**
* Register application state observer.
@@ -380,15 +398,16 @@ declare namespace appManager {
* @param { 'applicationState' } type - applicationState.
* @param { ApplicationStateObserver } observer - The application state observer.
* @param { Array } bundleNameList - The list of bundleName. The max length is 128.
- * @returns { number } Returns the number code of the observer.
+ * @returns { int } Returns the number code of the observer.
* @throws { BusinessError } 201 - Permission denied.
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
* 2. Incorrect parameter types; 3. Parameter verification failed.
* @throws { BusinessError } 16000050 - Internal error.
* @syscap SystemCapability.Ability.AbilityRuntime.Core
- * @since 14
+ * @since arkts {'1.1':'14', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
- function on(type: 'applicationState', observer: ApplicationStateObserver, bundleNameList: Array): number;
+ function on(type: 'applicationState', observer: ApplicationStateObserver, bundleNameList: Array): int;
/**
* Register app foreground or background state observer.
@@ -421,7 +440,8 @@ declare namespace appManager {
* @throws { BusinessError } 16000050 - Internal error.
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @systemapi
- * @since 12
+ * @since arkts {'1.1':'12', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
function on(type: 'abilityFirstFrameState', observer: AbilityFirstFrameStateObserver, bundleName?: string): void;
@@ -430,32 +450,34 @@ declare namespace appManager {
*
* @permission ohos.permission.RUNNING_STATE_OBSERVER
* @param { 'applicationState' } type - applicationState.
- * @param { number } observerId - Indicates the number code of the observer.
+ * @param { int } observerId - Indicates the number code of the observer.
* @param { AsyncCallback } callback - The callback of off.
* @throws { BusinessError } 201 - Permission denied.
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
* 2. Incorrect parameter types; 3. Parameter verification failed.
* @throws { BusinessError } 16000050 - Internal error.
* @syscap SystemCapability.Ability.AbilityRuntime.Core
- * @since 15
+ * @since arkts {'1.1':'15', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
- function off(type: 'applicationState', observerId: number, callback: AsyncCallback): void;
+ function off(type: 'applicationState', observerId: int, callback: AsyncCallback): void;
/**
* Unregister application state observer.
*
* @permission ohos.permission.RUNNING_STATE_OBSERVER
* @param { 'applicationState' } type - applicationState.
- * @param { number } observerId - Indicates the number code of the observer.
+ * @param { int } observerId - Indicates the number code of the observer.
* @returns { Promise } The promise returned by the function.
* @throws { BusinessError } 201 - Permission denied.
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
* 2. Incorrect parameter types; 3. Parameter verification failed.
* @throws { BusinessError } 16000050 - Internal error.
* @syscap SystemCapability.Ability.AbilityRuntime.Core
- * @since 14
+ * @since arkts {'1.1':'14', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
- function off(type: 'applicationState', observerId: number): Promise;
+ function off(type: 'applicationState', observerId: int): Promise;
/**
* Unregister app foreground or background state observer.
@@ -470,7 +492,8 @@ declare namespace appManager {
* @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 off(type: 'appForegroundState', observer?: AppForegroundStateObserver): void;
@@ -487,7 +510,8 @@ declare namespace appManager {
* @throws { BusinessError } 16000050 - Internal error.
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @systemapi
- * @since 12
+ * @since arkts {'1.1':'12', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
function off(type: 'abilityFirstFrameState', observer?: AbilityFirstFrameStateObserver): void;
@@ -545,7 +569,7 @@ declare namespace appManager {
* @permission ohos.permission.INTERACT_ACROSS_LOCAL_ACCOUNTS and ohos.permission.KILL_APP_PROCESSES
* or ohos.permission.INTERACT_ACROSS_LOCAL_ACCOUNTS and ohos.permission.CLEAN_BACKGROUND_PROCESSES
* @param { string } bundleName - The process bundle name.
- * @param { number } accountId - The account id.
+ * @param { int } accountId - The account id.
* @returns { Promise } The promise returned by the function.
* @throws { BusinessError } 201 - Permission denied.
* @throws { BusinessError } 202 - Not system application.
@@ -554,9 +578,10 @@ declare namespace appManager {
* @throws { BusinessError } 16000050 - Internal error.
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @systemapi
- * @since 14
+ * @since arkts {'1.1':'14', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
- function killProcessWithAccount(bundleName: string, accountId: number): Promise;
+ function killProcessWithAccount(bundleName: string, accountId: int): Promise;
/**
* Kill process with account.
@@ -564,9 +589,9 @@ declare namespace appManager {
* @permission ohos.permission.INTERACT_ACROSS_LOCAL_ACCOUNTS and ohos.permission.KILL_APP_PROCESSES
* or ohos.permission.INTERACT_ACROSS_LOCAL_ACCOUNTS and ohos.permission.CLEAN_BACKGROUND_PROCESSES
* @param { string } bundleName - The process bundle name.
- * @param { number } accountId - The account id.
+ * @param { int } accountId - The account id.
* @param { boolean } clearPageStack - The flag that indicates whether the page stack need to be cleared.
- * @param { number } [appIndex] - The application index.
+ * @param { int } [appIndex] - The application index.
* @returns { Promise } The promise returned by the function.
* @throws { BusinessError } 201 - Permission denied.
* @throws { BusinessError } 202 - Not system application.
@@ -574,9 +599,10 @@ declare namespace appManager {
* @throws { BusinessError } 16000050 - Internal error.
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @systemapi
- * @since 14
+ * @since arkts {'1.1':'14', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
- function killProcessWithAccount(bundleName: string, accountId: number, clearPageStack: boolean, appIndex?: number):
+ function killProcessWithAccount(bundleName: string, accountId: int, clearPageStack: boolean, appIndex?: int):
Promise;
/**
@@ -601,7 +627,7 @@ declare namespace appManager {
* @permission ohos.permission.INTERACT_ACROSS_LOCAL_ACCOUNTS and ohos.permission.KILL_APP_PROCESSES
* or ohos.permission.INTERACT_ACROSS_LOCAL_ACCOUNTS and ohos.permission.CLEAN_BACKGROUND_PROCESSES
* @param { string } bundleName - The process bundle name.
- * @param { number } accountId - The account id.
+ * @param { int } accountId - The account id.
* @param { AsyncCallback } callback - The callback of killProcessWithAccount.
* @throws { BusinessError } 201 - Permission denied.
* @throws { BusinessError } 202 - Not system application.
@@ -610,9 +636,10 @@ declare namespace appManager {
* @throws { BusinessError } 16000050 - Internal error.
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @systemapi
- * @since 14
+ * @since arkts {'1.1':'14', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
- function killProcessWithAccount(bundleName: string, accountId: number, callback: AsyncCallback): void;
+ function killProcessWithAccount(bundleName: string, accountId: int, callback: AsyncCallback): void;
/**
* Is user running in stability test.
@@ -633,7 +660,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 isRunningInStabilityTest(callback: AsyncCallback): void;
@@ -652,7 +680,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 isRunningInStabilityTest(): Promise;
@@ -684,7 +713,8 @@ declare namespace appManager {
* @throws { BusinessError } 16000050 - Internal error.
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @systemapi
- * @since 14
+ * @since arkts {'1.1':'14', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
function killProcessesByBundleName(bundleName: string): Promise;
@@ -694,15 +724,16 @@ declare namespace appManager {
* @permission ohos.permission.KILL_APP_PROCESSES or ohos.permission.CLEAN_BACKGROUND_PROCESSES
* @param { string } bundleName - bundle name.
* @param { boolean } clearPageStack - The flag that indicates whether the page stack need to be cleared.
- * @param { number } [appIndex] - The index of clone app.
+ * @param { int } [appIndex] - The index of clone app.
* @returns { Promise } The promise returned by the function.
* @throws { BusinessError } 201 - Permission denied.
* @throws { BusinessError } 401 - If the input parameter is not valid parameter.
* @throws { BusinessError } 16000050 - Internal error.
* @syscap SystemCapability.Ability.AbilityRuntime.Core
- * @since 14
+ * @since arkts {'1.1':'14', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
- function killProcessesByBundleName(bundleName: string, clearPageStack: boolean, appIndex?: number): Promise;
+ function killProcessesByBundleName(bundleName: string, clearPageStack: boolean, appIndex?: int): Promise;
/**
* Kill processes by bundle name
@@ -785,7 +816,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 isRamConstrainedDevice(): Promise;
@@ -808,7 +840,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 isRamConstrainedDevice(callback: AsyncCallback): void;
@@ -823,13 +856,14 @@ declare namespace appManager {
/**
* Get the memory size of the application
*
- * @returns { Promise } Returns the application memory size.
+ * @returns { Promise } Returns the application memory size.
* @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 getAppMemorySize(): Promise;
+ function getAppMemorySize(): Promise;
/**
* Get the memory size of the application
@@ -844,15 +878,16 @@ declare namespace appManager {
/**
* Get the memory size of the application
*
- * @param { AsyncCallback } callback - The callback is used to return the application memory size.
+ * @param { AsyncCallback } callback - The callback is used to return the application memory size.
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
* 2. Incorrect parameter types; 3. Parameter verification failed.
* @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 getAppMemorySize(callback: AsyncCallback): void;
+ function getAppMemorySize(callback: AsyncCallback): void;
/**
* If you apply for permission, you can obtain information about all running processes.
@@ -889,7 +924,8 @@ declare namespace appManager {
* @throws { BusinessError } 16000050 - Internal error.
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @systemapi
- * @since 12
+ * @since arkts {'1.1':'12', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
function getRunningProcessInformationByBundleType(
bundleType: bundleManager.BundleType): Promise>;
@@ -925,7 +961,7 @@ declare namespace appManager {
*
* @permission ohos.permission.GET_RUNNING_INFO
* @param { string } bundleName - Indicates the bundle name of the shared bundle.
- * @param { number } versionCode - Indicates the version code of the shared bundle.
+ * @param { long } versionCode - Indicates the version code of the shared bundle.
* @returns { Promise } Returns the shared bundle running result. The result is true if running, false otherwise.
* @throws { BusinessError } 201 - Permission denied.
* @throws { BusinessError } 202 - Not system application.
@@ -934,16 +970,17 @@ 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 isSharedBundleRunning(bundleName: string, versionCode: number): Promise;
+ function isSharedBundleRunning(bundleName: string, versionCode: long): Promise;
/**
* Check whether the shared bundle is running.
*
* @permission ohos.permission.GET_RUNNING_INFO
* @param { string } bundleName - Indicates the bundle name of the shared bundle.
- * @param { number } versionCode - Indicates the version code of the shared bundle.
+ * @param { long } versionCode - Indicates the version code of the shared bundle.
* @param { AsyncCallback } callback - The callback of checking the shared bundle running result.
* The result is true if running, false otherwise.
* @throws { BusinessError } 201 - Permission denied.
@@ -953,39 +990,42 @@ 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 isSharedBundleRunning(bundleName: string, versionCode: number, callback: AsyncCallback): void;
+ function isSharedBundleRunning(bundleName: string, versionCode: long, callback: AsyncCallback): void;
/**
* Obtains memory usage of one process by its pid.
*
- * @param { number } pid - Indicates the pid of the process.
- * @returns { Promise } Returns the memory usage of the process in KB.
+ * @param { int } pid - Indicates the pid of the process.
+ * @returns { Promise } Returns the memory usage of the process in KB.
* @throws { BusinessError } 202 - Permission denied, non-system app called system api.
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
* 2. Incorrect parameter types; 3. Parameter verification failed.
* @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 getProcessMemoryByPid(pid: number): Promise;
+ function getProcessMemoryByPid(pid: int): Promise;
/**
* Obtains memory usage of one process by its pid.
*
- * @param { number } pid - Indicates the pid of the process.
- * @param { AsyncCallback } callback - Indicates the callback of getting process memory by pid result.
+ * @param { int } pid - Indicates the pid of the process.
+ * @param { AsyncCallback } callback - Indicates the callback of getting process memory by pid result.
* @throws { BusinessError } 202 - Permission denied, non-system app called system api.
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
* 2. Incorrect parameter types; 3. Parameter verification failed.
* @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 getProcessMemoryByPid(pid: number, callback: AsyncCallback): void;
+ function getProcessMemoryByPid(pid: int, callback: AsyncCallback): void;
/**
* Obtains the process information list of running processes that belong to a specific bundle of current user.
@@ -1007,7 +1047,7 @@ declare namespace appManager {
* Obtains the process information list of running processes that belong to a specific bundle and specific user ID.
*
* @param { string } bundleName - Indicates the bundle name of the application to which the processes belong to.
- * @param { number } userId - Indicates the user ID of the application to which the processes belong to.
+ * @param { int } userId - Indicates the user ID of the application to which the processes belong to.
* @param { AsyncCallback> } callback - Indicates the callback of getting process information by bundleName result.
* @throws { BusinessError } 202 - Permission denied, non-system app called system api.
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
@@ -1018,7 +1058,7 @@ declare namespace appManager {
* @since arkts {'1.1':'10', '1.2':'20'}
* @arkts 1.1&1.2
*/
- function getRunningProcessInfoByBundleName(bundleName: string, userId: number, callback: AsyncCallback>): void;
+ function getRunningProcessInfoByBundleName(bundleName: string, userId: int, callback: AsyncCallback>): void;
/**
* Obtains the process information list of running processes that belong to a specific bundle of current user.
@@ -1040,7 +1080,7 @@ declare namespace appManager {
* Obtains the process information list of running processes that belong to a specific bundle and specific user ID.
*
* @param { string } bundleName - Indicates the bundle name of the application to which the processes belong to.
- * @param { number } userId - Indicates the user ID of the application to which the processes belong to.
+ * @param { int } userId - Indicates the user ID of the application to which the processes belong to.
* @returns { Promise> } Returns a list of process information.
* @throws { BusinessError } 202 - Permission denied, non-system app called system api.
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
@@ -1051,7 +1091,7 @@ declare namespace appManager {
* @since arkts {'1.1':'10', '1.2':'20'}
* @arkts 1.1&1.2
*/
- function getRunningProcessInfoByBundleName(bundleName: string, userId: number): Promise>;
+ function getRunningProcessInfoByBundleName(bundleName: string, userId: int): Promise>;
/**
* Check whether the bundle is running.
@@ -1093,9 +1133,9 @@ declare namespace appManager {
*
* @permission ohos.permission.PRELOAD_APPLICATION
* @param { string } bundleName - The bundle name of the application to preload.
- * @param { number } userId - Indicates the user identification.
+ * @param { int } userId - Indicates the user identification.
* @param { PreloadMode } mode - Preload application mode.
- * @param { number } [appIndex] - The index of application clone.
+ * @param { int } [appIndex] - The index of application clone.
* @returns { Promise } Returns the result of preloadApplication.
* @throws { BusinessError } 201 - The application does not have permission to call the interface.
* @throws { BusinessError } 202 - Not system application.
@@ -1106,9 +1146,10 @@ 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 preloadApplication(bundleName: string, userId: number, mode: PreloadMode, appIndex?: number): Promise;
+ function preloadApplication(bundleName: string, userId: int, mode: PreloadMode, appIndex?: int): Promise;
/**
* Get all running multi app info by bundleName
@@ -1135,7 +1176,7 @@ declare namespace appManager {
*
* @permission ohos.permission.GET_RUNNING_INFO
* @param { string } bundleName - Indicates the bundle name of the bundle.
- * @param { number } [appCloneIndex] - app clone index
+ * @param { int } [appCloneIndex] - app clone index
* @returns { Promise } Returns the bundle running result. The result is true if running, false otherwise.
* @throws { BusinessError } 201 - Permission denied.
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
@@ -1143,16 +1184,17 @@ declare namespace appManager {
* @throws { BusinessError } 16000050 - Internal error.
* @throws { BusinessError } 16000073 - The app clone index is invalid.
* @syscap SystemCapability.Ability.AbilityRuntime.Core
- * @since 14
+ * @since arkts {'1.1':'14', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
- function isAppRunning(bundleName: string, appCloneIndex?: number): Promise;
+ function isAppRunning(bundleName: string, appCloneIndex?: int): Promise;
/**
* Clear up application data by bundle name
*
* @permission ohos.permission.CLEAN_APPLICATION_DATA
* @param { string } bundleName - bundle name.
- * @param { number } [appCloneIndex] - app clone index
+ * @param { int } [appCloneIndex] - app clone index
* @returns { Promise } The promise returned by the function.
* @throws { BusinessError } 201 - Permission denied.
* @throws { BusinessError } 202 - Not system application.
@@ -1164,13 +1206,13 @@ declare namespace appManager {
* @systemapi
* @since 13
*/
- function clearUpAppData(bundleName: string, appCloneIndex?: number): Promise;
+ function clearUpAppData(bundleName: string, appCloneIndex?: int): Promise;
/**
* Terminate the mission of a UIAbility and back to caller.
*
* @permission ohos.permission.KILL_APP_PROCESSES
- * @param { number } missionId - The mission id of the UIAbility need to be terminated.
+ * @param { int } missionId - The mission id of the UIAbility need to be terminated.
* @returns { Promise } Returns the result of terminateMission.
* @throws { BusinessError } 201 - Permission denied.
* @throws { BusinessError } 202 - Not system application.
@@ -1181,14 +1223,14 @@ declare namespace appManager {
* @systemapi
* @since 13
*/
- function terminateMission(missionId: number): Promise;
+ function terminateMission(missionId: int): Promise;
/**
* Get pids of processes which belong to specific bundle name and support process cache feature.
*
* @permission ohos.permission.GET_RUNNING_INFO
* @param { string } bundleName - bundle name.
- * @returns { Promise> } Returns the list of pid.
+ * @returns { Promise> } Returns the list of pid.
* @throws { BusinessError } 201 - Permission denied.
* @throws { BusinessError } 202 - Not system application.
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
@@ -1198,16 +1240,17 @@ declare namespace appManager {
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @systemapi
* @stagemodelonly
- * @since 14
+ * @since arkts {'1.1':'14', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
- function getSupportedProcessCachePids(bundleName : string): Promise>;
+ function getSupportedProcessCachePids(bundleName : string): Promise>;
/**
* Set keep alive for the specified bundle.
*
* @permission ohos.permission.MANAGE_APP_KEEP_ALIVE
* @param { string } bundleName - bundle name.
- * @param { number } userId - user id.
+ * @param { int } userId - user id.
* @param { boolean } enable - flag indicates whether the bundle should be kept alive.
* @returns { Promise } The promise returned by the function.
* @throws { BusinessError } 201 - Permission denied.
@@ -1222,16 +1265,17 @@ declare namespace appManager {
* @throws { BusinessError } 16300010 - The target application is not attached to the status bar.
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @systemapi
- * @since 14
+ * @since arkts {'1.1':'14', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
- function setKeepAliveForBundle(bundleName: string, userId: number, enable: boolean): Promise;
+ function setKeepAliveForBundle(bundleName: string, userId: int, enable: boolean): Promise;
/**
* Get keep-alive bundle information.
*
* @permission ohos.permission.MANAGE_APP_KEEP_ALIVE
* @param { KeepAliveAppType } type - type of keep-alive apps to be quried.
- * @param { number } [userId] - user id.
+ * @param { int } [userId] - user id.
* @returns { Promise> } Returns the list of KeepAliveBundleInfo.
* @throws { BusinessError } 201 - Permission denied.
* @throws { BusinessError } 202 - Not system application.
@@ -1241,9 +1285,10 @@ declare namespace appManager {
* @throws { BusinessError } 16000050 - Internal error.
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @systemapi
- * @since 14
+ * @since arkts {'1.1':'14', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
- function getKeepAliveBundles(type: KeepAliveAppType, userId?: number): Promise>;
+ function getKeepAliveBundles(type: KeepAliveAppType, userId?: int): Promise>;
/**
* Set keep alive for the specified app service extension.
@@ -1285,7 +1330,7 @@ declare namespace appManager {
* Kill processes in batch.
*
* @permission ohos.permission.KILL_APP_PROCESSES
- * @param { Array } pids - The pids of the processes.
+ * @param { Array } pids - The pids of the processes.
* @returns { Promise } The promise returned by the function.
* @throws { BusinessError } 201 - Permission denied.
* @throws { BusinessError } 202 - Not system application.
@@ -1295,9 +1340,10 @@ declare namespace appManager {
* @throws { BusinessError } 16000050 - Internal error.
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @systemapi
- * @since 14
+ * @since arkts {'1.1':'14', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
- function killProcessesInBatch(pids: Array): Promise;
+ function killProcessesInBatch(pids: Array): Promise;
/**
* The ability or extension state data.
@@ -1308,6 +1354,16 @@ declare namespace appManager {
*/
export type AbilityStateData = _AbilityStateData.default;
+ /**
+ * The ability or extension state data.
+ *
+ * @typedef { _AbilityStateData }
+ * @syscap SystemCapability.Ability.AbilityRuntime.Core
+ * @since 20
+ * @arkts 1.2
+ */
+ export type AbilityStateData = _AbilityStateData;
+
/**
* The application state data.
*
@@ -1336,6 +1392,16 @@ declare namespace appManager {
*/
export type ApplicationStateObserver = _ApplicationStateObserver.default;
+ /**
+ * The application state observer.
+ *
+ * @typedef { _ApplicationStateObserver }
+ * @syscap SystemCapability.Ability.AbilityRuntime.Core
+ * @since 20
+ * @arkts 1.2
+ */
+ export type ApplicationStateObserver = _ApplicationStateObserver;
+
/**
* The application foreground state observer.
*
@@ -1346,6 +1412,17 @@ declare namespace appManager {
*/
export type AppForegroundStateObserver = _AppForegroundStateObserver.default;
+ /**
+ * The application foreground state observer.
+ *
+ * @typedef { _AppForegroundStateObserver }
+ * @syscap SystemCapability.Ability.AbilityRuntime.Core
+ * @systemapi
+ * @since 20
+ * @arkts 1.2
+ */
+ export type AppForegroundStateObserver = _AppForegroundStateObserver;
+
/**
* The class of a process information.
*
@@ -1372,6 +1449,16 @@ declare namespace appManager {
*/
export type ProcessData = _ProcessData.default;
+ /**
+ * The application state data.
+ *
+ * @typedef { _ProcessData }
+ * @syscap SystemCapability.Ability.AbilityRuntime.Core
+ * @since 20
+ * @arkts 1.2
+ */
+ export type ProcessData = _ProcessData;
+
/**
* The ability first frame state observer.
*
@@ -1382,6 +1469,17 @@ declare namespace appManager {
*/
export type AbilityFirstFrameStateObserver = _AbilityFirstFrameStateObserver.default;
+ /**
+ * The ability first frame state observer.
+ *
+ * @typedef { _AbilityFirstFrameStateObserver }
+ * @syscap SystemCapability.Ability.AbilityRuntime.Core
+ * @systemapi
+ * @since 20
+ * @arkts 1.2
+ */
+ export type AbilityFirstFrameStateObserver = _AbilityFirstFrameStateObserver;
+
/**
* The class of an ability first frame state data.
*
@@ -1392,6 +1490,17 @@ declare namespace appManager {
*/
export type AbilityFirstFrameStateData = _AbilityFirstFrameStateData.default;
+ /**
+ * The class of an ability first frame state data.
+ *
+ * @typedef { _AbilityFirstFrameStateData }
+ * @syscap SystemCapability.Ability.AbilityRuntime.Core
+ * @systemapi
+ * @since 20
+ * @arkts 1.2
+ */
+ export type AbilityFirstFrameStateData = _AbilityFirstFrameStateData;
+
/**
* The class of running multi app information.
*
diff --git a/api/@ohos.app.ability.application.d.ts b/api/@ohos.app.ability.application.d.ts
index 2d36e7fcb330a1a2c69e473d1f8d8598fa880058..263ea157c508f43d6e86c384d75f5e6d8adf9ceb 100644
--- a/api/@ohos.app.ability.application.d.ts
+++ b/api/@ohos.app.ability.application.d.ts
@@ -123,7 +123,8 @@ declare namespace application {
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @stagemodelonly
* @atomicservice
- * @since 14
+ * @since arkts {'1.1':'14', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
export function getApplicationContext(): ApplicationContext;
diff --git a/api/@ohos.app.ability.childProcessManager.d.ts b/api/@ohos.app.ability.childProcessManager.d.ts
index 683fe96719d0b5c0dd463a27f60292d11cb8f38d..d09a5e09aa16b94722fb421e4b6ca8851eab7806 100644
--- a/api/@ohos.app.ability.childProcessManager.d.ts
+++ b/api/@ohos.app.ability.childProcessManager.d.ts
@@ -66,7 +66,7 @@ declare namespace childProcessManager {
*
* @param { string } srcEntry - Child process source file entrance to be started.
* @param { StartMode } startMode - Child process start mode.
- * @returns { Promise } Returns the started child process pid.
+ * @returns { Promise } Returns the started child process pid.
* @throws { BusinessError } 401 - Parameter error. Possible causes:
* 1.Mandatory parameters are left unspecified; 2.Incorrect parameter types; 3.Parameter verification failed.
* @throws { BusinessError } 16000050 - Internal error.
@@ -76,14 +76,14 @@ declare namespace childProcessManager {
* @stagemodelonly
* @since 11
*/
- function startChildProcess(srcEntry: string, startMode: StartMode): Promise;
+ function startChildProcess(srcEntry: string, startMode: StartMode): Promise;
/**
* Start child process with the given src entry and mode.
*
* @param { string } srcEntry - Child process source file entrance to be started.
* @param { StartMode } startMode - Child process start mode.
- * @param { AsyncCallback } callback - The callback of startChildProcess.
+ * @param { AsyncCallback } callback - The callback of startChildProcess.
* @throws { BusinessError } 401 - Parameter error. Possible causes:
* 1.Mandatory parameters are left unspecified; 2.Incorrect parameter types; 3.Parameter verification failed.
* @throws { BusinessError } 16000050 - Internal error.
@@ -93,7 +93,7 @@ declare namespace childProcessManager {
* @stagemodelonly
* @since 11
*/
- function startChildProcess(srcEntry: string, startMode: StartMode, callback: AsyncCallback): void;
+ function startChildProcess(srcEntry: string, startMode: StartMode, callback: AsyncCallback): void;
/**
* Start child process with the given args and options.
@@ -117,7 +117,7 @@ declare namespace childProcessManager {
* @param { string } srcEntry - Indicates child process source file entrance to be started.
* @param { ChildProcessArgs } args - Indicates args to pass to child process.
* @param { ChildProcessOptions } [options] - Indicates options for starting child process.
- * @returns { Promise } Returns the started child process pid.
+ * @returns { Promise } Returns the started child process pid.
* @throws { BusinessError } 401 - Parameter error. Possible causes:
* 1.Mandatory parameters are left unspecified; 2.Incorrect parameter types; 3.Parameter verification failed.
* @throws { BusinessError } 801 - Capability not supported.
@@ -128,7 +128,7 @@ declare namespace childProcessManager {
* @stagemodelonly
* @since 13
*/
- function startArkChildProcess(srcEntry: string, args: ChildProcessArgs, options?: ChildProcessOptions): Promise;
+ function startArkChildProcess(srcEntry: string, args: ChildProcessArgs, options?: ChildProcessOptions): Promise;
/**
* Start native child process with the given args and options.
@@ -136,7 +136,7 @@ declare namespace childProcessManager {
* @param { string } entryPoint - Indicates entry point of child process, consisting of library and entry function, such as "libEntry.so:Main".
* @param { ChildProcessArgs } args - Indicates args to pass to child process.
* @param { ChildProcessOptions } [options] - Indicates options for starting child process.
- * @returns { Promise } Returns the started child process pid.
+ * @returns { Promise } Returns the started child process pid.
* @throws { BusinessError } 401 - Parameter error. Possible causes:
* 1.Mandatory parameters are left unspecified; 2.Incorrect parameter types; 3.Parameter verification failed.
* @throws { BusinessError } 801 - Capability not supported. Failed to call the API due to limited device capabilities.
@@ -147,7 +147,7 @@ declare namespace childProcessManager {
* @stagemodelonly
* @since 13
*/
- function startNativeChildProcess(entryPoint: string, args: ChildProcessArgs, options?: ChildProcessOptions): Promise;
+ function startNativeChildProcess(entryPoint: string, args: ChildProcessArgs, options?: ChildProcessOptions): Promise;
}
diff --git a/api/@ohos.app.ability.common.d.ts b/api/@ohos.app.ability.common.d.ts
index f26a6a6e5fddb4f3e5bf38a447b585155274612e..757cea8daf4d7669d3356d22b4fb94ef30720987 100644
--- a/api/@ohos.app.ability.common.d.ts
+++ b/api/@ohos.app.ability.common.d.ts
@@ -30,9 +30,6 @@ import * as _ExtensionContext from './application/ExtensionContext';
import * as _FormExtensionContext from './application/FormExtensionContext';
import * as _ServiceExtensionContext from './application/ServiceExtensionContext';
import * as _EventHub from './application/EventHub';
-import { PacMap as _PacMap } from './ability/dataAbilityHelper';
-import type _AbilityStartCallback from './application/AbilityStartCallback';
-import { ConnectOptions as _ConnectOptions } from './ability/connectOptions';
import type * as _VpnExtensionContext from './application/VpnExtensionContext';
import type { AutoStartupCallback as _AutoStartupCallback } from './application/AutoStartupCallback';
import type { AutoStartupInfo as _AutoStartupInfo } from './application/AutoStartupInfo';
@@ -42,19 +39,23 @@ import * as _UIServiceExtensionContext from './application/UIServiceExtensionCon
import * as _UIServiceProxy from './application/UIServiceProxy';
import * as _UIServiceHostProxy from './application/UIServiceHostProxy';
import * as _UIServiceExtensionConnectCallback from './application/UIServiceExtensionConnectCallback';
-import * as _AppServiceExtensionContext from './application/AppServiceExtensionContext';
+import { PacMap as _PacMap } from './ability/dataAbilityHelper';
/*** endif */
-import { AbilityResult as _AbilityResult } from './ability/abilityResult';
/*** if arkts 1.2 */
import _UIAbilityContext from './application/UIAbilityContext';
import type _UIExtensionContext from './application/UIExtensionContext';
import _AbilityStageContext from './application/AbilityStageContext';
import _ApplicationContext from './application/ApplicationContext';
+import _BaseContext from './application/BaseContext';
import _Context from './application/Context';
import _ExtensionContext from './application/ExtensionContext';
+import _FormExtensionContext from './application/FormExtensionContext';
import _ServiceExtensionContext from './application/ServiceExtensionContext';
+import _EventHub from './application/EventHub';
/*** endif */
-
+import { AbilityResult as _AbilityResult } from './ability/abilityResult';
+import type _AbilityStartCallback from './application/AbilityStartCallback';
+import { ConnectOptions as _ConnectOptions } from './ability/connectOptions';
/**
* This module provides application context classes and common data structures.
*
@@ -229,6 +230,19 @@ declare namespace common {
* @since 11
*/
export type BaseContext = _BaseContext.default;
+
+ /**
+ * The base context of 'app.Context' for FA Mode or 'application.Context' for Stage Mode.
+ *
+ * @typedef { _BaseContext }
+ * @syscap SystemCapability.Ability.AbilityRuntime.Core
+ * @stagemodelonly
+ * @crossplatform
+ * @atomicservice
+ * @since 20
+ * @arkts 1.2
+ */
+ export type BaseContext = _BaseContext;
/**
* The base context of an ability or an application. It allows access to
@@ -324,6 +338,20 @@ declare namespace common {
*/
export type FormExtensionContext = _FormExtensionContext.default;
+ /**
+ * The context of form extension. It allows access to
+ * formExtension-specific resources.
+ *
+ * @typedef { _FormExtensionContext }
+ * @syscap SystemCapability.Ability.AbilityRuntime.Core
+ * @stagemodelonly
+ * @atomicservice
+ * @since 20
+ * @arkts 1.2
+ */
+ export type FormExtensionContext = _FormExtensionContext;
+
+
/**
* The context of service extension. It allows access to
* serviceExtension-specific resources.
@@ -376,6 +404,19 @@ declare namespace common {
*/
export type EventHub = _EventHub.default;
+ /**
+ * The event center of a context, support the subscription and publication of events.
+ *
+ * @typedef { _EventHub }
+ * @syscap SystemCapability.Ability.AbilityRuntime.Core
+ * @stagemodelonly
+ * @crossplatform
+ * @atomicservice
+ * @since 20
+ * @arkts 1.2
+ */
+ export type EventHub = _EventHub;
+
/**
* Defines a PacMap object for storing a series of values.
*
@@ -418,7 +459,8 @@ declare namespace common {
* @typedef { _ConnectOptions }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @stagemodelonly
- * @since 9
+ * @since arkts {'1.1':'9', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
export type ConnectOptions = _ConnectOptions;
@@ -464,7 +506,8 @@ declare namespace common {
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @stagemodelonly
* @atomicservice
- * @since 11
+ * @since arkts {'1.1':'11', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
export type AbilityStartCallback = _AbilityStartCallback;
diff --git a/api/@ohos.app.ability.contextConstant.d.ts b/api/@ohos.app.ability.contextConstant.d.ts
index 784bf67af7bf6f7b607bd12579882d9dcf84b088..251dcfc68ac314688878874ca10c35e68b87bf5f 100644
--- a/api/@ohos.app.ability.contextConstant.d.ts
+++ b/api/@ohos.app.ability.contextConstant.d.ts
@@ -125,7 +125,8 @@ declare namespace contextConstant {
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @stagemodelonly
* @atomicservice
- * @since 12
+ * @since arkts {'1.1':'12', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
EL5 = 4
}
diff --git a/api/@ohos.app.ability.dataUriUtils.d.ts b/api/@ohos.app.ability.dataUriUtils.d.ts
index cdaa9b52b135b9d5efffc9347310c0c801681255..63ba6905b878f18f1a47ad8d4f3d40879e8bffe1 100644
--- a/api/@ohos.app.ability.dataUriUtils.d.ts
+++ b/api/@ohos.app.ability.dataUriUtils.d.ts
@@ -23,7 +23,8 @@
*
* @namespace dataUriUtils
* @syscap SystemCapability.Ability.AbilityRuntime.Core
- * @since 9
+ * @since arkts {'1.1':'9', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
declare namespace dataUriUtils {
/**
@@ -34,7 +35,8 @@ declare namespace dataUriUtils {
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
* 2. Incorrect parameter types; 3. Parameter verification failed.
* @syscap SystemCapability.Ability.AbilityRuntime.Core
- * @since 9
+ * @since arkts {'1.1':'9', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
function getId(uri: string): number;
@@ -47,7 +49,8 @@ declare namespace dataUriUtils {
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
* 2. Incorrect parameter types; 3. Parameter verification failed.
* @syscap SystemCapability.Ability.AbilityRuntime.Core
- * @since 9
+ * @since arkts {'1.1':'9', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
function attachId(uri: string, id: number): string;
@@ -59,7 +62,8 @@ declare namespace dataUriUtils {
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
* 2. Incorrect parameter types; 3. Parameter verification failed.
* @syscap SystemCapability.Ability.AbilityRuntime.Core
- * @since 9
+ * @since arkts {'1.1':'9', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
function deleteId(uri: string): string;
@@ -72,7 +76,8 @@ declare namespace dataUriUtils {
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
* 2. Incorrect parameter types; 3. Parameter verification failed.
* @syscap SystemCapability.Ability.AbilityRuntime.Core
- * @since 9
+ * @since arkts {'1.1':'9', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
function updateId(uri: string, id: number): string;
}
diff --git a/api/@ohos.app.ability.dialogRequest.d.ts b/api/@ohos.app.ability.dialogRequest.d.ts
index 275dc2f4173f94a9545c8bc955d6e3d6143af656..8c1b8ae2532cb2a9287e5d7c8de4b48d09ffe47f 100644
--- a/api/@ohos.app.ability.dialogRequest.d.ts
+++ b/api/@ohos.app.ability.dialogRequest.d.ts
@@ -18,7 +18,7 @@
* @kit AbilityKit
*/
- /*** if arkts 1.1 */
+/*** if arkts 1.1 */
import Want from './@ohos.app.ability.Want';
/*** endif */
@@ -43,42 +43,42 @@ declare namespace dialogRequest {
/**
* The left position of WindowRect
*
- * @type { number }
+ * @type { int }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @StageModelOnly
* @since 10
*/
- left: number;
+ left: int;
/**
* The top position of WindowRect
*
- * @type { number }
+ * @type { int }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @StageModelOnly
* @since 10
*/
- top: number;
+ top: int;
/**
* The width of WindowRect
*
- * @type { number }
+ * @type { int }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @StageModelOnly
* @since 10
*/
- width: number;
+ width: int;
/**
* The height of WindowRect
*
- * @type { number }
+ * @type { int }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @StageModelOnly
* @since 10
*/
- height: number;
+ height: int;
}
/**
* Request info of a request.
diff --git a/api/@ohos.app.ability.dialogSession.d.ts b/api/@ohos.app.ability.dialogSession.d.ts
index c4836a1a28309d0c9354dfe8e8458d1eae79d0c8..e51f9fd394f27b76390a452b0487c103acc34a7e 100644
--- a/api/@ohos.app.ability.dialogSession.d.ts
+++ b/api/@ohos.app.ability.dialogSession.d.ts
@@ -80,46 +80,46 @@ declare namespace dialogSession {
/**
* The icon id of ability
*
- * @type { number }
+ * @type { int }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @systemapi
* @stagemodelonly
* @since 11
*/
- abilityIconId: number;
+ abilityIconId: int;
/**
* The label id of ability
*
- * @type { number }
+ * @type { int }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @systemapi
* @stagemodelonly
* @since 11
*/
- abilityLabelId: number;
+ abilityLabelId: int;
/**
* The icon id of bundle
*
- * @type { number }
+ * @type { int }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @systemapi
* @stagemodelonly
* @since 11
*/
- bundleIconId: number;
+ bundleIconId: int;
/**
* The label id of bundle
*
- * @type { number }
+ * @type { int }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @systemapi
* @stagemodelonly
* @since 11
*/
- bundleLabelId: number;
+ bundleLabelId: int;
/**
* The ability is visible
@@ -135,13 +135,13 @@ declare namespace dialogSession {
/**
* Index of an application clone. It takes effect only for cloned applications.
*
- * @type { number }
+ * @type { int }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @systemapi
* @stagemodelonly
* @since 12
*/
- appIndex: number;
+ appIndex: int;
/**
* The mode of the multi-application.
diff --git a/api/@ohos.app.ability.insightIntent.d.ts b/api/@ohos.app.ability.insightIntent.d.ts
index c8f75ce1d14eba4cf3b5c1c8ec002ac1902b6776..0937b499060c3a0f1aaa9e5af5ac810410fea73b 100644
--- a/api/@ohos.app.ability.insightIntent.d.ts
+++ b/api/@ohos.app.ability.insightIntent.d.ts
@@ -101,14 +101,14 @@ declare namespace insightIntent {
/**
* Indicates result code.
*
- * @type { number }
+ * @type { int }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @StageModelOnly
* @atomicservice
* @since arkts {'1.1':'11', '1.2':'20'}
* @arkts 1.1&1.2
*/
- code: number;
+ code: int;
/**
* Indicates execute result.
@@ -141,14 +141,14 @@ declare namespace insightIntent {
* {@link wantConstant#Flags#FLAG_AUTH_READ_URI_PERMISSION}|
* {@link wantConstant#Flags#FLAG_AUTH_WRITE_URI_PERMISSION}.
*
- * @type { ?number }
+ * @type { ?int }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @stagemodelonly
* @atomicservice
* @since arkts {'1.1':'18', '1.2':'20'}
* @arkts 1.1&1.2
*/
- flags?: number;
+ flags?: int;
}
/**
diff --git a/api/@ohos.app.ability.insightIntentDriver.d.ts b/api/@ohos.app.ability.insightIntentDriver.d.ts
index f3f76353810889b6e3a28a91c52162fb1517a681..a39325f844a4799368fbd2202d1ddc576a4f0ee4 100644
--- a/api/@ohos.app.ability.insightIntentDriver.d.ts
+++ b/api/@ohos.app.ability.insightIntentDriver.d.ts
@@ -120,14 +120,14 @@ declare namespace insightIntentDriver {
/**
* Indicates the display Id, only works when executeMode is UIAbility foreground.
*
- * @type { ?number }
+ * @type { ?long }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @systemapi
* @StageModelOnly
* @since arkts {'1.1':'12', '1.2':'20'}
* @arkts 1.1&1.2
*/
- displayId?: number;
+ displayId?: long;
/**
* Indicates the URIs will be authorized to the insight intent executor.
@@ -148,14 +148,14 @@ declare namespace insightIntentDriver {
* {@link wantConstant#Flags#FLAG_AUTH_READ_URI_PERMISSION}|
* {@link wantConstant#Flags#FLAG_AUTH_WRITE_URI_PERMISSION}.
*
- * @type { ?number }
+ * @type { ?int }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @systemapi
* @stagemodelonly
* @since arkts {'1.1':'18', '1.2':'20'}
* @arkts 1.1&1.2
*/
- flags?: number;
+ flags?: int;
}
/**
diff --git a/api/@ohos.app.ability.missionManager.d.ts b/api/@ohos.app.ability.missionManager.d.ts
index d7a1be6b8d7fa83a051009bca53d83e33b3084d9..80799c91e2415d4cba625c6ccb8626194232aaa6 100644
--- a/api/@ohos.app.ability.missionManager.d.ts
+++ b/api/@ohos.app.ability.missionManager.d.ts
@@ -20,9 +20,11 @@
import { AsyncCallback } from './@ohos.base';
import { MissionInfo as _MissionInfo } from './application/MissionInfo';
+/*** if arkts 1.1 */
import { MissionListener as _MissionListener } from './application/MissionListener';
import { MissionSnapshot as _MissionSnapshot } from './application/MissionSnapshot';
import StartOptions from './@ohos.app.ability.StartOptions';
+/*** endif */
/**
* This module provides the capability to manage abilities and obtaining system task information.
@@ -30,7 +32,8 @@ import StartOptions from './@ohos.app.ability.StartOptions';
* @namespace missionManager
* @syscap SystemCapability.Ability.AbilityRuntime.Mission
* @systemapi
- * @since 9
+ * @since arkts {'1.1':'9', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
declare namespace missionManager {
/**
@@ -91,7 +94,7 @@ declare namespace missionManager {
*
* @permission ohos.permission.MANAGE_MISSIONS
* @param { string } deviceId - Indicates the device to be queried.
- * @param { number } missionId - Indicates mission id to be queried.
+ * @param { int } missionId - Indicates mission id to be queried.
* @param { AsyncCallback } callback - The callback is used to return the MissionInfo of the given id.
* @throws { BusinessError } 201 - Permission denied.
* @throws { BusinessError } 202 - Not system application.
@@ -99,16 +102,17 @@ declare namespace missionManager {
* 2. Incorrect parameter types; 3. Parameter verification failed.
* @syscap SystemCapability.Ability.AbilityRuntime.Mission
* @systemapi
- * @since 9
+ * @since arkts {'1.1':'9', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
- function getMissionInfo(deviceId: string, missionId: number, callback: AsyncCallback): void;
+ function getMissionInfo(deviceId: string, missionId: int, callback: AsyncCallback): void;
/**
* Get the missionInfo with the given missionId.
*
* @permission ohos.permission.MANAGE_MISSIONS
* @param { string } deviceId - Indicates the device to be queried.
- * @param { number } missionId - Indicates mission id to be queried.
+ * @param { int } missionId - Indicates mission id to be queried.
* @returns { Promise } Returns the MissionInfo of the given id.
* @throws { BusinessError } 201 - Permission denied.
* @throws { BusinessError } 202 - Not system application.
@@ -116,9 +120,10 @@ declare namespace missionManager {
* 2. Incorrect parameter types; 3. Parameter verification failed.
* @syscap SystemCapability.Ability.AbilityRuntime.Mission
* @systemapi
- * @since 9
+ * @since arkts {'1.1':'9', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
- function getMissionInfo(deviceId: string, missionId: number): Promise;
+ function getMissionInfo(deviceId: string, missionId: int): Promise;
/**
* Get missionInfos in the given deviceId with maximum number of numMax.
@@ -502,7 +507,8 @@ declare namespace missionManager {
* @typedef { _MissionInfo }
* @syscap SystemCapability.Ability.AbilityRuntime.Mission
* @systemapi
- * @since 9
+ * @since arkts {'1.1':'9', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
export type MissionInfo = _MissionInfo;
diff --git a/api/@ohos.app.ability.quickFixManager.d.ts b/api/@ohos.app.ability.quickFixManager.d.ts
index 99f73be5ae201716f72688906f17422d2032a847..77da4a09053a7cbba4c44e861499d37f979b2119 100644
--- a/api/@ohos.app.ability.quickFixManager.d.ts
+++ b/api/@ohos.app.ability.quickFixManager.d.ts
@@ -95,13 +95,13 @@ declare namespace quickFixManager {
/**
* The version number of the bundle.
*
- * @type { number }
+ * @type { long }
* @readonly
* @syscap SystemCapability.Ability.AbilityRuntime.QuickFix
* @systemapi
* @since 9
*/
- readonly bundleVersionCode: number;
+ readonly bundleVersionCode: long;
/**
* The version name of the bundle.
@@ -117,13 +117,13 @@ declare namespace quickFixManager {
/**
* The version number of the quick fix.
*
- * @type { number }
+ * @type { long }
* @readonly
* @syscap SystemCapability.Ability.AbilityRuntime.QuickFix
* @systemapi
* @since 9
*/
- readonly quickFixVersionCode: number;
+ readonly quickFixVersionCode: long;
/**
* The version name of the quick fix.
diff --git a/api/@ohos.app.ability.wantAgent.d.ts b/api/@ohos.app.ability.wantAgent.d.ts
index f61ab3080be00821d2ca6533c43c768ba5645028..c06e02e9fb1616b147e9c5ff6c813ad855eefd23 100644
--- a/api/@ohos.app.ability.wantAgent.d.ts
+++ b/api/@ohos.app.ability.wantAgent.d.ts
@@ -127,16 +127,17 @@ declare namespace wantAgent {
* This API uses an asynchronous callback to return the result.
*
* @param { WantAgent } agent - Target WantAgent object.
- * @param { AsyncCallback } callback - Callback used to return the user ID.
+ * @param { AsyncCallback } callback - Callback used to return the user ID.
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
* 2. Incorrect parameter types.
* @throws { BusinessError } 16000007 - Service busy. There are concurrent tasks. Try again later.
* @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 getUid(agent: WantAgent, callback: AsyncCallback): void;
+ function getUid(agent: WantAgent, callback: AsyncCallback): void;
/**
* Obtains the UID of a WantAgent.
@@ -155,16 +156,17 @@ declare namespace wantAgent {
* This API uses a promise to return the result.
*
* @param { WantAgent } agent - Target WantAgent object.
- * @returns { Promise } Promise used to return the user ID.
+ * @returns { Promise } Promise used to return the user ID.
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
* 2. Incorrect parameter types.
* @throws { BusinessError } 16000007 - Service busy. There are concurrent tasks. Try again later.
* @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 getUid(agent: WantAgent): Promise;
+ function getUid(agent: WantAgent): Promise;
/**
* Obtains the Want in a WantAgent object.
@@ -453,7 +455,7 @@ declare namespace wantAgent {
* This API uses an asynchronous callback to return the result.
*
* @param { WantAgent } agent - Target WantAgent object.
- * @param { AsyncCallback } callback - Callback used to return the operation type.
+ * @param { AsyncCallback } callback - Callback used to return the operation type.
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
* 2. Incorrect parameter types.
* @throws { BusinessError } 16000007 - Service busy. There are concurrent tasks. Try again later.
@@ -464,7 +466,7 @@ declare namespace wantAgent {
* @since arkts {'1.1':'12', '1.2':'20'}
* @arkts 1.1&1.2
*/
- function getOperationType(agent: WantAgent, callback: AsyncCallback): void;
+ function getOperationType(agent: WantAgent, callback: AsyncCallback): void;
/**
* Obtains the {@link OperationType} of a WantAgent.
@@ -484,7 +486,7 @@ declare namespace wantAgent {
* This API uses a promise to return the result.
*
* @param { WantAgent } agent - Indicates the WantAgent.
- * @returns { Promise } Returns the OperationType of the WantAgent.
+ * @returns { Promise } Returns the OperationType of the WantAgent.
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
* 2. Incorrect parameter types.
* @throws { BusinessError } 16000007 - Service busy. There are concurrent tasks. Try again later.
@@ -495,7 +497,7 @@ declare namespace wantAgent {
* @since arkts {'1.1':'12', '1.2':'20'}
* @arkts 1.1&1.2
*/
- function getOperationType(agent: WantAgent): Promise;
+ function getOperationType(agent: WantAgent): Promise;
/**
* Enables or disables the WantAgent multithreading feature.
@@ -889,7 +891,8 @@ declare namespace wantAgent {
* @type { WantAgent }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @atomicservice
- * @since 12
+ * @since arkts {'1.1':'12', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
info: WantAgent;
@@ -906,7 +909,8 @@ declare namespace wantAgent {
* @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;
@@ -920,12 +924,13 @@ declare namespace wantAgent {
/**
* Request code that triggers the WantAgent object.
*
- * @type { number }
+ * @type { int }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @atomicservice
- * @since 12
+ * @since arkts {'1.1':'12', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
- finalCode: number;
+ finalCode: int;
/**
* Final data collected by the common event.
@@ -940,7 +945,8 @@ declare namespace wantAgent {
* @type { string }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @atomicservice
- * @since 12
+ * @since arkts {'1.1':'12', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
finalData: string;
@@ -964,7 +970,8 @@ declare namespace wantAgent {
* @type { ?Record }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @atomicservice
- * @since 12
+ * @since arkts {'1.1':'12', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
extraInfo?: Record;
}
diff --git a/api/@ohos.app.appstartup.StartupConfig.d.ts b/api/@ohos.app.appstartup.StartupConfig.d.ts
index 8e5917b48b69e1244a6a0b4f15e96c20fb282ae4..41bef11f66bc59e1e9ab09373931c638b22da1bd 100644
--- a/api/@ohos.app.appstartup.StartupConfig.d.ts
+++ b/api/@ohos.app.appstartup.StartupConfig.d.ts
@@ -32,13 +32,13 @@ export default interface StartupConfig {
/**
* Indicates timeout for executing all startup tasks. Default value is 10000 milliseconds.
*
- * @type { ?number }
+ * @type { ?int }
* @default 10000
* @syscap SystemCapability.Ability.AppStartup
* @stagemodelonly
* @since 12
*/
- timeoutMs?: number;
+ timeoutMs?: int;
/**
* Indicates a listener for startup, which will be called when all tasks complete.
diff --git a/api/@ohos.application.uriPermissionManager.d.ts b/api/@ohos.application.uriPermissionManager.d.ts
index c4114ab741e5031dafcf0b130e4e6b4b6d61cc2b..a69039892adab18053fd025b77e7229268af766d 100644
--- a/api/@ohos.application.uriPermissionManager.d.ts
+++ b/api/@ohos.application.uriPermissionManager.d.ts
@@ -169,7 +169,7 @@ declare namespace uriPermissionManager {
* wantConstant.Flags.FLAG_AUTH_WRITE_URI_PERMISSION or
* wantConstant.Flags.FLAG_AUTH_PERSISTABLE_URI_PERMISSION.
* @param { string } targetBundleName - Indicates the bundle name of authorization target.
- * @param { number } appCloneIndex - Indicates the clone index of target application.
+ * @param { int } appCloneIndex - Indicates the clone index of target application.
* @returns { Promise } - the promise returned by the function.
* @throws { BusinessError } 201 - Permission denied.
* @throws { BusinessError } 202 - Not System App. Interface caller is not a system app.
@@ -187,7 +187,7 @@ declare namespace uriPermissionManager {
* @since arkts {'1.1':'19', '1.2':'20'}
* @arkts 1.1&1.2
*/
- function grantUriPermission(uri: string, flag: wantConstant.Flags, targetBundleName: string, appCloneIndex: number): Promise;
+ function grantUriPermission(uri: string, flag: wantConstant.Flags, targetBundleName: string, appCloneIndex: int): Promise;
/**
* Revoke URI from one application
@@ -320,7 +320,7 @@ declare namespace uriPermissionManager {
*
* @param { string } uri - File URI.
* @param { string } targetBundleName - Indicates the bundle name of authorization target.
- * @param { number } appCloneIndex - Indicates the clone index of target application.
+ * @param { int } appCloneIndex - Indicates the clone index of target application.
* @returns { Promise } - the promise returned by the function.
* @throws { BusinessError } 202 - Not System App. Interface caller is not a system app.
* @throws { BusinessError } 401 - Parameter error. Possible causes:
@@ -335,7 +335,7 @@ declare namespace uriPermissionManager {
* @since arkts {'1.1':'19', '1.2':'20'}
* @arkts 1.1&1.2
*/
- function revokeUriPermission(uri: string, targetBundleName: string, appCloneIndex: number): Promise;
+ function revokeUriPermission(uri: string, targetBundleName: string, appCloneIndex: int): Promise;
/**
* Grant URIs in UDkey to another application
@@ -343,7 +343,7 @@ declare namespace uriPermissionManager {
* @param { wantConstant.Flags } flag - wantConstant.Flags.FLAG_AUTH_READ_URI_PERMISSION,
* wantConstant.Flags.FLAG_AUTH_WRITE_URI_PERMISSION or
* wantConstant.Flags.FLAG_AUTH_PERSISTABLE_URI_PERMISSION.
- * @param { number } targetTokenId - Indicates the token id of target application.
+ * @param { int } targetTokenId - Indicates the token id of target application.
* @returns { Promise } - The promise returned by the function.
* @throws { BusinessError } 202 - Not System App. Interface caller is not a system app.
* @throws { BusinessError } 801 - Capability not supported.
@@ -357,7 +357,7 @@ declare namespace uriPermissionManager {
* @systemapi Hide this for inner system use.
* @since 20
*/
- function grantUriPermissionByKey(key: string, flag: wantConstant.Flags, targetTokenId: number): Promise;
+ function grantUriPermissionByKey(key: string, flag: wantConstant.Flags, targetTokenId: int): Promise;
/**
* Grant URIs in UDkey to another application
@@ -366,8 +366,8 @@ declare namespace uriPermissionManager {
* @param { wantConstant.Flags } flag - wantConstant.Flags.FLAG_AUTH_READ_URI_PERMISSION,
* wantConstant.Flags.FLAG_AUTH_WRITE_URI_PERMISSION or
* wantConstant.Flags.FLAG_AUTH_PERSISTABLE_URI_PERMISSION.
- * @param { number } callerTokenId - Indicates the token id of caller application.
- * @param { number } targetTokenId - Indicates the token id of target application.
+ * @param { int } callerTokenId - Indicates the token id of caller application.
+ * @param { int } targetTokenId - Indicates the token id of target application.
* @returns { Promise } - The promise returned by the function.
* @throws { BusinessError } 201 - Permission denied.
* @throws { BusinessError } 202 - Not System App. Interface caller is not a system app.
@@ -383,7 +383,7 @@ declare namespace uriPermissionManager {
* @systemapi Hide this for inner system use.
* @since 20
*/
- function grantUriPermissionByKeyAsCaller(key: string, flag: wantConstant.Flags, callerTokenId: number, targetTokenId: number): Promise;
+ function grantUriPermissionByKeyAsCaller(key: string, flag: wantConstant.Flags, callerTokenId: int, targetTokenId: int): Promise;
}
export default uriPermissionManager;
\ No newline at end of file
diff --git a/api/ability/abilityResult.d.ts b/api/ability/abilityResult.d.ts
index 636c91f97b799ca30d97f39dfab5a426d396d39e..b8036da5a3e603b645178797c9baa8d95fb596eb 100644
--- a/api/ability/abilityResult.d.ts
+++ b/api/ability/abilityResult.d.ts
@@ -45,13 +45,13 @@ export interface AbilityResult {
* Indicates the result code returned after the ability is destroyed. You can define the result
* code to identify an error.
*
- * @type { number }
+ * @type { int }
* @syscap SystemCapability.Ability.AbilityBase
* @atomicservice
* @since arkts {'1.1':'11', '1.2':'20'}
* @arkts 1.1&1.2
*/
- resultCode: number;
+ resultCode: int;
/**
* Indicates the data returned after the ability is destroyed. You can define the data returned.
diff --git a/api/ability/connectOptions.d.ts b/api/ability/connectOptions.d.ts
index 7a911505f6f8f88d6516627466d5b71a3d5740b0..ba55aa9e5dd74b7d6e5545c3d6f18fb24ab8c6f8 100644
--- a/api/ability/connectOptions.d.ts
+++ b/api/ability/connectOptions.d.ts
@@ -27,7 +27,8 @@ import rpc from './../@ohos.rpc';
*
* @interface ConnectOptions
* @syscap SystemCapability.Ability.AbilityRuntime.Core
- * @since 7
+ * @since arkts {'1.1':'7', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
export interface ConnectOptions {
/**
@@ -44,7 +45,8 @@ export interface ConnectOptions {
* @param { ElementName } elementName - The ohos.bundleManager.ElementName object of the service ability
* @param { rpc.IRemoteObject } remote - The remote object instance
* @syscap SystemCapability.Ability.AbilityRuntime.Core
- * @since 12
+ * @since arkts {'1.1':'12', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
onConnect(elementName: ElementName, remote: rpc.IRemoteObject): void;
@@ -60,16 +62,18 @@ export interface ConnectOptions {
*
* @param { ElementName } elementName - The ohos.bundleManager.ElementName object of the service ability
* @syscap SystemCapability.Ability.AbilityRuntime.Core
- * @since 12
+ * @since arkts {'1.1':'12', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
onDisconnect(elementName: ElementName): void;
/**
* The callback interface was connect failed.
*
- * @param { number } code - The error code of the failed.
+ * @param { int } code - The error code of the failed.
* @syscap SystemCapability.Ability.AbilityRuntime.Core
- * @since 7
+ * @since arkts {'1.1':'7', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
- onFailed(code: number): void;
+ onFailed(code: int): void;
}
diff --git a/api/app/processInfo.d.ts b/api/app/processInfo.d.ts
index 8c09ec06987c5b8165e3fbf52e70b7dc8029f4d8..ad16729547778794c48143d82d873d9cba536dd3 100644
--- a/api/app/processInfo.d.ts
+++ b/api/app/processInfo.d.ts
@@ -27,11 +27,11 @@ export interface ProcessInfo {
/**
* The id of the current process
*
- * @type { number }
+ * @type { int }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @since 7
*/
- pid: number;
+ pid: int;
/**
* The name of the current process
diff --git a/api/application/AbilityDelegator.d.ts b/api/application/AbilityDelegator.d.ts
index d7a91d0bf75b39ceff7ed9a8d674814f5a59ebf3..ab449c33aef0d05db9aac8a613342ad7910b7440 100644
--- a/api/application/AbilityDelegator.d.ts
+++ b/api/application/AbilityDelegator.d.ts
@@ -500,7 +500,7 @@ export interface AbilityDelegator {
* Wait for and returns the Ability object that matches the conditions set in the given AbilityMonitor.
*
* @param { AbilityMonitor } monitor - AbilityMonitor object.
- * @param { number } timeout - Maximum wait time, in milliseconds.
+ * @param { long } timeout - Maximum wait time, in milliseconds.
* @param { AsyncCallback } callback - The callback is used to return the Ability object.
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified. 2.Incorrect parameter types.
* @throws { BusinessError } 16000100 - Calling WaitAbilityMonitor failed.
@@ -510,7 +510,7 @@ export interface AbilityDelegator {
* @since arkts {'1.1':'11', '1.2':'20'}
* @arkts 1.1&1.2
*/
- waitAbilityMonitor(monitor: AbilityMonitor, timeout: number, callback: AsyncCallback): void;
+ waitAbilityMonitor(monitor: AbilityMonitor, timeout: long, callback: AsyncCallback): void;
/**
* Wait for and returns the Ability object that matches the conditions set in the given AbilityMonitor.
@@ -539,7 +539,7 @@ export interface AbilityDelegator {
* Wait for and returns the Ability object that matches the conditions set in the given AbilityMonitor.
*
* @param { AbilityMonitor } monitor - AbilityMonitor object.
- * @param { number } [timeout] - Maximum wait time, in milliseconds.
+ * @param { long } [timeout] - Maximum wait time, in milliseconds.
* @returns { Promise } Returns the Ability object.
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified. 2.Incorrect parameter types.
* @throws { BusinessError } 16000100 - Calling WaitAbilityMonitor failed.
@@ -549,7 +549,7 @@ export interface AbilityDelegator {
* @since arkts {'1.1':'11', '1.2':'20'}
* @arkts 1.1&1.2
*/
- waitAbilityMonitor(monitor: AbilityMonitor, timeout?: number): Promise;
+ waitAbilityMonitor(monitor: AbilityMonitor, timeout?: long): Promise;
/**
* Wait for and returns the AbilityStage object that matches the conditions set in the given AbilityStageMonitor.
@@ -614,7 +614,7 @@ export interface AbilityDelegator {
* Wait for and returns the AbilityStage object that matches the conditions set in the given AbilityStageMonitor.
*
* @param { AbilityStageMonitor } monitor - AbilityStageMonitor object.
- * @param { number } timeout - Maximum wait time, in milliseconds.
+ * @param { long } timeout - Maximum wait time, in milliseconds.
* @param { AsyncCallback } callback - The callback is used to return the AbilityStage object.
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified. 2.Incorrect parameter types.
* @throws { BusinessError } 16000100 - Calling WaitAbilityStageMonitor failed.
@@ -624,7 +624,7 @@ export interface AbilityDelegator {
* @since arkts {'1.1':'11', '1.2':'20'}
* @arkts 1.1&1.2
*/
- waitAbilityStageMonitor(monitor: AbilityStageMonitor, timeout: number, callback: AsyncCallback): void;
+ waitAbilityStageMonitor(monitor: AbilityStageMonitor, timeout: long, callback: AsyncCallback): void;
/**
* Wait for and returns the AbilityStage object that matches the conditions set in the given AbilityStageMonitor.
@@ -653,7 +653,7 @@ export interface AbilityDelegator {
* Wait for and returns the AbilityStage object that matches the conditions set in the given AbilityStageMonitor.
*
* @param { AbilityStageMonitor } monitor - AbilityStageMonitor object.
- * @param { number } [timeout] - Maximum wait time, in milliseconds.
+ * @param { long } [timeout] - Maximum wait time, in milliseconds.
* @returns { Promise } Returns the AbilityStage object.
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified. 2.Incorrect parameter types.
* @throws { BusinessError } 16000100 - Calling WaitAbilityStageMonitor failed.
@@ -663,7 +663,7 @@ export interface AbilityDelegator {
* @since arkts {'1.1':'11', '1.2':'20'}
* @arkts 1.1&1.2
*/
- waitAbilityStageMonitor(monitor: AbilityStageMonitor, timeout?: number): Promise;
+ waitAbilityStageMonitor(monitor: AbilityStageMonitor, timeout?: long): Promise;
/**
* Obtain the application context.
@@ -715,7 +715,7 @@ export interface AbilityDelegator {
* Obtain the lifecycle state of a specified ability.
*
* @param { UIAbility } ability - The Ability object.
- * @returns { number } Returns the state of the Ability object.
+ * @returns { int } Returns the state of the Ability object.
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified. 2.Incorrect parameter types.
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @crossplatform
@@ -723,7 +723,7 @@ export interface AbilityDelegator {
* @since arkts {'1.1':'11', '1.2':'20'}
* @arkts 1.1&1.2
*/
- getAbilityState(ability: UIAbility): number;
+ getAbilityState(ability: UIAbility): int;
/**
* Obtain the ability that is currently being displayed in this process.
@@ -1216,14 +1216,14 @@ export interface AbilityDelegator {
* Execute the given command in the aa tools side.
*
* @param { string } cmd - Shell command
- * @param { number } timeoutSecs - Timeout, in seconds
+ * @param { long } timeoutSecs - Timeout, in seconds
* @param { AsyncCallback } callback - The callback of executeShellCommand.
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @atomicservice
* @since arkts {'1.1':'11', '1.2':'20'}
* @arkts 1.1&1.2
*/
- executeShellCommand(cmd: string, timeoutSecs: number, callback: AsyncCallback): void;
+ executeShellCommand(cmd: string, timeoutSecs: long, callback: AsyncCallback): void;
/**
* Execute the given command in the aa tools side.
@@ -1238,14 +1238,14 @@ export interface AbilityDelegator {
* Execute the given command in the aa tools side.
*
* @param { string } cmd - Shell command
- * @param { number } [timeoutSecs] - Timeout, in seconds
+ * @param { long } [timeoutSecs] - Timeout, in seconds
* @returns { Promise } the promise returned by the function.
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @atomicservice
* @since arkts {'1.1':'11', '1.2':'20'}
* @arkts 1.1&1.2
*/
- executeShellCommand(cmd: string, timeoutSecs?: number): Promise;
+ executeShellCommand(cmd: string, timeoutSecs?: long): Promise;
/**
* Finish the test and print log information to the unit testing console.
@@ -1277,7 +1277,7 @@ export interface AbilityDelegator {
* The total length of the log information to be printed cannot exceed 1000 characters.
*
* @param { string } msg - Log information.
- * @param { number } code - Result code.
+ * @param { long } code - Result code.
* @param { AsyncCallback } callback - The callback of finishTest.
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified. 2.Incorrect parameter types.
* @throws { BusinessError } 16000100 - Calling FinishTest failed.
@@ -1287,7 +1287,7 @@ export interface AbilityDelegator {
* @since arkts {'1.1':'11', '1.2':'20'}
* @arkts 1.1&1.2
*/
- finishTest(msg: string, code: number, callback: AsyncCallback): void;
+ finishTest(msg: string, code: long, callback: AsyncCallback): void;
/**
* Finish the test and print log information to the unit testing console.
@@ -1319,7 +1319,7 @@ export interface AbilityDelegator {
* The total length of the log information to be printed cannot exceed 1000 characters.
*
* @param { string } msg - Log information.
- * @param { number } code - Result code.
+ * @param { long } code - Result code.
* @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.
* @throws { BusinessError } 16000100 - Calling FinishTest failed.
@@ -1329,7 +1329,7 @@ export interface AbilityDelegator {
* @since arkts {'1.1':'11', '1.2':'20'}
* @arkts 1.1&1.2
*/
- finishTest(msg: string, code: number): Promise;
+ finishTest(msg: string, code: long): Promise;
/**
* Used to set a list of mock data.
diff --git a/api/application/AbilityFirstFrameStateData.d.ts b/api/application/AbilityFirstFrameStateData.d.ts
index 6403ed97c0f4cee52f4c7b46f9a7e3e900b28611..39f4a8b803f6fc467ae6041bbeec1a4d31df5f24 100644
--- a/api/application/AbilityFirstFrameStateData.d.ts
+++ b/api/application/AbilityFirstFrameStateData.d.ts
@@ -60,13 +60,13 @@ export interface AbilityFirstFrameStateData {
/**
* The index of DLP sandbox.
*
- * @type { number }
+ * @type { int }
* @default 0
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @systemapi
* @since 12
*/
- appIndex: number;
+ appIndex: int;
/**
* The entry ability of application is cold-start return true, others false.
diff --git a/api/application/AbilityRunningInfo.d.ts b/api/application/AbilityRunningInfo.d.ts
index d19e8366d30ab65a4ca3aed75a1c5f306d264171..a51812ad4518019f406a3c5563a334dcba1b003f 100644
--- a/api/application/AbilityRunningInfo.d.ts
+++ b/api/application/AbilityRunningInfo.d.ts
@@ -26,7 +26,8 @@ import abilityManager from '../@ohos.app.ability.abilityManager';
*
* @typedef AbilityRunningInfo
* @syscap SystemCapability.Ability.AbilityRuntime.Core
- * @since 14
+ * @since arkts {'1.1':'14', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
export interface AbilityRunningInfo {
/**
@@ -43,29 +44,32 @@ export interface AbilityRunningInfo {
* @type { ElementName }
* @default the ohos.bundleManager.ElementName object of the ability.
* @syscap SystemCapability.Ability.AbilityRuntime.Core
- * @since 14
+ * @since arkts {'1.1':'14', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
ability: ElementName;
/**
* Process ID.
*
- * @type { number }
+ * @type { int }
* @default process id
* @syscap SystemCapability.Ability.AbilityRuntime.Core
- * @since 14
+ * @since arkts {'1.1':'14', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
- pid: number;
+ pid: int;
/**
* User ID.
*
- * @type { number }
+ * @type { int }
* @default user id
* @syscap SystemCapability.Ability.AbilityRuntime.Core
- * @since 14
+ * @since arkts {'1.1':'14', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
- uid: number;
+ uid: int;
/**
* Process name.
@@ -73,19 +77,21 @@ export interface AbilityRunningInfo {
* @type { string }
* @default the name of the process
* @syscap SystemCapability.Ability.AbilityRuntime.Core
- * @since 14
+ * @since arkts {'1.1':'14', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
processName: string;
/**
* Ability startup time.
*
- * @type { number }
+ * @type { long }
* @default ability start time
* @syscap SystemCapability.Ability.AbilityRuntime.Core
- * @since 14
+ * @since arkts {'1.1':'14', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
- startTime: number;
+ startTime: long;
/**
* Ability status.
@@ -93,7 +99,8 @@ export interface AbilityRunningInfo {
* @type { abilityManager.AbilityState }
* @default Enumerates state of the ability state info
* @syscap SystemCapability.Ability.AbilityRuntime.Core
- * @since 14
+ * @since arkts {'1.1':'14', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
abilityState: abilityManager.AbilityState;
}
diff --git a/api/application/AbilityStartCallback.d.ts b/api/application/AbilityStartCallback.d.ts
index 53953365b2e4d802a977c03cabeb850a2547de33..670f319f73733b1d6e7d6c123fdb8c1ed9981b16 100644
--- a/api/application/AbilityStartCallback.d.ts
+++ b/api/application/AbilityStartCallback.d.ts
@@ -21,17 +21,46 @@
/*** if arkts 1.1 */
import type { AbilityResult } from '../ability/abilityResult';
/*** endif */
+/*** if arkts 1.2 */
+import { AbilityResult } from '../ability/abilityResult';
+/*** endif */
+
+
+/**
+ * Defines a onResult function.
+ *
+ * @typedef { function } OnResultFn
+ * @param { AbilityResult } parameter - The Parameter returned if the UIExtensionAbility call terminateSelfWithResult.
+ * @syscap SystemCapability.Ability.AbilityRuntime.Core
+ * @since 20
+ * @arkts 1.2
+ */
+type OnResultFn = (parameter: AbilityResult) => void;
+/*** if arkts 1.1 */
/**
* The callback of UIAbility or UIExtensionAbility.
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @stagemodelonly
* @atomicservice
- * @since arkts {'1.1':'11', '1.2':'20'}
- * @arkts 1.1&1.2
+ * @since 11
*/
export default class AbilityStartCallback {
+/*** endif */
+/*** if arkts 1.2 */
+/**
+ * The callback of UIAbility or UIExtensionAbility.
+ *
+ * @typedef AbilityStartCallback
+ * @syscap SystemCapability.Ability.AbilityRuntime.Core
+ * @stagemodelonly
+ * @atomicservice
+ * @since 20
+ * @arkts 1.2
+ */
+declare interface AbilityStartCallback {
+/*** endif */
/**
* Called when some error occurred except disconnected from UIAbility or UIExtensionAbility.
*
@@ -41,7 +70,8 @@ export default class AbilityStartCallback {
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @stagemodelonly
* @atomicservice
- * @since 11
+ * @since arkts {'1.1':'11', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
onError(code: number, name: string, message: string): void;
@@ -55,4 +85,19 @@ export default class AbilityStartCallback {
* @since 12
*/
onResult?(parameter: AbilityResult): void;
+
+ /**
+ * Called when UIExtensionAbility terminate with result.
+ *
+ * @type { ?OnResultFn }
+ * @syscap SystemCapability.Ability.AbilityRuntime.Core
+ * @stagemodelonly
+ * @since 20
+ * @arkts 1.2
+ */
+ onResult?: OnResultFn;
}
+
+/*** if arkts 1.2 */
+export default AbilityStartCallback;
+/*** endif */
\ No newline at end of file
diff --git a/api/application/AbilityStateData.d.ts b/api/application/AbilityStateData.d.ts
index 2512f35105b7a5c854783ab7b64c1d54e145d38c..f1af499c0fd183564f44066802105521ceeb3d89 100644
--- a/api/application/AbilityStateData.d.ts
+++ b/api/application/AbilityStateData.d.ts
@@ -59,42 +59,42 @@ declare class AbilityStateData {
/**
* The pid.
*
- * @type { number }
+ * @type { int }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @since arkts {'1.1':'14', '1.2':'20'}
* @arkts 1.1&1.2
*/
- pid: number;
+ pid: int;
/**
* The uid.
*
- * @type { number }
+ * @type { int }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @since arkts {'1.1':'14', '1.2':'20'}
* @arkts 1.1&1.2
*/
- uid: number;
+ uid: int;
/**
* The application state.
*
- * @type { number }
+ * @type { int }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @since arkts {'1.1':'14', '1.2':'20'}
* @arkts 1.1&1.2
*/
- state: number;
+ state: int;
/**
* The ability type, page or service and so on.
*
- * @type { number }
+ * @type { int }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @since arkts {'1.1':'14', '1.2':'20'}
* @arkts 1.1&1.2
*/
- abilityType: number;
+ abilityType: int;
/**
* Indicates whether the application is atomic service.
@@ -108,12 +108,12 @@ declare class AbilityStateData {
/**
* The app clone index of ability instance.
- * @type { ?number }
+ * @type { ?int }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @since arkts {'1.1':'14', '1.2':'20'}
* @arkts 1.1&1.2
*/
- appCloneIndex?: number;
+ appCloneIndex?: int;
}
export default AbilityStateData;
\ No newline at end of file
diff --git a/api/application/ApplicationContext.d.ts b/api/application/ApplicationContext.d.ts
index e4777379ad5c0ff3384a9735a5fbb707486294f6..95a70ca941945d37c645a73cde0c0dbc1930cd45 100644
--- a/api/application/ApplicationContext.d.ts
+++ b/api/application/ApplicationContext.d.ts
@@ -23,11 +23,14 @@ import { AsyncCallback } from '../@ohos.base';
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 AbilityLifecycleCallback from '../@ohos.app.ability.AbilityLifecycleCallback';
+/*** if arkts 1.1 */
import type ApplicationStateChangeCallback from '../@ohos.app.ability.ApplicationStateChangeCallback';
/*** endif */
+/*** if arkts 1.2 */
+import ApplicationStateChangeCallback from '../@ohos.app.ability.ApplicationStateChangeCallback';
+/*** endif */
/**
* The context of an application. It allows access to application-specific resources.
@@ -92,16 +95,17 @@ declare class ApplicationContext extends Context {
*
* @param { 'abilityLifecycle' } type - Event type.
* @param { AbilityLifecycleCallback } callback - Callback used to return the ID of the registered listener.
- * @returns { number } Returns the number code of the callback.
+ * @returns { int } Returns the number code of the callback.
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified.
* 2.Incorrect parameter types.
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @stagemodelonly
* @crossplatform
* @atomicservice
- * @since 11
+ * @since arkts {'1.1':'11', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
- on(type: 'abilityLifecycle', callback: AbilityLifecycleCallback): number;
+ on(type: 'abilityLifecycle', callback: AbilityLifecycleCallback): int;
/**
* Unregister ability lifecycle callback.
@@ -135,7 +139,7 @@ declare class ApplicationContext extends Context {
*
*
* @param { 'abilityLifecycle' } type - Event type.
- * @param { number } callbackId - ID of the listener to unregister.
+ * @param { int } callbackId - ID of the listener to unregister.
* @param { AsyncCallback } callback - Callback used to return the result. If the deregistration is successful,
* err is undefined. Otherwise, err is an error object.
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified.
@@ -144,9 +148,10 @@ declare class ApplicationContext extends Context {
* @stagemodelonly
* @crossplatform
* @atomicservice
- * @since 11
+ * @since arkts {'1.1':'11', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
- off(type: 'abilityLifecycle', callbackId: number, callback: AsyncCallback): void;
+ off(type: 'abilityLifecycle', callbackId: int, callback: AsyncCallback): void;
/**
* Unregister ability lifecycle callback.
@@ -180,7 +185,7 @@ declare class ApplicationContext extends Context {
*
*
* @param { 'abilityLifecycle' } type - Event type.
- * @param { number } callbackId - ID of the listener to unregister.
+ * @param { int } callbackId - ID of the listener to unregister.
* @returns { Promise } Promise that returns no value.
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified.
* 2.Incorrect parameter types.
@@ -188,9 +193,10 @@ declare class ApplicationContext extends Context {
* @stagemodelonly
* @crossplatform
* @atomicservice
- * @since 12
+ * @since arkts {'1.1':'12', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
- off(type: 'abilityLifecycle', callbackId: number): Promise;
+ off(type: 'abilityLifecycle', callbackId: int): Promise;
/**
* Register environment callback.
@@ -204,25 +210,19 @@ declare class ApplicationContext extends Context {
* @since 9
*/
/**
- * Registers a listener for system environment changes.
- * This API uses an asynchronous callback to return the result.
- *
- * **NOTE**:
- *
It can be called only by the main thread.
- *
+ * Register environment callback.
*
- * @param { 'environment' } type - Event type.
- * @param { EnvironmentCallback } callback - Callback used to return the system environment changes.
- * @returns { number } ID of the registered listener. The ID is incremented by 1 each time the listener is
- * registered. When the ID exceeds 2^63-1, -1 is returned.
- * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified.
- * 2.Incorrect parameter types.
+ * @param { 'environment' } type - environment.
+ * @param { EnvironmentCallback } callback - The environment callback.
+ * @returns { int } Returns the number code of the callback.
+ * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified. 2.Incorrect parameter types.
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @stagemodelonly
* @atomicservice
- * @since 11
+ * @since arkts {'1.1':'11', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
- on(type: 'environment', callback: EnvironmentCallback): number;
+ on(type: 'environment', callback: EnvironmentCallback): int;
/**
* Unregister environment callback.
@@ -236,25 +236,19 @@ declare class ApplicationContext extends Context {
* @since 9
*/
/**
- * Unregisters the listener for system environment changes.
- * This API uses an asynchronous callback to return the result.
- *
- * **NOTE**:
- *
It can be called only by the main thread.
- *
+ * Unregister environment callback.
*
- * @param { 'environment' } type - Event type.
- * @param { number } callbackId - ID of the listener to unregister.
- * @param { AsyncCallback } callback - Callback used to return the result. If the deregistration is successful,
- * err is undefined. Otherwise, err is an error object.
- * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified.
- * 2.Incorrect parameter types.
+ * @param { 'environment' } type - environment.
+ * @param { int } callbackId - Indicates the number code of the callback.
+ * @param { AsyncCallback } callback - The callback of unregisterEnvironmentCallback.
+ * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified. 2.Incorrect parameter types.
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @stagemodelonly
* @atomicservice
- * @since 11
+ * @since arkts {'1.1':'11', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
- off(type: 'environment', callbackId: number, callback: AsyncCallback): void;
+ off(type: 'environment', callbackId: int, callback: AsyncCallback): void;
/**
* Unregister environment callback.
@@ -268,24 +262,19 @@ declare class ApplicationContext extends Context {
* @since 9
*/
/**
- * Unregisters the listener for system environment changes.
- * This API uses a promise to return the result.
- *
- * **NOTE**:
- *
It can be called only by the main thread.
- *
+ * Unregister environment callback.
*
- * @param { 'environment' } type - Event type.
- * @param { number } callbackId - ID of the listener to unregister.
- * @returns { Promise } Promise that returns no value.
- * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified.
- * 2.Incorrect parameter types.
+ * @param { 'environment' } type - environment.
+ * @param { int } callbackId - Indicates the number code of the callback.
+ * @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.
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @stagemodelonly
* @atomicservice
- * @since 11
+ * @since arkts {'1.1':'11', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
- off(type: 'environment', callbackId: number): Promise;
+ off(type: 'environment', callbackId: int): Promise;
/**
* Register applicationStateChange callback.
@@ -326,7 +315,8 @@ declare class ApplicationContext extends Context {
* @stagemodelonly
* @crossplatform
* @atomicservice
- * @since 18
+ * @since arkts {'1.1':'18', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
on(type: 'applicationStateChange', callback: ApplicationStateChangeCallback): void;
@@ -371,7 +361,8 @@ declare class ApplicationContext extends Context {
* @stagemodelonly
* @crossplatform
* @atomicservice
- * @since 18
+ * @since arkts {'1.1':'18', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
off(type: 'applicationStateChange', callback?: ApplicationStateChangeCallback): void;
@@ -549,6 +540,20 @@ declare class ApplicationContext extends Context {
*/
killAllProcesses(callback: AsyncCallback);
+ /**
+ * Kill all processes of the application
+ *
+ * @param { AsyncCallback } callback - The callback of killAllProcesses.
+ * @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified. 2.Incorrect parameter types.
+ * @throws { BusinessError } 16000011 - The context does not exist.
+ * @syscap SystemCapability.Ability.AbilityRuntime.Core
+ * @stagemodelonly
+ * @atomicservice
+ * @since 20
+ * @arkts 1.2
+ */
+ killAllProcesses(callback: AsyncCallback): void;
+
/**
* Set colorMode of the application
*
@@ -743,28 +748,22 @@ declare class ApplicationContext extends Context {
setFont(font: string): void;
/**
- * Obtains the index of the current application clone.
+ * Get current app clone index.
*
- * @returns { number } Index of the current application clone.
+ * @returns { int } Returns the app clone index for current app.
* @throws { BusinessError } 16000011 - The context does not exist.
- * @throws { BusinessError } 16000071 - App clone is not supported.
+ * @throws { BusinessError } 16000071 - The MultiAppMode is not {@link App_CLONE}.
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @stagemodelonly
* @atomicservice
- * @since 12
+ * @since arkts {'1.1':'12', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
- getCurrentAppCloneIndex(): number;
+ getCurrentAppCloneIndex(): int;
/**
- * Sets the scale ratio for the font size of this application.
- *
- * **NOTE**:
- *
It can be called only by the main thread.
- *
- *
- * @param {number} fontSizeScale - Font scale ratio. The value is a non-negative number. When the application's
- * {@link fontSizeScale} is set to followSystem
and the value set here exceeds the value of
- * fontSizeMaxScale, the value of fontSizeMaxScale takes effect.
+ * Set font size scale.
+ * @param {double} fontSizeScale - Font size scale.
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified.
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @stagemodelonly
@@ -772,7 +771,7 @@ declare class ApplicationContext extends Context {
* @since arkts {'1.1':'13', '1.2':'20'}
* @arkts 1.1&1.2
*/
- setFontSizeScale(fontSizeScale: number): void;
+ setFontSizeScale(fontSizeScale: double): void;
/**
* Obtains the unique instance ID of this application.
@@ -787,7 +786,8 @@ declare class ApplicationContext extends Context {
* @throws { BusinessError } 16000078 - The multi-instance is not supported.
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @stagemodelonly
- * @since 14
+ * @since arkts {'1.1':'14', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
getCurrentInstanceKey(): string;
@@ -807,7 +807,8 @@ declare class ApplicationContext extends Context {
* @throws { BusinessError } 16000078 - The multi-instance is not supported.
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @stagemodelonly
- * @since 14
+ * @since arkts {'1.1':'14', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
getAllRunningInstanceKeys(): Promise>;
}
diff --git a/api/application/AutoFillPopupConfig.d.ts b/api/application/AutoFillPopupConfig.d.ts
index 7c434db2be11b8d4be8fe0f0ecb5973ce5ca31cf..d892e129e748a97882e99ae882b033bdb8611261 100644
--- a/api/application/AutoFillPopupConfig.d.ts
+++ b/api/application/AutoFillPopupConfig.d.ts
@@ -64,24 +64,24 @@
/**
* The width of the popup.
*
- * @type { number }
+ * @type { double }
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @systemapi
* @stagemodelonly
* @since 12
*/
- width: number;
+ width: double;
/**
* The height of the popup.
*
- * @type { number }
+ * @type { double }
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @systemapi
* @stagemodelonly
* @since 12
*/
- height: number;
+ height: double;
}
/**
diff --git a/api/application/AutoFillRect.d.ts b/api/application/AutoFillRect.d.ts
index 9918835ac0bcf1113ea23fae90ecb851a668120a..7a5283bb09be7af358a382eeb82d30467370701b 100644
--- a/api/application/AutoFillRect.d.ts
+++ b/api/application/AutoFillRect.d.ts
@@ -31,44 +31,44 @@ export default interface AutoFillRect {
/**
* The left of the rect.
*
- * @type { number }
+ * @type { double }
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @systemapi
* @stagemodelonly
* @since 12
*/
- left: number;
+ left: double;
/**
* The top of the rect.
*
- * @type { number }
+ * @type { double }
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @systemapi
* @stagemodelonly
* @since 12
*/
- top: number;
+ top: double;
/**
* The width of the rect.
*
- * @type { number }
+ * @type { double }
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @systemapi
* @stagemodelonly
* @since 12
*/
- width: number;
+ width: double;
/**
* The height of the rect.
*
- * @type { number }
+ * @type { double }
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @systemapi
* @stagemodelonly
* @since 12
*/
- height: number;
+ height: double;
}
\ No newline at end of file
diff --git a/api/application/AutoFillType.d.ts b/api/application/AutoFillType.d.ts
index 8a5d9eb3bae344446be63fc02f82272e66da4549..751781f1aafdc11adf287f211621816e654e675d 100644
--- a/api/application/AutoFillType.d.ts
+++ b/api/application/AutoFillType.d.ts
@@ -25,7 +25,8 @@
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @systemapi
* @StageModelOnly
- * @since 11
+ * @since arkts {'1.1':'11', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
export enum AutoFillType {
/**
@@ -34,7 +35,8 @@ export enum AutoFillType {
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @systemapi
* @StageModelOnly
- * @since 11
+ * @since arkts {'1.1':'11', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
UNSPECIFIED = 0,
@@ -44,7 +46,8 @@ export enum AutoFillType {
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @systemapi
* @StageModelOnly
- * @since 11
+ * @since arkts {'1.1':'11', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
PASSWORD = 1,
@@ -54,7 +57,8 @@ export enum AutoFillType {
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @systemapi
* @StageModelOnly
- * @since 11
+ * @since arkts {'1.1':'11', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
USER_NAME = 2,
@@ -64,7 +68,8 @@ export enum AutoFillType {
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @systemapi
* @StageModelOnly
- * @since 11
+ * @since arkts {'1.1':'11', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
NEW_PASSWORD = 3,
@@ -74,7 +79,8 @@ export enum AutoFillType {
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @systemapi
* @StageModelOnly
- * @since 12
+ * @since arkts {'1.1':'12', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
FULL_STREET_ADDRESS = 4,
@@ -84,7 +90,8 @@ export enum AutoFillType {
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @systemapi
* @StageModelOnly
- * @since 12
+ * @since arkts {'1.1':'12', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
HOUSE_NUMBER = 5,
@@ -94,7 +101,8 @@ export enum AutoFillType {
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @systemapi
* @StageModelOnly
- * @since 12
+ * @since arkts {'1.1':'12', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
DISTRICT_ADDRESS = 6,
@@ -104,7 +112,8 @@ export enum AutoFillType {
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @systemapi
* @StageModelOnly
- * @since 12
+ * @since arkts {'1.1':'12', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
CITY_ADDRESS = 7,
@@ -114,7 +123,8 @@ export enum AutoFillType {
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @systemapi
* @StageModelOnly
- * @since 12
+ * @since arkts {'1.1':'12', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
PROVINCE_ADDRESS = 8,
@@ -124,7 +134,8 @@ export enum AutoFillType {
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @systemapi
* @StageModelOnly
- * @since 12
+ * @since arkts {'1.1':'12', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
COUNTRY_ADDRESS = 9,
@@ -134,7 +145,8 @@ export enum AutoFillType {
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @systemapi
* @StageModelOnly
- * @since 12
+ * @since arkts {'1.1':'12', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
PERSON_FULL_NAME = 10,
@@ -144,7 +156,8 @@ export enum AutoFillType {
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @systemapi
* @StageModelOnly
- * @since 12
+ * @since arkts {'1.1':'12', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
PERSON_LAST_NAME = 11,
@@ -154,7 +167,8 @@ export enum AutoFillType {
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @systemapi
* @StageModelOnly
- * @since 12
+ * @since arkts {'1.1':'12', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
PERSON_FIRST_NAME = 12,
@@ -164,7 +178,8 @@ export enum AutoFillType {
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @systemapi
* @StageModelOnly
- * @since 12
+ * @since arkts {'1.1':'12', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
PHONE_NUMBER = 13,
@@ -174,7 +189,8 @@ export enum AutoFillType {
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @systemapi
* @StageModelOnly
- * @since 12
+ * @since arkts {'1.1':'12', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
PHONE_COUNTRY_CODE = 14,
@@ -184,7 +200,8 @@ export enum AutoFillType {
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @systemapi
* @StageModelOnly
- * @since 12
+ * @since arkts {'1.1':'12', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
FULL_PHONE_NUMBER = 15,
@@ -194,7 +211,8 @@ export enum AutoFillType {
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @systemapi
* @StageModelOnly
- * @since 12
+ * @since arkts {'1.1':'12', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
EMAIL_ADDRESS = 16,
@@ -204,7 +222,8 @@ export enum AutoFillType {
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @systemapi
* @StageModelOnly
- * @since 12
+ * @since arkts {'1.1':'12', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
BANK_CARD_NUMBER = 17,
@@ -214,7 +233,8 @@ export enum AutoFillType {
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @systemapi
* @StageModelOnly
- * @since 12
+ * @since arkts {'1.1':'12', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
ID_CARD_NUMBER = 18,
@@ -224,7 +244,8 @@ export enum AutoFillType {
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @systemapi
* @StageModelOnly
- * @since 12
+ * @since arkts {'1.1':'12', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
NICKNAME = 24,
@@ -234,7 +255,8 @@ export enum AutoFillType {
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @systemapi
* @StageModelOnly
- * @since 12
+ * @since arkts {'1.1':'12', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
DETAIL_INFO_WITHOUT_STREET = 25,
@@ -244,7 +266,8 @@ export enum AutoFillType {
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @systemapi
* @StageModelOnly
- * @since 12
+ * @since arkts {'1.1':'12', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
FORMAT_ADDRESS = 26,
@@ -254,7 +277,8 @@ export enum AutoFillType {
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @systemapi
* @stagemodelonly
- * @since 18
+ * @since arkts {'1.1':'18', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
PASSPORT_NUMBER = 27,
@@ -264,7 +288,8 @@ export enum AutoFillType {
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @systemapi
* @stagemodelonly
- * @since 18
+ * @since arkts {'1.1':'18', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
VALIDITY = 28,
@@ -274,7 +299,8 @@ export enum AutoFillType {
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @systemapi
* @stagemodelonly
- * @since 18
+ * @since arkts {'1.1':'18', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
ISSUE_AT = 29,
@@ -284,7 +310,8 @@ export enum AutoFillType {
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @systemapi
* @stagemodelonly
- * @since 18
+ * @since arkts {'1.1':'18', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
ORGANIZATION = 30,
@@ -294,7 +321,8 @@ export enum AutoFillType {
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @systemapi
* @stagemodelonly
- * @since 18
+ * @since arkts {'1.1':'18', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
TAX_ID = 31,
@@ -304,7 +332,8 @@ export enum AutoFillType {
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @systemapi
* @stagemodelonly
- * @since 18
+ * @since arkts {'1.1':'18', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
ADDRESS_CITY_AND_STATE = 32,
@@ -314,7 +343,8 @@ export enum AutoFillType {
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @systemapi
* @stagemodelonly
- * @since 18
+ * @since arkts {'1.1':'18', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
FLIGHT_NUMBER = 33,
@@ -324,7 +354,8 @@ export enum AutoFillType {
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @systemapi
* @stagemodelonly
- * @since 18
+ * @since arkts {'1.1':'18', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
LICENSE_NUMBER = 34,
@@ -334,7 +365,8 @@ export enum AutoFillType {
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @systemapi
* @stagemodelonly
- * @since 18
+ * @since arkts {'1.1':'18', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
LICENSE_FILE_NUMBER = 35,
@@ -344,7 +376,8 @@ export enum AutoFillType {
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @systemapi
* @stagemodelonly
- * @since 18
+ * @since arkts {'1.1':'18', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
LICENSE_PLATE = 36,
@@ -354,7 +387,8 @@ export enum AutoFillType {
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @systemapi
* @stagemodelonly
- * @since 18
+ * @since arkts {'1.1':'18', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
ENGINE_NUMBER = 37,
@@ -364,7 +398,8 @@ export enum AutoFillType {
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @systemapi
* @stagemodelonly
- * @since 18
+ * @since arkts {'1.1':'18', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
LICENSE_CHASSIS_NUMBER = 38
}
\ No newline at end of file
diff --git a/api/application/AutoStartupInfo.d.ts b/api/application/AutoStartupInfo.d.ts
index 78da28241604e034268bd6d06f984d5980fcc818..e6d248c3952b0969b063c15c1b9f833d3749cf87 100644
--- a/api/application/AutoStartupInfo.d.ts
+++ b/api/application/AutoStartupInfo.d.ts
@@ -25,7 +25,8 @@
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @systemapi
* @stagemodelonly
- * @since 11
+ * @since arkts {'1.1':'11', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
export interface AutoStartupInfo {
/**
@@ -74,18 +75,18 @@ export interface AutoStartupInfo {
/**
* The app clone index of ability instance.
- * @type { ?number }
+ * @type { ?int }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @systemapi
* @stagemodelonly
* @since 12
*/
- appCloneIndex?: number;
+ appCloneIndex?: int;
/**
* The user id of application.
*
- * @type { ?number }
+ * @type { ?int }
* @readonly
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @systemapi
@@ -93,12 +94,12 @@ export interface AutoStartupInfo {
* @since 20
* @arkts 1.1&1.2
*/
- readonly userId?: number;
+ readonly userId?: int;
/**
* The user id of setter.
*
- * @type { ?number }
+ * @type { ?int }
* @readonly
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @systemapi
@@ -106,7 +107,7 @@ export interface AutoStartupInfo {
* @since 20
* @arkts 1.1&1.2
*/
- readonly setterUserId?: number;
+ readonly setterUserId?: int;
/**
* Whether to allow user to modify autostartup status.
diff --git a/api/application/BusinessAbilityInfo.d.ts b/api/application/BusinessAbilityInfo.d.ts
index ac287a950d46e2eb675ac3e4c56beaf88009c0b5..0c0f1e4cab611b775881a43133ca09bdc8d62756 100755
--- a/api/application/BusinessAbilityInfo.d.ts
+++ b/api/application/BusinessAbilityInfo.d.ts
@@ -66,35 +66,35 @@ export interface BusinessAbilityInfo {
/**
* Indicates the label id of the business ability info
*
- * @type { number }
+ * @type { int }
* @readonly
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @systemapi
* @since 10
*/
- readonly labelId: number;
+ readonly labelId: int;
/**
* Indicates the description id of the business ability info
*
- * @type { number }
+ * @type { int }
* @readonly
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @systemapi
* @since 10
*/
- readonly descriptionId: number;
+ readonly descriptionId: int;
/**
* Indicates the icon id of the business ability info
*
- * @type { number }
+ * @type { int }
* @readonly
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @systemapi
* @since 10
*/
- readonly iconId: number;
+ readonly iconId: int;
/**
* Enumerates types of the business ability info
diff --git a/api/application/Context.d.ts b/api/application/Context.d.ts
index b226b367193ebfd2d3c959463781b09b532b97b3..39034010ce4192bfe2de9a7072bf6babf2ee8176 100644
--- a/api/application/Context.d.ts
+++ b/api/application/Context.d.ts
@@ -19,11 +19,11 @@
*/
/*** if arkts 1.1 */
-import type { AsyncCallback } from '../@ohos.base';
import EventHub from './EventHub';
/*** endif */
import { ApplicationInfo } from '../bundleManager/ApplicationInfo';
import ApplicationContext from './ApplicationContext';
+import type { AsyncCallback } from '../@ohos.base';
import BaseContext from './BaseContext';
import resmgr from '../@ohos.resourceManager';
import contextConstant from '../@ohos.app.ability.contextConstant';
@@ -299,7 +299,8 @@ declare class Context extends BaseContext {
* @stagemodelonly
* @crossplatform
* @atomicservice
- * @since 11
+ * @since arkts {'1.1':'11', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
bundleCodeDir: string;
@@ -318,7 +319,8 @@ declare class Context extends BaseContext {
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @stagemodelonly
* @atomicservice
- * @since 11
+ * @since arkts {'1.1':'11', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
distributedFilesDir: string;
@@ -335,7 +337,8 @@ declare class Context extends BaseContext {
* @stagemodelonly
* @crossplatform
* @atomicservice
- * @since 11
+ * @since arkts {'1.1':'11', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
resourceDir: string;
@@ -346,7 +349,8 @@ declare class Context extends BaseContext {
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @stagemodelonly
* @atomicservice
- * @since 12
+ * @since arkts {'1.1':'12', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
cloudFileDir: string;
@@ -430,7 +434,8 @@ declare class Context extends BaseContext {
* @stagemodelonly
* @crossplatform
* @atomicservice
- * @since 18
+ * @since arkts {'1.1':'18', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
processName: string;
@@ -595,7 +600,8 @@ declare class Context extends BaseContext {
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @stagemodelonly
* @atomicservice
- * @since 11
+ * @since arkts {'1.1':'11', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
getGroupDir(dataGroupID: string, callback: AsyncCallback): void;
@@ -623,7 +629,8 @@ declare class Context extends BaseContext {
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @stagemodelonly
* @atomicservice
- * @since 11
+ * @since arkts {'1.1':'11', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
getGroupDir(dataGroupID: string): Promise;
@@ -656,7 +663,8 @@ declare class Context extends BaseContext {
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @stagemodelonly
* @atomicservice
- * @since 18
+ * @since arkts {'1.1':'18', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
createAreaModeContext(areaMode: contextConstant.AreaMode): Context;
@@ -664,16 +672,17 @@ declare class Context extends BaseContext {
* Creates the context based on the specified display ID, so as to obtain and use other application contexts with
* screen information (including ScreenDensity and Direction).
*
- * @param { number } displayId - Display ID.
+ * @param { long } displayId - Display ID.
* @returns { Context } Context with the specified screen information.
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified.
* 2.Incorrect parameter types.
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @stagemodelonly
* @atomicservice
- * @since 15
+ * @since arkts {'1.1':'15', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
- createDisplayContext(displayId: number): Context;
+ createDisplayContext(displayId: long): Context;
}
export default Context;
\ No newline at end of file
diff --git a/api/application/EventHub.d.ts b/api/application/EventHub.d.ts
index 8b1a3fb6c114b4c5e553a988db3165661201b1a4..921b346a518e7d26052aa683a3fe0c2ba7711967 100644
--- a/api/application/EventHub.d.ts
+++ b/api/application/EventHub.d.ts
@@ -42,7 +42,8 @@ import { BusinessError } from '../@ohos.base';
* @stagemodelonly
* @crossplatform
* @atomicservice
- * @since 12
+ * @since arkts {'1.1':'12', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
export default class EventHub {
/**
diff --git a/api/application/ExtensionRunningInfo.d.ts b/api/application/ExtensionRunningInfo.d.ts
index 6c23c5536b7375a6a17ecac825f7260e7d2d83a7..f0176db81e9e914d8bc5751c8bad498d9aa66802 100644
--- a/api/application/ExtensionRunningInfo.d.ts
+++ b/api/application/ExtensionRunningInfo.d.ts
@@ -27,7 +27,8 @@ import bundle from '../@ohos.bundle.bundleManager';
* @typedef ExtensionRunningInfo
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @systemapi
- * @since 9
+ * @since arkts {'1.1':'9', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
export interface ExtensionRunningInfo {
/**
@@ -35,52 +36,58 @@ export interface ExtensionRunningInfo {
* @default Indicates the extension of the extension info
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @systemapi
- * @since 9
+ * @since arkts {'1.1':'9', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
extension: ElementName;
/**
- * @type { number }
+ * @type { int }
* @default process id
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @systemapi
- * @since 9
+ * @since arkts {'1.1':'9', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
- pid: number;
+ pid: int;
/**
- * @type { number }
+ * @type { int }
* @default user id
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @systemapi
- * @since 9
+ * @since arkts {'1.1':'9', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
- uid: number;
+ uid: int;
/**
* @type { string }
* @default the name of the process
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @systemapi
- * @since 9
+ * @since arkts {'1.1':'9', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
processName: string;
/**
- * @type { number }
+ * @type { long }
* @default ability start time
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @systemapi
- * @since 9
+ * @since arkts {'1.1':'9', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
- startTime: number;
+ startTime: long;
/**
* @type { Array }
* @default All package names under the current process
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @systemapi
- * @since 9
+ * @since arkts {'1.1':'9', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
clientPackage: Array;
@@ -89,7 +96,8 @@ export interface ExtensionRunningInfo {
* @default Enumerates types of the extension info
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @systemapi
- * @since 9
+ * @since arkts {'1.1':'9', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
type: bundle.ExtensionAbilityType;
}
diff --git a/api/application/KioskStatus.d.ts b/api/application/KioskStatus.d.ts
index 6d223313e1b797b04cc757bf8cfd87ccf6b96725..e3fd3e47708ad558f9a1116e318ee4f6159c2c0c 100644
--- a/api/application/KioskStatus.d.ts
+++ b/api/application/KioskStatus.d.ts
@@ -53,11 +53,11 @@ export interface KioskStatus {
/**
* The budle uid of kiosk app.
*
- * @type { number }
+ * @type { int }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @stagemodelonly
* @since 20
* @arkts 1.1&1.2
*/
- kioskBundleUid: number;
+ kioskBundleUid: int;
}
diff --git a/api/application/MissionInfo.d.ts b/api/application/MissionInfo.d.ts
index 7f7681f119eb5b08dc6ea4a8119a727f70a1341c..2bec109dbb32e37a62d5abfb8f5499bb2e52c20b 100644
--- a/api/application/MissionInfo.d.ts
+++ b/api/application/MissionInfo.d.ts
@@ -32,22 +32,22 @@ export interface MissionInfo {
/**
* Indicates mission id.
*
- * @type { number }
+ * @type { int }
* @syscap SystemCapability.Ability.AbilityRuntime.Mission
* @systemapi
* @since 8
*/
- missionId: number;
+ missionId: int;
/**
* Indicates running state.
*
- * @type { number }
+ * @type { int }
* @syscap SystemCapability.Ability.AbilityRuntime.Mission
* @systemapi
* @since 8
*/
- runningState: number;
+ runningState: int;
/**
* Indicates locked state.
@@ -112,12 +112,12 @@ export interface MissionInfo {
/**
* Indicates the ability state of this mission.
*
- * @type { number }
+ * @type { int }
* @syscap SystemCapability.Ability.AbilityRuntime.Mission
* @systemapi
* @since 10
*/
- abilityState: number;
+ abilityState: int;
/**
* Indicates whether the mission is unclearable.
diff --git a/api/application/MissionListener.d.ts b/api/application/MissionListener.d.ts
index bfa9de00d6a433badbb9fe31712db507e45b2d61..b141fbaa10e8736757734b2dd5c9473e50112e22 100644
--- a/api/application/MissionListener.d.ts
+++ b/api/application/MissionListener.d.ts
@@ -32,71 +32,71 @@ export interface MissionListener {
/**
* Called by system when mission created.
*
- * @param { number } mission - Indicates the id of created mission.
+ * @param { int } mission - Indicates the id of created mission.
* @syscap SystemCapability.Ability.AbilityRuntime.Mission
* @systemapi
* @since 8
*/
- onMissionCreated(mission: number): void;
+ onMissionCreated(mission: int): void;
/**
* Called by system when mission destroyed.
*
- * @param { number } mission - Indicates the id of destroyed mission.
+ * @param { int } mission - Indicates the id of destroyed mission.
* @syscap SystemCapability.Ability.AbilityRuntime.Mission
* @systemapi
* @since 8
*/
- onMissionDestroyed(mission: number): void;
+ onMissionDestroyed(mission: int): void;
/**
* Called by system when mission snapshot changed.
*
- * @param { number } mission - Indicates the id of the mission which the snapshot changes
+ * @param { int } mission - Indicates the id of the mission which the snapshot changes
* @syscap SystemCapability.Ability.AbilityRuntime.Mission
* @systemapi
* @since 8
*/
- onMissionSnapshotChanged(mission: number): void;
+ onMissionSnapshotChanged(mission: int): void;
/**
* Called by system when mission moved to front.
*
- * @param { number } mission - Indicates the id of the mission being moved to the foreground.
+ * @param { int } mission - Indicates the id of the mission being moved to the foreground.
* @syscap SystemCapability.Ability.AbilityRuntime.Mission
* @systemapi
* @since 8
*/
- onMissionMovedToFront(mission: number): void;
+ onMissionMovedToFront(mission: int): void;
/**
* Called by system when mission label has changed.
*
- * @param { number } mission - Indicates the id of the mission whose label has changed.
+ * @param { int } mission - Indicates the id of the mission whose label has changed.
* @syscap SystemCapability.Ability.AbilityRuntime.Mission
* @systemapi
* @since 9
*/
- onMissionLabelUpdated(mission: number): void;
+ onMissionLabelUpdated(mission: int): void;
/**
* Called by system when mission icon has changed.
*
- * @param { number } mission - Indicates the id of the mission whose icon has changed.
+ * @param { int } mission - Indicates the id of the mission whose icon has changed.
* @param { image.PixelMap } icon - Indicates the icon of the mission whose icon has changed.
* @syscap SystemCapability.Ability.AbilityRuntime.Mission
* @systemapi
* @since 9
*/
- onMissionIconUpdated(mission: number, icon: image.PixelMap): void;
+ onMissionIconUpdated(mission: int, icon: image.PixelMap): void;
/**
* Called by system when target mission is closed.
*
- * @param { number } mission - Indicates the id of the mission whose ability instance is destroyed.
+ * @param { int } mission - Indicates the id of the mission whose ability instance is destroyed.
* @syscap SystemCapability.Ability.AbilityRuntime.Mission
* @systemapi
* @since 9
*/
- onMissionClosed(mission: number): void;
+ onMissionClosed(mission: int): void;
}
diff --git a/api/application/PageNodeInfo.d.ts b/api/application/PageNodeInfo.d.ts
index 5e9749e918f185c42469d4090240cfb56f55be2d..78a75b0671852ff49a42f1ff18b765f213c381f5 100644
--- a/api/application/PageNodeInfo.d.ts
+++ b/api/application/PageNodeInfo.d.ts
@@ -34,24 +34,24 @@ export default interface PageNodeInfo {
/**
* The id of page node.
*
- * @type { number }
+ * @type { int }
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @systemapi
* @stagemodelonly
* @since 11
*/
- id: number;
+ id: int;
/**
* The depth of page node.
*
- * @type { number }
+ * @type { int }
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
* @systemapi
* @stagemodelonly
* @since 11
*/
- depth: number;
+ depth: int;
/**
* The auto fill type of page node.
diff --git a/api/application/ProcessData.d.ts b/api/application/ProcessData.d.ts
index 7d6df91bbfa342da09cd02e440e31c974c2c7118..11f6e18b0350736c8c37c83f014b1c13c2831fc5 100644
--- a/api/application/ProcessData.d.ts
+++ b/api/application/ProcessData.d.ts
@@ -22,51 +22,57 @@
* The process data.
*
* @syscap SystemCapability.Ability.AbilityRuntime.Core
- * @since 14
+ * @since arkts {'1.1':'14', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
-export default class ProcessData {
+declare class ProcessData {
/**
* 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;
/**
* The pid.
*
- * @type { number }
+ * @type { int }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
- * @since 14
+ * @since arkts {'1.1':'14', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
- pid: number;
+ pid: int;
/**
* The uid.
*
- * @type { number }
+ * @type { int }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
- * @since 14
+ * @since arkts {'1.1':'14', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
- uid: number;
+ uid: int;
/**
* The process state.
*
- * @type { number }
+ * @type { int }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
- * @since 14
+ * @since arkts {'1.1':'14', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
- state: number;
+ state: int;
/**
* Whether the process is continuous task.
*
* @type { boolean }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
- * @since 14
+ * @since arkts {'1.1':'14', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
isContinuousTask: boolean;
@@ -75,7 +81,10 @@ export default class ProcessData {
*
* @type { boolean }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
- * @since 14
+ * @since arkts {'1.1':'14', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
isKeepAlive: boolean;
}
+
+export default ProcessData;
\ No newline at end of file
diff --git a/api/application/ProcessInformation.d.ts b/api/application/ProcessInformation.d.ts
index 8f64c790d66fd7e83a38a4b3841040b06904c5b3..77d2f9b1cfa71b88d3fed513678e76d7f7b39083 100644
--- a/api/application/ProcessInformation.d.ts
+++ b/api/application/ProcessInformation.d.ts
@@ -67,7 +67,7 @@ export interface ProcessInformation {
* @since 10
*/
/**
- * @type { number }
+ * @type { int }
* @default process id
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @crossplatform
@@ -75,7 +75,7 @@ export interface ProcessInformation {
* @since arkts {'1.1':'11', '1.2':'20'}
* @arkts 1.1&1.2
*/
- pid: number;
+ pid: int;
/**
* @type { number }
@@ -84,14 +84,14 @@ export interface ProcessInformation {
* @since 9
*/
/**
- * @type { number }
+ * @type { int }
* @default user id
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @atomicservice
* @since arkts {'1.1':'11', '1.2':'20'}
* @arkts 1.1&1.2
*/
- uid: number;
+ uid: int;
/**
* @type { string }
@@ -174,11 +174,11 @@ export interface ProcessInformation {
/**
* The app clone index of current process if app is multi app mode.
- * @type { ?number }
+ * @type { ?int }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @atomicservice
* @since arkts {'1.1':'12', '1.2':'20'}
* @arkts 1.1&1.2
*/
- appCloneIndex?: number;
+ appCloneIndex?: int;
}
diff --git a/api/application/RunningAppClone.d.ts b/api/application/RunningAppClone.d.ts
index 261cb1d15ab7804913898229678934892a6b2597..02f2c8dc4e975bd75c4ba60699ae434e87cc299e 100644
--- a/api/application/RunningAppClone.d.ts
+++ b/api/application/RunningAppClone.d.ts
@@ -31,33 +31,33 @@ export interface RunningAppClone {
/**
* The app clone index of current single app.
*
- * @type { number }
+ * @type { int }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @systemapi
* @since arkts {'1.1':'12', '1.2':'20'}
* @arkts 1.1&1.2
*/
- appCloneIndex: number;
+ appCloneIndex: int;
/**
* The uid of current single app.
*
- * @type { number }
+ * @type { int }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @systemapi
* @since arkts {'1.1':'12', '1.2':'20'}
* @arkts 1.1&1.2
*/
- uid: number;
+ uid: int;
/**
* All pids of current single app.
*
- * @type { Array }
+ * @type { Array }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @systemapi
* @since arkts {'1.1':'12', '1.2':'20'}
* @arkts 1.1&1.2
*/
- pids: Array;
+ pids: Array;
}
\ No newline at end of file
diff --git a/api/application/RunningMultiAppInfo.d.ts b/api/application/RunningMultiAppInfo.d.ts
index cb77e92feb76f6e4a8633f3d389d72b3e6cfa0a8..f5732fa40b82cdc56b3f2b6a6dbe7aa1c62ad06e 100644
--- a/api/application/RunningMultiAppInfo.d.ts
+++ b/api/application/RunningMultiAppInfo.d.ts
@@ -51,7 +51,8 @@ export interface RunningMultiAppInfo {
* @type { MultiAppMode }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @systemapi
- * @since 12
+ * @since arkts {'1.1':'12', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
mode: MultiAppMode;
@@ -72,7 +73,8 @@ export interface RunningMultiAppInfo {
* @type { ?Array }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @systemapi
- * @since 12
+ * @since arkts {'1.1':'12', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
runningAppClones?: Array;
}
\ No newline at end of file
diff --git a/api/application/RunningMultiInstanceInfo.d.ts b/api/application/RunningMultiInstanceInfo.d.ts
index 1645db4051150699348f31ddabb10c8ac71a571a..24b0df4c53f4b242c23116b1f3b89902632d9ece 100644
--- a/api/application/RunningMultiInstanceInfo.d.ts
+++ b/api/application/RunningMultiInstanceInfo.d.ts
@@ -42,20 +42,22 @@ export interface RunningMultiInstanceInfo {
/**
* The uid of current app instance.
*
- * @type { number }
+ * @type { int }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @systemapi
- * @since 14
+ * @since arkts {'1.1':'14', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
- uid: number;
+ uid: int;
/**
* All pids of current app instance.
*
- * @type { Array }
+ * @type { Array }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @systemapi
- * @since 14
+ * @since arkts {'1.1':'14', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
- pids: Array;
+ pids: Array;
}
\ No newline at end of file
diff --git a/api/application/ServiceExtensionContext.d.ts b/api/application/ServiceExtensionContext.d.ts
index e6bbf4ca594de29b100a186f2642dfb4744374d1..084bc4cad3f329d7ba66feda95c573538c83697f 100644
--- a/api/application/ServiceExtensionContext.d.ts
+++ b/api/application/ServiceExtensionContext.d.ts
@@ -915,7 +915,7 @@ declare class ServiceExtensionContext extends ExtensionContext {
*
* @permission ohos.permission.INTERACT_ACROSS_LOCAL_ACCOUNTS
* @param { Want } want - Indicates the ability to start.
- * @param { number } accountId - Indicates the accountId to start.
+ * @param { int } accountId - Indicates the accountId to start.
* @param { AsyncCallback } callback - The callback of startAbilityWithAccount.
* @throws { BusinessError } 201 - The application does not have permission to call the interface.
* @throws { BusinessError } 202 - The application is not system-app, can not use system-api.
@@ -950,7 +950,7 @@ declare class ServiceExtensionContext extends ExtensionContext {
* @stagemodelonly
* @since 14
*/
- startAbilityWithAccount(want: Want, accountId: number, callback: AsyncCallback): void;
+ startAbilityWithAccount(want: Want, accountId: int, callback: AsyncCallback): void;
/**
* Service extension uses this method to start a specific ability with account.
@@ -1064,7 +1064,7 @@ declare class ServiceExtensionContext extends ExtensionContext {
*
* @permission ohos.permission.INTERACT_ACROSS_LOCAL_ACCOUNTS
* @param { Want } want - Indicates the ability to start.
- * @param { number } accountId - Indicates the accountId to start.
+ * @param { int } accountId - Indicates the accountId to start.
* @param { StartOptions } options - Indicates the start options.
* @param { AsyncCallback } callback - The callback of startAbilityWithAccount.
* @throws { BusinessError } 201 - The application does not have permission to call the interface.
@@ -1098,7 +1098,7 @@ declare class ServiceExtensionContext extends ExtensionContext {
* @stagemodelonly
* @since 14
*/
- startAbilityWithAccount(want: Want, accountId: number, options: StartOptions, callback: AsyncCallback): void;
+ startAbilityWithAccount(want: Want, accountId: int, options: StartOptions, callback: AsyncCallback): void;
/**
* Service extension uses this method to start a specific ability with account. If the caller application is in foreground,
@@ -1186,7 +1186,7 @@ declare class ServiceExtensionContext extends ExtensionContext {
*
* @permission ohos.permission.INTERACT_ACROSS_LOCAL_ACCOUNTS
* @param { Want } want - Indicates the ability to start.
- * @param { number } accountId - Indicates the accountId to start.
+ * @param { int } accountId - Indicates the accountId to start.
* @param { StartOptions } [options] - Indicates the start options.
* @returns { Promise } The promise returned by the function.
* @throws { BusinessError } 201 - The application does not have permission to call the interface.
@@ -1222,7 +1222,7 @@ declare class ServiceExtensionContext extends ExtensionContext {
* @stagemodelonly
* @since 14
*/
- startAbilityWithAccount(want: Want, accountId: number, options?: StartOptions): Promise;
+ startAbilityWithAccount(want: Want, accountId: int, options?: StartOptions): Promise;
/**
* Starts a new service extension ability.
@@ -1456,7 +1456,7 @@ declare class ServiceExtensionContext extends ExtensionContext {
*
* @permission ohos.permission.INTERACT_ACROSS_LOCAL_ACCOUNTS
* @param { Want } want - Indicates the want info to start.
- * @param { number } accountId - Indicates the account to start.
+ * @param { int } accountId - Indicates the account to start.
* @param { AsyncCallback } callback - The callback of startServiceExtensionAbilityWithAccount.
* @throws { BusinessError } 201 - The application does not have permission to call the interface.
* @throws { BusinessError } 202 - The application is not system-app, can not use system-api.
@@ -1479,7 +1479,7 @@ declare class ServiceExtensionContext extends ExtensionContext {
* @stagemodelonly
* @since 12
*/
- startServiceExtensionAbilityWithAccount(want: Want, accountId: number, callback: AsyncCallback): void;
+ startServiceExtensionAbilityWithAccount(want: Want, accountId: int, callback: AsyncCallback): void;
/**
* Starts a new service extension ability with account.
@@ -1545,7 +1545,7 @@ declare class ServiceExtensionContext extends ExtensionContext {
*
* @permission ohos.permission.INTERACT_ACROSS_LOCAL_ACCOUNTS
* @param { Want } want - Indicates the want info to start.
- * @param { number } accountId - Indicates the account to start.
+ * @param { int } accountId - Indicates the account to start.
* @returns { Promise } The promise returned by the function.
* @throws { BusinessError } 201 - The application does not have permission to call the interface.
* @throws { BusinessError } 202 - The application is not system-app, can not use system-api.
@@ -1568,7 +1568,7 @@ declare class ServiceExtensionContext extends ExtensionContext {
* @stagemodelonly
* @since 12
*/
- startServiceExtensionAbilityWithAccount(want: Want, accountId: number): Promise;
+ startServiceExtensionAbilityWithAccount(want: Want, accountId: int): Promise;
/**
* Stops a service within the same application.
@@ -1614,7 +1614,8 @@ declare 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
*/
stopServiceExtensionAbility(want: Want, callback: AsyncCallback): void;
@@ -1662,7 +1663,8 @@ declare 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
*/
stopServiceExtensionAbility(want: Want): Promise;
@@ -1698,7 +1700,7 @@ declare class ServiceExtensionContext extends ExtensionContext {
*
* @permission ohos.permission.INTERACT_ACROSS_LOCAL_ACCOUNTS
* @param { Want } want - Indicates the want info to start.
- * @param { number } accountId - Indicates the accountId to start.
+ * @param { int } accountId - Indicates the accountId to start.
* @param { AsyncCallback } callback - The callback of stopServiceExtensionAbilityWithAccount.
* @throws { BusinessError } 201 - The application does not have permission to call the interface.
* @throws { BusinessError } 202 - The application is not system-app, can not use system-api.
@@ -1717,7 +1719,7 @@ declare class ServiceExtensionContext extends ExtensionContext {
* @stagemodelonly
* @since 10
*/
- stopServiceExtensionAbilityWithAccount(want: Want, accountId: number, callback: AsyncCallback): void;
+ stopServiceExtensionAbilityWithAccount(want: Want, accountId: int, callback: AsyncCallback): void;
/**
* Stops a service within the same application with account.
@@ -1751,7 +1753,7 @@ declare class ServiceExtensionContext extends ExtensionContext {
*
* @permission ohos.permission.INTERACT_ACROSS_LOCAL_ACCOUNTS
* @param { Want } want - Indicates the want info to start.
- * @param { number } accountId - Indicates the accountId to start.
+ * @param { int } accountId - Indicates the accountId to start.
* @returns { Promise } The promise returned by the function.
* @throws { BusinessError } 201 - The application does not have permission to call the interface.
* @throws { BusinessError } 202 - The application is not system-app, can not use system-api.
@@ -1770,7 +1772,7 @@ declare class ServiceExtensionContext extends ExtensionContext {
* @stagemodelonly
* @since 10
*/
- stopServiceExtensionAbilityWithAccount(want: Want, accountId: number): Promise;
+ stopServiceExtensionAbilityWithAccount(want: Want, accountId: int): Promise;
/**
* Destroys this service extension.
@@ -1869,7 +1871,7 @@ declare class ServiceExtensionContext extends ExtensionContext {
*
* @param { Want } want - Indicates the service extension to connect.
* @param { ConnectOptions } options - Indicates the callback of connection.
- * @returns { number } Returns the connection id.
+ * @returns { long } Returns the connection id.
* @throws { BusinessError } 201 - The application does not have permission to call the interface.
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
* 2. Incorrect parameter types; 3. Parameter verification failed.
@@ -1888,7 +1890,7 @@ declare class ServiceExtensionContext extends ExtensionContext {
* @stagemodelonly
* @since 10
*/
- connectServiceExtensionAbility(want: Want, options: ConnectOptions): number;
+ connectServiceExtensionAbility(want: Want, options: ConnectOptions): long;
/**
* Connects an ability to a Service extension with account.
@@ -1926,9 +1928,9 @@ declare class ServiceExtensionContext extends ExtensionContext {
*
* @permission ohos.permission.INTERACT_ACROSS_LOCAL_ACCOUNTS
* @param { Want } want - Indicates the service extension to connect.
- * @param { number } accountId - Indicates the account to connect.
+ * @param { int } accountId - Indicates the account to connect.
* @param { ConnectOptions } options - Indicates the callback of connection.
- * @returns { number } Returns the connection id.
+ * @returns { long } Returns the connection id.
* @throws { BusinessError } 201 - The application does not have permission to call the interface.
* @throws { BusinessError } 202 - The application is not system-app, can not use system-api.
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
@@ -1948,12 +1950,12 @@ declare class ServiceExtensionContext extends ExtensionContext {
* @stagemodelonly
* @since 10
*/
- connectServiceExtensionAbilityWithAccount(want: Want, accountId: number, options: ConnectOptions): number;
+ connectServiceExtensionAbilityWithAccount(want: Want, accountId: int, options: ConnectOptions): long;
/**
* Disconnect an ability from a service extension, in contrast to {@link connectAbility}.
*
- * @param { number } connection - the connection id returned from connectAbility api.
+ * @param { long } connection - the connection id returned from connectAbility api.
* @param { AsyncCallback } callback - The callback of disconnectAbility.
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
* 2. Incorrect parameter types; 3. Parameter verification failed.
@@ -1964,12 +1966,12 @@ declare class ServiceExtensionContext extends ExtensionContext {
* @stagemodelonly
* @since 9
*/
- disconnectServiceExtensionAbility(connection: number, callback: AsyncCallback): void;
+ disconnectServiceExtensionAbility(connection: long, callback: AsyncCallback): void;
/**
* Disconnect an ability from a service extension, in contrast to {@link connectAbility}.
*
- * @param { number } connection - the connection id returned from connectAbility api.
+ * @param { long } connection - the connection id returned from connectAbility api.
* @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.
@@ -1980,7 +1982,7 @@ declare class ServiceExtensionContext extends ExtensionContext {
* @stagemodelonly
* @since 9
*/
- disconnectServiceExtensionAbility(connection: number): Promise;
+ disconnectServiceExtensionAbility(connection: long): Promise;
/**
* Get the caller object of the startup capability.
@@ -2045,7 +2047,7 @@ declare class ServiceExtensionContext extends ExtensionContext {
*
* @permission ohos.permission.ABILITY_BACKGROUND_COMMUNICATION and ohos.permission.INTERACT_ACROSS_LOCAL_ACCOUNTS
* @param { Want } want - Indicates the ability to start.
- * @param { number } accountId - Indicates the account to start.
+ * @param { int } accountId - Indicates the account to start.
* @returns { Promise } Returns the Caller interface.
* @throws { BusinessError } 201 - The application does not have permission to call the interface.
* @throws { BusinessError } 202 - The application is not system-app, can not use system-api.
@@ -2067,7 +2069,7 @@ declare class ServiceExtensionContext extends ExtensionContext {
* @stagemodelonly
* @since 10
*/
- startAbilityByCallWithAccount(want: Want, accountId: number): Promise;
+ startAbilityByCallWithAccount(want: Want, accountId: int): Promise;
/**
* Service extension uses this method to start a specific ability,
diff --git a/api/application/UIAbilityContext.d.ts b/api/application/UIAbilityContext.d.ts
index f1ec7e7b6819e03993ca88ecf5f0c8ba34d62fcb..f73753a9526490b88048c1870f793d3bc8773434 100644
--- a/api/application/UIAbilityContext.d.ts
+++ b/api/application/UIAbilityContext.d.ts
@@ -19,17 +19,12 @@
*/
/*** if arkts 1.1 */
-import { ConnectOptions } from '../ability/connectOptions';
-import { Caller } from '../@ohos.app.ability.UIAbility';
import image from '../@ohos.multimedia.image';
import dialogRequest from '../@ohos.app.ability.dialogRequest';
import AbilityConstant from '../@ohos.app.ability.AbilityConstant';
import contextConstant from '../@ohos.app.ability.contextConstant';
-import type AtomicServiceOptions from '../@ohos.app.ability.AtomicServiceOptions';
-import type ConfigurationConstant from '../@ohos.app.ability.ConfigurationConstant';
import type UIServiceProxy from './UIServiceProxy';
import type UIServiceExtensionConnectCallback from './UIServiceExtensionConnectCallback';
-import type AbilityStartCallback from './AbilityStartCallback';
/*** endif */
import { AbilityInfo } from '../bundleManager/AbilityInfo';
import { AbilityResult } from '../ability/abilityResult';
@@ -41,6 +36,11 @@ import Want from '../@ohos.app.ability.Want';
import StartOptions from '../@ohos.app.ability.StartOptions';
import { Configuration } from '../@ohos.app.ability.Configuration';
import window from '../@ohos.window';
+import { ConnectOptions } from '../ability/connectOptions';
+import { Caller } from '../@ohos.app.ability.UIAbility';
+import type AtomicServiceOptions from '../@ohos.app.ability.AtomicServiceOptions';
+import type ConfigurationConstant from '../@ohos.app.ability.ConfigurationConstant';
+import type AbilityStartCallback from './AbilityStartCallback';
/**
* The context of an ability. It allows access to ability-specific resources.
@@ -1287,7 +1287,8 @@ declare class UIAbilityContext extends Context {
* @throws { BusinessError } 16000080 - Creating a new instance is not supported.
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @stagemodelonly
- * @since 14
+ * @since arkts {'1.1':'14', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
startAbilityByCall(want: Want): Promise;
@@ -1367,7 +1368,7 @@ declare class UIAbilityContext extends Context {
*
* @permission ohos.permission.ABILITY_BACKGROUND_COMMUNICATION and ohos.permission.INTERACT_ACROSS_LOCAL_ACCOUNTS
* @param { Want } want - Indicates the ability to start.
- * @param { number } accountId - Indicates the account to start.
+ * @param { int } accountId - Indicates the account to start.
* @returns { Promise } Returns the Caller interface.
* @throws { BusinessError } 201 - The application does not have permission to call the interface.
* @throws { BusinessError } 202 - The application is not system-app, can not use system-api.
@@ -1396,7 +1397,7 @@ declare class UIAbilityContext extends Context {
* @stagemodelonly
* @since 14
*/
- startAbilityByCallWithAccount(want: Want, accountId: number): Promise;
+ startAbilityByCallWithAccount(want: Want, accountId: int): Promise;
/**
* Starts a new ability with account. If the caller application is in foreground,
@@ -1480,7 +1481,7 @@ declare class UIAbilityContext extends Context {
*
* @permission ohos.permission.INTERACT_ACROSS_LOCAL_ACCOUNTS
* @param { Want } want - Indicates the want info to start.
- * @param { number } accountId - Indicates the account to start.
+ * @param { int } accountId - Indicates the account to start.
* @param { AsyncCallback } callback - The callback of startAbilityWithAccount.
* @throws { BusinessError } 201 - The application does not have permission to call the interface.
* @throws { BusinessError } 202 - The application is not system-app, can not use system-api.
@@ -1514,7 +1515,7 @@ declare class UIAbilityContext extends Context {
* @stagemodelonly
* @since 14
*/
- startAbilityWithAccount(want: Want, accountId: number, callback: AsyncCallback): void;
+ startAbilityWithAccount(want: Want, accountId: int, callback: AsyncCallback): void;
/**
* Starts a new ability with account.
@@ -1625,7 +1626,7 @@ declare class UIAbilityContext extends Context {
*
* @permission ohos.permission.INTERACT_ACROSS_LOCAL_ACCOUNTS
* @param { Want } want - Indicates the want info to start.
- * @param { number } accountId - Indicates the account to start.
+ * @param { int } accountId - Indicates the account to start.
* @param { StartOptions } options - Indicates the start options.
* @param { AsyncCallback } callback - The callback of startAbilityWithAccount.
* @throws { BusinessError } 201 - The application does not have permission to call the interface.
@@ -1658,7 +1659,7 @@ declare class UIAbilityContext extends Context {
* @stagemodelonly
* @since 14
*/
- startAbilityWithAccount(want: Want, accountId: number, options: StartOptions, callback: AsyncCallback): void;
+ startAbilityWithAccount(want: Want, accountId: int, options: StartOptions, callback: AsyncCallback): void;
/**
* Starts a new ability with account. If the caller application is in foreground,
@@ -1744,7 +1745,7 @@ declare class UIAbilityContext extends Context {
*
* @permission ohos.permission.INTERACT_ACROSS_LOCAL_ACCOUNTS
* @param { Want } want - Indicates the want info to start.
- * @param { number } accountId - Indicates the account to start.
+ * @param { int } accountId - Indicates the account to start.
* @param { StartOptions } [options] - Indicates the start options.
* @returns { Promise } The promise returned by the function.
* @throws { BusinessError } 201 - The application does not have permission to call the interface.
@@ -1779,7 +1780,7 @@ declare class UIAbilityContext extends Context {
* @stagemodelonly
* @since 14
*/
- startAbilityWithAccount(want: Want, accountId: number, options?: StartOptions): Promise;
+ startAbilityWithAccount(want: Want, accountId: int, options?: StartOptions): Promise;
/**
* Starts an ability and returns the execution result when the ability is destroyed.
@@ -2510,7 +2511,7 @@ declare class UIAbilityContext extends Context {
*
* @permission ohos.permission.INTERACT_ACROSS_LOCAL_ACCOUNTS
* @param { Want } want - Indicates the want info to start.
- * @param { number } accountId - Indicates the account to start.
+ * @param { int } accountId - Indicates the account to start.
* @param { AsyncCallback } callback - The callback is used to return the result of startAbility.
* @throws { BusinessError } 201 - The application does not have permission to call the interface.
* @throws { BusinessError } 202 - The application is not system-app, can not use system-api.
@@ -2544,7 +2545,7 @@ declare class UIAbilityContext extends Context {
* @stagemodelonly
* @since 14
*/
- startAbilityForResultWithAccount(want: Want, accountId: number, callback: AsyncCallback): void;
+ startAbilityForResultWithAccount(want: Want, accountId: int, callback: AsyncCallback): void;
/**
* Starts an ability and returns the execution result when the ability is destroyed with account.
@@ -2655,7 +2656,7 @@ declare class UIAbilityContext extends Context {
*
* @permission ohos.permission.INTERACT_ACROSS_LOCAL_ACCOUNTS
* @param { Want } want - Indicates the want info to start.
- * @param { number } accountId - Indicates the account to start.
+ * @param { int } accountId - Indicates the account to start.
* @param { StartOptions } options - Indicates the start options.
* @param { AsyncCallback } callback - The callback is used to return the result of startAbility.
* @throws { BusinessError } 201 - The application does not have permission to call the interface.
@@ -2690,7 +2691,7 @@ declare class UIAbilityContext extends Context {
*/
startAbilityForResultWithAccount(
want: Want,
- accountId: number,
+ accountId: int,
options: StartOptions,
callback: AsyncCallback
): void;
@@ -2798,7 +2799,7 @@ declare class UIAbilityContext extends Context {
*
* @permission ohos.permission.INTERACT_ACROSS_LOCAL_ACCOUNTS
* @param { Want } want - Indicates the want info to start.
- * @param { number } accountId - Indicates the account to start.
+ * @param { int } accountId - Indicates the account to start.
* @param { StartOptions } [options] - Indicates the start options.
* @returns { Promise } Returns the result of startAbility.
* @throws { BusinessError } 201 - The application does not have permission to call the interface.
@@ -2833,7 +2834,7 @@ declare class UIAbilityContext extends Context {
* @stagemodelonly
* @since 14
*/
- startAbilityForResultWithAccount(want: Want, accountId: number, options?: StartOptions): Promise;
+ startAbilityForResultWithAccount(want: Want, accountId: int, options?: StartOptions): Promise;
/**
* Starts a new service extension ability.
@@ -3059,7 +3060,7 @@ declare class UIAbilityContext extends Context {
*
* @permission ohos.permission.INTERACT_ACROSS_LOCAL_ACCOUNTS
* @param { Want } want - Indicates the want info to start.
- * @param { number } accountId - Indicates the account to start.
+ * @param { int } accountId - Indicates the account to start.
* @param { AsyncCallback } callback - The callback of startServiceExtensionAbilityWithAccount.
* @throws { BusinessError } 201 - The application does not have permission to call the interface.
* @throws { BusinessError } 202 - The application is not system-app, can not use system-api.
@@ -3081,7 +3082,7 @@ declare class UIAbilityContext extends Context {
* @stagemodelonly
* @since 12
*/
- startServiceExtensionAbilityWithAccount(want: Want, accountId: number, callback: AsyncCallback): void;
+ startServiceExtensionAbilityWithAccount(want: Want, accountId: int, callback: AsyncCallback): void;
/**
* Starts a new service extension ability with account.
@@ -3145,7 +3146,7 @@ declare class UIAbilityContext extends Context {
*
* @permission ohos.permission.INTERACT_ACROSS_LOCAL_ACCOUNTS
* @param { Want } want - Indicates the want info to start.
- * @param { number } accountId - Indicates the account to start.
+ * @param { int } accountId - Indicates the account to start.
* @returns { Promise } The promise returned by the function.
* @throws { BusinessError } 201 - The application does not have permission to call the interface.
* @throws { BusinessError } 202 - The application is not system-app, can not use system-api.
@@ -3167,7 +3168,7 @@ declare class UIAbilityContext extends Context {
* @stagemodelonly
* @since 12
*/
- startServiceExtensionAbilityWithAccount(want: Want, accountId: number): Promise;
+ startServiceExtensionAbilityWithAccount(want: Want, accountId: int): Promise;
/**
* Stops other service extension ability.
@@ -3294,7 +3295,7 @@ declare class UIAbilityContext extends Context {
*
* @permission ohos.permission.INTERACT_ACROSS_LOCAL_ACCOUNTS
* @param { Want } want - Indicates the want info to start.
- * @param { number } accountId - Indicates the accountId to start.
+ * @param { int } accountId - Indicates the accountId to start.
* @param { AsyncCallback } callback - The callback of stopServiceExtensionAbilityWithAccount.
* @throws { BusinessError } 201 - The application does not have permission to call the interface.
* @throws { BusinessError } 202 - The application is not system-app, can not use system-api.
@@ -3312,7 +3313,7 @@ declare class UIAbilityContext extends Context {
* @stagemodelonly
* @since 10
*/
- stopServiceExtensionAbilityWithAccount(want: Want, accountId: number, callback: AsyncCallback): void;
+ stopServiceExtensionAbilityWithAccount(want: Want, accountId: int, callback: AsyncCallback): void;
/**
* Stops other service extension ability with account.
@@ -3345,7 +3346,7 @@ declare class UIAbilityContext extends Context {
*
* @permission ohos.permission.INTERACT_ACROSS_LOCAL_ACCOUNTS
* @param { Want } want - Indicates the want info to start.
- * @param { number } accountId - Indicates the accountId to start.
+ * @param { int } accountId - Indicates the accountId to start.
* @returns { Promise } The promise returned by the function.
* @throws { BusinessError } 201 - The application does not have permission to call the interface.
* @throws { BusinessError } 202 - The application is not system-app, can not use system-api.
@@ -3363,7 +3364,7 @@ declare class UIAbilityContext extends Context {
* @stagemodelonly
* @since 10
*/
- stopServiceExtensionAbilityWithAccount(want: Want, accountId: number): Promise;
+ stopServiceExtensionAbilityWithAccount(want: Want, accountId: int): Promise;
/**
* Destroys this Page ability.
@@ -3590,7 +3591,7 @@ declare class UIAbilityContext extends Context {
*
* @param { Want } want - The element name of the service ability
* @param { ConnectOptions } options - The remote object instance
- * @returns { number } Returns the number code of the ability connected
+ * @returns { long } Returns the number code of the ability connected
* @throws { BusinessError } 201 - The application does not have permission to call the interface.
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified. 2.Incorrect parameter types.
* @throws { BusinessError } 16000001 - The specified ability does not exist.
@@ -3605,9 +3606,10 @@ declare class UIAbilityContext extends Context {
* @throws { BusinessError } 16000055 - Installation-free timed out.
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @stagemodelonly
- * @since 10
+ * @since arkts {'1.1':'10', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
- connectServiceExtensionAbility(want: Want, options: ConnectOptions): number;
+ connectServiceExtensionAbility(want: Want, options: ConnectOptions): long;
/**
* Connects the current ability to an service extension ability with account.
@@ -3638,9 +3640,9 @@ declare class UIAbilityContext extends Context {
*
* @permission ohos.permission.INTERACT_ACROSS_LOCAL_ACCOUNTS
* @param { Want } want - The element name of the service ability
- * @param { number } accountId - The account to connect
+ * @param { int } accountId - The account to connect
* @param { ConnectOptions } options - The remote object instance
- * @returns { number } Returns the number code of the ability connected
+ * @returns { long } Returns the number code of the ability connected
* @throws { BusinessError } 201 - The application does not have permission to call the interface.
* @throws { BusinessError } 202 - The application is not system-app, can not use system-api.
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified. 2.Incorrect parameter types.
@@ -3659,35 +3661,37 @@ declare class UIAbilityContext extends Context {
* @stagemodelonly
* @since 10
*/
- connectServiceExtensionAbilityWithAccount(want: Want, accountId: number, options: ConnectOptions): number;
+ connectServiceExtensionAbilityWithAccount(want: Want, accountId: int, options: ConnectOptions): long;
/**
* Disconnect an ability from a service extension, in contrast to {@link connectAbility}.
*
- * @param { number } connection - The number code of the ability connected
+ * @param { long } connection - The number code of the ability connected
* @param { AsyncCallback } callback - The callback of disconnectAbility.
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified. 2.Incorrect parameter types.
* @throws { BusinessError } 16000011 - The context does not exist.
* @throws { BusinessError } 16000050 - Internal error.
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @stagemodelonly
- * @since 9
+ * @since arkts {'1.1':'9', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
- disconnectServiceExtensionAbility(connection: number, callback: AsyncCallback): void;
+ disconnectServiceExtensionAbility(connection: long, callback: AsyncCallback): void;
/**
* Disconnect an ability from a service extension, in contrast to {@link connectAbility}.
*
- * @param { number } connection - The number code of the ability connected
+ * @param { long } connection - The number code of the ability connected
* @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.
* @throws { BusinessError } 16000011 - The context does not exist.
* @throws { BusinessError } 16000050 - Internal error.
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @stagemodelonly
- * @since 9
+ * @since arkts {'1.1':'9', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
- disconnectServiceExtensionAbility(connection: number): Promise;
+ disconnectServiceExtensionAbility(connection: long): Promise;
/**
* Set mission label of current ability.
@@ -3712,7 +3716,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
*/
setMissionLabel(label: string, callback: AsyncCallback): void;
@@ -3739,7 +3744,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
*/
setMissionLabel(label: string): Promise;
@@ -4500,7 +4506,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
*/
startAbilityByType(type: string, wantParam: Record,
abilityStartCallback: AbilityStartCallback, callback: AsyncCallback): void;
@@ -4649,7 +4656,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
*/
openAtomicService(appId: string, options?: AtomicServiceOptions): Promise;
@@ -4831,7 +4839,8 @@ declare class UIAbilityContext extends Context {
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @stagemodelonly
* @atomicservice
- * @since 18
+ * @since arkts {'1.1':'18', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
setColorMode(colorMode: ConfigurationConstant.ColorMode): void;
@@ -4890,7 +4899,7 @@ declare class UIAbilityContext extends Context {
*
* @param { Want } want - The element name of the app service ability
* @param { ConnectOptions } callback - The callback for obtaining the connection result
- * @returns { number } Returns the number code of the ability connected
+ * @returns { long } Returns the number code of the ability connected
* @throws { BusinessError } 801 - Capability not supported.
* @throws { BusinessError } 16000001 - The specified ability does not exist.
* @throws { BusinessError } 16000002 - Incorrect ability type.
@@ -4905,12 +4914,12 @@ declare class UIAbilityContext extends Context {
* @stagemodelonly
* @since 20
*/
- connectAppServiceExtensionAbility(want: Want, callback: ConnectOptions): number;
+ connectAppServiceExtensionAbility(want: Want, callback: ConnectOptions): long;
/**
* Disconnect current ability from an app service extension, in contrast to {@link connectAppServiceExtensionAbility}.
*
- * @param { number } connection - The number code of the ability connected
+ * @param { long } connection - The number code of the ability connected
* @returns { Promise } The promise returned by the function.
* @throws { BusinessError } 801 - Capability not supported.
* @throws { BusinessError } 16000011 - The context does not exist.
@@ -4919,7 +4928,7 @@ declare class UIAbilityContext extends Context {
* @stagemodelonly
* @since 20
*/
- disconnectAppServiceExtensionAbility(connection: number): Promise;
+ disconnectAppServiceExtensionAbility(connection: long): Promise;
/**
* The onNewWant callback is not triggered when a UIAbility's lifecycle is driven by scenarios.
diff --git a/api/application/UIExtensionContext.d.ts b/api/application/UIExtensionContext.d.ts
index 46bd0450b668cafda889ef2f36ada5127a28d450..20cf87191bf5eec5df3ade42bdf468135e303091 100755
--- a/api/application/UIExtensionContext.d.ts
+++ b/api/application/UIExtensionContext.d.ts
@@ -20,6 +20,7 @@
import type { AsyncCallback } from '../@ohos.base';
+import type ConfigurationConstant from '../@ohos.app.ability.ConfigurationConstant';
import ExtensionContext from './ExtensionContext';
import type Want from '../@ohos.app.ability.Want';
import type StartOptions from '../@ohos.app.ability.StartOptions';
@@ -28,12 +29,12 @@ import type { AbilityResult } from '../ability/abilityResult';
import type { ConnectOptions } from '../ability/connectOptions';
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';
+import { ConnectOptions } from '../ability/connectOptions';
/*** endif */
/**
@@ -528,7 +529,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
*/
startAbilityForResult(want: Want, callback: AsyncCallback): void;
@@ -637,7 +639,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
*/
startAbilityForResult(want: Want, options: StartOptions, callback: AsyncCallback): void;
@@ -752,7 +755,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
*/
startAbilityForResult(want: Want, options?: StartOptions): Promise;
@@ -824,7 +828,7 @@ declare class UIExtensionContext extends ExtensionContext {
*
* @param { Want } want - The element name of the service ability
* @param { ConnectOptions } options - The remote object instance
- * @returns { number } Returns the number code of the ability connected
+ * @returns { long } Returns the number code of the ability connected
* @throws { BusinessError } 201 - The application does not have permission to call the interface.
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified. 2.Incorrect parameter types.
* @throws { BusinessError } 16000001 - The specified ability does not exist.
@@ -840,37 +844,40 @@ declare class UIExtensionContext extends ExtensionContext {
* @throws { BusinessError } 16000070 - The extension cannot start the service.
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @stagemodelonly
- * @since 10
+ * @since arkts {'1.1':'10', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
- connectServiceExtensionAbility(want: Want, options: ConnectOptions): number;
+ connectServiceExtensionAbility(want: Want, options: ConnectOptions): long;
/**
* Disconnect an ability from a service extension, in contrast to {@link connectAbility}.
*
- * @param { number } connection - The number code of the ability connected
+ * @param { long } connection - The number code of the ability connected
* @param { AsyncCallback } callback - The callback of disconnectAbility.
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified. 2.Incorrect parameter types.
* @throws { BusinessError } 16000011 - The context does not exist.
* @throws { BusinessError } 16000050 - Internal error.
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @stagemodelonly
- * @since 10
+ * @since arkts {'1.1':'10', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
- disconnectServiceExtensionAbility(connection: number, callback: AsyncCallback): void;
+ disconnectServiceExtensionAbility(connection: long, callback: AsyncCallback): void;
/**
* Disconnect an ability from a service extension, in contrast to {@link connectAbility}.
*
- * @param { number } connection - The number code of the ability connected
+ * @param { long } connection - The number code of the ability connected
* @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.
* @throws { BusinessError } 16000011 - The context does not exist.
* @throws { BusinessError } 16000050 - Internal error.
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @stagemodelonly
- * @since 10
+ * @since arkts {'1.1':'10', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
- disconnectServiceExtensionAbility(connection: number): Promise;
+ disconnectServiceExtensionAbility(connection: long): Promise;
/**
* Report to system when the extension is drawn completed.
@@ -880,7 +887,8 @@ declare class UIExtensionContext extends ExtensionContext {
* @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
*/
reportDrawnCompleted(callback: AsyncCallback): void;
@@ -1066,7 +1074,7 @@ declare class UIExtensionContext extends ExtensionContext {
*
* @permission ohos.permission.INTERACT_ACROSS_LOCAL_ACCOUNTS
* @param { Want } want - Indicates the want info to start.
- * @param { number } accountId - Indicates the account to start.
+ * @param { int } accountId - Indicates the account to start.
* @returns { Promise } The promise returned by the function.
* @throws { BusinessError } 201 - The application does not have permission to call the interface.
* @throws { BusinessError } 202 - The application is not system-app, can not use system-api.
@@ -1088,7 +1096,7 @@ declare class UIExtensionContext extends ExtensionContext {
* @stagemodelonly
* @since 18
*/
- startServiceExtensionAbilityWithAccount(want: Want, accountId: number): Promise;
+ startServiceExtensionAbilityWithAccount(want: Want, accountId: int): Promise;
/**
* Set the uiextension to either not allow being covered by the host page or allow it.
@@ -1112,7 +1120,8 @@ declare class UIExtensionContext extends ExtensionContext {
* @throws { BusinessError } 16000011 - The context does not exist.
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @stagemodelonly
- * @since 18
+ * @since arkts {'1.1':'18', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
setColorMode(colorMode: ConfigurationConstant.ColorMode): void;
diff --git a/api/application/UIServiceExtensionContext.d.ts b/api/application/UIServiceExtensionContext.d.ts
index f4be665a63d6cafac4d156cf6b28ed28b5cf8dac..8100602bfe7483d416666c873ea1e3a151a314a7 100644
--- a/api/application/UIServiceExtensionContext.d.ts
+++ b/api/application/UIServiceExtensionContext.d.ts
@@ -115,7 +115,7 @@ export default class UIServiceExtensionContext extends ExtensionContext {
*
* @param { Want } want - Indicates the service extension to connect.
* @param { ConnectOptions } options - Indicates the callback of connection.
- * @returns { number } Returns the connection id.
+ * @returns { long } Returns the connection id.
* @throws { BusinessError } 201 - The application does not have permission to call the interface.
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
* 2. Incorrect parameter types; 3. Parameter verification failed.
@@ -135,12 +135,12 @@ export default class UIServiceExtensionContext extends ExtensionContext {
* @stagemodelonly
* @since 14
*/
- connectServiceExtensionAbility(want: Want, options: ConnectOptions): number;
+ connectServiceExtensionAbility(want: Want, options: ConnectOptions): long;
/**
* Disconnect an ability from a service extension, in contrast to {@link connectServiceExtensionAbility}.
*
- * @param { number } connectionId - the connection id returned from connectServiceExtensionAbility api.
+ * @param { long } connectionId - the connection id returned from connectServiceExtensionAbility api.
* @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.
@@ -151,5 +151,5 @@ export default class UIServiceExtensionContext extends ExtensionContext {
* @stagemodelonly
* @since 14
*/
- disconnectServiceExtensionAbility(connectionId: number): Promise;
+ disconnectServiceExtensionAbility(connectionId: long): Promise;
}
diff --git a/api/application/shellCmdResult.d.ts b/api/application/shellCmdResult.d.ts
index a6b5ca83b48b0867f3a2eafe4c57733f2705d999..3a43b03a409044ebe01202887e8a9211429ef63d 100644
--- a/api/application/shellCmdResult.d.ts
+++ b/api/application/shellCmdResult.d.ts
@@ -63,13 +63,13 @@ export interface ShellCmdResult {
/**
* shell cmd exec result.
*
- * @type { number }
+ * @type { int }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @atomicservice
* @since arkts {'1.1':'11', '1.2':'20'}
* @arkts 1.1&1.2
*/
- exitCode: number;
+ exitCode: int;
}
/*** if arkts 1.1 */
diff --git a/api/wantAgent/wantAgentInfo.d.ts b/api/wantAgent/wantAgentInfo.d.ts
index 47e51b5367ab0d033713ff6646d57ce2f97549f6..e0ebefedff030e7010cae6207dd5aea818310784 100644
--- a/api/wantAgent/wantAgentInfo.d.ts
+++ b/api/wantAgent/wantAgentInfo.d.ts
@@ -112,7 +112,8 @@ export interface WantAgentInfo {
* @type { number }
* @syscap SystemCapability.Ability.AbilityRuntime.Core
* @atomicservice
- * @since 12
+ * @since arkts {'1.1':'12', '1.2':'20'}
+ * @arkts 1.1&1.2
*/
requestCode: number;