正在查看: BodyTech v7.6.4 应用的 f.java JAVA 源代码文件
本页面展示 JAVA 反编译生成的源代码文件,支持语法高亮显示。 仅供安全研究与技术分析使用,严禁用于任何非法用途。请遵守相关法律法规。
正在查看: BodyTech v7.6.4 应用的 f.java JAVA 源代码文件
本页面展示 JAVA 反编译生成的源代码文件,支持语法高亮显示。 仅供安全研究与技术分析使用,严禁用于任何非法用途。请遵守相关法律法规。
package com.stripe.android.paymentsheet;
import androidx.compose.runtime.internal.StabilityInferred;
import com.stripe.android.model.DeferredIntentParams;
import com.stripe.android.model.PaymentIntent;
import com.stripe.android.model.SetupIntent;
import com.stripe.android.model.StripeIntent;
import com.stripe.android.paymentsheet.PaymentSheet;
import java.util.Locale;
import kotlin.Metadata;
@StabilityInferred(parameters = 1)
@Metadata(d1 = {"\u0000\u001c\n\u0002\u0018\u0002\n\u0002\u0010\u0000\n\u0002\u0018\u0002\n\u0000\n\u0002\u0018\u0002\n\u0000\n\u0002\u0010\u000b\n\u0002\b\u0005\bÀ\u0002\u0018\u00002\u00020\u0001B\t\b\u0002¢\u0006\u0004\b\t\u0010\nJ\u001e\u0010\b\u001a\u00020\u00022\u0006\u0010\u0003\u001a\u00020\u00022\u0006\u0010\u0005\u001a\u00020\u00042\u0006\u0010\u0007\u001a\u00020\u0006¨\u0006\u000b"}, d2 = {"Lcom/stripe/android/paymentsheet/f;", "", "Lcom/stripe/android/model/StripeIntent;", "stripeIntent", "Lcom/stripe/android/paymentsheet/PaymentSheet$IntentConfiguration;", "intentConfiguration", "", "isFlowController", "a", "<init>", "()V", "paymentsheet_release"}, k = 1, mv = {1, 9, 0})
public final class f {
public static final f a = new f();
private f() {
}
public final StripeIntent a(StripeIntent stripeIntent, PaymentSheet.IntentConfiguration intentConfiguration, boolean isFlowController) {
String str;
kotlin.jvm.internal.r.i(stripeIntent, "stripeIntent");
kotlin.jvm.internal.r.i(intentConfiguration, "intentConfiguration");
DeferredIntentParams b = m.b(intentConfiguration);
String str2 = null;
if (stripeIntent instanceof PaymentIntent) {
DeferredIntentParams.b mode = b.getMode();
DeferredIntentParams.b.Payment payment = mode instanceof DeferredIntentParams.b.Payment ? (DeferredIntentParams.b.Payment) mode : null;
if (payment == null) {
throw new IllegalArgumentException("You returned a PaymentIntent client secret but used a PaymentSheet.IntentConfiguration in setup mode.".toString());
}
String currency = payment.getCurrency();
Locale locale = Locale.ROOT;
String lowerCase = currency.toLowerCase(locale);
kotlin.jvm.internal.r.h(lowerCase, "toLowerCase(...)");
PaymentIntent paymentIntent = (PaymentIntent) stripeIntent;
String currency2 = paymentIntent.getCurrency();
if (currency2 != null) {
str = currency2.toLowerCase(locale);
kotlin.jvm.internal.r.h(str, "toLowerCase(...)");
} else {
str = null;
}
if (!kotlin.jvm.internal.r.d(lowerCase, str)) {
String currency3 = paymentIntent.getCurrency();
if (currency3 != null) {
str2 = currency3.toLowerCase(locale);
kotlin.jvm.internal.r.h(str2, "toLowerCase(...)");
}
String lowerCase2 = payment.getCurrency().toLowerCase(locale);
kotlin.jvm.internal.r.h(lowerCase2, "toLowerCase(...)");
throw new IllegalArgumentException(("Your PaymentIntent currency (" + str2 + ") does not match the PaymentSheet.IntentConfiguration currency (" + lowerCase2 + ").").toString());
}
if (payment.getSetupFutureUsage() != paymentIntent.getSetupFutureUsage()) {
throw new IllegalArgumentException(("Your PaymentIntent setupFutureUsage (" + paymentIntent.getSetupFutureUsage() + ") does not match the PaymentSheet.IntentConfiguration setupFutureUsage (" + payment.getSetupFutureUsage() + ").").toString());
}
if (payment.getCaptureMethod() != paymentIntent.getCaptureMethod()) {
throw new IllegalArgumentException(("Your PaymentIntent captureMethod (" + paymentIntent.getCaptureMethod() + ") does not match the PaymentSheet.IntentConfiguration captureMethod (" + payment.getCaptureMethod() + ").").toString());
}
if (paymentIntent.getConfirmationMethod() == PaymentIntent.ConfirmationMethod.e && !isFlowController) {
throw new IllegalArgumentException(("Your PaymentIntent confirmationMethod (" + paymentIntent.getConfirmationMethod() + ") can only be used with PaymentSheet.FlowController.").toString());
}
} else if (stripeIntent instanceof SetupIntent) {
DeferredIntentParams.b mode2 = b.getMode();
DeferredIntentParams.b.Setup setup = mode2 instanceof DeferredIntentParams.b.Setup ? (DeferredIntentParams.b.Setup) mode2 : null;
if (setup == null) {
throw new IllegalArgumentException("You returned a SetupIntent client secret but used a PaymentSheet.IntentConfiguration in payment mode.".toString());
}
SetupIntent setupIntent = (SetupIntent) stripeIntent;
if (setup.getSetupFutureUsage() != setupIntent.getUsage()) {
throw new IllegalArgumentException(("Your SetupIntent usage (" + setupIntent.getUsage() + ") does not match the PaymentSheet.IntentConfiguration usage (" + setupIntent.getUsage() + ").").toString());
}
}
return stripeIntent;
}
}