BinaryMessageEncodingBindingElement.BuildChannelFactory<TChannel> Metoda

Definice

Sestaví zásobník objektu pro vytváření kanálů na klientovi, který vytvoří zadaný typ kanálu pro zadaný kontext.

public:
generic <typename TChannel>
 override System::ServiceModel::Channels::IChannelFactory<TChannel> ^ BuildChannelFactory(System::ServiceModel::Channels::BindingContext ^ context);
public override System.ServiceModel.Channels.IChannelFactory<TChannel> BuildChannelFactory<TChannel>(System.ServiceModel.Channels.BindingContext context);
override this.BuildChannelFactory : System.ServiceModel.Channels.BindingContext -> System.ServiceModel.Channels.IChannelFactory<'Channel>
Public Overrides Function BuildChannelFactory(Of TChannel) (context As BindingContext) As IChannelFactory(Of TChannel)

Parametry typu

TChannel

Typ kanálu, který objekt pro vytváření kanálů vytváří.

Parametry

context
BindingContext

Kanál BindingContext .

Návraty

Typ IChannelFactory<TChannel>TChannel pro zadaný kontext.

Příklady

var binding = new CustomBinding();
var bpCol = new BindingParameterCollection();
var context = new BindingContext(binding, bpCol);
be.BuildChannelFactory<IDuplexChannel>(context);
Dim binding As New CustomBinding()
Dim bpCol As New BindingParameterCollection()
Dim context As New BindingContext(binding, bpCol)
be.BuildChannelFactory(Of IDuplexChannel)(context)

Platí pro