Condividi tramite


IRelationalCommandDiagnosticsLogger.CommandNonQueryExecutingAsync Metodo

Definizione

Registra l'evento CommandExecuting .

public System.Threading.Tasks.ValueTask<Microsoft.EntityFrameworkCore.Diagnostics.InterceptionResult<int>> CommandNonQueryExecutingAsync (Microsoft.EntityFrameworkCore.Storage.IRelationalConnection connection, System.Data.Common.DbCommand command, Microsoft.EntityFrameworkCore.DbContext? context, Guid commandId, Guid connectionId, DateTimeOffset startTime, Microsoft.EntityFrameworkCore.Diagnostics.CommandSource commandSource, System.Threading.CancellationToken cancellationToken = default);
abstract member CommandNonQueryExecutingAsync : Microsoft.EntityFrameworkCore.Storage.IRelationalConnection * System.Data.Common.DbCommand * Microsoft.EntityFrameworkCore.DbContext * Guid * Guid * DateTimeOffset * Microsoft.EntityFrameworkCore.Diagnostics.CommandSource * System.Threading.CancellationToken -> System.Threading.Tasks.ValueTask<Microsoft.EntityFrameworkCore.Diagnostics.InterceptionResult<int>>
Public Function CommandNonQueryExecutingAsync (connection As IRelationalConnection, command As DbCommand, context As DbContext, commandId As Guid, connectionId As Guid, startTime As DateTimeOffset, commandSource As CommandSource, Optional cancellationToken As CancellationToken = Nothing) As ValueTask(Of InterceptionResult(Of Integer))

Parametri

connection
IRelationalConnection

Connessione.

command
DbCommand

Oggetto comando del database.

context
DbContext

Oggetto DbContext attualmente in uso, su Null se non noto.

commandId
Guid

ID di correlazione associato all'oggetto specificato DbCommand.

connectionId
Guid

ID di correlazione associato all'oggetto DbConnection utilizzato.

startTime
DateTimeOffset

Ora di inizio dell'esecuzione.

commandSource
CommandSource

Origine del comando.

cancellationToken
CancellationToken

Oggetto CancellationToken da osservare durante l'attesa del completamento dell'attività.

Restituisce

Risultato intercettato.

Eccezioni

Si applica a