LogEntry class

Represents a single log entry with all its metadata

Constructors

LogEntry({required DateTime timestamp, required LogLevel level, required String message, String? tag, Object? error, StackTrace? stackTrace, Map<String, dynamic> context = const <String, dynamic>{}, String? loggerName})
const

Properties

context Map<String, dynamic>
Additional context data
final
error Object?
Optional error object
final
hashCode int
The hash code for this object.
no setteroverride
level LogLevel
Severity level of this log entry
final
loggerName String?
Name of the logger that created this entry
final
message String
The main log message
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
stackTrace StackTrace?
Optional stack trace
final
tag String?
Optional tag for categorization
final
timestamp DateTime
When this log entry was created
final

Methods

copyWith({DateTime? timestamp, LogLevel? level, String? message, String? tag, Object? error, StackTrace? stackTrace, Map<String, dynamic>? context, String? loggerName}) LogEntry
Create a copy with modified fields
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
override

Operators

operator ==(Object other) bool
The equality operator.
override