toJson method
Produces a Map that can be serialized to JSON.
Implementation
Map<String, dynamic> toJson() {
return {
...?unknown,
if (type != null) 'type': type,
if (value != null) 'value': value,
if (module != null) 'module': module,
if (stackTrace != null) 'stacktrace': stackTrace!.toJson(),
if (mechanism != null) 'mechanism': mechanism!.toJson(),
if (threadId != null) 'thread_id': threadId,
};
}