Beispiel #1
0
        public IClientChannelSink CreateSink(IChannelSender channel, string url, object remoteChannelData)
        {
            IClientChannelSink nextSink = null;

            if (this._next != null)
            {
                nextSink = this._next.CreateSink(channel, url, remoteChannelData);
                if (nextSink == null)
                {
                    return(null);
                }
            }
            SinkChannelProtocol protocol = CoreChannel.DetermineChannelProtocol(channel);

            return(new BinaryClientFormatterSink(nextSink)
            {
                IncludeVersioning = this._includeVersioning, StrictBinding = this._strictBinding, ChannelProtocol = protocol
            });
        }
        public IClientChannelSink CreateSink(IChannelSender channel, String url,
                                             Object remoteChannelData)
        {
            IClientChannelSink nextSink = null;

            if (_next != null)
            {
                nextSink = _next.CreateSink(channel, url, remoteChannelData);
                if (nextSink == null)
                {
                    return(null);
                }
            }

            SinkChannelProtocol protocol = CoreChannel.DetermineChannelProtocol(channel);

            BinaryClientFormatterSink sink = new BinaryClientFormatterSink(nextSink);

            sink.IncludeVersioning = _includeVersioning;
            sink.StrictBinding     = _strictBinding;
            sink.ChannelProtocol   = protocol;
            return(sink);
        } // CreateSink