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

49 lines
1.5 KiB
Java
Raw Normal View History

2024-07-27 18:17:47 +07:00
package o;
import com.google.common.primitives.UnsignedBytes;
import com.google.zxing.ChecksumException;
import com.google.zxing.FormatException;
import com.google.zxing.common.reedsolomon.ReedSolomonException;
/* loaded from: classes2.dex */
public final class HFq {
private final lxg a = new lxg(Ayo.j);
public final Qys b(C8902dZc c8902dZc) throws FormatException, ChecksumException {
C14518fui c14518fui = new C14518fui(c8902dZc);
wbF[] a = wbF.a(c14518fui.a(), c14518fui.d);
int i = 0;
for (wbF wbf : a) {
i += wbf.e;
}
byte[] bArr = new byte[i];
int length = a.length;
for (int i2 = 0; i2 < length; i2++) {
wbF wbf2 = a[i2];
byte[] bArr2 = wbf2.d;
int i3 = wbf2.e;
e(bArr2, i3);
for (int i4 = 0; i4 < i3; i4++) {
bArr[(i4 * length) + i2] = bArr2[i4];
}
}
return iBd.b(bArr);
}
private void e(byte[] bArr, int i) throws ChecksumException {
int length = bArr.length;
int[] iArr = new int[length];
for (int i2 = 0; i2 < length; i2++) {
iArr[i2] = bArr[i2] & UnsignedBytes.MAX_VALUE;
}
try {
this.a.b(iArr, bArr.length - i);
for (int i3 = 0; i3 < i; i3++) {
bArr[i3] = (byte) iArr[i3];
}
} catch (ReedSolomonException unused) {
throw ChecksumException.e();
}
}
}