Exemple #1
0
        public void Bind(IPEndPoint EndPoint)
        {
            if (EndPoint.AddressFamily == AddressFamily.InterNetwork)
            {
                EndPoint.Address = SocketUtilities.MapIPv4ToIPv6(EndPoint.Address);
            }

            LocalEndPoint = EndPoint;

            Socket.Bind(EndPoint);
        }
Exemple #2
0
        public void Connect(IPEndPoint EndPoint)
        {
            if (EndPoint.AddressFamily == AddressFamily.InterNetwork)
            {
                EndPoint.Address = SocketUtilities.MapIPv4ToIPv6(EndPoint.Address);
            }

            RemoteEndPoint = EndPoint;

            ConnectInternal(EndPoint);
        }