ConnectionErrorEventData 构造函数
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
重载
ConnectionErrorEventData(EventDefinitionBase, Func<EventDefinitionBase, EventData,String>, DbConnection, Guid, Exception, Boolean, DateTimeOffset, TimeSpan)
- Source:
- ConnectionErrorEventData.cs
- Source:
- ConnectionErrorEventData.cs
构造事件有效负载。
public ConnectionErrorEventData (Microsoft.EntityFrameworkCore.Diagnostics.EventDefinitionBase eventDefinition, Func<Microsoft.EntityFrameworkCore.Diagnostics.EventDefinitionBase,Microsoft.EntityFrameworkCore.Diagnostics.EventData,string> messageGenerator, System.Data.Common.DbConnection connection, Guid connectionId, Exception exception, bool async, DateTimeOffset startTime, TimeSpan duration);
new Microsoft.EntityFrameworkCore.Diagnostics.ConnectionErrorEventData : Microsoft.EntityFrameworkCore.Diagnostics.EventDefinitionBase * Func<Microsoft.EntityFrameworkCore.Diagnostics.EventDefinitionBase, Microsoft.EntityFrameworkCore.Diagnostics.EventData, string> * System.Data.Common.DbConnection * Guid * Exception * bool * DateTimeOffset * TimeSpan -> Microsoft.EntityFrameworkCore.Diagnostics.ConnectionErrorEventData
Public Sub New (eventDefinition As EventDefinitionBase, messageGenerator As Func(Of EventDefinitionBase, EventData, String), connection As DbConnection, connectionId As Guid, exception As Exception, async As Boolean, startTime As DateTimeOffset, duration As TimeSpan)
参数
- eventDefinition
- EventDefinitionBase
事件定义。
- messageGenerator
- Func<EventDefinitionBase,EventData,String>
生成此事件的日志消息的委托。
- connection
- DbConnection
- connectionId
- Guid
标识正在使用的实例的相关 DbConnection ID。
- exception
- Exception
连接失败时引发的异常。
- async
- Boolean
指示操作是否以异步方式发生。
- startTime
- DateTimeOffset
此事件的开始时间。
- duration
- TimeSpan
此事件的持续时间。
适用于
ConnectionErrorEventData(EventDefinitionBase, Func<EventDefinitionBase, EventData,String>, DbConnection, DbContext, Guid, Exception, Boolean, DateTimeOffset, TimeSpan)
- Source:
- ConnectionErrorEventData.cs
- Source:
- ConnectionErrorEventData.cs
- Source:
- ConnectionErrorEventData.cs
- Source:
- ConnectionErrorEventData.cs
- Source:
- ConnectionErrorEventData.cs
- Source:
- ConnectionErrorEventData.cs
- Source:
- ConnectionErrorEventData.cs
构造事件有效负载。
public ConnectionErrorEventData (Microsoft.EntityFrameworkCore.Diagnostics.EventDefinitionBase eventDefinition, Func<Microsoft.EntityFrameworkCore.Diagnostics.EventDefinitionBase,Microsoft.EntityFrameworkCore.Diagnostics.EventData,string> messageGenerator, System.Data.Common.DbConnection connection, Microsoft.EntityFrameworkCore.DbContext context, Guid connectionId, Exception exception, bool async, DateTimeOffset startTime, TimeSpan duration);
public ConnectionErrorEventData (Microsoft.EntityFrameworkCore.Diagnostics.EventDefinitionBase eventDefinition, Func<Microsoft.EntityFrameworkCore.Diagnostics.EventDefinitionBase,Microsoft.EntityFrameworkCore.Diagnostics.EventData,string> messageGenerator, System.Data.Common.DbConnection connection, Microsoft.EntityFrameworkCore.DbContext? context, Guid connectionId, Exception exception, bool async, DateTimeOffset startTime, TimeSpan duration);
new Microsoft.EntityFrameworkCore.Diagnostics.ConnectionErrorEventData : Microsoft.EntityFrameworkCore.Diagnostics.EventDefinitionBase * Func<Microsoft.EntityFrameworkCore.Diagnostics.EventDefinitionBase, Microsoft.EntityFrameworkCore.Diagnostics.EventData, string> * System.Data.Common.DbConnection * Microsoft.EntityFrameworkCore.DbContext * Guid * Exception * bool * DateTimeOffset * TimeSpan -> Microsoft.EntityFrameworkCore.Diagnostics.ConnectionErrorEventData
Public Sub New (eventDefinition As EventDefinitionBase, messageGenerator As Func(Of EventDefinitionBase, EventData, String), connection As DbConnection, context As DbContext, connectionId As Guid, exception As Exception, async As Boolean, startTime As DateTimeOffset, duration As TimeSpan)
参数
- eventDefinition
- EventDefinitionBase
事件定义。
- messageGenerator
- Func<EventDefinitionBase,EventData,String>
生成此事件的日志消息的委托。
- connection
- DbConnection
- connectionId
- Guid
标识正在使用的实例的相关 DbConnection ID。
- exception
- Exception
连接失败时引发的异常。
- async
- Boolean
指示操作是否以异步方式发生。
- startTime
- DateTimeOffset
此事件的开始时间。
- duration
- TimeSpan
此事件的持续时间。