Microsoft.Protocols.TestTools.StackSdk.BranchCache.Pchc.PCHCServer.ReceiveHttpRequest C# (CSharp) Method

ReceiveHttpRequest() private method

THe handle for the received http request event.
private ReceiveHttpRequest ( object sender, HttpRequestEventArg e ) : void
sender object The sender.
e Microsoft.Protocols.TestTools.StackSdk.CommonStack.HttpRequestEventArg THe http request event.
return void
        private void ReceiveHttpRequest(object sender, HttpRequestEventArg e)
        {
            lock (this.locker)
            {
                HttpListenerRequest request = e.ListenerContext.Request;
                this.DecomposeHttpRequest(request);
                PCHC_MESSAGE_TYPE msgType = DecodeMessage.GetMessageType(this.httpRequestPayload);
                if (msgType == PCHC_MESSAGE_TYPE.INITIAL_OFFER_MESSAGE)
                {
                    lock (this.initialQueue)
                    {
                        this.initialQueue.Enqueue(e.ListenerContext);
                    }
                }
                else if (msgType == PCHC_MESSAGE_TYPE.SEGMENT_INFO_MESSAGE)
                {
                    lock (this.segmentQueue)
                    {
                        this.segmentQueue.Enqueue(e.ListenerContext);
                    }
                }
            }
        }