Added auto dc switching

This commit is contained in:
Ilya Pirozhneko 2016-01-27 14:02:18 +03:00
parent f56ffc7c6f
commit 824ba77e12
7 changed files with 179 additions and 132 deletions

View file

@ -8,12 +8,10 @@ namespace TLSharp.Core.Network
{
public class TcpTransport : IDisposable
{
private const string defaultConnectionAddress = "91.108.56.165";
private const int defaultConnectionPort = 443;
private readonly TcpClient _tcpClient;
private int sendCounter = 0;
public TcpTransport(string address = defaultConnectionAddress, int port = defaultConnectionPort)
public TcpTransport(string address, int port)
{
_tcpClient = new TcpClient();