Use a Logger to log debug messages.

Loggers are named using a hierarchical dot-separated name convention.

Static Properties

root Logger

Top-level root Logger.

final

Constructors

Logger(String name)

Singleton constructor. Calling new Logger(name) will return the same actual instance whenever it is called with the same string name.

factory
Logger.detached(String name)

Creates a new detached Logger.

factory

Properties

children → Map<String, Logger>

Children in the hierarchy of loggers, indexed by their simple names.

final
fullName → String

The full name of this logger, which includes the parent's full name.

read-only
level Level

Effective level considering the levels established in this logger's parents (when hierarchicalLoggingEnabled is true).

read / write
name → String

Simple name of this logger.

final
onRecord → Stream<LogRecord>

Returns a stream of messages added to this Logger.

read-only
parent Logger

Parent of this logger in the hierarchy of loggers.

final
hashCode → int

The hash code for this object.

read-only, inherited
runtimeType → Type

A representation of the runtime type of the object.

read-only, inherited

Operators

operator ==(other) → bool

The equality operator.

inherited

Methods

clearListeners() → void

config(message, [ Object error, StackTrace stackTrace ]) → void

Log message at level Level.CONFIG.

fine(message, [ Object error, StackTrace stackTrace ]) → void

Log message at level Level.FINE.

finer(message, [ Object error, StackTrace stackTrace ]) → void

Log message at level Level.FINER.

finest(message, [ Object error, StackTrace stackTrace ]) → void

Log message at level Level.FINEST.

info(message, [ Object error, StackTrace stackTrace ]) → void

Log message at level Level.INFO.

isLoggable(Level value) → bool

Whether a message for value's level is loggable in this logger.

log(Level logLevel, message, [ Object error, StackTrace stackTrace, Zone zone ]) → void

Adds a log record for a message at a particular logLevel if isLoggable(logLevel) is true.

severe(message, [ Object error, StackTrace stackTrace ]) → void

Log message at level Level.SEVERE.

shout(message, [ Object error, StackTrace stackTrace ]) → void

Log message at level Level.SHOUT.

warning(message, [ Object error, StackTrace stackTrace ]) → void

Log message at level Level.WARNING.

noSuchMethod(Invocation invocation) → dynamic

Invoked when a non-existent method or property is accessed.

inherited
toString() → String

Returns a string representation of this object.

inherited