what-the-bank/sources/com/kofax/mobile/sdk/n/a.java

91 lines
2.2 KiB
Java
Raw Permalink Normal View History

2024-07-27 18:17:47 +07:00
package com.kofax.mobile.sdk.n;
import com.kofax.android.abc.machine_vision.TrackedDocument;
import com.kofax.mobile.sdk.n.c;
import o.InterfaceC13390fZB;
import o.InterfaceC13391fZD;
/* loaded from: classes3.dex */
public class a implements com.kofax.mobile.sdk.o.c {
private static final String TAG = "a";
private final com.kofax.mobile.sdk.o.a HP;
private final c HQ;
private c.a HR;
private final C0064a HS;
/* JADX INFO: Access modifiers changed from: package-private */
@InterfaceC13391fZD
public a(@InterfaceC13390fZB(a = "DOCUMENT") com.kofax.mobile.sdk.o.a aVar) {
c cVar = new c();
this.HQ = cVar;
this.HR = cVar.ma();
this.HS = C0064a.lW();
this.HP = aVar;
}
@Override // com.kofax.mobile.sdk.o.c
public TrackedDocument a(com.kofax.mobile.sdk.o.f fVar) {
if (this.HS.lY()) {
lU();
this.HS.reset();
}
TrackedDocument a = this.HP.a(fVar);
if (a == null) {
this.HS.lX();
} else {
this.HS.onSuccess();
}
return a;
}
@Override // com.kofax.mobile.sdk.o.c
public void destroy() {
this.HP.destroy();
}
private void lU() {
lV();
this.HP.a(this.HQ);
}
private void lV() {
String str = TAG;
StringBuilder sb = new StringBuilder("Changing edge type to ");
sb.append(this.HR);
com.kofax.mobile.sdk._internal.k.b(str, sb.toString());
this.HQ.a(this.HR);
this.HR = this.HR.md();
}
/* renamed from: com.kofax.mobile.sdk.n.a$a, reason: collision with other inner class name */
/* loaded from: classes3.dex */
static class C0064a {
static final int HU = 5;
private int HV;
private C0064a(int i) {
this.HV = i;
}
public static C0064a lW() {
return new C0064a(Integer.MAX_VALUE);
}
public void onSuccess() {
reset();
}
public void reset() {
this.HV = 0;
}
public boolean lY() {
return this.HV >= 5;
}
public void lX() {
this.HV++;
}
}
}