367 references to BuildComponentType
Microsoft.Build (187)
BackEnd\BuildManager\BuildManager.cs (29)
375private ISdkResolverService SdkResolverService => ((this as IBuildComponentHost).GetComponent(BuildComponentType.SdkResolverService) as ISdkResolverService)!; 381ILoggingService IBuildComponentHost.LoggingService => _componentFactories.GetComponent<ILoggingService>(BuildComponentType.LoggingService); 605NodeLauncher nodeLauncher = ((IBuildComponentHost)this).GetComponent<NodeLauncher>(BuildComponentType.NodeLauncher); 625_nodeManager = ((IBuildComponentHost)this).GetComponent(BuildComponentType.NodeManager) as INodeManager; 647var fileAccessManager = ((IBuildComponentHost)this).GetComponent<IFileAccessManager>(BuildComponentType.FileAccessManager); 659_taskHostNodeManager = ((IBuildComponentHost)this).GetComponent<INodeManager>(BuildComponentType.TaskHostNodeManager); 660_scheduler = ((IBuildComponentHost)this).GetComponent<IScheduler>(BuildComponentType.Scheduler); 751_configCache = ((IBuildComponentHost)this).GetComponent<IConfigCache>(BuildComponentType.ConfigCache); 752_resultsCache = ((IBuildComponentHost)this).GetComponent<IResultsCache>(BuildComponentType.ResultsCache); 803_componentFactories.ReplaceFactory(BuildComponentType.NodeLauncher, DetouredNodeLauncher.CreateComponent); 909_configCache = ((IBuildComponentHost)this).GetComponent<IConfigCache>(BuildComponentType.ConfigCache); 910_resultsCache = ((IBuildComponentHost)this).GetComponent<IResultsCache>(BuildComponentType.ResultsCache); 930_configCache = ((IBuildComponentHost)this).GetComponent(BuildComponentType.ConfigCache) as IConfigCache; 1349_nodeManager ??= (INodeManager)((IBuildComponentHost)this).GetComponent(BuildComponentType.NodeManager); 1389void IBuildComponentHost.RegisterFactory(BuildComponentType componentType, BuildComponentFactoryDelegate factory) 1399IBuildComponent IBuildComponentHost.GetComponent(BuildComponentType type) 1404TComponent IBuildComponentHost.GetComponent<TComponent>(BuildComponentType type) 2668ILoggingService loggingService = ((IBuildComponentHost)this).GetComponent<ILoggingService>(BuildComponentType.LoggingService); 2681ILoggingService loggingService = ((IBuildComponentHost)this).GetComponent<ILoggingService>(BuildComponentType.LoggingService); 2721((FileAccessManager)((IBuildComponentHost)this).GetComponent(BuildComponentType.FileAccessManager)).ReportFileAccess(fileAccessReport.FileAccessData, nodeId); 2736((FileAccessManager)((IBuildComponentHost)this).GetComponent(BuildComponentType.FileAccessManager)).ReportProcess(processReport.ProcessData, nodeId); 2855IConfigCache configCache = _componentFactories.GetComponent<IConfigCache>(BuildComponentType.ConfigCache); 2953ILoggingService loggingService = ((IBuildComponentHost)this).GetComponent<ILoggingService>(BuildComponentType.LoggingService); 3104_componentFactories.ReplaceFactory(BuildComponentType.LoggingService, loggingService as IBuildComponent); 3117((IBuildComponentHost)this).GetComponent(BuildComponentType.BuildCheckManagerProvider) as IBuildCheckManagerProvider; 3325_componentFactories.ShutdownComponent(BuildComponentType.LoggingService); 3332_componentFactories.ReplaceFactory(BuildComponentType.LoggingService, (IBuildComponent?)null); 3433_componentFactories.ReplaceFactory(BuildComponentType.ConfigCache, new ConfigCacheWithOverride(cacheAggregation.ConfigCache)); 3434_componentFactories.ReplaceFactory(BuildComponentType.ResultsCache, new ResultsCacheWithOverride(cacheAggregation.ResultsCache));
BackEnd\Components\BuildComponentFactoryCollection.cs (50)
26private readonly Dictionary<BuildComponentType, BuildComponentEntry> _componentEntriesByType; 39_componentEntriesByType = new Dictionary<BuildComponentType, BuildComponentEntry>(); 63_componentEntriesByType[BuildComponentType.Scheduler] = new BuildComponentEntry(BuildComponentType.Scheduler, Scheduler.CreateComponent, CreationPattern.Singleton); 64_componentEntriesByType[BuildComponentType.ConfigCache] = new BuildComponentEntry(BuildComponentType.ConfigCache, ConfigCache.CreateComponent, CreationPattern.Singleton); 65_componentEntriesByType[BuildComponentType.ResultsCache] = new BuildComponentEntry(BuildComponentType.ResultsCache, ResultsCache.CreateComponent, CreationPattern.Singleton); 66_componentEntriesByType[BuildComponentType.NodeManager] = new BuildComponentEntry(BuildComponentType.NodeManager, NodeManager.CreateComponent, CreationPattern.Singleton); 67_componentEntriesByType[BuildComponentType.TaskHostNodeManager] = new BuildComponentEntry(BuildComponentType.TaskHostNodeManager, TaskHostNodeManager.CreateComponent, CreationPattern.Singleton); 69_componentEntriesByType[BuildComponentType.NodeLauncher] = new BuildComponentEntry(BuildComponentType.NodeLauncher, NodeLauncher.CreateComponent, CreationPattern.Singleton); 70_componentEntriesByType[BuildComponentType.InProcNodeProvider] = new BuildComponentEntry(BuildComponentType.InProcNodeProvider, NodeProviderInProc.CreateComponent, CreationPattern.Singleton); 71_componentEntriesByType[BuildComponentType.OutOfProcNodeProvider] = new BuildComponentEntry(BuildComponentType.OutOfProcNodeProvider, NodeProviderOutOfProc.CreateComponent, CreationPattern.Singleton); 72_componentEntriesByType[BuildComponentType.OutOfProcTaskHostNodeProvider] = new BuildComponentEntry(BuildComponentType.OutOfProcTaskHostNodeProvider, NodeProviderOutOfProcTaskHost.CreateComponent, CreationPattern.Singleton); 77_componentEntriesByType[BuildComponentType.RequestEngine] = new BuildComponentEntry(BuildComponentType.RequestEngine, BuildRequestEngine.CreateComponent, CreationPattern.Singleton); 81_componentEntriesByType[BuildComponentType.LoggingService] = new BuildComponentEntry(BuildComponentType.LoggingService, null); 82_componentEntriesByType[BuildComponentType.RequestBuilder] = new BuildComponentEntry(BuildComponentType.RequestBuilder, RequestBuilder.CreateComponent, CreationPattern.CreateAlways); 84_componentEntriesByType[BuildComponentType.BuildCheckManagerProvider] = new BuildComponentEntry(BuildComponentType.BuildCheckManagerProvider, BuildCheckManagerProvider.CreateComponent, CreationPattern.Singleton); 85_componentEntriesByType[BuildComponentType.TelemetryForwarder] = new BuildComponentEntry(BuildComponentType.TelemetryForwarder, TelemetryForwarderProvider.CreateComponent, CreationPattern.Singleton); 86_componentEntriesByType[BuildComponentType.TargetBuilder] = new BuildComponentEntry(BuildComponentType.TargetBuilder, TargetBuilder.CreateComponent, CreationPattern.CreateAlways); 87_componentEntriesByType[BuildComponentType.TaskBuilder] = new BuildComponentEntry(BuildComponentType.TaskBuilder, TaskBuilder.CreateComponent, CreationPattern.CreateAlways); 88_componentEntriesByType[BuildComponentType.RegisteredTaskObjectCache] = new BuildComponentEntry(BuildComponentType.RegisteredTaskObjectCache, RegisteredTaskObjectCache.CreateComponent, CreationPattern.Singleton); 91_componentEntriesByType[BuildComponentType.SdkResolverService] = new BuildComponentEntry(BuildComponentType.SdkResolverService, MainNodeSdkResolverService.CreateComponent, CreationPattern.Singleton); 94_componentEntriesByType[BuildComponentType.FileAccessManager] = new BuildComponentEntry(BuildComponentType.FileAccessManager, FileAccessManager.CreateComponent, CreationPattern.Singleton); 103foreach (KeyValuePair<BuildComponentType, BuildComponentEntry> componentEntry in _componentEntriesByType) 115public void ShutdownComponent(BuildComponentType componentType) 126public void ReplaceFactory(BuildComponentType componentType, BuildComponentFactoryDelegate factory) 137public void ReplaceFactory(BuildComponentType componentType, IBuildComponent instance) 149public void AddFactory(BuildComponentType componentType, BuildComponentFactoryDelegate factory, CreationPattern creationPattern) 159public IBuildComponent GetComponent(BuildComponentType type) 169internal TComponent GetComponent<TComponent>(BuildComponentType type) where TComponent : IBuildComponent 192public BuildComponentEntry(BuildComponentType type, BuildComponentFactoryDelegate factory, CreationPattern pattern) 202public BuildComponentEntry(BuildComponentType type, IBuildComponent singleton) 212private BuildComponentType ComponentType { get; }
BackEnd\Components\BuildRequestEngine\BuildRequestEngine.cs (15)
296IBuildCheckManagerProvider buildCheckProvider = (_componentHost.GetComponent(BuildComponentType.BuildCheckManagerProvider) as IBuildCheckManagerProvider); 300ITelemetryForwarder telemetryForwarder = (_componentHost.GetComponent(BuildComponentType.TelemetryForwarder) as TelemetryForwarderProvider)!.Instance; 355IResultsCache cache = (IResultsCache)_componentHost.GetComponent(BuildComponentType.ResultsCache); 358BuildRequestConfiguration config = ((IConfigCache)_componentHost.GetComponent(BuildComponentType.ConfigCache))[request.ConfigurationId]; 462IResultsCache resultsCache = (IResultsCache)_componentHost.GetComponent(BuildComponentType.ResultsCache); 463IConfigCache configCache = (IConfigCache)_componentHost.GetComponent(BuildComponentType.ConfigCache); 548IConfigCache globalConfigurations = (IConfigCache)_componentHost.GetComponent(BuildComponentType.ConfigCache); 558IResultsCache resultsCache = (IResultsCache)_componentHost.GetComponent(BuildComponentType.ResultsCache); 632_configCache = (IConfigCache)host.GetComponent(BuildComponentType.ConfigCache); 658internal static IBuildComponent CreateComponent(BuildComponentType type) 660ErrorUtilities.VerifyThrow(type == BuildComponentType.RequestEngine, "Cannot create component of type {0}", type); 913_componentHost.GetComponent(BuildComponentType.ResultsCache) as IResultsCache; 979IRequestBuilder builder = (IRequestBuilder)_componentHost.GetComponent(BuildComponentType.RequestBuilder); 1156IConfigCache globalConfigCache = (IConfigCache)_componentHost.GetComponent(BuildComponentType.ConfigCache); 1248IResultsCache resultsCache = (IResultsCache)_componentHost.GetComponent(BuildComponentType.ResultsCache);
BackEnd\Components\Caching\ConfigCache.cs (2)
339internal static IBuildComponent CreateComponent(BuildComponentType componentType) 341ErrorUtilities.VerifyThrow(componentType == BuildComponentType.ConfigCache, "Cannot create components of type {0}", componentType);
BackEnd\Components\Caching\RegisteredTaskObjectCache.cs (2)
58internal static IBuildComponent CreateComponent(BuildComponentType type) 60ErrorUtilities.VerifyThrow(type == BuildComponentType.RegisteredTaskObjectCache, "Cannot create components of type {0}", type);
BackEnd\Components\Caching\ResultsCache.cs (2)
300internal static IBuildComponent CreateComponent(BuildComponentType componentType) 302ErrorUtilities.VerifyThrow(componentType == BuildComponentType.ResultsCache, "Cannot create components of type {0}", componentType);
BackEnd\Components\Communications\DetouredNodeLauncher.cs (3)
31public static IBuildComponent CreateComponent(BuildComponentType type) 33ErrorUtilities.VerifyThrowArgumentOutOfRange(type == BuildComponentType.NodeLauncher, nameof(type)); 39_fileAccessManager = (IFileAccessManager)host.GetComponent(BuildComponentType.FileAccessManager);
BackEnd\Components\Communications\NodeLauncher.cs (2)
29public static IBuildComponent CreateComponent(BuildComponentType type) 31ErrorUtilities.VerifyThrowArgumentOutOfRange(type == BuildComponentType.NodeLauncher, nameof(type));
BackEnd\Components\Communications\NodeManager.cs (4)
175_inProcNodeProvider = _componentHost.GetComponent(BuildComponentType.InProcNodeProvider) as INodeProvider; 176_outOfProcNodeProvider = _componentHost.GetComponent(BuildComponentType.OutOfProcNodeProvider) as INodeProvider; 288internal static IBuildComponent CreateComponent(BuildComponentType type) 290ErrorUtilities.VerifyThrow(type == BuildComponentType.NodeManager, "Cannot create component of type {0}", type);
BackEnd\Components\Communications\NodeProviderInProc.cs (2)
349internal static IBuildComponent CreateComponent(BuildComponentType type) 351ErrorUtilities.VerifyThrow(type == BuildComponentType.InProcNodeProvider, "Cannot create component of type {0}", type);
BackEnd\Components\Communications\NodeProviderOutOfProc.cs (2)
199internal static IBuildComponent CreateComponent(BuildComponentType componentType) 201ErrorUtilities.VerifyThrow(componentType == BuildComponentType.OutOfProcNodeProvider, "Factory cannot create components of type {0}", componentType);
BackEnd\Components\Communications\NodeProviderOutOfProcBase.cs (1)
372INodeLauncher nodeLauncher = (INodeLauncher)_componentHost.GetComponent(BuildComponentType.NodeLauncher);
BackEnd\Components\Communications\NodeProviderOutOfProcTaskHost.cs (2)
373internal static IBuildComponent CreateComponent(BuildComponentType componentType) 375ErrorUtilities.VerifyThrow(componentType == BuildComponentType.OutOfProcTaskHostNodeProvider, "Factory cannot create components of type {0}", componentType);
BackEnd\Components\Communications\TaskHostNodeManager.cs (3)
93_outOfProcTaskHostNodeProvider = _componentHost.GetComponent(BuildComponentType.OutOfProcTaskHostNodeProvider) as INodeProvider; 177internal static IBuildComponent CreateComponent(BuildComponentType type) 179ErrorUtilities.VerifyThrow(type == BuildComponentType.TaskHostNodeManager, "Cannot create component of type {0}", type);
BackEnd\Components\FileAccesses\FileAccessManager.cs (4)
38public static IBuildComponent CreateComponent(BuildComponentType type) 40ErrorUtilities.VerifyThrowArgumentOutOfRange(type == BuildComponentType.FileAccessManager, nameof(type)); 46_scheduler = host.GetComponent(BuildComponentType.Scheduler) as IScheduler; 47_configCache = host.GetComponent(BuildComponentType.ConfigCache) as IConfigCache;
BackEnd\Components\FileAccesses\OutOfProcNodeFileAccessManager.cs (2)
26public static IBuildComponent CreateComponent(BuildComponentType type, Action<INodePacket> sendPacket) 28ErrorUtilities.VerifyThrowArgumentOutOfRange(type == BuildComponentType.FileAccessManager, nameof(type));
BackEnd\Components\IBuildComponentHost.cs (4)
17internal delegate IBuildComponent BuildComponentFactoryDelegate(BuildComponentType type); 194void RegisterFactory(BuildComponentType factoryType, BuildComponentFactoryDelegate factory); 201IBuildComponent GetComponent(BuildComponentType type); 209TComponent GetComponent<TComponent>(BuildComponentType type)
BackEnd\Components\Logging\LoggingService.cs (2)
317_configCache = new Lazy<IConfigCache>(() => (IConfigCache)_componentHost.GetComponent(BuildComponentType.ConfigCache), LazyThreadSafetyMode.PublicationOnly); 905_buildEngineDataRouter = (buildComponentHost.GetComponent(BuildComponentType.BuildCheckManagerProvider) as IBuildCheckManagerProvider)?.BuildEngineDataRouter;
BackEnd\Components\Logging\LoggingServiceFactory.cs (2)
47public IBuildComponent CreateInstance(BuildComponentType type) 49ErrorUtilities.VerifyThrow(type == BuildComponentType.LoggingService, "Cannot create components of type {0}", type);
BackEnd\Components\RequestBuilder\RequestBuilder.cs (7)
215_targetBuilder = (ITargetBuilder)_componentHost.GetComponent(BuildComponentType.TargetBuilder); 630internal static IBuildComponent CreateComponent(BuildComponentType type) 632ErrorUtilities.VerifyThrow(type == BuildComponentType.RequestBuilder, "Cannot create components of type {0}", type); 1101: (_componentHost.GetComponent(BuildComponentType.BuildCheckManagerProvider) as IBuildCheckManagerProvider)!.Instance; 1241var resultsCache = (IResultsCache)_componentHost.GetComponent(BuildComponentType.ResultsCache); 1270((TelemetryForwarderProvider)_componentHost.GetComponent(BuildComponentType.TelemetryForwarder)) 1278IResultsCache resultsCache = (IResultsCache)_componentHost.GetComponent(BuildComponentType.ResultsCache);
BackEnd\Components\RequestBuilder\TargetBuilder.cs (5)
138IResultsCache resultsCache = (IResultsCache)_componentHost.GetComponent(BuildComponentType.ResultsCache); 170ITaskBuilder taskBuilder = _componentHost.GetComponent(BuildComponentType.TaskBuilder) as ITaskBuilder; 266ITaskBuilder taskBuilder = _componentHost.GetComponent(BuildComponentType.TaskBuilder) as ITaskBuilder; 398internal static IBuildComponent CreateComponent(BuildComponentType type) 400ErrorUtilities.VerifyThrow(type == BuildComponentType.TargetBuilder, "Cannot create components of type {0}", type);
BackEnd\Components\RequestBuilder\TaskBuilder.cs (2)
241internal static IBuildComponent CreateComponent(BuildComponentType type) 243ErrorUtilities.VerifyThrow(type == BuildComponentType.TaskBuilder, "Cannot create components of type {0}", type);
BackEnd\Components\RequestBuilder\TaskHost.cs (4)
621var objectCache = (IRegisteredTaskObjectCache)_host.GetComponent(BuildComponentType.RegisteredTaskObjectCache); 630var objectCache = (IRegisteredTaskObjectCache)_host.GetComponent(BuildComponentType.RegisteredTaskObjectCache); 639var objectCache = (IRegisteredTaskObjectCache)_host.GetComponent(BuildComponentType.RegisteredTaskObjectCache); 956((IFileAccessManager)buildComponentHost.GetComponent(BuildComponentType.FileAccessManager)).ReportFileAccess(fileAccessData, buildComponentHost.BuildParameters.NodeId);
BackEnd\Components\Scheduler\Scheduler.cs (4)
676_resultsCache = (IResultsCache)_componentHost.GetComponent(BuildComponentType.ResultsCache); 677_configCache = (IConfigCache)_componentHost.GetComponent(BuildComponentType.ConfigCache); 694internal static IBuildComponent CreateComponent(BuildComponentType componentType) 696ErrorUtilities.VerifyThrow(componentType == BuildComponentType.Scheduler, "Cannot create components of type {0}", componentType);
BackEnd\Components\SdkResolution\MainNodeSdkResolverService.cs (6)
25/// must have access to an <see cref="IBuildComponentHost"/> and call <see cref="IBuildComponentHost.GetComponent"/> and pass <see cref="BuildComponentType.SdkResolverService"/>. 34public static IBuildComponent CreateComponent(BuildComponentType type) 36ErrorUtilities.VerifyThrowArgumentOutOfRange(type == BuildComponentType.SdkResolverService, nameof(type)); 75ILoggingService loggingService = Host.GetComponent(BuildComponentType.LoggingService) as ILoggingService; 83ILoggingService loggingService = Host.GetComponent(BuildComponentType.LoggingService) as ILoggingService; 92INodeManager nodeManager = Host.GetComponent(BuildComponentType.NodeManager) as INodeManager;
BackEnd\Components\SdkResolution\OutOfProcNodeSdkResolverService.cs (1)
25/// must have access to an <see cref="IBuildComponentHost"/> and call <see cref="IBuildComponentHost.GetComponent"/> and pass <see cref="BuildComponentType.SdkResolverService"/>.
BackEnd\Components\SdkResolution\OutOfProcNodeSdkResolverServiceFactory.cs (1)
24public IBuildComponent CreateInstance(BuildComponentType type)
BackEnd\Node\InProcNode.cs (2)
121IBuildComponent buildRequestEngine = BuildRequestEngine.CreateComponent(BuildComponentType.RequestEngine); 340IRegisteredTaskObjectCache objectCache = (IRegisteredTaskObjectCache)(_componentHost.GetComponent(BuildComponentType.RegisteredTaskObjectCache));
BackEnd\Node\OutOfProcNode.cs (14)
155_buildRequestEngine = (this as IBuildComponentHost).GetComponent(BuildComponentType.RequestEngine) as IBuildRequestEngine; 156_globalConfigCache = (this as IBuildComponentHost).GetComponent(BuildComponentType.ConfigCache) as IConfigCache; 157_taskHostNodeManager = (this as IBuildComponentHost).GetComponent(BuildComponentType.TaskHostNodeManager) as INodeManager; 161((IBuildComponentHost)this).RegisterFactory(BuildComponentType.SdkResolverService, sdkResolverServiceFactory.CreateInstance); 162_sdkResolverService = (this as IBuildComponentHost).GetComponent(BuildComponentType.SdkResolverService) as ISdkResolverService; 166BuildComponentType.FileAccessManager, 295void IBuildComponentHost.RegisterFactory(BuildComponentType factoryType, BuildComponentFactoryDelegate factory) 305IBuildComponent IBuildComponentHost.GetComponent(BuildComponentType type) 310TComponent IBuildComponentHost.GetComponent<TComponent>(BuildComponentType type) 481IRegisteredTaskObjectCache objectCache = (IRegisteredTaskObjectCache)(_componentFactories.GetComponent(BuildComponentType.RegisteredTaskObjectCache)); 556if (_componentFactories.GetComponent(BuildComponentType.ConfigCache) is IConfigCache configCache) 561if (_componentFactories.GetComponent(BuildComponentType.ResultsCache) is IResultsCache resultsCache) 777_componentFactories.ReplaceFactory(BuildComponentType.LoggingService, loggingServiceFactory.CreateInstance); 779_loggingService = _componentFactories.GetComponent(BuildComponentType.LoggingService) as ILoggingService;
BackEnd\Shared\BuildRequestConfiguration.cs (1)
475ISdkResolverService sdkResolverService = componentHost.GetComponent(BuildComponentType.SdkResolverService) as ISdkResolverService;
BuildCheck\Infrastructure\BuildCheckManagerProvider.cs (2)
34internal static IBuildComponent CreateComponent(BuildComponentType type) 36ErrorUtilities.VerifyThrow(type == BuildComponentType.BuildCheckManagerProvider, "Cannot create components of type {0}", type);
BuildCheck\Infrastructure\BuildCheckReplayModeConnector.cs (1)
30.GetComponent(BuildComponentType.BuildCheckManagerProvider) as IBuildCheckManagerProvider;
Instance\TaskFactories\TaskHostTask.cs (2)
315_taskHostProvider = (NodeProviderOutOfProcTaskHost)_buildComponentHost.GetComponent(BuildComponentType.OutOfProcTaskHostNodeProvider); 528IFileAccessManager fileAccessManager = ((IFileAccessManager)_buildComponentHost.GetComponent(BuildComponentType.FileAccessManager));
TelemetryInfra\TelemetryForwarderProvider.cs (2)
23internal static IBuildComponent CreateComponent(BuildComponentType type) 25ErrorUtilities.VerifyThrow(type == BuildComponentType.TelemetryForwarder, "Cannot create components of type {0}", type);
Microsoft.Build.Engine.UnitTests (180)
BackEnd\BuildManager_Tests.cs (4)
1923host.GetComponent(BuildComponentType.ConfigCache); 1949host.GetComponent(BuildComponentType.ConfigCache); 1981host.GetComponent(BuildComponentType.ConfigCache); 2033host.GetComponent(BuildComponentType.ConfigCache);
BackEnd\BuildRequestEngine_Tests.cs (5)
287_engine = (IBuildRequestEngine)_host.GetComponent(BuildComponentType.RequestEngine); 288_cache = (IConfigCache)_host.GetComponent(BuildComponentType.ConfigCache); 394MockRequestBuilder builder = (MockRequestBuilder)_host.GetComponent(BuildComponentType.RequestBuilder); 447MockRequestBuilder builder = (MockRequestBuilder)_host.GetComponent(BuildComponentType.RequestBuilder); 513IBuildRequestEngine engine = (IBuildRequestEngine)_host.GetComponent(BuildComponentType.RequestEngine);
BackEnd\LoggingService_Tests.cs (1)
965ConfigCache configCache = host.GetComponent(BuildComponentType.ConfigCache) as ConfigCache;
BackEnd\LoggingServiceFactory_Tests.cs (2)
24LoggingService loggingService = (LoggingService)factory.CreateInstance(BuildComponentType.LoggingService); 35LoggingService loggingService = (LoggingService)factory.CreateInstance(BuildComponentType.LoggingService);
BackEnd\LoggingServicesLogMethod_Tests.cs (5)
838ConfigCache cache = (ConfigCache)componentHost.GetComponent(BuildComponentType.ConfigCache); 864ConfigCache cache = (ConfigCache)componentHost.GetComponent(BuildComponentType.ConfigCache); 903ConfigCache cache = (ConfigCache)componentHost.GetComponent(BuildComponentType.ConfigCache); 944ConfigCache cache = (ConfigCache)componentHost.GetComponent(BuildComponentType.ConfigCache); 1417ConfigCache cache = (ConfigCache)componentHost.GetComponent(BuildComponentType.ConfigCache);
BackEnd\MockHost.cs (12)
198public IBuildComponent GetComponent(BuildComponentType type) 202BuildComponentType.ConfigCache => (IBuildComponent)_configCache, 203BuildComponentType.LoggingService => (IBuildComponent)_loggingService, 204BuildComponentType.RequestEngine => (IBuildComponent)_requestEngine, 205BuildComponentType.TargetBuilder => (IBuildComponent)_targetBuilder, 206BuildComponentType.ResultsCache => (IBuildComponent)_resultsCache, 207BuildComponentType.RequestBuilder => (IBuildComponent)_requestBuilder, 208BuildComponentType.SdkResolverService => (IBuildComponent)_sdkResolverService, 209BuildComponentType.BuildCheckManagerProvider => (IBuildComponent)_buildCheckManagerProvider, 210BuildComponentType.TelemetryForwarder => (IBuildComponent)_telemetryForwarder, 215public TComponent GetComponent<TComponent>(BuildComponentType type) where TComponent : IBuildComponent 221public void RegisterFactory(BuildComponentType type, BuildComponentFactoryDelegate factory)
BackEnd\NodeEndpointInProc_Tests.cs (3)
78public IBuildComponent GetComponent(BuildComponentType type) 83public TComponent GetComponent<TComponent>(BuildComponentType type) where TComponent : IBuildComponent => throw new NotImplementedException("Not expected to be used."); 85public void RegisterFactory(BuildComponentType type, BuildComponentFactoryDelegate factory)
BackEnd\RequestBuilder_Tests.cs (12)
66_requestBuilder = (IRequestBuilder)_host.GetComponent(BuildComponentType.RequestBuilder); 88TestTargetBuilder targetBuilder = (TestTargetBuilder)_host.GetComponent(BuildComponentType.TargetBuilder); 89IConfigCache configCache = (IConfigCache)_host.GetComponent(BuildComponentType.ConfigCache); 118TestTargetBuilder targetBuilder = (TestTargetBuilder)_host.GetComponent(BuildComponentType.TargetBuilder); 119IConfigCache configCache = (IConfigCache)_host.GetComponent(BuildComponentType.ConfigCache); 151TestTargetBuilder targetBuilder = (TestTargetBuilder)_host.GetComponent(BuildComponentType.TargetBuilder); 152IConfigCache configCache = (IConfigCache)_host.GetComponent(BuildComponentType.ConfigCache); 190TestTargetBuilder targetBuilder = (TestTargetBuilder)_host.GetComponent(BuildComponentType.TargetBuilder); 191IConfigCache configCache = (IConfigCache)_host.GetComponent(BuildComponentType.ConfigCache); 229TestTargetBuilder targetBuilder = (TestTargetBuilder)_host.GetComponent(BuildComponentType.TargetBuilder); 230IConfigCache configCache = (IConfigCache)_host.GetComponent(BuildComponentType.ConfigCache); 305IConfigCache configCache = (IConfigCache)_host.GetComponent(BuildComponentType.ConfigCache);
BackEnd\Scheduler_Tests.cs (7)
72NodeProviderInProc nodeProviderInProc = ((IBuildComponentHost)BuildManager.DefaultBuildManager).GetComponent(BuildComponentType.InProcNodeProvider) as NodeProviderInProc; 99NodeProviderInProc nodeProviderInProc = ((IBuildComponentHost)_buildManager).GetComponent(BuildComponentType.InProcNodeProvider) as NodeProviderInProc; 379NodeProviderInProc nodeProviderInProc = ((IBuildComponentHost)BuildManager.DefaultBuildManager).GetComponent(BuildComponentType.InProcNodeProvider) as NodeProviderInProc; 573NodeProviderInProc nodeProviderInProc = ((IBuildComponentHost)BuildManager.DefaultBuildManager).GetComponent(BuildComponentType.InProcNodeProvider) as NodeProviderInProc; 617Assert.Null(((ResultsCacheWithOverride)_host.GetComponent(BuildComponentType.ResultsCache)).CurrentCache.GetResultsForConfiguration(1)); 742(_host.GetComponent(BuildComponentType.ConfigCache) as IConfigCache).AddConfiguration(config); 765(_host.GetComponent(BuildComponentType.ResultsCache) as IResultsCache).AddResult(result);
BackEnd\SdkResultOutOfProc_Tests.cs (1)
260((IBuildComponentHost)_buildManager).RegisterFactory(BuildComponentType.SdkResolverService, type =>
BackEnd\TargetBuilder_Tests.cs (90)
106TargetBuilder builder = (TargetBuilder)_host.GetComponent(BuildComponentType.TargetBuilder); 107IConfigCache cache = (IConfigCache)_host.GetComponent(BuildComponentType.ConfigCache); 126TargetBuilder builder = (TargetBuilder)_host.GetComponent(BuildComponentType.TargetBuilder); 127IConfigCache cache = (IConfigCache)_host.GetComponent(BuildComponentType.ConfigCache); 139IResultsCache resultsCache = (IResultsCache)_host.GetComponent(BuildComponentType.ResultsCache); 153TargetBuilder builder = (TargetBuilder)_host.GetComponent(BuildComponentType.TargetBuilder); 154IConfigCache cache = (IConfigCache)_host.GetComponent(BuildComponentType.ConfigCache); 162IResultsCache resultsCache = (IResultsCache)_host.GetComponent(BuildComponentType.ResultsCache); 179TargetBuilder builder = (TargetBuilder)_host.GetComponent(BuildComponentType.TargetBuilder); 180MockTaskBuilder taskBuilder = (MockTaskBuilder)_host.GetComponent(BuildComponentType.TaskBuilder); 183IConfigCache cache = (IConfigCache)_host.GetComponent(BuildComponentType.ConfigCache); 195IResultsCache resultsCache = (IResultsCache)_host.GetComponent(BuildComponentType.ResultsCache); 367TargetBuilder builder = (TargetBuilder)_host.GetComponent(BuildComponentType.TargetBuilder); 368IConfigCache cache = (IConfigCache)_host.GetComponent(BuildComponentType.ConfigCache); 507TargetBuilder builder = (TargetBuilder)_host.GetComponent(BuildComponentType.TargetBuilder); 508IConfigCache cache = (IConfigCache)_host.GetComponent(BuildComponentType.ConfigCache); 533TargetBuilder builder = (TargetBuilder)_host.GetComponent(BuildComponentType.TargetBuilder); 534IConfigCache cache = (IConfigCache)_host.GetComponent(BuildComponentType.ConfigCache); 559TargetBuilder builder = (TargetBuilder)_host.GetComponent(BuildComponentType.TargetBuilder); 560IConfigCache cache = (IConfigCache)_host.GetComponent(BuildComponentType.ConfigCache); 584MockTaskBuilder taskBuilder = (MockTaskBuilder)_host.GetComponent(BuildComponentType.TaskBuilder); 589TargetBuilder builder = (TargetBuilder)_host.GetComponent(BuildComponentType.TargetBuilder); 590IConfigCache cache = (IConfigCache)_host.GetComponent(BuildComponentType.ConfigCache); 619MockTaskBuilder taskBuilder = (MockTaskBuilder)_host.GetComponent(BuildComponentType.TaskBuilder); 624TargetBuilder builder = (TargetBuilder)_host.GetComponent(BuildComponentType.TargetBuilder); 625IConfigCache cache = (IConfigCache)_host.GetComponent(BuildComponentType.ConfigCache); 656TargetBuilder builder = (TargetBuilder)_host.GetComponent(BuildComponentType.TargetBuilder); 657IConfigCache cache = (IConfigCache)_host.GetComponent(BuildComponentType.ConfigCache); 687TargetBuilder builder = (TargetBuilder)_host.GetComponent(BuildComponentType.TargetBuilder); 688IConfigCache cache = (IConfigCache)_host.GetComponent(BuildComponentType.ConfigCache); 713TargetBuilder builder = (TargetBuilder)_host.GetComponent(BuildComponentType.TargetBuilder); 714IConfigCache cache = (IConfigCache)_host.GetComponent(BuildComponentType.ConfigCache); 749TargetBuilder builder = (TargetBuilder)_host.GetComponent(BuildComponentType.TargetBuilder); 750IConfigCache cache = (IConfigCache)_host.GetComponent(BuildComponentType.ConfigCache); 775TargetBuilder builder = (TargetBuilder)_host.GetComponent(BuildComponentType.TargetBuilder); 776IConfigCache cache = (IConfigCache)_host.GetComponent(BuildComponentType.ConfigCache); 802TargetBuilder builder = (TargetBuilder)_host.GetComponent(BuildComponentType.TargetBuilder); 803IConfigCache cache = (IConfigCache)_host.GetComponent(BuildComponentType.ConfigCache); 827MockTaskBuilder taskBuilder = (MockTaskBuilder)_host.GetComponent(BuildComponentType.TaskBuilder); 832TargetBuilder builder = (TargetBuilder)_host.GetComponent(BuildComponentType.TargetBuilder); 833IConfigCache cache = (IConfigCache)_host.GetComponent(BuildComponentType.ConfigCache); 871MockTaskBuilder taskBuilder = (MockTaskBuilder)_host.GetComponent(BuildComponentType.TaskBuilder); 876TargetBuilder builder = (TargetBuilder)_host.GetComponent(BuildComponentType.TargetBuilder); 877IConfigCache cache = (IConfigCache)_host.GetComponent(BuildComponentType.ConfigCache); 903TargetBuilder builder = (TargetBuilder)_host.GetComponent(BuildComponentType.TargetBuilder); 904IConfigCache cache = (IConfigCache)_host.GetComponent(BuildComponentType.ConfigCache); 930TargetBuilder builder = (TargetBuilder)_host.GetComponent(BuildComponentType.TargetBuilder); 931IConfigCache cache = (IConfigCache)_host.GetComponent(BuildComponentType.ConfigCache); 962TargetBuilder builder = (TargetBuilder)_host.GetComponent(BuildComponentType.TargetBuilder); 963IConfigCache cache = (IConfigCache)_host.GetComponent(BuildComponentType.ConfigCache); 1060TargetBuilder builder = (TargetBuilder)_host.GetComponent(BuildComponentType.TargetBuilder); 1061IConfigCache cache = (IConfigCache)_host.GetComponent(BuildComponentType.ConfigCache); 1095TargetBuilder builder = (TargetBuilder)_host.GetComponent(BuildComponentType.TargetBuilder); 1096IConfigCache cache = (IConfigCache)_host.GetComponent(BuildComponentType.ConfigCache); 1146TargetBuilder builder = (TargetBuilder)_host.GetComponent(BuildComponentType.TargetBuilder); 1147IConfigCache cache = (IConfigCache)_host.GetComponent(BuildComponentType.ConfigCache); 1206TargetBuilder builder = (TargetBuilder)_host.GetComponent(BuildComponentType.TargetBuilder); 1207IConfigCache cache = (IConfigCache)_host.GetComponent(BuildComponentType.ConfigCache); 1243MockTaskBuilder taskBuilder = (MockTaskBuilder)_host.GetComponent(BuildComponentType.TaskBuilder); 1248TargetBuilder builder = (TargetBuilder)_host.GetComponent(BuildComponentType.TargetBuilder); 1249IConfigCache cache = (IConfigCache)_host.GetComponent(BuildComponentType.ConfigCache); 1294TargetBuilder builder = (TargetBuilder)_host.GetComponent(BuildComponentType.TargetBuilder); 1295IConfigCache cache = (IConfigCache)_host.GetComponent(BuildComponentType.ConfigCache); 1325TargetBuilder builder = (TargetBuilder)_host.GetComponent(BuildComponentType.TargetBuilder); 1326IConfigCache cache = (IConfigCache)_host.GetComponent(BuildComponentType.ConfigCache); 1399TargetBuilder builder = (TargetBuilder)_host.GetComponent(BuildComponentType.TargetBuilder); 1400IConfigCache cache = (IConfigCache)_host.GetComponent(BuildComponentType.ConfigCache); 1428TargetBuilder builder = (TargetBuilder)_host.GetComponent(BuildComponentType.TargetBuilder); 1429MockTaskBuilder taskBuilder = (MockTaskBuilder)_host.GetComponent(BuildComponentType.TaskBuilder); 1433IConfigCache cache = (IConfigCache)_host.GetComponent(BuildComponentType.ConfigCache); 1439IResultsCache resultsCache = (IResultsCache)_host.GetComponent(BuildComponentType.ResultsCache); 1456TargetBuilder builder = (TargetBuilder)_host.GetComponent(BuildComponentType.TargetBuilder); 1457MockTaskBuilder taskBuilder = (MockTaskBuilder)_host.GetComponent(BuildComponentType.TaskBuilder); 1460IConfigCache cache = (IConfigCache)_host.GetComponent(BuildComponentType.ConfigCache); 1465IResultsCache resultsCache = (IResultsCache)_host.GetComponent(BuildComponentType.ResultsCache); 1549MockTaskBuilder mockBuilder = (MockTaskBuilder)_host.GetComponent(BuildComponentType.TaskBuilder); 1679IConfigCache cache = (IConfigCache)_host.GetComponent(BuildComponentType.ConfigCache); 1711MockTaskBuilder taskBuilder = (MockTaskBuilder)_host.GetComponent(BuildComponentType.TaskBuilder); 1714TargetBuilder builder = (TargetBuilder)_host.GetComponent(BuildComponentType.TargetBuilder); 1715IConfigCache cache = (IConfigCache)_host.GetComponent(BuildComponentType.ConfigCache); 1849public IBuildComponent GetComponent(BuildComponentType type) 1853BuildComponentType.ConfigCache => (IBuildComponent)_configCache, 1854BuildComponentType.LoggingService => (IBuildComponent)_loggingService, 1855BuildComponentType.ResultsCache => (IBuildComponent)_resultsCache, 1856BuildComponentType.RequestBuilder => (IBuildComponent)_requestBuilder, 1857BuildComponentType.TaskBuilder => (IBuildComponent)_taskBuilder, 1858BuildComponentType.TargetBuilder => (IBuildComponent)_targetBuilder, 1859BuildComponentType.SdkResolverService => (IBuildComponent)_sdkResolverService, 1864public TComponent GetComponent<TComponent>(BuildComponentType type) where TComponent : IBuildComponent 1870public void RegisterFactory(BuildComponentType type, BuildComponentFactoryDelegate factory)
BackEnd\TargetEntry_Tests.cs (24)
212MockTaskBuilder taskBuilder = (MockTaskBuilder)_host.GetComponent(BuildComponentType.TaskBuilder); 254MockTaskBuilder taskBuilder = (MockTaskBuilder)_host.GetComponent(BuildComponentType.TaskBuilder); 319MockTaskBuilder taskBuilder = (MockTaskBuilder)_host.GetComponent(BuildComponentType.TaskBuilder); 348MockTaskBuilder taskBuilder = (MockTaskBuilder)_host.GetComponent(BuildComponentType.TaskBuilder); 454MockTaskBuilder taskBuilder = (MockTaskBuilder)_host.GetComponent(BuildComponentType.TaskBuilder); 480MockTaskBuilder taskBuilder = (MockTaskBuilder)_host.GetComponent(BuildComponentType.TaskBuilder); 498MockTaskBuilder taskBuilder = (MockTaskBuilder)_host.GetComponent(BuildComponentType.TaskBuilder); 517MockTaskBuilder taskBuilder = (MockTaskBuilder)_host.GetComponent(BuildComponentType.TaskBuilder); 535MockTaskBuilder taskBuilder = (MockTaskBuilder)_host.GetComponent(BuildComponentType.TaskBuilder); 553MockTaskBuilder taskBuilder = (MockTaskBuilder)_host.GetComponent(BuildComponentType.TaskBuilder); 571MockTaskBuilder taskBuilder = (MockTaskBuilder)_host.GetComponent(BuildComponentType.TaskBuilder); 589MockTaskBuilder taskBuilder = (MockTaskBuilder)_host.GetComponent(BuildComponentType.TaskBuilder); 731NodeProviderInProc nodeProviderInProc = ((IBuildComponentHost)BuildManager.DefaultBuildManager).GetComponent(BuildComponentType.InProcNodeProvider) as NodeProviderInProc; 790NodeProviderInProc inProcNodeProvider = ((IBuildComponentHost)manager).GetComponent(BuildComponentType.InProcNodeProvider) as NodeProviderInProc; 899ITaskBuilder taskBuilder = _host.GetComponent(BuildComponentType.TaskBuilder) as ITaskBuilder; 1212public IBuildComponent GetComponent(BuildComponentType type) 1216BuildComponentType.ConfigCache => (IBuildComponent)_configCache, 1217BuildComponentType.LoggingService => (IBuildComponent)_loggingService, 1218BuildComponentType.ResultsCache => (IBuildComponent)_resultsCache, 1219BuildComponentType.RequestBuilder => (IBuildComponent)_requestBuilder, 1220BuildComponentType.TaskBuilder => (IBuildComponent)_taskBuilder, 1221BuildComponentType.SdkResolverService => (IBuildComponent)_sdkResolverService, 1226public TComponent GetComponent<TComponent>(BuildComponentType type) where TComponent : IBuildComponent 1232public void RegisterFactory(BuildComponentType type, BuildComponentFactoryDelegate factory)
BackEnd\TaskBuilder_Tests.cs (9)
1313public IBuildComponent GetComponent(BuildComponentType type) 1317BuildComponentType.ConfigCache => (IBuildComponent)_configCache, 1318BuildComponentType.LoggingService => (IBuildComponent)_loggingService, 1319BuildComponentType.ResultsCache => (IBuildComponent)_resultsCache, 1320BuildComponentType.RequestBuilder => (IBuildComponent)_requestBuilder, 1321BuildComponentType.TargetBuilder => (IBuildComponent)_targetBuilder, 1322BuildComponentType.SdkResolverService => (IBuildComponent)_sdkResolverService, 1327public TComponent GetComponent<TComponent>(BuildComponentType type) where TComponent : IBuildComponent 1333public void RegisterFactory(BuildComponentType type, BuildComponentFactoryDelegate factory)
BackEnd\TaskHost_Tests.cs (1)
71_loggingService = loggingFactory.CreateInstance(BuildComponentType.LoggingService) as LoggingService;
Construction\SolutionProjectGenerator_Tests.cs (4)
2190NodeProviderInProc nodeProviderInProc = ((IBuildComponentHost)BuildManager.DefaultBuildManager).GetComponent(BuildComponentType.InProcNodeProvider) as NodeProviderInProc; 2217NodeProviderInProc nodeProviderInProc = ((IBuildComponentHost)buildManager).GetComponent(BuildComponentType.InProcNodeProvider) as NodeProviderInProc; 2278NodeProviderInProc nodeProviderInProc = ((IBuildComponentHost)BuildManager.DefaultBuildManager).GetComponent(BuildComponentType.InProcNodeProvider) as NodeProviderInProc; 2305NodeProviderInProc nodeProviderInProc = ((IBuildComponentHost)buildManager).GetComponent(BuildComponentType.InProcNodeProvider) as NodeProviderInProc;