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


Java SMSSDK.submitVerificationCode方法代码示例

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


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

示例1: onClick

import cn.smssdk.SMSSDK; //导入方法依赖的package包/类
@Override
public void onClick(View v) {
    switch (v.getId()){
        case R.id.code_check:
            check();
            if (code.length() != 4){
                Toast.makeText(this, "请输入正确的验证码", Toast.LENGTH_SHORT).show();
                break;
            }
            SMSSDK.submitVerificationCode("86", phoneNumber,code);
            Toast.makeText(this, "验证中...", Toast.LENGTH_SHORT).show();
            break;
        case R.id.resend:
            //当重新发送按钮点击后,重新发送短信,倒计时重新运行,resend不能再被点击
            SMSSDK.getVerificationCode("86", phoneNumber);
            resend.setClickable(false);
            resend.setTextColor(0xff999999);
            watchTime();
            break;
    }
}
 
开发者ID:newDeepLearing,项目名称:decoy,代码行数:22,代码来源:activity_nextSign.java

示例2: onRegisteredClicked

import cn.smssdk.SMSSDK; //导入方法依赖的package包/类
/**
 * 下一步按钮监听
 *
 * @param view
 */
@OnClick(R.id.btn_register)
public void onRegisteredClicked(View view) {
    verifyCode = mVerifyEdittext.getText().toString().trim();

    if (TextUtils.isEmpty(verifyCode)) {
        ProgressHUD.showInfoMessage(mContext, getString(R.string.register_input_verify_code));
        return;
    }

    if (smsChannel == 0) {
        commitVerifyCodeBySMSApi();
    } else {
        SMSSDK.submitVerificationCode(countryNumber, mPhoneNum, verifyCode);
    }
}
 
开发者ID:LegendKe,项目名称:MyTravelingDiary,代码行数:21,代码来源:VerifyActivity.java

示例3: onClick

import cn.smssdk.SMSSDK; //导入方法依赖的package包/类
@Override
public void onClick(View v) {
    switch (v.getId()) {
        case R.id.getcode:

            mObserver = new SMSContentObserver(this, new Handler(), code);
            // 注册短信变化监听
            getContentResolver().registerContentObserver(Uri.parse("content://sms/"), true, mObserver);
            if (!Utils.isMobilePhone(phone.getText().toString())) {
                return;
            }
            SMSSDK.getVerificationCode("86", phone.getText().toString().trim());

            break;
        case R.id.verify:
            if (isSendMsg) {
               SMSSDK.submitVerificationCode("86", phone.getText().toString().trim(), code.getText().toString().trim());
            }
            break;
    }
}
 
开发者ID:Qrilee,项目名称:DevAsimpleApp,代码行数:22,代码来源:LoginActivity.java

示例4: submitCode

import cn.smssdk.SMSSDK; //导入方法依赖的package包/类
/**
 * 提交验证码
 */
private void submitCode() {

    String vCode = mEtCode.getText().toString().trim();    //验证码

    if (TextUtils.isEmpty(vCode)) {
        ToastUtils.setGravity(Gravity.CENTER, 0, 0);
        ToastUtils.showShortSafe(R.string.smssdk_write_identify_code);
        return;
    }

    SMSSDK.submitVerificationCode(countryCode, phone, vCode);
}
 
开发者ID:gaolhjy,项目名称:cniao5,代码行数:16,代码来源:RegSecondActivity.java

示例5: submitCode

import cn.smssdk.SMSSDK; //导入方法依赖的package包/类
private void submitCode() {
    mDialog.setMessage("正在验证...");
    mDialog.show();
    String code = mEtCode.getText().toString().trim();
    mPhone = mEtPhone.getText().toString().trim().replace("\\s*", "");
    if (TextUtils.isEmpty(code)) {
        mEtCode.setError("请输入验证码");
        ToastUtils.show(this, "请输入验证码");
        return;
    }
    Log.d(TAG, "submitCode: " + mPhone + code);
    SMSSDK.submitVerificationCode("86", mPhone, code);

}
 
开发者ID:yiwent,项目名称:Mobike,代码行数:15,代码来源:LoginActivity.java

示例6: enterCode

import cn.smssdk.SMSSDK; //导入方法依赖的package包/类
/**
 * 验证短信验证码
 */
private void enterCode() {
    DialogView.show();
    String code = et_code.getText().toString().trim();
    String phone = et_phone.getText().toString().trim();
    SMSSDK.submitVerificationCode("86", phone, code);

    ((PhoneRegsterActivity) getActivity()).phone = phone;

}
 
开发者ID:jiangzehui,项目名称:xmpp,代码行数:13,代码来源:PhoneRegsterFragment.java

示例7: submit

import cn.smssdk.SMSSDK; //导入方法依赖的package包/类
@OnClick(R.id.btn_register)
public void submit(View view) {
    verifyCode = mVerifyCodeEditText.getText().toString().trim();

    if (TextUtils.isEmpty(verifyCode)) {
        ProgressHUD.showInfoMessage(mContext, getString(R.string.register_input_verify_code));
        return;
    }

    if (smsChannel == 0) {
        commitVerifyCodeBySMSApi();
    } else {
        SMSSDK.submitVerificationCode(countryNumber, mPhoneNum, verifyCode);
    }
}
 
开发者ID:LegendKe,项目名称:MyTravelingDiary,代码行数:16,代码来源:RegisterVerifyActivity.java

示例8: onComplete

import cn.smssdk.SMSSDK; //导入方法依赖的package包/类
@OnClick(R.id.btn_complete)
    void onComplete() {

        String phoneNum = mNewMobile.getText().toString().trim().replaceAll("\\s*", "");
        String password = mLoginPassword.getText().toString().trim();
        String verifyCode = mGetVerifyCode.getText().toString().trim();

        if (TextUtils.isEmpty(password)) {
            ProgressHUD.showInfoMessage(mContext, getString(R.string.please_input_old_password));
            return;
        } else if (password.length() < 6 || password.length() > 16) {
            ProgressHUD.showInfoMessage(mContext, getString(R.string.register_password_tip));
            return;
        } else if (TextUtils.isEmpty(phoneNum)) {
            ProgressHUD.showInfoMessage(mContext, getString(R.string.register_please_input_phone));
            return;
        } else if (countryNumber.equals("+86") && !AppUtility.isMobilePhone(phoneNum)) {
//            ProgressHUD.showInfoMessage(mContext, getString(R.string.register_please_input_right_phone));
            dialog(getString(R.string.register_please_input_right_phone));
            return;
        } else if (phoneNum.equals(currentUser.getPhone())) {
            ProgressHUD.showInfoMessage(mContext, "对不起,您输入的新号码和原号码一致,请重新输入");
            return;
        } else if (TextUtils.isEmpty(verifyCode)) {
            ProgressHUD.showInfoMessage(mContext, getString(R.string.register_input_verify_code));
            return;
        } else {
            submitRegist();
        }

//        SMSSDK.submitVerificationCode("86", phoneNum, verifyCode);
        SMSSDK.submitVerificationCode(countryNumber, phoneNum, verifyCode);

    }
 
开发者ID:LegendKe,项目名称:MyTravelingDiary,代码行数:35,代码来源:ChangeMobileActivity.java

示例9: submitCode

import cn.smssdk.SMSSDK; //导入方法依赖的package包/类
private  void submitCode(){

        String vCode = mEtCode.getText().toString().trim();

        if (TextUtils.isEmpty(vCode)) {
            ToastUtils.show(this, R.string.smssdk_write_identify_code);
            return;
        }
        SMSSDK.submitVerificationCode(countryCode,phone,vCode);
        dialog.show();
    }
 
开发者ID:zzlnewair,项目名称:Myshop,代码行数:12,代码来源:RegSecondActivity.java

示例10: verifyRequest

import cn.smssdk.SMSSDK; //导入方法依赖的package包/类
/**
 * 核实验证码,结果发送到Listener去
 */
public static boolean verifyRequest(String phone, String code) {
    if (!isReady)
        return false;

    if (!XSCHelper.getInstance().connect()) {
        Toast.makeText(context, "当前喵网络链接", Toast.LENGTH_SHORT).show();
        return false;
    }

    SMSSDK.submitVerificationCode(CHINA, phone, code);
    return true;
}
 
开发者ID:lfkdsk,项目名称:PracticeCode,代码行数:16,代码来源:SMSValid.java

示例11: submitCode

import cn.smssdk.SMSSDK; //导入方法依赖的package包/类
/**
 * 提交验证码验证
 */
private void submitCode() {

    String vCode = mEdittxtCode.getText().toString().trim();

    if (TextUtils.isEmpty(vCode)) {
        ToastUtils.show(this, R.string.smssdk_write_identify_code);
        return;
    }
    SMSSDK.submitVerificationCode(countryCode, phone, vCode);
    //dialog.show();
}
 
开发者ID:wuyinlei,项目名称:MyHearts,代码行数:15,代码来源:RegisterSecondActivity.java

示例12: onClick

import cn.smssdk.SMSSDK; //导入方法依赖的package包/类
public void onClick(View v) 
{
	String phoneNums = inputPhoneEt.getText().toString();
	if(v.getId() == R.id.login_request_code_btn)
	{
		SMSSDK.getVerificationCode("86", phoneNums);
		requestCodeBtn.setClickable(false);
		requestCodeBtn.setText("重新发送(" + i + ")");
		new Thread(new Runnable()
		{
			public void run() 
			{
				for(; i>0; i--)
				{
					handler.sendEmptyMessage(-9);
					if(i<=0)
					{
						break;
					}
					try
					{
						Thread.sleep(1000);
						
					}catch(Exception e)
					{
						e.printStackTrace();
					}
				}
				handler.sendEmptyMessage(-8);
			}
			
		}).start();
	}
	else if(v.getId() == R.id.login_commit_btn)
	{
		SMSSDK.submitVerificationCode("86", phoneNums, inputCodeEt.getText().toString());
	}
	
		
}
 
开发者ID:ChuPeng1013,项目名称:SMSTesting,代码行数:41,代码来源:LoginActivity.java

示例13: onClick

import cn.smssdk.SMSSDK; //导入方法依赖的package包/类
@Override
public void onClick(View v) {
    switch (v.getId()) {
        case R.id.button1://获取验证码
            if (!TextUtils.isEmpty(phonEditText.getText().toString())) {
                SMSSDK.getVerificationCode("86", phonEditText.getText().toString());
                phString = phonEditText.getText().toString();
            } else {
                Toast.makeText(this, "电话不能为空", Toast.LENGTH_SHORT).show();
            }
            break;
        case R.id.button2://校验验证码
            if (!TextUtils.isEmpty(verEditText.getText().toString())) {
                SMSSDK.submitVerificationCode("86", phString, verEditText.getText().toString());

            } else {
                Toast.makeText(this, "验证码不能为空", Toast.LENGTH_SHORT).show();
            }
            break;
        case R.id.button3://国家列表
            SMSSDK.getSupportedCountries();
            //SMSSDK.getCountry("86");
            break;
        default:
            break;

    }
}
 
开发者ID:CrazyDudo,项目名称:MobSMS,代码行数:29,代码来源:CustomUI.java

示例14: onClick

import cn.smssdk.SMSSDK; //导入方法依赖的package包/类
public void onClick(View v) {
	int id = v.getId();
	int idLlBack = ResHelper.getIdRes(activity, "ll_back");
	int idBtnSubmit = ResHelper.getIdRes(activity, "btn_submit");
	int idTvUnreceiveIdentify = ResHelper.getIdRes(activity, "tv_unreceive_identify");
	int idIvClear = ResHelper.getIdRes(activity, "iv_clear");
	int idBtnSounds = ResHelper.getIdRes(activity, "btn_sounds");

	if (id == idLlBack) {
		runOnUIThread(new Runnable() {
			public void run() {
				showNotifyDialog();
			}
		});
	} else if (id == idBtnSubmit) {
		// 提交验证码
		String verificationCode = etIdentifyNum.getText().toString().trim();
		if (!TextUtils.isEmpty(code)) {
			if (pd != null && pd.isShowing()) {
				pd.dismiss();
			}
			pd = CommonDialog.ProgressDialog(activity);
			if (pd != null) {
				pd.show();
			}
			SMSSDK.submitVerificationCode(code, phone, verificationCode);
		} else {
			int resId = ResHelper.getStringRes(activity, "smssdk_write_identify_code");
			if (resId > 0) {
				Toast.makeText(getContext(), resId, Toast.LENGTH_SHORT).show();
			}
		}
	} else if (id == idTvUnreceiveIdentify) {
		showDialogType = 1;
		// 没有接收到短信
		showDialog(showDialogType);
	} else if (id == idIvClear) {
		etIdentifyNum.getText().clear();
	} else if (id == idBtnSounds) {
		long time = System.currentTimeMillis();
		if (time - lastRequestVVTime > MIN_REQUEST_VOICE_VERIFY_INTERVAL) {
			lastRequestVVTime = time;
			showDialogType = 2;
			// 发送语音验证码
			showDialog(showDialogType);
		}
	}
}
 
开发者ID:weiwenqiang,项目名称:GitHub,代码行数:49,代码来源:IdentifyNumPage.java

示例15: submitVerCode

import cn.smssdk.SMSSDK; //导入方法依赖的package包/类
public static void submitVerCode(String disCode, String phoneNum, String verCode) {
    SMSSDK.submitVerificationCode(disCode, phoneNum, verCode);
}
 
开发者ID:838030195,项目名称:DaiGo,代码行数:4,代码来源:SMSUtil.java


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