Microsoft.Protocols.TestTools.StackSdk.BranchCache.Pchc.PCHCServer.CreateResponseMessage C# (CSharp) 메소드

CreateResponseMessage() 공개 메소드

Create pchc response message.
public CreateResponseMessage ( RESPONSE_CODE responseCode ) : RESPONSE_MESSAGE
responseCode RESPONSE_CODE /// The response code indicates the hosted cache server response to the client request message ///
리턴 RESPONSE_MESSAGE
        public RESPONSE_MESSAGE CreateResponseMessage(RESPONSE_CODE responseCode)
        {
            RESPONSE_MESSAGE responseMessage;

            // Size (4 bytes):  Total message size in bytes, excluding this field.
            // ResponseCode (1 byte):  A code that indicates the server response to the client request message.
            responseMessage.TransportHeader.Size = 1;
            responseMessage.ResponseCode = responseCode;

            if (this.logger != null)
            {
                this.logger.AddDebug(string.Format(
                    "Pchc response message is created with reposne code: {0}",
                    (RESPONSE_CODE)responseCode));
            }

            return responseMessage;
        }