Serializes endpoint information into a SocketAddress instance.
Imports System.IO
Imports System.Net
Imports System.Text
public class MainClass
Shared Sub Main()
Dim endpoint As New IPEndPoint(0, 0)
Dim socketAddress As SocketAddress = endpoint.Serialize()
Console.WriteLine("Endpoint Serialize() : " + socketAddress.ToString())
Console.WriteLine("Socket Family : " + socketAddress.Family.ToString())
Console.WriteLine("Socket Size : " + socketAddress.ToString())
End Sub
End Class
Related examples in the same category