what-the-bank/sources/com/kofax/mobile/sdk/g/h.java

206 lines
7.7 KiB
Java
Raw Normal View History

2024-07-27 18:17:47 +07:00
package com.kofax.mobile.sdk.g;
import com.kofax.kmc.ken.engines.data.ImageSource;
import com.kofax.kmc.kut.utilities.appstats.AppStatsClientEventLogger;
import com.kofax.kmc.kut.utilities.appstats.dao.AppStatsDao;
import com.kofax.kmc.kut.utilities.appstats.dao.ImageDao;
import com.kofax.kmc.kut.utilities.appstats.dao.ImgCaptureEventDao;
import com.kofax.kmc.kut.utilities.appstats.type.AppStatsDsOpType;
import com.kofax.kmc.kut.utilities.appstats.type.AppStatsEventIDType;
import com.kofax.kmc.kut.utilities.appstats.type.AppStatsInstanceType;
import com.kofax.mobile.sdk._internal.k;
import java.util.ArrayList;
/* loaded from: classes3.dex */
public class h extends a {
private static final String TAG = "h";
private String imageID;
int level;
int stability;
private AppStatsEventIDType xD;
private ImgCaptureEventDao xU;
private int xV;
private AppStatsEventIDType xW;
int xX;
int xY;
int xZ;
public h(AppStatsInstanceType appStatsInstanceType) {
super(appStatsInstanceType);
this.xU = null;
this.xD = AppStatsEventIDType.APP_STATS_UNKNOWN_EVENT;
this.imageID = null;
this.xV = 0;
this.level = -1;
this.stability = -1;
this.xX = -1;
this.xY = -1;
this.xZ = -1;
this.xW = AppStatsEventIDType.APP_STATS_UNKNOWN_EVENT;
}
public h(String str, AppStatsInstanceType appStatsInstanceType, boolean z) {
super(str, appStatsInstanceType, z);
this.xU = null;
this.xD = AppStatsEventIDType.APP_STATS_UNKNOWN_EVENT;
this.imageID = null;
this.xV = 0;
this.level = -1;
this.stability = -1;
this.xX = -1;
this.xY = -1;
this.xZ = -1;
this.xW = AppStatsEventIDType.APP_STATS_UNKNOWN_EVENT;
}
public void b(AppStatsEventIDType appStatsEventIDType) {
a(appStatsEventIDType, new AppStatsClientEventLogger(this) { // from class: com.kofax.mobile.sdk.g.h.1
final h ya;
{
this.ya = this;
}
@Override // com.kofax.kmc.kut.utilities.appstats.AppStatsClientEventLogger
public void logEvent(AppStatsEventIDType appStatsEventIDType2) {
this.ya.imageID = null;
int i = AnonymousClass3.xL[appStatsEventIDType2.ordinal()];
if (i == 1) {
this.ya.xD = appStatsEventIDType2;
if (this.ya.xW == appStatsEventIDType2 || this.ya.xX == this.ya.xV) {
return;
}
this.ya.iI();
h hVar = this.ya;
hVar.xX = hVar.xV;
return;
}
if (i == 2) {
this.ya.xD = appStatsEventIDType2;
if (this.ya.xW == appStatsEventIDType2 || this.ya.xZ == this.ya.xV) {
return;
}
this.ya.iI();
h hVar2 = this.ya;
hVar2.xZ = hVar2.xV;
return;
}
if (i != 3) {
if (i == 4) {
this.ya.xD = appStatsEventIDType2;
if (this.ya.xW == appStatsEventIDType2 || this.ya.stability == this.ya.xV) {
return;
}
this.ya.iI();
h hVar3 = this.ya;
hVar3.stability = hVar3.xV;
return;
}
return;
}
this.ya.xD = appStatsEventIDType2;
if (this.ya.xW == appStatsEventIDType2 || this.ya.level == this.ya.xV) {
return;
}
String str = h.TAG;
StringBuilder sb = new StringBuilder("------ImgCaptureAppStatsClient :: APP_STATS_IMG_CAPTURE_LEVELNESS event = ");
sb.append(this.ya.xV);
k.c(str, sb.toString());
this.ya.iI();
h hVar4 = this.ya;
hVar4.level = hVar4.xV;
}
});
}
/* renamed from: com.kofax.mobile.sdk.g.h$3, reason: invalid class name */
/* loaded from: classes3.dex */
static /* synthetic */ class AnonymousClass3 {
static final int[] xL;
static {
int[] iArr = new int[AppStatsEventIDType.values().length];
xL = iArr;
try {
iArr[AppStatsEventIDType.APP_STATS_IMG_CAPTURE_FOCUS.ordinal()] = 1;
} catch (NoSuchFieldError unused) {
}
try {
xL[AppStatsEventIDType.APP_STATS_IMG_CAPTURE_PAGEDETECT.ordinal()] = 2;
} catch (NoSuchFieldError unused2) {
}
try {
xL[AppStatsEventIDType.APP_STATS_IMG_CAPTURE_LEVELNESS.ordinal()] = 3;
} catch (NoSuchFieldError unused3) {
}
try {
xL[AppStatsEventIDType.APP_STATS_IMG_CAPTURE_STABILITY.ordinal()] = 4;
} catch (NoSuchFieldError unused4) {
}
}
}
public void a(AppStatsEventIDType appStatsEventIDType, String str) {
a(appStatsEventIDType, new AppStatsClientEventLogger(this, str) { // from class: com.kofax.mobile.sdk.g.h.2
final h ya;
final String yb;
{
this.ya = this;
this.yb = str;
}
@Override // com.kofax.kmc.kut.utilities.appstats.AppStatsClientEventLogger
public void logEvent(AppStatsEventIDType appStatsEventIDType2) {
if (appStatsEventIDType2 == AppStatsEventIDType.APP_STATS_IMG_CAPTURE_EVENT || appStatsEventIDType2 == AppStatsEventIDType.APP_STATS_IMG_EXP_CAPTURE_EVENT || appStatsEventIDType2 == AppStatsEventIDType.APP_STATS_IMG_FORCE_CAPTURE_EVENT) {
k.c(h.TAG, "eventID = ".concat(String.valueOf(appStatsEventIDType2)));
this.ya.xD = appStatsEventIDType2;
this.ya.imageID = this.yb;
this.ya.iI();
}
}
});
}
/* JADX INFO: Access modifiers changed from: private */
public void iI() {
ArrayList arrayList = new ArrayList();
ImgCaptureEventDao imgCaptureEventDao = new ImgCaptureEventDao();
this.xU = imgCaptureEventDao;
imgCaptureEventDao.setInstanceId(this.rG);
this.xU.setEventType(this.xD);
this.xU.setEventTime(this.asFriend.currentEventTime());
this.xU.setDsOperation(AppStatsDsOpType.APP_STATS_DS_INSERT);
this.xU.setValue(this.xV);
this.xU.setImageID(this.imageID);
ImgCaptureEventDao imgCaptureEventDao2 = this.xU;
imgCaptureEventDao2.setSessionKey(imgCaptureEventDao2.getAppStatsSessionKey());
arrayList.add(this.xU);
if (this.imageID != null) {
ImageDao imageDao = new ImageDao();
imageDao.setId(this.imageID);
imageDao.setDsOperation(AppStatsDsOpType.APP_STATS_DS_UPDATE);
imageDao.setSource(ImageSource.CAPTURE);
imageDao.setSessionKey(this.xU.getAppStatsSessionKey());
arrayList.add(imageDao);
}
a((AppStatsDao[]) arrayList.toArray(new AppStatsDao[arrayList.size()]));
}
private void iJ() {
a(AppStatsEventIDType.APP_STATS_IMG_CAPTURE_FOCUS, 500);
a(AppStatsEventIDType.APP_STATS_IMG_CAPTURE_PAGEDETECT, 500);
a(AppStatsEventIDType.APP_STATS_IMG_CAPTURE_LEVELNESS, 500);
a(AppStatsEventIDType.APP_STATS_IMG_CAPTURE_STABILITY, 500);
}
@Override // com.kofax.mobile.sdk.g.a
protected AppStatsEventIDType it() {
return this.xD;
}
public void g(int i) {
this.xV = i;
}
}