Note

Access to this page requires authorization. You can try signing in or .

Access to this page requires authorization. You can try .

HostBuilderContext Class

Definition

Namespace:
Microsoft.Extensions.Hosting
Assembly:
Microsoft.Extensions.Hosting.Abstractions.dll
Package:
Microsoft.Extensions.Hosting.Abstractions v11.0.0-preview.5.26302.115
Source:
HostBuilderContext.cs
Source:
HostBuilderContext.cs
Source:
HostBuilderContext.cs
Source:
HostBuilderContext.cs

Important

Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.

Context containing the common services on the IHost. Some properties may be null until set by the IHost.

public ref class HostBuilderContext
public class HostBuilderContext
type HostBuilderContext = class
Public Class HostBuilderContext
Inheritance
HostBuilderContext

Constructors

Name Description
HostBuilderContext(IDictionary<Object,Object>)

Initializes a new instance of HostBuilderContext.

Properties

Name Description
Configuration

The IConfiguration containing the merged configuration of the application and the IHost.

HostingEnvironment

The IHostEnvironment initialized by the IHost.

Properties

A central location for sharing state between components during the host building process.

Methods

Name Description
Equals(Object)

Determines whether the specified object is equal to the current object.

(Inherited from Object)
GetHashCode()

Serves as the default hash function.

(Inherited from Object)
GetType()

Gets the Type of the current instance.

(Inherited from Object)
MemberwiseClone()

Creates a shallow copy of the current Object.

(Inherited from Object)
ToString()

Returns a string that represents the current object.

(Inherited from Object)

Applies to


Feedback

Was this page helpful?