Freigeben über


IRelationalCommandDiagnosticsLogger.CommandCreated Methode

Definition

Protokolle für das CommandCreated Ereignis.

public System.Data.Common.DbCommand CommandCreated (Microsoft.EntityFrameworkCore.Storage.IRelationalConnection connection, System.Data.Common.DbCommand command, Microsoft.EntityFrameworkCore.Diagnostics.DbCommandMethod commandMethod, Microsoft.EntityFrameworkCore.DbContext? context, Guid commandId, Guid connectionId, DateTimeOffset startTime, TimeSpan duration, Microsoft.EntityFrameworkCore.Diagnostics.CommandSource commandSource);
abstract member CommandCreated : Microsoft.EntityFrameworkCore.Storage.IRelationalConnection * System.Data.Common.DbCommand * Microsoft.EntityFrameworkCore.Diagnostics.DbCommandMethod * Microsoft.EntityFrameworkCore.DbContext * Guid * Guid * DateTimeOffset * TimeSpan * Microsoft.EntityFrameworkCore.Diagnostics.CommandSource -> System.Data.Common.DbCommand
Public Function CommandCreated (connection As IRelationalConnection, command As DbCommand, commandMethod As DbCommandMethod, context As DbContext, commandId As Guid, connectionId As Guid, startTime As DateTimeOffset, duration As TimeSpan, commandSource As CommandSource) As DbCommand

Parameter

connection
IRelationalConnection

Die Verbindung.

command
DbCommand

Das Datenbankbefehlsobjekt.

commandMethod
DbCommandMethod

Der Typ der Methode, die für diesen Befehl aufgerufen wird.

context
DbContext

Die DbContext derzeit verwendete , um NULL zu verwenden, wenn sie nicht bekannt ist.

commandId
Guid

Die Korrelations-ID, die dem angegebenen DbCommandzugeordnet ist.

connectionId
Guid

Die Korrelations-ID, die der DbConnection verwendeten zugeordnet ist.

startTime
DateTimeOffset

Der Zeitpunkt, zu dem die Ausführung begonnen hat.

duration
TimeSpan

Die Dauer der Befehlserstellung.

commandSource
CommandSource

Quelle des Befehls.

Gibt zurück

Ein abgefangenes Ergebnis.

Gilt für: