@types/node 12.12.10 → 12.12.11
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 +2 -2
- node/dgram.d.ts +31 -15
- node/index.d.ts +1 -0
- node/package.json +7 -2
node/README.md
CHANGED
|
@@ -8,9 +8,9 @@ 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: Tue, 19 Nov 2019 19:
|
|
11
|
+
* Last updated: Tue, 19 Nov 2019 19:44:54 GMT
|
|
12
12
|
* Dependencies: none
|
|
13
13
|
* Global values: `Buffer`, `NodeJS`, `Symbol`, `__dirname`, `__filename`, `clearImmediate`, `clearInterval`, `clearTimeout`, `console`, `exports`, `global`, `module`, `process`, `queueMicrotask`, `require`, `setImmediate`, `setInterval`, `setTimeout`
|
|
14
14
|
|
|
15
15
|
# Credits
|
|
16
|
-
These definitions were written by Microsoft TypeScript (https://github.com/Microsoft), DefinitelyTyped (https://github.com/DefinitelyTyped), Alberto Schiabel (https://github.com/jkomyno), Alexander T. (https://github.com/a-tarasyuk), Alvis HT Tang (https://github.com/alvis), Andrew Makarov (https://github.com/r3nya), Benjamin Toueg (https://github.com/btoueg), Bruno Scheufler (https://github.com/brunoscheufler), Chigozirim C. (https://github.com/smac89), Christian Vaagland Tellnes (https://github.com/tellnes), David Junger (https://github.com/touffy), Deividas Bakanas (https://github.com/DeividasBakanas), Eugene Y. Q. Shen (https://github.com/eyqs), Flarna (https://github.com/Flarna), Hannes Magnusson (https://github.com/Hannes-Magnusson-CK), Hoàng Văn Khải (https://github.com/KSXGitHub), Huw (https://github.com/hoo29), Kelvin Jin (https://github.com/kjin), Klaus Meinhardt (https://github.com/ajafff), Lishude (https://github.com/islishude), Mariusz Wiktorczyk (https://github.com/mwiktorczyk), Mohsen Azimi (https://github.com/mohsen1), Nicolas Even (https://github.com/n-e), Nicolas Voigt (https://github.com/octo-sniffle), Nikita Galkin (https://github.com/galkin), Parambir Singh (https://github.com/parambirs), Sebastian Silbermann (https://github.com/eps1lon), Simon Schick (https://github.com/SimonSchick), Thomas den Hollander (https://github.com/ThomasdenH), Wilco Bakker (https://github.com/WilcoBakker), wwwy3y3 (https://github.com/wwwy3y3), Zane Hannan AU (https://github.com/ZaneHannanAU), Samuel Ainsworth (https://github.com/samuela), Kyle Uehlein (https://github.com/kuehlein), Jordi Oliveras Rovira (https://github.com/j-oliveras), Thanik Bhongbhibhat (https://github.com/bhongy), Marcin Kopacz (https://github.com/chyzwar), Trivikram Kamat (https://github.com/trivikr),
|
|
16
|
+
These definitions were written by Microsoft TypeScript (https://github.com/Microsoft), DefinitelyTyped (https://github.com/DefinitelyTyped), Alberto Schiabel (https://github.com/jkomyno), Alexander T. (https://github.com/a-tarasyuk), Alvis HT Tang (https://github.com/alvis), Andrew Makarov (https://github.com/r3nya), Benjamin Toueg (https://github.com/btoueg), Bruno Scheufler (https://github.com/brunoscheufler), Chigozirim C. (https://github.com/smac89), Christian Vaagland Tellnes (https://github.com/tellnes), David Junger (https://github.com/touffy), Deividas Bakanas (https://github.com/DeividasBakanas), Eugene Y. Q. Shen (https://github.com/eyqs), Flarna (https://github.com/Flarna), Hannes Magnusson (https://github.com/Hannes-Magnusson-CK), Hoàng Văn Khải (https://github.com/KSXGitHub), Huw (https://github.com/hoo29), Kelvin Jin (https://github.com/kjin), Klaus Meinhardt (https://github.com/ajafff), Lishude (https://github.com/islishude), Mariusz Wiktorczyk (https://github.com/mwiktorczyk), Mohsen Azimi (https://github.com/mohsen1), Nicolas Even (https://github.com/n-e), Nicolas Voigt (https://github.com/octo-sniffle), Nikita Galkin (https://github.com/galkin), Parambir Singh (https://github.com/parambirs), Sebastian Silbermann (https://github.com/eps1lon), Simon Schick (https://github.com/SimonSchick), Thomas den Hollander (https://github.com/ThomasdenH), Wilco Bakker (https://github.com/WilcoBakker), wwwy3y3 (https://github.com/wwwy3y3), Zane Hannan AU (https://github.com/ZaneHannanAU), Samuel Ainsworth (https://github.com/samuela), Kyle Uehlein (https://github.com/kuehlein), Jordi Oliveras Rovira (https://github.com/j-oliveras), Thanik Bhongbhibhat (https://github.com/bhongy), Marcin Kopacz (https://github.com/chyzwar), Trivikram Kamat (https://github.com/trivikr), Minh Son Nguyen (https://github.com/nguymin4), and Junxiao Shi (https://github.com/yoursunny).
|
node/dgram.d.ts
CHANGED
|
@@ -11,9 +11,10 @@ declare module "dgram" {
|
|
|
11
11
|
}
|
|
12
12
|
|
|
13
13
|
interface BindOptions {
|
|
14
|
-
port
|
|
14
|
+
port?: number;
|
|
15
15
|
address?: string;
|
|
16
16
|
exclusive?: boolean;
|
|
17
|
+
fd?: number;
|
|
17
18
|
}
|
|
18
19
|
|
|
19
20
|
type SocketType = "udp4" | "udp6";
|
|
@@ -34,67 +35,82 @@ declare module "dgram" {
|
|
|
34
35
|
function createSocket(options: SocketOptions, callback?: (msg: Buffer, rinfo: RemoteInfo) => void): Socket;
|
|
35
36
|
|
|
36
37
|
class Socket extends events.EventEmitter {
|
|
37
|
-
|
|
38
|
-
|
|
38
|
+
addMembership(multicastAddress: string, multicastInterface?: string): void;
|
|
39
|
+
address(): AddressInfo;
|
|
39
40
|
bind(port?: number, address?: string, callback?: () => void): void;
|
|
40
41
|
bind(port?: number, callback?: () => void): void;
|
|
41
42
|
bind(callback?: () => void): void;
|
|
42
43
|
bind(options: BindOptions, callback?: () => void): void;
|
|
43
44
|
close(callback?: () => void): void;
|
|
44
|
-
address()
|
|
45
|
+
connect(port: number, address?: string, callback?: () => void): void;
|
|
46
|
+
connect(port: number, callback: () => void): void;
|
|
47
|
+
disconnect(): void;
|
|
48
|
+
dropMembership(multicastAddress: string, multicastInterface?: string): void;
|
|
49
|
+
getRecvBufferSize(): number;
|
|
50
|
+
getSendBufferSize(): number;
|
|
51
|
+
ref(): this;
|
|
52
|
+
remoteAddress(): AddressInfo;
|
|
53
|
+
send(msg: string | Uint8Array | any[], port?: number, address?: string, callback?: (error: Error | null, bytes: number) => void): void;
|
|
54
|
+
send(msg: string | Uint8Array | any[], port?: number, callback?: (error: Error | null, bytes: number) => void): void;
|
|
55
|
+
send(msg: string | Uint8Array | any[], callback?: (error: Error | null, bytes: number) => void): void;
|
|
56
|
+
send(msg: string | Uint8Array, offset: number, length: number, port?: number, address?: string, callback?: (error: Error | null, bytes: number) => void): void;
|
|
57
|
+
send(msg: string | Uint8Array, offset: number, length: number, port?: number, callback?: (error: Error | null, bytes: number) => void): void;
|
|
58
|
+
send(msg: string | Uint8Array, offset: number, length: number, callback?: (error: Error | null, bytes: number) => void): void;
|
|
45
59
|
setBroadcast(flag: boolean): void;
|
|
46
|
-
setTTL(ttl: number): void;
|
|
47
|
-
setMulticastTTL(ttl: number): void;
|
|
48
60
|
setMulticastInterface(multicastInterface: string): void;
|
|
49
61
|
setMulticastLoopback(flag: boolean): void;
|
|
50
|
-
|
|
51
|
-
dropMembership(multicastAddress: string, multicastInterface?: string): void;
|
|
52
|
-
ref(): this;
|
|
53
|
-
unref(): this;
|
|
62
|
+
setMulticastTTL(ttl: number): void;
|
|
54
63
|
setRecvBufferSize(size: number): void;
|
|
55
64
|
setSendBufferSize(size: number): void;
|
|
56
|
-
|
|
57
|
-
|
|
65
|
+
setTTL(ttl: number): void;
|
|
66
|
+
unref(): this;
|
|
58
67
|
|
|
59
68
|
/**
|
|
60
69
|
* events.EventEmitter
|
|
61
70
|
* 1. close
|
|
62
|
-
* 2.
|
|
63
|
-
* 3.
|
|
64
|
-
* 4.
|
|
71
|
+
* 2. connect
|
|
72
|
+
* 3. error
|
|
73
|
+
* 4. listening
|
|
74
|
+
* 5. message
|
|
65
75
|
*/
|
|
66
76
|
addListener(event: string, listener: (...args: any[]) => void): this;
|
|
67
77
|
addListener(event: "close", listener: () => void): this;
|
|
78
|
+
addListener(event: "connect", listener: () => void): this;
|
|
68
79
|
addListener(event: "error", listener: (err: Error) => void): this;
|
|
69
80
|
addListener(event: "listening", listener: () => void): this;
|
|
70
81
|
addListener(event: "message", listener: (msg: Buffer, rinfo: RemoteInfo) => void): this;
|
|
71
82
|
|
|
72
83
|
emit(event: string | symbol, ...args: any[]): boolean;
|
|
73
84
|
emit(event: "close"): boolean;
|
|
85
|
+
emit(event: "connect"): boolean;
|
|
74
86
|
emit(event: "error", err: Error): boolean;
|
|
75
87
|
emit(event: "listening"): boolean;
|
|
76
88
|
emit(event: "message", msg: Buffer, rinfo: RemoteInfo): boolean;
|
|
77
89
|
|
|
78
90
|
on(event: string, listener: (...args: any[]) => void): this;
|
|
79
91
|
on(event: "close", listener: () => void): this;
|
|
92
|
+
on(event: "connect", listener: () => void): this;
|
|
80
93
|
on(event: "error", listener: (err: Error) => void): this;
|
|
81
94
|
on(event: "listening", listener: () => void): this;
|
|
82
95
|
on(event: "message", listener: (msg: Buffer, rinfo: RemoteInfo) => void): this;
|
|
83
96
|
|
|
84
97
|
once(event: string, listener: (...args: any[]) => void): this;
|
|
85
98
|
once(event: "close", listener: () => void): this;
|
|
99
|
+
once(event: "connect", listener: () => void): this;
|
|
86
100
|
once(event: "error", listener: (err: Error) => void): this;
|
|
87
101
|
once(event: "listening", listener: () => void): this;
|
|
88
102
|
once(event: "message", listener: (msg: Buffer, rinfo: RemoteInfo) => void): this;
|
|
89
103
|
|
|
90
104
|
prependListener(event: string, listener: (...args: any[]) => void): this;
|
|
91
105
|
prependListener(event: "close", listener: () => void): this;
|
|
106
|
+
prependListener(event: "connect", listener: () => void): this;
|
|
92
107
|
prependListener(event: "error", listener: (err: Error) => void): this;
|
|
93
108
|
prependListener(event: "listening", listener: () => void): this;
|
|
94
109
|
prependListener(event: "message", listener: (msg: Buffer, rinfo: RemoteInfo) => void): this;
|
|
95
110
|
|
|
96
111
|
prependOnceListener(event: string, listener: (...args: any[]) => void): this;
|
|
97
112
|
prependOnceListener(event: "close", listener: () => void): this;
|
|
113
|
+
prependOnceListener(event: "connect", listener: () => void): this;
|
|
98
114
|
prependOnceListener(event: "error", listener: (err: Error) => void): this;
|
|
99
115
|
prependOnceListener(event: "listening", listener: () => void): this;
|
|
100
116
|
prependOnceListener(event: "message", listener: (msg: Buffer, rinfo: RemoteInfo) => void): this;
|
node/index.d.ts
CHANGED
|
@@ -39,6 +39,7 @@
|
|
|
39
39
|
// Marcin Kopacz <https://github.com/chyzwar>
|
|
40
40
|
// Trivikram Kamat <https://github.com/trivikr>
|
|
41
41
|
// Minh Son Nguyen <https://github.com/nguymin4>
|
|
42
|
+
// Junxiao Shi <https://github.com/yoursunny>
|
|
42
43
|
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
|
43
44
|
|
|
44
45
|
// NOTE: These definitions support NodeJS and TypeScript 3.2.
|
node/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@types/node",
|
|
3
|
-
"version": "12.12.
|
|
3
|
+
"version": "12.12.11",
|
|
4
4
|
"description": "TypeScript definitions for Node.js",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"contributors": [
|
|
@@ -198,6 +198,11 @@
|
|
|
198
198
|
"name": "Minh Son Nguyen",
|
|
199
199
|
"url": "https://github.com/nguymin4",
|
|
200
200
|
"githubUsername": "nguymin4"
|
|
201
|
+
},
|
|
202
|
+
{
|
|
203
|
+
"name": "Junxiao Shi",
|
|
204
|
+
"url": "https://github.com/yoursunny",
|
|
205
|
+
"githubUsername": "yoursunny"
|
|
201
206
|
}
|
|
202
207
|
],
|
|
203
208
|
"main": "",
|
|
@@ -216,6 +221,6 @@
|
|
|
216
221
|
},
|
|
217
222
|
"scripts": {},
|
|
218
223
|
"dependencies": {},
|
|
219
|
-
"typesPublisherContentHash": "
|
|
224
|
+
"typesPublisherContentHash": "db8a3e1fadc482615dd04e1c1d0d26eca954d792aed008eac14078e02f14e87b",
|
|
220
225
|
"typeScriptVersion": "2.8"
|
|
221
226
|
}
|