LogChannelManager class

Manages log channels and their associated handlers. Provides methods to add, remove, and manage log handlers for different channels.

Constructors

LogChannelManager()

Properties

channels Set<String>
Gets all registered channels.
no setter
hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

addHandler(LogHandler handler, {String channel = 'app'}) → void
Adds a log handler to a specific channel.
clearAll() → void
Removes all handlers from all channels.
clearChannel(String channel) → void
Removes all handlers from a specific channel.
closeAll() → void
Closes all handlers in all channels.
getHandlers(String channel) List<LogHandler>
Gets the handlers for a specific channel.
hasHandlers(String channel) bool
Checks if a channel has any handlers.
logToChannel(String channel, LogLevel level, String message, {Map<String, dynamic>? context, StackTrace? stackTrace}) → void
Logs a message to all handlers in the specified channel.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
removeHandler(LogHandler handler, {String channel = 'app'}) → void
Removes a log handler from a specific channel.
toString() String
A string representation of this object.
inherited

Operators

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