2021-08-03 07:33:18 +00:00
|
|
|
package i0;
|
|
|
|
|
|
|
|
import i0.e;
|
|
|
|
import java.io.IOException;
|
|
|
|
import java.lang.annotation.Annotation;
|
|
|
|
import java.lang.reflect.ParameterizedType;
|
|
|
|
import java.lang.reflect.Type;
|
|
|
|
import java.util.concurrent.Executor;
|
2021-08-10 21:19:22 +00:00
|
|
|
import okhttp3.Request;
|
2021-08-03 07:33:18 +00:00
|
|
|
import retrofit2.Response;
|
|
|
|
/* compiled from: DefaultCallAdapterFactory */
|
|
|
|
public final class i extends e.a {
|
|
|
|
public final Executor a;
|
|
|
|
|
|
|
|
/* compiled from: DefaultCallAdapterFactory */
|
|
|
|
public class a implements e<Object, d<?>> {
|
|
|
|
public final /* synthetic */ Type a;
|
|
|
|
public final /* synthetic */ Executor b;
|
|
|
|
|
|
|
|
public a(i iVar, Type type, Executor executor) {
|
|
|
|
this.a = type;
|
|
|
|
this.b = executor;
|
|
|
|
}
|
|
|
|
|
|
|
|
@Override // i0.e
|
|
|
|
public Type a() {
|
|
|
|
return this.a;
|
|
|
|
}
|
|
|
|
|
|
|
|
/* Return type fixed from 'java.lang.Object' to match base method */
|
|
|
|
/* JADX DEBUG: Method arguments types fixed to match base method, original types: [i0.d] */
|
|
|
|
@Override // i0.e
|
|
|
|
public d<?> b(d<Object> dVar) {
|
|
|
|
Executor executor = this.b;
|
|
|
|
return executor == null ? dVar : new b(executor, dVar);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
/* compiled from: DefaultCallAdapterFactory */
|
|
|
|
public static final class b<T> implements d<T> {
|
|
|
|
public final Executor i;
|
|
|
|
public final d<T> j;
|
|
|
|
|
|
|
|
/* compiled from: DefaultCallAdapterFactory */
|
|
|
|
public class a implements f<T> {
|
|
|
|
public final /* synthetic */ f a;
|
|
|
|
|
|
|
|
public a(f fVar) {
|
|
|
|
this.a = fVar;
|
|
|
|
}
|
|
|
|
|
|
|
|
@Override // i0.f
|
|
|
|
public void a(d<T> dVar, Throwable th) {
|
|
|
|
b.this.i.execute(new a(this, this.a, th));
|
|
|
|
}
|
|
|
|
|
|
|
|
@Override // i0.f
|
|
|
|
public void b(d<T> dVar, Response<T> response) {
|
|
|
|
b.this.i.execute(new b(this, this.a, response));
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
public b(Executor executor, d<T> dVar) {
|
|
|
|
this.i = executor;
|
|
|
|
this.j = dVar;
|
|
|
|
}
|
|
|
|
|
|
|
|
@Override // i0.d
|
|
|
|
public void B(f<T> fVar) {
|
|
|
|
this.j.B(new a(fVar));
|
|
|
|
}
|
|
|
|
|
|
|
|
@Override // i0.d
|
|
|
|
/* renamed from: K */
|
|
|
|
public d<T> clone() {
|
|
|
|
return new b(this.i, this.j.K());
|
|
|
|
}
|
|
|
|
|
|
|
|
@Override // i0.d
|
2021-08-10 21:19:22 +00:00
|
|
|
public Request c() {
|
2021-08-03 07:33:18 +00:00
|
|
|
return this.j.c();
|
|
|
|
}
|
|
|
|
|
|
|
|
@Override // i0.d
|
|
|
|
public void cancel() {
|
|
|
|
this.j.cancel();
|
|
|
|
}
|
|
|
|
|
|
|
|
@Override // i0.d
|
|
|
|
public boolean d() {
|
|
|
|
return this.j.d();
|
|
|
|
}
|
|
|
|
|
|
|
|
@Override // i0.d
|
|
|
|
public Response<T> execute() throws IOException {
|
|
|
|
return this.j.execute();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
public i(Executor executor) {
|
|
|
|
this.a = executor;
|
|
|
|
}
|
|
|
|
|
|
|
|
@Override // i0.e.a
|
|
|
|
public e<?, ?> a(Type type, Annotation[] annotationArr, y yVar) {
|
|
|
|
Executor executor = null;
|
|
|
|
if (c0.f(type) != d.class) {
|
|
|
|
return null;
|
|
|
|
}
|
|
|
|
if (type instanceof ParameterizedType) {
|
|
|
|
Type e = c0.e(0, (ParameterizedType) type);
|
|
|
|
if (!c0.i(annotationArr, a0.class)) {
|
|
|
|
executor = this.a;
|
|
|
|
}
|
|
|
|
return new a(this, e, executor);
|
|
|
|
}
|
|
|
|
throw new IllegalArgumentException("Call return type must be parameterized as Call<Foo> or Call<? extends Foo>");
|
|
|
|
}
|
|
|
|
}
|