[][src]Module runtime::net::tcp

Asynchronous TCP bindings.

Connecting to an address over TCP is done by using TcpStream::connect. This returns a Connect future which resolves to a TcpStream.

To listen for incoming TCP connections use TcpListener.bind, which creates a new TcpListener. Then use the the incoming method to accept new connections, yielding a stream of TcpStreams.

Structs

Accept

The future returned by TcpStream::accept.

Connect

The future returned by TcpStream::connect.

Incoming

A stream that infinitely accepts connections on a TcpListener.

TcpListener

A TCP socket server, listening for connections.

TcpStream

A TCP stream between a local and a remote socket.