CommandErrorEventData Costruttori
Definizione
Importante
Alcune informazioni sono relative alla release non definitiva del prodotto, che potrebbe subire modifiche significative prima della release definitiva. Microsoft non riconosce alcuna garanzia, espressa o implicita, in merito alle informazioni qui fornite.
Overload
CommandErrorEventData(EventDefinitionBase, Func<EventDefinitionBase, EventData,String>, DbCommand, DbCommandMethod, Guid, Guid, Exception, Boolean, Boolean, DateTimeOffset, TimeSpan)
Costruisce il payload dell'evento.
public CommandErrorEventData (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, Exception exception, bool async, bool logParameterValues, DateTimeOffset startTime, TimeSpan duration);
new Microsoft.EntityFrameworkCore.Diagnostics.CommandErrorEventData : Microsoft.EntityFrameworkCore.Diagnostics.EventDefinitionBase * Func<Microsoft.EntityFrameworkCore.Diagnostics.EventDefinitionBase, Microsoft.EntityFrameworkCore.Diagnostics.EventData, string> * System.Data.Common.DbCommand * Microsoft.EntityFrameworkCore.Diagnostics.DbCommandMethod * Guid * Guid * Exception * bool * bool * DateTimeOffset * TimeSpan -> Microsoft.EntityFrameworkCore.Diagnostics.CommandErrorEventData
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, exception As Exception, async As Boolean, logParameterValues As Boolean, startTime As DateTimeOffset, duration As TimeSpan)
Parametri
- eventDefinition
- EventDefinitionBase
Definizione dell'evento.
- messageGenerator
- Func<EventDefinitionBase,EventData,String>
Delegato che genera un messaggio di log per questo evento.
- executeMethod
- DbCommandMethod
Metodo DbCommand usato per eseguire il comando.
- connectionId
- Guid
ID di correlazione che identifica l'istanza DbConnection usata.
- exception
- Exception
Eccezione generata quando l'esecuzione non è riuscita.
- async
- Boolean
Indica se il comando è stato eseguito in modo asincrono.
- logParameterValues
- Boolean
Indica se l'applicazione consente la registrazione dei valori dei parametri.
- startTime
- DateTimeOffset
Ora di inizio di questo evento.
- duration
- TimeSpan
Durata dell'evento.
Si applica a
CommandErrorEventData(EventDefinitionBase, Func<EventDefinitionBase, EventData,String>, DbConnection, DbCommand, DbContext, DbCommandMethod, Guid, Guid, Exception, Boolean, Boolean, DateTimeOffset, TimeSpan)
Attenzione
Use the overload with CommandSource
Costruisce il payload dell'evento.
public CommandErrorEventData (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, Exception exception, bool async, bool logParameterValues, DateTimeOffset startTime, TimeSpan duration);
[System.Obsolete("Use the overload with CommandSource")]
public CommandErrorEventData (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, Exception exception, bool async, bool logParameterValues, DateTimeOffset startTime, TimeSpan duration);
new Microsoft.EntityFrameworkCore.Diagnostics.CommandErrorEventData : 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 * Exception * bool * bool * DateTimeOffset * TimeSpan -> Microsoft.EntityFrameworkCore.Diagnostics.CommandErrorEventData
[<System.Obsolete("Use the overload with CommandSource")>]
new Microsoft.EntityFrameworkCore.Diagnostics.CommandErrorEventData : 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 * Exception * bool * bool * DateTimeOffset * TimeSpan -> Microsoft.EntityFrameworkCore.Diagnostics.CommandErrorEventData
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, exception As Exception, async As Boolean, logParameterValues As Boolean, startTime As DateTimeOffset, duration As TimeSpan)
Parametri
- eventDefinition
- EventDefinitionBase
Definizione dell'evento.
- messageGenerator
- Func<EventDefinitionBase,EventData,String>
Delegato che genera un messaggio di log per questo evento.
- connection
- DbConnection
Oggetto DbConnection utilizzato.
- executeMethod
- DbCommandMethod
Metodo DbCommand usato per eseguire il comando.
- connectionId
- Guid
ID di correlazione che identifica l'istanza DbConnection usata.
- exception
- Exception
Eccezione generata quando l'esecuzione non è riuscita.
- async
- Boolean
Indica se il comando è stato eseguito in modo asincrono.
- logParameterValues
- Boolean
Indica se l'applicazione consente la registrazione dei valori dei parametri.
- startTime
- DateTimeOffset
Ora di inizio di questo evento.
- duration
- TimeSpan
Durata dell'evento.
- Attributi
Si applica a
CommandErrorEventData(EventDefinitionBase, Func<EventDefinitionBase, EventData,String>, DbConnection, DbCommand, DbContext, DbCommandMethod, Guid, Guid, Exception, Boolean, Boolean, DateTimeOffset, TimeSpan, CommandSource)
Costruisce il payload dell'evento.
public CommandErrorEventData (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, Exception exception, bool async, bool logParameterValues, DateTimeOffset startTime, TimeSpan duration, Microsoft.EntityFrameworkCore.Diagnostics.CommandSource commandSource);
new Microsoft.EntityFrameworkCore.Diagnostics.CommandErrorEventData : 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 * Exception * bool * bool * DateTimeOffset * TimeSpan * Microsoft.EntityFrameworkCore.Diagnostics.CommandSource -> Microsoft.EntityFrameworkCore.Diagnostics.CommandErrorEventData
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, exception As Exception, async As Boolean, logParameterValues As Boolean, startTime As DateTimeOffset, duration As TimeSpan, commandSource As CommandSource)
Parametri
- eventDefinition
- EventDefinitionBase
Definizione dell'evento.
- messageGenerator
- Func<EventDefinitionBase,EventData,String>
Delegato che genera un messaggio di log per questo evento.
- connection
- DbConnection
Oggetto DbConnection utilizzato.
- executeMethod
- DbCommandMethod
Metodo DbCommand usato per eseguire il comando.
- connectionId
- Guid
ID di correlazione che identifica l'istanza DbConnection usata.
- exception
- Exception
Eccezione generata quando l'esecuzione non è riuscita.
- async
- Boolean
Indica se il comando è stato eseguito in modo asincrono.
- logParameterValues
- Boolean
Indica se l'applicazione consente la registrazione dei valori dei parametri.
- startTime
- DateTimeOffset
Ora di inizio di questo evento.
- duration
- TimeSpan
Durata dell'evento.
- commandSource
- CommandSource
Origine del comando.