Why8n / TimberExtendedDemo

add some useful trees for timber

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

timberextended

中文文档

extra useful log classes for timber

ConstTagTree

Usage:

Timber.plant(new ConstTagTree().setTag("ConstTag"));
Timber.v("watch the tag"); //tag == "ConstTag"
Timber.v("watch the tag haha");//tag == "ConstTag"
Timber.v("watch the tag hehe");//tag == "ConstTag"

ReleaseTree

Usage:

Timber.plant(new ReleaseTree());
Timber.v("release log test: Timber.v"); //do not acutal log.
Timber.i("release log test: Timber.i"); //do not acutal log.
Timber.d("release log test: Timber.d"); //do not acutal log.
Timber.w("release log test: Timber.w"); //do log.
Timber.e("release log test: Timber.e"); //do log.
Timber.wtf("release log test: Timber.wtf"); //do log.

FileTree

Usage:

String path = Environment.getExternalStorageDirectory().getAbsolutePath();
Timber.plant(new FileTree().name("FileTree.txt").storeAt(path));
Timber.v("log in file"); //this will be store in file

MultiTagTree

Usage:

Timber.plant(new MultiTagTree().addTag("Whyn111")); //then the tag is like "Whyn111-MainActivity"
Timber.v("watch the tag");

About

add some useful trees for timber


Languages

Language:Java 100.0%