109 lines
3.2 KiB
Java
109 lines
3.2 KiB
Java
package com.google.android.gms.common.api;
|
|
|
|
import android.accounts.Account;
|
|
import android.content.Context;
|
|
import android.os.IBinder;
|
|
import android.os.IInterface;
|
|
import android.os.Looper;
|
|
import com.google.android.gms.auth.api.signin.GoogleSignInAccount;
|
|
import com.google.android.gms.common.Feature;
|
|
import com.google.android.gms.common.api.Api.ApiOptions;
|
|
import com.google.android.gms.common.internal.BaseGmsClient;
|
|
import com.google.android.gms.common.internal.ClientSettings;
|
|
import com.google.android.gms.common.internal.IAccountAccessor;
|
|
import com.google.android.gms.common.internal.Preconditions;
|
|
import java.util.Set;
|
|
|
|
/* loaded from: classes.dex */
|
|
public final class Api<O extends ApiOptions> {
|
|
private final AbstractClientBuilder<?, O> a;
|
|
private final String b;
|
|
|
|
public static abstract class AbstractClientBuilder<T extends Client, O> extends BaseClientBuilder<T, O> {
|
|
public abstract T a(Context context, Looper looper, ClientSettings clientSettings, O o, GoogleApiClient$ConnectionCallbacks googleApiClient$ConnectionCallbacks, GoogleApiClient$OnConnectionFailedListener googleApiClient$OnConnectionFailedListener);
|
|
}
|
|
|
|
public interface AnyClient {
|
|
}
|
|
|
|
public static class AnyClientKey<C extends AnyClient> {
|
|
}
|
|
|
|
public interface ApiOptions {
|
|
|
|
public interface HasAccountOptions extends HasOptions, NotRequiredOptions {
|
|
Account a();
|
|
}
|
|
|
|
public interface HasGoogleSignInAccountOptions extends HasOptions {
|
|
GoogleSignInAccount b();
|
|
}
|
|
|
|
public interface HasOptions extends ApiOptions {
|
|
}
|
|
|
|
public interface NotRequiredOptions extends ApiOptions {
|
|
}
|
|
|
|
public interface Optional extends HasOptions, NotRequiredOptions {
|
|
}
|
|
}
|
|
|
|
public static abstract class BaseClientBuilder<T extends AnyClient, O> {
|
|
}
|
|
|
|
public interface Client extends AnyClient {
|
|
void a();
|
|
|
|
void a(BaseGmsClient.ConnectionProgressReportCallbacks connectionProgressReportCallbacks);
|
|
|
|
void a(BaseGmsClient.SignOutCallbacks signOutCallbacks);
|
|
|
|
void a(IAccountAccessor iAccountAccessor, Set<Scope> set);
|
|
|
|
boolean b();
|
|
|
|
boolean d();
|
|
|
|
String e();
|
|
|
|
boolean f();
|
|
|
|
int g();
|
|
|
|
Feature[] h();
|
|
|
|
boolean i();
|
|
}
|
|
|
|
public static final class ClientKey<C extends Client> extends AnyClientKey<C> {
|
|
}
|
|
|
|
public interface SimpleClient<T extends IInterface> extends AnyClient {
|
|
T a(IBinder iBinder);
|
|
|
|
void a(int i, T t);
|
|
|
|
String j();
|
|
|
|
String k();
|
|
}
|
|
|
|
/* JADX WARN: Multi-variable type inference failed */
|
|
public <C extends Client> Api(String str, AbstractClientBuilder<C, O> abstractClientBuilder, ClientKey<C> clientKey) {
|
|
Preconditions.a(abstractClientBuilder, "Cannot construct an Api with a null ClientBuilder");
|
|
Preconditions.a(clientKey, "Cannot construct an Api with a null ClientKey");
|
|
this.b = str;
|
|
this.a = abstractClientBuilder;
|
|
}
|
|
|
|
public final String a() {
|
|
return this.b;
|
|
}
|
|
|
|
public final AbstractClientBuilder<?, O> b() {
|
|
Preconditions.b(this.a != null, "This API was constructed with a SimpleClientBuilder. Use getSimpleClientBuilder");
|
|
return this.a;
|
|
}
|
|
}
|