LogEntry class

日志条目

Constructors

LogEntry({required LogLevel level, required String message, String tag = 'default', LogSource source = LogSource.custom, DateTime? timestamp, StackTrace? stackTrace, Object? error, Map<String, dynamic>? extra, String? threadId, bool suppressConsole = false, int seq = 0})
LogEntry.fromJson(Map<String, dynamic> json)
从JSON创建
factory

Properties

error → Object?
错误对象
final
extra → Map<String, dynamic>?
额外数据
final
hashCode → int
The hash code for this object.
no setterinherited
level → LogLevel
日志级别
final
message → String
日志内容
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
seq ↔ int
自增序号,由 LogCollector.collect 在入队时分配,外部无需设置。
getter/setter pair
source → LogSource
日志来源
final
stackTrace → StackTrace?
堆栈跟踪
final
suppressConsole → bool
压制控制台输出:为 true 时本条目照常进入采集管线(内存 + 文件存储, getLogs / export 可查),仅在分发环节跳过控制台类输出器(见 LogOutput.isConsole)。
final
tag → String
日志标签/分类
final
threadId → String?
线程ID(如果有)
final
timestamp → DateTime
时间戳
final

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toJson() → Map<String, dynamic>
转换为JSON
toString() → String
转换为字符串
override

Operators

operator ==(Object other) → bool
The equality operator.
inherited