导航菜单

页面标题

页面副标题

Clash Legends v0.0.1 - RzpTokenReceiver.java 源代码

正在查看: Clash Legends v0.0.1 应用的 RzpTokenReceiver.java JAVA 源代码文件

本页面展示 JAVA 反编译生成的源代码文件,支持语法高亮显示。 仅供安全研究与技术分析使用,严禁用于任何非法用途。请遵守相关法律法规。


package com.razorpay;

import android.content.BroadcastReceiver;
import android.content.Context;
import android.content.Intent;
import android.os.Bundle;
import android.text.TextUtils;
import org.json.JSONArray;
import org.json.JSONObject;

public class RzpTokenReceiver extends BroadcastReceiver {
    @Override
    public void onReceive(Context context, Intent intent) {
        String deviceTokenListString;
        String deviceToken = CardSaving.getDeviceToken(context);
        if (!TextUtils.isEmpty(deviceToken)) {
            Bundle results = getResultExtras(true);
            JSONArray deviceTokenInfoArray = new JSONArray();
            if (results != null && (deviceTokenListString = results.getString("device_token_info_list")) != null) {
                try {
                    deviceTokenInfoArray = new JSONArray(deviceTokenListString);
                } catch (Exception e) {
                }
            }
            JSONObject deviceTokenInfo = new JSONObject();
            try {
                deviceTokenInfo.put("rzp_device_token", deviceToken);
                deviceTokenInfo.put("card_saving_token_source", context.getPackageName());
                deviceTokenInfoArray.put(deviceTokenInfo);
            } catch (Throwable th) {
            }
            results.putString("device_token_info_list", deviceTokenInfoArray.toString());
        }
    }
}