MetricsBuilderConfigurationExtensions.AddConfiguration 方法
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
從提供的 IConfiguration 區段讀取計量組態,並設定已啟用哪些 計量、 檢測和 IMetricsListeners 。
public:
[System::Runtime::CompilerServices::Extension]
static Microsoft::Extensions::Diagnostics::Metrics::IMetricsBuilder ^ AddConfiguration(Microsoft::Extensions::Diagnostics::Metrics::IMetricsBuilder ^ builder, Microsoft::Extensions::Configuration::IConfiguration ^ configuration);
public static Microsoft.Extensions.Diagnostics.Metrics.IMetricsBuilder AddConfiguration (this Microsoft.Extensions.Diagnostics.Metrics.IMetricsBuilder builder, Microsoft.Extensions.Configuration.IConfiguration configuration);
static member AddConfiguration : Microsoft.Extensions.Diagnostics.Metrics.IMetricsBuilder * Microsoft.Extensions.Configuration.IConfiguration -> Microsoft.Extensions.Diagnostics.Metrics.IMetricsBuilder
<Extension()>
Public Function AddConfiguration (builder As IMetricsBuilder, configuration As IConfiguration) As IMetricsBuilder
參數
- builder
- IMetricsBuilder
- configuration
- IConfiguration
要載入的組態區段。
傳回
鏈結的原始 IMetricsBuilder 。