• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Ability Framework Changelog
2
3## cl.ability.1 Application Component Startup Rule Change
4
5The rules for starting application components are changed in the following scenarios:
6
7 - Start an application component when the application is in the background.
8 - Start an invisible application component across applications.
9 - Start a ServiceAbility and DataAbility of the FA model across applications.
10 - Use the **startAbilityByCall** API.
11
12You need to adapt your application.
13
14
15**Change Impact**
16
17If new rules are not adapted, application components cannot be started in the previous scenarios.
18> **NOTE**
19>
20> Starting application components refers to any behavior starting or connecting to an ability.
21>
22> 1. Start an ability using APIs such as **startAbility**, **startServiceExtensionAbility**, and **startAbilityByCall**.
23> 2. Connect to an ability using APIs such as **connectAbility**, **connectServiceExtensionAbility**, **acquireDataAbilityHelper**, and **createDataShareHelper**.
24
25**Key API/Component Changes**
26
27 - Involved application components
28   - Stage model
29     - Ability
30     - ServiceExtension
31     - DataShareExtension
32   - FA model
33     - PageAbility
34     - ServiceAbility
35     - DataAbility
36 - Involved APIs
37   - Stage model
38     - startAbility(want: Want, callback: AsyncCallback<void>): void;
39     - startAbility(want: Want, options: StartOptions, callback: AsyncCallback<void>): void;
40     - startAbility(want: Want, options?: StartOptions): Promise<void>;
41     - startAbilityByCall(want: Want): Promise<Caller>;
42     - startAbilityWithAccount(want: Want, accountId: number, callback: AsyncCallback<void>): void;
43     - startAbilityWithAccount(want: Want, accountId: number, options: StartOptions, callback: AsyncCallback<void>): void;
44     - startAbilityWithAccount(want: Want, accountId: number, options?: StartOptions): Promise<void>;
45     - startAbilityForResult(want: Want, callback: AsyncCallback<AbilityResult>): void;
46     - startAbilityForResult(want: Want, options: StartOptions, callback: AsyncCallback<AbilityResult>): void;
47     - startAbilityForResult(want: Want, options?: StartOptions): Promise<AbilityResult>;
48     - startAbilityForResultWithAccount(want: Want, accountId: number, callback: AsyncCallback<AbilityResult>): void;
49     - startAbilityForResultWithAccount(want: Want, accountId: number, options: StartOptions, callback: AsyncCallback<void>): void;
50     - startAbilityForResultWithAccount(want: Want, accountId: number, options?: StartOptions): Promise<AbilityResult>;
51     - startServiceExtensionAbility(want: Want, callback: AsyncCallback<void>): void;
52     - startServiceExtensionAbility(want: Want): Promise<void>;
53     - startServiceExtensionAbilityWithAccount(want: Want, accountId: number, callback: AsyncCallback<void>): void;
54     - startServiceExtensionAbilityWithAccount(want: Want, accountId: number): Promise<void>;
55     - stopServiceExtensionAbility(want: Want, callback: AsyncCallback<void>): void;
56     - stopServiceExtensionAbility(want: Want): Promise<void>;
57     - stopServiceExtensionAbilityWithAccount(want: Want, accountId: number, callback: AsyncCallback<void>): void;
58     - stopServiceExtensionAbilityWithAccount(want: Want, accountId: number): Promise<void>;
59     - connectAbility(want: Want, options: ConnectOptions): number;
60     - connectAbilityWithAccount(want: Want, accountId: number, options: ConnectOptions): number;
61     - createDataShareHelper(context: Context, uri: string, callback: AsyncCallback<DataShareHelper>): void
62   - FA model
63     - startAbility(parameter: StartAbilityParameter, callback: AsyncCallback<number>): void;
64     - startAbility(parameter: StartAbilityParameter): Promise<number>;
65     - startAbilityForResult(parameter: StartAbilityParameter, callback: AsyncCallback<AbilityResult>): void;
66     - startAbilityForResult(parameter: StartAbilityParameter): Promise<AbilityResult>;
67     - acquireDataAbilityHelper(uri: string): DataAbilityHelper;
68     - connectAbility(request: Want, options:ConnectOptions ): number;
69
70**Adaptation Guide**
71
72Startup rules for different scenarios are as follows:
73 - **Starting an application component when the application is in the background**
74   - Rule in OpenHarmony 3.2 Beta3:
75
76      - There is no restriction.
77   - Rule in OpenHarmony 3.2 Beta4:
78     - Authentication is required. The following permissions must be configured:
79      - ```json
80        {
81            "name": "ohos.permission.START_ABILITIES_FROM_BACKGROUND",
82            "grantMode": "system_grant",
83            "availableLevel": "system_basic",
84            "provisionEnable": true,
85            "distributedSceneEnable": false
86        }
87        ```
88          > **NOTE**
89          >
90         > 1. Starting an application component of the same application is also restricted by this rule.
91         > 2. For SDKs of API version 8 or earlier, starting a ServiceAbility and DataAbility is not restricted by this rule.
92
93 - **Starting an invisible application component across applications**
94
95   - Rule in OpenHarmony 3.2 Beta3:
96
97     - For applications whose APL is normal, invisible application components cannot be started across applications.
98   - Rule in OpenHarmony 3.2 Beta4:
99     - For all applications, starting an invisible application component across applications requires authentication. The following permissions must be configured:
100     - ```json
101        {
102            "name": "ohos.permission.START_INVISIBLE_ABILITY",
103            "grantMode": "system_grant",
104            "availableLevel": "system_core",
105            "provisionEnable": true,
106            "distributedSceneEnable": false
107        }
108        ```
109
110 - **Starting a ServiceAbility and DataAbility of the FA model across applications**
111
112   - Rule in OpenHarmony 3.2 Beta3:
113     - There is no restriction.
114   - Rule in OpenHarmony 3.2 Beta4:
115     - Associated startup must be configured for the provider of the ServiceAbility and DataAbility. Otherwise, they cannot be started across applications. (Associated startup cannot be configured for common applications.)
116
117
118 - **Using the startAbilityByCall API**
119   - Rule in OpenHarmony 3.2 Beta3:
120
121     - This is no restriction.
122   - Rule in OpenHarmony 3.2 Beta4:
123
124     - The **startAbilityByCall** API cannot be called by the same application.
125   - Calling the **startAbilityByCall** API across applications requires authentication. The following permissions must be configured:
126
127      - ```json
128        {
129            "name": "ohos.permission.ABILITY_BACKGROUND_COMMUNICATION",
130            "grantMode": "system_grant",
131            "availableLevel": "system_basic",
132            "provisionEnable": true,
133            "distributedSceneEnable": false
134        }
135        ```
136        > **NOTE**
137        >
138        > Using the **startAbilityByCall** API is also restricted by the background startup and across-application invisible component startup rules.
139
140## cl.ability.2 Cross-Device Application Component Startup Rule Change (for System Applications Only)
141
142The rules for starting cross-device application components are changed in the following scenarios:
143
144 - Start an application component when the application is in the background.
145 - Start an invisible application component across applications.
146 - Start a ServiceAbility of the FA model across applications.
147
148You need to adapt your application.
149
150
151**Change Impact**
152
153If new rules are not adapted, application components cannot be started in the previous scenarios.
154> **NOTE**
155>
156> Starting application components refers to any behavior starting or connecting to an ability.
157>
158> 1. Start an ability using APIs such as **startAbility**, **startAbilityForResult**, and **startAbilityByCall**.
159> 2. Connect to an ability using APIs such as **connectAbility**.
160
161**Key API/Component Changes**
162
163 - Involved application components
164   - Stage model
165     - Ability
166     - ServiceExtension
167   - FA model
168     - PageAbility
169     - ServiceAbility
170 - Involved APIs
171   - Stage model
172     - startAbility(want: Want, callback: AsyncCallback<void>): void;
173     - startAbilityByCall(want: Want): Promise<Caller>;
174     - startAbilityForResult(want: Want, callback: AsyncCallback<AbilityResult>): void;
175     - connectAbility(want: Want, options: ConnectOptions): number;
176   - FA model
177     - startAbility(parameter: StartAbilityParameter, callback: AsyncCallback<number>): void;
178     - startAbility(parameter: StartAbilityParameter): Promise<number>;
179     - startAbilityForResult(parameter: StartAbilityParameter, callback: AsyncCallback<AbilityResult>): void;
180     - startAbilityForResult(parameter: StartAbilityParameter): Promise<AbilityResult>;
181     - connectAbility(request: Want, options:ConnectOptions ): number;
182
183**Adaptation Guide**
184
185Startup rules for different scenarios are as follows:
186 - **Starting an application component when the application is in the background**
187   - Rule in OpenHarmony 3.2 Beta3:
188
189      - There is no restriction.
190   - Rule in OpenHarmony 3.2 Beta4:
191     - Authentication is required. The following permissions must be configured:
192      - ```json
193        {
194            "name": "ohos.permission.START_ABILITIES_FROM_BACKGROUND",
195            "grantMode": "system_grant",
196            "availableLevel": "system_basic",
197            "provisionEnable": true,
198            "distributedSceneEnable": false
199        }
200        ```
201          > **NOTE**
202            1. Starting an application component of the same application is also restricted by this rule.
203                2.  For SDKs of API version 8 or earlier, starting a ServiceAbility is not restricted by this rule.
204
205 - **Starting an invisible application component across applications**
206
207   - Rule in OpenHarmony 3.2 Beta3:
208
209     - Invisible application components cannot be started across applications.
210   - Rule in OpenHarmony 3.2 Beta4:
211     - Authentication is required. The following permissions must be configured:
212     - ```json
213        {
214            "name": "ohos.permission.START_INVISIBLE_ABILITY",
215            "grantMode": "system_grant",
216            "availableLevel": "system_core",
217            "provisionEnable": true,
218            "distributedSceneEnable": false
219        }
220        ```
221
222 - **Starting a ServiceAbility of the FA model across applications**
223
224   - Rule in OpenHarmony 3.2 Beta3:
225
226     - There is no restriction.
227   - Rule in OpenHarmony 3.2 Beta4:
228     - Associated startup needs to be configured for the provider of the ServiceAbility. Otherwise, the ServiceAbility cannot be started across applications. (Associated startup cannot be configured for common applications.)
229     - Configure associated startup as follows:
230     - ```json
231        {
232            "bundleName": "",
233            "app_signature": ["xxxxxxxxxxxxxxxxxxx"],
234            "associatedWakeUp": true
235        }
236        ```
237
238## cl.ability.3 API Exception Handling Method Change
239
240Certain APIs of the ability subsystem use service logic return values to indicate error information, which does not comply with the API error code specifications of OpenHarmony.
241
242**Change Impact**
243
244The application developed based on earlier versions needs to be adapted. Otherwise, the service logic will be affected.
245
246**Key API/Component Changes**
247
248For adaptation to the unified API exception handling mode, certain ability subsystem APIs are deprecated (original APIs in the following table) and corresponding new APIs in the following table are added. (In the following table, original APIs in API version 9 will be deleted, and APIs in API version 8 and earlier will be deprecated.) The newly added APIs support unified error code handling specifications and function the same as the original APIs.
249
250| Original API                                         | New API                                         |
251| ----------------------------------------------- | ----------------------------------------------- |
252| @ohos.ability.wantConstant.d.ts                 | @ohos.app.ability.wantConstant.d.ts             |
253| @ohos.application.Ability.d.ts                  | @ohos.app.ability.UIAbility.d.ts                |
254| @ohos.application.AbilityConstant.d.ts          | @ohos.app.ability.AbilityConstant.d.ts          |
255| @ohos.application.abilityDelegatorRegistry.d.ts | @ohos.app.ability.abilityDelegatorRegistry.d.ts |
256| @ohos.application.AbilityLifecycleCallback.d.ts | @ohos.app.ability.AbilityLifecycleCallback.d.ts |
257| @ohos.application.abilityManager.d.ts           | @ohos.app.ability.abilityManager.d.ts           |
258| @ohos.application.AbilityStage.d.ts             | @ohos.app.ability.AbilityStage.d.ts             |
259| @ohos.application.appManager.d.ts               | @ohos.app.ability.appManager.d.ts               |
260| @ohos.application.Configuration.d.ts            | @ohos.app.ability.Configuration.d.ts            |
261| @ohos.application.ConfigurationConstant.d.ts    | @ohos.app.ability.ConfigurationConstant.d.ts    |
262| @ohos.application.context.d.ts                  | @ohos.app.ability.common.d.ts                   |
263| @ohos.application.EnvironmentCallback.d.ts      | @ohos.app.ability.EnvironmentCallback.d.ts      |
264| @ohos.application.errorManager.d.ts             | @ohos.app.ability.errorManager.d.ts             |
265| @ohos.application.ExtensionAbility.d.ts         | @ohos.app.ability.ExtensionAbility.d.ts         |
266| @ohos.application.formBindingData.d.ts          | @ohos.app.form.formBindingData.d.ts             |
267| @ohos.application.FormExtension.d.ts            | @ohos.app.form.FormExtensionAbility.d.ts        |
268| @ohos.application.formHost.d.ts                 | @ohos.app.form.formHost.d.ts                    |
269| @ohos.application.formInfo.d.ts                 | @ohos.app.form.formInfo.d.ts                    |
270| @ohos.application.formProvider.d.ts             | @ohos.app.form.formProvider.d.ts                |
271| @ohos.application.missionManager.d.ts           | @ohos.app.ability.missionManager.d.ts           |
272| @ohos.application.quickFixManager.d.ts          | @ohos.app.ability.quickFixManager.d.ts          |
273| @ohos.application.ServiceExtensionAbility.d.ts  | @ohos.app.ability.ServiceExtensionAbility.d.ts  |
274| @ohos.application.StartOptions.d.ts             | @ohos.app.ability.StartOptions.d.ts             |
275| @ohos.application.Want.d.ts                     | @ohos.app.ability.Want.d.ts                     |
276| @ohos.wantAgent.d.ts                            | @ohos.app.ability.wantAgent.d.ts                |
277
278**Adaptation Guide**
279
280The original APIs are only moved to the new namespace. Therefore, you can modify **import** to solve the adaptation problem.
281
282If the original API uses **@ohos.application.missionManager**:
283
284```js
285import missionManager from '@ohos.application.missionManager';
286```
287
288You can directly modify **import** to switch to the new namespace:
289
290```js
291import missionManager from '@ohos.app.ability.missionManager';
292```
293
294In addition, exception handling is needed. For details, see the API reference for the new APIs.
295
296## cl.ability.4 API Change
297
298The names of certain ability subsystem APIs are changed.
299
300**Key API/Component Changes**
301
302| Module                                   | Class                   | Method/Attribute/Enum/Constant                                         | Change Type|
303| ----------------------------------------- | ----------------------- | ------------------------------------------------------------ | -------- |
304| @ohos.application.Ability                 | Caller                  | onRelease(callback: OnReleaseCallBack): **void**;            | Deprecated    |
305| @ohos.app.ability.UIAbility               | Caller                  | on(**type**: "release", callback: OnReleaseCallBack): **void**; | Added    |
306| @ohos.application.Ability                 | Ability                 | dump(params: Array<**string**>): Array<**string**>;          | Deprecated    |
307| @ohos.app.ability.UIAbility               | UIAbility               | onDump(params: Array<**string**>): Array<**string**>;        | Added    |
308| @ohos.application.appManager              | appManager              | **function** registerApplicationStateObserver(observer: ApplicationStateObserver): **number**; | Deprecated    |
309| @ohos.application.appManager              | appManager              | **function** registerApplicationStateObserver(observer: ApplicationStateObserver, bundleNameList: Array<**string**>): **number**; | Deprecated    |
310| @ohos.application.appManager              | appManager              | **function** unregisterApplicationStateObserver(observerId: **number**, callback: AsyncCallback<**void**>): **void**; | Deprecated    |
311| @ohos.application.appManager              | appManager              | **function** unregisterApplicationStateObserver(observerId: **number**): Promise<**void**>; | Deprecated    |
312| @ohos.app.ability.appManager              | appManager              | **function** on(**type**: "applicationState", observer: ApplicationStateObserver): **number**; | Added    |
313| @ohos.app.ability.appManager              | appManager              | **function** on(**type**: "applicationState", observer: ApplicationStateObserver, bundleNameList: Array<**string**>): **number**; | Added    |
314| @ohos.app.ability.appManager              | appManager              | **function** off(**type**: "applicationState", observerId: **number**, callback: AsyncCallback<**void**>): **void**; | Added    |
315| @ohos.app.ability.appManager              | appManager              | **function** off(**type**: "applicationState", observerId: **number**): Promise<**void**>; | Added    |
316| @ohos.application.errorManager            | errorManager            | **function** registerErrorObserver(observer: ErrorObserver): **number**; | Deprecated    |
317| @ohos.application.errorManager            | errorManager            | **function** unregisterErrorObserver(observerId: **number**, callback: AsyncCallback<**void**>): **void**; | Deprecated    |
318| @ohos.application.errorManager            | errorManager            | **function** unregisterErrorObserver(observerId: **number**): Promise<**void**>; | Deprecated    |
319| @ohos.app.ability.errorManager            | errorManager            | **function** on(**type**: "error", observer: ErrorObserver): **number**; | Added    |
320| @ohos.app.ability.errorManager            | errorManager            | **function** off(**type**: "error", observerId: **number**, callback: AsyncCallback<**void**>): **void**; | Added    |
321| @ohos.app.ability.errorManager            | errorManager            | **function** off(**type**: "error", observerId: **number**): Promise<**void**>; | Added    |
322| @ohos.application.missionManager          | missionManager          | **function** registerMissionListener(listener: MissionListener): **number**; | Deprecated    |
323| @ohos.application.missionManager          | missionManager          | **function** unregisterMissionListener(listenerId: **number**, callback: AsyncCallback<**void**>): **void**; | Deprecated    |
324| @ohos.application.missionManager          | missionManager          | **function** unregisterMissionListener(listenerId: **number**): Promise<**void**>; | Deprecated    |
325| @ohos.app.ability.missionManager          | missionManager          | **function** on(**type**: "mission", listener: MissionListener): **number**; | Added    |
326| @ohos.app.ability.missionManager          | missionManager          | **function** off(**type**: "mission", listenerId: **number**, callback: AsyncCallback<**void**>): **void**; | Added    |
327| @ohos.app.ability.missionManager          | missionManager          | **function** off(**type**: "mission", listenerId: **number**): Promise<**void**>; | Added    |
328| @ohos.application.FormExtension           | FormExtension           | onCreate(want: Want): formBindingData.FormBindingData;       | Deprecated    |
329| @ohos.application.FormExtension           | FormExtension           | onCastToNormal(formId: **string**): **void**;                | Deprecated    |
330| @ohos.application.FormExtension           | FormExtension           | onUpdate(formId: **string**): **void**;                      | Deprecated    |
331| @ohos.application.FormExtension           | FormExtension           | onVisibilityChange(newStatus: { [key: **string**]: **number** }): **void**; | Deprecated    |
332| @ohos.application.FormExtension           | FormExtension           | onEvent(formId: **string**, message: **string**): **void**;  | Deprecated    |
333| @ohos.application.FormExtension           | FormExtension           | onDestroy(formId: **string**): **void**;                     | Deprecated    |
334| @ohos.application.FormExtension           | FormExtension           | onShare?(formId: **string**): {[key: **string**]: **any**};  | Deprecated    |
335| @ohos.app.form.FormExtensionAbility       | FormExtensionAbility    | onAddForm(want: Want): formBindingData.FormBindingData;      | Added    |
336| @ohos.app.form.FormExtensionAbility       | FormExtensionAbility    | onCastToNormalForm(formId: **string**): **void**;            | Added    |
337| @ohos.app.form.FormExtensionAbility       | FormExtensionAbility    | onUpdateForm(formId: **string**): **void**;                  | Added    |
338| @ohos.app.form.FormExtensionAbility       | FormExtensionAbility    | onChangeFormVisibility(newStatus: { [key: **string**]: **number** }): **void**; | Added    |
339| @ohos.app.form.FormExtensionAbility       | FormExtensionAbility    | onFormEvent(formId: **string**, message: **string**): **void**; | Added    |
340| @ohos.app.form.FormExtensionAbility       | FormExtensionAbility    | onRemoveForm(formId: **string**): **void**;                  | Added    |
341| @ohos.app.form.FormExtensionAbility       | FormExtensionAbility    | onShareForm?(formId: **string**): {[key: **string**]: **any**}; | Added    |
342| @ohos.application.formHost.d.ts           | formHost                | **function** castTempForm(formId: **string**, callback: AsyncCallback<**void**>): **void**; | Deprecated    |
343| @ohos.application.formHost.d.ts           | formHost                | **function** castTempForm(formId: **string**): Promise<**void**>; | Deprecated    |
344| @ohos.app.form.formHost.d.ts              | formHost                | **function** castToNormalForm(formId: **string**, callback: AsyncCallback<**void**>): **void**; | Added    |
345| @ohos.app.form.formHost.d.ts              | formHost                | **function** castToNormalForm(formId: **string**): Promise<**void**>; | Added    |
346| @ohos.application.ServiceExtensionAbility | ServiceExtensionAbility | dump(params: Array<**string**>): Array<**string**>;          | Deprecated    |
347| @ohos.app.ability.ServiceExtensionAbility | ServiceExtensionAbility | onDump(params: Array<**string**>): Array<**string**>;        | Added    |
348| application/AbilityContext                | AbilityContext          | connectAbility(want: Want, options: ConnectOptions): **number**; | Deprecated    |
349| application/AbilityContext                | AbilityContext          | connectAbilityWithAccount(want: Want, accountId: **number**, options: ConnectOptions): **number**; | Deprecated    |
350| application/AbilityContext                | AbilityContext          | disconnectAbility(connection: **number**, callback: AsyncCallback<**void**>): **void**; | Deprecated    |
351| application/AbilityContext                | AbilityContext          | disconnectAbility(connection: **number**): Promise<**void**>; | Deprecated    |
352| application/UIAbilityContext              | UIAbilityContext        | connectServiceExtensionAbilityWithAccount(want: Want, accountId: **number**, options: ConnectOptions): **number**; | Added    |
353| application/UIAbilityContext              | UIAbilityContext        | connectServiceExtensionAbilityWithAccount(want: Want, accountId: **number**, options: ConnectOptions): **number**; | Added    |
354| application/UIAbilityContext              | UIAbilityContext        | disconnectServiceExtensionAbility(connection: **number**, callback: AsyncCallback<**void**>): **void**; | Added    |
355| application/UIAbilityContext              | UIAbilityContext        | disconnectServiceExtensionAbility(connection: **number**): Promise<**void**>; | Added    |
356| application/ApplicationContext            | ApplicationContext      | registerAbilityLifecycleCallback(callback: AbilityLifecycleCallback): **number**; | Deprecated    |
357| application/ApplicationContext            | ApplicationContext      | unregisterAbilityLifecycleCallback(callbackId: **number**, callback: AsyncCallback<**void**>): **void**; | Deprecated    |
358| application/ApplicationContext            | ApplicationContext      | unregisterAbilityLifecycleCallback(callbackId: **number**): Promise<**void**>; | Deprecated    |
359| application/ApplicationContext            | ApplicationContext      | registerEnvironmentCallback(callback: EnvironmentCallback): **number**; | Deprecated    |
360| application/ApplicationContext            | ApplicationContext      | unregisterEnvironmentCallback(callbackId: **number**, callback: AsyncCallback<**void**>): **void**; | Deprecated    |
361| application/ApplicationContext            | ApplicationContext      | unregisterEnvironmentCallback(callbackId: **number**): Promise<**void**>; | Deprecated    |
362| application/ApplicationContext            | ApplicationContext      | on(**type**: "abilityLifecycle", callback: AbilityLifecycleCallback): **number**; | Added    |
363| application/ApplicationContext            | ApplicationContext      | off(**type**: "abilityLifecycle", callbackId: **number**, callback: AsyncCallback<**void**>): **void**; | Added    |
364| application/ApplicationContext            | ApplicationContext      | off(**type**: "abilityLifecycle", callbackId: **number**): Promise<**void**>; | Added    |
365| application/ApplicationContext            | ApplicationContext      | on(**type**: "environment", callback: EnvironmentCallback): **number**; | Added    |
366| application/ApplicationContext            | ApplicationContext      | off(**type**: "environment", callbackId: **number**, callback: AsyncCallback<**void**>): **void**; | Added    |
367| application/ApplicationContext            | ApplicationContext      | off(**type**: "environment", callbackId: **number**): Promise<**void**>; | Added    |
368| application/ServiceExtensionContext       | ServiceExtensionContext | connectAbility(want: Want, options: ConnectOptions): **number**; | Deprecated    |
369| application/ServiceExtensionContext       | ServiceExtensionContext | connectAbilityWithAccount(want: Want, accountId: **number**, options: ConnectOptions): **number**; | Deprecated    |
370| application/ServiceExtensionContext       | ServiceExtensionContext | disconnectAbility(connection: **number**, callback: AsyncCallback<**void**>): **void**; | Deprecated    |
371| application/ServiceExtensionContext       | ServiceExtensionContext | disconnectAbility(connection: **number**): Promise<**void**>; | Deprecated    |
372| application/ServiceExtensionContext       | ServiceExtensionContext | connectServiceExtensionAbility(want: Want, options: ConnectOptions): **number**; | Added    |
373| application/ServiceExtensionContext       | ServiceExtensionContext | connectServiceExtensionAbilityWithAccount(want: Want, accountId: **number**, options: ConnectOptions): **number**; | Added    |
374| application/ServiceExtensionContext       | ServiceExtensionContext | disconnectServiceExtensionAbility(connection: **number**, callback: AsyncCallback<**void**>): **void**; | Added    |
375| application/ServiceExtensionContext       | ServiceExtensionContext | disconnectServiceExtensionAbility(connection: **number**): Promise<**void**>; | Added    |
376