本文整理汇总了C#中BindingContext.BuildInnerChannelFactory方法的典型用法代码示例。如果您正苦于以下问题:C# BindingContext.BuildInnerChannelFactory方法的具体用法?C# BindingContext.BuildInnerChannelFactory怎么用?C# BindingContext.BuildInnerChannelFactory使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类BindingContext
的用法示例。
在下文中一共展示了BindingContext.BuildInnerChannelFactory方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: BuildChannelFactoryIgnoresRemaining
public void BuildChannelFactoryIgnoresRemaining ()
{
BindingContext ctx = new BindingContext (
new CustomBinding (
new HttpTransportBindingElement (),
new InvalidBindingElement ()),
empty_params);
ctx.BuildInnerChannelFactory<IRequestChannel> ();
}
示例2: CreateChannelWithoutOpen
public void CreateChannelWithoutOpen ()
{
BindingContext ctx = new BindingContext (
new CustomBinding (
new HttpTransportBindingElement ()),
empty_params);
// returns HttpChannelFactory
IChannelFactory<IRequestChannel> f =
ctx.BuildInnerChannelFactory<IRequestChannel> ();
IChannel c = f.CreateChannel (new EndpointAddress (
"http://www.mono-project.com"));
}
示例3: BuildChannelFactoryHttpNoMessage
// with July CTP it still works ...
public void BuildChannelFactoryHttpNoMessage ()
{
BindingContext ctx = new BindingContext (
new CustomBinding (
new HttpTransportBindingElement ()),
empty_params);
IChannelFactory<IRequestChannel> cf =
ctx.BuildInnerChannelFactory<IRequestChannel> ();
cf.Open ();
}
示例4: CreateChannelInvalidScheme
public void CreateChannelInvalidScheme ()
{
MsmqTransportBindingElement be =
new MsmqTransportBindingElement ();
// Without settings them, it borks when MSMQ setup
// does not support AD integration.
be.MsmqTransportSecurity.MsmqAuthenticationMode =
MsmqAuthenticationMode.None;
be.MsmqTransportSecurity.MsmqProtectionLevel =
ProtectionLevel.None;
BindingContext ctx = new BindingContext (
new CustomBinding (be),
empty_params);
// returns MsmqChannelFactory
IChannelFactory<IOutputChannel> f =
ctx.BuildInnerChannelFactory<IOutputChannel> ();
f.Open ();
f.CreateChannel (new EndpointAddress ("stream:dummy"));
}