com.meituan.android.walle.WalleChannelReader Java Examples
The following examples show how to use
com.meituan.android.walle.WalleChannelReader.
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: ReadhubApplicationLike.java From JReadHub with GNU General Public License v3.0 | 5 votes |
private void initBugly() { String packageName = getApplication().getPackageName(); String processName = getProcessName(android.os.Process.myPid()); CrashReport.UserStrategy strategy = new CrashReport.UserStrategy(getApplication()); strategy.setUploadProcess(processName == null || processName.equals(packageName)); Beta.storageDir = Environment.getExternalStoragePublicDirectory(Environment.DIRECTORY_DOWNLOADS); Beta.autoCheckUpgrade = false; Beta.canShowUpgradeActs.add(MainActivity.class); String channel = WalleChannelReader.getChannel(getApplication()); strategy.setAppChannel(channel); Bugly.init(getApplication(), "c16799f8bc", false, strategy); }
Example #2
Source File: ChannelUtil.java From SimpleProject with MIT License | 5 votes |
public static String getChannel(Context context) { String chanel = WalleChannelReader.getChannel(context.getApplicationContext()); if (TextUtils.isEmpty(chanel)) { chanel = "official"; } return chanel; }
Example #3
Source File: MainActivity.java From walle with Apache License 2.0 | 5 votes |
private void readChannel() { final TextView tv = (TextView) findViewById(R.id.tv_channel); final long startTime = System.currentTimeMillis(); final ChannelInfo channelInfo = WalleChannelReader.getChannelInfo(this.getApplicationContext()); if (channelInfo != null) { tv.setText(channelInfo.getChannel() + "\n" + channelInfo.getExtraInfo()); } Toast.makeText(this, "ChannelReader takes " + (System.currentTimeMillis() - startTime) + " milliseconds", Toast.LENGTH_SHORT).show(); }
Example #4
Source File: BaseApplication.java From NewFastFrame with Apache License 2.0 | 4 votes |
private void initUM() { String channel = WalleChannelReader.getChannel(this.getApplicationContext()); UMConfigure.init(this, Constant.UM_KEY, channel, UMConfigure.DEVICE_TYPE_PHONE, null); MobclickAgent.setScenarioType(this, MobclickAgent.EScenarioType.E_UM_GAME); MobclickAgent.openActivityDurationTrack(false); }
Example #5
Source File: UMengInit.java From TemplateSimpleProject with Apache License 2.0 | 2 votes |
/** * 获取渠道信息 * * @param context * @return */ public static String getChannel(final Context context) { return WalleChannelReader.getChannel(context, DEFAULT_CHANNEL_ID); }
Example #6
Source File: UMengInit.java From TemplateAppProject with Apache License 2.0 | 2 votes |
/** * 获取渠道信息 * * @param context * @return */ public static String getChannel(final Context context) { return WalleChannelReader.getChannel(context, DEFAULT_CHANNEL_ID); }