ComposablePartExportProvider.GetExportsCore 方法

定义

获取此提供程序中与指定导入的条件匹配的所有导出的集合。

protected:
 override System::Collections::Generic::IEnumerable<System::ComponentModel::Composition::Primitives::Export ^> ^ GetExportsCore(System::ComponentModel::Composition::Primitives::ImportDefinition ^ definition, System::ComponentModel::Composition::Hosting::AtomicComposition ^ atomicComposition);
protected override System.Collections.Generic.IEnumerable<System.ComponentModel.Composition.Primitives.Export> GetExportsCore (System.ComponentModel.Composition.Primitives.ImportDefinition definition, System.ComponentModel.Composition.Hosting.AtomicComposition atomicComposition);
protected override System.Collections.Generic.IEnumerable<System.ComponentModel.Composition.Primitives.Export>? GetExportsCore (System.ComponentModel.Composition.Primitives.ImportDefinition definition, System.ComponentModel.Composition.Hosting.AtomicComposition? atomicComposition);
override this.GetExportsCore : System.ComponentModel.Composition.Primitives.ImportDefinition * System.ComponentModel.Composition.Hosting.AtomicComposition -> seq<System.ComponentModel.Composition.Primitives.Export>
Protected Overrides Function GetExportsCore (definition As ImportDefinition, atomicComposition As AtomicComposition) As IEnumerable(Of Export)

参数

definition
ImportDefinition

定义要获取的 ImportDefinition 条件的 Export

atomicComposition
AtomicComposition

要使用的组合事务,或为 null 以禁用事务性组合。

返回

此提供程序中与指定条件匹配的所有导出的集合。

注解

实现者不应将基数相关的不匹配视为错误,也不应为基数相关的不匹配引发异常。 例如,如果导入只请求一个导出,并且提供程序没有匹配的导出或多个,则 GetExportsCore 方法应返回对象的空 IEnumerable<T> 集合 Export

适用于