CommandExecutedEventData 构造函数

定义

重载

CommandExecutedEventData(EventDefinitionBase, Func<EventDefinitionBase, EventData,String>, DbCommand, DbCommandMethod, Guid, Guid, Object, Boolean, Boolean, DateTimeOffset, TimeSpan)

构造事件有效负载。

CommandExecutedEventData(EventDefinitionBase, Func<EventDefinitionBase, EventData,String>, DbConnection, DbCommand, DbContext, DbCommandMethod, Guid, Guid, Object, Boolean, Boolean, DateTimeOffset, TimeSpan)
已过时.

构造事件有效负载。

CommandExecutedEventData(EventDefinitionBase, Func<EventDefinitionBase, EventData,String>, DbConnection, DbCommand, DbContext, DbCommandMethod, Guid, Guid, Object, Boolean, Boolean, DateTimeOffset, TimeSpan, CommandSource)

构造事件有效负载。

CommandExecutedEventData(EventDefinitionBase, Func<EventDefinitionBase, EventData,String>, DbCommand, DbCommandMethod, Guid, Guid, Object, Boolean, Boolean, DateTimeOffset, TimeSpan)

Source:
CommandExecutedEventData.cs
Source:
CommandExecutedEventData.cs

构造事件有效负载。

public CommandExecutedEventData (Microsoft.EntityFrameworkCore.Diagnostics.EventDefinitionBase eventDefinition, Func<Microsoft.EntityFrameworkCore.Diagnostics.EventDefinitionBase,Microsoft.EntityFrameworkCore.Diagnostics.EventData,string> messageGenerator, System.Data.Common.DbCommand command, Microsoft.EntityFrameworkCore.Diagnostics.DbCommandMethod executeMethod, Guid commandId, Guid connectionId, object result, bool async, bool logParameterValues, DateTimeOffset startTime, TimeSpan duration);
new Microsoft.EntityFrameworkCore.Diagnostics.CommandExecutedEventData : Microsoft.EntityFrameworkCore.Diagnostics.EventDefinitionBase * Func<Microsoft.EntityFrameworkCore.Diagnostics.EventDefinitionBase, Microsoft.EntityFrameworkCore.Diagnostics.EventData, string> * System.Data.Common.DbCommand * Microsoft.EntityFrameworkCore.Diagnostics.DbCommandMethod * Guid * Guid * obj * bool * bool * DateTimeOffset * TimeSpan -> Microsoft.EntityFrameworkCore.Diagnostics.CommandExecutedEventData
Public Sub New (eventDefinition As EventDefinitionBase, messageGenerator As Func(Of EventDefinitionBase, EventData, String), command As DbCommand, executeMethod As DbCommandMethod, commandId As Guid, connectionId As Guid, result As Object, async As Boolean, logParameterValues As Boolean, startTime As DateTimeOffset, duration As TimeSpan)

参数

eventDefinition
EventDefinitionBase

事件定义。

messageGenerator
Func<EventDefinitionBase,EventData,String>

生成此事件的日志消息的委托。

command
DbCommand

DbCommand失败时正在执行的 。

executeMethod
DbCommandMethod

DbCommand用于执行命令的方法。

commandId
Guid

一个关联 ID,用于标识正在使用的 DbCommand 实例。

connectionId
Guid

一个关联 ID,用于标识正在使用的 DbConnection 实例。

result
Object

执行操作的结果。

async
Boolean

指示命令是否以异步方式执行。

logParameterValues
Boolean

指示应用程序是否允许记录参数值。

startTime
DateTimeOffset

此事件的开始时间。

duration
TimeSpan

此事件的持续时间。

适用于

CommandExecutedEventData(EventDefinitionBase, Func<EventDefinitionBase, EventData,String>, DbConnection, DbCommand, DbContext, DbCommandMethod, Guid, Guid, Object, Boolean, Boolean, DateTimeOffset, TimeSpan)

Source:
CommandExecutedEventData.cs
Source:
CommandExecutedEventData.cs
Source:
CommandExecutedEventData.cs
Source:
CommandExecutedEventData.cs

注意

Use the overload with CommandSource

构造事件有效负载。

public CommandExecutedEventData (Microsoft.EntityFrameworkCore.Diagnostics.EventDefinitionBase eventDefinition, Func<Microsoft.EntityFrameworkCore.Diagnostics.EventDefinitionBase,Microsoft.EntityFrameworkCore.Diagnostics.EventData,string> messageGenerator, System.Data.Common.DbConnection connection, System.Data.Common.DbCommand command, Microsoft.EntityFrameworkCore.DbContext context, Microsoft.EntityFrameworkCore.Diagnostics.DbCommandMethod executeMethod, Guid commandId, Guid connectionId, object result, bool async, bool logParameterValues, DateTimeOffset startTime, TimeSpan duration);
[System.Obsolete("Use the overload with CommandSource")]
public CommandExecutedEventData (Microsoft.EntityFrameworkCore.Diagnostics.EventDefinitionBase eventDefinition, Func<Microsoft.EntityFrameworkCore.Diagnostics.EventDefinitionBase,Microsoft.EntityFrameworkCore.Diagnostics.EventData,string> messageGenerator, System.Data.Common.DbConnection connection, System.Data.Common.DbCommand command, Microsoft.EntityFrameworkCore.DbContext? context, Microsoft.EntityFrameworkCore.Diagnostics.DbCommandMethod executeMethod, Guid commandId, Guid connectionId, object? result, bool async, bool logParameterValues, DateTimeOffset startTime, TimeSpan duration);
new Microsoft.EntityFrameworkCore.Diagnostics.CommandExecutedEventData : Microsoft.EntityFrameworkCore.Diagnostics.EventDefinitionBase * Func<Microsoft.EntityFrameworkCore.Diagnostics.EventDefinitionBase, Microsoft.EntityFrameworkCore.Diagnostics.EventData, string> * System.Data.Common.DbConnection * System.Data.Common.DbCommand * Microsoft.EntityFrameworkCore.DbContext * Microsoft.EntityFrameworkCore.Diagnostics.DbCommandMethod * Guid * Guid * obj * bool * bool * DateTimeOffset * TimeSpan -> Microsoft.EntityFrameworkCore.Diagnostics.CommandExecutedEventData
[<System.Obsolete("Use the overload with CommandSource")>]
new Microsoft.EntityFrameworkCore.Diagnostics.CommandExecutedEventData : Microsoft.EntityFrameworkCore.Diagnostics.EventDefinitionBase * Func<Microsoft.EntityFrameworkCore.Diagnostics.EventDefinitionBase, Microsoft.EntityFrameworkCore.Diagnostics.EventData, string> * System.Data.Common.DbConnection * System.Data.Common.DbCommand * Microsoft.EntityFrameworkCore.DbContext * Microsoft.EntityFrameworkCore.Diagnostics.DbCommandMethod * Guid * Guid * obj * bool * bool * DateTimeOffset * TimeSpan -> Microsoft.EntityFrameworkCore.Diagnostics.CommandExecutedEventData
Public Sub New (eventDefinition As EventDefinitionBase, messageGenerator As Func(Of EventDefinitionBase, EventData, String), connection As DbConnection, command As DbCommand, context As DbContext, executeMethod As DbCommandMethod, commandId As Guid, connectionId As Guid, result As Object, async As Boolean, logParameterValues As Boolean, startTime As DateTimeOffset, duration As TimeSpan)

参数

eventDefinition
EventDefinitionBase

事件定义。

messageGenerator
Func<EventDefinitionBase,EventData,String>

生成此事件的日志消息的委托。

connection
DbConnection

DbConnection正在使用的 。

command
DbCommand

DbCommand失败时正在执行的 。

context
DbContext

当前 DbContext 正在使用的 ,如果未知,则为 null。

executeMethod
DbCommandMethod

DbCommand用于执行命令的方法。

commandId
Guid

一个关联 ID,用于标识正在使用的 DbCommand 实例。

connectionId
Guid

一个关联 ID,用于标识正在使用的 DbConnection 实例。

result
Object

执行操作的结果。

async
Boolean

指示命令是否以异步方式执行。

logParameterValues
Boolean

指示应用程序是否允许记录参数值。

startTime
DateTimeOffset

此事件的开始时间。

duration
TimeSpan

此事件的持续时间。

属性

适用于

CommandExecutedEventData(EventDefinitionBase, Func<EventDefinitionBase, EventData,String>, DbConnection, DbCommand, DbContext, DbCommandMethod, Guid, Guid, Object, Boolean, Boolean, DateTimeOffset, TimeSpan, CommandSource)

Source:
CommandExecutedEventData.cs
Source:
CommandExecutedEventData.cs
Source:
CommandExecutedEventData.cs
Source:
CommandExecutedEventData.cs

构造事件有效负载。

public CommandExecutedEventData (Microsoft.EntityFrameworkCore.Diagnostics.EventDefinitionBase eventDefinition, Func<Microsoft.EntityFrameworkCore.Diagnostics.EventDefinitionBase,Microsoft.EntityFrameworkCore.Diagnostics.EventData,string> messageGenerator, System.Data.Common.DbConnection connection, System.Data.Common.DbCommand command, Microsoft.EntityFrameworkCore.DbContext? context, Microsoft.EntityFrameworkCore.Diagnostics.DbCommandMethod executeMethod, Guid commandId, Guid connectionId, object? result, bool async, bool logParameterValues, DateTimeOffset startTime, TimeSpan duration, Microsoft.EntityFrameworkCore.Diagnostics.CommandSource commandSource);
new Microsoft.EntityFrameworkCore.Diagnostics.CommandExecutedEventData : Microsoft.EntityFrameworkCore.Diagnostics.EventDefinitionBase * Func<Microsoft.EntityFrameworkCore.Diagnostics.EventDefinitionBase, Microsoft.EntityFrameworkCore.Diagnostics.EventData, string> * System.Data.Common.DbConnection * System.Data.Common.DbCommand * Microsoft.EntityFrameworkCore.DbContext * Microsoft.EntityFrameworkCore.Diagnostics.DbCommandMethod * Guid * Guid * obj * bool * bool * DateTimeOffset * TimeSpan * Microsoft.EntityFrameworkCore.Diagnostics.CommandSource -> Microsoft.EntityFrameworkCore.Diagnostics.CommandExecutedEventData
Public Sub New (eventDefinition As EventDefinitionBase, messageGenerator As Func(Of EventDefinitionBase, EventData, String), connection As DbConnection, command As DbCommand, context As DbContext, executeMethod As DbCommandMethod, commandId As Guid, connectionId As Guid, result As Object, async As Boolean, logParameterValues As Boolean, startTime As DateTimeOffset, duration As TimeSpan, commandSource As CommandSource)

参数

eventDefinition
EventDefinitionBase

事件定义。

messageGenerator
Func<EventDefinitionBase,EventData,String>

生成此事件的日志消息的委托。

connection
DbConnection

DbConnection正在使用的 。

command
DbCommand

DbCommand失败时正在执行的 。

context
DbContext

当前 DbContext 正在使用的 ,如果未知,则为 null。

executeMethod
DbCommandMethod

DbCommand用于执行命令的方法。

commandId
Guid

一个关联 ID,用于标识正在使用的 DbCommand 实例。

connectionId
Guid

一个关联 ID,用于标识正在使用的 DbConnection 实例。

result
Object

执行操作的结果。

async
Boolean

指示命令是否以异步方式执行。

logParameterValues
Boolean

指示应用程序是否允许记录参数值。

startTime
DateTimeOffset

此事件的开始时间。

duration
TimeSpan

此事件的持续时间。

commandSource
CommandSource

命令的源。

适用于