TcpServer

An asynchronous TCP connection server.

Members

Functions

close
void close()

Stop listening on this socket.

listen
ushort listen(ushort port, string addr)
void listen(AddressInfo[] addressInfos)

Start listening on this socket.

Properties

handleAccept
void delegate(TcpConnection incoming) handleAccept [@property setter]

Callback for an incoming connection. Connections will not be accepted unless this handler is set.

handleAccept
void delegate(TcpConnection incoming) handleAccept [@property getter]

Callback for an incoming connection. Connections will not be accepted unless this handler is set.

isListening
bool isListening [@property getter]
Undocumented in source. Be warned that the author may not have intended to support it.
localAddresses
Address[] localAddresses [@property getter]
Undocumented in source. Be warned that the author may not have intended to support it.

Variables

handleClose
void delegate() handleClose;

Callback for when the socket was closed.

Meta