IRelationalCommandDiagnosticsLogger.CommandScalarExecutedAsync Méthode
Définition
Important
Certaines informations portent sur la préversion du produit qui est susceptible d’être en grande partie modifiée avant sa publication. Microsoft exclut toute garantie, expresse ou implicite, concernant les informations fournies ici.
Surcharges
CommandScalarExecutedAsync(IRelationalConnection, DbCommand, String, DbContext, Guid, Guid, Object, DateTimeOffset, TimeSpan, CommandSource, CancellationToken)
Journaux de l’événement CommandExecuted .
public System.Threading.Tasks.ValueTask<object?> CommandScalarExecutedAsync(Microsoft.EntityFrameworkCore.Storage.IRelationalConnection connection, System.Data.Common.DbCommand command, string logCommandText, Microsoft.EntityFrameworkCore.DbContext? context, Guid commandId, Guid connectionId, object? methodResult, DateTimeOffset startTime, TimeSpan duration, Microsoft.EntityFrameworkCore.Diagnostics.CommandSource commandSource, System.Threading.CancellationToken cancellationToken = default);
abstract member CommandScalarExecutedAsync : Microsoft.EntityFrameworkCore.Storage.IRelationalConnection * System.Data.Common.DbCommand * string * Microsoft.EntityFrameworkCore.DbContext * Guid * Guid * obj * DateTimeOffset * TimeSpan * Microsoft.EntityFrameworkCore.Diagnostics.CommandSource * System.Threading.CancellationToken -> System.Threading.Tasks.ValueTask<obj>
Public Function CommandScalarExecutedAsync (connection As IRelationalConnection, command As DbCommand, logCommandText As String, context As DbContext, commandId As Guid, connectionId As Guid, methodResult As Object, startTime As DateTimeOffset, duration As TimeSpan, commandSource As CommandSource, Optional cancellationToken As CancellationToken = Nothing) As ValueTask(Of Object)
Paramètres
- connection
- IRelationalConnection
Connexion.
- command
- DbCommand
Objet de commande de base de données.
- logCommandText
- String
Texte de commande qui peut être journalisé.
- connectionId
- Guid
ID de corrélation associé à l’utilisation DbConnection .
- methodResult
- Object
Valeur de retour de l’exécution de la méthode sous-jacente.
- startTime
- DateTimeOffset
Heure à laquelle l’exécution a commencé.
- duration
- TimeSpan
Durée de l’exécution de la commande, sans inclure les résultats consommant.
- commandSource
- CommandSource
Source de la commande.
- cancellationToken
- CancellationToken
À CancellationToken observer lors de l’attente de la fin de la tâche.
Retours
Résultat de l’exécution, qui a peut-être été modifié par un intercepteur.
Exceptions
Si la CancellationToken valeur est annulée.
S’applique à
CommandScalarExecutedAsync(IRelationalConnection, DbCommand, DbContext, Guid, Guid, Object, DateTimeOffset, TimeSpan, CommandSource, CancellationToken)
Journaux de l’événement CommandExecuted .
public System.Threading.Tasks.ValueTask<object?> CommandScalarExecutedAsync(Microsoft.EntityFrameworkCore.Storage.IRelationalConnection connection, System.Data.Common.DbCommand command, Microsoft.EntityFrameworkCore.DbContext? context, Guid commandId, Guid connectionId, object? methodResult, DateTimeOffset startTime, TimeSpan duration, Microsoft.EntityFrameworkCore.Diagnostics.CommandSource commandSource, System.Threading.CancellationToken cancellationToken = default);
abstract member CommandScalarExecutedAsync : Microsoft.EntityFrameworkCore.Storage.IRelationalConnection * System.Data.Common.DbCommand * Microsoft.EntityFrameworkCore.DbContext * Guid * Guid * obj * DateTimeOffset * TimeSpan * Microsoft.EntityFrameworkCore.Diagnostics.CommandSource * System.Threading.CancellationToken -> System.Threading.Tasks.ValueTask<obj>
Public Function CommandScalarExecutedAsync (connection As IRelationalConnection, command As DbCommand, context As DbContext, commandId As Guid, connectionId As Guid, methodResult As Object, startTime As DateTimeOffset, duration As TimeSpan, commandSource As CommandSource, Optional cancellationToken As CancellationToken = Nothing) As ValueTask(Of Object)
Paramètres
- connection
- IRelationalConnection
Connexion.
- command
- DbCommand
Objet de commande de base de données.
- connectionId
- Guid
ID de corrélation associé à l’utilisation DbConnection .
- methodResult
- Object
Valeur de retour de l’exécution de la méthode sous-jacente.
- startTime
- DateTimeOffset
Heure à laquelle l’exécution a commencé.
- duration
- TimeSpan
Durée de l’exécution de la commande, sans inclure les résultats consommant.
- commandSource
- CommandSource
Source de la commande.
- cancellationToken
- CancellationToken
À CancellationToken observer lors de l’attente de la fin de la tâche.
Retours
Résultat de l’exécution, qui a peut-être été modifié par un intercepteur.
Exceptions
Si la CancellationToken valeur est annulée.