HostingHostBuilderExtensions.ConfigureMetrics 方法
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
重载
ConfigureMetrics(IHostBuilder, Action<HostBuilderContext,IMetricsBuilder>) |
添加一个委托来配置提供的 IMetricsBuilder。 这可多次进行调用。 |
ConfigureMetrics(IHostBuilder, Action<IMetricsBuilder>) |
添加一个委托来配置提供的 IMetricsBuilder。 这可多次进行调用。 |
ConfigureMetrics(IHostBuilder, Action<HostBuilderContext,IMetricsBuilder>)
添加一个委托来配置提供的 IMetricsBuilder。 这可多次进行调用。
public:
[System::Runtime::CompilerServices::Extension]
static Microsoft::Extensions::Hosting::IHostBuilder ^ ConfigureMetrics(Microsoft::Extensions::Hosting::IHostBuilder ^ hostBuilder, Action<Microsoft::Extensions::Hosting::HostBuilderContext ^, Microsoft::Extensions::Diagnostics::Metrics::IMetricsBuilder ^> ^ configureMetrics);
public static Microsoft.Extensions.Hosting.IHostBuilder ConfigureMetrics (this Microsoft.Extensions.Hosting.IHostBuilder hostBuilder, Action<Microsoft.Extensions.Hosting.HostBuilderContext,Microsoft.Extensions.Diagnostics.Metrics.IMetricsBuilder> configureMetrics);
static member ConfigureMetrics : Microsoft.Extensions.Hosting.IHostBuilder * Action<Microsoft.Extensions.Hosting.HostBuilderContext, Microsoft.Extensions.Diagnostics.Metrics.IMetricsBuilder> -> Microsoft.Extensions.Hosting.IHostBuilder
<Extension()>
Public Function ConfigureMetrics (hostBuilder As IHostBuilder, configureMetrics As Action(Of HostBuilderContext, IMetricsBuilder)) As IHostBuilder
参数
- hostBuilder
- IHostBuilder
要配置的 IHostBuilder。
- configureMetrics
- Action<HostBuilderContext,IMetricsBuilder>
用于配置 IMetricsBuilder 的委托。
返回
用于链接的相同 IHostBuilder 实例。
适用于
ConfigureMetrics(IHostBuilder, Action<IMetricsBuilder>)
添加一个委托来配置提供的 IMetricsBuilder。 这可多次进行调用。
public:
[System::Runtime::CompilerServices::Extension]
static Microsoft::Extensions::Hosting::IHostBuilder ^ ConfigureMetrics(Microsoft::Extensions::Hosting::IHostBuilder ^ hostBuilder, Action<Microsoft::Extensions::Diagnostics::Metrics::IMetricsBuilder ^> ^ configureMetrics);
public static Microsoft.Extensions.Hosting.IHostBuilder ConfigureMetrics (this Microsoft.Extensions.Hosting.IHostBuilder hostBuilder, Action<Microsoft.Extensions.Diagnostics.Metrics.IMetricsBuilder> configureMetrics);
static member ConfigureMetrics : Microsoft.Extensions.Hosting.IHostBuilder * Action<Microsoft.Extensions.Diagnostics.Metrics.IMetricsBuilder> -> Microsoft.Extensions.Hosting.IHostBuilder
<Extension()>
Public Function ConfigureMetrics (hostBuilder As IHostBuilder, configureMetrics As Action(Of IMetricsBuilder)) As IHostBuilder
参数
- hostBuilder
- IHostBuilder
要配置的 IHostBuilder。
- configureMetrics
- Action<IMetricsBuilder>
用于配置 IMetricsBuilder 的委托。
返回
用于链接的相同 IHostBuilder 实例。