BindingContext.CanBuildInnerChannelFactory<TChannel> Method ()

 
System_CAPS_noteNote

The .NET API Reference documentation has a new home. Visit the .NET API Browser on docs.microsoft.com to see the new experience.

Returns a value that indicates whether the inner channel factory can produce a specified type of channel.

Namespace:   System.ServiceModel.Channels
Assembly:  System.ServiceModel (in System.ServiceModel.dll)

public bool CanBuildInnerChannelFactory<TChannel>()

Return Value

Type: System.Boolean

true if the inner channel factory can produce the specified TChannel; otherwise, false.

Type Parameters

TChannel

The type of IChannel object the inner channel factory produces.

CustomBinding binding = new CustomBinding();
BindingParameterCollection bpCol = new BindingParameterCollection();
BindingContext context = new BindingContext(binding, bpCol);
context.CanBuildInnerChannelFactory<IDuplexChannel>();

Universal Windows Platform
Available since 8
.NET Framework
Available since 3.0
Portable Class Library
Supported in: portable .NET platforms
Silverlight
Available since 2.0
Windows Phone Silverlight
Available since 7.0
Return to top
Show: