39 lines
1.3 KiB
Dart
39 lines
1.3 KiB
Dart
|
import 'package:logger/logger.dart';
|
||
|
|
||
|
class Log {
|
||
|
static final _verbolg = Logger();
|
||
|
static final _linelg = Logger(
|
||
|
printer: PrettyPrinter(methodCount: 0, printEmojis: false),
|
||
|
);
|
||
|
|
||
|
/// Log a message at level [Level.verbose].
|
||
|
static void v(dynamic message, [dynamic error, StackTrace? stackTrace]) {
|
||
|
_linelg.log(Level.verbose, message, error, stackTrace);
|
||
|
}
|
||
|
|
||
|
/// Log a message at level [Level.debug].
|
||
|
static void d(dynamic message, [dynamic error, StackTrace? stackTrace]) {
|
||
|
_linelg.log(Level.debug, message, error, stackTrace);
|
||
|
}
|
||
|
|
||
|
/// Log a message at level [Level.info].
|
||
|
static void i(dynamic message, [dynamic error, StackTrace? stackTrace]) {
|
||
|
_linelg.log(Level.info, message, error, stackTrace);
|
||
|
}
|
||
|
|
||
|
/// Log a message at level [Level.warning].
|
||
|
static void w(dynamic message, [dynamic error, StackTrace? stackTrace]) {
|
||
|
_verbolg.log(Level.warning, message, error, stackTrace);
|
||
|
}
|
||
|
|
||
|
/// Log a message at level [Level.error].
|
||
|
static void e(dynamic message, [dynamic error, StackTrace? stackTrace]) {
|
||
|
_verbolg.log(Level.error, message, error, stackTrace);
|
||
|
}
|
||
|
|
||
|
/// Log a message at level [Level.wtf].
|
||
|
static void wtf(dynamic message, [dynamic error, StackTrace? stackTrace]) {
|
||
|
_verbolg.log(Level.wtf, message, error, stackTrace);
|
||
|
}
|
||
|
}
|