C# IPEndPoint IPEndPoint(IPAddress, Int32)
Description
IPEndPoint IPEndPoint(IPAddress, Int32)
Initializes
a new instance of the IPEndPoint class with the specified address and port
number.
Syntax
IPEndPoint.IPEndPoint(IPAddress, Int32)
has the following syntax.
public IPEndPoint(
IPAddress address,
int port
)
Parameters
IPEndPoint.IPEndPoint(IPAddress, Int32)
has the following parameters.
address
- An IPAddress.port
- The port number associated with the address, or 0 to specify any available port. port is in host order.
Example
using System;/* w w w. j a v a 2 s. c om*/
using System.Net;
using System.Net.Sockets;
public class Example
{
public static void Main()
{
IPEndPoint endpoint = new IPEndPoint(IPAddress.Any, 80);
}
}