共用方式為


ConnectionCreatingEventData 建構函式

定義

建構事件承載。

public ConnectionCreatingEventData (Microsoft.EntityFrameworkCore.Diagnostics.EventDefinitionBase eventDefinition, Func<Microsoft.EntityFrameworkCore.Diagnostics.EventDefinitionBase,Microsoft.EntityFrameworkCore.Diagnostics.EventData,string> messageGenerator, Microsoft.EntityFrameworkCore.DbContext? context, string? connectionString, Guid connectionId, DateTimeOffset startTime);
new Microsoft.EntityFrameworkCore.Diagnostics.ConnectionCreatingEventData : Microsoft.EntityFrameworkCore.Diagnostics.EventDefinitionBase * Func<Microsoft.EntityFrameworkCore.Diagnostics.EventDefinitionBase, Microsoft.EntityFrameworkCore.Diagnostics.EventData, string> * Microsoft.EntityFrameworkCore.DbContext * string * Guid * DateTimeOffset -> Microsoft.EntityFrameworkCore.Diagnostics.ConnectionCreatingEventData
Public Sub New (eventDefinition As EventDefinitionBase, messageGenerator As Func(Of EventDefinitionBase, EventData, String), context As DbContext, connectionString As String, connectionId As Guid, startTime As DateTimeOffset)

參數

eventDefinition
EventDefinitionBase

事件定義。

messageGenerator
Func<EventDefinitionBase,EventData,String>

產生此事件的記錄訊息的委派。

context
DbContext

DbContext目前使用的 ,如果不知道,則為 null。

connectionString
String

如果已知,則為新連接的連接字串。

connectionId
Guid

識別所使用實例的 DbConnection 相互關聯識別碼。

startTime
DateTimeOffset

此事件的開始時間。

適用於