/// <summary> /// Sets the callback used to receive notifications of new events. /// </summary> public void SetRequestReceivedCallback(TcpChannelRequestEventHandler callback) { lock (DataLock) { m_RequestReceived = callback; } }
internal UaTcpReplyChannel( ChannelManagerBase manager, string listenerId, EndpointAddress address, TcpServerChannel channel, TcpChannelQuotas quotas) : base(manager) { m_listenerId = listenerId; m_address = address; m_channel = channel; m_quotas = quotas; m_requestQueue = new Queue <RequestContext>(); m_operationQueue = new Queue <TcpAsyncOperation <RequestContext> >(); m_RequestReceivedCallback = new TcpChannelRequestEventHandler(OnRequestReceived); // register for notifications. m_channel.SetRequestReceivedCallback(m_RequestReceivedCallback); }