LogOptions class

Options for sending a log entry

Constructors

LogOptions({required LogLevel level, required String message, String? stackTrace, String? metadata, String? userIdentifier, String? sessionId, bool autoCaptured = false, String? clientTimestamp})
const

Properties

autoCaptured → bool
Internal: marks whether this log was captured automatically by the SDK (as opposed to a manual call from app code). Not part of the public API.
final
clientTimestamp → String?
Client timestamp (UTC, RFC 3339). Left null to be stamped at send time; only set explicitly to preserve a timestamp across a beforeSend copy.
final
hashCode → int
The hash code for this object.
no setterinherited
level → LogLevel
Log level (required)
final
message → String
Log message (required)
final
metadata → String?
Additional metadata como texto (opcional). Los métodos de conveniencia de SmartGrowLogs (debug/logDebug/info/warn/error/ errorWithException/fatal) aceptan Object? metadata y lo guardan aquí ya convertido a String: null se mantiene null, un String se usa tal cual, y cualquier otro objeto se serializa con jsonEncode (es decir, viene en JSON cuando no es texto plano). beforeSend y toMap lo ven siempre en esta forma de texto.
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
sessionId → String?
Session identifier (optional)
final
stackTrace → String?
Stack trace for errors (optional)
final
userIdentifier → String?
User identifier for tracking (optional)
final

Methods

copyWith({LogLevel? level, String? message, Object? stackTrace = _unset, Object? metadata = _unset, Object? userIdentifier = _unset, Object? sessionId = _unset, bool? autoCaptured, Object? clientTimestamp = _unset}) → LogOptions
Returns a copy of this LogOptions with the given fields replaced.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toMap() → Map<String, dynamic>
toString() → String
A string representation of this object.
inherited

Operators

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