A Flutter plugin which provides the ability to use Tizen dlog logging service.
To use this package, add tizen_log
as a dependency in your pubspec.yaml
file.
dependencies:
tizen_log: ^0.1.1
const logTag = 'TEST';
Log.verbose(logTag, 'verbose message');
Log.debug(logTag, 'debug message');
Log.info(logTag, 'info message');
Log.warn(logTag, 'warn message');
Log.error(logTag, 'error message');
Log.fatal(logTag, 'fatal message');
To add file name, function name and line number to logs, use --dart-define=DEBUG_MODE=true
flag:
$ flutter-tizen run --dart-define=DEBUG_MODE=true
To override file name, function name or line number in logs, use additional parameters in function calls:
const logTag = 'TEST';
Log.warn(logTag, 'warn message', file: 'main');
Log.error(logTag, 'error message', func: 'constructor');
Log.fatal(logTag, 'fatal message', line: 1111);
Log.fatal(logTag, 'fatal message', file: 'main', line: 1234);
To view logs use the following command:
$ sdb dlog TEST # Replace TEST with your log tag.
- Galaxy Watch series (running Tizen 4.0 or later)