47 lines
1.4 KiB
Java
47 lines
1.4 KiB
Java
package c.i.a.f.c.a.f.b;
|
|
|
|
import android.content.Context;
|
|
import android.util.Log;
|
|
import androidx.loader.content.AsyncTaskLoader;
|
|
import c.i.a.f.e.h.c;
|
|
import java.util.Iterator;
|
|
import java.util.Objects;
|
|
import java.util.Set;
|
|
import java.util.concurrent.Semaphore;
|
|
import java.util.concurrent.TimeUnit;
|
|
/* compiled from: com.google.android.gms:play-services-auth@@19.0.0 */
|
|
public final class d extends AsyncTaskLoader<Void> {
|
|
public Semaphore a = new Semaphore(0);
|
|
public Set<c> b;
|
|
|
|
public d(Context context, Set<c> set) {
|
|
super(context);
|
|
this.b = set;
|
|
}
|
|
|
|
/* Return type fixed from 'java.lang.Object' to match base method */
|
|
@Override // androidx.loader.content.AsyncTaskLoader
|
|
public final Void loadInBackground() {
|
|
Iterator<c> it = this.b.iterator();
|
|
if (!it.hasNext()) {
|
|
try {
|
|
this.a.tryAcquire(0, 5, TimeUnit.SECONDS);
|
|
return null;
|
|
} catch (InterruptedException e) {
|
|
Log.i("GACSignInLoader", "Unexpected InterruptedException", e);
|
|
Thread.currentThread().interrupt();
|
|
return null;
|
|
}
|
|
} else {
|
|
Objects.requireNonNull(it.next());
|
|
throw new UnsupportedOperationException();
|
|
}
|
|
}
|
|
|
|
@Override // androidx.loader.content.Loader
|
|
public final void onStartLoading() {
|
|
this.a.drainPermits();
|
|
forceLoad();
|
|
}
|
|
}
|