summaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorSam Ruby <rubys@intertwingly.net>2018-07-12 13:48:11 -0400
committerVse Mozhet Byt <vsemozhetbyt@gmail.com>2018-07-15 23:57:35 +0300
commit40c85ff0634913f4c61e13cbb7cacb7e2c76120f (patch)
tree242febebcaa984898e65cdcd6bd61d6f6c1e4fed /doc
parent1009118d27b069411016df4ca6915aac3c36a41f (diff)
downloadandroid-node-v8-40c85ff0634913f4c61e13cbb7cacb7e2c76120f.tar.gz
android-node-v8-40c85ff0634913f4c61e13cbb7cacb7e2c76120f.tar.bz2
android-node-v8-40c85ff0634913f4c61e13cbb7cacb7e2c76120f.zip
doc: declare all parameter types
PR-URL: https://github.com/nodejs/node/pull/21782 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
Diffstat (limited to 'doc')
-rw-r--r--doc/api/console.md1
-rw-r--r--doc/api/crypto.md368
-rw-r--r--doc/api/dgram.md1
-rw-r--r--doc/api/dns.md114
-rw-r--r--doc/api/events.md36
-rw-r--r--doc/api/http.md4
-rw-r--r--doc/api/http2.md6
-rw-r--r--doc/api/https.md18
-rw-r--r--doc/api/net.md30
-rw-r--r--doc/api/process.md1
-rw-r--r--doc/api/stream.md2
-rw-r--r--doc/api/tty.md10
-rw-r--r--doc/api/util.md46
-rw-r--r--doc/api/v8.md4
-rw-r--r--doc/api/zlib.md76
15 files changed, 427 insertions, 290 deletions
diff --git a/doc/api/console.md b/doc/api/console.md
index 95801c31fe..2f1efe63ae 100644
--- a/doc/api/console.md
+++ b/doc/api/console.md
@@ -503,6 +503,7 @@ console.profileEnd('MyLabel');
<!-- YAML
added: v8.0.0
-->
+* `label` {string}
This method does not display anything unless used in the inspector. Stops the
current JavaScript CPU profiling session if one has been started and prints
diff --git a/doc/api/crypto.md b/doc/api/crypto.md
index 134964b436..37a2f41a10 100644
--- a/doc/api/crypto.md
+++ b/doc/api/crypto.md
@@ -55,8 +55,8 @@ data. The most common usage is handling output generated by the HTML5
<!-- YAML
added: v9.0.0
-->
-- `spkac` {string | Buffer | TypedArray | DataView}
-- Returns: {Buffer} The challenge component of the `spkac` data structure, which
+* `spkac` {string | Buffer | TypedArray | DataView}
+* Returns: {Buffer} The challenge component of the `spkac` data structure, which
includes a public key and a challenge.
```js
@@ -71,9 +71,9 @@ console.log(challenge.toString('utf8'));
<!-- YAML
added: v9.0.0
-->
-- `spkac` {string | Buffer | TypedArray | DataView}
-- `encoding` {string}
-- Returns: {Buffer} The public key component of the `spkac` data structure,
+* `spkac` {string | Buffer | TypedArray | DataView}
+* `encoding` {string}
+* Returns: {Buffer} The public key component of the `spkac` data structure,
which includes a public key and a challenge.
```js
@@ -88,8 +88,8 @@ console.log(publicKey);
<!-- YAML
added: v9.0.0
-->
-- `spkac` {Buffer | TypedArray | DataView}
-- Returns: {boolean} `true` if the given `spkac` data structure is valid,
+* `spkac` {Buffer | TypedArray | DataView}
+* Returns: {boolean} `true` if the given `spkac` data structure is valid,
`false` otherwise.
```js
@@ -121,8 +121,8 @@ const cert2 = crypto.Certificate();
<!-- YAML
added: v0.11.8
-->
-- `spkac` {string | Buffer | TypedArray | DataView}
-- Returns: {Buffer} The challenge component of the `spkac` data structure, which
+* `spkac` {string | Buffer | TypedArray | DataView}
+* Returns: {Buffer} The challenge component of the `spkac` data structure, which
includes a public key and a challenge.
```js
@@ -137,8 +137,8 @@ console.log(challenge.toString('utf8'));
<!-- YAML
added: v0.11.8
-->
-- `spkac` {string | Buffer | TypedArray | DataView}
-- Returns: {Buffer} The public key component of the `spkac` data structure,
+* `spkac` {string | Buffer | TypedArray | DataView}
+* Returns: {Buffer} The public key component of the `spkac` data structure,
which includes a public key and a challenge.
```js
@@ -153,8 +153,8 @@ console.log(publicKey);
<!-- YAML
added: v0.11.8
-->
-- `spkac` {Buffer | TypedArray | DataView}
-- Returns: {boolean} `true` if the given `spkac` data structure is valid,
+* `spkac` {Buffer | TypedArray | DataView}
+* Returns: {boolean} `true` if the given `spkac` data structure is valid,
`false` otherwise.
```js
@@ -231,8 +231,8 @@ console.log(encrypted);
<!-- YAML
added: v0.1.94
-->
-- `outputEncoding` {string}
-- Returns: {Buffer | string} Any remaining enciphered contents.
+* `outputEncoding` {string}
+* Returns: {Buffer | string} Any remaining enciphered contents.
If `outputEncoding` is one of `'latin1'`, `'base64'` or `'hex'`, a string is
returned. If an `outputEncoding` is not provided, a [`Buffer`][] is returned.
@@ -244,10 +244,10 @@ once will result in an error being thrown.
<!-- YAML
added: v1.0.0
-->
-- `buffer` {Buffer}
-- `options` {Object} [`stream.transform` options][]
+* `buffer` {Buffer}
+* `options` {Object} [`stream.transform` options][]
- `plaintextLength` {number}
-- Returns: {Cipher} for method chaining.
+* Returns: {Cipher} for method chaining.
When using an authenticated encryption mode (only `GCM` and `CCM` are currently
supported), the `cipher.setAAD()` method sets the value used for the
@@ -263,7 +263,7 @@ The `cipher.setAAD()` method must be called before [`cipher.update()`][].
<!-- YAML
added: v1.0.0
-->
-- Returns: {Buffer} When using an authenticated encryption mode (only `GCM` and
+* Returns: {Buffer} When using an authenticated encryption mode (only `GCM` and
`CCM` are currently supported), the `cipher.getAuthTag()` method returns a
[`Buffer`][] containing the _authentication tag_ that has been computed from
the given data.
@@ -275,8 +275,8 @@ been completed using the [`cipher.final()`][] method.
<!-- YAML
added: v0.7.1
-->
-- `autoPadding` {boolean} **Default:** `true`
-- Returns: {Cipher} for method chaining.
+* `autoPadding` {boolean} **Default:** `true`
+* Returns: {Cipher} for method chaining.
When using block encryption algorithms, the `Cipher` class will automatically
add padding to the input data to the appropriate block size. To disable the
@@ -298,10 +298,10 @@ changes:
pr-url: https://github.com/nodejs/node/pull/5522
description: The default `inputEncoding` changed from `binary` to `utf8`.
-->
-- `data` {string | Buffer | TypedArray | DataView}
-- `inputEncoding` {string}
-- `outputEncoding` {string}
-- Returns: {Buffer | string}
+* `data` {string | Buffer | TypedArray | DataView}
+* `inputEncoding` {string}
+* `outputEncoding` {string}
+* Returns: {Buffer | string}
Updates the cipher with `data`. If the `inputEncoding` argument is given,
its value must be one of `'utf8'`, `'ascii'`, or `'latin1'` and the `data`
@@ -390,8 +390,8 @@ console.log(decrypted);
<!-- YAML
added: v0.1.94
-->
-- `outputEncoding` {string}
-- Returns: {Buffer | string} Any remaining deciphered contents.
+* `outputEncoding` {string}
+* Returns: {Buffer | string} Any remaining deciphered contents.
If `outputEncoding` is one of `'latin1'`, `'ascii'` or `'utf8'`, a string is
returned. If an `outputEncoding` is not provided, a [`Buffer`][] is returned.
@@ -407,10 +407,10 @@ changes:
pr-url: https://github.com/nodejs/node/pull/9398
description: This method now returns a reference to `decipher`.
-->
-- `buffer` {Buffer | TypedArray | DataView}
-- `options` {Object} [`stream.transform` options][]
+* `buffer` {Buffer | TypedArray | DataView}
+* `options` {Object} [`stream.transform` options][]
- `plaintextLength` {number}
-- Returns: {Decipher} for method chaining.
+* Returns: {Decipher} for method chaining.
When using an authenticated encryption mode (only `GCM` and `CCM` are currently
supported), the `decipher.setAAD()` method sets the value used for the
@@ -433,8 +433,8 @@ changes:
pr-url: https://github.com/nodejs/node/pull/9398
description: This method now returns a reference to `decipher`.
-->
-- `buffer` {Buffer | TypedArray | DataView}
-- Returns: {Decipher} for method chaining.
+* `buffer` {Buffer | TypedArray | DataView}
+* Returns: {Decipher} for method chaining.
When using an authenticated encryption mode (only `GCM` and `CCM` are currently
supported), the `decipher.setAuthTag()` method is used to pass in the
@@ -451,8 +451,8 @@ The `decipher.setAuthTag()` method must be called before
<!-- YAML
added: v0.7.1
-->
-- `autoPadding` {boolean} **Default:** `true`
-- Returns: {Decipher} for method chaining.
+* `autoPadding` {boolean} **Default:** `true`
+* Returns: {Decipher} for method chaining.
When data has been encrypted without standard block padding, calling
`decipher.setAutoPadding(false)` will disable automatic padding to prevent
@@ -472,10 +472,10 @@ changes:
pr-url: https://github.com/nodejs/node/pull/5522
description: The default `inputEncoding` changed from `binary` to `utf8`.
-->
-- `data` {string | Buffer | TypedArray | DataView}
-- `inputEncoding` {string}
-- `outputEncoding` {string}
-- Returns: {Buffer | string}
+* `data` {string | Buffer | TypedArray | DataView}
+* `inputEncoding` {string}
+* `outputEncoding` {string}
+* Returns: {Buffer | string}
Updates the decipher with `data`. If the `inputEncoding` argument is given,
its value must be one of `'latin1'`, `'base64'`, or `'hex'` and the `data`
@@ -527,10 +527,10 @@ assert.strictEqual(aliceSecret.toString('hex'), bobSecret.toString('hex'));
<!-- YAML
added: v0.5.0
-->
-- `otherPublicKey` {string | Buffer | TypedArray | DataView}
-- `inputEncoding` {string}
-- `outputEncoding` {string}
-- Returns: {Buffer | string}
+* `otherPublicKey` {string | Buffer | TypedArray | DataView}
+* `inputEncoding` {string}
+* `outputEncoding` {string}
+* Returns: {Buffer | string}
Computes the shared secret using `otherPublicKey` as the other
party's public key and returns the computed shared secret. The supplied
@@ -547,8 +547,8 @@ If `outputEncoding` is given a string is returned; otherwise, a
<!-- YAML
added: v0.5.0
-->
-- `encoding` {string}
-- Returns: {Buffer | string}
+* `encoding` {string}
+* Returns: {Buffer | string}
Generates private and public Diffie-Hellman key values, and returns
the public key in the specified `encoding`. This key should be
@@ -560,8 +560,8 @@ or `'base64'`. If `encoding` is provided a string is returned; otherwise a
<!-- YAML
added: v0.5.0
-->
-- `encoding` {string}
-- Returns: {Buffer | string}
+* `encoding` {string}
+* Returns: {Buffer | string}
Returns the Diffie-Hellman generator in the specified `encoding`, which can
be `'latin1'`, `'hex'`, or `'base64'`. If `encoding` is provided a string is
@@ -571,8 +571,8 @@ returned; otherwise a [`Buffer`][] is returned.
<!-- YAML
added: v0.5.0
-->
-- `encoding` {string}
-- Returns: {Buffer | string}
+* `encoding` {string}
+* Returns: {Buffer | string}
Returns the Diffie-Hellman prime in the specified `encoding`, which can
be `'latin1'`, `'hex'`, or `'base64'`. If `encoding` is provided a string is
@@ -582,8 +582,8 @@ returned; otherwise a [`Buffer`][] is returned.
<!-- YAML
added: v0.5.0
-->
-- `encoding` {string}
-- Returns: {Buffer | string}
+* `encoding` {string}
+* Returns: {Buffer | string}
Returns the Diffie-Hellman private key in the specified `encoding`,
which can be `'latin1'`, `'hex'`, or `'base64'`. If `encoding` is provided a
@@ -593,8 +593,8 @@ string is returned; otherwise a [`Buffer`][] is returned.
<!-- YAML
added: v0.5.0
-->
-- `encoding` {string}
-- Returns: {Buffer | string}
+* `encoding` {string}
+* Returns: {Buffer | string}
Returns the Diffie-Hellman public key in the specified `encoding`, which
can be `'latin1'`, `'hex'`, or `'base64'`. If `encoding` is provided a
@@ -604,8 +604,8 @@ string is returned; otherwise a [`Buffer`][] is returned.
<!-- YAML
added: v0.5.0
-->
-- `privateKey` {string | Buffer | TypedArray | DataView}
-- `encoding` {string}
+* `privateKey` {string | Buffer | TypedArray | DataView}
+* `encoding` {string}
Sets the Diffie-Hellman private key. If the `encoding` argument is provided
and is either `'latin1'`, `'hex'`, or `'base64'`, `privateKey` is expected
@@ -616,8 +616,8 @@ to be a [`Buffer`][], `TypedArray`, or `DataView`.
<!-- YAML
added: v0.5.0
-->
-- `publicKey` {string | Buffer | TypedArray | DataView}
-- `encoding` {string}
+* `publicKey` {string | Buffer | TypedArray | DataView}
+* `encoding` {string}
Sets the Diffie-Hellman public key. If the `encoding` argument is provided
and is either `'latin1'`, `'hex'` or `'base64'`, `publicKey` is expected
@@ -676,12 +676,12 @@ assert.strictEqual(aliceSecret.toString('hex'), bobSecret.toString('hex'));
added: v10.0.0
-->
-- `key` {string | Buffer | TypedArray | DataView}
-- `curve` {string}
-- `inputEncoding` {string}
-- `outputEncoding` {string}
-- `format` {string} **Default:** `'uncompressed'`
-- Returns: {Buffer | string}
+* `key` {string | Buffer | TypedArray | DataView}
+* `curve` {string}
+* `inputEncoding` {string}
+* `outputEncoding` {string}
+* `format` {string} **Default:** `'uncompressed'`
+* Returns: {Buffer | string}
Converts the EC Diffie-Hellman public key specified by `key` and `curve` to the
format specified by `format`. The `format` argument specifies point encoding
@@ -732,10 +732,10 @@ changes:
description: Changed error format to better support invalid public key
error
-->
-- `otherPublicKey` {string | Buffer | TypedArray | DataView}
-- `inputEncoding` {string}
-- `outputEncoding` {string}
-- Returns: {Buffer | string}
+* `otherPublicKey` {string | Buffer | TypedArray | DataView}
+* `inputEncoding` {string}
+* `outputEncoding` {string}
+* Returns: {Buffer | string}
Computes the shared secret using `otherPublicKey` as the other
party's public key and returns the computed shared secret. The supplied
@@ -758,9 +758,9 @@ its recommended for developers to handle this exception accordingly.
<!-- YAML
added: v0.11.14
-->
-- `encoding` {string}
-- `format` {string} **Default:** `'uncompressed'`
-- Returns: {Buffer | string}
+* `encoding` {string}
+* `format` {string} **Default:** `'uncompressed'`
+* Returns: {Buffer | string}
Generates private and public EC Diffie-Hellman key values, and returns
the public key in the specified `format` and `encoding`. This key should be
@@ -778,8 +778,8 @@ is returned.
<!-- YAML
added: v0.11.14
-->
-- `encoding` {string}
-- Returns: {Buffer | string} The EC Diffie-Hellman private key in the specified
+* `encoding` {string}
+* Returns: {Buffer | string} The EC Diffie-Hellman private key in the specified
`encoding`, which can be `'latin1'`, `'hex'`, or `'base64'`. If `encoding`
is provided a string is returned; otherwise a [`Buffer`][] is returned.
@@ -787,9 +787,9 @@ added: v0.11.14
<!-- YAML
added: v0.11.14
-->
-- `encoding` {string}
-- `format` {string} **Default:** `'uncompressed'`
-- Returns: {Buffer | string} The EC Diffie-Hellman public key in the specified
+* `encoding` {string}
+* `format` {string} **Default:** `'uncompressed'`
+* Returns: {Buffer | string} The EC Diffie-Hellman public key in the specified
`encoding` and `format`.
The `format` argument specifies point encoding and can be `'compressed'` or
@@ -804,8 +804,8 @@ returned.
<!-- YAML
added: v0.11.14
-->
-- `privateKey` {string | Buffer | TypedArray | DataView}
-- `encoding` {string}
+* `privateKey` {string | Buffer | TypedArray | DataView}
+* `encoding` {string}
Sets the EC Diffie-Hellman private key. The `encoding` can be `'latin1'`,
`'hex'` or `'base64'`. If `encoding` is provided, `privateKey` is expected
@@ -824,8 +824,8 @@ deprecated: v5.2.0
> Stability: 0 - Deprecated
-- `publicKey` {string | Buffer | TypedArray | DataView}
-- `encoding` {string}
+* `publicKey` {string | Buffer | TypedArray | DataView}
+* `encoding` {string}
Sets the EC Diffie-Hellman public key. Key encoding can be `'latin1'`,
`'hex'` or `'base64'`. If `encoding` is provided `publicKey` is expected to
@@ -925,8 +925,8 @@ console.log(hash.digest('hex'));
<!-- YAML
added: v0.1.92
-->
-- `encoding` {string}
-- Returns: {Buffer | string}
+* `encoding` {string}
+* Returns: {Buffer | string}
Calculates the digest of all of the data passed to be hashed (using the
[`hash.update()`][] method). The `encoding` can be `'hex'`, `'latin1'` or
@@ -944,8 +944,8 @@ changes:
pr-url: https://github.com/nodejs/node/pull/5522
description: The default `inputEncoding` changed from `binary` to `utf8`.
-->
-- `data` {string | Buffer | TypedArray | DataView}
-- `inputEncoding` {string}
+* `data` {string | Buffer | TypedArray | DataView}
+* `inputEncoding` {string}
Updates the hash content with the given `data`, the encoding of which
is given in `inputEncoding` and can be `'utf8'`, `'ascii'` or
@@ -1017,8 +1017,8 @@ console.log(hmac.digest('hex'));
<!-- YAML
added: v0.1.94
-->
-- `encoding` {string}
-- Returns: {Buffer | string}
+* `encoding` {string}
+* Returns: {Buffer | string}
Calculates the HMAC digest of all of the data passed using [`hmac.update()`][].
The `encoding` can be `'hex'`, `'latin1'` or `'base64'`. If `encoding` is
@@ -1035,8 +1035,8 @@ changes:
pr-url: https://github.com/nodejs/node/pull/5522
description: The default `inputEncoding` changed from `binary` to `utf8`.
-->
-- `data` {string | Buffer | TypedArray | DataView}
-- `inputEncoding` {string}
+* `data` {string | Buffer | TypedArray | DataView}
+* `inputEncoding` {string}
Updates the `Hmac` content with the given `data`, the encoding of which
is given in `inputEncoding` and can be `'utf8'`, `'ascii'` or
@@ -1118,11 +1118,11 @@ changes:
pr-url: https://github.com/nodejs/node/pull/11705
description: Support for RSASSA-PSS and additional options was added.
-->
-- `privateKey` {string | Object}
+* `privateKey` {string | Object}
- `key` {string}
- `passphrase` {string}
-- `outputFormat` {string}
-- Returns: {Buffer | string}
+* `outputFormat` {string}
+* Returns: {Buffer | string}
Calculates the signature on all the data passed through using either
[`sign.update()`][] or [`sign.write()`][stream-writable-write].
@@ -1160,8 +1160,8 @@ changes:
pr-url: https://github.com/nodejs/node/pull/5522
description: The default `inputEncoding` changed from `binary` to `utf8`.
-->
-- `data` {string | Buffer | TypedArray | DataView}
-- `inputEncoding` {string}
+* `data` {string | Buffer | TypedArray | DataView}
+* `inputEncoding` {string}
Updates the `Sign` content with the given `data`, the encoding of which
is given in `inputEncoding` and can be `'utf8'`, `'ascii'` or
@@ -1224,8 +1224,8 @@ changes:
pr-url: https://github.com/nodejs/node/pull/5522
description: The default `inputEncoding` changed from `binary` to `utf8`.
-->
-- `data` {string | Buffer | TypedArray | DataView}
-- `inputEncoding` {string}
+* `data` {string | Buffer | TypedArray | DataView}
+* `inputEncoding` {string}
Updates the `Verify` content with the given `data`, the encoding of which
is given in `inputEncoding` and can be `'utf8'`, `'ascii'` or
@@ -1243,10 +1243,10 @@ changes:
pr-url: https://github.com/nodejs/node/pull/11705
description: Support for RSASSA-PSS and additional options was added.
-->
-- `object` {string | Object}
-- `signature` {string | Buffer | TypedArray | DataView}
-- `signatureFormat` {string}
-- Returns: {boolean} `true` or `false` depending on the validity of the
+* `object` {string | Object}
+* `signature` {string | Buffer | TypedArray | DataView}
+* `signatureFormat` {string}
+* Returns: {boolean} `true` or `false` depending on the validity of the
signature for the data and public key.
Verifies the provided data using the given `object` and `signature`.
@@ -1283,7 +1283,7 @@ thrown.
<!-- YAML
added: v6.3.0
-->
-- Returns: {Object} An object containing commonly used constants for crypto and
+* Returns: {Object} An object containing commonly used constants for crypto and
security related operations. The specific constants currently defined are
described in [Crypto Constants][].
@@ -1329,10 +1329,10 @@ changes:
> Stability: 0 - Deprecated: Use [`crypto.createCipheriv()`][] instead.
-- `algorithm` {string}
-- `password` {string | Buffer | TypedArray | DataView}
-- `options` {Object} [`stream.transform` options][]
-- Returns: {Cipher}
+* `algorithm` {string}
+* `password` {string | Buffer | TypedArray | DataView}
+* `options` {Object} [`stream.transform` options][]
+* Returns: {Cipher}
Creates and returns a `Cipher` object that uses the given `algorithm` and
`password`.
@@ -1382,11 +1382,11 @@ changes:
description: The `iv` parameter may now be `null` for ciphers which do not
need an initialization vector.
-->
-- `algorithm` {string}
-- `key` {string | Buffer | TypedArray | DataView}
-- `iv` {string | Buffer | TypedArray | DataView}
-- `options` {Object} [`stream.transform` options][]
-- Returns: {Cipher}
+* `algorithm` {string}
+* `key` {string | Buffer | TypedArray | DataView}
+* `iv` {string | Buffer | TypedArray | DataView}
+* `options` {Object} [`stream.transform` options][]
+* Returns: {Cipher}
Creates and returns a `Cipher` object, with the given `algorithm`, `key` and
initialization vector (`iv`).
@@ -1423,10 +1423,10 @@ deprecated: v10.0.0
> Stability: 0 - Deprecated: Use [`crypto.createDecipheriv()`][] instead.
-- `algorithm` {string}
-- `password` {string | Buffer | TypedArray | DataView}
-- `options` {Object} [`stream.transform` options][]
-- Returns: {Decipher}
+* `algorithm` {string}
+* `password` {string | Buffer | TypedArray | DataView}
+* `options` {Object} [`stream.transform` options][]
+* Returns: {Decipher}
Creates and returns a `Decipher` object that uses the given `algorithm` and
`password` (key).
@@ -1461,11 +1461,11 @@ changes:
description: The `iv` parameter may now be `null` for ciphers which do not
need an initialization vector.
-->
-- `algorithm` {string}
-- `key` {string | Buffer | TypedArray | DataView}
-- `iv` {string | Buffer | TypedArray | DataView}
-- `options` {Object} [`stream.transform` options][]
-- Returns: {Decipher}
+* `algorithm` {string}
+* `key` {string | Buffer | TypedArray | DataView}
+* `iv` {string | Buffer | TypedArray | DataView}
+* `options` {Object} [`stream.transform` options][]
+* Returns: {Decipher}
Creates and returns a `Decipher` object that uses the given `algorithm`, `key`
and initialization vector (`iv`).
@@ -1509,11 +1509,11 @@ changes:
description: The default for the encoding parameters changed
from `binary` to `utf8`.
-->
-- `prime` {string | Buffer | TypedArray | DataView}
-- `primeEncoding` {string}
-- `generator` {number | string | Buffer | TypedArray | DataView} **Default:**
+* `prime` {string | Buffer | TypedArray | DataView}
+* `primeEncoding` {string}
+* `generator` {number | string | Buffer | TypedArray | DataView} **Default:**
`2`
-- `generatorEncoding` {string}
+* `generatorEncoding` {string}
Creates a `DiffieHellman` key exchange object using the supplied `prime` and an
optional specific `generator`.
@@ -1534,8 +1534,8 @@ otherwise a number, [`Buffer`][], `TypedArray`, or `DataView` is expected.
<!-- YAML
added: v0.5.0
-->
-- `primeLength` {number}
-- `generator` {number | string | Buffer | TypedArray | DataView} **Default:**
+* `primeLength` {number}
+* `generator` {number | string | Buffer | TypedArray | DataView} **Default:**
`2`
Creates a `DiffieHellman` key exchange object and generates a prime of
@@ -1546,7 +1546,7 @@ If `generator` is not specified, the value `2` is used.
<!-- YAML
added: v0.11.14
-->
-- `curveName` {string}
+* `curveName` {string}
Creates an Elliptic Curve Diffie-Hellman (`ECDH`) key exchange object using a
predefined curve specified by the `curveName` string. Use
@@ -1558,9 +1558,9 @@ and description of each available elliptic curve.
<!-- YAML
added: v0.1.92
-->
-- `algorithm` {string}
-- `options` {Object} [`stream.transform` options][]
-- Returns: {Hash}
+* `algorithm` {string}
+* `options` {Object} [`stream.transform` options][]
+* Returns: {Hash}
Creates and returns a `Hash` object that can be used to generate hash digests
using the given `algorithm`. Optional `options` argument controls stream
@@ -1596,10 +1596,10 @@ input.on('readable', () => {
<!-- YAML
added: v0.1.94
-->
-- `algorithm` {string}
-- `key` {string | Buffer | TypedArray | DataView}
-- `options` {Object} [`stream.transform` options][]
-- Returns: {Hmac}
+* `algorithm` {string}
+* `key` {string | Buffer | TypedArray | DataView}
+* `options` {Object} [`stream.transform` options][]
+* Returns: {Hmac}
Creates and returns an `Hmac` object that uses the given `algorithm` and `key`.
Optional `options` argument controls stream behavior.
@@ -1636,9 +1636,9 @@ input.on('readable', () => {
<!-- YAML
added: v0.1.92
-->
-- `algorithm` {string}
-- `options` {Object} [`stream.Writable` options][]
-- Returns: {Sign}
+* `algorithm` {string}
+* `options` {Object} [`stream.Writable` options][]
+* Returns: {Sign}
Creates and returns a `Sign` object that uses the given `algorithm`.
Use [`crypto.getHashes()`][] to obtain an array of names of the available
@@ -1649,9 +1649,9 @@ signing algorithms. Optional `options` argument controls the
<!-- YAML
added: v0.1.92
-->
-- `algorithm` {string}
-- `options` {Object} [`stream.Writable` options][]
-- Returns: {Verify}
+* `algorithm` {string}
+* `options` {Object} [`stream.Writable` options][]
+* Returns: {Verify}
Creates and returns a `Verify` object that uses the given algorithm.
Use [`crypto.getHashes()`][] to obtain an array of names of the available
@@ -1662,7 +1662,7 @@ signing algorithms. Optional `options` argument controls the
<!-- YAML
added: v0.9.3
-->
-- Returns: {string[]} An array with the names of the supported cipher
+* Returns: {string[]} An array with the names of the supported cipher
algorithms.
Example:
@@ -1676,7 +1676,7 @@ console.log(ciphers); // ['aes-128-cbc', 'aes-128-ccm', ...]
<!-- YAML
added: v2.3.0
-->
-- Returns: {string[]} An array with the names of the supported elliptic curves.
+* Returns: {string[]} An array with the names of the supported elliptic curves.
Example:
@@ -1689,8 +1689,8 @@ console.log(curves); // ['Oakley-EC2N-3', 'Oakley-EC2N-4', ...]
<!-- YAML
added: v0.7.5
-->
-- `groupName` {string}
-- Returns: {Object}
+* `groupName` {string}
+* Returns: {Object}
Creates a predefined `DiffieHellman` key exchange object. The
supported groups are: `'modp1'`, `'modp2'`, `'modp5'` (defined in
@@ -1724,14 +1724,14 @@ console.log(aliceSecret === bobSecret);
<!-- YAML
added: v10.0.0
-->
-- Returns: {boolean} `true` if and only if a FIPS compliant crypto provider is
+* Returns: {boolean} `true` if and only if a FIPS compliant crypto provider is
currently in use.
### crypto.getHashes()
<!-- YAML
added: v0.9.3
-->
-- Returns: {string[]} An array of the names of the supported hash algorithms,
+* Returns: {string[]} An array of the names of the supported hash algorithms,
such as `'RSA-SHA256'`.
Example:
@@ -1757,12 +1757,12 @@ changes:
description: The default encoding for `password` if it is a string changed
from `binary` to `utf8`.
-->
-- `password` {string|Buffer|TypedArray|DataView}
-- `salt` {string|Buffer|TypedArray|DataView}
-- `iterations` {number}
-- `keylen` {number}
-- `digest` {string}
-- `callback` {Function}
+* `password` {string|Buffer|TypedArray|DataView}
+* `salt` {string|Buffer|TypedArray|DataView}
+* `iterations` {number}
+* `keylen` {number}
+* `digest` {string}
+* `callback` {Function}
- `err` {Error}
- `derivedKey` {Buffer}
@@ -1827,12 +1827,12 @@ changes:
description: The default encoding for `password` if it is a string changed
from `binary` to `utf8`.
-->
-- `password` {string|Buffer|TypedArray|DataView}
-- `salt` {string|Buffer|TypedArray|DataView}
-- `iterations` {number}
-- `keylen` {number}
-- `digest` {string}
-- Returns: {Buffer}
+* `password` {string|Buffer|TypedArray|DataView}
+* `salt` {string|Buffer|TypedArray|DataView}
+* `iterations` {number}
+* `keylen` {number}
+* `digest` {string}
+* Returns: {Buffer}
Provides a synchronous Password-Based Key Derivation Function 2 (PBKDF2)
implementation. A selected HMAC digest algorithm specified by `digest` is
@@ -1875,15 +1875,15 @@ An array of supported digest functions can be retrieved using
<!-- YAML
added: v0.11.14
-->
-- `privateKey` {Object | string}
+* `privateKey` {Object | string}
- `key` {string} A PEM encoded private key.
- `passphrase` {string} An optional passphrase for the private key.
- `padding` {crypto.constants} An optional padding value defined in
`crypto.constants`, which may be: `crypto.constants.RSA_NO_PADDING`,
`crypto.constants.RSA_PKCS1_PADDING`, or
`crypto.constants.RSA_PKCS1_OAEP_PADDING`.
-- `buffer` {Buffer | TypedArray | DataView}
-- Returns: {Buffer} A new `Buffer` with the decrypted content.
+* `buffer` {Buffer | TypedArray | DataView}
+* Returns: {Buffer} A new `Buffer` with the decrypted content.
Decrypts `buffer` with `privateKey`.
@@ -1894,14 +1894,14 @@ treated as the key with no passphrase and will use `RSA_PKCS1_OAEP_PADDING`.
<!-- YAML
added: v1.1.0
-->
-- `privateKey` {Object | string}
+* `privateKey` {Object | string}
- `key` {string} A PEM encoded private key.
- `passphrase` {string} An optional passphrase for the private key.
- `padding` {crypto.constants} An optional padding value defined in
`crypto.constants`, which may be: `crypto.constants.RSA_NO_PADDING` or
`crypto.constants.RSA_PKCS1_PADDING`.
-- `buffer` {Buffer | TypedArray | DataView}
-- Returns: {Buffer} A new `Buffer` with the encrypted content.
+* `buffer` {Buffer | TypedArray | DataView}
+* Returns: {Buffer} A new `Buffer` with the encrypted content.
Encrypts `buffer` with `privateKey`.
@@ -1912,14 +1912,14 @@ treated as the key with no passphrase and will use `RSA_PKCS1_PADDING`.
<!-- YAML
added: v1.1.0
-->
-- `key` {Object | string}
+* `key` {Object | string}
- `key` {string} A PEM encoded public or private key.
- `passphrase` {string} An optional passphrase for the private key.
- `padding` {crypto.constants} An optional padding value defined in
`crypto.constants`, which may be: `crypto.constants.RSA_NO_PADDING` or
`crypto.constants.RSA_PKCS1_PADDING`.
-- `buffer` {Buffer | TypedArray | DataView}
-- Returns: {Buffer} A new `Buffer` with the decrypted content.
+* `buffer` {Buffer | TypedArray | DataView}
+* Returns: {Buffer} A new `Buffer` with the decrypted content.
Decrypts `buffer` with `key`.
@@ -1933,15 +1933,15 @@ be passed instead of a public key.
<!-- YAML
added: v0.11.14
-->
-- `key` {Object | string}
+* `key` {Object | string}
- `key` {string} A PEM encoded public or private key.
- `passphrase` {string} An optional passphrase for the private key.
- `padding` {crypto.constants} An optional padding value defined in
`crypto.constants`, which may be: `crypto.constants.RSA_NO_PADDING`,
`crypto.constants.RSA_PKCS1_PADDING`, or
`crypto.constants.RSA_PKCS1_OAEP_PADDING`.
-- `buffer` {Buffer | TypedArray | DataView}
-- Returns: {Buffer} A new `Buffer` with the encrypted content.
+* `buffer` {Buffer | TypedArray | DataView}
+* Returns: {Buffer} A new `Buffer` with the encrypted content.
Encrypts the content of `buffer` with `key` and returns a new
[`Buffer`][] with encrypted content.
@@ -1961,11 +1961,11 @@ changes:
description: Passing `null` as the `callback` argument now throws
`ERR_INVALID_CALLBACK`.
-->
-- `size` {number}
-- `callback` {Function}
+* `size` {number}
+* `callback` {Function}
- `err` {Error}
- `buf` {Buffer}
-- Returns: {Buffer} if the `callback` function is not provided.
+* Returns: {Buffer} if the `callback` function is not provided.
Generates cryptographically strong pseudo-random data. The `size` argument
is a number indicating the number of bytes to generate.
@@ -2125,17 +2125,17 @@ request.
<!-- YAML
added: v10.5.0
-->
-- `password` {string|Buffer|TypedArray|DataView}
-- `salt` {string|Buffer|TypedArray|DataView}
-- `keylen` {number}
-- `options` {Object}
+* `password` {string|Buffer|TypedArray|DataView}
+* `salt` {string|Buffer|TypedArray|DataView}
+* `keylen` {number}
+* `options` {Object}
- `N` {number} CPU/memory cost parameter. Must be a power of two greater
than one. **Default:** `16384`.
- `r` {number} Block size parameter. **Default:** `8`.
- `p` {number} Parallelization parameter. **Default:** `1`.
- `maxmem` {number} Memory upper bound. It is an error when (approximately)
`128 * N * r > maxmem`. **Default:** `32 * 1024 * 1024`.
-- `callback` {Function}
+* `callback` {Function}
- `err` {Error}
- `derivedKey` {Buffer}
@@ -2171,17 +2171,17 @@ crypto.scrypt('secret', 'salt', 64, { N: 1024 }, (err, derivedKey) => {
<!-- YAML
added: v10.5.0
-->
-- `password` {string|Buffer|TypedArray|DataView}
-- `salt` {string|Buffer|TypedArray|DataView}
-- `keylen` {number}
-- `options` {Object}
+* `password` {string|Buffer|TypedArray|DataView}
+* `salt` {string|Buffer|TypedArray|DataView}
+* `keylen` {number}
+* `options` {Object}
- `N` {number} CPU/memory cost parameter. Must be a power of two greater
than one. **Default:** `16384`.
- `r` {number} Block size parameter. **Default:** `8`.
- `p` {number} Parallelization parameter. **Default:** `1`.
- `maxmem` {number} Memory upper bound. It is an error when (approximately)
`128 * N * r > maxmem`. **Default:** `32 * 1024 * 1024`.
-- Returns: {Buffer}
+* Returns: {Buffer}
Provides a synchronous [scrypt][] implementation. Scrypt is a password-based
key derivation function that is designed to be expensive computationally and
@@ -2210,8 +2210,8 @@ console.log(key2.toString('hex')); // '3745e48...aa39b34'
<!-- YAML
added: v0.11.11
-->
-- `engine` {string}
-- `flags` {crypto.constants} **Default:** `crypto.constants.ENGINE_METHOD_ALL`
+* `engine` {string}
+* `flags` {crypto.constants} **Default:** `crypto.constants.ENGINE_METHOD_ALL`
Load and set the `engine` for some or all OpenSSL functions (selected by flags).
@@ -2252,9 +2252,9 @@ Throws an error if FIPS mode is not available.
<!-- YAML
added: v6.6.0
-->
-- `a` {Buffer | TypedArray | DataView}
-- `b` {Buffer | TypedArray | DataView}
-- Returns: {boolean}
+* `a` {Buffer | TypedArray | DataView}
+* `b` {Buffer | TypedArray | DataView}
+* Returns: {boolean}
This function is based on a constant-time algorithm.
Returns true if `a` is equal to `b`, without leaking timing information that
diff --git a/doc/api/dgram.md b/doc/api/dgram.md
index f4db86d5ea..50fd5db5a6 100644
--- a/doc/api/dgram.md
+++ b/doc/api/dgram.md
@@ -208,6 +208,7 @@ socket.bind({
<!-- YAML
added: v0.1.99
-->
+* `callback` {Function} Called when the socket has been closed.
Close the underlying socket and stop listening for data on it. If a callback is
provided, it is added as a listener for the [`'close'`][] event.
diff --git a/doc/api/dns.md b/doc/api/dns.md
index 82ee2442a0..1d988d8b57 100644
--- a/doc/api/dns.md
+++ b/doc/api/dns.md
@@ -134,8 +134,8 @@ changes:
pr-url: https://github.com/nodejs/node/pull/744
description: The `all` option is supported now.
-->
-- `hostname` {string}
-- `options` {integer | Object}
+* `hostname` {string}
+* `options` {integer | Object}
- `family` {integer} The record family. Must be `4` or `6`. IPv4
and IPv6 addresses are both returned by default.
- `hints` {number} One or more [supported `getaddrinfo` flags][]. Multiple
@@ -148,7 +148,7 @@ changes:
**Default:** currently `false` (addresses are reordered) but this is
expected to change in the not too distant future.
New code should use `{ verbatim: true }`.
-- `callback` {Function}
+* `callback` {Function}
- `err` {Error}
- `address` {string} A string representation of an IPv4 or IPv6 address.
- `family` {integer} `4` or `6`, denoting the family of `address`.
@@ -213,9 +213,9 @@ on some operating systems (e.g FreeBSD 10.1).
<!-- YAML
added: v0.11.14
-->
-- `address` {string}
-- `port` {number}
-- `callback` {Function}
+* `address` {string}
+* `port` {number}
+* `callback` {Function}
- `err` {Error}
- `hostname` {string} e.g. `example.com`
- `service` {string} e.g. `http`
@@ -244,9 +244,9 @@ If this method is invoked as its [`util.promisify()`][]ed version, it returns a
<!-- YAML
added: v0.1.27
-->
-- `hostname` {string} Hostname to resolve.
-- `rrtype` {string} Resource record type. **Default:** `'A'`.
-- `callback` {Function}
+* `hostname` {string} Hostname to resolve.
+* `rrtype` {string} Resource record type. **Default:** `'A'`.
+* `callback` {Function}
- `err` {Error}
- `records` {string[] | Object[] | Object}
@@ -281,13 +281,13 @@ changes:
description: This method now supports passing `options`,
specifically `options.ttl`.
-->
-- `hostname` {string} Hostname to resolve.
-- `options` {Object}
+* `hostname` {string} Hostname to resolve.
+* `options` {Object}
- `ttl` {boolean} Retrieve the Time-To-Live value (TTL) of each record.
When `true`, the callback receives an array of
`{ address: '1.2.3.4', ttl: 60 }` objects rather than an array of strings,
with the TTL expressed in seconds.
-- `callback` {Function}
+* `callback` {Function}
- `err` {Error}
- `addresses` {string[] | Object[]}
@@ -305,13 +305,13 @@ changes:
description: This method now supports passing `options`,
specifically `options.ttl`.
-->
-- `hostname` {string} Hostname to resolve.
-- `options` {Object}
+* `hostname` {string} Hostname to resolve.
+* `options` {Object}
- `ttl` {boolean} Retrieve the Time-To-Live value (TTL) of each record.
When `true`, the callback receives an array of
`{ address: '0:1:2:3:4:5:6:7', ttl: 60 }` objects rather than an array of
strings, with the TTL expressed in seconds.
-- `callback` {Function}
+* `callback` {Function}
- `err` {Error}
- `addresses` {string[] | Object[]}
@@ -321,8 +321,8 @@ will contain an array of IPv6 addresses.
## dns.resolveAny(hostname, callback)
-- `hostname` {string}
-- `callback` {Function}
+* `hostname` {string}
+* `callback` {Function}
- `err` {Error}
- `ret` {Object[]}
@@ -368,8 +368,8 @@ Here is an example of the `ret` object passed to the callback:
<!-- YAML
added: v0.3.2
-->
-- `hostname` {string}
-- `callback` {Function}
+* `hostname` {string}
+* `callback` {Function}
- `err` {Error}
- `addresses` {string[]}
@@ -382,8 +382,8 @@ will contain an array of canonical name records available for the `hostname`
<!-- YAML
added: v0.1.27
-->
-- `hostname` {string}
-- `callback` {Function}
+* `hostname` {string}
+* `callback` {Function}
- `err` {Error}
- `addresses` {Object[]}
@@ -396,8 +396,8 @@ property (e.g. `[{priority: 10, exchange: 'mx.example.com'}, ...]`).
<!-- YAML
added: v0.9.12
-->
-- `hostname` {string}
-- `callback` {Function}
+* `hostname` {string}
+* `callback` {Function}
- `err` {Error}
- `addresses` {Object[]}
@@ -428,8 +428,8 @@ function will contain an array of objects with the following properties:
<!-- YAML
added: v0.1.90
-->
-- `hostname` {string}
-- `callback` {Function}
+* `hostname` {string}
+* `callback` {Function}
- `err` {Error}
- `addresses` {string[]}
@@ -442,8 +442,8 @@ contain an array of name server records available for `hostname`
<!-- YAML
added: v6.0.0
-->
-- `hostname` {string}
-- `callback` {Function}
+* `hostname` {string}
+* `callback` {Function}
- `err` {Error}
- `addresses` {string[]}
@@ -455,8 +455,8 @@ be an array of strings containing the reply records.
<!-- YAML
added: v0.11.10
-->
-- `hostname` {string}
-- `callback` {Function}
+* `hostname` {string}
+* `callback` {Function}
- `err` {Error}
- `address` {Object}
@@ -489,8 +489,8 @@ be an object with the following properties:
<!-- YAML
added: v0.1.27
-->
-- `hostname` {string}
-- `callback` {Function}
+* `hostname` {string}
+* `callback` {Function}
- `err` {Error}
- `addresses` {Object[]}
@@ -517,8 +517,8 @@ be an array of objects with the following properties:
<!-- YAML
added: v0.1.27
-->
-- `hostname` {string}
-- `callback` {Function}
+* `hostname` {string}
+* `callback` {Function}
- `err` {Error}
- `records` {string[][]}
@@ -533,8 +533,8 @@ treated separately.
<!-- YAML
added: v0.1.16
-->
-- `ip` {string}
-- `callback` {Function}
+* `ip` {string}
+* `callback` {Function}
- `err` {Error}
- `hostnames` {string[]}
@@ -548,7 +548,7 @@ one of the [DNS error codes][].
<!-- YAML
added: v0.11.3
-->
-- `servers` {string[]} array of [rfc5952][] formatted addresses
+* `servers` {string[]} array of [rfc5952][] formatted addresses
Sets the IP address and port of servers to be used when performing DNS
resolution. The `servers` argument is an array of [rfc5952][] formatted
@@ -654,8 +654,8 @@ section if a custom port is used.
<!-- YAML
added: v10.6.0
-->
-- `hostname` {string}
-- `options` {integer | Object}
+* `hostname` {string}
+* `options` {integer | Object}
- `family` {integer} The record family. Must be `4` or `6`. IPv4
and IPv6 addresses are both returned by default.
- `hints` {number} One or more [supported `getaddrinfo` flags][]. Multiple
@@ -717,8 +717,8 @@ dnsPromises.lookup('example.com', options).then((result) => {
<!-- YAML
added: v10.6.0
-->
-- `address` {string}
-- `port` {number}
+* `address` {string}
+* `port` {number}
Resolves the given `address` and `port` into a hostname and service using
the operating system's underlying `getnameinfo` implementation.
@@ -742,8 +742,8 @@ dnsPromises.lookupService('127.0.0.1', 22).then((result) => {
<!-- YAML
added: v10.6.0
-->
-- `hostname` {string} Hostname to resolve.
-- `rrtype` {string} Resource record type. **Default:** `'A'`.
+* `hostname` {string} Hostname to resolve.
+* `rrtype` {string} Resource record type. **Default:** `'A'`.
Uses the DNS protocol to resolve a hostname (e.g. `'nodejs.org'`) into an array
of the resource records. When successful, the `Promise` is resolved with an
@@ -771,8 +771,8 @@ is one of the [DNS error codes](#dns_error_codes).
<!-- YAML
added: v10.6.0
-->
-- `hostname` {string} Hostname to resolve.
-- `options` {Object}
+* `hostname` {string} Hostname to resolve.
+* `options` {Object}
- `ttl` {boolean} Retrieve the Time-To-Live value (TTL) of each record.
When `true`, the `Promise` is resolved with an array of
`{ address: '1.2.3.4', ttl: 60 }` objects rather than an array of strings,
@@ -786,8 +786,8 @@ addresses (e.g. `['74.125.79.104', '74.125.79.105', '74.125.79.106']`).
<!-- YAML
added: v10.6.0
-->
-- `hostname` {string} Hostname to resolve.
-- `options` {Object}
+* `hostname` {string} Hostname to resolve.
+* `options` {Object}
- `ttl` {boolean} Retrieve the Time-To-Live value (TTL) of each record.
When `true`, the `Promise` is resolved with an array of
`{ address: '0:1:2:3:4:5:6:7', ttl: 60 }` objects rather than an array of
@@ -801,7 +801,7 @@ addresses.
<!-- YAML
added: v10.6.0
-->
-- `hostname` {string}
+* `hostname` {string}
Uses the DNS protocol to resolve all records (also known as `ANY` or `*` query).
On success, the `Promise` is resolved with an array containing various types of
@@ -845,7 +845,7 @@ Here is an example of the result object:
<!-- YAML
added: v10.6.0
-->
-- `hostname` {string}
+* `hostname` {string}
Uses the DNS protocol to resolve `CNAME` records for the `hostname`. On success,
the `Promise` is resolved with an array of canonical name records available for
@@ -855,7 +855,7 @@ the `hostname` (e.g. `['bar.example.com']`).
<!-- YAML
added: v10.6.0
-->
-- `hostname` {string}
+* `hostname` {string}
Uses the DNS protocol to resolve mail exchange records (`MX` records) for the
`hostname`. On success, the `Promise` is resolved with an array of objects
@@ -866,7 +866,7 @@ containing both a `priority` and `exchange` property (e.g.
<!-- YAML
added: v10.6.0
-->
-- `hostname` {string}
+* `hostname` {string}
Uses the DNS protocol to resolve regular expression based records (`NAPTR`
records) for the `hostname`. On success, the `Promise` is resolved with an array
@@ -895,7 +895,7 @@ of objects with the following properties:
<!-- YAML
added: v10.6.0
-->
-- `hostname` {string}
+* `hostname` {string}
Uses the DNS protocol to resolve name server records (`NS` records) for the
`hostname`. On success, the `Promise` is resolved with an array of name server
@@ -906,7 +906,7 @@ records available for `hostname` (e.g.
<!-- YAML
added: v10.6.0
-->
-- `hostname` {string}
+* `hostname` {string}
Uses the DNS protocol to resolve pointer records (`PTR` records) for the
`hostname`. On success, the `Promise` is resolved with an array of strings
@@ -916,7 +916,7 @@ containing the reply records.
<!-- YAML
added: v10.6.0
-->
-- `hostname` {string}
+* `hostname` {string}
Uses the DNS protocol to resolve a start of authority record (`SOA` record) for
the `hostname`. On success, the `Promise` is resolved with an object with the
@@ -947,7 +947,7 @@ following properties:
<!-- YAML
added: v10.6.0
-->
-- `hostname` {string}
+* `hostname` {string}
Uses the DNS protocol to resolve service records (`SRV` records) for the
`hostname`. On success, the `Promise` is resolved with an array of objects with
@@ -972,7 +972,7 @@ the following properties:
<!-- YAML
added: v10.6.0
-->
-- `hostname` {string}
+* `hostname` {string}
Uses the DNS protocol to resolve text queries (`TXT` records) for the
`hostname`. On success, the `Promise` is resolved with a two-dimensional array
@@ -985,7 +985,7 @@ treated separately.
<!-- YAML
added: v10.6.0
-->
-- `ip` {string}
+* `ip` {string}
Performs a reverse DNS query that resolves an IPv4 or IPv6 address to an
array of hostnames.
@@ -997,7 +997,7 @@ is one of the [DNS error codes](#dns_error_codes).
<!-- YAML
added: v10.6.0
-->
-- `servers` {string[]} array of [rfc5952][] formatted addresses
+* `servers` {string[]} array of [rfc5952][] formatted addresses
Sets the IP address and port of servers to be used when performing DNS
resolution. The `servers` argument is an array of [rfc5952][] formatted
diff --git a/doc/api/events.md b/doc/api/events.md
index bf57572f59..edb4daa2fb 100644
--- a/doc/api/events.md
+++ b/doc/api/events.md
@@ -228,6 +228,8 @@ The `'removeListener'` event is emitted *after* the `listener` is removed.
added: v0.9.12
deprecated: v4.0.0
-->
+* `emitter` {EventEmitter} The emitter to query
+* `eventName` {string|symbol} The event name
> Stability: 0 - Deprecated: Use [`emitter.listenerCount()`][] instead.
@@ -286,8 +288,8 @@ Its `name` property is set to `'MaxListenersExceededWarning'`.
<!-- YAML
added: v0.1.26
-->
-- `eventName` {string|symbol}
-- `listener` {Function}
+* `eventName` {string|symbol}
+* `listener` {Function}
Alias for `emitter.on(eventName, listener)`.
@@ -295,9 +297,9 @@ Alias for `emitter.on(eventName, listener)`.
<!-- YAML
added: v0.1.26
-->
-- `eventName` {string|symbol}
+* `eventName` {string|symbol}
- `...args` {any}
-- Returns: {boolean}
+* Returns: {boolean}
Synchronously calls each of the listeners registered for the event named
`eventName`, in the order they were registered, passing the supplied arguments
@@ -310,7 +312,7 @@ Returns `true` if the event had listeners, `false` otherwise.
added: v6.0.0
-->
-- Returns: {Array}
+* Returns: {Array}
Returns an array listing the events for which the emitter has registered
listeners. The values in the array will be strings or `Symbol`s.
@@ -333,7 +335,7 @@ console.log(myEE.eventNames());
added: v1.0.0
-->
-- Returns: {integer}
+* Returns: {integer}
Returns the current max listener value for the `EventEmitter` which is either
set by [`emitter.setMaxListeners(n)`][] or defaults to
@@ -358,8 +360,8 @@ changes:
description: For listeners attached using `.once()` this returns the
original listeners instead of wrapper functions now.
-->
-- `eventName` {string|symbol}
-- Returns: {Function[]}
+* `eventName` {string|symbol}
+* Returns: {Function[]}
Returns a copy of the array of listeners for the event named `eventName`.
@@ -501,8 +503,8 @@ Returns a reference to the `EventEmitter`, so that calls can be chained.
<!-- YAML
added: v0.1.26
-->
-- `eventName` {string|symbol}
-- Returns: {EventEmitter}
+* `eventName` {string|symbol}
+* Returns: {EventEmitter}
Removes all listeners, or those of the specified `eventName`.
@@ -516,9 +518,9 @@ Returns a reference to the `EventEmitter`, so that calls can be chained.
<!-- YAML
added: v0.1.26
-->
-- `eventName` {string|symbol}
-- `listener` {Function}
-- Returns: {EventEmitter}
+* `eventName` {string|symbol}
+* `listener` {Function}
+* Returns: {EventEmitter}
Removes the specified `listener` from the listener array for the event named
`eventName`.
@@ -585,8 +587,8 @@ Returns a reference to the `EventEmitter`, so that calls can be chained.
<!-- YAML
added: v0.3.5
-->
-- `n` {integer}
-- Returns: {EventEmitter}
+* `n` {integer}
+* Returns: {EventEmitter}
By default `EventEmitter`s will print a warning if more than `10` listeners are
added for a particular event. This is a useful default that helps finding
@@ -601,8 +603,8 @@ Returns a reference to the `EventEmitter`, so that calls can be chained.
<!-- YAML
added: v9.4.0
-->
-- `eventName` {string|symbol}
-- Returns: {Function[]}
+* `eventName` {string|symbol}
+* Returns: {Function[]}
Returns a copy of the array of listeners for the event named `eventName`,
including any wrappers (such as those created by `.once()`).
diff --git a/doc/api/http.md b/doc/api/http.md
index fdbc99774e..3c86e856d2 100644
--- a/doc/api/http.md
+++ b/doc/api/http.md
@@ -1781,14 +1781,14 @@ changes:
pr-url: https://github.com/nodejs/node/pull/15752
description: The `options` argument is supported now.
-->
-- `options` {Object}
+* `options` {Object}
* `IncomingMessage` {http.IncomingMessage} Specifies the `IncomingMessage`
class to be used. Useful for extending the original `IncomingMessage`.
**Default:** `IncomingMessage`.
* `ServerResponse` {http.ServerResponse} Specifies the `ServerResponse` class
to be used. Useful for extending the original `ServerResponse`. **Default:**
`ServerResponse`.
-- `requestListener` {Function}
+* `requestListener` {Function}
* Returns: {http.Server}
diff --git a/doc/api/http2.md b/doc/api/http2.md
index 9f702de02b..a98c0f52b7 100644
--- a/doc/api/http2.md
+++ b/doc/api/http2.md
@@ -1609,7 +1609,7 @@ a given number of milliseconds set using `http2server.setTimeout()`.
<!-- YAML
added: v8.4.0
-->
-- `callback` {Function}
+* `callback` {Function}
Stops the server from accepting new connections. See [`net.Server.close()`][].
@@ -1728,7 +1728,7 @@ the connection is terminated. See the [Compatibility API][].
<!-- YAML
added: v8.4.0
-->
-- `callback` {Function}
+* `callback` {Function}
Stops the server from accepting new connections. See [`tls.Server.close()`][].
@@ -3139,6 +3139,8 @@ will result in a [`TypeError`][] being thrown.
<!-- YAML
added: v8.4.0
-->
+* `headers` {HTTP/2 Headers Object} An object describing the headers
+* `callback` {Function}
Call [`http2stream.pushStream()`][] with the given headers, and wraps the
given newly created [`Http2Stream`] on `Http2ServerResponse`.
diff --git a/doc/api/https.md b/doc/api/https.md
index 51e6e5c162..70147c7790 100644
--- a/doc/api/https.md
+++ b/doc/api/https.md
@@ -27,7 +27,7 @@ This class is a subclass of `tls.Server` and emits events same as
<!-- YAML
added: v0.1.90
-->
-- `callback` {Function}
+* `callback` {Function}
See [`server.close()`][`http.close()`] from the HTTP module for details.
@@ -47,8 +47,8 @@ See [`http.Server#maxHeadersCount`][].
<!-- YAML
added: v0.11.2
-->
-- `msecs` {number} **Default:** `120000` (2 minutes)
-- `callback` {Function}
+* `msecs` {number} **Default:** `120000` (2 minutes)
+* `callback` {Function}
See [`http.Server#setTimeout()`][].
@@ -72,9 +72,9 @@ See [`http.Server#keepAliveTimeout`][].
<!-- YAML
added: v0.3.4
-->
-- `options` {Object} Accepts `options` from [`tls.createServer()`][],
+* `options` {Object} Accepts `options` from [`tls.createServer()`][],
[`tls.createSecureContext()`][] and [`http.createServer()`][].
-- `requestListener` {Function} A listener to be added to the `'request'` event.
+* `requestListener` {Function} A listener to be added to the `'request'` event.
Example:
@@ -124,9 +124,9 @@ changes:
description: The `options` parameter can be a WHATWG `URL` object.
-->
- `url` {string | URL}
-- `options` {Object} Accepts the same `options` as
+* `options` {Object | string | URL} Accepts the same `options` as
[`https.request()`][], with the `method` always set to `GET`.
-- `callback` {Function}
+* `callback` {Function}
Like [`http.get()`][] but for HTTPS.
@@ -175,12 +175,12 @@ changes:
description: The `options` parameter can be a WHATWG `URL` object.
-->
- `url` {string | URL}
-- `options` {Object} Accepts all `options` from
+* `options` {Object | string | URL} Accepts all `options` from
[`http.request()`][], with some differences in default values:
- `protocol` **Default:** `'https:'`
- `port` **Default:** `443`
- `agent` **Default:** `https.globalAgent`
-- `callback` {Function}
+* `callback` {Function}
Makes a request to a secure web server.
diff --git a/doc/api/net.md b/doc/api/net.md
index f1e41b46c4..ac004d6c22 100644
--- a/doc/api/net.md
+++ b/doc/api/net.md
@@ -64,10 +64,12 @@ This class is used to create a TCP or [IPC][] server.
### new net.Server([options][, connectionListener])
+* `options` {Object} See
+ [`net.createServer([options][, connectionListener])`][`net.createServer()`].
+* `connectionListener` {Function} Automatically set as a listener for the
+ [`'connection'`][] event.
* Returns: {net.Server}
-See [`net.createServer([options][, connectionListener])`][`net.createServer()`].
-
`net.Server` is an [`EventEmitter`][] with the following events:
### Event: 'close'
@@ -145,6 +147,7 @@ Don't call `server.address()` until the `'listening'` event has been emitted.
added: v0.1.90
-->
+* `callback` {Function} Called when the server is closed
* Returns: {net.Server}
Stops the server from accepting new connections and keeps existing
@@ -173,6 +176,7 @@ connections use asynchronous [`server.getConnections()`][] instead.
added: v0.9.7
-->
+* `callback` {Function}
* Returns: {net.Server}
Asynchronously get the number of concurrent connections on the server. Works
@@ -394,8 +398,6 @@ it to interact with the client.
added: v0.3.4
-->
-Creates a new socket object.
-
* `options` {Object} Available options are:
* `fd` {number} If specified, wrap around an existing socket with
the given file descriptor, otherwise a new socket will be created.
@@ -408,6 +410,8 @@ Creates a new socket object.
otherwise ignored. **Default:** `false`.
* Returns: {net.Socket}
+Creates a new socket object.
+
The newly created socket can be either a TCP socket or a streaming [IPC][]
endpoint, depending on what it [`connect()`][`socket.connect()`] to.
@@ -668,6 +672,7 @@ callback.
added: v0.1.90
-->
+* `exception` {Object}
* Returns: {net.Socket}
Ensures that no more I/O activity happens on this socket. Only necessary in
@@ -686,6 +691,8 @@ listeners for that event will receive `exception` as an argument.
added: v0.1.90
-->
+* `data` {string|Buffer|Uint8Array}
+* `encoding` {string} Only used when data is `string`. **Default:** `'utf8'`.
* Returns: {net.Socket} The socket itself.
Half-closes the socket. i.e., it sends a FIN packet. It is possible the
@@ -765,6 +772,7 @@ Resumes reading after a call to [`socket.pause()`][].
added: v0.1.90
-->
+* `encoding` {string}
* Returns: {net.Socket} The socket itself.
Set the encoding for the socket as a [Readable Stream][]. See
@@ -804,6 +812,8 @@ algorithm, they buffer data before sending it off. Setting `true` for
added: v0.1.90
-->
+* `timeout` {number}
+* `callback` {Function}
* Returns: {net.Socket} The socket itself.
Sets the socket to timeout after `timeout` milliseconds of inactivity on
@@ -877,6 +887,8 @@ Possible signatures:
<!-- YAML
added: v0.7.0
-->
+* `options` {Object}
+* `connectListener` {Function}
Alias to
[`net.createConnection(options[, connectListener])`][`net.createConnection(options)`].
@@ -884,6 +896,8 @@ Alias to
<!-- YAML
added: v0.1.90
-->
+* `path` {string}
+* `connectListener` {Function}
Alias to
[`net.createConnection(path[, connectListener])`][`net.createConnection(path)`].
@@ -892,6 +906,9 @@ Alias to
<!-- YAML
added: v0.1.90
-->
+* `port` {number}
+* `host` {string}
+* `connectListener` {Function}
Alias to
[`net.createConnection(port[, host][, connectListener])`][`net.createConnection(port, host)`].
@@ -1014,6 +1031,8 @@ then returns the `net.Socket` that starts the connection.
<!-- YAML
added: v0.5.0
-->
+* `options` {Object}
+* `connectionListener` {Function}
Creates a new TCP or [IPC][] server.
@@ -1089,6 +1108,7 @@ $ nc -U /tmp/echo.sock
added: v0.3.0
-->
+* `input` {string}
* Returns: {integer}
Tests if input is an IP address. Returns `0` for invalid strings,
@@ -1100,6 +1120,7 @@ addresses.
added: v0.3.0
-->
+* `input` {string}
* Returns: {boolean}
Returns `true` if input is a version 4 IP address, otherwise returns `false`.
@@ -1109,6 +1130,7 @@ Returns `true` if input is a version 4 IP address, otherwise returns `false`.
added: v0.3.0
-->
+* `input` {string}
* Returns: {boolean}
Returns `true` if input is a version 6 IP address, otherwise returns `false`.
diff --git a/doc/api/process.md b/doc/api/process.md
index 2c27409d80..ed567595a3 100644
--- a/doc/api/process.md
+++ b/doc/api/process.md
@@ -1695,6 +1695,7 @@ This feature is not available in [`Worker`][] threads.
<!-- YAML
added: v0.1.28
-->
+* `id` {integer | string}
The `process.setuid(id)` method sets the user identity of the process. (See
setuid(2).) The `id` can be passed as either a numeric ID or a username string.
diff --git a/doc/api/stream.md b/doc/api/stream.md
index 47d1154cc0..9896c596c8 100644
--- a/doc/api/stream.md
+++ b/doc/api/stream.md
@@ -363,6 +363,7 @@ See also: [`writable.uncork()`][].
added: v8.0.0
-->
+* `error` {Error}
* Returns: {this}
Destroy the stream, and emit the passed `'error'` and a `'close'` event.
@@ -1285,6 +1286,7 @@ Examples of `Transform` streams include:
<!-- YAML
added: v8.0.0
-->
+* `error` {Error}
Destroy the stream, and emit `'error'`. After this call, the
transform stream would release any internal resources.
diff --git a/doc/api/tty.md b/doc/api/tty.md
index 91bca8284d..cc95bfa9ae 100644
--- a/doc/api/tty.md
+++ b/doc/api/tty.md
@@ -60,6 +60,11 @@ A `boolean` that is always `true` for `tty.ReadStream` instances.
added: v0.7.7
-->
+* `mode` {boolean} If `true`, configures the `tty.ReadStream` to operate as a
+ raw device. If `false`, configures the `tty.ReadStream` to operate in its
+ default mode. The `readStream.isRaw` property will be set to the resulting
+ mode.
+
Allows configuration of `tty.ReadStream` so that it operates as a raw device.
When in raw mode, input is always available character-by-character, not
@@ -67,11 +72,6 @@ including modifiers. Additionally, all special processing of characters by the
terminal is disabled, including echoing input characters.
Note that `CTRL`+`C` will no longer cause a `SIGINT` when in this mode.
-* `mode` {boolean} If `true`, configures the `tty.ReadStream` to operate as a
- raw device. If `false`, configures the `tty.ReadStream` to operate in its
- default mode. The `readStream.isRaw` property will be set to the resulting
- mode.
-
## Class: tty.WriteStream
<!-- YAML
added: v0.5.8
diff --git a/doc/api/util.md b/doc/api/util.md
index 42cdf1b99c..1c7d2393a1 100644
--- a/doc/api/util.md
+++ b/doc/api/util.md
@@ -298,13 +298,13 @@ changes:
description: The `constructor` parameter can refer to an ES6 class now.
-->
+* `constructor` {Function}
+* `superConstructor` {Function}
+
Usage of `util.inherits()` is discouraged. Please use the ES6 `class` and
`extends` keywords to get language level inheritance support. Also note
that the two styles are [semantically incompatible][].
-* `constructor` {Function}
-* `superConstructor` {Function}
-
Inherit the prototype methods from one [constructor][] into another. The
prototype of `constructor` will be set to a new object created from
`superConstructor`.
@@ -939,6 +939,7 @@ useful for addon developers who prefer to do type checking in JavaScript.
added: v10.0.0
-->
+* `value` {any}
* Returns: {boolean}
Returns `true` if the value is a built-in [`ArrayBuffer`][] or
@@ -959,6 +960,7 @@ util.types.isAnyArrayBuffer(new SharedArrayBuffer()); // Returns true
added: v10.0.0
-->
+* `value` {any}
* Returns: {boolean}
Returns `true` if the value is an `arguments` object.
@@ -977,6 +979,7 @@ function foo() {
added: v10.0.0
-->
+* `value` {any}
* Returns: {boolean}
Returns `true` if the value is a built-in [`ArrayBuffer`][] instance.
@@ -995,6 +998,7 @@ util.types.isArrayBuffer(new SharedArrayBuffer()); // Returns false
added: v10.0.0
-->
+* `value` {any}
* Returns: {boolean}
Returns `true` if the value is an [async function][].
@@ -1014,6 +1018,7 @@ util.types.isAsyncFunction(async function foo() {}); // Returns true
added: v10.0.0
-->
+* `value` {any}
* Returns: {boolean}
Returns `true` if the value is a `BigInt64Array` instance. The
@@ -1033,6 +1038,7 @@ util.types.isBigInt64Array(new BigUint64Array()); // Returns false
added: v10.0.0
-->
+* `value` {any}
* Returns: {boolean}
Returns `true` if the value is a `BigUint64Array` instance. The
@@ -1052,6 +1058,7 @@ util.types.isBigUint64Array(new BigUint64Array()); // Returns true
added: v10.0.0
-->
+* `value` {any}
* Returns: {boolean}
Returns `true` if the value is a boolean object, e.g. created
@@ -1073,6 +1080,7 @@ util.types.isBooleanObject(Boolean(true)); // Returns false
added: v10.0.0
-->
+* `value` {any}
* Returns: {boolean}
Returns `true` if the value is a built-in [`DataView`][] instance.
@@ -1092,6 +1100,7 @@ See also [`ArrayBuffer.isView()`][].
added: v10.0.0
-->
+* `value` {any}
* Returns: {boolean}
Returns `true` if the value is a built-in [`Date`][] instance.
@@ -1107,6 +1116,7 @@ util.types.isDate(new Date()); // Returns true
added: v10.0.0
-->
+* `value` {any}
* Returns: {boolean}
Returns `true` if the value is a native `External` value.
@@ -1116,6 +1126,7 @@ Returns `true` if the value is a native `External` value.
added: v10.0.0
-->
+* `value` {any}
* Returns: {boolean}
Returns `true` if the value is a built-in [`Float32Array`][] instance.
@@ -1133,6 +1144,7 @@ util.types.isFloat32Array(new Float64Array()); // Returns false
added: v10.0.0
-->
+* `value` {any}
* Returns: {boolean}
Returns `true` if the value is a built-in [`Float64Array`][] instance.
@@ -1150,6 +1162,7 @@ util.types.isFloat64Array(new Float64Array()); // Returns true
added: v10.0.0
-->
+* `value` {any}
* Returns: {boolean}
Returns `true` if the value is a generator function.
@@ -1169,6 +1182,7 @@ util.types.isGeneratorFunction(function* foo() {}); // Returns true
added: v10.0.0
-->
+* `value` {any}
* Returns: {boolean}
Returns `true` if the value is a generator object as returned from a
@@ -1190,6 +1204,7 @@ util.types.isGeneratorObject(generator); // Returns true
added: v10.0.0
-->
+* `value` {any}
* Returns: {boolean}
Returns `true` if the value is a built-in [`Int8Array`][] instance.
@@ -1207,6 +1222,7 @@ util.types.isInt8Array(new Float64Array()); // Returns false
added: v10.0.0
-->
+* `value` {any}
* Returns: {boolean}
Returns `true` if the value is a built-in [`Int16Array`][] instance.
@@ -1224,6 +1240,7 @@ util.types.isInt16Array(new Float64Array()); // Returns false
added: v10.0.0
-->
+* `value` {any}
* Returns: {boolean}
Returns `true` if the value is a built-in [`Int32Array`][] instance.
@@ -1241,6 +1258,7 @@ util.types.isInt32Array(new Float64Array()); // Returns false
added: v10.0.0
-->
+* `value` {any}
* Returns: {boolean}
Returns `true` if the value is a built-in [`Map`][] instance.
@@ -1256,6 +1274,7 @@ util.types.isMap(new Map()); // Returns true
added: v10.0.0
-->
+* `value` {any}
* Returns: {boolean}
Returns `true` if the value is an iterator returned for a built-in
@@ -1276,6 +1295,7 @@ util.types.isMapIterator(map[Symbol.iterator]()); // Returns true
added: v10.0.0
-->
+* `value` {any}
* Returns: {boolean}
Returns `true` if the value is an instance of a [Module Namespace Object][].
@@ -1294,6 +1314,7 @@ util.types.isModuleNamespaceObject(ns); // Returns true
added: v10.0.0
-->
+* `value` {any}
* Returns: {boolean}
Returns `true` if the value is an instance of a built-in [`Error`][] type.
@@ -1311,6 +1332,7 @@ util.types.isNativeError(new RangeError()); // Returns true
added: v10.0.0
-->
+* `value` {any}
* Returns: {boolean}
Returns `true` if the value is a number object, e.g. created
@@ -1328,6 +1350,7 @@ util.types.isNumberObject(new Number(0)); // Returns true
added: v10.0.0
-->
+* `value` {any}
* Returns: {boolean}
Returns `true` if the value is a built-in [`Promise`][].
@@ -1343,6 +1366,7 @@ util.types.isPromise(Promise.resolve(42)); // Returns true
added: v10.0.0
-->
+* `value` {any}
* Returns: {boolean}
Returns `true` if the value is a [`Proxy`][] instance.
@@ -1361,6 +1385,7 @@ util.types.isProxy(proxy); // Returns true
added: v10.0.0
-->
+* `value` {any}
* Returns: {boolean}
Returns `true` if the value is a regular expression object.
@@ -1377,6 +1402,7 @@ util.types.isRegExp(new RegExp('abc')); // Returns true
added: v10.0.0
-->
+* `value` {any}
* Returns: {boolean}
Returns `true` if the value is a built-in [`Set`][] instance.
@@ -1392,6 +1418,7 @@ util.types.isSet(new Set()); // Returns true
added: v10.0.0
-->
+* `value` {any}
* Returns: {boolean}
Returns `true` if the value is an iterator returned for a built-in
@@ -1412,6 +1439,7 @@ util.types.isSetIterator(set[Symbol.iterator]()); // Returns true
added: v10.0.0
-->
+* `value` {any}
* Returns: {boolean}
Returns `true` if the value is a built-in [`SharedArrayBuffer`][] instance.
@@ -1430,6 +1458,7 @@ util.types.isSharedArrayBuffer(new SharedArrayBuffer()); // Returns true
added: v10.0.0
-->
+* `value` {any}
* Returns: {boolean}
Returns `true` if the value is a string object, e.g. created
@@ -1447,6 +1476,7 @@ util.types.isStringObject(new String('foo')); // Returns true
added: v10.0.0
-->
+* `value` {any}
* Returns: {boolean}
Returns `true` if the value is a symbol object, created
@@ -1465,6 +1495,7 @@ util.types.isSymbolObject(Object(symbol)); // Returns true
added: v10.0.0
-->
+* `value` {any}
* Returns: {boolean}
Returns `true` if the value is a built-in [`TypedArray`][] instance.
@@ -1484,6 +1515,7 @@ See also [`ArrayBuffer.isView()`][].
added: v10.0.0
-->
+* `value` {any}
* Returns: {boolean}
Returns `true` if the value is a built-in [`Uint8Array`][] instance.
@@ -1501,6 +1533,7 @@ util.types.isUint8Array(new Float64Array()); // Returns false
added: v10.0.0
-->
+* `value` {any}
* Returns: {boolean}
Returns `true` if the value is a built-in [`Uint8ClampedArray`][] instance.
@@ -1518,6 +1551,7 @@ util.types.isUint8ClampedArray(new Float64Array()); // Returns false
added: v10.0.0
-->
+* `value` {any}
* Returns: {boolean}
Returns `true` if the value is a built-in [`Uint16Array`][] instance.
@@ -1535,6 +1569,7 @@ util.types.isUint16Array(new Float64Array()); // Returns false
added: v10.0.0
-->
+* `value` {any}
* Returns: {boolean}
Returns `true` if the value is a built-in [`Uint32Array`][] instance.
@@ -1552,6 +1587,7 @@ util.types.isUint32Array(new Float64Array()); // Returns false
added: v10.0.0
-->
+* `value` {any}
* Returns: {boolean}
Returns `true` if the value is a built-in [`WeakMap`][] instance.
@@ -1567,6 +1603,7 @@ util.types.isWeakMap(new WeakMap()); // Returns true
added: v10.0.0
-->
+* `value` {any}
* Returns: {boolean}
Returns `true` if the value is a built-in [`WeakSet`][] instance.
@@ -1582,6 +1619,7 @@ util.types.isWeakSet(new WeakSet()); // Returns true
added: v10.0.0
-->
+* `value` {any}
* Returns: {boolean}
Returns `true` if the value is a built-in [`WebAssembly.Module`][] instance.
@@ -1603,6 +1641,8 @@ applications and modules should be updated to find alternative approaches.
added: v0.7.5
deprecated: v6.0.0
-->
+* `target` {Object}
+* `source` {Object}
> Stability: 0 - Deprecated: Use [`Object.assign()`] instead.
diff --git a/doc/api/v8.md b/doc/api/v8.md
index c9afa93f89..6536451e3a 100644
--- a/doc/api/v8.md
+++ b/doc/api/v8.md
@@ -175,6 +175,7 @@ changes to the API or wire format) may occur until this warning is removed.
added: v8.0.0
-->
+* `value` {any}
* Returns: {Buffer}
Uses a [`DefaultSerializer`][] to serialize `value` into a buffer.
@@ -203,6 +204,8 @@ Writes out a header, which includes the serialization format version.
#### serializer.writeValue(value)
+* `value` {any}
+
Serializes a JavaScript value and adds the serialized representation to the
internal buffer.
@@ -362,6 +365,7 @@ For use inside of a custom [`deserializer._readHostObject()`][].
#### deserializer.readRawBytes(length)
+* `length` {integer}
* Returns: {Buffer}
Read raw bytes from the deserializer’s internal buffer. The `length` parameter
diff --git a/doc/api/zlib.md b/doc/api/zlib.md
index e6c5504bff..89ce111e22 100644
--- a/doc/api/zlib.md
+++ b/doc/api/zlib.md
@@ -428,6 +428,8 @@ as appropriate for the derived class).
added: v0.9.4
-->
+* `callback` {Function}
+
Close the underlying handle.
### zlib.flush([kind], callback)
@@ -436,6 +438,7 @@ added: v0.5.8
-->
* `kind` **Default:** `zlib.constants.Z_FULL_FLUSH`
+* `callback` {Function}
Flush pending data. Don't call this frivolously, premature flushes negatively
impact the effectiveness of the compression algorithm.
@@ -450,6 +453,10 @@ writes and will only produce output when data is being read from the stream.
added: v0.11.4
-->
+* `level` {integer}
+* `strategy` {integer}
+* `callback` {Function}
+
Dynamically update the compression level and compression strategy.
Only applicable to deflate algorithm.
@@ -473,6 +480,8 @@ Provides an object enumerating Zlib-related constants.
added: v0.5.8
-->
+* `options` {Object}
+
Creates and returns a new [`Deflate`][] object with the given [`options`][].
## zlib.createDeflateRaw([options])
@@ -480,6 +489,8 @@ Creates and returns a new [`Deflate`][] object with the given [`options`][].
added: v0.5.8
-->
+* `options` {Object}
+
Creates and returns a new [`DeflateRaw`][] object with the given [`options`][].
An upgrade of zlib from 1.2.8 to 1.2.11 changed behavior when `windowBits`
@@ -494,6 +505,8 @@ that effectively uses an 8-bit window only.
added: v0.5.8
-->
+* `options` {Object}
+
Creates and returns a new [`Gunzip`][] object with the given [`options`][].
## zlib.createGzip([options])
@@ -501,6 +514,8 @@ Creates and returns a new [`Gunzip`][] object with the given [`options`][].
added: v0.5.8
-->
+* `options` {Object}
+
Creates and returns a new [`Gzip`][] object with the given [`options`][].
## zlib.createInflate([options])
@@ -508,6 +523,8 @@ Creates and returns a new [`Gzip`][] object with the given [`options`][].
added: v0.5.8
-->
+* `options` {Object}
+
Creates and returns a new [`Inflate`][] object with the given [`options`][].
## zlib.createInflateRaw([options])
@@ -515,6 +532,8 @@ Creates and returns a new [`Inflate`][] object with the given [`options`][].
added: v0.5.8
-->
+* `options` {Object}
+
Creates and returns a new [`InflateRaw`][] object with the given [`options`][].
## zlib.createUnzip([options])
@@ -522,6 +541,8 @@ Creates and returns a new [`InflateRaw`][] object with the given [`options`][].
added: v0.5.8
-->
+* `options` {Object}
+
Creates and returns a new [`Unzip`][] object with the given [`options`][].
## Convenience Methods
@@ -550,6 +571,10 @@ changes:
pr-url: https://github.com/nodejs/node/pull/12001
description: The `buffer` parameter can be an `Uint8Array` now.
-->
+* `buffer` {Buffer|TypedArray|DataView|ArrayBuffer|string}
+* `options` {Object}
+* `callback` {Function}
+
### zlib.deflateSync(buffer[, options])
<!-- YAML
added: v0.11.12
@@ -565,7 +590,8 @@ changes:
description: The `buffer` parameter can be an `Uint8Array` now.
-->
-- `buffer` {Buffer|TypedArray|DataView|ArrayBuffer|string}
+* `buffer` {Buffer|TypedArray|DataView|ArrayBuffer|string}
+* `options` {Object}
Compress a chunk of data with [`Deflate`][].
@@ -580,6 +606,11 @@ changes:
pr-url: https://github.com/nodejs/node/pull/12001
description: The `buffer` parameter can be an `Uint8Array` now.
-->
+
+* `buffer` {Buffer|TypedArray|DataView|ArrayBuffer|string}
+* `options` {Object}
+* `callback` {Function}
+
### zlib.deflateRawSync(buffer[, options])
<!-- YAML
added: v0.11.12
@@ -595,7 +626,8 @@ changes:
description: The `buffer` parameter can be an `Uint8Array` now.
-->
-- `buffer` {Buffer|TypedArray|DataView|ArrayBuffer|string}
+* `buffer` {Buffer|TypedArray|DataView|ArrayBuffer|string}
+* `options` {Object}
Compress a chunk of data with [`DeflateRaw`][].
@@ -613,6 +645,11 @@ changes:
pr-url: https://github.com/nodejs/node/pull/12001
description: The `buffer` parameter can be an `Uint8Array` now.
-->
+
+* `buffer` {Buffer|TypedArray|DataView|ArrayBuffer|string}
+* `options` {Object}
+* `callback` {Function}
+
### zlib.gunzipSync(buffer[, options])
<!-- YAML
added: v0.11.12
@@ -628,7 +665,8 @@ changes:
description: The `buffer` parameter can be an `Uint8Array` now.
-->
-- `buffer` {Buffer|TypedArray|DataView|ArrayBuffer|string}
+* `buffer` {Buffer|TypedArray|DataView|ArrayBuffer|string}
+* `options` {Object}
Decompress a chunk of data with [`Gunzip`][].
@@ -646,6 +684,11 @@ changes:
pr-url: https://github.com/nodejs/node/pull/12001
description: The `buffer` parameter can be an `Uint8Array` now.
-->
+
+* `buffer` {Buffer|TypedArray|DataView|ArrayBuffer|string}
+* `options` {Object}
+* `callback` {Function}
+
### zlib.gzipSync(buffer[, options])
<!-- YAML
added: v0.11.12
@@ -661,7 +704,8 @@ changes:
description: The `buffer` parameter can be an `Uint8Array` now.
-->
-- `buffer` {Buffer|TypedArray|DataView|ArrayBuffer|string}
+* `buffer` {Buffer|TypedArray|DataView|ArrayBuffer|string}
+* `options` {Object}
Compress a chunk of data with [`Gzip`][].
@@ -679,6 +723,11 @@ changes:
pr-url: https://github.com/nodejs/node/pull/12001
description: The `buffer` parameter can be an `Uint8Array` now.
-->
+
+* `buffer` {Buffer|TypedArray|DataView|ArrayBuffer|string}
+* `options` {Object}
+* `callback` {Function}
+
### zlib.inflateSync(buffer[, options])
<!-- YAML
added: v0.11.12
@@ -694,7 +743,8 @@ changes:
description: The `buffer` parameter can be an `Uint8Array` now.
-->
-- `buffer` {Buffer|TypedArray|DataView|ArrayBuffer|string}
+* `buffer` {Buffer|TypedArray|DataView|ArrayBuffer|string}
+* `options` {Object}
Decompress a chunk of data with [`Inflate`][].
@@ -712,6 +762,11 @@ changes:
pr-url: https://github.com/nodejs/node/pull/12001
description: The `buffer` parameter can be an `Uint8Array` now.
-->
+
+* `buffer` {Buffer|TypedArray|DataView|ArrayBuffer|string}
+* `options` {Object}
+* `callback` {Function}
+
### zlib.inflateRawSync(buffer[, options])
<!-- YAML
added: v0.11.12
@@ -727,7 +782,8 @@ changes:
description: The `buffer` parameter can be an `Uint8Array` now.
-->
-- `buffer` {Buffer|TypedArray|DataView|ArrayBuffer|string}
+* `buffer` {Buffer|TypedArray|DataView|ArrayBuffer|string}
+* `options` {Object}
Decompress a chunk of data with [`InflateRaw`][].
@@ -745,6 +801,11 @@ changes:
pr-url: https://github.com/nodejs/node/pull/12001
description: The `buffer` parameter can be an `Uint8Array` now.
-->
+
+* `buffer` {Buffer|TypedArray|DataView|ArrayBuffer|string}
+* `options` {Object}
+* `callback` {Function}
+
### zlib.unzipSync(buffer[, options])
<!-- YAML
added: v0.11.12
@@ -760,7 +821,8 @@ changes:
description: The `buffer` parameter can be an `Uint8Array` now.
-->
-- `buffer` {Buffer|TypedArray|DataView|ArrayBuffer|string}
+* `buffer` {Buffer|TypedArray|DataView|ArrayBuffer|string}
+* `options` {Object}
Decompress a chunk of data with [`Unzip`][].