Beispiel #1
0
        /// <summary>
        /// Stops the discovery.
        /// </summary>
        public void StopDiscovery()
        {
            Stopped = true;
            RetryTimer?.Dispose();
            RetryTimer = null;

            foreach (var udpClient in UdpSendClients)
            {
                udpClient.Close();
            }
        }
Beispiel #2
0
 public void Stop()
 {
     try
     {
         RetryTimer.Dispose();
         NetworkClient.Close();
     }
     catch
     {
     }
 }
Beispiel #3
0
        /// <summary>
        /// Stops the discovery.
        /// </summary>
        public void StopDiscovery()
        {
            Stopped = true;

            if (UdpClient != null)
            {
                UdpClient.Close();
                UdpClient = null;
            }

            if (RetryTimer != null)
            {
                RetryTimer.Dispose();
                RetryTimer = null;
            }
        }