UseHostingEnvironment Method
Definition
- Namespace
- Cuemon.Extensions.AspNetCore.Hosting
- Assemblies
- Cuemon.Extensions.AspNetCore.dll
UseHostingEnvironment(IApplicationBuilder, Action<HostingEnvironmentOptions>)
Adds a hosting environment HTTP header to the IApplicationBuilder request execution pipeline.
public static IApplicationBuilder UseHostingEnvironment(this IApplicationBuilder builder, Action<HostingEnvironmentOptions> setup = null)
Parameters
builderIApplicationBuilderThe type that provides the mechanisms to configure an application’s request pipeline.
setupAction<HostingEnvironmentOptions>The HostingEnvironmentOptions middleware which may be configured.
Returns
- IApplicationBuilder
A reference to this instance after the operation has completed.
Remarks
Default HTTP header name is X-Hosting-Environment.