Initial commit
This commit is contained in:
@@ -0,0 +1,24 @@
|
||||
package com.google.android.gms.common.internal;
|
||||
|
||||
import android.accounts.Account;
|
||||
import android.os.Binder;
|
||||
import android.os.RemoteException;
|
||||
import android.util.Log;
|
||||
import com.google.android.gms.common.internal.IAccountAccessor;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public class AccountAccessor extends IAccountAccessor.Stub {
|
||||
public static Account a(IAccountAccessor iAccountAccessor) {
|
||||
if (iAccountAccessor != null) {
|
||||
long clearCallingIdentity = Binder.clearCallingIdentity();
|
||||
try {
|
||||
return iAccountAccessor.a();
|
||||
} catch (RemoteException unused) {
|
||||
Log.w("AccountAccessor", "Remote account accessor probably died");
|
||||
} finally {
|
||||
Binder.restoreCallingIdentity(clearCallingIdentity);
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
}
|
45
sources/com/google/android/gms/common/internal/Asserts.java
Normal file
45
sources/com/google/android/gms/common/internal/Asserts.java
Normal file
@@ -0,0 +1,45 @@
|
||||
package com.google.android.gms.common.internal;
|
||||
|
||||
import android.os.Looper;
|
||||
import android.util.Log;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public final class Asserts {
|
||||
public static void a(Object obj) {
|
||||
if (obj == null) {
|
||||
throw new IllegalArgumentException("null reference");
|
||||
}
|
||||
}
|
||||
|
||||
public static void b(String str) {
|
||||
if (Looper.getMainLooper().getThread() != Thread.currentThread()) {
|
||||
return;
|
||||
}
|
||||
String valueOf = String.valueOf(Thread.currentThread());
|
||||
String valueOf2 = String.valueOf(Looper.getMainLooper().getThread());
|
||||
StringBuilder sb = new StringBuilder(String.valueOf(valueOf).length() + 56 + String.valueOf(valueOf2).length());
|
||||
sb.append("checkNotMainThread: current thread ");
|
||||
sb.append(valueOf);
|
||||
sb.append(" IS the main thread ");
|
||||
sb.append(valueOf2);
|
||||
sb.append("!");
|
||||
Log.e("Asserts", sb.toString());
|
||||
throw new IllegalStateException(str);
|
||||
}
|
||||
|
||||
public static void a(String str) {
|
||||
if (Looper.getMainLooper().getThread() == Thread.currentThread()) {
|
||||
return;
|
||||
}
|
||||
String valueOf = String.valueOf(Thread.currentThread());
|
||||
String valueOf2 = String.valueOf(Looper.getMainLooper().getThread());
|
||||
StringBuilder sb = new StringBuilder(String.valueOf(valueOf).length() + 57 + String.valueOf(valueOf2).length());
|
||||
sb.append("checkMainThread: current thread ");
|
||||
sb.append(valueOf);
|
||||
sb.append(" IS NOT the main thread ");
|
||||
sb.append(valueOf2);
|
||||
sb.append("!");
|
||||
Log.e("Asserts", sb.toString());
|
||||
throw new IllegalStateException(str);
|
||||
}
|
||||
}
|
@@ -0,0 +1,113 @@
|
||||
package com.google.android.gms.common.internal;
|
||||
|
||||
import android.accounts.Account;
|
||||
import android.os.IBinder;
|
||||
import android.os.Parcel;
|
||||
import android.os.Parcelable;
|
||||
import com.google.android.gms.common.api.Scope;
|
||||
import com.google.android.gms.common.internal.IAccountAccessor;
|
||||
import com.google.android.gms.common.internal.safeparcel.AbstractSafeParcelable;
|
||||
import com.google.android.gms.common.internal.safeparcel.SafeParcelWriter;
|
||||
import java.util.Arrays;
|
||||
import java.util.HashSet;
|
||||
import java.util.Set;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public class AuthAccountRequest extends AbstractSafeParcelable {
|
||||
public static final Parcelable.Creator<AuthAccountRequest> CREATOR = new zaa();
|
||||
private final int zale;
|
||||
|
||||
@Deprecated
|
||||
private final IBinder zanw;
|
||||
private final Scope[] zanx;
|
||||
private Integer zany;
|
||||
private Integer zanz;
|
||||
private Account zax;
|
||||
|
||||
AuthAccountRequest(int i, IBinder iBinder, Scope[] scopeArr, Integer num, Integer num2, Account account) {
|
||||
this.zale = i;
|
||||
this.zanw = iBinder;
|
||||
this.zanx = scopeArr;
|
||||
this.zany = num;
|
||||
this.zanz = num2;
|
||||
this.zax = account;
|
||||
}
|
||||
|
||||
public Account getAccount() {
|
||||
Account account = this.zax;
|
||||
if (account != null) {
|
||||
return account;
|
||||
}
|
||||
IBinder iBinder = this.zanw;
|
||||
if (iBinder != null) {
|
||||
return AccountAccessor.a(IAccountAccessor.Stub.a(iBinder));
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
public Integer getOauthPolicy() {
|
||||
return this.zany;
|
||||
}
|
||||
|
||||
public Integer getPolicyAction() {
|
||||
return this.zanz;
|
||||
}
|
||||
|
||||
public Set<Scope> getScopes() {
|
||||
return new HashSet(Arrays.asList(this.zanx));
|
||||
}
|
||||
|
||||
public AuthAccountRequest setOauthPolicy(Integer num) {
|
||||
this.zany = num;
|
||||
return this;
|
||||
}
|
||||
|
||||
public AuthAccountRequest setPolicyAction(Integer num) {
|
||||
this.zanz = num;
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override // android.os.Parcelable
|
||||
public void writeToParcel(Parcel parcel, int i) {
|
||||
int a = SafeParcelWriter.a(parcel);
|
||||
SafeParcelWriter.a(parcel, 1, this.zale);
|
||||
SafeParcelWriter.a(parcel, 2, this.zanw, false);
|
||||
SafeParcelWriter.a(parcel, 3, (Parcelable[]) this.zanx, i, false);
|
||||
SafeParcelWriter.a(parcel, 4, this.zany, false);
|
||||
SafeParcelWriter.a(parcel, 5, this.zanz, false);
|
||||
SafeParcelWriter.a(parcel, 6, (Parcelable) this.zax, i, false);
|
||||
SafeParcelWriter.a(parcel, a);
|
||||
}
|
||||
|
||||
@Deprecated
|
||||
public AuthAccountRequest(IAccountAccessor iAccountAccessor, Set<Scope> set) {
|
||||
this(3, iAccountAccessor.asBinder(), (Scope[]) set.toArray(new Scope[set.size()]), null, null, null);
|
||||
}
|
||||
|
||||
/* JADX WARN: Illegal instructions before constructor call */
|
||||
/*
|
||||
Code decompiled incorrectly, please refer to instructions dump.
|
||||
To view partially-correct code enable 'Show inconsistent code' option in preferences
|
||||
*/
|
||||
public AuthAccountRequest(android.accounts.Account r8, java.util.Set<com.google.android.gms.common.api.Scope> r9) {
|
||||
/*
|
||||
r7 = this;
|
||||
int r0 = r9.size()
|
||||
com.google.android.gms.common.api.Scope[] r0 = new com.google.android.gms.common.api.Scope[r0]
|
||||
java.lang.Object[] r9 = r9.toArray(r0)
|
||||
r3 = r9
|
||||
com.google.android.gms.common.api.Scope[] r3 = (com.google.android.gms.common.api.Scope[]) r3
|
||||
com.google.android.gms.common.internal.Preconditions.a(r8)
|
||||
r6 = r8
|
||||
android.accounts.Account r6 = (android.accounts.Account) r6
|
||||
r1 = 3
|
||||
r2 = 0
|
||||
r4 = 0
|
||||
r5 = 0
|
||||
r0 = r7
|
||||
r0.<init>(r1, r2, r3, r4, r5, r6)
|
||||
return
|
||||
*/
|
||||
throw new UnsupportedOperationException("Method not decompiled: com.google.android.gms.common.internal.AuthAccountRequest.<init>(android.accounts.Account, java.util.Set):void");
|
||||
}
|
||||
}
|
@@ -0,0 +1,803 @@
|
||||
package com.google.android.gms.common.internal;
|
||||
|
||||
import android.accounts.Account;
|
||||
import android.app.PendingIntent;
|
||||
import android.content.ComponentName;
|
||||
import android.content.Context;
|
||||
import android.content.ServiceConnection;
|
||||
import android.os.Bundle;
|
||||
import android.os.DeadObjectException;
|
||||
import android.os.Handler;
|
||||
import android.os.IBinder;
|
||||
import android.os.IInterface;
|
||||
import android.os.Looper;
|
||||
import android.os.Message;
|
||||
import android.os.Parcel;
|
||||
import android.os.RemoteException;
|
||||
import android.text.TextUtils;
|
||||
import android.util.Log;
|
||||
import com.google.android.gms.common.ConnectionResult;
|
||||
import com.google.android.gms.common.Feature;
|
||||
import com.google.android.gms.common.GoogleApiAvailabilityLight;
|
||||
import com.google.android.gms.common.api.Scope;
|
||||
import com.google.android.gms.common.internal.GmsClientSupervisor;
|
||||
import com.google.android.gms.common.internal.IGmsCallbacks;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Collections;
|
||||
import java.util.Set;
|
||||
import java.util.concurrent.atomic.AtomicInteger;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public abstract class BaseGmsClient<T extends IInterface> {
|
||||
private static final Feature[] v = new Feature[0];
|
||||
private zzh a;
|
||||
private final Context b;
|
||||
private final GmsClientSupervisor c;
|
||||
private final GoogleApiAvailabilityLight d;
|
||||
final Handler e;
|
||||
private final Object f;
|
||||
private final Object g;
|
||||
private IGmsServiceBroker h;
|
||||
protected ConnectionProgressReportCallbacks i;
|
||||
private T j;
|
||||
private final ArrayList<zzc<?>> k;
|
||||
private zze l;
|
||||
private int m;
|
||||
private final BaseConnectionCallbacks n;
|
||||
private final BaseOnConnectionFailedListener o;
|
||||
private final int p;
|
||||
private final String q;
|
||||
private ConnectionResult r;
|
||||
private boolean s;
|
||||
private volatile com.google.android.gms.common.internal.zzb t;
|
||||
protected AtomicInteger u;
|
||||
|
||||
public interface BaseConnectionCallbacks {
|
||||
void d(Bundle bundle);
|
||||
|
||||
void i(int i);
|
||||
}
|
||||
|
||||
public interface BaseOnConnectionFailedListener {
|
||||
void a(ConnectionResult connectionResult);
|
||||
}
|
||||
|
||||
public interface ConnectionProgressReportCallbacks {
|
||||
void a(ConnectionResult connectionResult);
|
||||
}
|
||||
|
||||
protected class LegacyClientCallbackAdapter implements ConnectionProgressReportCallbacks {
|
||||
public LegacyClientCallbackAdapter() {
|
||||
}
|
||||
|
||||
@Override // com.google.android.gms.common.internal.BaseGmsClient.ConnectionProgressReportCallbacks
|
||||
public void a(ConnectionResult connectionResult) {
|
||||
if (connectionResult.isSuccess()) {
|
||||
BaseGmsClient baseGmsClient = BaseGmsClient.this;
|
||||
baseGmsClient.a((IAccountAccessor) null, baseGmsClient.r());
|
||||
} else if (BaseGmsClient.this.o != null) {
|
||||
BaseGmsClient.this.o.a(connectionResult);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public interface SignOutCallbacks {
|
||||
void a();
|
||||
}
|
||||
|
||||
private abstract class zza extends zzc<Boolean> {
|
||||
private final int d;
|
||||
private final Bundle e;
|
||||
|
||||
protected zza(int i, Bundle bundle) {
|
||||
super(true);
|
||||
this.d = i;
|
||||
this.e = bundle;
|
||||
}
|
||||
|
||||
protected abstract void a(ConnectionResult connectionResult);
|
||||
|
||||
@Override // com.google.android.gms.common.internal.BaseGmsClient.zzc
|
||||
protected final /* synthetic */ void a(Boolean bool) {
|
||||
if (bool == null) {
|
||||
BaseGmsClient.this.b(1, null);
|
||||
return;
|
||||
}
|
||||
int i = this.d;
|
||||
if (i == 0) {
|
||||
if (e()) {
|
||||
return;
|
||||
}
|
||||
BaseGmsClient.this.b(1, null);
|
||||
a(new ConnectionResult(8, null));
|
||||
return;
|
||||
}
|
||||
if (i == 10) {
|
||||
BaseGmsClient.this.b(1, null);
|
||||
throw new IllegalStateException(String.format("A fatal developer error has occurred. Class name: %s. Start service action: %s. Service Descriptor: %s. ", getClass().getSimpleName(), BaseGmsClient.this.u(), BaseGmsClient.this.t()));
|
||||
}
|
||||
BaseGmsClient.this.b(1, null);
|
||||
Bundle bundle = this.e;
|
||||
a(new ConnectionResult(this.d, bundle != null ? (PendingIntent) bundle.getParcelable("pendingIntent") : null));
|
||||
}
|
||||
|
||||
@Override // com.google.android.gms.common.internal.BaseGmsClient.zzc
|
||||
protected final void c() {
|
||||
}
|
||||
|
||||
protected abstract boolean e();
|
||||
}
|
||||
|
||||
final class zzb extends com.google.android.gms.internal.common.zze {
|
||||
public zzb(Looper looper) {
|
||||
super(looper);
|
||||
}
|
||||
|
||||
private static void a(Message message) {
|
||||
zzc zzcVar = (zzc) message.obj;
|
||||
zzcVar.c();
|
||||
zzcVar.b();
|
||||
}
|
||||
|
||||
private static boolean b(Message message) {
|
||||
int i = message.what;
|
||||
return i == 2 || i == 1 || i == 7;
|
||||
}
|
||||
|
||||
@Override // android.os.Handler
|
||||
public final void handleMessage(Message message) {
|
||||
if (BaseGmsClient.this.u.get() != message.arg1) {
|
||||
if (b(message)) {
|
||||
a(message);
|
||||
return;
|
||||
}
|
||||
return;
|
||||
}
|
||||
int i = message.what;
|
||||
if ((i == 1 || i == 7 || i == 4 || i == 5) && !BaseGmsClient.this.d()) {
|
||||
a(message);
|
||||
return;
|
||||
}
|
||||
int i2 = message.what;
|
||||
if (i2 == 4) {
|
||||
BaseGmsClient.this.r = new ConnectionResult(message.arg2);
|
||||
if (BaseGmsClient.this.z() && !BaseGmsClient.this.s) {
|
||||
BaseGmsClient.this.b(3, null);
|
||||
return;
|
||||
}
|
||||
ConnectionResult connectionResult = BaseGmsClient.this.r != null ? BaseGmsClient.this.r : new ConnectionResult(8);
|
||||
BaseGmsClient.this.i.a(connectionResult);
|
||||
BaseGmsClient.this.a(connectionResult);
|
||||
return;
|
||||
}
|
||||
if (i2 == 5) {
|
||||
ConnectionResult connectionResult2 = BaseGmsClient.this.r != null ? BaseGmsClient.this.r : new ConnectionResult(8);
|
||||
BaseGmsClient.this.i.a(connectionResult2);
|
||||
BaseGmsClient.this.a(connectionResult2);
|
||||
return;
|
||||
}
|
||||
if (i2 == 3) {
|
||||
Object obj = message.obj;
|
||||
ConnectionResult connectionResult3 = new ConnectionResult(message.arg2, obj instanceof PendingIntent ? (PendingIntent) obj : null);
|
||||
BaseGmsClient.this.i.a(connectionResult3);
|
||||
BaseGmsClient.this.a(connectionResult3);
|
||||
return;
|
||||
}
|
||||
if (i2 == 6) {
|
||||
BaseGmsClient.this.b(5, null);
|
||||
if (BaseGmsClient.this.n != null) {
|
||||
BaseGmsClient.this.n.i(message.arg2);
|
||||
}
|
||||
BaseGmsClient.this.a(message.arg2);
|
||||
BaseGmsClient.this.a(5, 1, (int) null);
|
||||
return;
|
||||
}
|
||||
if (i2 == 2 && !BaseGmsClient.this.b()) {
|
||||
a(message);
|
||||
return;
|
||||
}
|
||||
if (b(message)) {
|
||||
((zzc) message.obj).d();
|
||||
return;
|
||||
}
|
||||
int i3 = message.what;
|
||||
StringBuilder sb = new StringBuilder(45);
|
||||
sb.append("Don't know how to handle message: ");
|
||||
sb.append(i3);
|
||||
Log.wtf("GmsClient", sb.toString(), new Exception());
|
||||
}
|
||||
}
|
||||
|
||||
protected abstract class zzc<TListener> {
|
||||
private TListener a;
|
||||
private boolean b = false;
|
||||
|
||||
public zzc(TListener tlistener) {
|
||||
this.a = tlistener;
|
||||
}
|
||||
|
||||
public final void a() {
|
||||
synchronized (this) {
|
||||
this.a = null;
|
||||
}
|
||||
}
|
||||
|
||||
protected abstract void a(TListener tlistener);
|
||||
|
||||
public final void b() {
|
||||
a();
|
||||
synchronized (BaseGmsClient.this.k) {
|
||||
BaseGmsClient.this.k.remove(this);
|
||||
}
|
||||
}
|
||||
|
||||
protected abstract void c();
|
||||
|
||||
public final void d() {
|
||||
TListener tlistener;
|
||||
synchronized (this) {
|
||||
tlistener = this.a;
|
||||
if (this.b) {
|
||||
String valueOf = String.valueOf(this);
|
||||
StringBuilder sb = new StringBuilder(String.valueOf(valueOf).length() + 47);
|
||||
sb.append("Callback proxy ");
|
||||
sb.append(valueOf);
|
||||
sb.append(" being reused. This is not safe.");
|
||||
Log.w("GmsClient", sb.toString());
|
||||
}
|
||||
}
|
||||
if (tlistener != null) {
|
||||
try {
|
||||
a(tlistener);
|
||||
} catch (RuntimeException e) {
|
||||
c();
|
||||
throw e;
|
||||
}
|
||||
} else {
|
||||
c();
|
||||
}
|
||||
synchronized (this) {
|
||||
this.b = true;
|
||||
}
|
||||
b();
|
||||
}
|
||||
}
|
||||
|
||||
public final class zze implements ServiceConnection {
|
||||
private final int a;
|
||||
|
||||
public zze(int i) {
|
||||
this.a = i;
|
||||
}
|
||||
|
||||
@Override // android.content.ServiceConnection
|
||||
public final void onServiceConnected(ComponentName componentName, final IBinder iBinder) {
|
||||
IGmsServiceBroker iGmsServiceBroker;
|
||||
if (iBinder == null) {
|
||||
BaseGmsClient.this.c(16);
|
||||
return;
|
||||
}
|
||||
synchronized (BaseGmsClient.this.g) {
|
||||
BaseGmsClient baseGmsClient = BaseGmsClient.this;
|
||||
if (iBinder == null) {
|
||||
iGmsServiceBroker = null;
|
||||
} else {
|
||||
IInterface queryLocalInterface = iBinder.queryLocalInterface("com.google.android.gms.common.internal.IGmsServiceBroker");
|
||||
iGmsServiceBroker = (queryLocalInterface == null || !(queryLocalInterface instanceof IGmsServiceBroker)) ? new IGmsServiceBroker(iBinder) { // from class: com.google.android.gms.common.internal.IGmsServiceBroker$Stub$zza
|
||||
private final IBinder a;
|
||||
|
||||
{
|
||||
this.a = iBinder;
|
||||
}
|
||||
|
||||
@Override // com.google.android.gms.common.internal.IGmsServiceBroker
|
||||
public final void a(IGmsCallbacks iGmsCallbacks, GetServiceRequest getServiceRequest) throws RemoteException {
|
||||
Parcel obtain = Parcel.obtain();
|
||||
Parcel obtain2 = Parcel.obtain();
|
||||
try {
|
||||
obtain.writeInterfaceToken("com.google.android.gms.common.internal.IGmsServiceBroker");
|
||||
obtain.writeStrongBinder(iGmsCallbacks != null ? iGmsCallbacks.asBinder() : null);
|
||||
if (getServiceRequest != null) {
|
||||
obtain.writeInt(1);
|
||||
getServiceRequest.writeToParcel(obtain, 0);
|
||||
} else {
|
||||
obtain.writeInt(0);
|
||||
}
|
||||
this.a.transact(46, obtain, obtain2, 0);
|
||||
obtain2.readException();
|
||||
} finally {
|
||||
obtain2.recycle();
|
||||
obtain.recycle();
|
||||
}
|
||||
}
|
||||
|
||||
@Override // android.os.IInterface
|
||||
public final IBinder asBinder() {
|
||||
return this.a;
|
||||
}
|
||||
} : (IGmsServiceBroker) queryLocalInterface;
|
||||
}
|
||||
baseGmsClient.h = iGmsServiceBroker;
|
||||
}
|
||||
BaseGmsClient.this.a(0, (Bundle) null, this.a);
|
||||
}
|
||||
|
||||
@Override // android.content.ServiceConnection
|
||||
public final void onServiceDisconnected(ComponentName componentName) {
|
||||
synchronized (BaseGmsClient.this.g) {
|
||||
BaseGmsClient.this.h = null;
|
||||
}
|
||||
Handler handler = BaseGmsClient.this.e;
|
||||
handler.sendMessage(handler.obtainMessage(6, this.a, 1));
|
||||
}
|
||||
}
|
||||
|
||||
protected final class zzf extends zza {
|
||||
private final IBinder g;
|
||||
|
||||
public zzf(int i, IBinder iBinder, Bundle bundle) {
|
||||
super(i, bundle);
|
||||
this.g = iBinder;
|
||||
}
|
||||
|
||||
@Override // com.google.android.gms.common.internal.BaseGmsClient.zza
|
||||
protected final void a(ConnectionResult connectionResult) {
|
||||
if (BaseGmsClient.this.o != null) {
|
||||
BaseGmsClient.this.o.a(connectionResult);
|
||||
}
|
||||
BaseGmsClient.this.a(connectionResult);
|
||||
}
|
||||
|
||||
@Override // com.google.android.gms.common.internal.BaseGmsClient.zza
|
||||
protected final boolean e() {
|
||||
try {
|
||||
String interfaceDescriptor = this.g.getInterfaceDescriptor();
|
||||
if (!BaseGmsClient.this.t().equals(interfaceDescriptor)) {
|
||||
String t = BaseGmsClient.this.t();
|
||||
StringBuilder sb = new StringBuilder(String.valueOf(t).length() + 34 + String.valueOf(interfaceDescriptor).length());
|
||||
sb.append("service descriptor mismatch: ");
|
||||
sb.append(t);
|
||||
sb.append(" vs. ");
|
||||
sb.append(interfaceDescriptor);
|
||||
Log.e("GmsClient", sb.toString());
|
||||
return false;
|
||||
}
|
||||
IInterface a = BaseGmsClient.this.a(this.g);
|
||||
if (a == null || !(BaseGmsClient.this.a(2, 4, (int) a) || BaseGmsClient.this.a(3, 4, (int) a))) {
|
||||
return false;
|
||||
}
|
||||
BaseGmsClient.this.r = null;
|
||||
Bundle n = BaseGmsClient.this.n();
|
||||
if (BaseGmsClient.this.n == null) {
|
||||
return true;
|
||||
}
|
||||
BaseGmsClient.this.n.d(n);
|
||||
return true;
|
||||
} catch (RemoteException unused) {
|
||||
Log.w("GmsClient", "service probably died");
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
protected final class zzg extends zza {
|
||||
public zzg(int i, Bundle bundle) {
|
||||
super(i, null);
|
||||
}
|
||||
|
||||
@Override // com.google.android.gms.common.internal.BaseGmsClient.zza
|
||||
protected final void a(ConnectionResult connectionResult) {
|
||||
BaseGmsClient.this.i.a(connectionResult);
|
||||
BaseGmsClient.this.a(connectionResult);
|
||||
}
|
||||
|
||||
@Override // com.google.android.gms.common.internal.BaseGmsClient.zza
|
||||
protected final boolean e() {
|
||||
BaseGmsClient.this.i.a(ConnectionResult.RESULT_SUCCESS);
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
static {
|
||||
new String[]{"service_esmobile", "service_googleme"};
|
||||
}
|
||||
|
||||
/* JADX WARN: Illegal instructions before constructor call */
|
||||
/*
|
||||
Code decompiled incorrectly, please refer to instructions dump.
|
||||
To view partially-correct code enable 'Show inconsistent code' option in preferences
|
||||
*/
|
||||
protected BaseGmsClient(android.content.Context r10, android.os.Looper r11, int r12, com.google.android.gms.common.internal.BaseGmsClient.BaseConnectionCallbacks r13, com.google.android.gms.common.internal.BaseGmsClient.BaseOnConnectionFailedListener r14, java.lang.String r15) {
|
||||
/*
|
||||
r9 = this;
|
||||
com.google.android.gms.common.internal.GmsClientSupervisor r3 = com.google.android.gms.common.internal.GmsClientSupervisor.a(r10)
|
||||
com.google.android.gms.common.GoogleApiAvailabilityLight r4 = com.google.android.gms.common.GoogleApiAvailabilityLight.a()
|
||||
com.google.android.gms.common.internal.Preconditions.a(r13)
|
||||
r6 = r13
|
||||
com.google.android.gms.common.internal.BaseGmsClient$BaseConnectionCallbacks r6 = (com.google.android.gms.common.internal.BaseGmsClient.BaseConnectionCallbacks) r6
|
||||
com.google.android.gms.common.internal.Preconditions.a(r14)
|
||||
r7 = r14
|
||||
com.google.android.gms.common.internal.BaseGmsClient$BaseOnConnectionFailedListener r7 = (com.google.android.gms.common.internal.BaseGmsClient.BaseOnConnectionFailedListener) r7
|
||||
r0 = r9
|
||||
r1 = r10
|
||||
r2 = r11
|
||||
r5 = r12
|
||||
r8 = r15
|
||||
r0.<init>(r1, r2, r3, r4, r5, r6, r7, r8)
|
||||
return
|
||||
*/
|
||||
throw new UnsupportedOperationException("Method not decompiled: com.google.android.gms.common.internal.BaseGmsClient.<init>(android.content.Context, android.os.Looper, int, com.google.android.gms.common.internal.BaseGmsClient$BaseConnectionCallbacks, com.google.android.gms.common.internal.BaseGmsClient$BaseOnConnectionFailedListener, java.lang.String):void");
|
||||
}
|
||||
|
||||
/* JADX INFO: Access modifiers changed from: private */
|
||||
public final void a(com.google.android.gms.common.internal.zzb zzbVar) {
|
||||
this.t = zzbVar;
|
||||
}
|
||||
|
||||
/* JADX INFO: Access modifiers changed from: private */
|
||||
public final void b(int i, T t) {
|
||||
Preconditions.a((i == 4) == (t != null));
|
||||
synchronized (this.f) {
|
||||
this.m = i;
|
||||
this.j = t;
|
||||
a(i, (int) t);
|
||||
if (i != 1) {
|
||||
if (i == 2 || i == 3) {
|
||||
if (this.l != null && this.a != null) {
|
||||
String c = this.a.c();
|
||||
String a = this.a.a();
|
||||
StringBuilder sb = new StringBuilder(String.valueOf(c).length() + 70 + String.valueOf(a).length());
|
||||
sb.append("Calling connect() while still connected, missing disconnect() for ");
|
||||
sb.append(c);
|
||||
sb.append(" on ");
|
||||
sb.append(a);
|
||||
Log.e("GmsClient", sb.toString());
|
||||
this.c.a(this.a.c(), this.a.a(), this.a.b(), this.l, x());
|
||||
this.u.incrementAndGet();
|
||||
}
|
||||
this.l = new zze(this.u.get());
|
||||
this.a = (this.m != 3 || q() == null) ? new zzh(v(), u(), false, 129) : new zzh(o().getPackageName(), q(), true, 129);
|
||||
if (!this.c.a(new GmsClientSupervisor.zza(this.a.c(), this.a.a(), this.a.b()), this.l, x())) {
|
||||
String c2 = this.a.c();
|
||||
String a2 = this.a.a();
|
||||
StringBuilder sb2 = new StringBuilder(String.valueOf(c2).length() + 34 + String.valueOf(a2).length());
|
||||
sb2.append("unable to connect to service: ");
|
||||
sb2.append(c2);
|
||||
sb2.append(" on ");
|
||||
sb2.append(a2);
|
||||
Log.e("GmsClient", sb2.toString());
|
||||
a(16, (Bundle) null, this.u.get());
|
||||
}
|
||||
} else if (i == 4) {
|
||||
a((BaseGmsClient<T>) t);
|
||||
}
|
||||
} else if (this.l != null) {
|
||||
this.c.a(u(), v(), 129, this.l, x());
|
||||
this.l = null;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* JADX INFO: Access modifiers changed from: private */
|
||||
public final void c(int i) {
|
||||
int i2;
|
||||
if (y()) {
|
||||
i2 = 5;
|
||||
this.s = true;
|
||||
} else {
|
||||
i2 = 4;
|
||||
}
|
||||
Handler handler = this.e;
|
||||
handler.sendMessage(handler.obtainMessage(i2, this.u.get(), 16));
|
||||
}
|
||||
|
||||
private final String x() {
|
||||
String str = this.q;
|
||||
return str == null ? this.b.getClass().getName() : str;
|
||||
}
|
||||
|
||||
private final boolean y() {
|
||||
boolean z;
|
||||
synchronized (this.f) {
|
||||
z = this.m == 3;
|
||||
}
|
||||
return z;
|
||||
}
|
||||
|
||||
/* JADX INFO: Access modifiers changed from: private */
|
||||
public final boolean z() {
|
||||
if (this.s || TextUtils.isEmpty(t()) || TextUtils.isEmpty(q())) {
|
||||
return false;
|
||||
}
|
||||
try {
|
||||
Class.forName(t());
|
||||
return true;
|
||||
} catch (ClassNotFoundException unused) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
protected abstract T a(IBinder iBinder);
|
||||
|
||||
void a(int i, T t) {
|
||||
}
|
||||
|
||||
public boolean d() {
|
||||
boolean z;
|
||||
synchronized (this.f) {
|
||||
z = this.m == 2 || this.m == 3;
|
||||
}
|
||||
return z;
|
||||
}
|
||||
|
||||
public String e() {
|
||||
zzh zzhVar;
|
||||
if (!b() || (zzhVar = this.a) == null) {
|
||||
throw new RuntimeException("Failed to connect when checking package");
|
||||
}
|
||||
return zzhVar.a();
|
||||
}
|
||||
|
||||
public boolean f() {
|
||||
return true;
|
||||
}
|
||||
|
||||
public int g() {
|
||||
return GoogleApiAvailabilityLight.a;
|
||||
}
|
||||
|
||||
public final Feature[] h() {
|
||||
com.google.android.gms.common.internal.zzb zzbVar = this.t;
|
||||
if (zzbVar == null) {
|
||||
return null;
|
||||
}
|
||||
return zzbVar.zzda;
|
||||
}
|
||||
|
||||
public boolean i() {
|
||||
return false;
|
||||
}
|
||||
|
||||
public void j() {
|
||||
int a = this.d.a(this.b, g());
|
||||
if (a == 0) {
|
||||
a(new LegacyClientCallbackAdapter());
|
||||
} else {
|
||||
b(1, null);
|
||||
a(new LegacyClientCallbackAdapter(), a, (PendingIntent) null);
|
||||
}
|
||||
}
|
||||
|
||||
protected final void k() {
|
||||
if (!b()) {
|
||||
throw new IllegalStateException("Not connected. Call connect() and wait for onConnected() to be called.");
|
||||
}
|
||||
}
|
||||
|
||||
public Account l() {
|
||||
return null;
|
||||
}
|
||||
|
||||
public Feature[] m() {
|
||||
return v;
|
||||
}
|
||||
|
||||
public Bundle n() {
|
||||
return null;
|
||||
}
|
||||
|
||||
public final Context o() {
|
||||
return this.b;
|
||||
}
|
||||
|
||||
protected Bundle p() {
|
||||
return new Bundle();
|
||||
}
|
||||
|
||||
protected String q() {
|
||||
return null;
|
||||
}
|
||||
|
||||
protected Set<Scope> r() {
|
||||
return Collections.EMPTY_SET;
|
||||
}
|
||||
|
||||
public final T s() throws DeadObjectException {
|
||||
T t;
|
||||
synchronized (this.f) {
|
||||
if (this.m == 5) {
|
||||
throw new DeadObjectException();
|
||||
}
|
||||
k();
|
||||
Preconditions.b(this.j != null, "Client is connected but service is null");
|
||||
t = this.j;
|
||||
}
|
||||
return t;
|
||||
}
|
||||
|
||||
protected abstract String t();
|
||||
|
||||
protected abstract String u();
|
||||
|
||||
protected String v() {
|
||||
return "com.google.android.gms";
|
||||
}
|
||||
|
||||
public boolean w() {
|
||||
return false;
|
||||
}
|
||||
|
||||
protected void a(T t) {
|
||||
System.currentTimeMillis();
|
||||
}
|
||||
|
||||
public static final class zzd extends IGmsCallbacks.zza {
|
||||
private BaseGmsClient a;
|
||||
private final int b;
|
||||
|
||||
public zzd(BaseGmsClient baseGmsClient, int i) {
|
||||
this.a = baseGmsClient;
|
||||
this.b = i;
|
||||
}
|
||||
|
||||
@Override // com.google.android.gms.common.internal.IGmsCallbacks
|
||||
public final void a(int i, IBinder iBinder, Bundle bundle) {
|
||||
Preconditions.a(this.a, "onPostInitComplete can be called only once per call to getRemoteService");
|
||||
this.a.a(i, iBinder, bundle, this.b);
|
||||
this.a = null;
|
||||
}
|
||||
|
||||
@Override // com.google.android.gms.common.internal.IGmsCallbacks
|
||||
public final void b(int i, Bundle bundle) {
|
||||
Log.wtf("GmsClient", "received deprecated onAccountValidationComplete callback, ignoring", new Exception());
|
||||
}
|
||||
|
||||
@Override // com.google.android.gms.common.internal.IGmsCallbacks
|
||||
public final void a(int i, IBinder iBinder, com.google.android.gms.common.internal.zzb zzbVar) {
|
||||
Preconditions.a(this.a, "onPostInitCompleteWithConnectionInfo can be called only once per call togetRemoteService");
|
||||
Preconditions.a(zzbVar);
|
||||
this.a.a(zzbVar);
|
||||
a(i, iBinder, zzbVar.zzcz);
|
||||
}
|
||||
}
|
||||
|
||||
protected void a(int i) {
|
||||
System.currentTimeMillis();
|
||||
}
|
||||
|
||||
protected void a(ConnectionResult connectionResult) {
|
||||
connectionResult.getErrorCode();
|
||||
System.currentTimeMillis();
|
||||
}
|
||||
|
||||
protected BaseGmsClient(Context context, Looper looper, GmsClientSupervisor gmsClientSupervisor, GoogleApiAvailabilityLight googleApiAvailabilityLight, int i, BaseConnectionCallbacks baseConnectionCallbacks, BaseOnConnectionFailedListener baseOnConnectionFailedListener, String str) {
|
||||
this.f = new Object();
|
||||
this.g = new Object();
|
||||
this.k = new ArrayList<>();
|
||||
this.m = 1;
|
||||
this.r = null;
|
||||
this.s = false;
|
||||
this.t = null;
|
||||
this.u = new AtomicInteger(0);
|
||||
Preconditions.a(context, "Context must not be null");
|
||||
this.b = context;
|
||||
Preconditions.a(looper, "Looper must not be null");
|
||||
Preconditions.a(gmsClientSupervisor, "Supervisor must not be null");
|
||||
this.c = gmsClientSupervisor;
|
||||
Preconditions.a(googleApiAvailabilityLight, "API availability must not be null");
|
||||
this.d = googleApiAvailabilityLight;
|
||||
this.e = new zzb(looper);
|
||||
this.p = i;
|
||||
this.n = baseConnectionCallbacks;
|
||||
this.o = baseOnConnectionFailedListener;
|
||||
this.q = str;
|
||||
}
|
||||
|
||||
/* JADX INFO: Access modifiers changed from: private */
|
||||
public final boolean a(int i, int i2, T t) {
|
||||
synchronized (this.f) {
|
||||
if (this.m != i) {
|
||||
return false;
|
||||
}
|
||||
b(i2, t);
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
public void a(ConnectionProgressReportCallbacks connectionProgressReportCallbacks) {
|
||||
Preconditions.a(connectionProgressReportCallbacks, "Connection progress callbacks cannot be null.");
|
||||
this.i = connectionProgressReportCallbacks;
|
||||
b(2, null);
|
||||
}
|
||||
|
||||
public void a() {
|
||||
this.u.incrementAndGet();
|
||||
synchronized (this.k) {
|
||||
int size = this.k.size();
|
||||
for (int i = 0; i < size; i++) {
|
||||
this.k.get(i).a();
|
||||
}
|
||||
this.k.clear();
|
||||
}
|
||||
synchronized (this.g) {
|
||||
this.h = null;
|
||||
}
|
||||
b(1, null);
|
||||
}
|
||||
|
||||
protected void a(ConnectionProgressReportCallbacks connectionProgressReportCallbacks, int i, PendingIntent pendingIntent) {
|
||||
Preconditions.a(connectionProgressReportCallbacks, "Connection progress callbacks cannot be null.");
|
||||
this.i = connectionProgressReportCallbacks;
|
||||
Handler handler = this.e;
|
||||
handler.sendMessage(handler.obtainMessage(3, this.u.get(), i, pendingIntent));
|
||||
}
|
||||
|
||||
protected void a(int i, IBinder iBinder, Bundle bundle, int i2) {
|
||||
Handler handler = this.e;
|
||||
handler.sendMessage(handler.obtainMessage(1, i2, -1, new zzf(i, iBinder, bundle)));
|
||||
}
|
||||
|
||||
protected final void a(int i, Bundle bundle, int i2) {
|
||||
Handler handler = this.e;
|
||||
handler.sendMessage(handler.obtainMessage(7, i2, -1, new zzg(i, null)));
|
||||
}
|
||||
|
||||
public void a(IAccountAccessor iAccountAccessor, Set<Scope> set) {
|
||||
Bundle p = p();
|
||||
GetServiceRequest getServiceRequest = new GetServiceRequest(this.p);
|
||||
getServiceRequest.zzdh = this.b.getPackageName();
|
||||
getServiceRequest.zzdk = p;
|
||||
if (set != null) {
|
||||
getServiceRequest.zzdj = (Scope[]) set.toArray(new Scope[set.size()]);
|
||||
}
|
||||
if (i()) {
|
||||
getServiceRequest.zzdl = l() != null ? l() : new Account("<<default account>>", "com.google");
|
||||
if (iAccountAccessor != null) {
|
||||
getServiceRequest.zzdi = iAccountAccessor.asBinder();
|
||||
}
|
||||
} else if (w()) {
|
||||
getServiceRequest.zzdl = l();
|
||||
}
|
||||
getServiceRequest.zzdm = v;
|
||||
getServiceRequest.zzdn = m();
|
||||
try {
|
||||
synchronized (this.g) {
|
||||
if (this.h != null) {
|
||||
this.h.a(new zzd(this, this.u.get()), getServiceRequest);
|
||||
} else {
|
||||
Log.w("GmsClient", "mServiceBroker is null, client disconnected");
|
||||
}
|
||||
}
|
||||
} catch (DeadObjectException e) {
|
||||
Log.w("GmsClient", "IGmsServiceBroker.getService failed", e);
|
||||
b(1);
|
||||
} catch (RemoteException e2) {
|
||||
e = e2;
|
||||
Log.w("GmsClient", "IGmsServiceBroker.getService failed", e);
|
||||
a(8, (IBinder) null, (Bundle) null, this.u.get());
|
||||
} catch (SecurityException e3) {
|
||||
throw e3;
|
||||
} catch (RuntimeException e4) {
|
||||
e = e4;
|
||||
Log.w("GmsClient", "IGmsServiceBroker.getService failed", e);
|
||||
a(8, (IBinder) null, (Bundle) null, this.u.get());
|
||||
}
|
||||
}
|
||||
|
||||
public boolean b() {
|
||||
boolean z;
|
||||
synchronized (this.f) {
|
||||
z = this.m == 4;
|
||||
}
|
||||
return z;
|
||||
}
|
||||
|
||||
public void b(int i) {
|
||||
Handler handler = this.e;
|
||||
handler.sendMessage(handler.obtainMessage(6, this.u.get(), i));
|
||||
}
|
||||
|
||||
public void a(SignOutCallbacks signOutCallbacks) {
|
||||
signOutCallbacks.a();
|
||||
}
|
||||
}
|
@@ -0,0 +1,41 @@
|
||||
package com.google.android.gms.common.internal;
|
||||
|
||||
import android.os.IBinder;
|
||||
import android.os.Parcel;
|
||||
import android.os.Parcelable;
|
||||
import com.google.android.gms.common.annotation.KeepName;
|
||||
|
||||
@KeepName
|
||||
/* loaded from: classes.dex */
|
||||
public final class BinderWrapper implements Parcelable {
|
||||
public static final Parcelable.Creator<BinderWrapper> CREATOR = new zza();
|
||||
private IBinder zzcy;
|
||||
|
||||
public BinderWrapper() {
|
||||
this.zzcy = null;
|
||||
}
|
||||
|
||||
@Override // android.os.Parcelable
|
||||
public final int describeContents() {
|
||||
return 0;
|
||||
}
|
||||
|
||||
@Override // android.os.Parcelable
|
||||
public final void writeToParcel(Parcel parcel, int i) {
|
||||
parcel.writeStrongBinder(this.zzcy);
|
||||
}
|
||||
|
||||
public BinderWrapper(IBinder iBinder) {
|
||||
this.zzcy = null;
|
||||
this.zzcy = iBinder;
|
||||
}
|
||||
|
||||
private BinderWrapper(Parcel parcel) {
|
||||
this.zzcy = null;
|
||||
this.zzcy = parcel.readStrongBinder();
|
||||
}
|
||||
|
||||
/* synthetic */ BinderWrapper(Parcel parcel, zza zzaVar) {
|
||||
this(parcel);
|
||||
}
|
||||
}
|
@@ -0,0 +1,53 @@
|
||||
package com.google.android.gms.common.internal;
|
||||
|
||||
import android.os.Parcel;
|
||||
import android.os.Parcelable;
|
||||
import com.google.android.gms.common.internal.safeparcel.AbstractSafeParcelable;
|
||||
import com.google.android.gms.common.internal.safeparcel.SafeParcelWriter;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public class ClientIdentity extends AbstractSafeParcelable {
|
||||
public static final Parcelable.Creator<ClientIdentity> CREATOR = new zab();
|
||||
private final String packageName;
|
||||
private final int uid;
|
||||
|
||||
public ClientIdentity(int i, String str) {
|
||||
this.uid = i;
|
||||
this.packageName = str;
|
||||
}
|
||||
|
||||
public boolean equals(Object obj) {
|
||||
if (obj == this) {
|
||||
return true;
|
||||
}
|
||||
if (obj != null && (obj instanceof ClientIdentity)) {
|
||||
ClientIdentity clientIdentity = (ClientIdentity) obj;
|
||||
if (clientIdentity.uid == this.uid && Objects.a(clientIdentity.packageName, this.packageName)) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
public int hashCode() {
|
||||
return this.uid;
|
||||
}
|
||||
|
||||
public String toString() {
|
||||
int i = this.uid;
|
||||
String str = this.packageName;
|
||||
StringBuilder sb = new StringBuilder(String.valueOf(str).length() + 12);
|
||||
sb.append(i);
|
||||
sb.append(":");
|
||||
sb.append(str);
|
||||
return sb.toString();
|
||||
}
|
||||
|
||||
@Override // android.os.Parcelable
|
||||
public void writeToParcel(Parcel parcel, int i) {
|
||||
int a = SafeParcelWriter.a(parcel);
|
||||
SafeParcelWriter.a(parcel, 1, this.uid);
|
||||
SafeParcelWriter.a(parcel, 2, this.packageName, false);
|
||||
SafeParcelWriter.a(parcel, a);
|
||||
}
|
||||
}
|
@@ -0,0 +1,120 @@
|
||||
package com.google.android.gms.common.internal;
|
||||
|
||||
import android.accounts.Account;
|
||||
import android.view.View;
|
||||
import androidx.collection.ArraySet;
|
||||
import com.google.android.gms.common.api.Api;
|
||||
import com.google.android.gms.common.api.Scope;
|
||||
import com.google.android.gms.signin.SignInOptions;
|
||||
import java.util.Collection;
|
||||
import java.util.Collections;
|
||||
import java.util.HashSet;
|
||||
import java.util.Iterator;
|
||||
import java.util.Map;
|
||||
import java.util.Set;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public final class ClientSettings {
|
||||
private final Account a;
|
||||
private final Set<Scope> b;
|
||||
private final Set<Scope> c;
|
||||
private final Map<Api<?>, OptionalApiSettings> d;
|
||||
private final String e;
|
||||
private final String f;
|
||||
private final SignInOptions g;
|
||||
private Integer h;
|
||||
|
||||
public static final class Builder {
|
||||
private Account a;
|
||||
private ArraySet<Scope> b;
|
||||
private Map<Api<?>, OptionalApiSettings> c;
|
||||
private View e;
|
||||
private String f;
|
||||
private String g;
|
||||
private int d = 0;
|
||||
private SignInOptions h = SignInOptions.i;
|
||||
|
||||
public final Builder a(Account account) {
|
||||
this.a = account;
|
||||
return this;
|
||||
}
|
||||
|
||||
public final Builder b(String str) {
|
||||
this.f = str;
|
||||
return this;
|
||||
}
|
||||
|
||||
public final Builder a(Collection<Scope> collection) {
|
||||
if (this.b == null) {
|
||||
this.b = new ArraySet<>();
|
||||
}
|
||||
this.b.addAll(collection);
|
||||
return this;
|
||||
}
|
||||
|
||||
public final Builder a(String str) {
|
||||
this.g = str;
|
||||
return this;
|
||||
}
|
||||
|
||||
public final ClientSettings a() {
|
||||
return new ClientSettings(this.a, this.b, this.c, this.d, this.e, this.f, this.g, this.h);
|
||||
}
|
||||
}
|
||||
|
||||
public static final class OptionalApiSettings {
|
||||
public final Set<Scope> a;
|
||||
}
|
||||
|
||||
public ClientSettings(Account account, Set<Scope> set, Map<Api<?>, OptionalApiSettings> map, int i, View view, String str, String str2, SignInOptions signInOptions) {
|
||||
this.a = account;
|
||||
this.b = set == null ? Collections.EMPTY_SET : Collections.unmodifiableSet(set);
|
||||
this.d = map == null ? Collections.EMPTY_MAP : map;
|
||||
this.e = str;
|
||||
this.f = str2;
|
||||
this.g = signInOptions;
|
||||
HashSet hashSet = new HashSet(this.b);
|
||||
Iterator<OptionalApiSettings> it = this.d.values().iterator();
|
||||
while (it.hasNext()) {
|
||||
hashSet.addAll(it.next().a);
|
||||
}
|
||||
this.c = Collections.unmodifiableSet(hashSet);
|
||||
}
|
||||
|
||||
public final Account a() {
|
||||
return this.a;
|
||||
}
|
||||
|
||||
public final Account b() {
|
||||
Account account = this.a;
|
||||
return account != null ? account : new Account("<<default account>>", "com.google");
|
||||
}
|
||||
|
||||
public final Set<Scope> c() {
|
||||
return this.c;
|
||||
}
|
||||
|
||||
public final Integer d() {
|
||||
return this.h;
|
||||
}
|
||||
|
||||
public final String e() {
|
||||
return this.f;
|
||||
}
|
||||
|
||||
public final String f() {
|
||||
return this.e;
|
||||
}
|
||||
|
||||
public final Set<Scope> g() {
|
||||
return this.b;
|
||||
}
|
||||
|
||||
public final SignInOptions h() {
|
||||
return this.g;
|
||||
}
|
||||
|
||||
public final void a(Integer num) {
|
||||
this.h = num;
|
||||
}
|
||||
}
|
@@ -0,0 +1,172 @@
|
||||
package com.google.android.gms.common.internal;
|
||||
|
||||
import android.R;
|
||||
import android.content.Context;
|
||||
import android.content.pm.PackageManager;
|
||||
import android.content.res.Resources;
|
||||
import android.text.TextUtils;
|
||||
import android.util.Log;
|
||||
import androidx.collection.SimpleArrayMap;
|
||||
import com.google.android.gms.base.R$string;
|
||||
import com.google.android.gms.common.GooglePlayServicesUtil;
|
||||
import com.google.android.gms.common.util.DeviceProperties;
|
||||
import com.google.android.gms.common.wrappers.Wrappers;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public final class ConnectionErrorMessages {
|
||||
private static final SimpleArrayMap<String, String> a = new SimpleArrayMap<>();
|
||||
|
||||
public static String a(Context context, int i) {
|
||||
Resources resources = context.getResources();
|
||||
return i != 1 ? i != 2 ? i != 3 ? resources.getString(R.string.ok) : resources.getString(R$string.common_google_play_services_enable_button) : resources.getString(R$string.common_google_play_services_update_button) : resources.getString(R$string.common_google_play_services_install_button);
|
||||
}
|
||||
|
||||
public static String b(Context context, int i) {
|
||||
Resources resources = context.getResources();
|
||||
String a2 = a(context);
|
||||
if (i == 1) {
|
||||
return resources.getString(R$string.common_google_play_services_install_text, a2);
|
||||
}
|
||||
if (i == 2) {
|
||||
return DeviceProperties.c(context) ? resources.getString(R$string.common_google_play_services_wear_update_text) : resources.getString(R$string.common_google_play_services_update_text, a2);
|
||||
}
|
||||
if (i == 3) {
|
||||
return resources.getString(R$string.common_google_play_services_enable_text, a2);
|
||||
}
|
||||
if (i == 5) {
|
||||
return a(context, "common_google_play_services_invalid_account_text", a2);
|
||||
}
|
||||
if (i == 7) {
|
||||
return a(context, "common_google_play_services_network_error_text", a2);
|
||||
}
|
||||
if (i == 9) {
|
||||
return resources.getString(R$string.common_google_play_services_unsupported_text, a2);
|
||||
}
|
||||
if (i == 20) {
|
||||
return a(context, "common_google_play_services_restricted_profile_text", a2);
|
||||
}
|
||||
switch (i) {
|
||||
case 16:
|
||||
return a(context, "common_google_play_services_api_unavailable_text", a2);
|
||||
case 17:
|
||||
return a(context, "common_google_play_services_sign_in_failed_text", a2);
|
||||
case 18:
|
||||
return resources.getString(R$string.common_google_play_services_updating_text, a2);
|
||||
default:
|
||||
return resources.getString(com.google.android.gms.common.R$string.common_google_play_services_unknown_issue, a2);
|
||||
}
|
||||
}
|
||||
|
||||
public static String c(Context context, int i) {
|
||||
return i == 6 ? a(context, "common_google_play_services_resolution_required_text", a(context)) : b(context, i);
|
||||
}
|
||||
|
||||
public static String d(Context context, int i) {
|
||||
String a2 = i == 6 ? a(context, "common_google_play_services_resolution_required_title") : e(context, i);
|
||||
return a2 == null ? context.getResources().getString(R$string.common_google_play_services_notification_ticker) : a2;
|
||||
}
|
||||
|
||||
public static String e(Context context, int i) {
|
||||
Resources resources = context.getResources();
|
||||
switch (i) {
|
||||
case 1:
|
||||
return resources.getString(R$string.common_google_play_services_install_title);
|
||||
case 2:
|
||||
return resources.getString(R$string.common_google_play_services_update_title);
|
||||
case 3:
|
||||
return resources.getString(R$string.common_google_play_services_enable_title);
|
||||
case 4:
|
||||
case 6:
|
||||
case 18:
|
||||
return null;
|
||||
case 5:
|
||||
Log.e("GoogleApiAvailability", "An invalid account was specified when connecting. Please provide a valid account.");
|
||||
return a(context, "common_google_play_services_invalid_account_title");
|
||||
case 7:
|
||||
Log.e("GoogleApiAvailability", "Network error occurred. Please retry request later.");
|
||||
return a(context, "common_google_play_services_network_error_title");
|
||||
case 8:
|
||||
Log.e("GoogleApiAvailability", "Internal error occurred. Please see logs for detailed information");
|
||||
return null;
|
||||
case 9:
|
||||
Log.e("GoogleApiAvailability", "Google Play services is invalid. Cannot recover.");
|
||||
return null;
|
||||
case 10:
|
||||
Log.e("GoogleApiAvailability", "Developer error occurred. Please see logs for detailed information");
|
||||
return null;
|
||||
case 11:
|
||||
Log.e("GoogleApiAvailability", "The application is not licensed to the user.");
|
||||
return null;
|
||||
case 12:
|
||||
case 13:
|
||||
case 14:
|
||||
case 15:
|
||||
case 19:
|
||||
default:
|
||||
StringBuilder sb = new StringBuilder(33);
|
||||
sb.append("Unexpected error code ");
|
||||
sb.append(i);
|
||||
Log.e("GoogleApiAvailability", sb.toString());
|
||||
return null;
|
||||
case 16:
|
||||
Log.e("GoogleApiAvailability", "One of the API components you attempted to connect to is not available.");
|
||||
return null;
|
||||
case 17:
|
||||
Log.e("GoogleApiAvailability", "The specified account could not be signed in.");
|
||||
return a(context, "common_google_play_services_sign_in_failed_title");
|
||||
case 20:
|
||||
Log.e("GoogleApiAvailability", "The current user profile is restricted and could not use authenticated features.");
|
||||
return a(context, "common_google_play_services_restricted_profile_title");
|
||||
}
|
||||
}
|
||||
|
||||
public static String a(Context context) {
|
||||
String packageName = context.getPackageName();
|
||||
try {
|
||||
return Wrappers.a(context).b(packageName).toString();
|
||||
} catch (PackageManager.NameNotFoundException | NullPointerException unused) {
|
||||
String str = context.getApplicationInfo().name;
|
||||
return TextUtils.isEmpty(str) ? packageName : str;
|
||||
}
|
||||
}
|
||||
|
||||
private static String a(Context context, String str, String str2) {
|
||||
Resources resources = context.getResources();
|
||||
String a2 = a(context, str);
|
||||
if (a2 == null) {
|
||||
a2 = resources.getString(com.google.android.gms.common.R$string.common_google_play_services_unknown_issue);
|
||||
}
|
||||
return String.format(resources.getConfiguration().locale, a2, str2);
|
||||
}
|
||||
|
||||
private static String a(Context context, String str) {
|
||||
synchronized (a) {
|
||||
String str2 = a.get(str);
|
||||
if (str2 != null) {
|
||||
return str2;
|
||||
}
|
||||
Resources remoteResource = GooglePlayServicesUtil.getRemoteResource(context);
|
||||
if (remoteResource == null) {
|
||||
return null;
|
||||
}
|
||||
int identifier = remoteResource.getIdentifier(str, "string", "com.google.android.gms");
|
||||
if (identifier == 0) {
|
||||
String valueOf = String.valueOf(str);
|
||||
Log.w("GoogleApiAvailability", valueOf.length() != 0 ? "Missing resource: ".concat(valueOf) : new String("Missing resource: "));
|
||||
return null;
|
||||
}
|
||||
String string = remoteResource.getString(identifier);
|
||||
if (TextUtils.isEmpty(string)) {
|
||||
String valueOf2 = String.valueOf(str);
|
||||
Log.w("GoogleApiAvailability", valueOf2.length() != 0 ? "Got empty resource: ".concat(valueOf2) : new String("Got empty resource: "));
|
||||
return null;
|
||||
}
|
||||
a.put(str, string);
|
||||
return string;
|
||||
}
|
||||
}
|
||||
|
||||
public static String b(Context context) {
|
||||
return context.getResources().getString(R$string.common_google_play_services_notification_channel_name);
|
||||
}
|
||||
}
|
@@ -0,0 +1,32 @@
|
||||
package com.google.android.gms.common.internal;
|
||||
|
||||
import android.app.Activity;
|
||||
import android.content.ActivityNotFoundException;
|
||||
import android.content.DialogInterface;
|
||||
import android.content.Intent;
|
||||
import android.util.Log;
|
||||
import androidx.fragment.app.Fragment;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public abstract class DialogRedirect implements DialogInterface.OnClickListener {
|
||||
public static DialogRedirect a(Activity activity, Intent intent, int i) {
|
||||
return new zac(intent, activity, i);
|
||||
}
|
||||
|
||||
protected abstract void a();
|
||||
|
||||
@Override // android.content.DialogInterface.OnClickListener
|
||||
public void onClick(DialogInterface dialogInterface, int i) {
|
||||
try {
|
||||
a();
|
||||
} catch (ActivityNotFoundException e) {
|
||||
Log.e("DialogRedirect", "Failed to start resolution intent", e);
|
||||
} finally {
|
||||
dialogInterface.dismiss();
|
||||
}
|
||||
}
|
||||
|
||||
public static DialogRedirect a(Fragment fragment, Intent intent, int i) {
|
||||
return new zad(intent, fragment, i);
|
||||
}
|
||||
}
|
@@ -0,0 +1,38 @@
|
||||
package com.google.android.gms.common.internal;
|
||||
|
||||
import com.google.android.gms.common.internal.safeparcel.AbstractSafeParcelable;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public abstract class DowngradeableSafeParcel extends AbstractSafeParcelable implements ReflectedParcelable {
|
||||
private static final Object zzdb = new Object();
|
||||
private static ClassLoader zzdc;
|
||||
private static Integer zzdd;
|
||||
private boolean zzde = false;
|
||||
|
||||
protected static boolean canUnparcelSafely(String str) {
|
||||
zzp();
|
||||
return true;
|
||||
}
|
||||
|
||||
protected static Integer getUnparcelClientVersion() {
|
||||
synchronized (zzdb) {
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
private static ClassLoader zzp() {
|
||||
synchronized (zzdb) {
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
protected abstract boolean prepareForClientVersion(int i);
|
||||
|
||||
public void setShouldDowngrade(boolean z) {
|
||||
this.zzde = z;
|
||||
}
|
||||
|
||||
protected boolean shouldDowngrade() {
|
||||
return this.zzde;
|
||||
}
|
||||
}
|
@@ -0,0 +1,79 @@
|
||||
package com.google.android.gms.common.internal;
|
||||
|
||||
import android.accounts.Account;
|
||||
import android.os.Bundle;
|
||||
import android.os.IBinder;
|
||||
import android.os.Parcel;
|
||||
import android.os.Parcelable;
|
||||
import com.google.android.gms.common.Feature;
|
||||
import com.google.android.gms.common.GoogleApiAvailabilityLight;
|
||||
import com.google.android.gms.common.api.Scope;
|
||||
import com.google.android.gms.common.internal.IAccountAccessor;
|
||||
import com.google.android.gms.common.internal.safeparcel.AbstractSafeParcelable;
|
||||
import com.google.android.gms.common.internal.safeparcel.SafeParcelWriter;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public class GetServiceRequest extends AbstractSafeParcelable {
|
||||
public static final Parcelable.Creator<GetServiceRequest> CREATOR = new zzd();
|
||||
private final int version;
|
||||
private final int zzdf;
|
||||
private int zzdg;
|
||||
String zzdh;
|
||||
IBinder zzdi;
|
||||
Scope[] zzdj;
|
||||
Bundle zzdk;
|
||||
Account zzdl;
|
||||
Feature[] zzdm;
|
||||
Feature[] zzdn;
|
||||
private boolean zzdo;
|
||||
|
||||
public GetServiceRequest(int i) {
|
||||
this.version = 4;
|
||||
this.zzdg = GoogleApiAvailabilityLight.a;
|
||||
this.zzdf = i;
|
||||
this.zzdo = true;
|
||||
}
|
||||
|
||||
public Bundle getExtraArgs() {
|
||||
return this.zzdk;
|
||||
}
|
||||
|
||||
@Override // android.os.Parcelable
|
||||
public void writeToParcel(Parcel parcel, int i) {
|
||||
int a = SafeParcelWriter.a(parcel);
|
||||
SafeParcelWriter.a(parcel, 1, this.version);
|
||||
SafeParcelWriter.a(parcel, 2, this.zzdf);
|
||||
SafeParcelWriter.a(parcel, 3, this.zzdg);
|
||||
SafeParcelWriter.a(parcel, 4, this.zzdh, false);
|
||||
SafeParcelWriter.a(parcel, 5, this.zzdi, false);
|
||||
SafeParcelWriter.a(parcel, 6, (Parcelable[]) this.zzdj, i, false);
|
||||
SafeParcelWriter.a(parcel, 7, this.zzdk, false);
|
||||
SafeParcelWriter.a(parcel, 8, (Parcelable) this.zzdl, i, false);
|
||||
SafeParcelWriter.a(parcel, 10, (Parcelable[]) this.zzdm, i, false);
|
||||
SafeParcelWriter.a(parcel, 11, (Parcelable[]) this.zzdn, i, false);
|
||||
SafeParcelWriter.a(parcel, 12, this.zzdo);
|
||||
SafeParcelWriter.a(parcel, a);
|
||||
}
|
||||
|
||||
GetServiceRequest(int i, int i2, int i3, String str, IBinder iBinder, Scope[] scopeArr, Bundle bundle, Account account, Feature[] featureArr, Feature[] featureArr2, boolean z) {
|
||||
this.version = i;
|
||||
this.zzdf = i2;
|
||||
this.zzdg = i3;
|
||||
if ("com.google.android.gms".equals(str)) {
|
||||
this.zzdh = "com.google.android.gms";
|
||||
} else {
|
||||
this.zzdh = str;
|
||||
}
|
||||
if (i < 2) {
|
||||
this.zzdl = iBinder != null ? AccountAccessor.a(IAccountAccessor.Stub.a(iBinder)) : null;
|
||||
} else {
|
||||
this.zzdi = iBinder;
|
||||
this.zzdl = account;
|
||||
}
|
||||
this.zzdj = scopeArr;
|
||||
this.zzdk = bundle;
|
||||
this.zzdm = featureArr;
|
||||
this.zzdn = featureArr2;
|
||||
this.zzdo = z;
|
||||
}
|
||||
}
|
@@ -0,0 +1,99 @@
|
||||
package com.google.android.gms.common.internal;
|
||||
|
||||
import android.accounts.Account;
|
||||
import android.content.Context;
|
||||
import android.os.IInterface;
|
||||
import android.os.Looper;
|
||||
import com.google.android.gms.common.GoogleApiAvailability;
|
||||
import com.google.android.gms.common.api.Api;
|
||||
import com.google.android.gms.common.api.GoogleApiClient$ConnectionCallbacks;
|
||||
import com.google.android.gms.common.api.GoogleApiClient$OnConnectionFailedListener;
|
||||
import com.google.android.gms.common.api.Scope;
|
||||
import com.google.android.gms.common.internal.BaseGmsClient;
|
||||
import java.util.Iterator;
|
||||
import java.util.Set;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public abstract class GmsClient<T extends IInterface> extends BaseGmsClient<T> implements Api.Client, GmsClientEventManager$GmsClientEventState {
|
||||
private final Set<Scope> w;
|
||||
private final Account x;
|
||||
|
||||
/* JADX WARN: Illegal instructions before constructor call */
|
||||
/*
|
||||
Code decompiled incorrectly, please refer to instructions dump.
|
||||
To view partially-correct code enable 'Show inconsistent code' option in preferences
|
||||
*/
|
||||
protected GmsClient(android.content.Context r10, android.os.Looper r11, int r12, com.google.android.gms.common.internal.ClientSettings r13, com.google.android.gms.common.api.GoogleApiClient$ConnectionCallbacks r14, com.google.android.gms.common.api.GoogleApiClient$OnConnectionFailedListener r15) {
|
||||
/*
|
||||
r9 = this;
|
||||
com.google.android.gms.common.internal.GmsClientSupervisor r3 = com.google.android.gms.common.internal.GmsClientSupervisor.a(r10)
|
||||
com.google.android.gms.common.GoogleApiAvailability r4 = com.google.android.gms.common.GoogleApiAvailability.a()
|
||||
com.google.android.gms.common.internal.Preconditions.a(r14)
|
||||
r7 = r14
|
||||
com.google.android.gms.common.api.GoogleApiClient$ConnectionCallbacks r7 = (com.google.android.gms.common.api.GoogleApiClient$ConnectionCallbacks) r7
|
||||
com.google.android.gms.common.internal.Preconditions.a(r15)
|
||||
r8 = r15
|
||||
com.google.android.gms.common.api.GoogleApiClient$OnConnectionFailedListener r8 = (com.google.android.gms.common.api.GoogleApiClient$OnConnectionFailedListener) r8
|
||||
r0 = r9
|
||||
r1 = r10
|
||||
r2 = r11
|
||||
r5 = r12
|
||||
r6 = r13
|
||||
r0.<init>(r1, r2, r3, r4, r5, r6, r7, r8)
|
||||
return
|
||||
*/
|
||||
throw new UnsupportedOperationException("Method not decompiled: com.google.android.gms.common.internal.GmsClient.<init>(android.content.Context, android.os.Looper, int, com.google.android.gms.common.internal.ClientSettings, com.google.android.gms.common.api.GoogleApiClient$ConnectionCallbacks, com.google.android.gms.common.api.GoogleApiClient$OnConnectionFailedListener):void");
|
||||
}
|
||||
|
||||
private static BaseGmsClient.BaseConnectionCallbacks a(GoogleApiClient$ConnectionCallbacks googleApiClient$ConnectionCallbacks) {
|
||||
if (googleApiClient$ConnectionCallbacks == null) {
|
||||
return null;
|
||||
}
|
||||
return new zaf(googleApiClient$ConnectionCallbacks);
|
||||
}
|
||||
|
||||
private final Set<Scope> b(Set<Scope> set) {
|
||||
a(set);
|
||||
Iterator<Scope> it = set.iterator();
|
||||
while (it.hasNext()) {
|
||||
if (!set.contains(it.next())) {
|
||||
throw new IllegalStateException("Expanding scopes is not permitted, use implied scopes instead");
|
||||
}
|
||||
}
|
||||
return set;
|
||||
}
|
||||
|
||||
protected Set<Scope> a(Set<Scope> set) {
|
||||
return set;
|
||||
}
|
||||
|
||||
@Override // com.google.android.gms.common.internal.BaseGmsClient, com.google.android.gms.common.api.Api.Client
|
||||
public int g() {
|
||||
return super.g();
|
||||
}
|
||||
|
||||
@Override // com.google.android.gms.common.internal.BaseGmsClient
|
||||
public final Account l() {
|
||||
return this.x;
|
||||
}
|
||||
|
||||
@Override // com.google.android.gms.common.internal.BaseGmsClient
|
||||
protected final Set<Scope> r() {
|
||||
return this.w;
|
||||
}
|
||||
|
||||
private static BaseGmsClient.BaseOnConnectionFailedListener a(GoogleApiClient$OnConnectionFailedListener googleApiClient$OnConnectionFailedListener) {
|
||||
if (googleApiClient$OnConnectionFailedListener == null) {
|
||||
return null;
|
||||
}
|
||||
return new zag(googleApiClient$OnConnectionFailedListener);
|
||||
}
|
||||
|
||||
protected GmsClient(Context context, Looper looper, GmsClientSupervisor gmsClientSupervisor, GoogleApiAvailability googleApiAvailability, int i, ClientSettings clientSettings, GoogleApiClient$ConnectionCallbacks googleApiClient$ConnectionCallbacks, GoogleApiClient$OnConnectionFailedListener googleApiClient$OnConnectionFailedListener) {
|
||||
super(context, looper, gmsClientSupervisor, googleApiAvailability, i, a(googleApiClient$ConnectionCallbacks), a(googleApiClient$OnConnectionFailedListener), clientSettings.e());
|
||||
this.x = clientSettings.a();
|
||||
Set<Scope> c = clientSettings.c();
|
||||
b(c);
|
||||
this.w = c;
|
||||
}
|
||||
}
|
@@ -0,0 +1,5 @@
|
||||
package com.google.android.gms.common.internal;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public interface GmsClientEventManager$GmsClientEventState {
|
||||
}
|
@@ -0,0 +1,82 @@
|
||||
package com.google.android.gms.common.internal;
|
||||
|
||||
import android.content.ComponentName;
|
||||
import android.content.Context;
|
||||
import android.content.Intent;
|
||||
import android.content.ServiceConnection;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public abstract class GmsClientSupervisor {
|
||||
private static final Object a = new Object();
|
||||
private static GmsClientSupervisor b;
|
||||
|
||||
protected static final class zza {
|
||||
private final String a;
|
||||
private final String b;
|
||||
private final ComponentName c;
|
||||
private final int d;
|
||||
|
||||
public zza(String str, String str2, int i) {
|
||||
Preconditions.b(str);
|
||||
this.a = str;
|
||||
Preconditions.b(str2);
|
||||
this.b = str2;
|
||||
this.c = null;
|
||||
this.d = i;
|
||||
}
|
||||
|
||||
public final ComponentName a() {
|
||||
return this.c;
|
||||
}
|
||||
|
||||
public final String b() {
|
||||
return this.b;
|
||||
}
|
||||
|
||||
public final int c() {
|
||||
return this.d;
|
||||
}
|
||||
|
||||
public final boolean equals(Object obj) {
|
||||
if (this == obj) {
|
||||
return true;
|
||||
}
|
||||
if (!(obj instanceof zza)) {
|
||||
return false;
|
||||
}
|
||||
zza zzaVar = (zza) obj;
|
||||
return Objects.a(this.a, zzaVar.a) && Objects.a(this.b, zzaVar.b) && Objects.a(this.c, zzaVar.c) && this.d == zzaVar.d;
|
||||
}
|
||||
|
||||
public final int hashCode() {
|
||||
return Objects.a(this.a, this.b, this.c, Integer.valueOf(this.d));
|
||||
}
|
||||
|
||||
public final String toString() {
|
||||
String str = this.a;
|
||||
return str == null ? this.c.flattenToString() : str;
|
||||
}
|
||||
|
||||
public final Intent a(Context context) {
|
||||
String str = this.a;
|
||||
return str != null ? new Intent(str).setPackage(this.b) : new Intent().setComponent(this.c);
|
||||
}
|
||||
}
|
||||
|
||||
public static GmsClientSupervisor a(Context context) {
|
||||
synchronized (a) {
|
||||
if (b == null) {
|
||||
b = new zze(context.getApplicationContext());
|
||||
}
|
||||
}
|
||||
return b;
|
||||
}
|
||||
|
||||
protected abstract boolean a(zza zzaVar, ServiceConnection serviceConnection, String str);
|
||||
|
||||
protected abstract void b(zza zzaVar, ServiceConnection serviceConnection, String str);
|
||||
|
||||
public final void a(String str, String str2, int i, ServiceConnection serviceConnection, String str3) {
|
||||
b(new zza(str, str2, i), serviceConnection, str3);
|
||||
}
|
||||
}
|
@@ -0,0 +1,52 @@
|
||||
package com.google.android.gms.common.internal;
|
||||
|
||||
import android.content.Context;
|
||||
import android.util.SparseIntArray;
|
||||
import com.google.android.gms.common.GoogleApiAvailabilityLight;
|
||||
import com.google.android.gms.common.api.Api;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public class GoogleApiAvailabilityCache {
|
||||
private final SparseIntArray a = new SparseIntArray();
|
||||
private GoogleApiAvailabilityLight b;
|
||||
|
||||
public GoogleApiAvailabilityCache(GoogleApiAvailabilityLight googleApiAvailabilityLight) {
|
||||
Preconditions.a(googleApiAvailabilityLight);
|
||||
this.b = googleApiAvailabilityLight;
|
||||
}
|
||||
|
||||
public int a(Context context, Api.Client client) {
|
||||
Preconditions.a(context);
|
||||
Preconditions.a(client);
|
||||
if (!client.f()) {
|
||||
return 0;
|
||||
}
|
||||
int g = client.g();
|
||||
int i = this.a.get(g, -1);
|
||||
if (i != -1) {
|
||||
return i;
|
||||
}
|
||||
int i2 = 0;
|
||||
while (true) {
|
||||
if (i2 < this.a.size()) {
|
||||
int keyAt = this.a.keyAt(i2);
|
||||
if (keyAt > g && this.a.get(keyAt) == 0) {
|
||||
i = 0;
|
||||
break;
|
||||
}
|
||||
i2++;
|
||||
} else {
|
||||
break;
|
||||
}
|
||||
}
|
||||
if (i == -1) {
|
||||
i = this.b.a(context, g);
|
||||
}
|
||||
this.a.put(g, i);
|
||||
return i;
|
||||
}
|
||||
|
||||
public void a() {
|
||||
this.a.clear();
|
||||
}
|
||||
}
|
@@ -0,0 +1,38 @@
|
||||
package com.google.android.gms.common.internal;
|
||||
|
||||
import android.accounts.Account;
|
||||
import android.os.IBinder;
|
||||
import android.os.IInterface;
|
||||
import android.os.Parcel;
|
||||
import android.os.RemoteException;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public interface IAccountAccessor extends IInterface {
|
||||
|
||||
public static abstract class Stub extends com.google.android.gms.internal.common.zzb implements IAccountAccessor {
|
||||
|
||||
public static class zza extends com.google.android.gms.internal.common.zza implements IAccountAccessor {
|
||||
zza(IBinder iBinder) {
|
||||
super(iBinder, "com.google.android.gms.common.internal.IAccountAccessor");
|
||||
}
|
||||
|
||||
@Override // com.google.android.gms.common.internal.IAccountAccessor
|
||||
public final Account a() throws RemoteException {
|
||||
Parcel a = a(2, i());
|
||||
Account account = (Account) com.google.android.gms.internal.common.zzc.a(a, Account.CREATOR);
|
||||
a.recycle();
|
||||
return account;
|
||||
}
|
||||
}
|
||||
|
||||
public static IAccountAccessor a(IBinder iBinder) {
|
||||
if (iBinder == null) {
|
||||
return null;
|
||||
}
|
||||
IInterface queryLocalInterface = iBinder.queryLocalInterface("com.google.android.gms.common.internal.IAccountAccessor");
|
||||
return queryLocalInterface instanceof IAccountAccessor ? (IAccountAccessor) queryLocalInterface : new zza(iBinder);
|
||||
}
|
||||
}
|
||||
|
||||
Account a() throws RemoteException;
|
||||
}
|
@@ -0,0 +1,39 @@
|
||||
package com.google.android.gms.common.internal;
|
||||
|
||||
import android.os.Bundle;
|
||||
import android.os.IBinder;
|
||||
import android.os.IInterface;
|
||||
import android.os.Parcel;
|
||||
import android.os.RemoteException;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public interface IGmsCallbacks extends IInterface {
|
||||
|
||||
public static abstract class zza extends com.google.android.gms.internal.common.zzb implements IGmsCallbacks {
|
||||
public zza() {
|
||||
super("com.google.android.gms.common.internal.IGmsCallbacks");
|
||||
}
|
||||
|
||||
@Override // com.google.android.gms.internal.common.zzb
|
||||
protected final boolean a(int i, Parcel parcel, Parcel parcel2, int i2) throws RemoteException {
|
||||
if (i == 1) {
|
||||
a(parcel.readInt(), parcel.readStrongBinder(), (Bundle) com.google.android.gms.internal.common.zzc.a(parcel, Bundle.CREATOR));
|
||||
} else if (i == 2) {
|
||||
b(parcel.readInt(), (Bundle) com.google.android.gms.internal.common.zzc.a(parcel, Bundle.CREATOR));
|
||||
} else {
|
||||
if (i != 3) {
|
||||
return false;
|
||||
}
|
||||
a(parcel.readInt(), parcel.readStrongBinder(), (zzb) com.google.android.gms.internal.common.zzc.a(parcel, zzb.CREATOR));
|
||||
}
|
||||
parcel2.writeNoException();
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
void a(int i, IBinder iBinder, Bundle bundle) throws RemoteException;
|
||||
|
||||
void a(int i, IBinder iBinder, zzb zzbVar) throws RemoteException;
|
||||
|
||||
void b(int i, Bundle bundle) throws RemoteException;
|
||||
}
|
@@ -0,0 +1,9 @@
|
||||
package com.google.android.gms.common.internal;
|
||||
|
||||
import android.os.IInterface;
|
||||
import android.os.RemoteException;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public interface IGmsServiceBroker extends IInterface {
|
||||
void a(IGmsCallbacks iGmsCallbacks, GetServiceRequest getServiceRequest) throws RemoteException;
|
||||
}
|
63
sources/com/google/android/gms/common/internal/Objects.java
Normal file
63
sources/com/google/android/gms/common/internal/Objects.java
Normal file
@@ -0,0 +1,63 @@
|
||||
package com.google.android.gms.common.internal;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public final class Objects {
|
||||
|
||||
public static final class ToStringHelper {
|
||||
private final List<String> a;
|
||||
private final Object b;
|
||||
|
||||
private ToStringHelper(Object obj) {
|
||||
Preconditions.a(obj);
|
||||
this.b = obj;
|
||||
this.a = new ArrayList();
|
||||
}
|
||||
|
||||
public final ToStringHelper a(String str, Object obj) {
|
||||
List<String> list = this.a;
|
||||
Preconditions.a(str);
|
||||
String str2 = str;
|
||||
String valueOf = String.valueOf(obj);
|
||||
StringBuilder sb = new StringBuilder(String.valueOf(str2).length() + 1 + String.valueOf(valueOf).length());
|
||||
sb.append(str2);
|
||||
sb.append("=");
|
||||
sb.append(valueOf);
|
||||
list.add(sb.toString());
|
||||
return this;
|
||||
}
|
||||
|
||||
public final String toString() {
|
||||
StringBuilder sb = new StringBuilder(100);
|
||||
sb.append(this.b.getClass().getSimpleName());
|
||||
sb.append('{');
|
||||
int size = this.a.size();
|
||||
for (int i = 0; i < size; i++) {
|
||||
sb.append(this.a.get(i));
|
||||
if (i < size - 1) {
|
||||
sb.append(", ");
|
||||
}
|
||||
}
|
||||
sb.append('}');
|
||||
return sb.toString();
|
||||
}
|
||||
}
|
||||
|
||||
public static boolean a(Object obj, Object obj2) {
|
||||
if (obj != obj2) {
|
||||
return obj != null && obj.equals(obj2);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
public static int a(Object... objArr) {
|
||||
return Arrays.hashCode(objArr);
|
||||
}
|
||||
|
||||
public static ToStringHelper a(Object obj) {
|
||||
return new ToStringHelper(obj);
|
||||
}
|
||||
}
|
@@ -0,0 +1,95 @@
|
||||
package com.google.android.gms.common.internal;
|
||||
|
||||
import android.os.Handler;
|
||||
import android.os.Looper;
|
||||
import android.text.TextUtils;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public final class Preconditions {
|
||||
public static <T> T a(T t) {
|
||||
if (t != null) {
|
||||
return t;
|
||||
}
|
||||
throw new NullPointerException("null reference");
|
||||
}
|
||||
|
||||
public static String b(String str) {
|
||||
if (TextUtils.isEmpty(str)) {
|
||||
throw new IllegalArgumentException("Given String is empty or null");
|
||||
}
|
||||
return str;
|
||||
}
|
||||
|
||||
public static void c(String str) {
|
||||
if (com.google.android.gms.common.util.zzc.a()) {
|
||||
throw new IllegalStateException(str);
|
||||
}
|
||||
}
|
||||
|
||||
public static String a(String str, Object obj) {
|
||||
if (TextUtils.isEmpty(str)) {
|
||||
throw new IllegalArgumentException(String.valueOf(obj));
|
||||
}
|
||||
return str;
|
||||
}
|
||||
|
||||
public static void b(boolean z) {
|
||||
if (!z) {
|
||||
throw new IllegalStateException();
|
||||
}
|
||||
}
|
||||
|
||||
public static <T> T a(T t, Object obj) {
|
||||
if (t != null) {
|
||||
return t;
|
||||
}
|
||||
throw new NullPointerException(String.valueOf(obj));
|
||||
}
|
||||
|
||||
public static void b(boolean z, Object obj) {
|
||||
if (!z) {
|
||||
throw new IllegalStateException(String.valueOf(obj));
|
||||
}
|
||||
}
|
||||
|
||||
public static int a(int i) {
|
||||
if (i != 0) {
|
||||
return i;
|
||||
}
|
||||
throw new IllegalArgumentException("Given Integer is zero");
|
||||
}
|
||||
|
||||
public static void a(boolean z, String str, Object... objArr) {
|
||||
if (!z) {
|
||||
throw new IllegalStateException(String.format(str, objArr));
|
||||
}
|
||||
}
|
||||
|
||||
public static void a(boolean z, Object obj) {
|
||||
if (!z) {
|
||||
throw new IllegalArgumentException(String.valueOf(obj));
|
||||
}
|
||||
}
|
||||
|
||||
public static void a(boolean z) {
|
||||
if (!z) {
|
||||
throw new IllegalArgumentException();
|
||||
}
|
||||
}
|
||||
|
||||
public static void a(String str) {
|
||||
if (!com.google.android.gms.common.util.zzc.a()) {
|
||||
throw new IllegalStateException(str);
|
||||
}
|
||||
}
|
||||
|
||||
public static void a() {
|
||||
c("Must not be called on the main application thread");
|
||||
}
|
||||
|
||||
public static void a(Handler handler) {
|
||||
if (Looper.myLooper() != handler.getLooper()) {
|
||||
throw new IllegalStateException("Must be called on the handler thread");
|
||||
}
|
||||
}
|
||||
}
|
@@ -0,0 +1,7 @@
|
||||
package com.google.android.gms.common.internal;
|
||||
|
||||
import android.os.Parcelable;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public interface ReflectedParcelable extends Parcelable {
|
||||
}
|
@@ -0,0 +1,50 @@
|
||||
package com.google.android.gms.common.internal;
|
||||
|
||||
import android.accounts.Account;
|
||||
import android.os.Parcel;
|
||||
import android.os.Parcelable;
|
||||
import com.google.android.gms.auth.api.signin.GoogleSignInAccount;
|
||||
import com.google.android.gms.common.internal.safeparcel.AbstractSafeParcelable;
|
||||
import com.google.android.gms.common.internal.safeparcel.SafeParcelWriter;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public class ResolveAccountRequest extends AbstractSafeParcelable {
|
||||
public static final Parcelable.Creator<ResolveAccountRequest> CREATOR = new zam();
|
||||
private final int zale;
|
||||
private final int zaoz;
|
||||
private final GoogleSignInAccount zapa;
|
||||
private final Account zax;
|
||||
|
||||
ResolveAccountRequest(int i, Account account, int i2, GoogleSignInAccount googleSignInAccount) {
|
||||
this.zale = i;
|
||||
this.zax = account;
|
||||
this.zaoz = i2;
|
||||
this.zapa = googleSignInAccount;
|
||||
}
|
||||
|
||||
public Account getAccount() {
|
||||
return this.zax;
|
||||
}
|
||||
|
||||
public int getSessionId() {
|
||||
return this.zaoz;
|
||||
}
|
||||
|
||||
public GoogleSignInAccount getSignInAccountHint() {
|
||||
return this.zapa;
|
||||
}
|
||||
|
||||
@Override // android.os.Parcelable
|
||||
public void writeToParcel(Parcel parcel, int i) {
|
||||
int a = SafeParcelWriter.a(parcel);
|
||||
SafeParcelWriter.a(parcel, 1, this.zale);
|
||||
SafeParcelWriter.a(parcel, 2, (Parcelable) getAccount(), i, false);
|
||||
SafeParcelWriter.a(parcel, 3, getSessionId());
|
||||
SafeParcelWriter.a(parcel, 4, (Parcelable) getSignInAccountHint(), i, false);
|
||||
SafeParcelWriter.a(parcel, a);
|
||||
}
|
||||
|
||||
public ResolveAccountRequest(Account account, int i, GoogleSignInAccount googleSignInAccount) {
|
||||
this(2, account, i, googleSignInAccount);
|
||||
}
|
||||
}
|
@@ -0,0 +1,88 @@
|
||||
package com.google.android.gms.common.internal;
|
||||
|
||||
import android.os.IBinder;
|
||||
import android.os.Parcel;
|
||||
import android.os.Parcelable;
|
||||
import com.google.android.gms.common.ConnectionResult;
|
||||
import com.google.android.gms.common.internal.IAccountAccessor;
|
||||
import com.google.android.gms.common.internal.safeparcel.AbstractSafeParcelable;
|
||||
import com.google.android.gms.common.internal.safeparcel.SafeParcelWriter;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public class ResolveAccountResponse extends AbstractSafeParcelable {
|
||||
public static final Parcelable.Creator<ResolveAccountResponse> CREATOR = new zan();
|
||||
private ConnectionResult zadh;
|
||||
private boolean zagf;
|
||||
private final int zale;
|
||||
private IBinder zanw;
|
||||
private boolean zapb;
|
||||
|
||||
ResolveAccountResponse(int i, IBinder iBinder, ConnectionResult connectionResult, boolean z, boolean z2) {
|
||||
this.zale = i;
|
||||
this.zanw = iBinder;
|
||||
this.zadh = connectionResult;
|
||||
this.zagf = z;
|
||||
this.zapb = z2;
|
||||
}
|
||||
|
||||
public boolean equals(Object obj) {
|
||||
if (this == obj) {
|
||||
return true;
|
||||
}
|
||||
if (!(obj instanceof ResolveAccountResponse)) {
|
||||
return false;
|
||||
}
|
||||
ResolveAccountResponse resolveAccountResponse = (ResolveAccountResponse) obj;
|
||||
return this.zadh.equals(resolveAccountResponse.zadh) && getAccountAccessor().equals(resolveAccountResponse.getAccountAccessor());
|
||||
}
|
||||
|
||||
public IAccountAccessor getAccountAccessor() {
|
||||
return IAccountAccessor.Stub.a(this.zanw);
|
||||
}
|
||||
|
||||
public ConnectionResult getConnectionResult() {
|
||||
return this.zadh;
|
||||
}
|
||||
|
||||
public boolean getSaveDefaultAccount() {
|
||||
return this.zagf;
|
||||
}
|
||||
|
||||
public boolean isFromCrossClientAuth() {
|
||||
return this.zapb;
|
||||
}
|
||||
|
||||
public ResolveAccountResponse setAccountAccessor(IAccountAccessor iAccountAccessor) {
|
||||
this.zanw = iAccountAccessor == null ? null : iAccountAccessor.asBinder();
|
||||
return this;
|
||||
}
|
||||
|
||||
public ResolveAccountResponse setIsFromCrossClientAuth(boolean z) {
|
||||
this.zapb = z;
|
||||
return this;
|
||||
}
|
||||
|
||||
public ResolveAccountResponse setSaveDefaultAccount(boolean z) {
|
||||
this.zagf = z;
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override // android.os.Parcelable
|
||||
public void writeToParcel(Parcel parcel, int i) {
|
||||
int a = SafeParcelWriter.a(parcel);
|
||||
SafeParcelWriter.a(parcel, 1, this.zale);
|
||||
SafeParcelWriter.a(parcel, 2, this.zanw, false);
|
||||
SafeParcelWriter.a(parcel, 3, (Parcelable) getConnectionResult(), i, false);
|
||||
SafeParcelWriter.a(parcel, 4, getSaveDefaultAccount());
|
||||
SafeParcelWriter.a(parcel, 5, isFromCrossClientAuth());
|
||||
SafeParcelWriter.a(parcel, a);
|
||||
}
|
||||
|
||||
public ResolveAccountResponse(ConnectionResult connectionResult) {
|
||||
this(1, null, connectionResult, false, false);
|
||||
}
|
||||
|
||||
public ResolveAccountResponse(int i) {
|
||||
this(new ConnectionResult(i, null));
|
||||
}
|
||||
}
|
@@ -0,0 +1,52 @@
|
||||
package com.google.android.gms.common.internal;
|
||||
|
||||
import android.os.Parcel;
|
||||
import android.os.Parcelable;
|
||||
import com.google.android.gms.common.api.Scope;
|
||||
import com.google.android.gms.common.internal.safeparcel.AbstractSafeParcelable;
|
||||
import com.google.android.gms.common.internal.safeparcel.SafeParcelWriter;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public class SignInButtonConfig extends AbstractSafeParcelable {
|
||||
public static final Parcelable.Creator<SignInButtonConfig> CREATOR = new zao();
|
||||
private final int zale;
|
||||
|
||||
@Deprecated
|
||||
private final Scope[] zanx;
|
||||
private final int zapc;
|
||||
private final int zapd;
|
||||
|
||||
SignInButtonConfig(int i, int i2, int i3, Scope[] scopeArr) {
|
||||
this.zale = i;
|
||||
this.zapc = i2;
|
||||
this.zapd = i3;
|
||||
this.zanx = scopeArr;
|
||||
}
|
||||
|
||||
public int getButtonSize() {
|
||||
return this.zapc;
|
||||
}
|
||||
|
||||
public int getColorScheme() {
|
||||
return this.zapd;
|
||||
}
|
||||
|
||||
@Deprecated
|
||||
public Scope[] getScopes() {
|
||||
return this.zanx;
|
||||
}
|
||||
|
||||
@Override // android.os.Parcelable
|
||||
public void writeToParcel(Parcel parcel, int i) {
|
||||
int a = SafeParcelWriter.a(parcel);
|
||||
SafeParcelWriter.a(parcel, 1, this.zale);
|
||||
SafeParcelWriter.a(parcel, 2, getButtonSize());
|
||||
SafeParcelWriter.a(parcel, 3, getColorScheme());
|
||||
SafeParcelWriter.a(parcel, 4, (Parcelable[]) getScopes(), i, false);
|
||||
SafeParcelWriter.a(parcel, a);
|
||||
}
|
||||
|
||||
public SignInButtonConfig(int i, int i2, Scope[] scopeArr) {
|
||||
this(1, i, i2, null);
|
||||
}
|
||||
}
|
@@ -0,0 +1,39 @@
|
||||
package com.google.android.gms.common.internal;
|
||||
|
||||
import android.os.IBinder;
|
||||
import android.os.IInterface;
|
||||
import com.google.android.gms.common.api.Api;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public class SimpleClientAdapter<T extends IInterface> extends GmsClient<T> {
|
||||
private final Api.SimpleClient<T> y;
|
||||
|
||||
@Override // com.google.android.gms.common.internal.BaseGmsClient
|
||||
protected T a(IBinder iBinder) {
|
||||
return this.y.a(iBinder);
|
||||
}
|
||||
|
||||
@Override // com.google.android.gms.common.internal.GmsClient, com.google.android.gms.common.internal.BaseGmsClient, com.google.android.gms.common.api.Api.Client
|
||||
public int g() {
|
||||
return super.g();
|
||||
}
|
||||
|
||||
@Override // com.google.android.gms.common.internal.BaseGmsClient
|
||||
protected String t() {
|
||||
return this.y.j();
|
||||
}
|
||||
|
||||
@Override // com.google.android.gms.common.internal.BaseGmsClient
|
||||
protected String u() {
|
||||
return this.y.k();
|
||||
}
|
||||
|
||||
public Api.SimpleClient<T> x() {
|
||||
return this.y;
|
||||
}
|
||||
|
||||
@Override // com.google.android.gms.common.internal.BaseGmsClient
|
||||
protected void a(int i, T t) {
|
||||
this.y.a(i, t);
|
||||
}
|
||||
}
|
@@ -0,0 +1,25 @@
|
||||
package com.google.android.gms.common.internal;
|
||||
|
||||
import android.content.Context;
|
||||
import android.content.res.Resources;
|
||||
import com.google.android.gms.common.R$string;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public class StringResourceValueReader {
|
||||
private final Resources a;
|
||||
private final String b;
|
||||
|
||||
public StringResourceValueReader(Context context) {
|
||||
Preconditions.a(context);
|
||||
this.a = context.getResources();
|
||||
this.b = this.a.getResourcePackageName(R$string.common_google_play_services_unknown_issue);
|
||||
}
|
||||
|
||||
public String a(String str) {
|
||||
int identifier = this.a.getIdentifier(str, "string", this.b);
|
||||
if (identifier == 0) {
|
||||
return null;
|
||||
}
|
||||
return this.a.getString(identifier);
|
||||
}
|
||||
}
|
@@ -0,0 +1,9 @@
|
||||
package com.google.android.gms.common.internal.safeparcel;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public abstract class AbstractSafeParcelable implements SafeParcelable {
|
||||
@Override // android.os.Parcelable
|
||||
public final int describeContents() {
|
||||
return 0;
|
||||
}
|
||||
}
|
@@ -0,0 +1,428 @@
|
||||
package com.google.android.gms.common.internal.safeparcel;
|
||||
|
||||
import android.os.Bundle;
|
||||
import android.os.IBinder;
|
||||
import android.os.Parcel;
|
||||
import android.os.Parcelable;
|
||||
import java.math.BigDecimal;
|
||||
import java.math.BigInteger;
|
||||
import java.util.ArrayList;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public class SafeParcelReader {
|
||||
|
||||
public static class ParseException extends RuntimeException {
|
||||
/* JADX WARN: Illegal instructions before constructor call */
|
||||
/*
|
||||
Code decompiled incorrectly, please refer to instructions dump.
|
||||
To view partially-correct code enable 'Show inconsistent code' option in preferences
|
||||
*/
|
||||
public ParseException(java.lang.String r4, android.os.Parcel r5) {
|
||||
/*
|
||||
r3 = this;
|
||||
int r0 = r5.dataPosition()
|
||||
int r5 = r5.dataSize()
|
||||
java.lang.String r1 = java.lang.String.valueOf(r4)
|
||||
int r1 = r1.length()
|
||||
int r1 = r1 + 41
|
||||
java.lang.StringBuilder r2 = new java.lang.StringBuilder
|
||||
r2.<init>(r1)
|
||||
r2.append(r4)
|
||||
java.lang.String r4 = " Parcel: pos="
|
||||
r2.append(r4)
|
||||
r2.append(r0)
|
||||
java.lang.String r4 = " size="
|
||||
r2.append(r4)
|
||||
r2.append(r5)
|
||||
java.lang.String r4 = r2.toString()
|
||||
r3.<init>(r4)
|
||||
return
|
||||
*/
|
||||
throw new UnsupportedOperationException("Method not decompiled: com.google.android.gms.common.internal.safeparcel.SafeParcelReader.ParseException.<init>(java.lang.String, android.os.Parcel):void");
|
||||
}
|
||||
}
|
||||
|
||||
public static Long A(Parcel parcel, int i) {
|
||||
int B = B(parcel, i);
|
||||
if (B == 0) {
|
||||
return null;
|
||||
}
|
||||
a(parcel, i, B, 8);
|
||||
return Long.valueOf(parcel.readLong());
|
||||
}
|
||||
|
||||
public static int B(Parcel parcel, int i) {
|
||||
return (i & (-65536)) != -65536 ? (i >> 16) & 65535 : parcel.readInt();
|
||||
}
|
||||
|
||||
public static void C(Parcel parcel, int i) {
|
||||
parcel.setDataPosition(parcel.dataPosition() + B(parcel, i));
|
||||
}
|
||||
|
||||
public static int a(int i) {
|
||||
return i & 65535;
|
||||
}
|
||||
|
||||
public static int a(Parcel parcel) {
|
||||
return parcel.readInt();
|
||||
}
|
||||
|
||||
public static int b(Parcel parcel) {
|
||||
int a = a(parcel);
|
||||
int B = B(parcel, a);
|
||||
int dataPosition = parcel.dataPosition();
|
||||
if (a(a) != 20293) {
|
||||
String valueOf = String.valueOf(Integer.toHexString(a));
|
||||
throw new ParseException(valueOf.length() != 0 ? "Expected object header. Got 0x".concat(valueOf) : new String("Expected object header. Got 0x"), parcel);
|
||||
}
|
||||
int i = B + dataPosition;
|
||||
if (i >= dataPosition && i <= parcel.dataSize()) {
|
||||
return i;
|
||||
}
|
||||
StringBuilder sb = new StringBuilder(54);
|
||||
sb.append("Size read is invalid start=");
|
||||
sb.append(dataPosition);
|
||||
sb.append(" end=");
|
||||
sb.append(i);
|
||||
throw new ParseException(sb.toString(), parcel);
|
||||
}
|
||||
|
||||
public static BigInteger c(Parcel parcel, int i) {
|
||||
int B = B(parcel, i);
|
||||
int dataPosition = parcel.dataPosition();
|
||||
if (B == 0) {
|
||||
return null;
|
||||
}
|
||||
byte[] createByteArray = parcel.createByteArray();
|
||||
parcel.setDataPosition(dataPosition + B);
|
||||
return new BigInteger(createByteArray);
|
||||
}
|
||||
|
||||
public static BigInteger[] d(Parcel parcel, int i) {
|
||||
int B = B(parcel, i);
|
||||
int dataPosition = parcel.dataPosition();
|
||||
if (B == 0) {
|
||||
return null;
|
||||
}
|
||||
int readInt = parcel.readInt();
|
||||
BigInteger[] bigIntegerArr = new BigInteger[readInt];
|
||||
for (int i2 = 0; i2 < readInt; i2++) {
|
||||
bigIntegerArr[i2] = new BigInteger(parcel.createByteArray());
|
||||
}
|
||||
parcel.setDataPosition(dataPosition + B);
|
||||
return bigIntegerArr;
|
||||
}
|
||||
|
||||
public static boolean[] e(Parcel parcel, int i) {
|
||||
int B = B(parcel, i);
|
||||
int dataPosition = parcel.dataPosition();
|
||||
if (B == 0) {
|
||||
return null;
|
||||
}
|
||||
boolean[] createBooleanArray = parcel.createBooleanArray();
|
||||
parcel.setDataPosition(dataPosition + B);
|
||||
return createBooleanArray;
|
||||
}
|
||||
|
||||
public static Bundle f(Parcel parcel, int i) {
|
||||
int B = B(parcel, i);
|
||||
int dataPosition = parcel.dataPosition();
|
||||
if (B == 0) {
|
||||
return null;
|
||||
}
|
||||
Bundle readBundle = parcel.readBundle();
|
||||
parcel.setDataPosition(dataPosition + B);
|
||||
return readBundle;
|
||||
}
|
||||
|
||||
public static byte[] g(Parcel parcel, int i) {
|
||||
int B = B(parcel, i);
|
||||
int dataPosition = parcel.dataPosition();
|
||||
if (B == 0) {
|
||||
return null;
|
||||
}
|
||||
byte[] createByteArray = parcel.createByteArray();
|
||||
parcel.setDataPosition(dataPosition + B);
|
||||
return createByteArray;
|
||||
}
|
||||
|
||||
public static double[] h(Parcel parcel, int i) {
|
||||
int B = B(parcel, i);
|
||||
int dataPosition = parcel.dataPosition();
|
||||
if (B == 0) {
|
||||
return null;
|
||||
}
|
||||
double[] createDoubleArray = parcel.createDoubleArray();
|
||||
parcel.setDataPosition(dataPosition + B);
|
||||
return createDoubleArray;
|
||||
}
|
||||
|
||||
public static float[] i(Parcel parcel, int i) {
|
||||
int B = B(parcel, i);
|
||||
int dataPosition = parcel.dataPosition();
|
||||
if (B == 0) {
|
||||
return null;
|
||||
}
|
||||
float[] createFloatArray = parcel.createFloatArray();
|
||||
parcel.setDataPosition(dataPosition + B);
|
||||
return createFloatArray;
|
||||
}
|
||||
|
||||
public static int[] j(Parcel parcel, int i) {
|
||||
int B = B(parcel, i);
|
||||
int dataPosition = parcel.dataPosition();
|
||||
if (B == 0) {
|
||||
return null;
|
||||
}
|
||||
int[] createIntArray = parcel.createIntArray();
|
||||
parcel.setDataPosition(dataPosition + B);
|
||||
return createIntArray;
|
||||
}
|
||||
|
||||
public static long[] k(Parcel parcel, int i) {
|
||||
int B = B(parcel, i);
|
||||
int dataPosition = parcel.dataPosition();
|
||||
if (B == 0) {
|
||||
return null;
|
||||
}
|
||||
long[] createLongArray = parcel.createLongArray();
|
||||
parcel.setDataPosition(dataPosition + B);
|
||||
return createLongArray;
|
||||
}
|
||||
|
||||
public static Parcel l(Parcel parcel, int i) {
|
||||
int B = B(parcel, i);
|
||||
int dataPosition = parcel.dataPosition();
|
||||
if (B == 0) {
|
||||
return null;
|
||||
}
|
||||
Parcel obtain = Parcel.obtain();
|
||||
obtain.appendFrom(parcel, dataPosition, B);
|
||||
parcel.setDataPosition(dataPosition + B);
|
||||
return obtain;
|
||||
}
|
||||
|
||||
public static Parcel[] m(Parcel parcel, int i) {
|
||||
int B = B(parcel, i);
|
||||
int dataPosition = parcel.dataPosition();
|
||||
if (B == 0) {
|
||||
return null;
|
||||
}
|
||||
int readInt = parcel.readInt();
|
||||
Parcel[] parcelArr = new Parcel[readInt];
|
||||
for (int i2 = 0; i2 < readInt; i2++) {
|
||||
int readInt2 = parcel.readInt();
|
||||
if (readInt2 != 0) {
|
||||
int dataPosition2 = parcel.dataPosition();
|
||||
Parcel obtain = Parcel.obtain();
|
||||
obtain.appendFrom(parcel, dataPosition2, readInt2);
|
||||
parcelArr[i2] = obtain;
|
||||
parcel.setDataPosition(dataPosition2 + readInt2);
|
||||
} else {
|
||||
parcelArr[i2] = null;
|
||||
}
|
||||
}
|
||||
parcel.setDataPosition(dataPosition + B);
|
||||
return parcelArr;
|
||||
}
|
||||
|
||||
public static String n(Parcel parcel, int i) {
|
||||
int B = B(parcel, i);
|
||||
int dataPosition = parcel.dataPosition();
|
||||
if (B == 0) {
|
||||
return null;
|
||||
}
|
||||
String readString = parcel.readString();
|
||||
parcel.setDataPosition(dataPosition + B);
|
||||
return readString;
|
||||
}
|
||||
|
||||
public static String[] o(Parcel parcel, int i) {
|
||||
int B = B(parcel, i);
|
||||
int dataPosition = parcel.dataPosition();
|
||||
if (B == 0) {
|
||||
return null;
|
||||
}
|
||||
String[] createStringArray = parcel.createStringArray();
|
||||
parcel.setDataPosition(dataPosition + B);
|
||||
return createStringArray;
|
||||
}
|
||||
|
||||
public static ArrayList<String> p(Parcel parcel, int i) {
|
||||
int B = B(parcel, i);
|
||||
int dataPosition = parcel.dataPosition();
|
||||
if (B == 0) {
|
||||
return null;
|
||||
}
|
||||
ArrayList<String> createStringArrayList = parcel.createStringArrayList();
|
||||
parcel.setDataPosition(dataPosition + B);
|
||||
return createStringArrayList;
|
||||
}
|
||||
|
||||
public static void q(Parcel parcel, int i) {
|
||||
if (parcel.dataPosition() == i) {
|
||||
return;
|
||||
}
|
||||
StringBuilder sb = new StringBuilder(37);
|
||||
sb.append("Overread allowed size end=");
|
||||
sb.append(i);
|
||||
throw new ParseException(sb.toString(), parcel);
|
||||
}
|
||||
|
||||
public static boolean r(Parcel parcel, int i) {
|
||||
a(parcel, i, 4);
|
||||
return parcel.readInt() != 0;
|
||||
}
|
||||
|
||||
public static double s(Parcel parcel, int i) {
|
||||
a(parcel, i, 8);
|
||||
return parcel.readDouble();
|
||||
}
|
||||
|
||||
public static Double t(Parcel parcel, int i) {
|
||||
int B = B(parcel, i);
|
||||
if (B == 0) {
|
||||
return null;
|
||||
}
|
||||
a(parcel, i, B, 8);
|
||||
return Double.valueOf(parcel.readDouble());
|
||||
}
|
||||
|
||||
public static float u(Parcel parcel, int i) {
|
||||
a(parcel, i, 4);
|
||||
return parcel.readFloat();
|
||||
}
|
||||
|
||||
public static Float v(Parcel parcel, int i) {
|
||||
int B = B(parcel, i);
|
||||
if (B == 0) {
|
||||
return null;
|
||||
}
|
||||
a(parcel, i, B, 4);
|
||||
return Float.valueOf(parcel.readFloat());
|
||||
}
|
||||
|
||||
public static IBinder w(Parcel parcel, int i) {
|
||||
int B = B(parcel, i);
|
||||
int dataPosition = parcel.dataPosition();
|
||||
if (B == 0) {
|
||||
return null;
|
||||
}
|
||||
IBinder readStrongBinder = parcel.readStrongBinder();
|
||||
parcel.setDataPosition(dataPosition + B);
|
||||
return readStrongBinder;
|
||||
}
|
||||
|
||||
public static int x(Parcel parcel, int i) {
|
||||
a(parcel, i, 4);
|
||||
return parcel.readInt();
|
||||
}
|
||||
|
||||
public static Integer y(Parcel parcel, int i) {
|
||||
int B = B(parcel, i);
|
||||
if (B == 0) {
|
||||
return null;
|
||||
}
|
||||
a(parcel, i, B, 4);
|
||||
return Integer.valueOf(parcel.readInt());
|
||||
}
|
||||
|
||||
public static long z(Parcel parcel, int i) {
|
||||
a(parcel, i, 8);
|
||||
return parcel.readLong();
|
||||
}
|
||||
|
||||
private static void a(Parcel parcel, int i, int i2) {
|
||||
int B = B(parcel, i);
|
||||
if (B == i2) {
|
||||
return;
|
||||
}
|
||||
String hexString = Integer.toHexString(B);
|
||||
StringBuilder sb = new StringBuilder(String.valueOf(hexString).length() + 46);
|
||||
sb.append("Expected size ");
|
||||
sb.append(i2);
|
||||
sb.append(" got ");
|
||||
sb.append(B);
|
||||
sb.append(" (0x");
|
||||
sb.append(hexString);
|
||||
sb.append(")");
|
||||
throw new ParseException(sb.toString(), parcel);
|
||||
}
|
||||
|
||||
private static void a(Parcel parcel, int i, int i2, int i3) {
|
||||
if (i2 == i3) {
|
||||
return;
|
||||
}
|
||||
String hexString = Integer.toHexString(i2);
|
||||
StringBuilder sb = new StringBuilder(String.valueOf(hexString).length() + 46);
|
||||
sb.append("Expected size ");
|
||||
sb.append(i3);
|
||||
sb.append(" got ");
|
||||
sb.append(i2);
|
||||
sb.append(" (0x");
|
||||
sb.append(hexString);
|
||||
sb.append(")");
|
||||
throw new ParseException(sb.toString(), parcel);
|
||||
}
|
||||
|
||||
public static <T> ArrayList<T> c(Parcel parcel, int i, Parcelable.Creator<T> creator) {
|
||||
int B = B(parcel, i);
|
||||
int dataPosition = parcel.dataPosition();
|
||||
if (B == 0) {
|
||||
return null;
|
||||
}
|
||||
ArrayList<T> createTypedArrayList = parcel.createTypedArrayList(creator);
|
||||
parcel.setDataPosition(dataPosition + B);
|
||||
return createTypedArrayList;
|
||||
}
|
||||
|
||||
public static BigDecimal a(Parcel parcel, int i) {
|
||||
int B = B(parcel, i);
|
||||
int dataPosition = parcel.dataPosition();
|
||||
if (B == 0) {
|
||||
return null;
|
||||
}
|
||||
byte[] createByteArray = parcel.createByteArray();
|
||||
int readInt = parcel.readInt();
|
||||
parcel.setDataPosition(dataPosition + B);
|
||||
return new BigDecimal(new BigInteger(createByteArray), readInt);
|
||||
}
|
||||
|
||||
public static BigDecimal[] b(Parcel parcel, int i) {
|
||||
int B = B(parcel, i);
|
||||
int dataPosition = parcel.dataPosition();
|
||||
if (B == 0) {
|
||||
return null;
|
||||
}
|
||||
int readInt = parcel.readInt();
|
||||
BigDecimal[] bigDecimalArr = new BigDecimal[readInt];
|
||||
for (int i2 = 0; i2 < readInt; i2++) {
|
||||
byte[] createByteArray = parcel.createByteArray();
|
||||
bigDecimalArr[i2] = new BigDecimal(new BigInteger(createByteArray), parcel.readInt());
|
||||
}
|
||||
parcel.setDataPosition(dataPosition + B);
|
||||
return bigDecimalArr;
|
||||
}
|
||||
|
||||
public static <T extends Parcelable> T a(Parcel parcel, int i, Parcelable.Creator<T> creator) {
|
||||
int B = B(parcel, i);
|
||||
int dataPosition = parcel.dataPosition();
|
||||
if (B == 0) {
|
||||
return null;
|
||||
}
|
||||
T createFromParcel = creator.createFromParcel(parcel);
|
||||
parcel.setDataPosition(dataPosition + B);
|
||||
return createFromParcel;
|
||||
}
|
||||
|
||||
public static <T> T[] b(Parcel parcel, int i, Parcelable.Creator<T> creator) {
|
||||
int B = B(parcel, i);
|
||||
int dataPosition = parcel.dataPosition();
|
||||
if (B == 0) {
|
||||
return null;
|
||||
}
|
||||
T[] tArr = (T[]) parcel.createTypedArray(creator);
|
||||
parcel.setDataPosition(dataPosition + B);
|
||||
return tArr;
|
||||
}
|
||||
}
|
@@ -0,0 +1,394 @@
|
||||
package com.google.android.gms.common.internal.safeparcel;
|
||||
|
||||
import android.os.Bundle;
|
||||
import android.os.IBinder;
|
||||
import android.os.Parcel;
|
||||
import android.os.Parcelable;
|
||||
import java.math.BigDecimal;
|
||||
import java.math.BigInteger;
|
||||
import java.util.List;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public class SafeParcelWriter {
|
||||
public static int a(Parcel parcel) {
|
||||
return b(parcel, 20293);
|
||||
}
|
||||
|
||||
private static void b(Parcel parcel, int i, int i2) {
|
||||
if (i2 < 65535) {
|
||||
parcel.writeInt(i | (i2 << 16));
|
||||
} else {
|
||||
parcel.writeInt(i | (-65536));
|
||||
parcel.writeInt(i2);
|
||||
}
|
||||
}
|
||||
|
||||
private static void c(Parcel parcel, int i) {
|
||||
int dataPosition = parcel.dataPosition();
|
||||
parcel.setDataPosition(i - 4);
|
||||
parcel.writeInt(dataPosition - i);
|
||||
parcel.setDataPosition(dataPosition);
|
||||
}
|
||||
|
||||
public static void a(Parcel parcel, int i) {
|
||||
c(parcel, i);
|
||||
}
|
||||
|
||||
public static void a(Parcel parcel, int i, boolean z) {
|
||||
b(parcel, i, 4);
|
||||
parcel.writeInt(z ? 1 : 0);
|
||||
}
|
||||
|
||||
private static int b(Parcel parcel, int i) {
|
||||
parcel.writeInt(i | (-65536));
|
||||
parcel.writeInt(0);
|
||||
return parcel.dataPosition();
|
||||
}
|
||||
|
||||
public static void a(Parcel parcel, int i, int i2) {
|
||||
b(parcel, i, 4);
|
||||
parcel.writeInt(i2);
|
||||
}
|
||||
|
||||
public static <T extends Parcelable> void c(Parcel parcel, int i, List<T> list, boolean z) {
|
||||
if (list == null) {
|
||||
if (z) {
|
||||
b(parcel, i, 0);
|
||||
return;
|
||||
}
|
||||
return;
|
||||
}
|
||||
int b = b(parcel, i);
|
||||
int size = list.size();
|
||||
parcel.writeInt(size);
|
||||
for (int i2 = 0; i2 < size; i2++) {
|
||||
T t = list.get(i2);
|
||||
if (t == null) {
|
||||
parcel.writeInt(0);
|
||||
} else {
|
||||
a(parcel, t, 0);
|
||||
}
|
||||
}
|
||||
c(parcel, b);
|
||||
}
|
||||
|
||||
public static void a(Parcel parcel, int i, Integer num, boolean z) {
|
||||
if (num != null) {
|
||||
b(parcel, i, 4);
|
||||
parcel.writeInt(num.intValue());
|
||||
} else if (z) {
|
||||
b(parcel, i, 0);
|
||||
}
|
||||
}
|
||||
|
||||
public static void b(Parcel parcel, int i, List<String> list, boolean z) {
|
||||
if (list == null) {
|
||||
if (z) {
|
||||
b(parcel, i, 0);
|
||||
}
|
||||
} else {
|
||||
int b = b(parcel, i);
|
||||
parcel.writeStringList(list);
|
||||
c(parcel, b);
|
||||
}
|
||||
}
|
||||
|
||||
public static void a(Parcel parcel, int i, long j) {
|
||||
b(parcel, i, 8);
|
||||
parcel.writeLong(j);
|
||||
}
|
||||
|
||||
public static void a(Parcel parcel, int i, Long l, boolean z) {
|
||||
if (l != null) {
|
||||
b(parcel, i, 8);
|
||||
parcel.writeLong(l.longValue());
|
||||
} else if (z) {
|
||||
b(parcel, i, 0);
|
||||
}
|
||||
}
|
||||
|
||||
public static void a(Parcel parcel, int i, BigInteger bigInteger, boolean z) {
|
||||
if (bigInteger == null) {
|
||||
if (z) {
|
||||
b(parcel, i, 0);
|
||||
}
|
||||
} else {
|
||||
int b = b(parcel, i);
|
||||
parcel.writeByteArray(bigInteger.toByteArray());
|
||||
c(parcel, b);
|
||||
}
|
||||
}
|
||||
|
||||
public static void a(Parcel parcel, int i, float f) {
|
||||
b(parcel, i, 4);
|
||||
parcel.writeFloat(f);
|
||||
}
|
||||
|
||||
public static void a(Parcel parcel, int i, Float f, boolean z) {
|
||||
if (f != null) {
|
||||
b(parcel, i, 4);
|
||||
parcel.writeFloat(f.floatValue());
|
||||
} else if (z) {
|
||||
b(parcel, i, 0);
|
||||
}
|
||||
}
|
||||
|
||||
public static void a(Parcel parcel, int i, double d) {
|
||||
b(parcel, i, 8);
|
||||
parcel.writeDouble(d);
|
||||
}
|
||||
|
||||
public static void a(Parcel parcel, int i, Double d, boolean z) {
|
||||
if (d != null) {
|
||||
b(parcel, i, 8);
|
||||
parcel.writeDouble(d.doubleValue());
|
||||
} else if (z) {
|
||||
b(parcel, i, 0);
|
||||
}
|
||||
}
|
||||
|
||||
public static void a(Parcel parcel, int i, BigDecimal bigDecimal, boolean z) {
|
||||
if (bigDecimal == null) {
|
||||
if (z) {
|
||||
b(parcel, i, 0);
|
||||
}
|
||||
} else {
|
||||
int b = b(parcel, i);
|
||||
parcel.writeByteArray(bigDecimal.unscaledValue().toByteArray());
|
||||
parcel.writeInt(bigDecimal.scale());
|
||||
c(parcel, b);
|
||||
}
|
||||
}
|
||||
|
||||
public static void a(Parcel parcel, int i, String str, boolean z) {
|
||||
if (str == null) {
|
||||
if (z) {
|
||||
b(parcel, i, 0);
|
||||
}
|
||||
} else {
|
||||
int b = b(parcel, i);
|
||||
parcel.writeString(str);
|
||||
c(parcel, b);
|
||||
}
|
||||
}
|
||||
|
||||
public static void a(Parcel parcel, int i, IBinder iBinder, boolean z) {
|
||||
if (iBinder == null) {
|
||||
if (z) {
|
||||
b(parcel, i, 0);
|
||||
}
|
||||
} else {
|
||||
int b = b(parcel, i);
|
||||
parcel.writeStrongBinder(iBinder);
|
||||
c(parcel, b);
|
||||
}
|
||||
}
|
||||
|
||||
public static void a(Parcel parcel, int i, Parcelable parcelable, int i2, boolean z) {
|
||||
if (parcelable == null) {
|
||||
if (z) {
|
||||
b(parcel, i, 0);
|
||||
}
|
||||
} else {
|
||||
int b = b(parcel, i);
|
||||
parcelable.writeToParcel(parcel, i2);
|
||||
c(parcel, b);
|
||||
}
|
||||
}
|
||||
|
||||
public static void a(Parcel parcel, int i, Bundle bundle, boolean z) {
|
||||
if (bundle == null) {
|
||||
if (z) {
|
||||
b(parcel, i, 0);
|
||||
}
|
||||
} else {
|
||||
int b = b(parcel, i);
|
||||
parcel.writeBundle(bundle);
|
||||
c(parcel, b);
|
||||
}
|
||||
}
|
||||
|
||||
public static void a(Parcel parcel, int i, byte[] bArr, boolean z) {
|
||||
if (bArr == null) {
|
||||
if (z) {
|
||||
b(parcel, i, 0);
|
||||
}
|
||||
} else {
|
||||
int b = b(parcel, i);
|
||||
parcel.writeByteArray(bArr);
|
||||
c(parcel, b);
|
||||
}
|
||||
}
|
||||
|
||||
public static void a(Parcel parcel, int i, boolean[] zArr, boolean z) {
|
||||
if (zArr == null) {
|
||||
if (z) {
|
||||
b(parcel, i, 0);
|
||||
}
|
||||
} else {
|
||||
int b = b(parcel, i);
|
||||
parcel.writeBooleanArray(zArr);
|
||||
c(parcel, b);
|
||||
}
|
||||
}
|
||||
|
||||
public static void a(Parcel parcel, int i, int[] iArr, boolean z) {
|
||||
if (iArr == null) {
|
||||
if (z) {
|
||||
b(parcel, i, 0);
|
||||
}
|
||||
} else {
|
||||
int b = b(parcel, i);
|
||||
parcel.writeIntArray(iArr);
|
||||
c(parcel, b);
|
||||
}
|
||||
}
|
||||
|
||||
public static void a(Parcel parcel, int i, long[] jArr, boolean z) {
|
||||
if (jArr == null) {
|
||||
if (z) {
|
||||
b(parcel, i, 0);
|
||||
}
|
||||
} else {
|
||||
int b = b(parcel, i);
|
||||
parcel.writeLongArray(jArr);
|
||||
c(parcel, b);
|
||||
}
|
||||
}
|
||||
|
||||
public static void a(Parcel parcel, int i, BigInteger[] bigIntegerArr, boolean z) {
|
||||
if (bigIntegerArr == null) {
|
||||
if (z) {
|
||||
b(parcel, i, 0);
|
||||
return;
|
||||
}
|
||||
return;
|
||||
}
|
||||
int b = b(parcel, i);
|
||||
parcel.writeInt(bigIntegerArr.length);
|
||||
for (BigInteger bigInteger : bigIntegerArr) {
|
||||
parcel.writeByteArray(bigInteger.toByteArray());
|
||||
}
|
||||
c(parcel, b);
|
||||
}
|
||||
|
||||
public static void a(Parcel parcel, int i, float[] fArr, boolean z) {
|
||||
if (fArr == null) {
|
||||
if (z) {
|
||||
b(parcel, i, 0);
|
||||
}
|
||||
} else {
|
||||
int b = b(parcel, i);
|
||||
parcel.writeFloatArray(fArr);
|
||||
c(parcel, b);
|
||||
}
|
||||
}
|
||||
|
||||
public static void a(Parcel parcel, int i, double[] dArr, boolean z) {
|
||||
if (dArr == null) {
|
||||
if (z) {
|
||||
b(parcel, i, 0);
|
||||
}
|
||||
} else {
|
||||
int b = b(parcel, i);
|
||||
parcel.writeDoubleArray(dArr);
|
||||
c(parcel, b);
|
||||
}
|
||||
}
|
||||
|
||||
public static void a(Parcel parcel, int i, BigDecimal[] bigDecimalArr, boolean z) {
|
||||
if (bigDecimalArr == null) {
|
||||
if (z) {
|
||||
b(parcel, i, 0);
|
||||
return;
|
||||
}
|
||||
return;
|
||||
}
|
||||
int b = b(parcel, i);
|
||||
int length = bigDecimalArr.length;
|
||||
parcel.writeInt(length);
|
||||
for (int i2 = 0; i2 < length; i2++) {
|
||||
parcel.writeByteArray(bigDecimalArr[i2].unscaledValue().toByteArray());
|
||||
parcel.writeInt(bigDecimalArr[i2].scale());
|
||||
}
|
||||
c(parcel, b);
|
||||
}
|
||||
|
||||
public static void a(Parcel parcel, int i, String[] strArr, boolean z) {
|
||||
if (strArr == null) {
|
||||
if (z) {
|
||||
b(parcel, i, 0);
|
||||
}
|
||||
} else {
|
||||
int b = b(parcel, i);
|
||||
parcel.writeStringArray(strArr);
|
||||
c(parcel, b);
|
||||
}
|
||||
}
|
||||
|
||||
public static <T extends Parcelable> void a(Parcel parcel, int i, T[] tArr, int i2, boolean z) {
|
||||
if (tArr == null) {
|
||||
if (z) {
|
||||
b(parcel, i, 0);
|
||||
return;
|
||||
}
|
||||
return;
|
||||
}
|
||||
int b = b(parcel, i);
|
||||
parcel.writeInt(tArr.length);
|
||||
for (T t : tArr) {
|
||||
if (t == null) {
|
||||
parcel.writeInt(0);
|
||||
} else {
|
||||
a(parcel, t, i2);
|
||||
}
|
||||
}
|
||||
c(parcel, b);
|
||||
}
|
||||
|
||||
private static <T extends Parcelable> void a(Parcel parcel, T t, int i) {
|
||||
int dataPosition = parcel.dataPosition();
|
||||
parcel.writeInt(1);
|
||||
int dataPosition2 = parcel.dataPosition();
|
||||
t.writeToParcel(parcel, i);
|
||||
int dataPosition3 = parcel.dataPosition();
|
||||
parcel.setDataPosition(dataPosition);
|
||||
parcel.writeInt(dataPosition3 - dataPosition2);
|
||||
parcel.setDataPosition(dataPosition3);
|
||||
}
|
||||
|
||||
public static void a(Parcel parcel, int i, Parcel parcel2, boolean z) {
|
||||
if (parcel2 == null) {
|
||||
if (z) {
|
||||
b(parcel, i, 0);
|
||||
}
|
||||
} else {
|
||||
int b = b(parcel, i);
|
||||
parcel.appendFrom(parcel2, 0, parcel2.dataSize());
|
||||
c(parcel, b);
|
||||
}
|
||||
}
|
||||
|
||||
public static void a(Parcel parcel, int i, List<Parcel> list, boolean z) {
|
||||
if (list == null) {
|
||||
if (z) {
|
||||
b(parcel, i, 0);
|
||||
return;
|
||||
}
|
||||
return;
|
||||
}
|
||||
int b = b(parcel, i);
|
||||
int size = list.size();
|
||||
parcel.writeInt(size);
|
||||
for (int i2 = 0; i2 < size; i2++) {
|
||||
Parcel parcel2 = list.get(i2);
|
||||
if (parcel2 != null) {
|
||||
parcel.writeInt(parcel2.dataSize());
|
||||
parcel.appendFrom(parcel2, 0, parcel2.dataSize());
|
||||
} else {
|
||||
parcel.writeInt(0);
|
||||
}
|
||||
}
|
||||
c(parcel, b);
|
||||
}
|
||||
}
|
@@ -0,0 +1,8 @@
|
||||
package com.google.android.gms.common.internal.safeparcel;
|
||||
|
||||
import android.os.Parcelable;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public interface SafeParcelable extends Parcelable {
|
||||
public static final String NULL = "SAFE_PARCELABLE_NULL_STRING";
|
||||
}
|
55
sources/com/google/android/gms/common/internal/zaa.java
Normal file
55
sources/com/google/android/gms/common/internal/zaa.java
Normal file
@@ -0,0 +1,55 @@
|
||||
package com.google.android.gms.common.internal;
|
||||
|
||||
import android.accounts.Account;
|
||||
import android.os.IBinder;
|
||||
import android.os.Parcel;
|
||||
import android.os.Parcelable;
|
||||
import com.google.android.gms.common.api.Scope;
|
||||
import com.google.android.gms.common.internal.safeparcel.SafeParcelReader;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public final class zaa implements Parcelable.Creator<AuthAccountRequest> {
|
||||
@Override // android.os.Parcelable.Creator
|
||||
public final /* synthetic */ AuthAccountRequest createFromParcel(Parcel parcel) {
|
||||
int b = SafeParcelReader.b(parcel);
|
||||
IBinder iBinder = null;
|
||||
Scope[] scopeArr = null;
|
||||
Integer num = null;
|
||||
Integer num2 = null;
|
||||
Account account = null;
|
||||
int i = 0;
|
||||
while (parcel.dataPosition() < b) {
|
||||
int a = SafeParcelReader.a(parcel);
|
||||
switch (SafeParcelReader.a(a)) {
|
||||
case 1:
|
||||
i = SafeParcelReader.x(parcel, a);
|
||||
break;
|
||||
case 2:
|
||||
iBinder = SafeParcelReader.w(parcel, a);
|
||||
break;
|
||||
case 3:
|
||||
scopeArr = (Scope[]) SafeParcelReader.b(parcel, a, Scope.CREATOR);
|
||||
break;
|
||||
case 4:
|
||||
num = SafeParcelReader.y(parcel, a);
|
||||
break;
|
||||
case 5:
|
||||
num2 = SafeParcelReader.y(parcel, a);
|
||||
break;
|
||||
case 6:
|
||||
account = (Account) SafeParcelReader.a(parcel, a, Account.CREATOR);
|
||||
break;
|
||||
default:
|
||||
SafeParcelReader.C(parcel, a);
|
||||
break;
|
||||
}
|
||||
}
|
||||
SafeParcelReader.q(parcel, b);
|
||||
return new AuthAccountRequest(i, iBinder, scopeArr, num, num2, account);
|
||||
}
|
||||
|
||||
@Override // android.os.Parcelable.Creator
|
||||
public final /* synthetic */ AuthAccountRequest[] newArray(int i) {
|
||||
return new AuthAccountRequest[i];
|
||||
}
|
||||
}
|
33
sources/com/google/android/gms/common/internal/zab.java
Normal file
33
sources/com/google/android/gms/common/internal/zab.java
Normal file
@@ -0,0 +1,33 @@
|
||||
package com.google.android.gms.common.internal;
|
||||
|
||||
import android.os.Parcel;
|
||||
import android.os.Parcelable;
|
||||
import com.google.android.gms.common.internal.safeparcel.SafeParcelReader;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public final class zab implements Parcelable.Creator<ClientIdentity> {
|
||||
@Override // android.os.Parcelable.Creator
|
||||
public final /* synthetic */ ClientIdentity createFromParcel(Parcel parcel) {
|
||||
int b = SafeParcelReader.b(parcel);
|
||||
int i = 0;
|
||||
String str = null;
|
||||
while (parcel.dataPosition() < b) {
|
||||
int a = SafeParcelReader.a(parcel);
|
||||
int a2 = SafeParcelReader.a(a);
|
||||
if (a2 == 1) {
|
||||
i = SafeParcelReader.x(parcel, a);
|
||||
} else if (a2 != 2) {
|
||||
SafeParcelReader.C(parcel, a);
|
||||
} else {
|
||||
str = SafeParcelReader.n(parcel, a);
|
||||
}
|
||||
}
|
||||
SafeParcelReader.q(parcel, b);
|
||||
return new ClientIdentity(i, str);
|
||||
}
|
||||
|
||||
@Override // android.os.Parcelable.Creator
|
||||
public final /* synthetic */ ClientIdentity[] newArray(int i) {
|
||||
return new ClientIdentity[i];
|
||||
}
|
||||
}
|
25
sources/com/google/android/gms/common/internal/zac.java
Normal file
25
sources/com/google/android/gms/common/internal/zac.java
Normal file
@@ -0,0 +1,25 @@
|
||||
package com.google.android.gms.common.internal;
|
||||
|
||||
import android.app.Activity;
|
||||
import android.content.Intent;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
final class zac extends DialogRedirect {
|
||||
private final /* synthetic */ Intent a;
|
||||
private final /* synthetic */ Activity b;
|
||||
private final /* synthetic */ int c;
|
||||
|
||||
zac(Intent intent, Activity activity, int i) {
|
||||
this.a = intent;
|
||||
this.b = activity;
|
||||
this.c = i;
|
||||
}
|
||||
|
||||
@Override // com.google.android.gms.common.internal.DialogRedirect
|
||||
public final void a() {
|
||||
Intent intent = this.a;
|
||||
if (intent != null) {
|
||||
this.b.startActivityForResult(intent, this.c);
|
||||
}
|
||||
}
|
||||
}
|
25
sources/com/google/android/gms/common/internal/zad.java
Normal file
25
sources/com/google/android/gms/common/internal/zad.java
Normal file
@@ -0,0 +1,25 @@
|
||||
package com.google.android.gms.common.internal;
|
||||
|
||||
import android.content.Intent;
|
||||
import androidx.fragment.app.Fragment;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
final class zad extends DialogRedirect {
|
||||
private final /* synthetic */ Intent a;
|
||||
private final /* synthetic */ Fragment b;
|
||||
private final /* synthetic */ int c;
|
||||
|
||||
zad(Intent intent, Fragment fragment, int i) {
|
||||
this.a = intent;
|
||||
this.b = fragment;
|
||||
this.c = i;
|
||||
}
|
||||
|
||||
@Override // com.google.android.gms.common.internal.DialogRedirect
|
||||
public final void a() {
|
||||
Intent intent = this.a;
|
||||
if (intent != null) {
|
||||
this.b.startActivityForResult(intent, this.c);
|
||||
}
|
||||
}
|
||||
}
|
24
sources/com/google/android/gms/common/internal/zaf.java
Normal file
24
sources/com/google/android/gms/common/internal/zaf.java
Normal file
@@ -0,0 +1,24 @@
|
||||
package com.google.android.gms.common.internal;
|
||||
|
||||
import android.os.Bundle;
|
||||
import com.google.android.gms.common.api.GoogleApiClient$ConnectionCallbacks;
|
||||
import com.google.android.gms.common.internal.BaseGmsClient;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
final class zaf implements BaseGmsClient.BaseConnectionCallbacks {
|
||||
private final /* synthetic */ GoogleApiClient$ConnectionCallbacks a;
|
||||
|
||||
zaf(GoogleApiClient$ConnectionCallbacks googleApiClient$ConnectionCallbacks) {
|
||||
this.a = googleApiClient$ConnectionCallbacks;
|
||||
}
|
||||
|
||||
@Override // com.google.android.gms.common.internal.BaseGmsClient.BaseConnectionCallbacks
|
||||
public final void d(Bundle bundle) {
|
||||
this.a.d(bundle);
|
||||
}
|
||||
|
||||
@Override // com.google.android.gms.common.internal.BaseGmsClient.BaseConnectionCallbacks
|
||||
public final void i(int i) {
|
||||
this.a.i(i);
|
||||
}
|
||||
}
|
19
sources/com/google/android/gms/common/internal/zag.java
Normal file
19
sources/com/google/android/gms/common/internal/zag.java
Normal file
@@ -0,0 +1,19 @@
|
||||
package com.google.android.gms.common.internal;
|
||||
|
||||
import com.google.android.gms.common.ConnectionResult;
|
||||
import com.google.android.gms.common.api.GoogleApiClient$OnConnectionFailedListener;
|
||||
import com.google.android.gms.common.internal.BaseGmsClient;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
final class zag implements BaseGmsClient.BaseOnConnectionFailedListener {
|
||||
private final /* synthetic */ GoogleApiClient$OnConnectionFailedListener a;
|
||||
|
||||
zag(GoogleApiClient$OnConnectionFailedListener googleApiClient$OnConnectionFailedListener) {
|
||||
this.a = googleApiClient$OnConnectionFailedListener;
|
||||
}
|
||||
|
||||
@Override // com.google.android.gms.common.internal.BaseGmsClient.BaseOnConnectionFailedListener
|
||||
public final void a(ConnectionResult connectionResult) {
|
||||
this.a.a(connectionResult);
|
||||
}
|
||||
}
|
41
sources/com/google/android/gms/common/internal/zam.java
Normal file
41
sources/com/google/android/gms/common/internal/zam.java
Normal file
@@ -0,0 +1,41 @@
|
||||
package com.google.android.gms.common.internal;
|
||||
|
||||
import android.accounts.Account;
|
||||
import android.os.Parcel;
|
||||
import android.os.Parcelable;
|
||||
import com.google.android.gms.auth.api.signin.GoogleSignInAccount;
|
||||
import com.google.android.gms.common.internal.safeparcel.SafeParcelReader;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public final class zam implements Parcelable.Creator<ResolveAccountRequest> {
|
||||
@Override // android.os.Parcelable.Creator
|
||||
public final /* synthetic */ ResolveAccountRequest createFromParcel(Parcel parcel) {
|
||||
int b = SafeParcelReader.b(parcel);
|
||||
Account account = null;
|
||||
int i = 0;
|
||||
GoogleSignInAccount googleSignInAccount = null;
|
||||
int i2 = 0;
|
||||
while (parcel.dataPosition() < b) {
|
||||
int a = SafeParcelReader.a(parcel);
|
||||
int a2 = SafeParcelReader.a(a);
|
||||
if (a2 == 1) {
|
||||
i = SafeParcelReader.x(parcel, a);
|
||||
} else if (a2 == 2) {
|
||||
account = (Account) SafeParcelReader.a(parcel, a, Account.CREATOR);
|
||||
} else if (a2 == 3) {
|
||||
i2 = SafeParcelReader.x(parcel, a);
|
||||
} else if (a2 != 4) {
|
||||
SafeParcelReader.C(parcel, a);
|
||||
} else {
|
||||
googleSignInAccount = (GoogleSignInAccount) SafeParcelReader.a(parcel, a, GoogleSignInAccount.CREATOR);
|
||||
}
|
||||
}
|
||||
SafeParcelReader.q(parcel, b);
|
||||
return new ResolveAccountRequest(i, account, i2, googleSignInAccount);
|
||||
}
|
||||
|
||||
@Override // android.os.Parcelable.Creator
|
||||
public final /* synthetic */ ResolveAccountRequest[] newArray(int i) {
|
||||
return new ResolveAccountRequest[i];
|
||||
}
|
||||
}
|
44
sources/com/google/android/gms/common/internal/zan.java
Normal file
44
sources/com/google/android/gms/common/internal/zan.java
Normal file
@@ -0,0 +1,44 @@
|
||||
package com.google.android.gms.common.internal;
|
||||
|
||||
import android.os.IBinder;
|
||||
import android.os.Parcel;
|
||||
import android.os.Parcelable;
|
||||
import com.google.android.gms.common.ConnectionResult;
|
||||
import com.google.android.gms.common.internal.safeparcel.SafeParcelReader;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public final class zan implements Parcelable.Creator<ResolveAccountResponse> {
|
||||
@Override // android.os.Parcelable.Creator
|
||||
public final /* synthetic */ ResolveAccountResponse createFromParcel(Parcel parcel) {
|
||||
int b = SafeParcelReader.b(parcel);
|
||||
IBinder iBinder = null;
|
||||
ConnectionResult connectionResult = null;
|
||||
int i = 0;
|
||||
boolean z = false;
|
||||
boolean z2 = false;
|
||||
while (parcel.dataPosition() < b) {
|
||||
int a = SafeParcelReader.a(parcel);
|
||||
int a2 = SafeParcelReader.a(a);
|
||||
if (a2 == 1) {
|
||||
i = SafeParcelReader.x(parcel, a);
|
||||
} else if (a2 == 2) {
|
||||
iBinder = SafeParcelReader.w(parcel, a);
|
||||
} else if (a2 == 3) {
|
||||
connectionResult = (ConnectionResult) SafeParcelReader.a(parcel, a, ConnectionResult.CREATOR);
|
||||
} else if (a2 == 4) {
|
||||
z = SafeParcelReader.r(parcel, a);
|
||||
} else if (a2 != 5) {
|
||||
SafeParcelReader.C(parcel, a);
|
||||
} else {
|
||||
z2 = SafeParcelReader.r(parcel, a);
|
||||
}
|
||||
}
|
||||
SafeParcelReader.q(parcel, b);
|
||||
return new ResolveAccountResponse(i, iBinder, connectionResult, z, z2);
|
||||
}
|
||||
|
||||
@Override // android.os.Parcelable.Creator
|
||||
public final /* synthetic */ ResolveAccountResponse[] newArray(int i) {
|
||||
return new ResolveAccountResponse[i];
|
||||
}
|
||||
}
|
40
sources/com/google/android/gms/common/internal/zao.java
Normal file
40
sources/com/google/android/gms/common/internal/zao.java
Normal file
@@ -0,0 +1,40 @@
|
||||
package com.google.android.gms.common.internal;
|
||||
|
||||
import android.os.Parcel;
|
||||
import android.os.Parcelable;
|
||||
import com.google.android.gms.common.api.Scope;
|
||||
import com.google.android.gms.common.internal.safeparcel.SafeParcelReader;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public final class zao implements Parcelable.Creator<SignInButtonConfig> {
|
||||
@Override // android.os.Parcelable.Creator
|
||||
public final /* synthetic */ SignInButtonConfig createFromParcel(Parcel parcel) {
|
||||
int b = SafeParcelReader.b(parcel);
|
||||
int i = 0;
|
||||
Scope[] scopeArr = null;
|
||||
int i2 = 0;
|
||||
int i3 = 0;
|
||||
while (parcel.dataPosition() < b) {
|
||||
int a = SafeParcelReader.a(parcel);
|
||||
int a2 = SafeParcelReader.a(a);
|
||||
if (a2 == 1) {
|
||||
i = SafeParcelReader.x(parcel, a);
|
||||
} else if (a2 == 2) {
|
||||
i2 = SafeParcelReader.x(parcel, a);
|
||||
} else if (a2 == 3) {
|
||||
i3 = SafeParcelReader.x(parcel, a);
|
||||
} else if (a2 != 4) {
|
||||
SafeParcelReader.C(parcel, a);
|
||||
} else {
|
||||
scopeArr = (Scope[]) SafeParcelReader.b(parcel, a, Scope.CREATOR);
|
||||
}
|
||||
}
|
||||
SafeParcelReader.q(parcel, b);
|
||||
return new SignInButtonConfig(i, i2, i3, scopeArr);
|
||||
}
|
||||
|
||||
@Override // android.os.Parcelable.Creator
|
||||
public final /* synthetic */ SignInButtonConfig[] newArray(int i) {
|
||||
return new SignInButtonConfig[i];
|
||||
}
|
||||
}
|
20
sources/com/google/android/gms/common/internal/zza.java
Normal file
20
sources/com/google/android/gms/common/internal/zza.java
Normal file
@@ -0,0 +1,20 @@
|
||||
package com.google.android.gms.common.internal;
|
||||
|
||||
import android.os.Parcel;
|
||||
import android.os.Parcelable;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
final class zza implements Parcelable.Creator<BinderWrapper> {
|
||||
zza() {
|
||||
}
|
||||
|
||||
@Override // android.os.Parcelable.Creator
|
||||
public final /* synthetic */ BinderWrapper createFromParcel(Parcel parcel) {
|
||||
return new BinderWrapper(parcel, null);
|
||||
}
|
||||
|
||||
@Override // android.os.Parcelable.Creator
|
||||
public final /* synthetic */ BinderWrapper[] newArray(int i) {
|
||||
return new BinderWrapper[i];
|
||||
}
|
||||
}
|
31
sources/com/google/android/gms/common/internal/zzb.java
Normal file
31
sources/com/google/android/gms/common/internal/zzb.java
Normal file
@@ -0,0 +1,31 @@
|
||||
package com.google.android.gms.common.internal;
|
||||
|
||||
import android.os.Bundle;
|
||||
import android.os.Parcel;
|
||||
import android.os.Parcelable;
|
||||
import com.google.android.gms.common.Feature;
|
||||
import com.google.android.gms.common.internal.safeparcel.AbstractSafeParcelable;
|
||||
import com.google.android.gms.common.internal.safeparcel.SafeParcelWriter;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public final class zzb extends AbstractSafeParcelable {
|
||||
public static final Parcelable.Creator<zzb> CREATOR = new zzc();
|
||||
Bundle zzcz;
|
||||
Feature[] zzda;
|
||||
|
||||
zzb(Bundle bundle, Feature[] featureArr) {
|
||||
this.zzcz = bundle;
|
||||
this.zzda = featureArr;
|
||||
}
|
||||
|
||||
@Override // android.os.Parcelable
|
||||
public final void writeToParcel(Parcel parcel, int i) {
|
||||
int a = SafeParcelWriter.a(parcel);
|
||||
SafeParcelWriter.a(parcel, 1, this.zzcz, false);
|
||||
SafeParcelWriter.a(parcel, 2, (Parcelable[]) this.zzda, i, false);
|
||||
SafeParcelWriter.a(parcel, a);
|
||||
}
|
||||
|
||||
public zzb() {
|
||||
}
|
||||
}
|
35
sources/com/google/android/gms/common/internal/zzc.java
Normal file
35
sources/com/google/android/gms/common/internal/zzc.java
Normal file
@@ -0,0 +1,35 @@
|
||||
package com.google.android.gms.common.internal;
|
||||
|
||||
import android.os.Bundle;
|
||||
import android.os.Parcel;
|
||||
import android.os.Parcelable;
|
||||
import com.google.android.gms.common.Feature;
|
||||
import com.google.android.gms.common.internal.safeparcel.SafeParcelReader;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public final class zzc implements Parcelable.Creator<zzb> {
|
||||
@Override // android.os.Parcelable.Creator
|
||||
public final /* synthetic */ zzb createFromParcel(Parcel parcel) {
|
||||
int b = SafeParcelReader.b(parcel);
|
||||
Bundle bundle = null;
|
||||
Feature[] featureArr = null;
|
||||
while (parcel.dataPosition() < b) {
|
||||
int a = SafeParcelReader.a(parcel);
|
||||
int a2 = SafeParcelReader.a(a);
|
||||
if (a2 == 1) {
|
||||
bundle = SafeParcelReader.f(parcel, a);
|
||||
} else if (a2 != 2) {
|
||||
SafeParcelReader.C(parcel, a);
|
||||
} else {
|
||||
featureArr = (Feature[]) SafeParcelReader.b(parcel, a, Feature.CREATOR);
|
||||
}
|
||||
}
|
||||
SafeParcelReader.q(parcel, b);
|
||||
return new zzb(bundle, featureArr);
|
||||
}
|
||||
|
||||
@Override // android.os.Parcelable.Creator
|
||||
public final /* synthetic */ zzb[] newArray(int i) {
|
||||
return new zzb[i];
|
||||
}
|
||||
}
|
78
sources/com/google/android/gms/common/internal/zzd.java
Normal file
78
sources/com/google/android/gms/common/internal/zzd.java
Normal file
@@ -0,0 +1,78 @@
|
||||
package com.google.android.gms.common.internal;
|
||||
|
||||
import android.accounts.Account;
|
||||
import android.os.Bundle;
|
||||
import android.os.IBinder;
|
||||
import android.os.Parcel;
|
||||
import android.os.Parcelable;
|
||||
import com.google.android.gms.common.Feature;
|
||||
import com.google.android.gms.common.api.Scope;
|
||||
import com.google.android.gms.common.internal.safeparcel.SafeParcelReader;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public final class zzd implements Parcelable.Creator<GetServiceRequest> {
|
||||
@Override // android.os.Parcelable.Creator
|
||||
public final /* synthetic */ GetServiceRequest createFromParcel(Parcel parcel) {
|
||||
int b = SafeParcelReader.b(parcel);
|
||||
String str = null;
|
||||
IBinder iBinder = null;
|
||||
Scope[] scopeArr = null;
|
||||
Bundle bundle = null;
|
||||
Account account = null;
|
||||
Feature[] featureArr = null;
|
||||
Feature[] featureArr2 = null;
|
||||
int i = 0;
|
||||
int i2 = 0;
|
||||
int i3 = 0;
|
||||
boolean z = false;
|
||||
while (parcel.dataPosition() < b) {
|
||||
int a = SafeParcelReader.a(parcel);
|
||||
switch (SafeParcelReader.a(a)) {
|
||||
case 1:
|
||||
i = SafeParcelReader.x(parcel, a);
|
||||
break;
|
||||
case 2:
|
||||
i2 = SafeParcelReader.x(parcel, a);
|
||||
break;
|
||||
case 3:
|
||||
i3 = SafeParcelReader.x(parcel, a);
|
||||
break;
|
||||
case 4:
|
||||
str = SafeParcelReader.n(parcel, a);
|
||||
break;
|
||||
case 5:
|
||||
iBinder = SafeParcelReader.w(parcel, a);
|
||||
break;
|
||||
case 6:
|
||||
scopeArr = (Scope[]) SafeParcelReader.b(parcel, a, Scope.CREATOR);
|
||||
break;
|
||||
case 7:
|
||||
bundle = SafeParcelReader.f(parcel, a);
|
||||
break;
|
||||
case 8:
|
||||
account = (Account) SafeParcelReader.a(parcel, a, Account.CREATOR);
|
||||
break;
|
||||
case 9:
|
||||
default:
|
||||
SafeParcelReader.C(parcel, a);
|
||||
break;
|
||||
case 10:
|
||||
featureArr = (Feature[]) SafeParcelReader.b(parcel, a, Feature.CREATOR);
|
||||
break;
|
||||
case 11:
|
||||
featureArr2 = (Feature[]) SafeParcelReader.b(parcel, a, Feature.CREATOR);
|
||||
break;
|
||||
case 12:
|
||||
z = SafeParcelReader.r(parcel, a);
|
||||
break;
|
||||
}
|
||||
}
|
||||
SafeParcelReader.q(parcel, b);
|
||||
return new GetServiceRequest(i, i2, i3, str, iBinder, scopeArr, bundle, account, featureArr, featureArr2, z);
|
||||
}
|
||||
|
||||
@Override // android.os.Parcelable.Creator
|
||||
public final /* synthetic */ GetServiceRequest[] newArray(int i) {
|
||||
return new GetServiceRequest[i];
|
||||
}
|
||||
}
|
127
sources/com/google/android/gms/common/internal/zze.java
Normal file
127
sources/com/google/android/gms/common/internal/zze.java
Normal file
@@ -0,0 +1,127 @@
|
||||
package com.google.android.gms.common.internal;
|
||||
|
||||
import android.content.ComponentName;
|
||||
import android.content.Context;
|
||||
import android.content.ServiceConnection;
|
||||
import android.os.Handler;
|
||||
import android.os.Message;
|
||||
import android.util.Log;
|
||||
import com.google.android.gms.common.internal.GmsClientSupervisor;
|
||||
import com.google.android.gms.common.stats.ConnectionTracker;
|
||||
import com.ubt.jimu.diy.model.CategoryModel;
|
||||
import java.util.HashMap;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
final class zze extends GmsClientSupervisor implements Handler.Callback {
|
||||
private final Context d;
|
||||
private final Handler e;
|
||||
private final HashMap<GmsClientSupervisor.zza, zzf> c = new HashMap<>();
|
||||
private final ConnectionTracker f = ConnectionTracker.a();
|
||||
private final long g = 5000;
|
||||
private final long h = 300000;
|
||||
|
||||
zze(Context context) {
|
||||
this.d = context.getApplicationContext();
|
||||
this.e = new com.google.android.gms.internal.common.zze(context.getMainLooper(), this);
|
||||
}
|
||||
|
||||
@Override // com.google.android.gms.common.internal.GmsClientSupervisor
|
||||
protected final boolean a(GmsClientSupervisor.zza zzaVar, ServiceConnection serviceConnection, String str) {
|
||||
boolean d;
|
||||
Preconditions.a(serviceConnection, "ServiceConnection must not be null");
|
||||
synchronized (this.c) {
|
||||
zzf zzfVar = this.c.get(zzaVar);
|
||||
if (zzfVar == null) {
|
||||
zzfVar = new zzf(this, zzaVar);
|
||||
zzfVar.a(serviceConnection, str);
|
||||
zzfVar.a(str);
|
||||
this.c.put(zzaVar, zzfVar);
|
||||
} else {
|
||||
this.e.removeMessages(0, zzaVar);
|
||||
if (zzfVar.a(serviceConnection)) {
|
||||
String valueOf = String.valueOf(zzaVar);
|
||||
StringBuilder sb = new StringBuilder(String.valueOf(valueOf).length() + 81);
|
||||
sb.append("Trying to bind a GmsServiceConnection that was already connected before. config=");
|
||||
sb.append(valueOf);
|
||||
throw new IllegalStateException(sb.toString());
|
||||
}
|
||||
zzfVar.a(serviceConnection, str);
|
||||
int c = zzfVar.c();
|
||||
if (c == 1) {
|
||||
serviceConnection.onServiceConnected(zzfVar.b(), zzfVar.a());
|
||||
} else if (c == 2) {
|
||||
zzfVar.a(str);
|
||||
}
|
||||
}
|
||||
d = zzfVar.d();
|
||||
}
|
||||
return d;
|
||||
}
|
||||
|
||||
@Override // com.google.android.gms.common.internal.GmsClientSupervisor
|
||||
protected final void b(GmsClientSupervisor.zza zzaVar, ServiceConnection serviceConnection, String str) {
|
||||
Preconditions.a(serviceConnection, "ServiceConnection must not be null");
|
||||
synchronized (this.c) {
|
||||
zzf zzfVar = this.c.get(zzaVar);
|
||||
if (zzfVar == null) {
|
||||
String valueOf = String.valueOf(zzaVar);
|
||||
StringBuilder sb = new StringBuilder(String.valueOf(valueOf).length() + 50);
|
||||
sb.append("Nonexistent connection status for service config: ");
|
||||
sb.append(valueOf);
|
||||
throw new IllegalStateException(sb.toString());
|
||||
}
|
||||
if (!zzfVar.a(serviceConnection)) {
|
||||
String valueOf2 = String.valueOf(zzaVar);
|
||||
StringBuilder sb2 = new StringBuilder(String.valueOf(valueOf2).length() + 76);
|
||||
sb2.append("Trying to unbind a GmsServiceConnection that was not bound before. config=");
|
||||
sb2.append(valueOf2);
|
||||
throw new IllegalStateException(sb2.toString());
|
||||
}
|
||||
zzfVar.b(serviceConnection, str);
|
||||
if (zzfVar.e()) {
|
||||
this.e.sendMessageDelayed(this.e.obtainMessage(0, zzaVar), this.g);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@Override // android.os.Handler.Callback
|
||||
public final boolean handleMessage(Message message) {
|
||||
int i = message.what;
|
||||
if (i == 0) {
|
||||
synchronized (this.c) {
|
||||
GmsClientSupervisor.zza zzaVar = (GmsClientSupervisor.zza) message.obj;
|
||||
zzf zzfVar = this.c.get(zzaVar);
|
||||
if (zzfVar != null && zzfVar.e()) {
|
||||
if (zzfVar.d()) {
|
||||
zzfVar.b("GmsClientSupervisor");
|
||||
}
|
||||
this.c.remove(zzaVar);
|
||||
}
|
||||
}
|
||||
return true;
|
||||
}
|
||||
if (i != 1) {
|
||||
return false;
|
||||
}
|
||||
synchronized (this.c) {
|
||||
GmsClientSupervisor.zza zzaVar2 = (GmsClientSupervisor.zza) message.obj;
|
||||
zzf zzfVar2 = this.c.get(zzaVar2);
|
||||
if (zzfVar2 != null && zzfVar2.c() == 3) {
|
||||
String valueOf = String.valueOf(zzaVar2);
|
||||
StringBuilder sb = new StringBuilder(String.valueOf(valueOf).length() + 47);
|
||||
sb.append("Timeout waiting for ServiceConnection callback ");
|
||||
sb.append(valueOf);
|
||||
Log.wtf("GmsClientSupervisor", sb.toString(), new Exception());
|
||||
ComponentName b = zzfVar2.b();
|
||||
if (b == null) {
|
||||
b = zzaVar2.a();
|
||||
}
|
||||
if (b == null) {
|
||||
b = new ComponentName(zzaVar2.b(), CategoryModel.unknown);
|
||||
}
|
||||
zzfVar2.onServiceDisconnected(b);
|
||||
}
|
||||
}
|
||||
return true;
|
||||
}
|
||||
}
|
155
sources/com/google/android/gms/common/internal/zzf.java
Normal file
155
sources/com/google/android/gms/common/internal/zzf.java
Normal file
@@ -0,0 +1,155 @@
|
||||
package com.google.android.gms.common.internal;
|
||||
|
||||
import android.content.ComponentName;
|
||||
import android.content.Context;
|
||||
import android.content.ServiceConnection;
|
||||
import android.os.Handler;
|
||||
import android.os.IBinder;
|
||||
import android.os.Message;
|
||||
import com.google.android.gms.common.internal.GmsClientSupervisor;
|
||||
import com.google.android.gms.common.stats.ConnectionTracker;
|
||||
import java.util.HashMap;
|
||||
import java.util.HashSet;
|
||||
import java.util.Iterator;
|
||||
import java.util.Set;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
final class zzf implements ServiceConnection {
|
||||
private final Set<ServiceConnection> a = new HashSet();
|
||||
private int b = 2;
|
||||
private boolean c;
|
||||
private IBinder d;
|
||||
private final GmsClientSupervisor.zza e;
|
||||
private ComponentName f;
|
||||
private final /* synthetic */ zze g;
|
||||
|
||||
public zzf(zze zzeVar, GmsClientSupervisor.zza zzaVar) {
|
||||
this.g = zzeVar;
|
||||
this.e = zzaVar;
|
||||
}
|
||||
|
||||
public final void a(String str) {
|
||||
ConnectionTracker connectionTracker;
|
||||
Context context;
|
||||
Context context2;
|
||||
ConnectionTracker connectionTracker2;
|
||||
Context context3;
|
||||
Handler handler;
|
||||
Handler handler2;
|
||||
long j;
|
||||
this.b = 3;
|
||||
connectionTracker = this.g.f;
|
||||
context = this.g.d;
|
||||
GmsClientSupervisor.zza zzaVar = this.e;
|
||||
context2 = this.g.d;
|
||||
this.c = connectionTracker.a(context, str, zzaVar.a(context2), this, this.e.c());
|
||||
if (this.c) {
|
||||
handler = this.g.e;
|
||||
Message obtainMessage = handler.obtainMessage(1, this.e);
|
||||
handler2 = this.g.e;
|
||||
j = this.g.h;
|
||||
handler2.sendMessageDelayed(obtainMessage, j);
|
||||
return;
|
||||
}
|
||||
this.b = 2;
|
||||
try {
|
||||
connectionTracker2 = this.g.f;
|
||||
context3 = this.g.d;
|
||||
connectionTracker2.a(context3, this);
|
||||
} catch (IllegalArgumentException unused) {
|
||||
}
|
||||
}
|
||||
|
||||
public final void b(String str) {
|
||||
Handler handler;
|
||||
ConnectionTracker connectionTracker;
|
||||
Context context;
|
||||
handler = this.g.e;
|
||||
handler.removeMessages(1, this.e);
|
||||
connectionTracker = this.g.f;
|
||||
context = this.g.d;
|
||||
connectionTracker.a(context, this);
|
||||
this.c = false;
|
||||
this.b = 2;
|
||||
}
|
||||
|
||||
public final int c() {
|
||||
return this.b;
|
||||
}
|
||||
|
||||
public final boolean d() {
|
||||
return this.c;
|
||||
}
|
||||
|
||||
public final boolean e() {
|
||||
return this.a.isEmpty();
|
||||
}
|
||||
|
||||
@Override // android.content.ServiceConnection
|
||||
public final void onServiceConnected(ComponentName componentName, IBinder iBinder) {
|
||||
HashMap hashMap;
|
||||
Handler handler;
|
||||
hashMap = this.g.c;
|
||||
synchronized (hashMap) {
|
||||
handler = this.g.e;
|
||||
handler.removeMessages(1, this.e);
|
||||
this.d = iBinder;
|
||||
this.f = componentName;
|
||||
Iterator<ServiceConnection> it = this.a.iterator();
|
||||
while (it.hasNext()) {
|
||||
it.next().onServiceConnected(componentName, iBinder);
|
||||
}
|
||||
this.b = 1;
|
||||
}
|
||||
}
|
||||
|
||||
@Override // android.content.ServiceConnection
|
||||
public final void onServiceDisconnected(ComponentName componentName) {
|
||||
HashMap hashMap;
|
||||
Handler handler;
|
||||
hashMap = this.g.c;
|
||||
synchronized (hashMap) {
|
||||
handler = this.g.e;
|
||||
handler.removeMessages(1, this.e);
|
||||
this.d = null;
|
||||
this.f = componentName;
|
||||
Iterator<ServiceConnection> it = this.a.iterator();
|
||||
while (it.hasNext()) {
|
||||
it.next().onServiceDisconnected(componentName);
|
||||
}
|
||||
this.b = 2;
|
||||
}
|
||||
}
|
||||
|
||||
public final void b(ServiceConnection serviceConnection, String str) {
|
||||
ConnectionTracker unused;
|
||||
Context unused2;
|
||||
unused = this.g.f;
|
||||
unused2 = this.g.d;
|
||||
this.a.remove(serviceConnection);
|
||||
}
|
||||
|
||||
public final ComponentName b() {
|
||||
return this.f;
|
||||
}
|
||||
|
||||
public final void a(ServiceConnection serviceConnection, String str) {
|
||||
Context context;
|
||||
ConnectionTracker unused;
|
||||
Context unused2;
|
||||
unused = this.g.f;
|
||||
unused2 = this.g.d;
|
||||
GmsClientSupervisor.zza zzaVar = this.e;
|
||||
context = this.g.d;
|
||||
zzaVar.a(context);
|
||||
this.a.add(serviceConnection);
|
||||
}
|
||||
|
||||
public final boolean a(ServiceConnection serviceConnection) {
|
||||
return this.a.contains(serviceConnection);
|
||||
}
|
||||
|
||||
public final IBinder a() {
|
||||
return this.d;
|
||||
}
|
||||
}
|
38
sources/com/google/android/gms/common/internal/zzg.java
Normal file
38
sources/com/google/android/gms/common/internal/zzg.java
Normal file
@@ -0,0 +1,38 @@
|
||||
package com.google.android.gms.common.internal;
|
||||
|
||||
import android.content.Intent;
|
||||
import android.net.Uri;
|
||||
import android.text.TextUtils;
|
||||
import com.ubt.jimu.controller.data.widget.JockstickDataConverter;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public final class zzg {
|
||||
static {
|
||||
Uri.parse("https://plus.google.com/").buildUpon().appendPath("circles").appendPath("find").build();
|
||||
}
|
||||
|
||||
public static Intent a(String str) {
|
||||
Uri fromParts = Uri.fromParts("package", str, null);
|
||||
Intent intent = new Intent("android.settings.APPLICATION_DETAILS_SETTINGS");
|
||||
intent.setData(fromParts);
|
||||
return intent;
|
||||
}
|
||||
|
||||
public static Intent a(String str, String str2) {
|
||||
Intent intent = new Intent("android.intent.action.VIEW");
|
||||
Uri.Builder appendQueryParameter = Uri.parse("market://details").buildUpon().appendQueryParameter(JockstickDataConverter.ID, str);
|
||||
if (!TextUtils.isEmpty(str2)) {
|
||||
appendQueryParameter.appendQueryParameter("pcampaignid", str2);
|
||||
}
|
||||
intent.setData(appendQueryParameter.build());
|
||||
intent.setPackage("com.android.vending");
|
||||
intent.addFlags(524288);
|
||||
return intent;
|
||||
}
|
||||
|
||||
public static Intent a() {
|
||||
Intent intent = new Intent("com.google.android.clockwork.home.UPDATE_ANDROID_WEAR_ACTION");
|
||||
intent.setPackage("com.google.android.wearable.app");
|
||||
return intent;
|
||||
}
|
||||
}
|
25
sources/com/google/android/gms/common/internal/zzh.java
Normal file
25
sources/com/google/android/gms/common/internal/zzh.java
Normal file
@@ -0,0 +1,25 @@
|
||||
package com.google.android.gms.common.internal;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public final class zzh {
|
||||
private final String a;
|
||||
private final String b;
|
||||
private final int c = 129;
|
||||
|
||||
public zzh(String str, String str2, boolean z, int i) {
|
||||
this.b = str;
|
||||
this.a = str2;
|
||||
}
|
||||
|
||||
final String a() {
|
||||
return this.b;
|
||||
}
|
||||
|
||||
final int b() {
|
||||
return this.c;
|
||||
}
|
||||
|
||||
final String c() {
|
||||
return this.a;
|
||||
}
|
||||
}
|
12
sources/com/google/android/gms/common/internal/zzi.java
Normal file
12
sources/com/google/android/gms/common/internal/zzi.java
Normal file
@@ -0,0 +1,12 @@
|
||||
package com.google.android.gms.common.internal;
|
||||
|
||||
import android.os.IInterface;
|
||||
import android.os.RemoteException;
|
||||
import com.google.android.gms.dynamic.IObjectWrapper;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public interface zzi extends IInterface {
|
||||
IObjectWrapper h() throws RemoteException;
|
||||
|
||||
int zzc() throws RemoteException;
|
||||
}
|
39
sources/com/google/android/gms/common/internal/zzj.java
Normal file
39
sources/com/google/android/gms/common/internal/zzj.java
Normal file
@@ -0,0 +1,39 @@
|
||||
package com.google.android.gms.common.internal;
|
||||
|
||||
import android.os.IBinder;
|
||||
import android.os.IInterface;
|
||||
import android.os.Parcel;
|
||||
import android.os.RemoteException;
|
||||
import com.google.android.gms.dynamic.IObjectWrapper;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public abstract class zzj extends com.google.android.gms.internal.common.zzb implements zzi {
|
||||
public zzj() {
|
||||
super("com.google.android.gms.common.internal.ICertData");
|
||||
}
|
||||
|
||||
public static zzi a(IBinder iBinder) {
|
||||
if (iBinder == null) {
|
||||
return null;
|
||||
}
|
||||
IInterface queryLocalInterface = iBinder.queryLocalInterface("com.google.android.gms.common.internal.ICertData");
|
||||
return queryLocalInterface instanceof zzi ? (zzi) queryLocalInterface : new zzk(iBinder);
|
||||
}
|
||||
|
||||
@Override // com.google.android.gms.internal.common.zzb
|
||||
protected final boolean a(int i, Parcel parcel, Parcel parcel2, int i2) throws RemoteException {
|
||||
if (i == 1) {
|
||||
IObjectWrapper h = h();
|
||||
parcel2.writeNoException();
|
||||
com.google.android.gms.internal.common.zzc.a(parcel2, h);
|
||||
} else {
|
||||
if (i != 2) {
|
||||
return false;
|
||||
}
|
||||
int zzc = zzc();
|
||||
parcel2.writeNoException();
|
||||
parcel2.writeInt(zzc);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
}
|
29
sources/com/google/android/gms/common/internal/zzk.java
Normal file
29
sources/com/google/android/gms/common/internal/zzk.java
Normal file
@@ -0,0 +1,29 @@
|
||||
package com.google.android.gms.common.internal;
|
||||
|
||||
import android.os.IBinder;
|
||||
import android.os.Parcel;
|
||||
import android.os.RemoteException;
|
||||
import com.google.android.gms.dynamic.IObjectWrapper;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public final class zzk extends com.google.android.gms.internal.common.zza implements zzi {
|
||||
zzk(IBinder iBinder) {
|
||||
super(iBinder, "com.google.android.gms.common.internal.ICertData");
|
||||
}
|
||||
|
||||
@Override // com.google.android.gms.common.internal.zzi
|
||||
public final IObjectWrapper h() throws RemoteException {
|
||||
Parcel a = a(1, i());
|
||||
IObjectWrapper a2 = IObjectWrapper.Stub.a(a.readStrongBinder());
|
||||
a.recycle();
|
||||
return a2;
|
||||
}
|
||||
|
||||
@Override // com.google.android.gms.common.internal.zzi
|
||||
public final int zzc() throws RemoteException {
|
||||
Parcel a = a(2, i());
|
||||
int readInt = a.readInt();
|
||||
a.recycle();
|
||||
return readInt;
|
||||
}
|
||||
}
|
10
sources/com/google/android/gms/common/internal/zzm.java
Normal file
10
sources/com/google/android/gms/common/internal/zzm.java
Normal file
@@ -0,0 +1,10 @@
|
||||
package com.google.android.gms.common.internal;
|
||||
|
||||
import android.os.IInterface;
|
||||
import android.os.RemoteException;
|
||||
import com.google.android.gms.dynamic.IObjectWrapper;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public interface zzm extends IInterface {
|
||||
boolean a(com.google.android.gms.common.zzk zzkVar, IObjectWrapper iObjectWrapper) throws RemoteException;
|
||||
}
|
15
sources/com/google/android/gms/common/internal/zzn.java
Normal file
15
sources/com/google/android/gms/common/internal/zzn.java
Normal file
@@ -0,0 +1,15 @@
|
||||
package com.google.android.gms.common.internal;
|
||||
|
||||
import android.os.IBinder;
|
||||
import android.os.IInterface;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public abstract class zzn extends com.google.android.gms.internal.common.zzb implements zzm {
|
||||
public static zzm a(IBinder iBinder) {
|
||||
if (iBinder == null) {
|
||||
return null;
|
||||
}
|
||||
IInterface queryLocalInterface = iBinder.queryLocalInterface("com.google.android.gms.common.internal.IGoogleCertificatesApi");
|
||||
return queryLocalInterface instanceof zzm ? (zzm) queryLocalInterface : new zzo(iBinder);
|
||||
}
|
||||
}
|
24
sources/com/google/android/gms/common/internal/zzo.java
Normal file
24
sources/com/google/android/gms/common/internal/zzo.java
Normal file
@@ -0,0 +1,24 @@
|
||||
package com.google.android.gms.common.internal;
|
||||
|
||||
import android.os.IBinder;
|
||||
import android.os.Parcel;
|
||||
import android.os.RemoteException;
|
||||
import com.google.android.gms.dynamic.IObjectWrapper;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public final class zzo extends com.google.android.gms.internal.common.zza implements zzm {
|
||||
zzo(IBinder iBinder) {
|
||||
super(iBinder, "com.google.android.gms.common.internal.IGoogleCertificatesApi");
|
||||
}
|
||||
|
||||
@Override // com.google.android.gms.common.internal.zzm
|
||||
public final boolean a(com.google.android.gms.common.zzk zzkVar, IObjectWrapper iObjectWrapper) throws RemoteException {
|
||||
Parcel i = i();
|
||||
com.google.android.gms.internal.common.zzc.a(i, zzkVar);
|
||||
com.google.android.gms.internal.common.zzc.a(i, iObjectWrapper);
|
||||
Parcel a = a(5, i);
|
||||
boolean a2 = com.google.android.gms.internal.common.zzc.a(a);
|
||||
a.recycle();
|
||||
return a2;
|
||||
}
|
||||
}
|
46
sources/com/google/android/gms/common/internal/zzp.java
Normal file
46
sources/com/google/android/gms/common/internal/zzp.java
Normal file
@@ -0,0 +1,46 @@
|
||||
package com.google.android.gms.common.internal;
|
||||
|
||||
import android.content.Context;
|
||||
import android.content.pm.PackageManager;
|
||||
import android.os.Bundle;
|
||||
import android.util.Log;
|
||||
import com.google.android.gms.common.wrappers.Wrappers;
|
||||
import com.ubtrobot.jimu.robotapi.PeripheralType;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public final class zzp {
|
||||
private static Object a = new Object();
|
||||
private static boolean b;
|
||||
private static String c;
|
||||
private static int d;
|
||||
|
||||
public static String a(Context context) {
|
||||
c(context);
|
||||
return c;
|
||||
}
|
||||
|
||||
public static int b(Context context) {
|
||||
c(context);
|
||||
return d;
|
||||
}
|
||||
|
||||
private static void c(Context context) {
|
||||
Bundle bundle;
|
||||
synchronized (a) {
|
||||
if (b) {
|
||||
return;
|
||||
}
|
||||
b = true;
|
||||
try {
|
||||
bundle = Wrappers.a(context).a(context.getPackageName(), PeripheralType.SERVO).metaData;
|
||||
} catch (PackageManager.NameNotFoundException e) {
|
||||
Log.wtf("MetadataValueReader", "This should never happen.", e);
|
||||
}
|
||||
if (bundle == null) {
|
||||
return;
|
||||
}
|
||||
c = bundle.getString("com.google.app.id");
|
||||
d = bundle.getInt("com.google.android.gms.version");
|
||||
}
|
||||
}
|
||||
}
|
24
sources/com/google/android/gms/common/internal/zzr.java
Normal file
24
sources/com/google/android/gms/common/internal/zzr.java
Normal file
@@ -0,0 +1,24 @@
|
||||
package com.google.android.gms.common.internal;
|
||||
|
||||
import android.os.Parcel;
|
||||
import android.os.Parcelable;
|
||||
import com.google.android.gms.common.internal.safeparcel.AbstractSafeParcelable;
|
||||
import com.google.android.gms.common.internal.safeparcel.SafeParcelWriter;
|
||||
|
||||
@Deprecated
|
||||
/* loaded from: classes.dex */
|
||||
public final class zzr extends AbstractSafeParcelable {
|
||||
public static final Parcelable.Creator<zzr> CREATOR = new zzs();
|
||||
private final int zzg;
|
||||
|
||||
zzr(int i) {
|
||||
this.zzg = i;
|
||||
}
|
||||
|
||||
@Override // android.os.Parcelable
|
||||
public final void writeToParcel(Parcel parcel, int i) {
|
||||
int a = SafeParcelWriter.a(parcel);
|
||||
SafeParcelWriter.a(parcel, 1, this.zzg);
|
||||
SafeParcelWriter.a(parcel, a);
|
||||
}
|
||||
}
|
29
sources/com/google/android/gms/common/internal/zzs.java
Normal file
29
sources/com/google/android/gms/common/internal/zzs.java
Normal file
@@ -0,0 +1,29 @@
|
||||
package com.google.android.gms.common.internal;
|
||||
|
||||
import android.os.Parcel;
|
||||
import android.os.Parcelable;
|
||||
import com.google.android.gms.common.internal.safeparcel.SafeParcelReader;
|
||||
|
||||
/* loaded from: classes.dex */
|
||||
public final class zzs implements Parcelable.Creator<zzr> {
|
||||
@Override // android.os.Parcelable.Creator
|
||||
public final /* synthetic */ zzr createFromParcel(Parcel parcel) {
|
||||
int b = SafeParcelReader.b(parcel);
|
||||
int i = 0;
|
||||
while (parcel.dataPosition() < b) {
|
||||
int a = SafeParcelReader.a(parcel);
|
||||
if (SafeParcelReader.a(a) != 1) {
|
||||
SafeParcelReader.C(parcel, a);
|
||||
} else {
|
||||
i = SafeParcelReader.x(parcel, a);
|
||||
}
|
||||
}
|
||||
SafeParcelReader.q(parcel, b);
|
||||
return new zzr(i);
|
||||
}
|
||||
|
||||
@Override // android.os.Parcelable.Creator
|
||||
public final /* synthetic */ zzr[] newArray(int i) {
|
||||
return new zzr[i];
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user