FakeLogRecord Constructor
Definición
Importante
Parte de la información hace referencia a la versión preliminar del producto, que puede haberse modificado sustancialmente antes de lanzar la versión definitiva. Microsoft no otorga ninguna garantía, explícita o implícita, con respecto a la información proporcionada aquí.
Inicializa una nueva instancia de la clase FakeLogRecord.
public:
FakeLogRecord(Microsoft::Extensions::Logging::LogLevel level, Microsoft::Extensions::Logging::EventId id, System::Object ^ state, Exception ^ exception, System::String ^ message, System::Collections::Generic::IReadOnlyList<System::Object ^> ^ scopes, System::String ^ category, bool enabled, DateTimeOffset timestamp);
public FakeLogRecord (Microsoft.Extensions.Logging.LogLevel level, Microsoft.Extensions.Logging.EventId id, object? state, Exception? exception, string message, System.Collections.Generic.IReadOnlyList<object?> scopes, string? category, bool enabled, DateTimeOffset timestamp);
new Microsoft.Extensions.Logging.Testing.FakeLogRecord : Microsoft.Extensions.Logging.LogLevel * Microsoft.Extensions.Logging.EventId * obj * Exception * string * System.Collections.Generic.IReadOnlyList<obj> * string * bool * DateTimeOffset -> Microsoft.Extensions.Logging.Testing.FakeLogRecord
Public Sub New (level As LogLevel, id As EventId, state As Object, exception As Exception, message As String, scopes As IReadOnlyList(Of Object), category As String, enabled As Boolean, timestamp As DateTimeOffset)
Parámetros
- level
- LogLevel
Nivel utilizado al generar el registro.
- id
- EventId
Identificador que representa la instrucción de registro específica.
- state
- Object
Estado opaco proporcionado por el autor de la llamada al crear el registro.
- exception
- Exception
Excepción opcional asociada al registro.
- message
- String
Texto del mensaje con formato para el registro.
- scopes
- IReadOnlyList<Object>
Lista de ámbitos activos activos para este registro.
- category
- String
Categoría opcional de este registro, que corresponde al T de ILogger<TCategoryName>.
- enabled
- Boolean
Indica si el nivel de registro se habilitó o no cuando se llamó al Log<TState>(LogLevel, EventId, TState, Exception, Func<TState,Exception,String>) método .
- timestamp
- DateTimeOffset
Hora a la que se creó el registro.