共用方式為


DbConnectionInterceptor.ConnectionClosedAsync 方法

定義

在 EF 呼叫 之後呼叫 CloseAsync()

public virtual System.Threading.Tasks.Task ConnectionClosedAsync (System.Data.Common.DbConnection connection, Microsoft.EntityFrameworkCore.Diagnostics.ConnectionEndEventData eventData);
abstract member ConnectionClosedAsync : System.Data.Common.DbConnection * Microsoft.EntityFrameworkCore.Diagnostics.ConnectionEndEventData -> System.Threading.Tasks.Task
override this.ConnectionClosedAsync : System.Data.Common.DbConnection * Microsoft.EntityFrameworkCore.Diagnostics.ConnectionEndEventData -> System.Threading.Tasks.Task
Public Overridable Function ConnectionClosedAsync (connection As DbConnection, eventData As ConnectionEndEventData) As Task

參數

connection
DbConnection

連接。

eventData
ConnectionEndEventData

連線的相關內容資訊。

傳回

代表非同步作業的 Task

實作

適用於