EventSourceLoggerFactoryExtensions.AddEventSourceLogger Метод

Определение

Перегрузки

AddEventSourceLogger(ILoggerFactory)
Является устаревшей.

Добавляет средство ведения журнала событий, для которого задан уровень LogLevel.Information или более высокий.Adds an event logger that is enabled for LogLevel.Information or higher.

AddEventSourceLogger(ILoggingBuilder)

Добавляет средство ведения журнала событий с именем EventSource в фабрику.Adds an event logger named 'EventSource' to the factory.

AddEventSourceLogger(ILoggerFactory)

Внимание!

This method is obsolete and will be removed in a future version. The recommended alternative is AddEventSourceLogger(this ILoggingBuilder builder).

Добавляет средство ведения журнала событий, для которого задан уровень LogLevel.Information или более высокий.Adds an event logger that is enabled for LogLevel.Information or higher.

public:
[System::Runtime::CompilerServices::Extension]
 static Microsoft::Extensions::Logging::ILoggerFactory ^ AddEventSourceLogger(Microsoft::Extensions::Logging::ILoggerFactory ^ factory);
public static Microsoft.Extensions.Logging.ILoggerFactory AddEventSourceLogger (this Microsoft.Extensions.Logging.ILoggerFactory factory);
[System.Obsolete("This method is obsolete and will be removed in a future version. The recommended alternative is AddEventSourceLogger(this ILoggingBuilder builder).")]
public static Microsoft.Extensions.Logging.ILoggerFactory AddEventSourceLogger (this Microsoft.Extensions.Logging.ILoggerFactory factory);
static member AddEventSourceLogger : Microsoft.Extensions.Logging.ILoggerFactory -> Microsoft.Extensions.Logging.ILoggerFactory
[<System.Obsolete("This method is obsolete and will be removed in a future version. The recommended alternative is AddEventSourceLogger(this ILoggingBuilder builder).")>]
static member AddEventSourceLogger : Microsoft.Extensions.Logging.ILoggerFactory -> Microsoft.Extensions.Logging.ILoggerFactory
<Extension()>
Public Function AddEventSourceLogger (factory As ILoggerFactory) As ILoggerFactory

Параметры

factory
ILoggerFactory

Аргумент метода расширения.The extension method argument.

Возвращаемое значение

ILoggerFactory
Атрибуты

Применяется к

AddEventSourceLogger(ILoggingBuilder)

Добавляет средство ведения журнала событий с именем EventSource в фабрику.Adds an event logger named 'EventSource' to the factory.

public:
[System::Runtime::CompilerServices::Extension]
 static Microsoft::Extensions::Logging::ILoggingBuilder ^ AddEventSourceLogger(Microsoft::Extensions::Logging::ILoggingBuilder ^ builder);
public static Microsoft.Extensions.Logging.ILoggingBuilder AddEventSourceLogger (this Microsoft.Extensions.Logging.ILoggingBuilder builder);
static member AddEventSourceLogger : Microsoft.Extensions.Logging.ILoggingBuilder -> Microsoft.Extensions.Logging.ILoggingBuilder
<Extension()>
Public Function AddEventSourceLogger (builder As ILoggingBuilder) As ILoggingBuilder

Параметры

builder
ILoggingBuilder

Аргумент метода расширения.The extension method argument.

Возвращаемое значение

ILoggingBuilder

ILoggingBuilder для объединения дополнительных вызовов в цепочку.The ILoggingBuilder so that additional calls can be chained.

Применяется к