public object AfterReceiveRequest(ref Message request, IClientChannel channel, InstanceContext instanceContext)
 {
     AddressingVersionExtension.Activate(_version);
     //ResourceUriHeader.ReadFrom(request);
     //MaxEnvelopeSizeHeader.ReadFrom(request);
     return(null);
 }
Пример #2
0
        public ClientContext(Uri endpointUri, AddressingVersion addressingVersion, IChannelFactory <T> proxyFactory, AddressHeaderCreatorDelegate addressHeaderCreatorDelegate)
        {
            var builder = new EndpointAddressBuilder();

            addressHeaderCreatorDelegate(builder.Headers);
            builder.Uri = endpointUri;

            _channel = proxyFactory.CreateChannel(builder.ToEndpointAddress());
            _scope   = new OperationContextScope((IContextChannel)_channel);
            AddressingVersionExtension.Activate(addressingVersion);
        }