Changelog History
-
v2.2.0 Changes
March 24, 2018- ๐ More documentation are added for public api.
- ๐ Support annotations (
NonNull
andNullable
) are added for each possible place. This makes it more easier to use in Kotlin. - ๐ New dependency configurations are used.
- โก๏ธ All dependencies are updated.
Thanks to @svenjacobs for the contribution.
-
v2.1.1 Changes
June 06, 2017๐ Fixed NPE issue for Logger.d(null)
-
v2.1.0 Changes
May 28, 2017 -
v2.0.0 Changes
May 27, 2017๐ฒ LogAdapter functionality is changed. Log adapter decides when to log with
isLoggable
and how to log with format strategy. You can create your custom adapter and add to Logger. Logger now accepts multiple log adapters.๐ Initialization changed. Old style is not supported any longer. Use the following style with log adapters. This approach allows you to add multiple adapters and each adapter contains different logic.
Logger.addLogAdapter(new AndroidLogAdapter());
FormatStrategy added. With format strategy, you can have different output format such as normal pretty look or csv. You can also add your custom format.
๐ Settings is removed. Format settings are associated with format strategy. Use the built-in functions to change the appearance or behavior.
FormatStrategy formatStrategy = PrettyFormatStrategy.newBuilder() .showThreadInfo(false) // (Optional) Whether to show thread info or not. Default true .methodCount(0) // (Optional) How many method line to show. Default 2 .methodOffset(7) // (Optional) Hides internal method calls up to offset. Default 5 .logStrategy(customLog) // (Optional) Changes the log strategy to print out. Default LogCat .tag("My custom tag") // (Optional) Custom tag for each log. Default PRETTY\_LOGGER .build();Logger.addLogAdapter(new AndroidLogAdapter(formatStrategy));
๐ LogStrategy added. Log stratey decides what to do with the input, for example: print out to logcat or save it to file. You can create your custom log strategy as well.
๐ LogLevel removed. There are many different ways when it comes to what to log and when to log. Therefore decision is now up to the developer. Log adapters contain
isLoggable
function. Simply override it and put your log condition.Logger.addLogAdapter(new AndroidLogAdapter(){ @Override public boolean isLoggable(int priority, String tag) { return BuildConfig.DEBUG; } });
๐ DiskLogAdapter added. Save output to file, CSV format is supported.
Logger.addLogAdapter(new DiskLogAdapter());
Divider's width is increased. Visual appearance change.
For more details about the new structure, check the diagram how it works.
-
v1.15
May 27, 2017 -
v1.12 Changes
October 06, 2015๐ฒ Log util can can be injected now.
.logTool()
clear() method added in order to clear the static fields when no needed
some static fields converted to local
๐ jitpack support added
-
v1.10 Changes
May 30, 2015Method count stack offset feature added. With this feature you can integrate the logger easily with other libraries.
Logger.init() .setMethodOffset(5);
-
v1.9 Changes
May 25, 2015method count bug fix
-
v1.8
April 13, 2015 -
v1.8-tag
April 13, 2015