Esempio n. 1
0
        public void Install(ChannelFactory channelFactory, IKernel kernel, IWcfBurden burden)
        {
            var extension = GetInstance(kernel, burden);

            if (extension is IChannelFactoryAware)
            {
                WcfUtils.BindChannelFactoryAware(channelFactory, (IChannelFactoryAware)extension, true);
            }
        }
 private static void BindChannelFactoryAware(ChannelFactory channelFactory, IKernel kernel, IWcfBurden burden)
 {
     WcfUtils.AddBehaviors <IWcfPolicy>(kernel, WcfExtensionScope.Undefined, null, burden, null);
     WcfUtils.AddBehaviors <IChannelFactoryAware>(kernel, WcfExtensionScope.Clients, null, burden,
                                                  channelFactoryAware =>
     {
         WcfUtils.BindChannelFactoryAware(channelFactory, channelFactoryAware, true);
         return(true);
     });
 }