DatabaseLogFormatter.LogCommand<TResult> Method

Definition

Called to log a command that is about to be executed. Override this method to change how the command is logged to System.Data.Entity.Infrastructure.Interception.DatabaseLogFormatter.WriteAction.

public virtual void LogCommand<TResult> (System.Data.Common.DbCommand command, System.Data.Entity.Infrastructure.Interception.DbCommandInterceptionContext<TResult> interceptionContext);
abstract member LogCommand : System.Data.Common.DbCommand * System.Data.Entity.Infrastructure.Interception.DbCommandInterceptionContext<'Result> -> unit
override this.LogCommand : System.Data.Common.DbCommand * System.Data.Entity.Infrastructure.Interception.DbCommandInterceptionContext<'Result> -> unit
Public Overridable Sub LogCommand(Of TResult) (command As DbCommand, interceptionContext As DbCommandInterceptionContext(Of TResult))

Type Parameters

TResult

The type of the operation's results.

Parameters

command
DbCommand

The command to be logged.

interceptionContext
DbCommandInterceptionContext<TResult>

Contextual information associated with the command.

Applies to