toJson method

Map<String, dynamic> toJson()

Implementation

Map<String, dynamic> toJson() {
  return {
    'id': id,
    'timestamp': timestamp.toIso8601String(),
    'level': level.name,
    'message': message,
    'category': category,
    'tag': tag,
    'metadata': metadata,
    'stackTrace': stackTrace,
    'userId': userId,
    'sessionId': sessionId,
  };
}