agent.createConnection()

agent.createConnection(options[, callback])

Produces a socket/stream to be used for HTTP requests.

By default, this function is the same as net.createConnection(). However, custom Agents may override this method in case greater flexibility is desired.

A socket/stream can be supplied in one of two ways: by returning the socket/stream from this function, or by passing the socket/stream to callback.

callback has a signature of (err, stream).

doc_Nodejs
2016-04-30 04:37:09
Comments
Leave a Comment

Please login to continue.