Microsoft.Protocols.TestSuites.MS_OXCMAPIHTTP.S02_RequestTypesForAddressBookServerEndpoint.Bind C# (CSharp) Method

Bind() private method

Initiate a session between the client and the server.
private Bind ( ) : void
return void
        private void Bind()
        {
            STAT stat = new STAT();
            stat.InitiateStat();

            uint flags = 0x0;
            BindRequestBody bindRequestBody = new BindRequestBody();
            bindRequestBody.State = stat;
            bindRequestBody.Flags = flags;
            bindRequestBody.HasState = true;
            byte[] auxIn = new byte[] { };
            bindRequestBody.AuxiliaryBuffer = auxIn;
            bindRequestBody.AuxiliaryBufferSize = (uint)auxIn.Length;

            int responseCode;
            BindResponseBody bindResponseBody = this.Adapter.Bind(bindRequestBody, out responseCode);
            Site.Assert.AreEqual<uint>((uint)0, bindResponseBody.ErrorCode, "Bind operation should succeed and 0 is expected to be returned. The return value is {0}.", bindResponseBody.ErrorCode);
        }