共用方式為


HostingEnvironmentExtensions Class

Definition

Extension methods for IHostingEnvironment.

public ref class HostingEnvironmentExtensions abstract sealed
public static class HostingEnvironmentExtensions
type HostingEnvironmentExtensions = class
Public Module HostingEnvironmentExtensions
Inheritance
HostingEnvironmentExtensions

Methods

IsDevelopment(IHostingEnvironment)

Checks if the current hosting environment name is Development.

IsEnvironment(IHostingEnvironment, String)

Compares the current hosting environment name against the specified value.

IsProduction(IHostingEnvironment)

Checks if the current hosting environment name is Production.

IsStaging(IHostingEnvironment)

Checks if the current hosting environment name is Staging.

Applies to