Exemplo n.º 1
0
 public ExclusiveTcpTransportManager(ExclusiveTcpTransportManagerRegistration registration, TcpChannelListener channelListener, System.Net.IPAddress ipAddressAny, UriHostNameType ipHostNameType)
 {
     base.ApplyListenerSettings(channelListener);
     this.listenSocket = channelListener.GetListenSocket(ipHostNameType);
     if (this.listenSocket != null)
     {
         this.ipAddress = ((IPEndPoint)this.listenSocket.LocalEndPoint).Address;
     }
     else if (channelListener.Uri.HostNameType == ipHostNameType)
     {
         this.ipAddress = System.Net.IPAddress.Parse(channelListener.Uri.DnsSafeHost);
     }
     else
     {
         this.ipAddress = ipAddressAny;
     }
     this.listenBacklog = channelListener.ListenBacklog;
     this.registration  = registration;
 }
 public ExclusiveTcpTransportManager(ExclusiveTcpTransportManagerRegistration registration, TcpChannelListener channelListener, System.Net.IPAddress ipAddressAny, UriHostNameType ipHostNameType)
 {
     base.ApplyListenerSettings(channelListener);
     this.listenSocket = channelListener.GetListenSocket(ipHostNameType);
     if (this.listenSocket != null)
     {
         this.ipAddress = ((IPEndPoint) this.listenSocket.LocalEndPoint).Address;
     }
     else if (channelListener.Uri.HostNameType == ipHostNameType)
     {
         this.ipAddress = System.Net.IPAddress.Parse(channelListener.Uri.DnsSafeHost);
     }
     else
     {
         this.ipAddress = ipAddressAny;
     }
     this.listenBacklog = channelListener.ListenBacklog;
     this.registration = registration;
 }