EventDefinition<TParam> Constructors

Definition

Overloads

EventDefinition<TParam>(EventId, LogLevel, Action<ILogger,TParam,Exception>)

Creates an event definition instance.

EventDefinition<TParam>(EventId, LogLevel, String, Action<ILogger,TParam,Exception>)

Creates an event definition instance.

EventDefinition<TParam>(ILoggingOptions, EventId, LogLevel, String, Func<LogLevel,Action<ILogger,TParam,Exception>>)

Creates an event definition instance.

EventDefinition<TParam>(EventId, LogLevel, Action<ILogger,TParam,Exception>)

Creates an event definition instance.

public EventDefinition (Microsoft.Extensions.Logging.EventId eventId, Microsoft.Extensions.Logging.LogLevel level, Action<Microsoft.Extensions.Logging.ILogger,TParam,Exception> logAction);
new Microsoft.EntityFrameworkCore.Diagnostics.EventDefinition<'Param> : Microsoft.Extensions.Logging.EventId * Microsoft.Extensions.Logging.LogLevel * Action<Microsoft.Extensions.Logging.ILogger, 'Param, Exception> -> Microsoft.EntityFrameworkCore.Diagnostics.EventDefinition<'Param>
Public Sub New (eventId As EventId, level As LogLevel, logAction As Action(Of ILogger, TParam, Exception))

Parameters

eventId
EventId

The EventId.

level
LogLevel

The LogLevel at which the event will be logged.

logAction
Action<ILogger,TParam,Exception>

A cached delegate for logging the event.

Applies to

EventDefinition<TParam>(EventId, LogLevel, String, Action<ILogger,TParam,Exception>)

Creates an event definition instance.

public EventDefinition (Microsoft.Extensions.Logging.EventId eventId, Microsoft.Extensions.Logging.LogLevel level, string eventIdCode, Action<Microsoft.Extensions.Logging.ILogger,TParam,Exception> logAction);
new Microsoft.EntityFrameworkCore.Diagnostics.EventDefinition<'Param> : Microsoft.Extensions.Logging.EventId * Microsoft.Extensions.Logging.LogLevel * string * Action<Microsoft.Extensions.Logging.ILogger, 'Param, Exception> -> Microsoft.EntityFrameworkCore.Diagnostics.EventDefinition<'Param>
Public Sub New (eventId As EventId, level As LogLevel, eventIdCode As String, logAction As Action(Of ILogger, TParam, Exception))

Parameters

eventId
EventId

The EventId.

level
LogLevel

The LogLevel at which the event will be logged.

eventIdCode
String

A string representing the code that should be passed to ConfigureWanings.

logAction
Action<ILogger,TParam,Exception>

A cached delegate for logging the event.

Applies to

EventDefinition<TParam>(ILoggingOptions, EventId, LogLevel, String, Func<LogLevel,Action<ILogger,TParam,Exception>>)

Creates an event definition instance.

public EventDefinition (Microsoft.EntityFrameworkCore.Diagnostics.ILoggingOptions loggingOptions, Microsoft.Extensions.Logging.EventId eventId, Microsoft.Extensions.Logging.LogLevel level, string eventIdCode, Func<Microsoft.Extensions.Logging.LogLevel,Action<Microsoft.Extensions.Logging.ILogger,TParam,Exception>> logActionFunc);
public EventDefinition (Microsoft.EntityFrameworkCore.Diagnostics.ILoggingOptions loggingOptions, Microsoft.Extensions.Logging.EventId eventId, Microsoft.Extensions.Logging.LogLevel level, string eventIdCode, Func<Microsoft.Extensions.Logging.LogLevel,Action<Microsoft.Extensions.Logging.ILogger,TParam,Exception?>> logActionFunc);
new Microsoft.EntityFrameworkCore.Diagnostics.EventDefinition<'Param> : Microsoft.EntityFrameworkCore.Diagnostics.ILoggingOptions * Microsoft.Extensions.Logging.EventId * Microsoft.Extensions.Logging.LogLevel * string * Func<Microsoft.Extensions.Logging.LogLevel, Action<Microsoft.Extensions.Logging.ILogger, 'Param, Exception>> -> Microsoft.EntityFrameworkCore.Diagnostics.EventDefinition<'Param>
Public Sub New (loggingOptions As ILoggingOptions, eventId As EventId, level As LogLevel, eventIdCode As String, logActionFunc As Func(Of LogLevel, Action(Of ILogger, TParam, Exception)))

Parameters

loggingOptions
ILoggingOptions

Logging options.

eventId
EventId

The EventId.

level
LogLevel

The LogLevel at which the event will be logged.

eventIdCode
String

A string representing the code that should be passed to ConfigureWarnings(Action<WarningsConfigurationBuilder>).

logActionFunc
Func<LogLevel,Action<ILogger,TParam,Exception>>

Function to create a cached delegate for logging the event.

Applies to