public int SendAsyncRequest(ProxyOutgoingAsyncBase outAsync) { lock (this) { if (!_initialized) { outAsync.Cancelable(this); // This will throw if the request is canceled } if (!Initialized()) { _requests.AddLast(outAsync); return(OutgoingAsyncBase.AsyncStatusQueued); } } Debug.Assert(_connection != null); return(outAsync.InvokeRemote(_connection, _compress, _response)); }
public void SendAsyncRequest(ProxyOutgoingAsyncBase outAsync) { lock (this) { if (!_initialized) { outAsync.Cancelable(this); // This will throw if the request is canceled } if (!Initialized()) { _requests.AddLast(outAsync); return; } } Debug.Assert(_connection != null); outAsync.InvokeRemote(_connection, _compress, !outAsync.IsOneway); }