HostingHostBuilderExtensions.ConfigureMetrics Metode
Penting
Beberapa informasi terkait produk prarilis yang dapat diubah secara signifikan sebelum dirilis. Microsoft tidak memberikan jaminan, tersirat maupun tersurat, sehubungan dengan informasi yang diberikan di sini.
ConfigureMetrics(IHostBuilder, Action<HostBuilderContext,IMetricsBuilder>) |
Menambahkan delegasi untuk mengonfigurasi yang disediakan IMetricsBuilder. Ini dapat dipanggil beberapa kali. |
ConfigureMetrics(IHostBuilder, Action<IMetricsBuilder>) |
Menambahkan delegasi untuk mengonfigurasi yang disediakan IMetricsBuilder. Ini dapat dipanggil beberapa kali. |
Menambahkan delegasi untuk mengonfigurasi yang disediakan IMetricsBuilder. Ini dapat dipanggil beberapa kali.
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
Parameter
- hostBuilder
- IHostBuilder
untuk IHostBuilder mengonfigurasi.
- configureMetrics
- Action<HostBuilderContext,IMetricsBuilder>
Delegasi yang mengonfigurasi IMetricsBuilder.
Mengembalikan
Instans yang sama untuk penautan IHostBuilder .
Berlaku untuk
.NET 9 (package-provided) dan versi lainnya
Produk | Versi |
---|---|
.NET | 6 (package-provided), 7 (package-provided), 8 (package-provided), 9 (package-provided) |
.NET Framework | 4.7 (package-provided), 4.7.1 (package-provided), 4.7.2 (package-provided), 4.8 (package-provided) |
.NET Standard | 2.0 (package-provided), 2.1 (package-provided) |
Menambahkan delegasi untuk mengonfigurasi yang disediakan IMetricsBuilder. Ini dapat dipanggil beberapa kali.
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
Parameter
- hostBuilder
- IHostBuilder
untuk IHostBuilder mengonfigurasi.
- configureMetrics
- Action<IMetricsBuilder>
Delegasi yang mengonfigurasi IMetricsBuilder.
Mengembalikan
Instans yang sama untuk penautan IHostBuilder .
Berlaku untuk
.NET 9 (package-provided) dan versi lainnya
Produk | Versi |
---|---|
.NET | 6 (package-provided), 7 (package-provided), 8 (package-provided), 9 (package-provided) |
.NET Framework | 4.7 (package-provided), 4.7.1 (package-provided), 4.7.2 (package-provided), 4.8 (package-provided) |
.NET Standard | 2.0 (package-provided), 2.1 (package-provided) |
Umpan balik .NET
.NET adalah proyek sumber terbuka. Pilih tautan untuk memberikan umpan balik: