Logger class

The main logger class that manages logging operations.

Constructors

Logger.new({LogConfig? config})
Gets the singleton instance of the logger.
factory

Properties

config LogConfig
The current logging configuration.
getter/setter pair
hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

agentLog(LogLevel level, String message, {String? agentName, Map<String, dynamic>? metadata}) → void
Logs a message for an AI agent.
clientLog(LogLevel level, String message, {String? clientName, Map<String, dynamic>? metadata}) → void
Logs a message for an AI client.
close() → void
Closes all handlers and releases resources.
debug(String message, {String? source, Map<String, dynamic>? metadata}) → void
Logs a debug message.
error(String message, {String? source, Map<String, dynamic>? metadata}) → void
Logs an error message.
info(String message, {String? source, Map<String, dynamic>? metadata}) → void
Logs an info message.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toolLog(LogLevel level, String message, {String? toolName, Map<String, dynamic>? metadata}) → void
Logs a message for a tool.
toString() String
A string representation of this object.
inherited
updateConfig(LogConfig newConfig) → void
Updates the logger's configuration.
warning(String message, {String? source, Map<String, dynamic>? metadata}) → void
Logs a warning message.

Operators

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