提交 5db869ba 编写于 作者: S shawn_he

update doc

Signed-off-by: Nshawn_he <shawn.he@huawei.com>
上级 e11ce5f9
......@@ -1327,7 +1327,7 @@ This is a system API.
| Name | Type | Mandatory| Description |
| -------- | ----------------------------------------------------------- | ---- | ------------------------------------------------------------ |
| slotId | number | Yes | Card slot ID.<br>- **0**: card slot 1<br>- **1**: card slot 2 |
| callback | AsyncCallback&lt;[CallWaitingStatus](#callwaitingstatus7)\> | Yes | Callback used to return the result.<br> <br>- **0**: Call waiting is disabled.<br>- **1**: Call waiting is enabled.|
| callback | AsyncCallback&lt;[CallWaitingStatus](#callwaitingstatus7)\> | Yes | Callback used to return the result.<br><br>- **0**: Call waiting is disabled.<br>- **1**: Call waiting is enabled.|
**Example**
......@@ -2744,12 +2744,12 @@ Defines the dialup options.
**System capability**: SystemCapability.Telephony.CallManager
| Name | Type | Mandatory| Description |
| ---------- | ---------------------------------- | ---- | ------------------------------------------------------------ |
| ------------------------ | ---------------------------------- | ---- | ------------------------------------------------------------ |
| extras | boolean | No | Indication of a video call. <br>- **true**: video call<br>- **false** (default): voice call|
| accountId | number | No | Account ID. This API is supported since API version 8. It is a system API. |
| videoState | [VideoStateType](#videostatetype7) | No | Video state type. This API is supported since API version 8. It is a system API. |
| dialScene | [DialScene](#dialscene8) | No | Dialup scenario. This API is supported since API version 8. It is a system API. |
| dialType | [DialType](#dialtype8) | No | Dialup type. This API is supported since API version 8. It is a system API. |
| accountId <sup>8+</sup> | number | No | Account ID. This is a system API. |
| videoState <sup>8+</sup> | [VideoStateType](#videostatetype7) | No | Video state type. This is a system API. |
| dialScene <sup>8+</sup> | [DialScene](#dialscene8) | No | Dialup scenario. This is a system API. |
| dialType <sup>8+</sup> | [DialType](#dialtype8) | No | Dialup type. This is a system API. |
## CallState
......
......@@ -1588,6 +1588,128 @@ promise.then(data => {
});
```
## radio.getImsRegInfo<sup>9+</sup>
getImsRegInfo(slotId: number, imsType: ImsServiceType, callback: AsyncCallback<ImsRegInfo\>): void
Obtains the IMS registration status of the specified IMS service type. This API uses an asynchronous callback to return the result.
This is a system API.
**Required permission**: ohos.permission.GET_TELEPHONY_STATE
**System capability**: SystemCapability.Telephony.CoreService
**Parameters**
| Name | Type | Mandatory| Description |
| -------- | ------------------------------------------ | ---- | -------------------------------------- |
| slotId | number | Yes | Card slot ID.<br>- **0**: card slot 1<br>- **1**: card slot 2|
| imsType | [ImsServiceType](#imsservicetype9) | Yes | IMS service type. |
| callback | AsyncCallback<[ImsRegInfo](#imsreginfo9)\> | Yes | Callback used to return the result. |
**Example**
```js
radio.getImsRegInfo(0, 1, (err, data) => {
console.log(`callback: err->${JSON.stringify(err)}, data->${JSON.stringify(data)}`);
});
```
## radio.getImsRegInfo<sup>9+</sup>
getImsRegInfo(slotId: number, imsType: ImsServiceType): Promise<ImsRegInfo\>
Obtains the IMS registration status of the specified IMS service type. This API uses a promise to return the result.
This is a system API.
**Required permission**: ohos.permission.GET_TELEPHONY_STATE
**System capability**: SystemCapability.Telephony.CoreService
**Parameters**
| Name | Type | Mandatory| Description |
| ------- | ---------------------------------- | ---- | -------------------------------------- |
| slotId | number | Yes | Card slot ID.<br>- **0**: card slot 1<br>- **1**: card slot 2|
| imsType | [ImsServiceType](#imsservicetype9) | Yes | IMS service type. |
**Return value**
| Type | Description |
| ------------------------------------- | ----------------------- |
| Promise\<[ImsRegInfo](#imsreginfo9)\> | Promise used to return the result.|
**Example**
```js
let promise = radio.getImsRegInfo(0, 1);
promise.then(data => {
console.log(`getImsRegInfo success, promise: data->${JSON.stringify(data)}`);
}).catch(err => {
console.log(`getImsRegInfo fail, promise: err->${JSON.stringify(err)}`);
});
```
## radio.on('imsRegStateChange')<sup>9+</sup>
on(type: 'imsRegStateChange', slotId: number, imsType: ImsServiceType, callback: Callback<ImsRegInfo\>): void
Enables listening for **imsRegStateChange** events. This API uses an asynchronous callback to return the result.
This is a system API.
**Required permission**: ohos.permission.GET_TELEPHONY_STATE
**System capability**: SystemCapability.Telephony.CoreService
**Parameters**
| Name | Type | Mandatory| Description |
| -------- | ------------------------------------ | ---- | -------------------------------------- |
| type | string | Yes | IMS registration status changes. |
| slotId | number | Yes | Card slot ID.<br>- **0**: card slot 1<br>- **1**: card slot 2|
| imsType | [ImsServiceType](#imsservicetype9) | Yes | IMS service type. |
| callback | Callback<[ImsRegInfo](#imsreginfo9)> | Yes | Callback used to return the result. |
**Example**
```js
radio.on('imsRegStateChange', 0, 1, (err, data) => {
console.log(`callback: err->${JSON.stringify(err)}, data->${JSON.stringify(data)}`);
});
```
## radio.off('imsRegStateChange')<sup>9+</sup>
off(type: 'imsRegStateChange', slotId: number, imsType: ImsServiceType, callback?: Callback<ImsRegInfo\>): void
Disables listening for **imsRegStateChange** events. This API uses an asynchronous callback to return the result.
This is a system API.
**Required permission**: ohos.permission.GET_TELEPHONY_STATE
**System capability**: SystemCapability.Telephony.CoreService
**Parameters**
| Name | Type | Mandatory| Description |
| -------- | ------------------------------------ | ---- | -------------------------------------- |
| type | string | Yes | IMS registration status changes. |
| slotId | number | Yes | Card slot ID.<br>- **0**: card slot 1<br>- **1**: card slot 2|
| imsType | [ImsServiceType](#imsservicetype9) | Yes | IMS service type. |
| callback | Callback<[ImsRegInfo](#imsreginfo9)> | No | Callback used to return the result. |
**Example**
```js
radio.off('imsRegStateChange', 0, 1, (err, data) => {
console.log(`callback: err->${JSON.stringify(err)}, data->${JSON.stringify(data)}`);
});
```
## RadioTechnology
Enumerates radio access technologies.
......@@ -1759,7 +1881,7 @@ This is a system API.
| isCamped | boolean | Status of the cell. |
| timeStamp | number | Timestamp when cell information is obtained. |
| signalInformation | [SignalInformation](#signalinformation) | Signal information. |
| data | [CdmaCellInformation](#cdmacellinformation) \| [GsmCellInformation](#gsmcellinformation) \| [LteCellInformation](#ltecellinformation) \| [NrCellInformation](#nrcellinformation) \| [TdscdmaCellInformation](#tdscdmacellinformation) | CDMA cell information \| GSM cell information \| LTE cell information \| NR cell information \| TD-SCDMA cell information |
| data | [CdmaCellInformation](#cdmacellinformation8) \| [GsmCellInformation](#gsmcellinformation8) \| [LteCellInformation](#ltecellinformation8) \| [NrCellInformation](#nrcellinformation8) \| [TdscdmaCellInformation](#tdscdmacellinformation8) | CDMA cell information \|GSM cell information \|LTE cell information \|NR cell information \|TD-SCDMA cell information|
## CdmaCellInformation<sup>8+</sup>
......@@ -1883,6 +2005,8 @@ This is a system API.
Defines the network search result.
This is a system API.
**System capability**: SystemCapability.Telephony.CoreService
| Name | Type | Description |
......@@ -1934,3 +2058,59 @@ This is a system API.
| selectMode | [NetworkSelectionMode](#networkselectionmode) | Network selection mode. |
| networkInformation | [NetworkInformation](#networkinformation) | Network information. |
| resumeSelection | boolean | Whether to resume selection. |
## ImsRegState<sup>9+</sup>
Enumerates IMS registration states.
This is a system API.
**System capability**: SystemCapability.Telephony.CoreService
| Name | Value | Description |
| ---------------- | ---- | -------- |
| IMS_UNREGISTERED | 0 | Not registered.|
| IMS_REGISTERED | 1 | Registered.|
## ImsRegTech<sup>9+</sup>
Enumerates IMS registration technologies.
This is a system API.
**System capability**: SystemCapability.Telephony.CoreService
| Name | Value | Description |
| ----------------------- | ---- | --------------- |
| REGISTRATION_TECH_NONE | 0 | None. |
| REGISTRATION_TECH_LTE | 1 | LTE. |
| REGISTRATION_TECH_IWLAN | 2 | I-WLAN.|
| REGISTRATION_TECH_NR | 3 | NR. |
## ImsRegInfo<sup>9+</sup>
Defines the IMS registration information.
This is a system API.
**System capability**: SystemCapability.Telephony.CoreService
| Name | Type | Description |
| ----------- | ---------------------------- | ------------- |
| imsRegState | [ImsRegState](#imsregstate9) | IMS registration state.|
| imsRegTech | [ImsRegTech](#imsregtech9) | IMS registration technology.|
## ImsServiceType<sup>9+</sup>
Enumerates IMS service types.
This is a system API.
**System capability**: SystemCapability.Telephony.CoreService
| Name | Value | Description |
| ---------- | ---- | ---------- |
| TYPE_VOICE | 0 | Voice service.|
| TYPE_VIDEO | 1 | Video service.|
| TYPE_UT | 2 | UT service. |
| TYPE_SMS | 3 | SMS service.|
......@@ -1482,7 +1482,7 @@ promise.then(data => {
## sim.**unlockPin**2<sup>8+</sup>
****unlockPin2****(slotId: number,pin2: string ,callback: AsyncCallback<LockStatusResponse\>): void
unlockPin2(slotId: number,pin2: string ,callback: AsyncCallback<LockStatusResponse\>): void
Unlocks PIN 2 of the SIM card in the specified slot. This API uses an asynchronous callback to return the result.
......@@ -1549,7 +1549,7 @@ promise.then(data => {
## sim.**unlockPuk**2<sup>8+</sup>
unlockPuk2(slotId: number,newPin2: string,puk2: string ,callback: AsyncCallback<LockStatusResponse\>): void
unlockPuk2(slotId: number, newPin2: string, puk2: string, callback: AsyncCallback<LockStatusResponse\>): void
Unlocks PUK 2 of the SIM card in the specified slot. This API uses an asynchronous callback to return the result.
......@@ -1581,7 +1581,7 @@ sim.unlockPuk2(0, newPin2, puk2, (err, data) => {
## sim.**unlockPuk2**<sup>8+</sup>
unlockPuk2slotId: number,newPin2: string,puk2: string): Promise&lt;LockStatusResponse\>
unlockPuk2(slotId: number, newPin2: string, puk2: string): Promise&lt;LockStatusResponse\>
Unlocks PUK 2 of the SIM card in the specified slot. This API uses a promise to return the result.
......@@ -2653,7 +2653,7 @@ promise.then(data => {
## sim.getOpKey<sup>9+</sup>
getOpKey(slotId: number, callback: AsyncCallback<number\>): void
getOpKey(slotId: number, callback: AsyncCallback<string\>): void
Obtains the opkey of the SIM card in the specified slot. This API uses an asynchronous callback to return the result.
......@@ -2666,7 +2666,7 @@ This is a system API.
| Name | Type | Mandatory| Description |
| -------- | ---------------------- | ---- | -------------------------------------- |
| slotId | number | Yes | Card slot ID.<br>- **0**: card slot 1<br>- **1**: card slot 2|
| callback | AsyncCallback<number\> | Yes | Callback used to return the result. |
| callback | AsyncCallback<string\> | Yes | Callback used to return the result. |
**Example**
......@@ -2679,7 +2679,7 @@ sim.getOpKey(0, (err, data) => {
## sim.getOpKey<sup>9+</sup>
getOpKey(slotId: number): Promise<number\>
getOpKey(slotId: number): Promise<string\>
Obtains the opkey of the SIM card in the specified slot. This API uses a promise to return the result.
......@@ -2697,7 +2697,7 @@ This is a system API.
| Type | Description |
| ---------------- | ----------------------------------------- |
| Promise<number\> | Promise used to return the result.|
| Promise<string\> | Promise used to return the result.|
**Example**
......
......@@ -678,7 +678,7 @@ This is a system API.
| Name | Type | Mandatory| Description |
| -------- | ----------------------------------------------------------- | ---- | ----------------------------------------- |
| slotId | number | Yes | SIM card slot ID. <br>- **0**: card slot 1<br>- **1**: card slot 2|
| callback | AsyncCallback<Array<[SimShortMessage](#simshortmessage8)\>> | Yes | Callback used to return the result. |
| callback | AsyncCallback<Array<[SimShortMessage](#simshortmessage7)\>> | Yes | Callback used to return the result. |
**Example**
......@@ -712,7 +712,7 @@ This is a system API.
| Type | Description |
| ------------------------------------------------------- | ---------------------------------- |
| PromiseArray<[SimShortMessage](#simshortmessage8)\>&gt; | Promise used to return the result.|
| PromiseArray<[SimShortMessage](#simshortmessage7)\>&gt; | Promise used to return the result.|
**Example**
......@@ -742,7 +742,7 @@ This is a system API.
| Name | Type | Mandatory| Description |
| -------- | ------------------------------------ | ---- | ------------ |
| options | [CBConfigOptions](#cbconfigoptions8) | Yes | Cell broadcast configuration options.|
| options | [CBConfigOptions](#cbconfigoptions7) | Yes | Cell broadcast configuration options.|
| callback | AsyncCallback&lt;void&gt; | Yes | Callback used to return the result. |
**Example**
......@@ -776,7 +776,7 @@ This is a system API.
| Name | Type | Mandatory| Description |
| ------- | ------------------------------------ | ---- | ------------ |
| options | [CBConfigOptions](#cbconfigoptions8) | Yes | Cell broadcast configuration options.|
| options | [CBConfigOptions](#cbconfigoptions7) | Yes | Cell broadcast configuration options.|
**Return value**
......@@ -818,7 +818,7 @@ This is a system API.
| slotId | number | Yes | SIM card slot ID. <br>- **0**: card slot 1<br>- **1**: card slot 2|
| message | string | Yes | SMS message. |
| force7bit | boolean | Yes | Whether to use 7-bit coding. |
| callback | AsyncCallback&lt;[SmsSegmentsInfo](#<smssegmentsinfo8)&gt; | Yes | Callback used to return the result. |
| callback | | Yes | Callback used to return the result. |
**Example**
......@@ -852,7 +852,7 @@ This is a system API.
| Type | Description |
| ------------------------------------------------------- | ----------------------------- |
| Promise&lt;[SmsSegmentsInfo](#<smssegmentsinfo8)&gt; | Promise used to return the result.|
| | Promise used to return the result.|
**Example**
......@@ -1331,6 +1331,25 @@ This is a system API.
| date | number | Yes | Date. |
| readStatus | number | Yes | Read status.|
## MmsReadRecInd<sup>8+</sup>
Defines the MMS message reading index.
This is a system API.
**System capability**: SystemCapability.Telephony.SmsMms
| Name | Type | Mandatory| Description |
| ---------- | ---------------------------------- | ---- | -------- |
| version | [MmsVersionType](#mmsversiontype8) | Yes | Version |
| messageId | string | Yes | Message ID. |
| to | Array<[MmsAddress](#mmsaddress8)\> | Yes | Destination. |
| from | [MmsAddress](#mmsaddress8) | Yes | Source. |
| readStatus | number | Yes | Read state.|
| date | number | No | Date. |
## MmsAttachment<sup>8+</sup>
Defines the attachment of an MMS message.
......@@ -1466,7 +1485,7 @@ This is a system API.
| MMS_YES | 128 | YES |
| MMS_NO | 129 | NO |
## CBConfigOptions<sup>8+</sup>
## CBConfigOptions<sup>7+</sup>
Defines the cell broadcast configuration options.
......@@ -1557,7 +1576,7 @@ This is a system API.
| pdu | string | Yes | Protocol data unit. |
| smsc | string | Yes | Short message service center.|
## SimShortMessage<sup>8+</sup>
## SimShortMessage<sup>7+</sup>
Defines a SIM message.
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册