what-the-bank/sources/com/google/android/gms/internal/vision/zzex.java

130 lines
4.0 KiB
Java

package com.google.android.gms.internal.vision;
import java.io.IOException;
import java.nio.charset.Charset;
/* JADX INFO: Access modifiers changed from: package-private */
/* loaded from: classes2.dex */
public class zzex extends zzew {
protected final byte[] zzse;
/* JADX INFO: Access modifiers changed from: package-private */
public zzex(byte[] bArr) {
bArr.getClass();
this.zzse = bArr;
}
/* JADX INFO: Access modifiers changed from: protected */
public int zzdn() {
return 0;
}
@Override // com.google.android.gms.internal.vision.zzeo
public byte zzai(int i) {
return this.zzse[i];
}
@Override // com.google.android.gms.internal.vision.zzeo
public int size() {
return this.zzse.length;
}
@Override // com.google.android.gms.internal.vision.zzeo
public final zzeo zzc(int i, int i2) {
int zzb = zzb(0, i2, size());
if (zzb == 0) {
return zzeo.zzrx;
}
return new zzes(this.zzse, zzdn(), zzb);
}
/* JADX INFO: Access modifiers changed from: protected */
@Override // com.google.android.gms.internal.vision.zzeo
public void zza(byte[] bArr, int i, int i2, int i3) {
System.arraycopy(this.zzse, 0, bArr, 0, i3);
}
/* JADX INFO: Access modifiers changed from: package-private */
@Override // com.google.android.gms.internal.vision.zzeo
public final void zza(zzen zzenVar) throws IOException {
zzenVar.zza(this.zzse, zzdn(), size());
}
@Override // com.google.android.gms.internal.vision.zzeo
protected final String zza(Charset charset) {
return new String(this.zzse, zzdn(), size(), charset);
}
@Override // com.google.android.gms.internal.vision.zzeo
public final boolean zzdl() {
int zzdn = zzdn();
return zziw.zzg(this.zzse, zzdn, size() + zzdn);
}
@Override // com.google.android.gms.internal.vision.zzeo
public final boolean equals(Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof zzeo) || size() != ((zzeo) obj).size()) {
return false;
}
if (size() == 0) {
return true;
}
if (obj instanceof zzex) {
zzex zzexVar = (zzex) obj;
int zzdm = zzdm();
int zzdm2 = zzexVar.zzdm();
if (zzdm == 0 || zzdm2 == 0 || zzdm == zzdm2) {
return zza(zzexVar, 0, size());
}
return false;
}
return obj.equals(this);
}
@Override // com.google.android.gms.internal.vision.zzew
final boolean zza(zzeo zzeoVar, int i, int i2) {
if (i2 > zzeoVar.size()) {
int size = size();
StringBuilder sb = new StringBuilder(40);
sb.append("Length too large: ");
sb.append(i2);
sb.append(size);
throw new IllegalArgumentException(sb.toString());
}
if (i2 > zzeoVar.size()) {
int size2 = zzeoVar.size();
StringBuilder sb2 = new StringBuilder(59);
sb2.append("Ran off end of other: 0, ");
sb2.append(i2);
sb2.append(", ");
sb2.append(size2);
throw new IllegalArgumentException(sb2.toString());
}
if (zzeoVar instanceof zzex) {
zzex zzexVar = (zzex) zzeoVar;
byte[] bArr = this.zzse;
byte[] bArr2 = zzexVar.zzse;
int zzdn = zzdn();
int zzdn2 = zzdn();
int zzdn3 = zzexVar.zzdn();
while (zzdn2 < zzdn + i2) {
if (bArr[zzdn2] != bArr2[zzdn3]) {
return false;
}
zzdn2++;
zzdn3++;
}
return true;
}
return zzeoVar.zzc(0, i2).equals(zzc(0, i2));
}
@Override // com.google.android.gms.internal.vision.zzeo
protected final int zza(int i, int i2, int i3) {
return zzga.zza(i, this.zzse, zzdn(), i3);
}
}