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

            foreach (var udpClient in UdpSendClients)
            {
                udpClient.Close();
            }
        }
Exemple #2
0
 public void Stop()
 {
     try
     {
         RetryTimer.Dispose();
         NetworkClient.Close();
     }
     catch
     {
     }
 }
Exemple #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;
            }
        }