39 lines
2.0 KiB
Java
39 lines
2.0 KiB
Java
|
package com.kofax.mobile.sdk.w;
|
||
|
|
||
|
import bolts.CancellationToken;
|
||
|
import com.google.android.gms.maps.model.BitmapDescriptorFactory;
|
||
|
import com.kofax.kmc.kut.utilities.error.ErrorInfo;
|
||
|
import com.kofax.kmc.kut.utilities.error.KmcRuntimeException;
|
||
|
import com.kofax.mobile.sdk.extract.id.AggregateException;
|
||
|
import com.kofax.mobile.sdk.extract.id.IIdExtractionListener;
|
||
|
import com.kofax.mobile.sdk.extract.id.IdExtractionParameters;
|
||
|
|
||
|
/* loaded from: classes3.dex */
|
||
|
public class j implements com.kofax.mobile.sdk.e.c {
|
||
|
private final KmcRuntimeException PR = new KmcRuntimeException(ErrorInfo.KMC_EV_CANCEL_OPERATION_SUCCESS);
|
||
|
|
||
|
@Override // com.kofax.mobile.sdk.e.c
|
||
|
public void a(Object obj, CancellationToken cancellationToken) {
|
||
|
float f;
|
||
|
com.kofax.mobile.sdk.e.a aVar = (com.kofax.mobile.sdk.e.a) obj;
|
||
|
IIdExtractionListener extractionListener = aVar.getExtractionListener();
|
||
|
IdExtractionParameters hq = aVar.hq();
|
||
|
try {
|
||
|
String str = null;
|
||
|
if (cancellationToken.isCancellationRequested()) {
|
||
|
extractionListener.onExtractionComplete(new com.kofax.mobile.sdk.u.a(false, false, 0.0d, null, BitmapDescriptorFactory.HUE_RED, null, null, null), new AggregateException(hq.getFrontImage() != null ? this.PR : null, hq.getBackImage() != null ? this.PR : null));
|
||
|
return;
|
||
|
}
|
||
|
if (aVar.hu() != null) {
|
||
|
str = aVar.hu().getClassId();
|
||
|
f = aVar.hu().getConfidence();
|
||
|
} else {
|
||
|
f = BitmapDescriptorFactory.HUE_RED;
|
||
|
}
|
||
|
extractionListener.onExtractionComplete(new com.kofax.mobile.sdk.u.a(aVar.isBarcodeRead(), aVar.isOcrRead(), aVar.getDocumentVerificationConfidenceRating(), str, f, aVar.getFaceImageField(), aVar.getSignatureImageField(), aVar.hz()), aVar.hA());
|
||
|
} catch (Exception e) {
|
||
|
com.kofax.mobile.sdk._internal.k.e("Unhandled exception in application code", e);
|
||
|
}
|
||
|
}
|
||
|
}
|