コード例 #1
0
 public void Dispose(int timeoutMs = 500)
 {
     _webExchange.Abort();
     if (_thread != null)
     {
         _thread.Shutdown(timeoutMs);
     }
     _thread = null;
 }
コード例 #2
0
 public Status Dispose()
 {
     if (_running)
     {
         _running = false;
         bool success = _runningThread.Shutdown(2000);
         if (!success)
         {
             _runningThread.Abort();
             return(Status.Aborted);
         }
     }
     return(Status.Ok);
 }