net.createConnection(port[, host][, connectlistener])


初始化一个TCP连接

这个函数用默认配置创建一个新的net.Socket,然后socket.connect(port[, host][, connectListener])初始化一个连接,并返回开启连接的那个 net.Socket

Initiates a TCP connection.

This function creates a new net.Socket with all options set to default, immediately initiates connection with socket.connect(port[, host][, connectListener]), then returns the net.Socket that starts the connection.