EventDefinition<TParam1,TParam2,TParam3,TParam4,TParam5,TParam6>.Log 方法

定义

重载

Log<TLoggerCategory>(IDiagnosticsLogger<TLoggerCategory>, TParam1, TParam2, TParam3, TParam4, TParam5, TParam6)

记录事件,如果事件已配置为被视为错误,则引发 。

Log<TLoggerCategory>(IDiagnosticsLogger<TLoggerCategory>, WarningBehavior, TParam1, TParam2, TParam3, TParam4, TParam5, TParam6)

记录事件,如果事件已配置为被视为错误,则引发 。

Log<TLoggerCategory>(IDiagnosticsLogger<TLoggerCategory>, TParam1, TParam2, TParam3, TParam4, TParam5, TParam6, Exception)
已过时.

记录事件,如果事件已配置为被视为错误,则引发 。

Log<TLoggerCategory>(IDiagnosticsLogger<TLoggerCategory>, WarningBehavior, TParam1, TParam2, TParam3, TParam4, TParam5, TParam6, Exception)

记录事件,如果事件已配置为被视为错误,则引发 。

Log<TLoggerCategory>(IDiagnosticsLogger<TLoggerCategory>, TParam1, TParam2, TParam3, TParam4, TParam5, TParam6)

记录事件,如果事件已配置为被视为错误,则引发 。

public virtual void Log<TLoggerCategory> (Microsoft.EntityFrameworkCore.Diagnostics.IDiagnosticsLogger<TLoggerCategory> logger, TParam1 arg1, TParam2 arg2, TParam3 arg3, TParam4 arg4, TParam5 arg5, TParam6 arg6) where TLoggerCategory : Microsoft.EntityFrameworkCore.Diagnostics.LoggerCategory<TLoggerCategory>, new();
abstract member Log : Microsoft.EntityFrameworkCore.Diagnostics.IDiagnosticsLogger<'LoggerCategory (requires 'LoggerCategory :> Microsoft.EntityFrameworkCore.Diagnostics.LoggerCategory<'LoggerCategory> and 'LoggerCategory : (new : unit -> 'LoggerCategory))> * 'TParam1 * 'TParam2 * 'TParam3 * 'TParam4 * 'TParam5 * 'TParam6 -> unit (requires 'LoggerCategory :> Microsoft.EntityFrameworkCore.Diagnostics.LoggerCategory<'LoggerCategory> and 'LoggerCategory : (new : unit -> 'LoggerCategory))
override this.Log : Microsoft.EntityFrameworkCore.Diagnostics.IDiagnosticsLogger<'LoggerCategory (requires 'LoggerCategory :> Microsoft.EntityFrameworkCore.Diagnostics.LoggerCategory<'LoggerCategory> and 'LoggerCategory : (new : unit -> 'LoggerCategory))> * 'TParam1 * 'TParam2 * 'TParam3 * 'TParam4 * 'TParam5 * 'TParam6 -> unit (requires 'LoggerCategory :> Microsoft.EntityFrameworkCore.Diagnostics.LoggerCategory<'LoggerCategory> and 'LoggerCategory : (new : unit -> 'LoggerCategory))
Public Overridable Sub Log(Of TLoggerCategory As {LoggerCategory(Of TLoggerCategory)New}) (logger As IDiagnosticsLogger(Of TLoggerCategory), arg1 As TParam1, arg2 As TParam2, arg3 As TParam3, arg4 As TParam4, arg5 As TParam5, arg6 As TParam6)

类型参数

TLoggerCategory

DbLoggerCategory

参数

logger
IDiagnosticsLogger<TLoggerCategory>

事件应记录到的记录器。

arg1
TParam1

第一个消息参数。

arg2
TParam2

第二个消息参数。

arg3
TParam3

第三个消息参数。

arg4
TParam4

第四个消息参数。

arg5
TParam5

第五个消息参数。

arg6
TParam6

第六个消息参数。

适用于

Log<TLoggerCategory>(IDiagnosticsLogger<TLoggerCategory>, WarningBehavior, TParam1, TParam2, TParam3, TParam4, TParam5, TParam6)

记录事件,如果事件已配置为被视为错误,则引发 。

public virtual void Log<TLoggerCategory> (Microsoft.EntityFrameworkCore.Diagnostics.IDiagnosticsLogger<TLoggerCategory> logger, Microsoft.EntityFrameworkCore.WarningBehavior warningBehavior, TParam1 arg1, TParam2 arg2, TParam3 arg3, TParam4 arg4, TParam5 arg5, TParam6 arg6) where TLoggerCategory : Microsoft.EntityFrameworkCore.Diagnostics.LoggerCategory<TLoggerCategory>, new();
abstract member Log : Microsoft.EntityFrameworkCore.Diagnostics.IDiagnosticsLogger<'LoggerCategory (requires 'LoggerCategory :> Microsoft.EntityFrameworkCore.Diagnostics.LoggerCategory<'LoggerCategory> and 'LoggerCategory : (new : unit -> 'LoggerCategory))> * Microsoft.EntityFrameworkCore.WarningBehavior * 'TParam1 * 'TParam2 * 'TParam3 * 'TParam4 * 'TParam5 * 'TParam6 -> unit (requires 'LoggerCategory :> Microsoft.EntityFrameworkCore.Diagnostics.LoggerCategory<'LoggerCategory> and 'LoggerCategory : (new : unit -> 'LoggerCategory))
override this.Log : Microsoft.EntityFrameworkCore.Diagnostics.IDiagnosticsLogger<'LoggerCategory (requires 'LoggerCategory :> Microsoft.EntityFrameworkCore.Diagnostics.LoggerCategory<'LoggerCategory> and 'LoggerCategory : (new : unit -> 'LoggerCategory))> * Microsoft.EntityFrameworkCore.WarningBehavior * 'TParam1 * 'TParam2 * 'TParam3 * 'TParam4 * 'TParam5 * 'TParam6 -> unit (requires 'LoggerCategory :> Microsoft.EntityFrameworkCore.Diagnostics.LoggerCategory<'LoggerCategory> and 'LoggerCategory : (new : unit -> 'LoggerCategory))
Public Overridable Sub Log(Of TLoggerCategory As {LoggerCategory(Of TLoggerCategory)New}) (logger As IDiagnosticsLogger(Of TLoggerCategory), warningBehavior As WarningBehavior, arg1 As TParam1, arg2 As TParam2, arg3 As TParam3, arg4 As TParam4, arg5 As TParam5, arg6 As TParam6)

类型参数

TLoggerCategory

DbLoggerCategory

参数

logger
IDiagnosticsLogger<TLoggerCategory>

事件应记录到的记录器。

warningBehavior
WarningBehavior

是应记录事件、作为异常引发还是忽略事件。

arg1
TParam1

第一个消息参数。

arg2
TParam2

第二个消息参数。

arg3
TParam3

第三个消息参数。

arg4
TParam4

第四个消息参数。

arg5
TParam5

第五个消息参数。

arg6
TParam6

第六个消息参数。

适用于

Log<TLoggerCategory>(IDiagnosticsLogger<TLoggerCategory>, TParam1, TParam2, TParam3, TParam4, TParam5, TParam6, Exception)

注意

Use the other overload

记录事件,如果事件已配置为被视为错误,则引发 。

public virtual void Log<TLoggerCategory> (Microsoft.EntityFrameworkCore.Diagnostics.IDiagnosticsLogger<TLoggerCategory> logger, TParam1 arg1, TParam2 arg2, TParam3 arg3, TParam4 arg4, TParam5 arg5, TParam6 arg6, Exception exception = default) where TLoggerCategory : Microsoft.EntityFrameworkCore.Diagnostics.LoggerCategory<TLoggerCategory>, new();
[System.Obsolete("Use the other overload")]
public virtual void Log<TLoggerCategory> (Microsoft.EntityFrameworkCore.Diagnostics.IDiagnosticsLogger<TLoggerCategory> logger, TParam1 arg1, TParam2 arg2, TParam3 arg3, TParam4 arg4, TParam5 arg5, TParam6 arg6, Exception exception = default) where TLoggerCategory : Microsoft.EntityFrameworkCore.Diagnostics.LoggerCategory<TLoggerCategory>, new();
abstract member Log : Microsoft.EntityFrameworkCore.Diagnostics.IDiagnosticsLogger<'LoggerCategory (requires 'LoggerCategory :> Microsoft.EntityFrameworkCore.Diagnostics.LoggerCategory<'LoggerCategory> and 'LoggerCategory : (new : unit -> 'LoggerCategory))> * 'TParam1 * 'TParam2 * 'TParam3 * 'TParam4 * 'TParam5 * 'TParam6 * Exception -> unit (requires 'LoggerCategory :> Microsoft.EntityFrameworkCore.Diagnostics.LoggerCategory<'LoggerCategory> and 'LoggerCategory : (new : unit -> 'LoggerCategory))
override this.Log : Microsoft.EntityFrameworkCore.Diagnostics.IDiagnosticsLogger<'LoggerCategory (requires 'LoggerCategory :> Microsoft.EntityFrameworkCore.Diagnostics.LoggerCategory<'LoggerCategory> and 'LoggerCategory : (new : unit -> 'LoggerCategory))> * 'TParam1 * 'TParam2 * 'TParam3 * 'TParam4 * 'TParam5 * 'TParam6 * Exception -> unit (requires 'LoggerCategory :> Microsoft.EntityFrameworkCore.Diagnostics.LoggerCategory<'LoggerCategory> and 'LoggerCategory : (new : unit -> 'LoggerCategory))
[<System.Obsolete("Use the other overload")>]
abstract member Log : Microsoft.EntityFrameworkCore.Diagnostics.IDiagnosticsLogger<'LoggerCategory (requires 'LoggerCategory :> Microsoft.EntityFrameworkCore.Diagnostics.LoggerCategory<'LoggerCategory> and 'LoggerCategory : (new : unit -> 'LoggerCategory))> * 'TParam1 * 'TParam2 * 'TParam3 * 'TParam4 * 'TParam5 * 'TParam6 * Exception -> unit (requires 'LoggerCategory :> Microsoft.EntityFrameworkCore.Diagnostics.LoggerCategory<'LoggerCategory> and 'LoggerCategory : (new : unit -> 'LoggerCategory))
override this.Log : Microsoft.EntityFrameworkCore.Diagnostics.IDiagnosticsLogger<'LoggerCategory (requires 'LoggerCategory :> Microsoft.EntityFrameworkCore.Diagnostics.LoggerCategory<'LoggerCategory> and 'LoggerCategory : (new : unit -> 'LoggerCategory))> * 'TParam1 * 'TParam2 * 'TParam3 * 'TParam4 * 'TParam5 * 'TParam6 * Exception -> unit (requires 'LoggerCategory :> Microsoft.EntityFrameworkCore.Diagnostics.LoggerCategory<'LoggerCategory> and 'LoggerCategory : (new : unit -> 'LoggerCategory))
Public Overridable Sub Log(Of TLoggerCategory As {LoggerCategory(Of TLoggerCategory)New}) (logger As IDiagnosticsLogger(Of TLoggerCategory), arg1 As TParam1, arg2 As TParam2, arg3 As TParam3, arg4 As TParam4, arg5 As TParam5, arg6 As TParam6, Optional exception As Exception = Nothing)

类型参数

TLoggerCategory

DbLoggerCategory

参数

logger
IDiagnosticsLogger<TLoggerCategory>

事件应记录到的记录器。

arg1
TParam1

第一个消息参数。

arg2
TParam2

第二个消息参数。

arg3
TParam3

第三个消息参数。

arg4
TParam4

第四个消息参数。

arg5
TParam5

第五个消息参数。

arg6
TParam6

第六个消息参数。

exception
Exception

与事件关联的可选异常。

属性

适用于

Log<TLoggerCategory>(IDiagnosticsLogger<TLoggerCategory>, WarningBehavior, TParam1, TParam2, TParam3, TParam4, TParam5, TParam6, Exception)

记录事件,如果事件已配置为被视为错误,则引发 。

public virtual void Log<TLoggerCategory> (Microsoft.EntityFrameworkCore.Diagnostics.IDiagnosticsLogger<TLoggerCategory> logger, Microsoft.EntityFrameworkCore.WarningBehavior warningBehavior, TParam1 arg1, TParam2 arg2, TParam3 arg3, TParam4 arg4, TParam5 arg5, TParam6 arg6, Exception exception = default) where TLoggerCategory : Microsoft.EntityFrameworkCore.Diagnostics.LoggerCategory<TLoggerCategory>, new();
abstract member Log : Microsoft.EntityFrameworkCore.Diagnostics.IDiagnosticsLogger<'LoggerCategory (requires 'LoggerCategory :> Microsoft.EntityFrameworkCore.Diagnostics.LoggerCategory<'LoggerCategory> and 'LoggerCategory : (new : unit -> 'LoggerCategory))> * Microsoft.EntityFrameworkCore.WarningBehavior * 'TParam1 * 'TParam2 * 'TParam3 * 'TParam4 * 'TParam5 * 'TParam6 * Exception -> unit (requires 'LoggerCategory :> Microsoft.EntityFrameworkCore.Diagnostics.LoggerCategory<'LoggerCategory> and 'LoggerCategory : (new : unit -> 'LoggerCategory))
override this.Log : Microsoft.EntityFrameworkCore.Diagnostics.IDiagnosticsLogger<'LoggerCategory (requires 'LoggerCategory :> Microsoft.EntityFrameworkCore.Diagnostics.LoggerCategory<'LoggerCategory> and 'LoggerCategory : (new : unit -> 'LoggerCategory))> * Microsoft.EntityFrameworkCore.WarningBehavior * 'TParam1 * 'TParam2 * 'TParam3 * 'TParam4 * 'TParam5 * 'TParam6 * Exception -> unit (requires 'LoggerCategory :> Microsoft.EntityFrameworkCore.Diagnostics.LoggerCategory<'LoggerCategory> and 'LoggerCategory : (new : unit -> 'LoggerCategory))
Public Overridable Sub Log(Of TLoggerCategory As {LoggerCategory(Of TLoggerCategory)New}) (logger As IDiagnosticsLogger(Of TLoggerCategory), warningBehavior As WarningBehavior, arg1 As TParam1, arg2 As TParam2, arg3 As TParam3, arg4 As TParam4, arg5 As TParam5, arg6 As TParam6, Optional exception As Exception = Nothing)

类型参数

TLoggerCategory

DbLoggerCategory

参数

logger
IDiagnosticsLogger<TLoggerCategory>

事件应记录到的记录器。

warningBehavior
WarningBehavior

是应记录事件、作为异常引发还是忽略事件。

arg1
TParam1

第一个消息参数。

arg2
TParam2

第二个消息参数。

arg3
TParam3

第三个消息参数。

arg4
TParam4

第四个消息参数。

arg5
TParam5

第五个消息参数。

arg6
TParam6

第六个消息参数。

exception
Exception

与事件关联的可选异常。

适用于