提交 5b7d4f7c 编写于 作者: G Gloria

Update docs against 18393+17759

Signed-off-by: wusongqing<wusongqing@huawei.com>
上级 6d25ce1b
...@@ -39,7 +39,7 @@ For details about the error codes, see [workScheduler Error Codes](../errorcodes ...@@ -39,7 +39,7 @@ For details about the error codes, see [workScheduler Error Codes](../errorcodes
| 9700001 | Memory operation failed. | | 9700001 | Memory operation failed. |
| 9700002 | Parcel operation failed. | | 9700002 | Parcel operation failed. |
| 9700003 | System service operation failed. | | 9700003 | System service operation failed. |
| 9700004 | Checking workInfo failed. | | 9700004 | Check workInfo failed. |
| 9700005 | StartWork failed. | | 9700005 | StartWork failed. |
...@@ -80,7 +80,7 @@ Instructs the **WorkSchedulerService** to stop the specified task. ...@@ -80,7 +80,7 @@ Instructs the **WorkSchedulerService** to stop the specified task.
| Name | Type | Mandatory | Description | | Name | Type | Mandatory | Description |
| ---------- | --------------------- | ---- | ---------- | | ---------- | --------------------- | ---- | ---------- |
| work | [WorkInfo](#workinfo) | Yes | Task to stop. | | work | [WorkInfo](#workinfo) | Yes | Task to stop. |
| needCancel | boolean | Yes | Whether to cancel the task.| | needCancel | boolean | No | Whether to cancel the task. The default value is **false**.|
**Error codes** **Error codes**
...@@ -91,7 +91,7 @@ For details about the error codes, see [workScheduler Error Codes](../errorcodes ...@@ -91,7 +91,7 @@ For details about the error codes, see [workScheduler Error Codes](../errorcodes
| 9700001 | Memory operation failed. | | 9700001 | Memory operation failed. |
| 9700002 | Parcel operation failed. | | 9700002 | Parcel operation failed. |
| 9700003 | System service operation failed. | | 9700003 | System service operation failed. |
| 9700004 | Checking workInfo failed. | | 9700004 | Check workInfo failed. |
**Example** **Example**
...@@ -118,7 +118,7 @@ For details about the error codes, see [workScheduler Error Codes](../errorcodes ...@@ -118,7 +118,7 @@ For details about the error codes, see [workScheduler Error Codes](../errorcodes
} }
``` ```
## workScheduler.getWorkStatus:callback ## workScheduler.getWorkStatus
getWorkStatus(workId: number, callback : AsyncCallback\<WorkInfo>): void getWorkStatus(workId: number, callback : AsyncCallback\<WorkInfo>): void
Obtains the latest task status. This API uses an asynchronous callback to return the result. Obtains the latest task status. This API uses an asynchronous callback to return the result.
...@@ -141,7 +141,7 @@ For details about the error codes, see [workScheduler Error Codes](../errorcodes ...@@ -141,7 +141,7 @@ For details about the error codes, see [workScheduler Error Codes](../errorcodes
| 9700001 | Memory operation failed. | | 9700001 | Memory operation failed. |
| 9700002 | Parcel operation failed. | | 9700002 | Parcel operation failed. |
| 9700003 | System service operation failed. | | 9700003 | System service operation failed. |
| 9700004 | Checking workInfo failed. | | 9700004 | Check workInfo failed. |
**Example** **Example**
...@@ -161,7 +161,7 @@ For details about the error codes, see [workScheduler Error Codes](../errorcodes ...@@ -161,7 +161,7 @@ For details about the error codes, see [workScheduler Error Codes](../errorcodes
} }
``` ```
## workScheduler.getWorkStatus:promise ## workScheduler.getWorkStatus
getWorkStatus(workId: number): Promise\<WorkInfo> getWorkStatus(workId: number): Promise\<WorkInfo>
Obtains the latest task status. This API uses a promise to return the result. Obtains the latest task status. This API uses a promise to return the result.
...@@ -189,7 +189,7 @@ For details about the error codes, see [workScheduler Error Codes](../errorcodes ...@@ -189,7 +189,7 @@ For details about the error codes, see [workScheduler Error Codes](../errorcodes
| 9700001 | Memory operation failed. | | 9700001 | Memory operation failed. |
| 9700002 | Parcel operation failed. | | 9700002 | Parcel operation failed. |
| 9700003 | System service operation failed. | | 9700003 | System service operation failed. |
| 9700004 | Checking workInfo failed. | | 9700004 | Check workInfo failed. |
**Example** **Example**
...@@ -207,7 +207,7 @@ For details about the error codes, see [workScheduler Error Codes](../errorcodes ...@@ -207,7 +207,7 @@ For details about the error codes, see [workScheduler Error Codes](../errorcodes
} }
``` ```
## workScheduler.obtainAllWorks:callback ## workScheduler.obtainAllWorks
obtainAllWorks(callback : AsyncCallback\<void>): Array\<WorkInfo> obtainAllWorks(callback : AsyncCallback\<void>): Array\<WorkInfo>
Obtains all tasks associated with this application. This API uses an asynchronous callback to return the result. Obtains all tasks associated with this application. This API uses an asynchronous callback to return the result.
...@@ -252,8 +252,8 @@ For details about the error codes, see [workScheduler Error Codes](../errorcodes ...@@ -252,8 +252,8 @@ For details about the error codes, see [workScheduler Error Codes](../errorcodes
} }
``` ```
## workScheduler.obtainAllWorks:promise ## workScheduler.obtainAllWorks
obtainAllWorks(): Promise<Array\<WorkInfo>> obtainAllWorks(): Promise\<Array\<WorkInfo>>
Obtains all tasks associated with this application. This API uses a promise to return the result. Obtains all tasks associated with this application. This API uses a promise to return the result.
...@@ -317,7 +317,7 @@ For details about the error codes, see [workScheduler Error Codes](../errorcodes ...@@ -317,7 +317,7 @@ For details about the error codes, see [workScheduler Error Codes](../errorcodes
} }
``` ```
## workScheduler.isLastWorkTimeOut:callback ## workScheduler.isLastWorkTimeOut
isLastWorkTimeOut(workId: number, callback : AsyncCallback\<void>): boolean isLastWorkTimeOut(workId: number, callback : AsyncCallback\<void>): boolean
Checks whether the last execution of the specified task timed out. This API uses an asynchronous callback to return the result. Checks whether the last execution of the specified task timed out. This API uses an asynchronous callback to return the result.
...@@ -346,7 +346,7 @@ For details about the error codes, see [workScheduler Error Codes](../errorcodes ...@@ -346,7 +346,7 @@ For details about the error codes, see [workScheduler Error Codes](../errorcodes
| 9700001 | Memory operation failed. | | 9700001 | Memory operation failed. |
| 9700002 | Parcel operation failed. | | 9700002 | Parcel operation failed. |
| 9700003 | System service operation failed. | | 9700003 | System service operation failed. |
| 9700004 | Checking workInfo failed. | | 9700004 | Check workInfo failed. |
**Example** **Example**
...@@ -364,7 +364,7 @@ For details about the error codes, see [workScheduler Error Codes](../errorcodes ...@@ -364,7 +364,7 @@ For details about the error codes, see [workScheduler Error Codes](../errorcodes
} }
``` ```
## workScheduler.isLastWorkTimeOut:promise ## workScheduler.isLastWorkTimeOut
isLastWorkTimeOut(workId: number): Promise\<boolean> isLastWorkTimeOut(workId: number): Promise\<boolean>
Checks whether the last execution of the specified task timed out. This API uses a promise to return the result. Checks whether the last execution of the specified task timed out. This API uses a promise to return the result.
...@@ -392,7 +392,7 @@ For details about the error codes, see [workScheduler Error Codes](../errorcodes ...@@ -392,7 +392,7 @@ For details about the error codes, see [workScheduler Error Codes](../errorcodes
| 9700001 | Memory operation failed. | | 9700001 | Memory operation failed. |
| 9700002 | Parcel operation failed. | | 9700002 | Parcel operation failed. |
| 9700003 | System service operation failed. | | 9700003 | System service operation failed. |
| 9700004 | Checking workInfo failed. | | 9700004 | Check workInfo failed. |
**Example** **Example**
...@@ -432,7 +432,7 @@ Provides detailed information about the task. For details about the constraints ...@@ -432,7 +432,7 @@ Provides detailed information about the task. For details about the constraints
| isPersisted | boolean | No | Whether to enable persistent storage for the task. | | isPersisted | boolean | No | Whether to enable persistent storage for the task. |
| isDeepIdle | boolean | No | Whether the device needs to enter the idle state. | | isDeepIdle | boolean | No | Whether the device needs to enter the idle state. |
| idleWaitTime | number | No | Time to wait in the idle state. | | idleWaitTime | number | No | Time to wait in the idle state. |
| parameters | {[key: string]: number | string | boolean} | No | Carried parameters. | | parameters | {[key: string]: number \| string \| boolean} | No | Carried parameters. |
## NetworkType ## NetworkType
Enumerates the network types that can trigger the task. Enumerates the network types that can trigger the task.
......
...@@ -38,7 +38,7 @@ Try again later or restart the device. ...@@ -38,7 +38,7 @@ Try again later or restart the device.
**Error Message** **Error Message**
IPC failed. Inner transact failed.
**Possible Causes** **Possible Causes**
...@@ -67,7 +67,7 @@ Try again later or restart the device. ...@@ -67,7 +67,7 @@ Try again later or restart the device.
**Error Message** **Error Message**
Continuous task verification failed. Background task verification failed.
**Possible Causes** **Possible Causes**
...@@ -120,7 +120,7 @@ Task storage failed. ...@@ -120,7 +120,7 @@ Task storage failed.
**Error Message** **Error Message**
Caller information verification failed for a transient task. Caller information verification failed.
**Possible Causes** **Possible Causes**
...@@ -138,7 +138,7 @@ Caller information verification failed for a transient task. ...@@ -138,7 +138,7 @@ Caller information verification failed for a transient task.
**Error Message** **Error Message**
Transient task verification failed. Background task verification failed.
**Possible Causes** **Possible Causes**
...@@ -157,7 +157,7 @@ Transient task verification failed. ...@@ -157,7 +157,7 @@ Transient task verification failed.
**Error Message** **Error Message**
Caller information verification failed when applying for efficiency resources. Caller information verification failed.
**Possible Causes** **Possible Causes**
......
...@@ -53,7 +53,7 @@ Try again later or restart the device. ...@@ -53,7 +53,7 @@ Try again later or restart the device.
**Error Message** **Error Message**
Checking workInfo failed. Check workInfo failed.
**Possible Causes** **Possible Causes**
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册