protected override void DoStart() { base.DoStart(); m_ClientSites = new Registry <clientSiteState>(); m_Listener = Binding.SocketFactory.MakeListener(this, new IPEndPoint(m_IPAddress, m_Port), socketReceiveAction); }
protected override void DoWaitForCompleteStop() { if (m_Listener != null) { m_Listener.Dispose(); m_Listener = null; } m_ClientSites = null; }
protected internal MpxServerSocket(MpxListener listener, IPEndPoint clientEndPoint, ClientSite clientSite, MpxSocketReceiveAction <MpxServerTransport> receiveAction ) : base(listener.Transport, clientEndPoint, clientSite, receiveAction) { m_Listener = listener; listener.Transport.ClientSiteConnected(this); }
internal MpxWinServerSocket(MpxListener listener, TcpClient client, ClientSite clientSite, MpxSocketReceiveAction <MpxServerTransport> receiveAction ) : base(listener, (IPEndPoint)client.Client.RemoteEndPoint, clientSite, receiveAction) { m_Client = client; m_Socket = m_Client.Client; m_RArgs = new SocketState(m_Client.Client, m_ReceiveChunk.GetBuffer()); m_RArgs.Completed += socketCallback; initiateReceive(); }