Udostępnij za pośrednictwem


FallbackEventDefinition.Log Metoda

Definicja

Przeciążenia

Log<TLoggerCategory>(IDiagnosticsLogger<TLoggerCategory>, Action<ILogger>)
Przestarzałe.

Rejestruje zdarzenie lub zgłasza, czy zdarzenie zostało skonfigurowane do traktowania jako błędu.

Log<TLoggerCategory>(IDiagnosticsLogger<TLoggerCategory>, WarningBehavior, Action<ILogger>)

Rejestruje zdarzenie lub zgłasza, czy zdarzenie zostało skonfigurowane do traktowania jako błędu.

Log<TLoggerCategory>(IDiagnosticsLogger<TLoggerCategory>, Action<ILogger>)

Źródło:
FallbackEventDefinition.cs
Źródło:
FallbackEventDefinition.cs
Źródło:
FallbackEventDefinition.cs
Źródło:
FallbackEventDefinition.cs
Źródło:
FallbackEventDefinition.cs
Źródło:
FallbackEventDefinition.cs
Źródło:
FallbackEventDefinition.cs

Przestroga

Use the other overload

Rejestruje zdarzenie lub zgłasza, czy zdarzenie zostało skonfigurowane do traktowania jako błędu.

public virtual void Log<TLoggerCategory> (Microsoft.EntityFrameworkCore.Diagnostics.IDiagnosticsLogger<TLoggerCategory> logger, Action<Microsoft.Extensions.Logging.ILogger> logAction) 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, Action<Microsoft.Extensions.Logging.ILogger> logAction) 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))> * Action<Microsoft.Extensions.Logging.ILogger> -> 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))> * Action<Microsoft.Extensions.Logging.ILogger> -> 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))> * Action<Microsoft.Extensions.Logging.ILogger> -> 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))> * Action<Microsoft.Extensions.Logging.ILogger> -> 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), logAction As Action(Of ILogger))

Parametry typu

TLoggerCategory

Element DbLoggerCategory.

Parametry

logger
IDiagnosticsLogger<TLoggerCategory>

Rejestrator, do którego ma zostać zarejestrowane zdarzenie.

logAction
Action<ILogger>

Delegat, który będzie rejestrować komunikat do pliku ILogger.

Atrybuty

Dotyczy

Log<TLoggerCategory>(IDiagnosticsLogger<TLoggerCategory>, WarningBehavior, Action<ILogger>)

Źródło:
FallbackEventDefinition.cs
Źródło:
FallbackEventDefinition.cs
Źródło:
FallbackEventDefinition.cs
Źródło:
FallbackEventDefinition.cs

Rejestruje zdarzenie lub zgłasza, czy zdarzenie zostało skonfigurowane do traktowania jako błędu.

public virtual void Log<TLoggerCategory> (Microsoft.EntityFrameworkCore.Diagnostics.IDiagnosticsLogger<TLoggerCategory> logger, Microsoft.EntityFrameworkCore.WarningBehavior warningBehavior, Action<Microsoft.Extensions.Logging.ILogger> logAction) 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 * Action<Microsoft.Extensions.Logging.ILogger> -> 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 * Action<Microsoft.Extensions.Logging.ILogger> -> 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, logAction As Action(Of ILogger))

Parametry typu

TLoggerCategory

Element DbLoggerCategory.

Parametry

logger
IDiagnosticsLogger<TLoggerCategory>

Rejestrator, do którego ma zostać zarejestrowane zdarzenie.

warningBehavior
WarningBehavior

Niezależnie od tego, czy zdarzenie powinno być rejestrowane, zgłaszane jako wyjątek, czy ignorowane.

logAction
Action<ILogger>

Delegat, który będzie rejestrować komunikat do pliku ILogger.

Dotyczy