6 implementations of IHostBuilder
Microsoft.AspNetCore (2)
Microsoft.AspNetCore.Mvc.Testing (1)
Microsoft.Extensions.Hosting (2)
Microsoft.Extensions.Hosting.Testing (1)
562 references to IHostBuilder
AutobahnTestApp (1)
BasicLinkedApp (1)
Benchmarks (2)
Binding.UDS.IntegrationTests (1)
BlazorServerApp (1)
Certificate.Optional.Sample (1)
Certificate.Sample (1)
CustomAuthorizationFailureResponse (1)
DefaultBuilder.SampleApp (1)
DelegationSite (1)
GenericHostWebSite (1)
HeaderPropagationSample (1)
HostedBlazorWebassemblyApp.Server (1)
HostFilteringSample (1)
http2cat (2)
Http2SampleApp (1)
Http3SampleApp (1)
HttpLogging.Sample (1)
HttpStress (1)
Identity.DefaultUI.WebSite (1)
IdentitySample.DefaultUI (1)
IIS.FunctionalTests (2)
IIS.LongTests (2)
IIS.NewHandler.FunctionalTests (2)
IIS.NewShim.FunctionalTests (2)
IISExpress.FunctionalTests (2)
InMemory.FunctionalTests (1)
IntegrationTestsWebsite (1)
Interop.FunctionalTests (86)
InteropWebsite (1)
Kestrel.SampleApp (1)
Logging.W3C.Sample (1)
Microsoft.AspNetCore (30)
Microsoft.AspNetCore.App.Analyzers.Test (1)
Microsoft.AspNetCore.Authentication.Negotiate.Test (4)
Microsoft.AspNetCore.DataProtection.Tests (2)
Microsoft.AspNetCore.Diagnostics.Middleware.Tests (1)
Microsoft.AspNetCore.Hosting (25)
Microsoft.AspNetCore.Hosting.Tests (2)
Microsoft.AspNetCore.HttpLogging.Tests (2)
Microsoft.AspNetCore.Identity.FunctionalTests (2)
Microsoft.AspNetCore.Mvc.FunctionalTests (3)
Microsoft.AspNetCore.Mvc.Testing (26)
Microsoft.AspNetCore.OpenApi.Tests (1)
Microsoft.AspNetCore.OutputCaching.Tests (43)
Microsoft.AspNetCore.ResponseCaching.Tests (39)
Microsoft.AspNetCore.Routing.FunctionalTests (2)
Microsoft.AspNetCore.Server.HttpSys.FunctionalTests (3)
Microsoft.AspNetCore.Server.Kestrel.Transport.Quic.Tests (7)
Microsoft.AspNetCore.Tests (8)
Microsoft.Extensions.AmbientMetadata.Application (2)
Microsoft.Extensions.AmbientMetadata.Application.Tests (1)
Microsoft.Extensions.Hosting (97)
HostingHostBuilderExtensions.cs (70)
23/// Provides extension methods for the <see cref="IHostBuilder"/> from the hosting package.
31/// <param name="hostBuilder">The <see cref="IHostBuilder"/> to configure.</param>
33/// <returns>The <see cref="IHostBuilder"/>.</returns>
34public static IHostBuilder UseEnvironment(this IHostBuilder hostBuilder, string environment)
51/// <param name="hostBuilder">The <see cref="IHostBuilder"/> to configure.</param>
53/// <returns>The <see cref="IHostBuilder"/>.</returns>
54public static IHostBuilder UseContentRoot(this IHostBuilder hostBuilder, string contentRoot)
70/// <param name="hostBuilder">The <see cref="IHostBuilder"/> to configure.</param>
72/// <returns>The <see cref="IHostBuilder"/>.</returns>
73public static IHostBuilder UseDefaultServiceProvider(this IHostBuilder hostBuilder, Action<ServiceProviderOptions> configure)
79/// <param name="hostBuilder">The <see cref="IHostBuilder"/> to configure.</param>
81/// <returns>The <see cref="IHostBuilder"/>.</returns>
82public static IHostBuilder UseDefaultServiceProvider(this IHostBuilder hostBuilder, Action<HostBuilderContext, ServiceProviderOptions> configure)
95/// <param name="hostBuilder">The <see cref="IHostBuilder" /> to configure.</param>
97/// <returns>The same instance of the <see cref="IHostBuilder"/> for chaining.</returns>
98public static IHostBuilder ConfigureLogging(this IHostBuilder hostBuilder, Action<HostBuilderContext, ILoggingBuilder> configureLogging)
106/// <param name="hostBuilder">The <see cref="IHostBuilder" /> to configure.</param>
108/// <returns>The same instance of the <see cref="IHostBuilder"/> for chaining.</returns>
109public static IHostBuilder ConfigureLogging(this IHostBuilder hostBuilder, Action<ILoggingBuilder> configureLogging)
117/// <param name="hostBuilder">The <see cref="IHostBuilder" /> to configure.</param>
119/// <returns>The same instance of the <see cref="IHostBuilder"/> for chaining.</returns>
120public static IHostBuilder ConfigureHostOptions(this IHostBuilder hostBuilder, Action<HostBuilderContext, HostOptions> configureOptions)
129/// <param name="hostBuilder">The <see cref="IHostBuilder" /> to configure.</param>
131/// <returns>The same instance of the <see cref="IHostBuilder"/> for chaining.</returns>
132public static IHostBuilder ConfigureHostOptions(this IHostBuilder hostBuilder, Action<HostOptions> configureOptions)
142/// <param name="hostBuilder">The <see cref="IHostBuilder" /> to configure.</param>
145/// <returns>The same instance of the <see cref="IHostBuilder"/> for chaining.</returns>
146public static IHostBuilder ConfigureAppConfiguration(this IHostBuilder hostBuilder, Action<IConfigurationBuilder> configureDelegate)
154/// <param name="hostBuilder">The <see cref="IHostBuilder" /> to configure.</param>
156/// <returns>The same instance of the <see cref="IHostBuilder"/> for chaining.</returns>
157public static IHostBuilder ConfigureServices(this IHostBuilder hostBuilder, Action<IServiceCollection> configureDelegate)
167/// <param name="hostBuilder">The <see cref="IHostBuilder" /> to configure.</param>
169/// <returns>The same instance of the <see cref="IHostBuilder"/> for chaining.</returns>
170public static IHostBuilder ConfigureContainer<TContainerBuilder>(this IHostBuilder hostBuilder, Action<TContainerBuilder> configureDelegate)
176/// Configures an existing <see cref="IHostBuilder"/> instance with pre-configured defaults. This will overwrite
180/// The following defaults are applied to the <see cref="IHostBuilder"/>:
193/// <returns>The same instance of the <see cref="IHostBuilder"/> for chaining.</returns>
194public static IHostBuilder ConfigureDefaults(this IHostBuilder builder, string[]? args)
339/// <param name="hostBuilder">The <see cref="IHostBuilder" /> to configure.</param>
340/// <returns>The same instance of the <see cref="IHostBuilder"/> for chaining.</returns>
345public static IHostBuilder UseConsoleLifetime(this IHostBuilder hostBuilder)
354/// <param name="hostBuilder">The <see cref="IHostBuilder" /> to configure.</param>
356/// <returns>The same instance of the <see cref="IHostBuilder"/> for chaining.</returns>
361public static IHostBuilder UseConsoleLifetime(this IHostBuilder hostBuilder, Action<ConsoleLifetimeOptions> configureOptions)
373/// <param name="hostBuilder">The <see cref="IHostBuilder" /> to configure.</param>
380public static Task RunConsoleAsync(this IHostBuilder hostBuilder, CancellationToken cancellationToken = default)
388/// <param name="hostBuilder">The <see cref="IHostBuilder" /> to configure.</param>
396public static Task RunConsoleAsync(this IHostBuilder hostBuilder, Action<ConsoleLifetimeOptions> configureOptions, CancellationToken cancellationToken = default)
404/// <param name="hostBuilder">The <see cref="IHostBuilder" /> to configure.</param>
406/// <returns>The same instance of the <see cref="IHostBuilder"/> for chaining.</returns>
407public static IHostBuilder ConfigureMetrics(this IHostBuilder hostBuilder, Action<IMetricsBuilder> configureMetrics)
415/// <param name="hostBuilder">The <see cref="IHostBuilder" /> to configure.</param>
417/// <returns>The same instance of the <see cref="IHostBuilder"/> for chaining.</returns>
418public static IHostBuilder ConfigureMetrics(this IHostBuilder hostBuilder, Action<HostBuilderContext, IMetricsBuilder> configureMetrics)
Microsoft.Extensions.Hosting.Abstractions (18)
Microsoft.Extensions.Hosting.Systemd (4)
Microsoft.Extensions.Hosting.Testing (44)
FakeHostingExtensions.cs (27)
73/// <param name="builder">An <see cref="IHostBuilder"/> instance.</param>
75/// <returns>The <see cref="IHostBuilder"/> instance.</returns>
76public static IHostBuilder AddFakeLoggingOutputSink(this IHostBuilder builder, Action<string> callback)
100/// Exposes <see cref="IHostBuilder"/> for changes via a delegate.
102/// <param name="builder">An <see cref="IHostBuilder"/> instance.</param>
103/// <param name="configure">Configures the <see cref="IHostBuilder"/> instance.</param>
104/// <returns>The <see cref="IHostBuilder"/> instance.</returns>
108public static IHostBuilder Configure(this IHostBuilder builder, Action<IHostBuilder> configure)
119/// <param name="builder">An <see cref="IHostBuilder"/> instance.</param>
121/// <returns>The <see cref="IHostBuilder"/> instance.</returns>
122public static IHostBuilder ConfigureHostConfiguration(this IHostBuilder builder, params (string key, string value)[] configurations)
137/// <param name="builder">An <see cref="IHostBuilder"/> instance.</param>
140/// <returns>The <see cref="IHostBuilder"/> instance.</returns>
141public static IHostBuilder ConfigureHostConfiguration(this IHostBuilder builder, string key, string value)
150/// <param name="builder">An <see cref="IHostBuilder"/> instance.</param>
152/// <returns>The <see cref="IHostBuilder"/> instance.</returns>
153public static IHostBuilder ConfigureAppConfiguration(this IHostBuilder builder, params (string key, string value)[] configurations)
168/// <param name="builder">An <see cref="IHostBuilder"/> instance.</param>
171/// <returns>The <see cref="IHostBuilder"/> instance.</returns>
172public static IHostBuilder ConfigureAppConfiguration(this IHostBuilder builder, string key, string value)
Microsoft.Extensions.Hosting.Testing.Tests (24)
Microsoft.Extensions.Hosting.WindowsServices (8)
Negotiate.Client (1)
Negotiate.Server (1)
NegotiateAuthSample (1)
RoutingSandbox (1)
RoutingWebSite (1)
Sandbox (1)
SelfHostServer (1)
SignalR.Client.FunctionalTestApp (1)
Sockets.BindTests (18)
Sockets.FunctionalTests (12)
SystemdTestApp (1)