예제 #1
0
        /// <summary>
        /// Stop the server.
        /// </summary>
        public void Stop()
        {
            try
            {
                // Stop the server.
                if (_server != null)
                {
                    _server.Stop();
                }
            }
            catch { }
            finally
            {
                if (_server != null)
                {
                    _server.Dispose();
                }

                if (_clients != null)
                {
                    CloseClients();
                }

                _server  = null;
                _clients = null;
            }
        }
예제 #2
0
 /// <summary>
 /// Stop the server listener.
 /// </summary>
 public void Stop()
 {
     _server.Stop();
 }