aboutsummaryrefslogtreecommitdiff
path: root/doc/api/http.md
diff options
context:
space:
mode:
Diffstat (limited to 'doc/api/http.md')
-rw-r--r--doc/api/http.md13
1 files changed, 5 insertions, 8 deletions
diff --git a/doc/api/http.md b/doc/api/http.md
index f69ac11274..dab18b5539 100644
--- a/doc/api/http.md
+++ b/doc/api/http.md
@@ -662,12 +662,11 @@ added: v0.5.9
* `timeout` {number} Milliseconds before a request times out.
* `callback` {Function} Optional function to be called when a timeout occurs.
Same as binding to the `timeout` event.
+* Returns: {http.ClientRequest}
Once a socket is assigned to this request and is connected
[`socket.setTimeout()`][] will be called.
-Returns `request`.
-
### request.socket
<!-- YAML
added: v0.3.0
@@ -706,6 +705,7 @@ added: v0.1.29
* `chunk` {string|Buffer}
* `encoding` {string}
* `callback` {Function}
+* Returns: {boolean}
Sends a chunk of the body. By calling this method
many times, a request body can be sent to a
@@ -928,6 +928,7 @@ added: v0.9.12
* `msecs` {number} **Default:** `120000` (2 minutes)
* `callback` {Function}
+* Returns: {http.Server}
Sets the timeout value for sockets, and emits a `'timeout'` event on
the Server object, passing the socket as an argument, if a timeout
@@ -940,8 +941,6 @@ By default, the Server's timeout value is 2 minutes, and sockets are
destroyed automatically if they time out. However, if a callback is assigned
to the Server's `'timeout'` event, timeouts must be handled explicitly.
-Returns `server`.
-
### server.timeout
<!-- YAML
added: v0.9.12
@@ -1248,6 +1247,7 @@ added: v0.9.12
* `msecs` {number}
* `callback` {Function}
+* Returns: {http.ServerResponse}
Sets the Socket's timeout value to `msecs`. If a callback is
provided, then it is added as a listener on the `'timeout'` event on
@@ -1258,8 +1258,6 @@ the server, then sockets are destroyed when they time out. If a handler is
assigned to the request, the response, or the server's `'timeout'` events,
timed out sockets must be handled explicitly.
-Returns `response`.
-
### response.socket
<!-- YAML
added: v0.3.0
@@ -1579,11 +1577,10 @@ added: v0.5.9
* `msecs` {number}
* `callback` {Function}
+* Returns: {http.IncomingMessage}
Calls `message.connection.setTimeout(msecs, callback)`.
-Returns `message`.
-
### message.socket
<!-- YAML
added: v0.3.0