Logger class

A Logger to display colorful and named logs.

Expample:

Logger logger = Logger(name: 'Logan the logger');

logger.log('Hello there');

Constructors

Logger({String name = "Logger", bool colored = true})

Properties

colored bool
If this Logger should print colored logs. Defaults to true.
final
hashCode int
The hash code for this object. [...]
read-only, inherited
name String
The Logger name is displayed in front of every message.
read / write
runtimeType Type
A representation of the runtime type of the object.
read-only, inherited

Methods

log(dynamic message) → void
logError(dynamic message, [dynamic error, Exception exception]) → void
Prints an error message. If exception is given it will also throw an exception.
logInfo(dynamic message) → void
logRich(dynamic message, [String description]) → void
Rich logs also include runtime Types.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed. [...]
inherited
toString() String
A string representation of this object. [...]
inherited

Operators

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