API Reference 1.0.1+1rikulo_logging

rikulo_logging library

Functions

void simpleLoggerHandler(LogRecord record) #

A simple implementation of LoggerHandler. You can use it to configure your root logger, such as

new Logger("myorg").onRecord.listen(simpleLoggerHandler);
void simpleLoggerHandler(LogRecord record) {
 //for better response time, do it async (since the onRecord stream is sync)
 new Future(() {
   print("${record.time}:${record.loggerName}:${record.sequenceNumber}\n"
     "${record.level}: ${record.message}");
   if (record.stackTrace != null)
     print("${record.stackTrace}");
 });
}