Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
Export (0) Print
Expand All

PeerTransportBindingElement.BuildChannelFactory<TChannel> Method

Creates a channel factory that can be used to create a channel for sending messages.

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

public override IChannelFactory<TChannel> BuildChannelFactory<TChannel>(
	BindingContext context
)

Type Parameters

TChannel

The type of channel to produce.

Parameters

context
Type: System.ServiceModel.Channels.BindingContext

BindingContext that specifies the binding context for the channel factory.

Return Value

Type: System.ServiceModel.Channels.IChannelFactory<TChannel>
IChannelFactory that contains the new channel factory of the specified type.

ExceptionCondition
ArgumentNullException

The context parameter is set to null.

InvalidOperationException

Manual addressing was specified in the binding context for this channel factory.

ArgumentException

The channel type indicated by this binding context is not supported.

This method can be used to get a channel factory based on the configuration of the transport binding element.

This method can be used to get a channel factory for sending messages based on the configuration of the transport binding element.

.NET Framework

Supported in: 4.6, 4.5, 4, 3.5, 3.0

.NET Framework Client Profile

Supported in: 4, 3.5 SP1
Show:
© 2015 Microsoft