提交 094c8381 编写于 作者: W wusongqing

update docs against 6587

Signed-off-by: Nwusongqing <wusongqing@huawei.com>
上级 84c47a10
...@@ -61,7 +61,7 @@ Obtains detailed information about a system error code. ...@@ -61,7 +61,7 @@ Obtains detailed information about a system error code.
**Example** **Example**
```js ```js
var errnum = 10; // 10 is the system error code. var errnum = 10; // 10 is a system error code.
var result = util.getErrorString(errnum); var result = util.getErrorString(errnum);
console.log("result = " + result); console.log("result = " + result);
``` ```
...@@ -104,14 +104,16 @@ Calls back an asynchronous function. In the callback, the first parameter indica ...@@ -104,14 +104,16 @@ Calls back an asynchronous function. In the callback, the first parameter indica
promiseWrapper(original: (err: Object, value: Object) =&gt; void): Object promiseWrapper(original: (err: Object, value: Object) =&gt; void): Object
> **Introduce**<br/> > **NOTE**
> Deprecated starting from API version 9, it is recommended to use [util.promisify9 +] (\utilpromisify9) instead. >
> This API is deprecated since API version 9. You are advised to use **[util.promisify9+](#utilpromisify9)** instead.
Processes an asynchronous function and returns a promise version. Processes an asynchronous function and returns a promise version.
**System capability**: SystemCapability.Utils.Lang **System capability**: SystemCapability.Utils.Lang
**Parameters** **Parameters**
| Name| Type| Mandatory| Description| | Name| Type| Mandatory| Description|
| -------- | -------- | -------- | -------- | | -------- | -------- | -------- | -------- |
| original | Function | Yes| Asynchronous function.| | original | Function | Yes| Asynchronous function.|
...@@ -136,7 +138,7 @@ Processes an asynchronous function and returns a promise version. ...@@ -136,7 +138,7 @@ Processes an asynchronous function and returns a promise version.
promisify(original: (err: Object, value: Object) =&gt; void): Function promisify(original: (err: Object, value: Object) =&gt; void): Function
Processes an asynchronous function and returns a promise function. Processes an asynchronous function and returns a promise.
**System capability**: SystemCapability.Utils.Lang **System capability**: SystemCapability.Utils.Lang
...@@ -148,7 +150,7 @@ Processes an asynchronous function and returns a promise function. ...@@ -148,7 +150,7 @@ Processes an asynchronous function and returns a promise function.
**Return value** **Return value**
| Type| Description| | Type| Description|
| -------- | -------- | | -------- | -------- |
| Function | Function in the error-first style (that is, **(err, value) =>...** is called as the last parameter) and the promise version.| | Function | Function in the error-first style (that is, **(err, value) =>...** is called as the last parameter) and the promise.|
**Example** **Example**
```js ```js
...@@ -165,7 +167,6 @@ Processes an asynchronous function and returns a promise function. ...@@ -165,7 +167,6 @@ Processes an asynchronous function and returns a promise function.
}) })
``` ```
## TextDecoder ## TextDecoder
### Attributes ### Attributes
...@@ -217,7 +218,7 @@ Decodes the input content. ...@@ -217,7 +218,7 @@ Decodes the input content.
**Parameters** **Parameters**
| Name| Type| Mandatory| Description| | Name| Type| Mandatory| Description|
| -------- | -------- | -------- | -------- | | -------- | -------- | -------- | -------- |
| input | Unit8Array | Yes| Uint8Array to decode.| | input | Uint8Array | Yes| Uint8Array to decode.|
| options | Object | No| Options related to decoding.| | options | Object | No| Options related to decoding.|
**Table 2** options **Table 2** options
...@@ -982,7 +983,6 @@ Performs subsequent operations after a value is removed. ...@@ -982,7 +983,6 @@ Performs subsequent operations after a value is removed.
**Example** **Example**
```js ```js
var arr = []; var arr = [];
var arr = [];
class ChildLruBuffer extends util.LruBuffer class ChildLruBuffer extends util.LruBuffer
{ {
constructor() constructor()
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册