381 lines
11 KiB
Java
381 lines
11 KiB
Java
package o;
|
|
|
|
import android.text.TextUtils;
|
|
import java.util.ArrayList;
|
|
import java.util.List;
|
|
import java.util.Map;
|
|
import java.util.NoSuchElementException;
|
|
import o.AbstractC5071bmC;
|
|
import o.GJE;
|
|
import o.InterfaceC9249dgE;
|
|
import o.ZI;
|
|
|
|
/* renamed from: o.bmC, reason: case insensitive filesystem */
|
|
/* loaded from: classes4.dex */
|
|
public abstract class AbstractC5071bmC<T extends InterfaceC9249dgE> extends ZI<T> {
|
|
final yVa a;
|
|
final jVg b;
|
|
protected final ZUb c;
|
|
Map<String, String> d;
|
|
final mZh e;
|
|
final C17020tL g;
|
|
final C15689hlW h;
|
|
List<HBt> i;
|
|
protected int k;
|
|
Map<String, String> l;
|
|
List<HBt> m;
|
|
final zxA n;
|
|
|
|
/* renamed from: o, reason: collision with root package name */
|
|
Map<String, String> f8577o;
|
|
public lUI p;
|
|
public final JaU q;
|
|
private Boolean r;
|
|
private String s;
|
|
private final zhU t;
|
|
|
|
/* renamed from: o.bmC$HBt */
|
|
/* loaded from: classes4.dex */
|
|
public enum HBt {
|
|
TITLE,
|
|
FIRST_NAME,
|
|
LAST_NAME,
|
|
MOBILE_NUMBER,
|
|
HOME_ADDRESS,
|
|
MAILING_ADDRESS,
|
|
EMAIL,
|
|
INCOMING,
|
|
MARITAL_STATUS,
|
|
EDUCATION_LEVEL,
|
|
NATIONAL_ID,
|
|
LASER_ID,
|
|
RESIDENCE_TYPE,
|
|
EXPIRY_DATE,
|
|
BIRTH_DATE,
|
|
ISSUE_DATE,
|
|
FIRST_NAME_ENGLISH,
|
|
LAST_NAME_ENGLISH
|
|
}
|
|
|
|
/* JADX INFO: Access modifiers changed from: protected */
|
|
public boolean a() {
|
|
return true;
|
|
}
|
|
|
|
/* JADX INFO: Access modifiers changed from: protected */
|
|
public AbstractC5071bmC(C16903sI c16903sI, mZh mzh, ZUb zUb, zhU zhu, C17020tL c17020tL, zxA zxa, JaU jaU, lUI lui, jVg jvg, yVa yva, C15689hlW c15689hlW) {
|
|
super(c16903sI);
|
|
this.i = new ArrayList();
|
|
this.r = Boolean.FALSE;
|
|
this.s = "";
|
|
this.k = 0;
|
|
this.e = mzh;
|
|
this.c = zUb;
|
|
this.t = zhu;
|
|
this.g = c17020tL;
|
|
this.n = zxa;
|
|
this.q = jaU;
|
|
this.p = lui;
|
|
this.b = jvg;
|
|
this.a = yva;
|
|
this.h = c15689hlW;
|
|
}
|
|
|
|
public final void a(HBt hBt, boolean z) {
|
|
if (z) {
|
|
if (this.i.contains(hBt)) {
|
|
return;
|
|
}
|
|
this.i.add(hBt);
|
|
return;
|
|
}
|
|
this.i.remove(hBt);
|
|
}
|
|
|
|
public final void e(double d) {
|
|
c(HBt.INCOMING, d >= ((double) this.k), d == 0.0d);
|
|
}
|
|
|
|
public final void c(final HBt hBt, boolean z, boolean z2) {
|
|
if (z) {
|
|
ZI.IeS ieS = new ZI.IeS(hBt) { // from class: o.bmH
|
|
private AbstractC5071bmC.HBt d;
|
|
|
|
@Override // o.ZI.IeS
|
|
public final void e(Object obj) {
|
|
((InterfaceC9249dgE) obj).b(this.d);
|
|
}
|
|
|
|
{
|
|
this.d = hBt;
|
|
}
|
|
};
|
|
if (this.f != 0) {
|
|
ieS.e(this.f);
|
|
}
|
|
} else if (z2) {
|
|
ZI.IeS ieS2 = new ZI.IeS(hBt) { // from class: o.bmG
|
|
private AbstractC5071bmC.HBt e;
|
|
|
|
@Override // o.ZI.IeS
|
|
public final void e(Object obj) {
|
|
((InterfaceC9249dgE) obj).c(this.e);
|
|
}
|
|
|
|
{
|
|
this.e = hBt;
|
|
}
|
|
};
|
|
if (this.f != 0) {
|
|
ieS2.e(this.f);
|
|
}
|
|
} else {
|
|
ZI.IeS ieS3 = new ZI.IeS(hBt) { // from class: o.bmL
|
|
private AbstractC5071bmC.HBt a;
|
|
|
|
@Override // o.ZI.IeS
|
|
public final void e(Object obj) {
|
|
((InterfaceC9249dgE) obj).a(this.a);
|
|
}
|
|
|
|
{
|
|
this.a = hBt;
|
|
}
|
|
};
|
|
if (this.f != 0) {
|
|
ieS3.e(this.f);
|
|
}
|
|
}
|
|
a(hBt, z);
|
|
}
|
|
|
|
public final void c(final HBt hBt, String str, int i, boolean z) {
|
|
if (z) {
|
|
ZI.IeS ieS = new ZI.IeS(hBt) { // from class: o.bmW
|
|
private AbstractC5071bmC.HBt a;
|
|
|
|
@Override // o.ZI.IeS
|
|
public final void e(Object obj) {
|
|
((InterfaceC9249dgE) obj).b(this.a);
|
|
}
|
|
|
|
{
|
|
this.a = hBt;
|
|
}
|
|
};
|
|
if (this.f != 0) {
|
|
ieS.e(this.f);
|
|
return;
|
|
}
|
|
return;
|
|
}
|
|
b(hBt, str, i);
|
|
}
|
|
|
|
/* JADX INFO: Access modifiers changed from: package-private */
|
|
/* renamed from: o.bmC$4, reason: invalid class name */
|
|
/* loaded from: classes4.dex */
|
|
public static /* synthetic */ class AnonymousClass4 {
|
|
static final int[] e;
|
|
|
|
static {
|
|
int[] iArr = new int[HBt.values().length];
|
|
e = iArr;
|
|
try {
|
|
iArr[HBt.FIRST_NAME.ordinal()] = 1;
|
|
} catch (NoSuchFieldError unused) {
|
|
}
|
|
try {
|
|
e[HBt.LAST_NAME.ordinal()] = 2;
|
|
} catch (NoSuchFieldError unused2) {
|
|
}
|
|
try {
|
|
e[HBt.FIRST_NAME_ENGLISH.ordinal()] = 3;
|
|
} catch (NoSuchFieldError unused3) {
|
|
}
|
|
try {
|
|
e[HBt.LAST_NAME_ENGLISH.ordinal()] = 4;
|
|
} catch (NoSuchFieldError unused4) {
|
|
}
|
|
try {
|
|
e[HBt.INCOMING.ordinal()] = 5;
|
|
} catch (NoSuchFieldError unused5) {
|
|
}
|
|
}
|
|
}
|
|
|
|
public final void b(HBt hBt, String str, int i) {
|
|
int i2 = AnonymousClass4.e[hBt.ordinal()];
|
|
if (i2 == 1 || i2 == 2) {
|
|
c(hBt, c(str, i, "^[\\u0E01-\\u0E39\\u0E40-\\u0E4C ]+$"), TextUtils.isEmpty(str));
|
|
return;
|
|
}
|
|
if (i2 == 3 || i2 == 4) {
|
|
c(hBt, c(str, i, "^[a-zA-Z .'-]+$"), TextUtils.isEmpty(str));
|
|
} else if (i2 == 5) {
|
|
c(hBt, C6583cXR.c(str).doubleValue() >= ((double) this.k), TextUtils.isEmpty(str));
|
|
}
|
|
}
|
|
|
|
public final boolean d(String str) {
|
|
if (!this.s.equals(str)) {
|
|
this.s = str != null ? str : "";
|
|
this.r = Boolean.valueOf((str == null || str.length() != 10 || (cXG.b(str, "dd/MM/yyyy") == null && cXG.b(cXG.e(str, "/"), "dd/MM/yyyy") == null)) ? false : true);
|
|
}
|
|
return this.r.booleanValue();
|
|
}
|
|
|
|
/* JADX INFO: Access modifiers changed from: package-private */
|
|
public final AbstractC13163fSk<GJE> a(final GJE.Sts sts) {
|
|
return this.t.b(sts).flatMap(new fSS(sts) { // from class: o.bmF
|
|
private GJE.Sts a;
|
|
|
|
/* JADX WARN: Multi-variable type inference failed */
|
|
@Override // o.fSS
|
|
public final Object a(Object obj) {
|
|
GJE.Sts sts2 = this.a;
|
|
zEQ zeq = (zEQ) obj;
|
|
if (zeq.d == 0) {
|
|
StringBuilder sb = new StringBuilder();
|
|
sb.append(sts2);
|
|
sb.append(" should be set before");
|
|
return AbstractC13163fSk.error(new Throwable(sb.toString()));
|
|
}
|
|
T t = zeq.d;
|
|
if (t != 0) {
|
|
return AbstractC13163fSk.just((GJE) t);
|
|
}
|
|
throw new NoSuchElementException("No value present");
|
|
}
|
|
|
|
{
|
|
this.a = sts;
|
|
}
|
|
});
|
|
}
|
|
|
|
public final void c() {
|
|
boolean a = a();
|
|
if (this.i.size() == this.m.size() && a) {
|
|
ZI.IeS ieS = new ZI.IeS() { // from class: o.bmT
|
|
@Override // o.ZI.IeS
|
|
public final void e(Object obj) {
|
|
((InterfaceC9249dgE) obj).c();
|
|
}
|
|
};
|
|
if (this.f != 0) {
|
|
ieS.e(this.f);
|
|
return;
|
|
}
|
|
return;
|
|
}
|
|
for (final HBt hBt : this.m) {
|
|
if (!this.i.contains(hBt)) {
|
|
ZI.IeS ieS2 = new ZI.IeS(hBt) { // from class: o.bmK
|
|
private AbstractC5071bmC.HBt a;
|
|
|
|
@Override // o.ZI.IeS
|
|
public final void e(Object obj) {
|
|
((InterfaceC9249dgE) obj).c(this.a);
|
|
}
|
|
|
|
{
|
|
this.a = hBt;
|
|
}
|
|
};
|
|
if (this.f != 0) {
|
|
ieS2.e(this.f);
|
|
}
|
|
}
|
|
}
|
|
ZI.IeS ieS3 = new ZI.IeS() { // from class: o.bmM
|
|
@Override // o.ZI.IeS
|
|
public final void e(Object obj) {
|
|
((InterfaceC9249dgE) obj).g();
|
|
}
|
|
};
|
|
if (this.f != 0) {
|
|
ieS3.e(this.f);
|
|
}
|
|
}
|
|
|
|
private static boolean c(String str, int i, String str2) {
|
|
return str != null && !str.trim().isEmpty() && str.length() <= i && str.matches(str2);
|
|
}
|
|
|
|
/* JADX INFO: Access modifiers changed from: protected */
|
|
public static C0306Dtd b(GJE gje) {
|
|
return new C0306Dtd(gje.f8179o, gje.n, gje.l, gje.b, gje.j, gje.c, gje.g, gje.i, gje.f, gje.k, gje.a.d, gje.d.d, gje.h.d, gje.a.b, gje.d.b, gje.h.b, gje.e);
|
|
}
|
|
|
|
/* JADX INFO: Access modifiers changed from: package-private */
|
|
public static String c(Map<String, String> map, final String str) {
|
|
zEQ d;
|
|
YKU yku = new YKU(map.entrySet());
|
|
YKU yku2 = new YKU(yku.a, new GEP(yku.b, new Jel(str) { // from class: o.bmR
|
|
private String b;
|
|
|
|
@Override // o.Jel
|
|
public final boolean e(Object obj) {
|
|
return ((String) ((Map.Entry) obj).getValue()).equalsIgnoreCase(this.b);
|
|
}
|
|
|
|
{
|
|
this.b = str;
|
|
}
|
|
}));
|
|
if (yku2.b.hasNext()) {
|
|
d = zEQ.a(yku2.b.next());
|
|
} else {
|
|
d = zEQ.d();
|
|
}
|
|
Object obj = d.b(new InterfaceC1244Ytw() { // from class: o.ss
|
|
@Override // o.InterfaceC1244Ytw
|
|
public final Object d(Object obj2) {
|
|
return (String) ((Map.Entry) obj2).getKey();
|
|
}
|
|
}).d;
|
|
if (obj == null) {
|
|
obj = "";
|
|
}
|
|
return (String) obj;
|
|
}
|
|
|
|
@Override // o.ZI
|
|
public final void w_() {
|
|
zhU zhu = this.t;
|
|
if (!zhu.h.isDisposed()) {
|
|
zhu.h.dispose();
|
|
}
|
|
ZUb zUb = this.c;
|
|
if (!zUb.h.isDisposed()) {
|
|
zUb.h.dispose();
|
|
}
|
|
mZh mzh = this.e;
|
|
if (!mzh.h.isDisposed()) {
|
|
mzh.h.dispose();
|
|
}
|
|
C15689hlW c15689hlW = this.h;
|
|
if (!c15689hlW.h.isDisposed()) {
|
|
c15689hlW.h.dispose();
|
|
}
|
|
jVg jvg = this.b;
|
|
if (!jvg.h.isDisposed()) {
|
|
jvg.h.dispose();
|
|
}
|
|
zxA zxa = this.n;
|
|
if (!zxa.h.isDisposed()) {
|
|
zxa.h.dispose();
|
|
}
|
|
yVa yva = this.a;
|
|
if (!yva.h.isDisposed()) {
|
|
yva.h.dispose();
|
|
}
|
|
super.w_();
|
|
}
|
|
|
|
public void c(int i, String str, HBt hBt) {
|
|
a(hBt, str != null || i > 0);
|
|
}
|
|
}
|