public IServerChannelSink CreateSink(IChannelReceiver channel) { if (null == channel) { throw new ArgumentNullException("channel"); } IServerChannelSink nextSink = null; if (_next != null) { nextSink = _next.CreateSink(channel); } BinaryServerFormatterSink.Protocol protocol = BinaryServerFormatterSink.Protocol.Other; // see if this is an http channel String uri = channel.GetUrlsForUri("")[0]; if (String.Compare("http", 0, uri, 0, 4, StringComparison.OrdinalIgnoreCase) == 0) { protocol = BinaryServerFormatterSink.Protocol.Http; } BinaryServerFormatterSink sink = new BinaryServerFormatterSink(protocol, nextSink, channel); sink.TypeFilterLevel = _formatterSecurityLevel; sink.IncludeVersioning = _includeVersioning; sink.StrictBinding = _strictBinding; return(sink); } // CreateSink
public BinaryServerFormatterSink (BinaryServerFormatterSink.Protocol protocol, IServerChannelSink nextSink, IChannelReceiver receiver) { this.protocol = protocol; this.next_sink = nextSink; this.receiver = receiver; }
public IServerChannelSink CreateSink(IChannelReceiver channel) { IServerChannelSink next_sink = null; BinaryServerFormatterSink result; if (next != null) { next_sink = next.CreateSink(channel); } result = new BinaryServerFormatterSink(BinaryServerFormatterSink.Protocol.Other, next_sink, channel); result.BinaryCore = _binaryCore; return(result); }
public IServerChannelSink CreateSink(IChannelReceiver channel) { if(null == channel) { throw new ArgumentNullException("channel"); } IServerChannelSink nextSink = null; if (_next != null) nextSink = _next.CreateSink(channel); BinaryServerFormatterSink.Protocol protocol = BinaryServerFormatterSink.Protocol.Other; // see if this is an http channel String uri = channel.GetUrlsForUri("")[0]; if (String.Compare("http", 0, uri, 0, 4, StringComparison.OrdinalIgnoreCase) == 0) protocol = BinaryServerFormatterSink.Protocol.Http; BinaryServerFormatterSink sink = new BinaryServerFormatterSink(protocol, nextSink, channel); sink.TypeFilterLevel = _formatterSecurityLevel; sink.IncludeVersioning = _includeVersioning; sink.StrictBinding = _strictBinding; return sink; } // CreateSink
public IServerChannelSink CreateSink (IChannelReceiver channel) { IServerChannelSink next_sink = null; BinaryServerFormatterSink result; if (next != null) next_sink = next.CreateSink (channel); result = new BinaryServerFormatterSink (BinaryServerFormatterSink.Protocol.Other, next_sink, channel); result.BinaryCore = _binaryCore; return result; }