System.Net.Sockets.TcpClient.ConnectAsync C# (CSharp) Méthode

ConnectAsync() public méthode

public ConnectAsync ( IPAddress address, int port ) : System.Threading.Tasks.Task
address IPAddress
port int
Résultat System.Threading.Tasks.Task
        public Task ConnectAsync(IPAddress address, int port) => ConnectAsyncCore(address, port);

Same methods

TcpClient::ConnectAsync ( string host, int port ) : System.Threading.Tasks.Task

Usage Example

Exemple #1
0
	    public async Task<TcpClient> ConnectAsync(string hostname, int port)
	    {
	        TcpClient client = new TcpClient();
	        await client.ConnectAsync(hostname, port);
	        DoHandshake(client, hostname, port);
	        return client;
	    } 
All Usage Examples Of System.Net.Sockets.TcpClient::ConnectAsync