LoggerConfig class

Configuration for the Logger

Constructors

LoggerConfig({bool enabled = true, LogLevel minLevel = LogLevel.verbose, bool showTimestamp = true, bool showLevel = true, bool showLocation = false, bool showStackTrace = true, bool prettyJson = true, int maxLength = 0, void customHandler(LogLevel level, String message, {String? tag})?})
const

Properties

customHandler → void Function(LogLevel level, String message, {String? tag})?
Custom log handler
final
enabled → bool
Enable/disable logging globally
final
hashCode → int
The hash code for this object.
no setterinherited
maxLength → int
Maximum length for log messages (0 = unlimited)
final
minLevel → LogLevel
Minimum log level to display
final
prettyJson → bool
Pretty print JSON objects
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
showLevel → bool
Show log level in logs
final
showLocation → bool
Show file and line number
final
showStackTrace → bool
Show stack trace for errors
final
showTimestamp → bool
Show timestamps in logs
final

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() → String
A string representation of this object.
inherited

Operators

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

Constants

development → const LoggerConfig
Default configuration for development
production → const LoggerConfig
Default configuration for production
testing → const LoggerConfig
Minimal configuration for testing