You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
> method form `signal:start_oneshot(signum, callback)`
1222
+
> method form `signal:start_oneshot(signame, callback)`
1127
1223
1128
1224
**Parameters:**
1129
1225
-`signal`: `uv_signal_t userdata`
1130
-
-`signum`: `integer` or `string`
1226
+
-`signame`: `string` or `integer`
1131
1227
-`callback`: `callable`
1132
-
-`signum`: `string`
1228
+
-`signame`: `string`
1133
1229
1134
1230
Same functionality as `uv.signal_start()` but the signal handler is reset the moment the signal is received.
1135
1231
1232
+
See [Constants][] for supported `signame` input and output values.
1233
+
1136
1234
**Returns:**`0` or `fail`
1137
1235
1138
1236
### `uv.signal_stop(signal)`
@@ -1274,28 +1372,32 @@ When the child process exits, `on_exit` is called with an exit code and signal.
1274
1372
1275
1373
**Returns:**`uv_process_t userdata`, `integer`
1276
1374
1277
-
### `uv.process_kill(process, signum)`
1375
+
### `uv.process_kill(process, signame)`
1278
1376
1279
-
> method form `process:kill(signum)`
1377
+
> method form `process:kill(signame)`
1280
1378
1281
1379
**Parameters:**
1282
1380
-`process`: `uv_process_t userdata`
1283
-
-`signum`: `integer` or `string` or `nil` (default: `sigterm`)
1381
+
-`signame`: `string` or `integer` or `nil` (default: `sigterm`)
1284
1382
1285
1383
Sends the specified signal to the given process handle. Check the documentation
1286
1384
on `uv_signal_t` for signal support, specially on Windows.
1287
1385
1386
+
See [Constants][] for supported `signame` input values.
1387
+
1288
1388
**Returns:**`0` or `fail`
1289
1389
1290
-
### `uv.kill(pid, signum)`
1390
+
### `uv.kill(pid, signame)`
1291
1391
1292
1392
**Parameters:**
1293
1393
-`pid`: `integer`
1294
-
-`signum`: `integer` or `string` or `nil` (default: `sigterm`)
1394
+
-`signame`: `string` or `integer` or `nil` (default: `sigterm`)
1295
1395
1296
1396
Sends the specified signal to the given PID. Check the documentation on
1297
1397
`uv_signal_t` for signal support, specially on Windows.
1298
1398
1399
+
See [Constants][] for supported `signame` input values.
1400
+
1299
1401
**Returns:**`0` or `fail`
1300
1402
1301
1403
### `uv.process_get_pid(process)`
@@ -1549,11 +1651,12 @@ TCP handles are used to represent both TCP streams and servers.
1549
1651
### `uv.new_tcp([flags])`
1550
1652
1551
1653
**Parameters:**
1552
-
-`flags`: `string` or `nil`
1654
+
-`flags`: `string` or `integer` or `nil`
1553
1655
1554
1656
Creates and initializes a new `uv_tcp_t`. Returns the Lua userdata wrapping it.
1555
-
Flags may be a family string: `"unix"`, `"inet"`, `"inet6"`, `"ipx"`,
1556
-
`"netlink"`, `"x25"`, `"ax25"`, `"atmpvc"`, `"appletalk"`, or `"packet"`.
1657
+
1658
+
If set, `flags` must be a valid address family. See [Constants][] for supported
1659
+
address family input values.
1557
1660
1558
1661
**Returns:**`uv_tcp_t userdata` or `fail`
1559
1662
@@ -1649,6 +1752,8 @@ later using `uv.tcp_getsockname()`.
1649
1752
1650
1753
Get the address of the peer connected to the handle.
1651
1754
1755
+
See [Constants][] for supported address `family` output values.
1756
+
1652
1757
**Returns:**`table` or `fail`
1653
1758
-`ip` : `string`
1654
1759
-`family` : `string`
@@ -1663,6 +1768,8 @@ Get the address of the peer connected to the handle.
1663
1768
1664
1769
Get the current address to which the handle is bound.
1665
1770
1771
+
See [Constants][] for supported address `family` output values.
1772
+
1666
1773
**Returns:**`table` or `fail`
1667
1774
-`ip` : `string`
1668
1775
-`family` : `string`
@@ -1723,8 +1830,7 @@ and `uv.tcp_close_reset()` calls is not allowed.
1723
1830
1724
1831
Create a pair of connected sockets with the specified properties. The resulting handles can be passed to `uv.tcp_open`, used with `uv.spawn`, or for any other purpose.
1725
1832
1726
-
When specified as a string, `socktype` must be one of `"stream"`, `"dgram"`, `"raw"`,
1727
-
`"rdm"`, or `"seqpacket"`.
1833
+
See [Constants][] for supported `socktype` input values.
1728
1834
1729
1835
When `protocol` is set to 0 or nil, it will be automatically chosen based on the socket's domain and type. When `protocol` is specified as a string, it will be looked up using the `getprotobyname(3)` function (examples: `"ip"`, `"icmp"`, `"tcp"`, `"udp"`, etc).
1730
1836
@@ -2059,16 +2165,11 @@ This function is not thread safe on systems that don’t support ioctl TIOCGPTN
2059
2165
2060
2166
**Parameters:**
2061
2167
-`tty`: `uv_tty_t userdata`
2062
-
-`mode`: `integer`
2168
+
-`mode`: `string` or `integer`
2063
2169
2064
2170
Set the TTY using the specified terminal mode.
2065
2171
2066
-
Parameter `mode` is a C enum with the following values:
0 commit comments