Java Code Examples for com.tencent.bugly.crashreport.CrashReport#getAppChannel()
The following examples show how to use
com.tencent.bugly.crashreport.CrashReport#getAppChannel() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: App.java From UIWidget with Apache License 2.0 | 6 votes |
@Override public void onCreate() { super.onCreate(); sContext = this; CrashReport.initCrashReport(getApplicationContext()); String appChannel = (String) SPUtil.get(getApplicationContext(), SPConstant.SP_KEY_APP_CHANNEL, ""); Log.i("appChannel", "appChannel0:" + appChannel); if (TextUtils.isEmpty(appChannel)) { appChannel = CrashReport.getAppChannel(); Log.i("appChannel", "appChannel1:" + appChannel); SPUtil.put(getApplicationContext(), SPConstant.SP_KEY_APP_CHANNEL, appChannel); } else { CrashReport.setAppChannel(getApplicationContext(), appChannel); } Log.i("appChannel", "appChannel2:" + appChannel); if (BuildConfig.DEBUG) { CrashReport.closeBugly(); } 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); registerActivityLifecycleCallbacks(this); }