<td class="cellrowborder" valign="top" width="68%"><p id="p1998432514020"><a name="p1998432514020"></a><a name="p1998432514020"></a>Bundle name of the application. It uniquely identifies the application.</p>
<td class="cellrowborder" valign="top" width="69.72697269726973%" headers="mcps1.2.4.1.3 "><p id="p37010510548"><a name="p37010510548"></a><a name="p37010510548"></a>Current language of the application, for example, <strong id="b1260120418488"><a name="b1260120418488"></a><a name="b1260120418488"></a>zh</strong>.</p>
<td class="cellrowborder" valign="top" width="69.72697269726973%" headers="mcps1.2.4.1.3 "><p id="p33321417565"><a name="p33321417565"></a><a name="p33321417565"></a>Text layout direction. Available values are as follows:</p>
<a name="ul1861816241119"></a><a name="ul1861816241119"></a><ul id="ul1861816241119"><li><strong id="b16720155216481"><a name="b16720155216481"></a><a name="b16720155216481"></a>ltr</strong>: The text direction is from left to right.</li><li><strong id="b1910563194919"><a name="b1910563194919"></a><a name="b1910563194919"></a>rtl</strong>: The text direction is from right to left.</li></ul>
<td class="cellrowborder" valign="top" width="69.72697269726973%" headers="mcps1.2.4.1.3 "><p id="p97106183311"><a name="p97106183311"></a><a name="p97106183311"></a>Unicode key set determined by the locale.</p>
<p id="p213145115319"><a name="p213145115319"></a><a name="p213145115319"></a>For example, <strong id="b14471162633518"><a name="b14471162633518"></a><a name="b14471162633518"></a>{"nu":"arab"}</strong> indicates that the current locale uses Arabic numerals.</p>
<p id="p849701364"><a name="p849701364"></a><a name="p849701364"></a>If the current locale does not have a specific key set, an empty set is returned.</p>
> The initial APIs of this module are supported since API 8. Newly added APIs will be marked with a superscript to indicate their earliest API version.
> The initial APIs of this module are supported since API version 9. Newly added APIs will be marked with a superscript to indicate their earliest API version.
Provides APIs related to **ServiceExtension**.
Provides APIs related to **ServiceExtension**.
...
@@ -10,13 +10,13 @@ Provides APIs related to **ServiceExtension**.
...
@@ -10,13 +10,13 @@ Provides APIs related to **ServiceExtension**.
## Modules to Import
## Modules to Import
```
```
import ServiceExtension from '@ohos.application.ServiceExtension';
import ServiceExtension from '@ohos.application.ServiceExtensionAbility';
```
```
## Required Permissions
## Required Permissions
None
None.
## Attributes
## Attributes
...
@@ -26,7 +26,7 @@ None
...
@@ -26,7 +26,7 @@ None
| context | [ServiceExtensionContext](js-apis-service-extension-context.md) | Yes| No| Service extension context, which is inherited from **ExtensionContext**.<br>**System capability**: SystemCapability.Ability.AbilityRuntime.Core|
| context | [ServiceExtensionContext](js-apis-service-extension-context.md) | Yes| No| Service extension context, which is inherited from **ExtensionContext**.<br>**System capability**: SystemCapability.Ability.AbilityRuntime.Core|
## onCreate
## ServiceExtensionAbility.onCreate
onCreate(want: Want): void;
onCreate(want: Want): void;
...
@@ -51,7 +51,7 @@ Called when an extension is created to initialize the service logic.
...
@@ -51,7 +51,7 @@ Called when an extension is created to initialize the service logic.
```
```
## onDestroy
## ServiceExtensionAbility.onDestroy
onDestroy(): void;
onDestroy(): void;
...
@@ -70,7 +70,7 @@ Called when this extension is destroyed to clear resources.
...
@@ -70,7 +70,7 @@ Called when this extension is destroyed to clear resources.
```
```
## onRequest
## ServiceExtensionAbility.onRequest
onRequest(want: Want, startId: number): void;
onRequest(want: Want, startId: number): void;
...
@@ -96,7 +96,7 @@ Called after **onCreate** is invoked when an ability is started by calling **sta
...
@@ -96,7 +96,7 @@ Called after **onCreate** is invoked when an ability is started by calling **sta
```
```
## onConnect
## ServiceExtensionAbility.onConnect
onConnect(want: Want): rpc.RemoteObject;
onConnect(want: Want): rpc.RemoteObject;
...
@@ -136,7 +136,7 @@ Called after **onCreate** is invoked when an ability is started by calling **con
...
@@ -136,7 +136,7 @@ Called after **onCreate** is invoked when an ability is started by calling **con