what-the-bank/sources/o/C6412cSB.java

630 lines
20 KiB
Java

package o;
import java.util.ArrayList;
import java.util.Iterator;
import java.util.List;
import o.C0690Mh;
import o.C1168Xb;
import o.C15715hv;
import o.C6412cSB;
import o.PRA;
import o.ZI;
import o.wRi;
/* renamed from: o.cSB */
/* loaded from: classes4.dex */
public final class C6412cSB extends ZI<InterfaceC6648cYz> {
public Boolean a;
public boolean b;
public Boolean c;
public boolean d;
public final mro e;
public WW g;
public Boolean h;
public Boolean i;
private final DX k;
private C1212Yc l;
public C0367Fb m;
public String n;
/* renamed from: o */
private final DW f8623o;
private String q;
private double t;
/* JADX WARN: 'super' call moved to the top of the method (can break code semantics) */
@InterfaceC13391fZD
public C6412cSB(mro mroVar, DX dx, C16903sI c16903sI, DW dw) {
super(c16903sI);
C14957gcv.e(mroVar, "");
C14957gcv.e(dx, "");
C14957gcv.e(c16903sI, "");
C14957gcv.e(dw, "");
this.e = mroVar;
this.k = dx;
this.f8623o = dw;
this.d = true;
this.t = -1.0d;
}
public final boolean c(double d, double d2, double d3) {
if (d < d2 || d > d3) {
ZI.IeS ieS = new ZI.IeS(Integer.valueOf(C15715hv.tOB.cardless_invalid_amount)) { // from class: o.cSE
private Integer a;
@Override // o.ZI.IeS
public final void e(Object obj) {
C6412cSB.a(this.a, (InterfaceC6648cYz) obj);
}
{
this.a = r1;
}
};
if (this.f != 0) {
ieS.e(this.f);
}
} else if (d % 100.0d != 0.0d) {
ZI.IeS ieS2 = new ZI.IeS(Integer.valueOf(C15715hv.tOB.cardless_invalid_divisible)) { // from class: o.cSE
private Integer a;
@Override // o.ZI.IeS
public final void e(Object obj) {
C6412cSB.a(this.a, (InterfaceC6648cYz) obj);
}
{
this.a = r1;
}
};
if (this.f != 0) {
ieS2.e(this.f);
}
} else if (d > d()) {
ZI.IeS ieS3 = new ZI.IeS(Integer.valueOf(C15715hv.tOB.cardless_invalid_insufficient_balance)) { // from class: o.cSE
private Integer a;
@Override // o.ZI.IeS
public final void e(Object obj) {
C6412cSB.a(this.a, (InterfaceC6648cYz) obj);
}
{
this.a = r1;
}
};
if (this.f != 0) {
ieS3.e(this.f);
}
} else {
ZI.IeS ieS4 = new ZI.IeS(null) { // from class: o.cSE
private Integer a;
@Override // o.ZI.IeS
public final void e(Object obj) {
C6412cSB.a(this.a, (InterfaceC6648cYz) obj);
}
{
this.a = r1;
}
};
if (this.f != 0) {
ieS4.e(this.f);
}
return true;
}
return false;
}
/* renamed from: o.cSB$Sts */
/* loaded from: classes4.dex */
public final class Sts extends wRi.LWm<xEp> {
private C6412cSB d;
public Sts(C6412cSB c6412cSB) {
this.d = c6412cSB;
}
@Override // o.wRi.LWm, o.InterfaceC13174fSv
public final /* synthetic */ void onNext(Object obj) {
xEp xep = (xEp) obj;
C14957gcv.e(xep, "");
C6412cSB c6412cSB = this.d;
ZI.IeS ieS = new ZI.IeS(c6412cSB, xep) { // from class: o.cSL
private C6412cSB c;
private xEp d;
@Override // o.ZI.IeS
public final void e(Object obj2) {
C6412cSB.Sts.a(this.c, this.d, (InterfaceC6648cYz) obj2);
}
{
this.c = c6412cSB;
this.d = xep;
}
};
if (c6412cSB.f != 0) {
ieS.e(c6412cSB.f);
}
}
@Override // o.wRi.LWm, o.InterfaceC13174fSv
public final void onError(Throwable th) {
C14957gcv.e(th, "");
C6412cSB.a(this.d, th, C0690Mh.IeS.NAVIGATE_BACK);
}
public static /* synthetic */ void a(C6412cSB c6412cSB, xEp xep, InterfaceC6648cYz interfaceC6648cYz) {
C14957gcv.e(c6412cSB, "");
C14957gcv.e(xep, "");
c6412cSB.l = c6412cSB.f8623o.d(xep);
C1212Yc c1212Yc = c6412cSB.l;
if (c1212Yc != null) {
if (c1212Yc.g) {
interfaceC6648cYz.c();
} else {
interfaceC6648cYz.br_();
}
}
}
}
private final C1210Yb c(List<C1210Yb> list) {
Object obj;
Iterator<T> it = list.iterator();
while (true) {
obj = null;
if (!it.hasNext()) {
break;
}
Object next = it.next();
C1210Yb c1210Yb = (C1210Yb) next;
if (gdZ.a(this.n, c1210Yb != null ? c1210Yb.i : null, true)) {
obj = next;
break;
}
}
return (C1210Yb) obj;
}
/* renamed from: o.cSB$HBt */
/* loaded from: classes4.dex */
public final class HBt extends wRi.LWm<SVW> {
private final C12817fI a;
private final String b;
private C6412cSB e;
public static /* synthetic */ void e() {
}
@Override // o.wRi.LWm, o.InterfaceC13174fSv
public final /* synthetic */ void onNext(Object obj) {
SVW svw = (SVW) obj;
C14957gcv.e(svw, "");
String str = svw.b;
if (str != null) {
C6412cSB c6412cSB = this.e;
int hashCode = str.hashCode();
if (hashCode != 1507423) {
if (hashCode != 1567040) {
if (hashCode != 1567043 || !str.equals("3017")) {
return;
}
} else if (!str.equals("3014")) {
return;
}
c6412cSB.d(c6412cSB.j.b(svw.a, svw.e, C15715hv.tOB.confirm, C15715hv.tOB.cancel, new Runnable(this, svw) { // from class: o.cSS
private SVW a;
private C6412cSB.HBt b;
@Override // java.lang.Runnable
public final void run() {
C6412cSB.HBt.a(this.b, this.a);
}
{
this.b = this;
this.a = svw;
}
}, new Runnable() { // from class: o.cSP
@Override // java.lang.Runnable
public final void run() {
C6412cSB.HBt.e();
}
}));
return;
}
if (str.equals("1000")) {
C6412cSB c6412cSB2 = this.e;
cSQ csq = new cSQ(c6412cSB2, this, svw);
if (c6412cSB2.f != 0) {
csq.e(c6412cSB2.f);
}
}
}
}
public HBt(C6412cSB c6412cSB, C12817fI c12817fI, String str) {
C14957gcv.e(c12817fI, "");
this.e = c6412cSB;
this.a = c12817fI;
this.b = str;
}
@Override // o.wRi.LWm, o.InterfaceC13174fSv
public final void onError(Throwable th) {
C14957gcv.e(th, "");
C6412cSB.b(this.e, th);
}
public static /* synthetic */ void a(C6412cSB c6412cSB, HBt hBt, SVW svw, InterfaceC6648cYz interfaceC6648cYz) {
C14957gcv.e(c6412cSB, "");
C14957gcv.e(hBt, "");
C14957gcv.e(svw, "");
interfaceC6648cYz.ar_();
DX dx = c6412cSB.k;
C12817fI c12817fI = hBt.a;
String str = hBt.b;
String str2 = EnumC6470cTu.DEPOSIT.typeCode.equalsIgnoreCase(c12817fI.c) ? (String) C16157lj.c(new Object[]{c12817fI.b, Boolean.valueOf(c6412cSB.e.c.T())}, 1230925834, -1230925834, (int) System.currentTimeMillis()) : str;
if (EnumC6470cTu.DEPOSIT.typeCode.equalsIgnoreCase(c12817fI.c)) {
str = c12817fI.b;
}
C1208Ya c1208Ya = new C1208Ya();
c1208Ya.c = DX.c(Double.valueOf(c12817fI.a));
c1208Ya.a = str2;
c1208Ya.f8464o = str;
YKU yku = new YKU(svw.j);
c1208Ya.f = (List) new YKU(yku.a, new wxK(yku.b, new InterfaceC1244Ytw() { // from class: o.DZ
@Override // o.InterfaceC1244Ytw
public final Object d(Object obj) {
return DX.b((C0615KrK) obj);
}
})).a(new PRA.Sts(new PRA.AnonymousClass4(), new PRA.AnonymousClass8()));
YKU yku2 = new YKU(svw.j);
c1208Ya.i = (List) new YKU(yku2.a, new wxK(yku2.b, new InterfaceC1244Ytw(dx) { // from class: o.Ec
private DX d;
@Override // o.InterfaceC1244Ytw
public final Object d(Object obj) {
String h;
h = DX.h(((C0615KrK) obj).c);
return h;
}
{
this.d = dx;
}
})).a(new PRA.Sts(new PRA.AnonymousClass4(), new PRA.AnonymousClass8()));
c1208Ya.b = svw.c;
c1208Ya.h = svw.f;
c1208Ya.e = dx.b_(svw.h);
c1208Ya.g = c12817fI.c;
c1208Ya.j = svw.i;
if (svw.d != null && svw.g != null) {
ArrayList arrayList = new ArrayList();
if (svw.d != null) {
arrayList.add(DX.e(svw.d));
}
if (svw.g != null) {
arrayList.add(DX.e(svw.g));
}
C1168Xb.LWm lWm = new C1168Xb.LWm();
lWm.a = arrayList;
c1208Ya.d = new C1168Xb(lWm, (byte) 0);
}
C14957gcv.c(c1208Ya, "");
interfaceC6648cYz.b(c1208Ya, c6412cSB.q);
}
public static /* synthetic */ void a(HBt hBt, SVW svw) {
C14957gcv.e(hBt, "");
C14957gcv.e(svw, "");
C6412cSB c6412cSB = hBt.e;
cSQ csq = new cSQ(c6412cSB, hBt, svw);
if (c6412cSB.f != 0) {
csq.e(c6412cSB.f);
}
}
}
@Override // o.ZI
public final void w_() {
mro mroVar = this.e;
if (!mroVar.h.isDisposed()) {
mroVar.h.dispose();
}
super.w_();
}
/* renamed from: o.cSB$LWm */
/* loaded from: classes4.dex */
public static final class LWm {
private LWm() {
}
public /* synthetic */ LWm(byte b) {
this();
}
}
public static /* synthetic */ void d(C6412cSB c6412cSB, InterfaceC6648cYz interfaceC6648cYz) {
C14957gcv.e(c6412cSB, "");
interfaceC6648cYz.b(c6412cSB.q);
}
public static /* synthetic */ void a(C6412cSB c6412cSB, InterfaceC6648cYz interfaceC6648cYz) {
C14957gcv.e(c6412cSB, "");
C1212Yc c1212Yc = c6412cSB.l;
if (c1212Yc != null) {
if (!c1212Yc.c.isEmpty()) {
C1210Yb c = c6412cSB.c(c1212Yc.c);
interfaceC6648cYz.c(c);
c6412cSB.q = c != null ? c.d : null;
interfaceC6648cYz.b(c != null ? c.d : null);
return;
}
EnumC17575xuS enumC17575xuS = c1212Yc.a;
C14957gcv.e(enumC17575xuS, "");
if (EnumC17575xuS.SUCCESS == enumC17575xuS || EnumC17575xuS.CASA_FAIL == enumC17575xuS) {
interfaceC6648cYz.d(c1212Yc.e);
} else {
interfaceC6648cYz.a();
}
}
}
/* JADX WARN: Code restructure failed: missing block: B:20:0x004b, code lost:
if (o.gdZ.a("MOUSPD", r0 != null ? r0.V : null, true) != false) goto L58;
*/
/* JADX WARN: Removed duplicated region for block: B:24:0x005d */
/* JADX WARN: Removed duplicated region for block: B:27:? A[RETURN, SYNTHETIC] */
/*
Code decompiled incorrectly, please refer to instructions dump.
To view partially-correct add '--show-bad-code' argument
*/
public static /* synthetic */ void e(o.C6412cSB r4, o.InterfaceC6648cYz r5) {
/*
java.lang.String r0 = ""
o.C14957gcv.e(r4, r0)
o.Yc r0 = r4.l
if (r0 == 0) goto L66
java.util.List<o.Yb> r1 = r0.d
java.util.Collection r1 = (java.util.Collection) r1
boolean r1 = r1.isEmpty()
r2 = 1
r1 = r1 ^ r2
if (r1 == 0) goto L63
java.util.List<o.Yb> r0 = r0.d
o.Yb r0 = r4.c(r0)
r5.c(r0)
if (r0 == 0) goto L62
o.Yg r5 = r0.c
if (r5 == 0) goto L62
java.lang.String r0 = r4.n
java.lang.String r1 = "B2K"
boolean r0 = o.gdZ.a(r1, r0, r2)
if (r0 == 0) goto L50
o.Fb r0 = r4.m
r1 = 0
if (r0 == 0) goto L36
java.lang.String r0 = r0.V
goto L37
L36:
r0 = r1
L37:
java.lang.String r3 = "NONSPD"
boolean r0 = o.gdZ.a(r3, r0, r2)
if (r0 != 0) goto L4d
o.Fb r0 = r4.m
if (r0 == 0) goto L45
java.lang.String r1 = r0.V
L45:
java.lang.String r0 = "MOUSPD"
boolean r0 = o.gdZ.a(r0, r1, r2)
if (r0 == 0) goto L50
L4d:
java.lang.String r5 = r5.e
goto L52
L50:
java.lang.String r5 = r5.a
L52:
r4.q = r5
o.cSN r5 = new o.cSN
r5.<init>(r4)
T extends o.cYp r0 = r4.f
if (r0 == 0) goto L62
T extends o.cYp r4 = r4.f
r5.e(r4)
L62:
return
L63:
r5.a()
L66:
return
*/
throw new UnsupportedOperationException("Method not decompiled: o.C6412cSB.e(o.cSB, o.cYz):void");
}
public static /* synthetic */ void d(C6412cSB c6412cSB, WW ww, InterfaceC6648cYz interfaceC6648cYz) {
C14957gcv.e(c6412cSB, "");
if (c6412cSB.b && ww.j != null) {
interfaceC6648cYz.e(ww.j);
} else {
interfaceC6648cYz.e(ww.d);
}
}
public static /* synthetic */ void b(C6412cSB c6412cSB, InterfaceC6648cYz interfaceC6648cYz) {
C14957gcv.e(c6412cSB, "");
C1212Yc c1212Yc = c6412cSB.l;
if (c1212Yc != null) {
if (c1212Yc.b != null) {
interfaceC6648cYz.c(c1212Yc.b);
C1210Yb c1210Yb = c1212Yc.b;
String str = c1210Yb != null ? c1210Yb.d : null;
c6412cSB.q = str;
interfaceC6648cYz.b(str);
} else {
EnumC17575xuS enumC17575xuS = c1212Yc.a;
C14957gcv.e(enumC17575xuS, "");
if (EnumC17575xuS.SUCCESS == enumC17575xuS || EnumC17575xuS.CARD_FAIL == enumC17575xuS) {
interfaceC6648cYz.e(c1212Yc.e);
} else {
interfaceC6648cYz.a();
}
}
if (c6412cSB.f != 0) {
c6412cSB.f.ar_();
}
}
}
public static /* synthetic */ void c(C6412cSB c6412cSB, InterfaceC6648cYz interfaceC6648cYz) {
C14957gcv.e(c6412cSB, "");
if (c6412cSB.d) {
Boolean bool = c6412cSB.c;
if (bool != null && bool.booleanValue()) {
interfaceC6648cYz.a();
return;
}
Boolean bool2 = c6412cSB.i;
if (bool2 != null && !bool2.booleanValue()) {
C1212Yc c1212Yc = c6412cSB.l;
interfaceC6648cYz.e(c1212Yc != null ? c1212Yc.e : null);
} else {
cSM csm = new cSM(c6412cSB);
if (c6412cSB.f != 0) {
csm.e(c6412cSB.f);
}
}
}
}
public static /* synthetic */ void a(Integer num, InterfaceC6648cYz interfaceC6648cYz) {
C14866gag c14866gag;
if (num != null) {
interfaceC6648cYz.c(num.intValue());
c14866gag = C14866gag.c;
} else {
c14866gag = null;
}
if (c14866gag == null) {
interfaceC6648cYz.e();
}
}
public static /* synthetic */ void g(C6412cSB c6412cSB, InterfaceC6648cYz interfaceC6648cYz) {
C14957gcv.e(c6412cSB, "");
if (c6412cSB.d) {
return;
}
Boolean bool = c6412cSB.a;
if (bool != null && bool.booleanValue()) {
interfaceC6648cYz.a();
return;
}
Boolean bool2 = c6412cSB.h;
if (bool2 != null && !bool2.booleanValue()) {
C1212Yc c1212Yc = c6412cSB.l;
interfaceC6648cYz.d(c1212Yc != null ? c1212Yc.e : null);
} else {
c6412cSB.c();
}
}
public static final /* synthetic */ void b(C6412cSB c6412cSB, Throwable th) {
if (c6412cSB.b(th)) {
c6412cSB.d(c6412cSB.j.e(th));
}
}
public static final /* synthetic */ void a(C6412cSB c6412cSB, Throwable th, C0690Mh.IeS ieS) {
if (c6412cSB.b(th)) {
c6412cSB.d(c6412cSB.j.d(th, ieS));
}
}
public final void c() {
String str;
C0367Fb c0367Fb = this.m;
if (c0367Fb != null) {
if (!C2974aoj.c(c0367Fb.U)) {
this.n = c0367Fb.U;
if (c0367Fb == null || (str = c0367Fb.V) == null || !gdZ.d(str, "SPD", false)) {
ZI.IeS ieS = new ZI.IeS(this) { // from class: o.cSK
private C6412cSB a;
@Override // o.ZI.IeS
public final void e(Object obj) {
C6412cSB.a(this.a, (InterfaceC6648cYz) obj);
}
{
this.a = this;
}
};
if (this.f != 0) {
ieS.e(this.f);
}
} else {
ZI.IeS ieS2 = new ZI.IeS(this) { // from class: o.cSA
private C6412cSB e;
@Override // o.ZI.IeS
public final void e(Object obj) {
C6412cSB.e(this.e, (InterfaceC6648cYz) obj);
}
{
this.e = this;
}
};
if (this.f != 0) {
ieS2.e(this.f);
}
}
}
if (this.f != 0) {
this.f.ar_();
}
}
}
public final double d() {
WW ww;
if (!this.d || (ww = this.g) == null) {
C0367Fb c0367Fb = this.m;
if (c0367Fb != null) {
Double c = C6583cXR.c(c0367Fb != null ? c0367Fb.d : null);
C14957gcv.c(c, "");
return c.doubleValue();
}
} else if (ww != null) {
if (this.b && ww.j != null) {
Double d = ww.j;
C14957gcv.c(d, "");
return d.doubleValue();
}
Double d2 = ww.d;
C14957gcv.c(d2, "");
return d2.doubleValue();
}
return this.t;
}
public static boolean d(C0367Fb c0367Fb) {
String str;
if (c0367Fb == null || (str = c0367Fb.V) == null) {
return false;
}
return gdZ.d(str, "SPD", false);
}
static {
new LWm((byte) 0);
}
}