discord-jadx/app/src/main/java/g0/d.java

68 lines
1.5 KiB
Java
Raw Normal View History

2021-11-08 18:25:28 +00:00
package g0;
2021-12-21 23:37:30 +00:00
import b.d.b.a.a;
2021-11-08 18:25:28 +00:00
import d0.z.d.m;
import java.io.IOException;
/* compiled from: AsyncTimeout.kt */
2022-03-02 20:59:20 +00:00
/* loaded from: classes3.dex */
2021-11-08 18:25:28 +00:00
public final class d implements x {
2021-12-17 22:03:14 +00:00
public final /* synthetic */ b j;
public final /* synthetic */ x k;
2021-11-08 18:25:28 +00:00
public d(b bVar, x xVar) {
2021-12-17 22:03:14 +00:00
this.j = bVar;
this.k = xVar;
2021-11-08 18:25:28 +00:00
}
@Override // g0.x, java.io.Closeable, java.lang.AutoCloseable
public void close() {
2021-12-17 22:03:14 +00:00
b bVar = this.j;
2021-11-08 18:25:28 +00:00
bVar.i();
try {
2021-12-17 22:03:14 +00:00
this.k.close();
2021-11-08 18:25:28 +00:00
if (bVar.j()) {
throw bVar.k(null);
}
} catch (IOException e) {
2022-03-02 20:59:20 +00:00
if (bVar.j()) {
throw bVar.k(e);
2021-11-08 18:25:28 +00:00
}
} finally {
bVar.j();
}
}
@Override // g0.x
public long i0(e eVar, long j) {
m.checkParameterIsNotNull(eVar, "sink");
2021-12-17 22:03:14 +00:00
b bVar = this.j;
2021-11-08 18:25:28 +00:00
bVar.i();
try {
2021-12-17 22:03:14 +00:00
long i02 = this.k.i0(eVar, j);
2021-11-08 18:25:28 +00:00
if (!bVar.j()) {
return i02;
}
throw bVar.k(null);
} catch (IOException e) {
if (!bVar.j()) {
throw e;
}
throw bVar.k(e);
} finally {
bVar.j();
}
}
@Override // g0.x
public y timeout() {
2021-12-17 22:03:14 +00:00
return this.j;
2021-11-08 18:25:28 +00:00
}
public String toString() {
2022-03-30 16:43:10 +00:00
StringBuilder R = a.R("AsyncTimeout.source(");
R.append(this.k);
R.append(')');
return R.toString();
2021-11-08 18:25:28 +00:00
}
}