1 type derived from MefHostServices
Microsoft.CodeAnalysis.Workspaces.Test.Utilities (1)
MEF\UseExportProviderAttribute.cs (1)
216private class ExportProviderMefHostServices : MefHostServices, IMefHostExportProvider
1 instantiation of MefHostServices
Microsoft.CodeAnalysis.Workspaces.UnitTests (1)
CommandLineProject\CommandLineProjectTests.cs (1)
39var ws = new AdhocWorkspace(new MefHostServices(new ContainerConfiguration().CreateContainer())); // no services
51 references to MefHostServices
AnalyzerRunner (4)
AnalyzerRunnerMefHostServices.cs (3)
16private static MefHostServices s_defaultServices; 18public static MefHostServices DefaultServices 24Interlocked.CompareExchange(ref s_defaultServices, MefHostServices.Create(DefaultAssemblies), null);
CodeRefactoringRunner.cs (1)
201var assemblies = new List<Assembly>(MefHostServices.DefaultAssemblies);
IdeBenchmarks (2)
InheritanceMargin\InheritanceMarginServiceBenchmarks.cs (2)
46var hostService = MefHostServices.Create(assemblies);
IdeCoreBenchmarks (8)
ClassificationBenchmarks.cs (2)
67var services = MefHostServices.Create(assemblies);
FindReferencesBenchmarks.cs (2)
64var services = MefHostServices.Create(assemblies);
IncrementalSourceGeneratorBenchmarks.cs (2)
72var services = MefHostServices.Create(assemblies);
NavigateToBenchmarks.cs (2)
69var services = MefHostServices.Create(assemblies);
Microsoft.AspNetCore.App.Analyzers.Test (3)
TestDiagnosticAnalyzer.cs (3)
123var assemblies = MefHostServices.DefaultAssemblies.ToList(); 142var host = MefHostServices.Create(exportProvider.AsCompositionContext());
Microsoft.CodeAnalysis.CodeStyle.Fixes (1)
Host\Mef\CodeStyleHostLanguageServices.cs (1)
51return MefHostServices.DefaultAssemblies.Concat(
Microsoft.CodeAnalysis.EditorFeatures (1)
Shared\Preview\PreviewWorkspace.cs (1)
17: base(MefHostServices.DefaultHost, WorkspaceKind.Preview)
Microsoft.CodeAnalysis.EditorFeatures.Test.Utilities (1)
Workspaces\MefTestWorkspace.cs (1)
19: base(Microsoft.CodeAnalysis.Host.Mef.MefHostServices.DefaultHost, "MefTest")
Microsoft.CodeAnalysis.EditorFeatures.UnitTests (2)
Diagnostics\IDEDiagnosticIDConfigurationTests.cs (1)
30foreach (var assembly in MefHostServices.DefaultAssemblies)
Workspaces\DefaultMefHostTests.cs (1)
22MefHostServices.TestAccessor.HookServiceCreation(null);
Microsoft.CodeAnalysis.Remote.ServiceHub (1)
Host\RemoteWorkspaceManager.cs (1)
26MefHostServices.DefaultAssemblies
Microsoft.CodeAnalysis.Workspaces (6)
Workspace\AdhocWorkspace.cs (1)
22: this(Host.Mef.MefHostServices.DefaultHost)
Workspace\Host\Mef\MefHostServices.cs (5)
20internal delegate MefHostServices CreationHook(IEnumerable<Assembly> assemblies); 28public static MefHostServices Create(CompositionContext compositionContext) 38public static MefHostServices Create(IEnumerable<System.Reflection.Assembly> assemblies) 76private static MefHostServices s_defaultHost; 77public static MefHostServices DefaultHost
Microsoft.CodeAnalysis.Workspaces.Desktop (3)
Workspace\Host\Mef\DesktopMefHostServices.cs (3)
12public static MefHostServices DefaultServices => MefHostServices.DefaultHost; 13public static ImmutableArray<Assembly> DefaultAssemblies => MefHostServices.DefaultAssemblies;
Microsoft.CodeAnalysis.Workspaces.MSBuild (3)
Host\Mef\MSBuildMefHostServices.cs (3)
12public static MefHostServices DefaultServices 18return MefHostServices.DefaultHost; 28return MefHostServices.DefaultAssemblies;
Microsoft.CodeAnalysis.Workspaces.MSBuild.UnitTests (4)
VisualStudioMSBuildWorkspaceTests.cs (4)
1135private readonly IEnumerable<Assembly> _defaultAssembliesWithoutCSharp = MefHostServices.DefaultAssemblies.Where(a => !a.FullName.Contains("CSharp")); 1147using var workspace = CreateMSBuildWorkspace(MefHostServices.Create(_defaultAssembliesWithoutCSharp)); 1165using var workspace = CreateMSBuildWorkspace(MefHostServices.Create(_defaultAssembliesWithoutCSharp)); 1183using var workspace = MSBuildWorkspace.Create(MefHostServices.Create(_defaultAssembliesWithoutCSharp));
Microsoft.CodeAnalysis.Workspaces.Test.Utilities (10)
MEF\ExportProviderCache.cs (3)
25.AddAssemblies(MefHostServices.DefaultAssemblies) 46/// Use to create <see cref="IExportProviderFactory"/> for default instances of <see cref="MefHostServices"/>. 51assembliesArray == MefHostServices.DefaultAssemblies)
MEF\FeaturesTestCompositions.cs (1)
15.AddAssemblies(MefHostServices.DefaultAssemblies)
MEF\UseExportProviderAttribute.cs (6)
55private MefHostServices? _hostServices; 68MefHostServices.TestAccessor.HookServiceCreation(CreateMefHostServices); 98MefHostServices.TestAccessor.HookServiceCreation(DenyMefHostServicesCreationBetweenTests); 175private MefHostServices CreateMefHostServices(IEnumerable<Assembly> assemblies) 180array == MefHostServices.DefaultAssemblies && 203private static MefHostServices DenyMefHostServicesCreationBetweenTests(IEnumerable<Assembly> assemblies)
Microsoft.CodeAnalysis.Workspaces.UnitTests (2)
SolutionTests\TryApplyChangesTests.cs (1)
32: base(Host.Mef.MefHostServices.DefaultHost, workspaceKind: nameof(CustomizedCanApplyWorkspace))
WorkspaceTests\WorkspaceTests.cs (1)
120: this(Host.Mef.MefHostServices.DefaultHost)