@types/node 14.14.1 → 14.14.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- node/README.md +1 -1
- node/fs/promises.d.ts +10 -0
- node/fs.d.ts +33 -0
- node/globals.d.ts +2 -0
- node/http.d.ts +4 -1
- node/package.json +2 -2
- node/process.d.ts +1 -1
- node/tls.d.ts +6 -4
node/README.md
CHANGED
|
@@ -8,7 +8,7 @@ This package contains type definitions for Node.js (http://nodejs.org/).
|
|
|
8
8
|
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/node.
|
|
9
9
|
|
|
10
10
|
### Additional Details
|
|
11
|
-
* Last updated: Wed, 21 Oct 2020
|
|
11
|
+
* Last updated: Wed, 21 Oct 2020 21:01:39 GMT
|
|
12
12
|
* Dependencies: none
|
|
13
13
|
* Global values: `Buffer`, `__dirname`, `__filename`, `clearImmediate`, `clearInterval`, `clearTimeout`, `console`, `exports`, `global`, `module`, `process`, `queueMicrotask`, `require`, `setImmediate`, `setInterval`, `setTimeout`
|
|
14
14
|
|
node/fs/promises.d.ts
CHANGED
|
@@ -415,6 +415,16 @@ declare module 'fs/promises' {
|
|
|
415
415
|
*/
|
|
416
416
|
function lchown(path: PathLike, uid: number, gid: number): Promise<void>;
|
|
417
417
|
|
|
418
|
+
/**
|
|
419
|
+
* Changes the access and modification times of a file in the same way as `fsPromises.utimes()`,
|
|
420
|
+
* with the difference that if the path refers to a symbolic link, then the link is not
|
|
421
|
+
* dereferenced: instead, the timestamps of the symbolic link itself are changed.
|
|
422
|
+
* @param path A path to a file. If a URL is provided, it must use the `file:` protocol.
|
|
423
|
+
* @param atime The last access time. If a string is provided, it will be coerced to number.
|
|
424
|
+
* @param mtime The last modified time. If a string is provided, it will be coerced to number.
|
|
425
|
+
*/
|
|
426
|
+
function lutimes(path: PathLike, atime: string | number | Date, mtime: string | number | Date): Promise<void>;
|
|
427
|
+
|
|
418
428
|
/**
|
|
419
429
|
* Asynchronous fchown(2) - Change ownership of a file.
|
|
420
430
|
* @param handle A `FileHandle`.
|
node/fs.d.ts
CHANGED
|
@@ -427,6 +427,39 @@ declare module "fs" {
|
|
|
427
427
|
*/
|
|
428
428
|
export function lchownSync(path: PathLike, uid: number, gid: number): void;
|
|
429
429
|
|
|
430
|
+
/**
|
|
431
|
+
* Changes the access and modification times of a file in the same way as `fs.utimes()`,
|
|
432
|
+
* with the difference that if the path refers to a symbolic link, then the link is not
|
|
433
|
+
* dereferenced: instead, the timestamps of the symbolic link itself are changed.
|
|
434
|
+
* @param path A path to a file. If a URL is provided, it must use the `file:` protocol.
|
|
435
|
+
* @param atime The last access time. If a string is provided, it will be coerced to number.
|
|
436
|
+
* @param mtime The last modified time. If a string is provided, it will be coerced to number.
|
|
437
|
+
*/
|
|
438
|
+
export function lutimes(path: PathLike, atime: string | number | Date, mtime: string | number | Date, callback: NoParamCallback): void;
|
|
439
|
+
|
|
440
|
+
// NOTE: This namespace provides design-time support for util.promisify. Exported members do not exist at runtime.
|
|
441
|
+
export namespace lutimes {
|
|
442
|
+
/**
|
|
443
|
+
* Changes the access and modification times of a file in the same way as `fsPromises.utimes()`,
|
|
444
|
+
* with the difference that if the path refers to a symbolic link, then the link is not
|
|
445
|
+
* dereferenced: instead, the timestamps of the symbolic link itself are changed.
|
|
446
|
+
* @param path A path to a file. If a URL is provided, it must use the `file:` protocol.
|
|
447
|
+
* @param atime The last access time. If a string is provided, it will be coerced to number.
|
|
448
|
+
* @param mtime The last modified time. If a string is provided, it will be coerced to number.
|
|
449
|
+
*/
|
|
450
|
+
function __promisify__(path: PathLike, atime: string | number | Date, mtime: string | number | Date): Promise<void>;
|
|
451
|
+
}
|
|
452
|
+
|
|
453
|
+
/**
|
|
454
|
+
* Change the file system timestamps of the symbolic link referenced by `path`. Returns `undefined`,
|
|
455
|
+
* or throws an exception when parameters are incorrect or the operation fails.
|
|
456
|
+
* This is the synchronous version of `fs.lutimes()`.
|
|
457
|
+
* @param path A path to a file. If a URL is provided, it must use the `file:` protocol.
|
|
458
|
+
* @param atime The last access time. If a string is provided, it will be coerced to number.
|
|
459
|
+
* @param mtime The last modified time. If a string is provided, it will be coerced to number.
|
|
460
|
+
*/
|
|
461
|
+
export function lutimesSync(path: PathLike, atime: string | number | Date, mtime: string | number | Date): void;
|
|
462
|
+
|
|
430
463
|
/**
|
|
431
464
|
* Asynchronous chmod(2) - Change permissions of a file.
|
|
432
465
|
* @param path A path to a file. If a URL is provided, it must use the `file:` protocol.
|
node/globals.d.ts
CHANGED
|
@@ -541,6 +541,7 @@ declare namespace NodeJS {
|
|
|
541
541
|
interface Timer extends RefCounted {
|
|
542
542
|
hasRef(): boolean;
|
|
543
543
|
refresh(): this;
|
|
544
|
+
[Symbol.toPrimitive](): number;
|
|
544
545
|
}
|
|
545
546
|
|
|
546
547
|
interface Immediate extends RefCounted {
|
|
@@ -551,6 +552,7 @@ declare namespace NodeJS {
|
|
|
551
552
|
interface Timeout extends Timer {
|
|
552
553
|
hasRef(): boolean;
|
|
553
554
|
refresh(): this;
|
|
555
|
+
[Symbol.toPrimitive](): number;
|
|
554
556
|
}
|
|
555
557
|
|
|
556
558
|
type TypedArray = Uint8Array | Uint8ClampedArray | Uint16Array | Uint32Array | Int8Array | Int16Array | Int32Array | Float32Array | Float64Array;
|
node/http.d.ts
CHANGED
|
@@ -207,7 +207,9 @@ declare module "http" {
|
|
|
207
207
|
|
|
208
208
|
// https://github.com/nodejs/node/blob/master/lib/_http_client.js#L77
|
|
209
209
|
class ClientRequest extends OutgoingMessage {
|
|
210
|
-
aborted:
|
|
210
|
+
aborted: boolean;
|
|
211
|
+
host: string;
|
|
212
|
+
protocol: string;
|
|
211
213
|
|
|
212
214
|
constructor(url: string | URL | ClientRequestArgs, cb?: (res: IncomingMessage) => void);
|
|
213
215
|
|
|
@@ -372,6 +374,7 @@ declare module "http" {
|
|
|
372
374
|
class Agent {
|
|
373
375
|
maxFreeSockets: number;
|
|
374
376
|
maxSockets: number;
|
|
377
|
+
maxTotalSockets: number;
|
|
375
378
|
readonly freeSockets: NodeJS.ReadOnlyDict<Socket[]>;
|
|
376
379
|
readonly sockets: NodeJS.ReadOnlyDict<Socket[]>;
|
|
377
380
|
readonly requests: NodeJS.ReadOnlyDict<IncomingMessage[]>;
|
node/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@types/node",
|
|
3
|
-
"version": "14.14.
|
|
3
|
+
"version": "14.14.2",
|
|
4
4
|
"description": "TypeScript definitions for Node.js",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"contributors": [
|
|
@@ -246,6 +246,6 @@
|
|
|
246
246
|
},
|
|
247
247
|
"scripts": {},
|
|
248
248
|
"dependencies": {},
|
|
249
|
-
"typesPublisherContentHash": "
|
|
249
|
+
"typesPublisherContentHash": "62f78f9df1f7c9ffe432964d2b1c5f35197a03ed078462d1b663de35f91bd3c4",
|
|
250
250
|
"typeScriptVersion": "3.2"
|
|
251
251
|
}
|
node/process.d.ts
CHANGED
node/tls.d.ts
CHANGED
|
@@ -707,12 +707,14 @@ declare module "tls" {
|
|
|
707
707
|
*/
|
|
708
708
|
sessionIdContext?: string;
|
|
709
709
|
/**
|
|
710
|
-
* 48
|
|
710
|
+
* 48-bytes of cryptographically strong pseudo-random data.
|
|
711
|
+
* See Session Resumption for more information.
|
|
711
712
|
*/
|
|
712
713
|
ticketKeys?: Buffer;
|
|
713
714
|
/**
|
|
714
|
-
* The number of seconds after which a TLS session created by the
|
|
715
|
-
* will no longer be resumable.
|
|
715
|
+
* The number of seconds after which a TLS session created by the
|
|
716
|
+
* server will no longer be resumable. See Session Resumption for more
|
|
717
|
+
* information. Default: 300.
|
|
716
718
|
*/
|
|
717
719
|
sessionTimeout?: number;
|
|
718
720
|
}
|
|
@@ -738,7 +740,7 @@ declare module "tls" {
|
|
|
738
740
|
* @deprecated since v0.11.3 Use `tls.TLSSocket` instead.
|
|
739
741
|
*/
|
|
740
742
|
function createSecurePair(credentials?: SecureContext, isServer?: boolean, requestCert?: boolean, rejectUnauthorized?: boolean): SecurePair;
|
|
741
|
-
function createSecureContext(
|
|
743
|
+
function createSecureContext(options?: SecureContextOptions): SecureContext;
|
|
742
744
|
function getCiphers(): string[];
|
|
743
745
|
|
|
744
746
|
/**
|