本文整理汇总了Java中com.tencent.mm.sdk.constants.Build类的典型用法代码示例。如果您正苦于以下问题:Java Build类的具体用法?Java Build怎么用?Java Build使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
Build类属于com.tencent.mm.sdk.constants包,在下文中一共展示了Build类的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。
示例1: a
import com.tencent.mm.sdk.constants.Build; //导入依赖的package包/类
public boolean a(Context context, String str) {
this.a = context;
this.b = str;
if (d()) {
String str2 = ConstantsAPI.ACTION_HANDLE_APP_REGISTER;
String str3 = "weixin://registerapp?appid=" + str;
String str4 = WXApp.WXAPP_BROADCAST_PERMISSION;
String packageName = context.getPackageName();
Intent intent = new Intent(str2);
intent.putExtra(ConstantsAPI.SDK_VERSION, Build.MUSIC_DATA_URL_SUPPORTED_SDK_INT);
intent.putExtra(ConstantsAPI.APP_PACKAGE, packageName);
intent.putExtra(ConstantsAPI.CONTENT, str3);
intent.putExtra(ConstantsAPI.CHECK_SUM, a(str3, packageName, Build.MUSIC_DATA_URL_SUPPORTED_SDK_INT));
context.sendBroadcast(intent, str4);
Ln.d("sending broadcast, intent=" + str2 + ", perm=" + str4, new Object[0]);
return true;
}
Ln.e("register app failed for wechat app signature check failed", new Object[0]);
return false;
}
开发者ID:JackChan1999,项目名称:boohee_v5.6,代码行数:21,代码来源:j.java
示例2: b
import com.tencent.mm.sdk.constants.Build; //导入依赖的package包/类
public boolean b() {
if (!d()) {
return false;
}
int parseInt;
try {
parseInt = R.parseInt(a("_build_info_sdk_int_"));
} catch (Throwable th) {
Ln.e(th);
parseInt = -1;
}
return parseInt >= Build.EMOJI_SUPPORTED_SDK_INT;
}
开发者ID:JackChan1999,项目名称:boohee_v5.6,代码行数:14,代码来源:j.java
示例3: c
import com.tencent.mm.sdk.constants.Build; //导入依赖的package包/类
public boolean c() {
int parseInt;
try {
parseInt = R.parseInt(a("_build_info_sdk_int_"));
} catch (Throwable th) {
Ln.e(th);
parseInt = -1;
}
return parseInt >= Build.TIMELINE_SUPPORTED_SDK_INT;
}
开发者ID:JackChan1999,项目名称:boohee_v5.6,代码行数:11,代码来源:j.java
示例4: pay
import com.tencent.mm.sdk.constants.Build; //导入依赖的package包/类
/**
* 付款-包括传入ip地址 - 未安装微信判断
*
* @param price 价格
* @param describe 描述
* @param notifyUrl 通知URL
* @param context
*/
public void pay(float price, String describe, String notifyUrl, Context context) {
boolean isPaySupported = msgApi.getWXAppSupportAPI() >= Build.PAY_SUPPORTED_SDK_INT;
if (!isPaySupported) {
this.ipAddress = Util.getIpAddress(context);
Toast.makeText(context, "请先安装微信 ~", Toast.LENGTH_SHORT).show();
} else {
Log.i("Z-WeChatPayDirector", "ip: " + ipAddress);
pay(price, describe, notifyUrl);
}
}
开发者ID:EthanCo,项目名称:WeChatPayModule,代码行数:19,代码来源:WeChatPayDirector.java
示例5: onStart
import com.tencent.mm.sdk.constants.Build; //导入依赖的package包/类
@Override
protected void onStart() {
if (App.getWechatAppId() == null) {
dispatchException();
return;
}
IWXAPI api = WXAPIFactory.createWXAPI(mContext, mAppId);
if (api == null) {
dispatchException();
return;
}
if (!api.isWXAppInstalled()) {
dispatchException();
return;
}
if (api.getWXAppSupportAPI() < Build.PAY_SUPPORTED_SDK_INT) {
dispatchException();
return;
}
api.registerApp(mAppId);
PayReq req = new PayReq();
req.appId = mAppId;
req.partnerId = mPartnerId;
req.prepayId = mPrepayId;
req.nonceStr = mNonceStr;
req.timeStamp = mTimeStamp;
req.packageValue = mPackageValue;
req.sign = mSign;
if (mExtData != null) {
req.extData = mExtData;
}
api.sendReq(req);
WXPayBroadcast broadcast = new WXPayBroadcast(mContext);
broadcast.setOnReceiveListener(new WXPayBroadcastReceiverListener());
if (mContext instanceof IStoppableManager) {
((IStoppableManager) mContext).bind(this);
}
broadcast.start();
}
开发者ID:wavinsun,项目名称:MUtils,代码行数:40,代码来源:WXPayTask.java
示例6: check
import com.tencent.mm.sdk.constants.Build; //导入依赖的package包/类
private boolean check() {
return mWXApi.isWXAppInstalled() && mWXApi.getWXAppSupportAPI() >= Build.PAY_SUPPORTED_SDK_INT;
}
开发者ID:cheng2016,项目名称:developNote,代码行数:4,代码来源:WXPayUtils.java
注:本文中的com.tencent.mm.sdk.constants.Build类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论