LoggingEnrichmentExtensions.EnableEnrichment 方法
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
重载
EnableEnrichment(ILoggingBuilder) |
启用日志记录基础结构中的扩充功能。 |
EnableEnrichment(ILoggingBuilder, IConfigurationSection) |
启用日志记录基础结构中的扩充功能。 |
EnableEnrichment(ILoggingBuilder, Action<LoggerEnrichmentOptions>) |
启用日志记录基础结构中的扩充功能。 |
EnableEnrichment(ILoggingBuilder)
启用日志记录基础结构中的扩充功能。
public:
[System::Runtime::CompilerServices::Extension]
static Microsoft::Extensions::Logging::ILoggingBuilder ^ EnableEnrichment(Microsoft::Extensions::Logging::ILoggingBuilder ^ builder);
public static Microsoft.Extensions.Logging.ILoggingBuilder EnableEnrichment (this Microsoft.Extensions.Logging.ILoggingBuilder builder);
static member EnableEnrichment : Microsoft.Extensions.Logging.ILoggingBuilder -> Microsoft.Extensions.Logging.ILoggingBuilder
<Extension()>
Public Function EnableEnrichment (builder As ILoggingBuilder) As ILoggingBuilder
参数
- builder
- ILoggingBuilder
要向其添加日志记录的依赖项注入容器。
返回
builder
的值。
适用于
EnableEnrichment(ILoggingBuilder, IConfigurationSection)
启用日志记录基础结构中的扩充功能。
public:
[System::Runtime::CompilerServices::Extension]
static Microsoft::Extensions::Logging::ILoggingBuilder ^ EnableEnrichment(Microsoft::Extensions::Logging::ILoggingBuilder ^ builder, Microsoft::Extensions::Configuration::IConfigurationSection ^ section);
public static Microsoft.Extensions.Logging.ILoggingBuilder EnableEnrichment (this Microsoft.Extensions.Logging.ILoggingBuilder builder, Microsoft.Extensions.Configuration.IConfigurationSection section);
static member EnableEnrichment : Microsoft.Extensions.Logging.ILoggingBuilder * Microsoft.Extensions.Configuration.IConfigurationSection -> Microsoft.Extensions.Logging.ILoggingBuilder
<Extension()>
Public Function EnableEnrichment (builder As ILoggingBuilder, section As IConfigurationSection) As ILoggingBuilder
参数
- builder
- ILoggingBuilder
要向其添加日志记录的依赖项注入容器。
- section
- IConfigurationSection
包含 LoggerEnrichmentOptions的配置节。
返回
builder
的值。
适用于
EnableEnrichment(ILoggingBuilder, Action<LoggerEnrichmentOptions>)
启用日志记录基础结构中的扩充功能。
public:
[System::Runtime::CompilerServices::Extension]
static Microsoft::Extensions::Logging::ILoggingBuilder ^ EnableEnrichment(Microsoft::Extensions::Logging::ILoggingBuilder ^ builder, Action<Microsoft::Extensions::Logging::LoggerEnrichmentOptions ^> ^ configure);
public static Microsoft.Extensions.Logging.ILoggingBuilder EnableEnrichment (this Microsoft.Extensions.Logging.ILoggingBuilder builder, Action<Microsoft.Extensions.Logging.LoggerEnrichmentOptions> configure);
static member EnableEnrichment : Microsoft.Extensions.Logging.ILoggingBuilder * Action<Microsoft.Extensions.Logging.LoggerEnrichmentOptions> -> Microsoft.Extensions.Logging.ILoggingBuilder
<Extension()>
Public Function EnableEnrichment (builder As ILoggingBuilder, configure As Action(Of LoggerEnrichmentOptions)) As ILoggingBuilder
参数
- builder
- ILoggingBuilder
要向其添加日志记录的依赖项注入容器。
- configure
- Action<LoggerEnrichmentOptions>
委托微调选项。
返回
builder
的值。