IDbCommandInterceptor.CommandInitialized Method

Definition

Called after EF has initialized CommandText and other command configuration.

public virtual System.Data.Common.DbCommand CommandInitialized (Microsoft.EntityFrameworkCore.Diagnostics.CommandEndEventData eventData, System.Data.Common.DbCommand result);
abstract member CommandInitialized : Microsoft.EntityFrameworkCore.Diagnostics.CommandEndEventData * System.Data.Common.DbCommand -> System.Data.Common.DbCommand
override this.CommandInitialized : Microsoft.EntityFrameworkCore.Diagnostics.CommandEndEventData * System.Data.Common.DbCommand -> System.Data.Common.DbCommand
Public Overridable Function CommandInitialized (eventData As CommandEndEventData, result As DbCommand) As DbCommand

Parameters

eventData
CommandEndEventData

Contextual information about the command and execution.

result
DbCommand

The command. This value is typically used as the return value for the implementation of this method.

Returns

The result that EF will use. An implementation of this method for any interceptor that is not attempting to change the result is to return the result value passed in.

Applies to