共用方式為


CoreLoggerExtensions.ContextInitialized 方法

定義

ContextInitialized事件的記錄。

public static void ContextInitialized (this Microsoft.EntityFrameworkCore.Diagnostics.IDiagnosticsLogger<Microsoft.EntityFrameworkCore.DbLoggerCategory.Infrastructure> diagnostics, Microsoft.EntityFrameworkCore.DbContext context, Microsoft.EntityFrameworkCore.DbContextOptions contextOptions);
static member ContextInitialized : Microsoft.EntityFrameworkCore.Diagnostics.IDiagnosticsLogger<Microsoft.EntityFrameworkCore.DbLoggerCategory.Infrastructure> * Microsoft.EntityFrameworkCore.DbContext * Microsoft.EntityFrameworkCore.DbContextOptions -> unit
<Extension()>
Public Sub ContextInitialized (diagnostics As IDiagnosticsLogger(Of DbLoggerCategory.Infrastructure), context As DbContext, contextOptions As DbContextOptions)

參數

diagnostics
IDiagnosticsLogger<DbLoggerCategory.Infrastructure>

要使用的診斷記錄器。

context
DbContext

使用的內容。

contextOptions
DbContextOptions

使用的內容選項。

適用於