コード例 #1
0
ファイル: Binding.cs プロジェクト: yisea123/NETMF-LPC
        /// <summary>
        /// Sends a one-way DPWS request to the remote endpoint.
        /// </summary>
        /// <param name="request">One-way request message</param>
        public void RequestOneWay(WsMessage request)
        {
            // Clone binding context so that properties added by the send/receive
            // do not persist beyond this request
            BindingContext ctx = m_context.Clone();

            SendMessage(request, ctx);
        }
コード例 #2
0
ファイル: Binding.cs プロジェクト: leeholder/Netduino_SDK
        /// <summary>
        /// Extracts the request from the channel
        /// </summary>
        /// <returns>The Context of the request.</returns>
        public RequestContext ReceiveRequest()
        {
            // Clone binding context so that properties added by the send/receive
            // do not persist beyond this request
            BindingContext ctx = m_context.Clone();

            WsMessage msg = ReceiveMessage(ctx);

            if (msg != null)
            {
                return(new RequestContext(msg, this, ctx));
            }

            return(null);
        }