共用方式為


DataServiceHostFactory.CreateServiceHost(Type, Uri[]) 方法

定義

從 URI 建立新的 DataServiceHost

protected:
 override System::ServiceModel::ServiceHost ^ CreateServiceHost(Type ^ serviceType, cli::array <Uri ^> ^ baseAddresses);
protected override System.ServiceModel.ServiceHost CreateServiceHost (Type serviceType, Uri[] baseAddresses);
override this.CreateServiceHost : Type * Uri[] -> System.ServiceModel.ServiceHost
Protected Overrides Function CreateServiceHost (serviceType As Type, baseAddresses As Uri()) As ServiceHost

參數

serviceType
Type

指定要裝載之 WCF 服務的型別。

baseAddresses
Uri[]

服務的基底位址陣列。

傳回

建立的 DataServiceHost 物件。

適用於