215 lines
7.0 KiB
Java
215 lines
7.0 KiB
Java
package com.google.android.libraries.places.internal;
|
|
|
|
import com.google.android.libraries.places.api.model.PlaceTypes;
|
|
import com.google.common.primitives.UnsignedBytes;
|
|
import java.lang.reflect.Field;
|
|
import java.nio.Buffer;
|
|
import java.security.AccessController;
|
|
import java.util.logging.Level;
|
|
import java.util.logging.Logger;
|
|
import sun.misc.Unsafe;
|
|
|
|
/* loaded from: classes2.dex */
|
|
final class zzahs {
|
|
static final long zza;
|
|
static final boolean zzb;
|
|
private static final Unsafe zzc;
|
|
private static final Class zzd;
|
|
private static final boolean zze;
|
|
private static final zzahr zzf;
|
|
private static final boolean zzg;
|
|
private static final boolean zzh;
|
|
|
|
/* JADX WARN: Removed duplicated region for block: B:14:0x006a */
|
|
/* JADX WARN: Removed duplicated region for block: B:20:0x013e */
|
|
/* JADX WARN: Removed duplicated region for block: B:25:0x014e */
|
|
/* JADX WARN: Removed duplicated region for block: B:7:0x0039 */
|
|
static {
|
|
/*
|
|
Method dump skipped, instructions count: 338
|
|
To view this dump add '--comments-level debug' option
|
|
*/
|
|
throw new UnsupportedOperationException("Method not decompiled: com.google.android.libraries.places.internal.zzahs.<clinit>():void");
|
|
}
|
|
|
|
private static int zzA(Class cls) {
|
|
if (zzh) {
|
|
return zzf.zzi(cls);
|
|
}
|
|
return -1;
|
|
}
|
|
|
|
private static Field zzC(Class cls, String str) {
|
|
try {
|
|
return cls.getDeclaredField(str);
|
|
} catch (Throwable unused) {
|
|
return null;
|
|
}
|
|
}
|
|
|
|
/* JADX INFO: Access modifiers changed from: private */
|
|
public static void zzD(Object obj, long j, byte b) {
|
|
zzahr zzahrVar = zzf;
|
|
long j2 = (-4) & j;
|
|
int zzj = zzahrVar.zzj(obj, j2);
|
|
int i = ((~((int) j)) & 3) << 3;
|
|
zzahrVar.zzn(obj, j2, ((~(255 << i)) & zzj) | ((b & UnsignedBytes.MAX_VALUE) << i));
|
|
}
|
|
|
|
/* JADX INFO: Access modifiers changed from: private */
|
|
public static void zzE(Object obj, long j, byte b) {
|
|
zzahr zzahrVar = zzf;
|
|
long j2 = (-4) & j;
|
|
int zzj = zzahrVar.zzj(obj, j2);
|
|
int i = (((int) j) & 3) << 3;
|
|
zzahrVar.zzn(obj, j2, ((~(255 << i)) & zzj) | ((b & UnsignedBytes.MAX_VALUE) << i));
|
|
}
|
|
|
|
/* JADX INFO: Access modifiers changed from: package-private */
|
|
public static double zza(Object obj, long j) {
|
|
return zzf.zza(obj, j);
|
|
}
|
|
|
|
/* JADX INFO: Access modifiers changed from: package-private */
|
|
public static float zzb(Object obj, long j) {
|
|
return zzf.zzb(obj, j);
|
|
}
|
|
|
|
/* JADX INFO: Access modifiers changed from: package-private */
|
|
public static int zzc(Object obj, long j) {
|
|
return zzf.zzj(obj, j);
|
|
}
|
|
|
|
/* JADX INFO: Access modifiers changed from: package-private */
|
|
public static long zzd(Object obj, long j) {
|
|
return zzf.zzk(obj, j);
|
|
}
|
|
|
|
/* JADX INFO: Access modifiers changed from: package-private */
|
|
public static Object zze(Class cls) {
|
|
try {
|
|
return zzc.allocateInstance(cls);
|
|
} catch (InstantiationException e) {
|
|
throw new IllegalStateException(e);
|
|
}
|
|
}
|
|
|
|
/* JADX INFO: Access modifiers changed from: package-private */
|
|
public static Object zzf(Object obj, long j) {
|
|
return zzf.zzm(obj, j);
|
|
}
|
|
|
|
/* JADX INFO: Access modifiers changed from: package-private */
|
|
public static Unsafe zzg() {
|
|
try {
|
|
return (Unsafe) AccessController.doPrivileged(new zzaho());
|
|
} catch (Throwable unused) {
|
|
return null;
|
|
}
|
|
}
|
|
|
|
static /* synthetic */ void zzh(Throwable th) {
|
|
Logger.getLogger(zzahs.class.getName()).logp(Level.WARNING, "o.vqr", "logMissingMethod", "platform method missing - proto runtime falling back to safer methods: ".concat(th.toString()));
|
|
}
|
|
|
|
/* JADX INFO: Access modifiers changed from: package-private */
|
|
public static void zzm(Object obj, long j, boolean z) {
|
|
zzf.zzc(obj, j, z);
|
|
}
|
|
|
|
/* JADX INFO: Access modifiers changed from: package-private */
|
|
public static void zzn(byte[] bArr, long j, byte b) {
|
|
zzf.zzd(bArr, zza + j, b);
|
|
}
|
|
|
|
/* JADX INFO: Access modifiers changed from: package-private */
|
|
public static void zzo(Object obj, long j, double d) {
|
|
zzf.zze(obj, j, d);
|
|
}
|
|
|
|
/* JADX INFO: Access modifiers changed from: package-private */
|
|
public static void zzp(Object obj, long j, float f) {
|
|
zzf.zzf(obj, j, f);
|
|
}
|
|
|
|
/* JADX INFO: Access modifiers changed from: package-private */
|
|
public static void zzq(Object obj, long j, int i) {
|
|
zzf.zzn(obj, j, i);
|
|
}
|
|
|
|
/* JADX INFO: Access modifiers changed from: package-private */
|
|
public static void zzr(Object obj, long j, long j2) {
|
|
zzf.zzo(obj, j, j2);
|
|
}
|
|
|
|
/* JADX INFO: Access modifiers changed from: package-private */
|
|
public static void zzs(Object obj, long j, Object obj2) {
|
|
zzf.zzp(obj, j, obj2);
|
|
}
|
|
|
|
/* JADX INFO: Access modifiers changed from: package-private */
|
|
public static /* synthetic */ boolean zzt(Object obj, long j) {
|
|
return ((byte) (zzf.zzj(obj, (-4) & j) >>> ((int) (((~j) & 3) << 3)))) != 0;
|
|
}
|
|
|
|
/* JADX INFO: Access modifiers changed from: package-private */
|
|
public static /* synthetic */ boolean zzu(Object obj, long j) {
|
|
return ((byte) (zzf.zzj(obj, (-4) & j) >>> ((int) ((j & 3) << 3)))) != 0;
|
|
}
|
|
|
|
/* JADX WARN: Multi-variable type inference failed */
|
|
static boolean zzv(Class cls) {
|
|
try {
|
|
Class cls2 = zzd;
|
|
cls2.getMethod("peekLong", cls, Boolean.TYPE);
|
|
cls2.getMethod("pokeLong", cls, Long.TYPE, Boolean.TYPE);
|
|
cls2.getMethod("pokeInt", cls, Integer.TYPE, Boolean.TYPE);
|
|
cls2.getMethod("peekInt", cls, Boolean.TYPE);
|
|
cls2.getMethod("pokeByte", cls, Byte.TYPE);
|
|
cls2.getMethod("peekByte", cls);
|
|
cls2.getMethod("pokeByteArray", cls, byte[].class, Integer.TYPE, Integer.TYPE);
|
|
cls2.getMethod("peekByteArray", cls, byte[].class, Integer.TYPE, Integer.TYPE);
|
|
return true;
|
|
} catch (Throwable unused) {
|
|
return false;
|
|
}
|
|
}
|
|
|
|
/* JADX INFO: Access modifiers changed from: package-private */
|
|
public static boolean zzw(Object obj, long j) {
|
|
return zzf.zzg(obj, j);
|
|
}
|
|
|
|
private static int zzz(Class cls) {
|
|
if (zzh) {
|
|
return zzf.zzh(cls);
|
|
}
|
|
return -1;
|
|
}
|
|
|
|
private static Field zzB() {
|
|
Field zzC = zzC(Buffer.class, "effectiveDirectAddress");
|
|
if (zzC != null) {
|
|
return zzC;
|
|
}
|
|
Field zzC2 = zzC(Buffer.class, PlaceTypes.ADDRESS);
|
|
if (zzC2 == null || zzC2.getType() != Long.TYPE) {
|
|
return null;
|
|
}
|
|
return zzC2;
|
|
}
|
|
|
|
/* JADX INFO: Access modifiers changed from: package-private */
|
|
public static boolean zzy() {
|
|
return zzg;
|
|
}
|
|
|
|
/* JADX INFO: Access modifiers changed from: package-private */
|
|
public static boolean zzx() {
|
|
return zzh;
|
|
}
|
|
|
|
private zzahs() {
|
|
}
|
|
}
|