共用方式為


ChannelFactoryBase<TChannel>.OnCreateChannel 方法

定義

在衍生類別內實作時,提供建立通道時的擴充點。

protected:
 abstract TChannel OnCreateChannel(System::ServiceModel::EndpointAddress ^ address, Uri ^ via);
protected abstract TChannel OnCreateChannel (System.ServiceModel.EndpointAddress address, Uri via);
abstract member OnCreateChannel : System.ServiceModel.EndpointAddress * Uri -> 'Channel
Protected MustOverride Function OnCreateChannel (address As EndpointAddress, via As Uri) As TChannel

參數

address
EndpointAddress

通道傳送訊息之目標遠端端點的 EndpointAddress

via
Uri

包含在輸出通道上傳送訊息之目標傳輸位址的 Uri

傳回

TChannel

具有指定之位址的 TChannel 型別通道。

備註

這個方法會在叫用時,由 CreateChannel 所呼叫。

適用於