当前位置: 首页>>代码示例>>Java>>正文


Java Timber.plant方法代码示例

本文整理汇总了Java中timber.log.Timber.plant方法的典型用法代码示例。如果您正苦于以下问题:Java Timber.plant方法的具体用法?Java Timber.plant怎么用?Java Timber.plant使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在timber.log.Timber的用法示例。


在下文中一共展示了Timber.plant方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: onCreate

import timber.log.Timber; //导入方法依赖的package包/类
@Override
public void onCreate() {
    super.onCreate();
    if (BuildConfig.DEBUG) {
        if (LeakCanary.isInAnalyzerProcess(this)) {
            // This process is dedicated to LeakCanary for heap analysis.
            // You should not init your app in this process.
            return;
        }
        LeakCanary.install(this);
    }

    component = DaggerAppComponent.builder()
            .appModule(new AppModule(this))
            .netModule(new NetModule())
            .repositoryModule(new RepositoryModule())
            .build();

    Timber.plant(new Timber.DebugTree());
}
 
开发者ID:pabloserranof,项目名称:GuardianReader,代码行数:21,代码来源:MyApplication.java

示例2: onCreate

import timber.log.Timber; //导入方法依赖的package包/类
@Override
public void onCreate() {
    INSTANCE = this;
    super.onCreate();
    appComponent = DaggerApplicationComponent
            .builder()
            .apiModule(new ApiModule())
            .applicationModule(new ApplicationModule(this))
            .ciceroneModule(new CiceroneModule(Cicerone.create()))
            .build();

    if (BuildConfig.DEBUG) { //init Timber
        Timber.plant(new Timber.DebugTree());
    }

}
 
开发者ID:AntonZorin,项目名称:Mvp-app-sample,代码行数:17,代码来源:TemplateApplication.java

示例3: onCreate

import timber.log.Timber; //导入方法依赖的package包/类
@Override
protected void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    setContentView(R.layout.activity_test_player);
    ButterKnife.bind(this);
    btDecrypt.setOnClickListener(this);
    btEncrypt.setOnClickListener(this);
    allPlayerTime.setOnClickListener(this);
    startPlay.setOnClickListener(this);
    btEncryplay.setOnClickListener(this);

    if (BuildConfig.DEBUG) {
        Timber.plant(new Timber.DebugTree());
    }


    initData();
    initPlayer(deng);


}
 
开发者ID:ChangWeiBa,项目名称:AesExoPlayer,代码行数:22,代码来源:TestPlayerActivity.java

示例4: onCreate

import timber.log.Timber; //导入方法依赖的package包/类
@Override
public void onCreate() {
    super.onCreate();

    Timber.setAppTag("WearVibrationCenter");

    boolean isDebuggable = (getApplicationInfo().flags & ApplicationInfo.FLAG_DEBUGGABLE) != 0;
    if (!isDebuggable) {
        ExceptionWear.initialize(this);
        Timber.plant(new TimberExceptionWear(this));
    }

    Timber.plant(new Timber.AndroidDebugTree(isDebuggable));

    FileLogger fileLogger = FileLogger.getInstance(this);
    fileLogger.activate();
    Timber.plant(fileLogger);
}
 
开发者ID:matejdro,项目名称:WearVibrationCenter,代码行数:19,代码来源:WearVibrationCenter.java

示例5: onCreate

import timber.log.Timber; //导入方法依赖的package包/类
@Override
public void onCreate() {
    super.onCreate();

    //Enable timber
    Timber.plant(new ReleaseTree());
}
 
开发者ID:kevalpatel2106,项目名称:smart-lens,代码行数:8,代码来源:MyApplication.java

示例6: onCreate

import timber.log.Timber; //导入方法依赖的package包/类
@Override
public void onCreate() {
    super.onCreate();
    if (BuildConfig.DEBUG) Timber.plant(new Timber.DebugTree());
    mApplicationComponent = DaggerApplicationComponent.builder()
            .applicationModule(new ApplicationModule(this))
            .build();
}
 
开发者ID:weiwenqiang,项目名称:GitHub,代码行数:9,代码来源:HackerNewsApplication.java

示例7: onCreate

import timber.log.Timber; //导入方法依赖的package包/类
@Override
public void onCreate() {
    super.onCreate();
    if (BuildConfig.DEBUG) {
        Timber.plant(new Timber.DebugTree());
        Timber.tag("BasicCalculator");
    }

    applicationComponent = DaggerApplicationComponent.builder()
            .applicationModule(new ApplicationModule(this))
            .build();
}
 
开发者ID:raulh82vlc,项目名称:SimpleCalculator,代码行数:13,代码来源:BasicCalculatorApp.java

示例8: onCreate

import timber.log.Timber; //导入方法依赖的package包/类
@Override
protected void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    if (BuildConfig.DEBUG){
        Timber.plant(new Timber.DebugTree());
    }
    mBinding = DataBindingUtil.setContentView(this, R.layout.activity_main);
    setSupportActionBar(mBinding.toolbar);
}
 
开发者ID:harrynp,项目名称:BakingApp,代码行数:10,代码来源:MainActivity.java

示例9: onCreate

import timber.log.Timber; //导入方法依赖的package包/类
@Override
public void onCreate() {
    super.onCreate();
    if (BuildConfig.DEBUG) {
        Timber.plant(new AwesomeDebugTree());
    }
    MobileAppInjector.getInstance().init(this);
}
 
开发者ID:leinardi,项目名称:androidthings-kuman-sm9,代码行数:9,代码来源:MobileApp.java

示例10: onCreate

import timber.log.Timber; //导入方法依赖的package包/类
@Override public void onCreate() {
  super.onCreate();

  applicationComponent = DaggerApplicationComponent.builder()
      .applicationModule(new ApplicationModule(this))
      .contextModule(new ContextModule(this))
      .databaseModule(new DatabaseModule())
      .networkModule(new NetworkModule())
      .build();

  applicationComponent.inject(this);

  CalligraphyConfig.initDefault(calligraphyConfig);
  Timber.plant(new Timber.DebugTree());
}
 
开发者ID:nikacotAndroid,项目名称:Weather-Guru-MVP,代码行数:16,代码来源:WeatherGuruApplication.java

示例11: onCreate

import timber.log.Timber; //导入方法依赖的package包/类
@Override
public void onCreate() {
    super.onCreate();

    if (BuildConfig.DEBUG) {
        Timber.plant(new Timber.DebugTree());
    }
    Timber.i("AstaApp started");
}
 
开发者ID:AStA-HTWG-Konstanz,项目名称:app-android,代码行数:10,代码来源:AstaApp.java

示例12: onCreate

import timber.log.Timber; //导入方法依赖的package包/类
@Override
public void onCreate() {
    super.onCreate();
    if (BuildConfig.DEBUG) Timber.plant(new Timber.DebugTree());

    mApplicationComponent = DaggerApplicationComponent.builder()
            .applicationModule(new ApplicationModule(this))
            .build();
}
 
开发者ID:sathishmscict,项目名称:Pickr,代码行数:10,代码来源:PickrApplication.java

示例13: init

import timber.log.Timber; //导入方法依赖的package包/类
@Override
public void init() {
    Timber.plant(new Timber.DebugTree(){
        @Override
        protected String createStackElementTag(StackTraceElement element) {
            return super.createStackElementTag(element)+":"+element.getLineNumber();
        }
    });
}
 
开发者ID:iamBedant,项目名称:InstantAppStarter,代码行数:10,代码来源:AppImpl.java

示例14: onCreate

import timber.log.Timber; //导入方法依赖的package包/类
@Override public void onCreate() {
  super.onCreate();

  if (BuildConfig.DEBUG) {
    Timber.plant(new DebugTree());
  } else {
    Timber.plant(new ReleaseTree());
  }
}
 
开发者ID:WassimBenltaief,项目名称:TodoMvp,代码行数:10,代码来源:App.java

示例15: onCreate

import timber.log.Timber; //导入方法依赖的package包/类
@Override
public void onCreate() {
    super.onCreate();
    Timber.plant(new Timber.DebugTree());
    RealmInitializer.init(this);
}
 
开发者ID:jonashao,项目名称:Samantha,代码行数:7,代码来源:App.java


注:本文中的timber.log.Timber.plant方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。