public Task StartAsync() { // TODO: Make idempotent _thread.Post(_startListeningCallback, this); return(_startedTcs.Task); }
public async Task <UvTcpConnection> ConnectAsync() { _thread.Post(_startConnect, this); var connection = await _connectTcs.Task; return(connection); }
public async Task <UvTcpConnection> ConnectAsync() { _thread.Post(_startConnect, this); var connection = await _connectTcs.Task; // Get back onto the current context await Task.Yield(); return(connection); }