TcpConnection.adopt

AdoptResult adopt(ref EventLoop loop, Handle clientHandle) @trusted nothrow

Adopt an already-accepted client socket.

On success, EVE takes ownership of clientHandle and the caller must not close it. On failure, ownership remains with the caller.

Parameters

loopEvent loop to register with.
clientHandleSocket handle from accept.

Returns

AdoptResult.OK on success, or an error variant.