Exemplo n.º 1
0
 /// <inheritdoc />
 protected override void Dispose(bool disposing)
 {
     sender.Dispose();
     connector.Dispose();
     base.Dispose(disposing);
     connectSocketArgs.Dispose();
     sendSocketArgs.Dispose();
     receiveSocketArgs.Dispose();
 }
Exemplo n.º 2
0
 private void ReconnectTimer_Elapsed(object sender, ElapsedEventArgs e)
 {
     if (Program.AppSettingsClient.ReconnectMinutsInterval == 0)
     {
         return;
     }
     try
     {
         if (_rnd.Next(Program.AppSettingsClient.ReconnectMinutsInterval) == 0)
         {
             _clientConnector.Dispose();
             InitClientConnector();
         }
     }
     catch (Exception ex) { }
 }
        public override void Dispose()
        {
            base.Dispose();

            Connector.Dispose();
        }