Parse() public static method

Parse the Execute request type success response body.
public static Parse ( byte rawData ) : ExecuteSuccessResponseBody
rawData byte The raw data which is returned by server.
return ExecuteSuccessResponseBody
        /// <summary>
        /// Send ROP request through MAPI over HTTP
        /// </summary>
        /// <param name="rgbIn">ROP request buffer.</param>
        /// <param name="pcbOut">The maximum size of the rgbOut buffer to place response in.</param>
        /// <param name="rawData">The response payload bytes.</param>
        /// <returns>0 indicates success, other values indicate failure. </returns>
        public uint Execute(byte[] rgbIn, uint pcbOut, out byte[] rawData)
        {
            uint ret = 0;

            ExecuteRequestBody executeBody = new ExecuteRequestBody();

            // Client requests server to not compress or XOR payload of rgbOut and rgbAuxOut.
            executeBody.Flags         = 0x00000003;
            executeBody.RopBufferSize = (uint)rgbIn.Length;
            executeBody.RopBuffer     = rgbIn;

            // Set the max size of the rgbAuxOut
            executeBody.MaxRopOut           = pcbOut; // 0x10008;
            executeBody.AuxiliaryBufferSize = 0;
            executeBody.AuxiliaryBuffer     = new byte[] { };

            HttpWebResponse response = SendMAPIHttpRequest(
                this.site,
                this.mailStoreUrl,
                this.userName,
                this.domain,
                this.userPassword,
                executeBody,
                "Execute",
                this.cookies);

            string responseCode = response.Headers["X-ResponseCode"];

            byte[] rawBuffer = ReadHttpResponse(response);
            response.GetResponseStream().Close();

            if (int.Parse(responseCode) == 0)
            {
                ChunkedResponse chunkedResponse = ChunkedResponse.ParseChunkedResponse(rawBuffer);

                ExecuteSuccessResponseBody responseSuccess = ExecuteSuccessResponseBody.Parse(chunkedResponse.ResponseBodyRawData);

                rawData = responseSuccess.RopBuffer;
                ret     = responseSuccess.ErrorCode;
            }
            else
            {
                rawData = null;
                this.site.Assert.Fail("MAPIHTTP call failed, the error code returned from server is: {0}", responseCode);
            }

            this.cookies = response.Cookies;
            return(ret);
        }