33 references to ExportServices
System.ComponentModel.Composition (33)
System\ComponentModel\Composition\ExportServices.cs (13)
19private static readonly MethodInfo _createStronglyTypedLazyOfTM = typeof(ExportServices).GetMethod("CreateStronglyTypedLazyOfTM", BindingFlags.NonPublic | BindingFlags.Static)!; 20private static readonly MethodInfo _createStronglyTypedLazyOfT = typeof(ExportServices).GetMethod("CreateStronglyTypedLazyOfT", BindingFlags.NonPublic | BindingFlags.Static)!; 21private static readonly MethodInfo _createSemiStronglyTypedLazy = typeof(ExportServices).GetMethod("CreateSemiStronglyTypedLazy", BindingFlags.NonPublic | BindingFlags.Static)!; 52genericMethod = _createStronglyTypedLazyOfTM.MakeGenericMethod(exportType ?? ExportServices.DefaultExportedValueType, metadataViewType); 56genericMethod = _createStronglyTypedLazyOfT.MakeGenericMethod(exportType ?? ExportServices.DefaultExportedValueType); 70exportType ?? ExportServices.DefaultExportedValueType, 71metadataViewType ?? ExportServices.DefaultMetadataViewType); 84() => ExportServices.GetCastedExportedValue<T>(export), 92() => ExportServices.GetCastedExportedValue<T>(export), 103() => ExportServices.GetCastedExportedValue<T>(export), 109return new Lazy<T>(() => ExportServices.GetCastedExportedValue<T>(export), LazyThreadSafetyMode.PublicationOnly); 118() => ExportServices.GetCastedExportedValue<T>(export), 126() => ExportServices.GetCastedExportedValue<T>(export),
System\ComponentModel\Composition\Hosting\CompositionServices.cs (2)
472ExportServices.IsDefaultMetadataViewType(metadataViewType) || 473ExportServices.IsDictionaryConstructorViewType(metadataViewType) ||
System\ComponentModel\Composition\Hosting\ExportProvider.cs (1)
214var checkResult = ExportServices.CheckCardinality(definition, exports);
System\ComponentModel\Composition\Hosting\ExportProvider.GetExportOverrides.cs (8)
266Func<Export, Lazy<object, object>> typedExportFactory = ExportServices.CreateSemiStronglyTypedLazyFactory(type, metadataViewType); 718result.Add(ExportServices.GetCastedExportedValue<T>(export)); 732return (export != null) ? ExportServices.GetCastedExportedValue<T>(export) : default; 742result.Add(ExportServices.CreateStronglyTypedLazyOfT<T>(export)); 754result.Add(ExportServices.CreateStronglyTypedLazyOfTM<T, TMetadataView>(export)); 763return (export != null) ? ExportServices.CreateStronglyTypedLazyOfTM<T, TMetadataView>(export) : null; 770return (export != null) ? ExportServices.CreateStronglyTypedLazyOfT<T>(export) : null; 783metadataViewType ??= ExportServices.DefaultMetadataViewType;
System\ComponentModel\Composition\MetadataViewProvider.cs (2)
131if (ExportServices.IsDefaultMetadataViewType(metadataViewType) || 133ExportServices.IsDictionaryConstructorViewType(metadataViewType))
System\ComponentModel\Composition\ReflectionModel\ExportfactoryCreator.LifetimeContext.cs (4)
24exportedValue = ExportServices.GetCastedExportedValue<T>(exportProduct); 33exportedValue = ExportServices.GetCastedExportedValue<T>(exportProduct); 39var factoryPartDefinition = ExportServices.GetCastedExportedValue<ComposablePartDefinition>(export); 43exportedValue = ExportServices.CastExportedValue<T>(part.ToElement(), part.GetExportedValue(exportDef));
System\ComponentModel\Composition\ReflectionModel\ImportType.cs (2)
171castFunction = ExportServices.CreateStronglyTypedLazyFactory(arguments[0].UnderlyingSystemType, null); 180castFunction = ExportServices.CreateStronglyTypedLazyFactory(arguments[0].UnderlyingSystemType, arguments[1].UnderlyingSystemType);
System\ComponentModel\Composition\ReflectionModel\ReflectionComposablePart.cs (1)
396ExportCardinalityCheckResult result = ExportServices.CheckCardinality(definition, exports);