public void Dispose() { Entry.Dispose(); _AgentUpdater.Stop(); _Service.Leave(_Agent); _Service.Dispose(); }
void IDisposable.Dispose() { _ThreadUpdater.Stop(); _Updater.Shutdown(); lock (_Users) { _Users.Clear(); } }
public void Shutdown() { _Reader.DoneEvent -= _RequestPush; _Reader.Stop(); _Writer.Stop(); System.Threading.Interlocked.Add(ref _TotalResponse, -_Responses.Count); System.Threading.Interlocked.Add(ref _TotalRequest, -_Requests.Count); _Updater.Stop(); SendBreakEvent(); }
void _Shutdown() { _Reader.DoneEvent -= _RequestPush; _Reader.Stop(); _Writer.Stop(); _Updater.Stop(); RequestPackage req; while (_ExternalRequests.TryDequeue(out req)) { } System.Threading.Interlocked.Add(ref _TotalResponse, -_Responses.Count); System.Threading.Interlocked.Add(ref _TotalRequest, -_Requests.Count); _SendBreakEvent(); _Enable = false; }
void IDisposable.Dispose() { _Updater.Stop(); _Users.Shutdown(); }