MessageEncodingBindingElementImporter.IPolicyImportExtension.ImportPolicy 方法

定义

定义一个方法,该方法可导入消息编码的自定义策略断言,并添加实现策略的绑定元素。

 virtual void System.ServiceModel.Description.IPolicyImportExtension.ImportPolicy(System::ServiceModel::Description::MetadataImporter ^ importer, System::ServiceModel::Description::PolicyConversionContext ^ context) = System::ServiceModel::Description::IPolicyImportExtension::ImportPolicy;
void IPolicyImportExtension.ImportPolicy (System.ServiceModel.Description.MetadataImporter importer, System.ServiceModel.Description.PolicyConversionContext context);
abstract member System.ServiceModel.Description.IPolicyImportExtension.ImportPolicy : System.ServiceModel.Description.MetadataImporter * System.ServiceModel.Description.PolicyConversionContext -> unit
override this.System.ServiceModel.Description.IPolicyImportExtension.ImportPolicy : System.ServiceModel.Description.MetadataImporter * System.ServiceModel.Description.PolicyConversionContext -> unit
Sub ImportPolicy (importer As MetadataImporter, context As PolicyConversionContext) Implements IPolicyImportExtension.ImportPolicy

参数

importer
MetadataImporter

可导入元数据信息的 MetadataImporter

context
PolicyConversionContext

PolicyConversionContext 对象,其中既包含可以导入的策略断言,也包含可向其添加实现编码策略的自定义绑定元素的绑定元素集合。

实现

例外

importerpolicyContextnull

适用于