Initial import of ADIF API reverse-engineering toolkit

This commit is contained in:
2025-12-16 08:37:56 +01:00
commit 60388529c1
11486 changed files with 1086536 additions and 0 deletions

View File

@@ -0,0 +1,129 @@
package r3;
import kotlin.jvm.internal.Intrinsics;
/* loaded from: classes3.dex */
public final class A implements I {
/* renamed from: a, reason: collision with root package name */
public final InterfaceC0578j f8236a;
/* renamed from: b, reason: collision with root package name */
public final C0576h f8237b;
/* renamed from: c, reason: collision with root package name */
public D f8238c;
/* renamed from: d, reason: collision with root package name */
public int f8239d;
/* renamed from: e, reason: collision with root package name */
public boolean f8240e;
/* renamed from: f, reason: collision with root package name */
public long f8241f;
public A(InterfaceC0578j upstream) {
Intrinsics.checkNotNullParameter(upstream, "upstream");
this.f8236a = upstream;
C0576h a2 = upstream.a();
this.f8237b = a2;
D d4 = a2.f8283a;
this.f8238c = d4;
this.f8239d = d4 != null ? d4.f8249b : -1;
}
@Override // java.io.Closeable, java.lang.AutoCloseable
public final void close() {
this.f8240e = true;
}
/* JADX WARN: Code restructure failed: missing block: B:10:0x0020, code lost:
if (r3 == r5.f8249b) goto L15;
*/
@Override // r3.I
/*
Code decompiled incorrectly, please refer to instructions dump.
To view partially-correct add '--show-bad-code' argument
*/
public final long read(r3.C0576h r9, long r10) {
/*
r8 = this;
java.lang.String r0 = "sink"
kotlin.jvm.internal.Intrinsics.checkNotNullParameter(r9, r0)
r0 = 0
int r2 = (r10 > r0 ? 1 : (r10 == r0 ? 0 : -1))
if (r2 < 0) goto L6e
boolean r3 = r8.f8240e
if (r3 != 0) goto L66
r3.D r3 = r8.f8238c
r3.h r4 = r8.f8237b
if (r3 == 0) goto L2b
r3.D r5 = r4.f8283a
if (r3 != r5) goto L23
int r3 = r8.f8239d
kotlin.jvm.internal.Intrinsics.checkNotNull(r5)
int r5 = r5.f8249b
if (r3 != r5) goto L23
goto L2b
L23:
java.lang.IllegalStateException r8 = new java.lang.IllegalStateException
java.lang.String r9 = "Peek source is invalid because upstream source was used"
r8.<init>(r9)
throw r8
L2b:
if (r2 != 0) goto L2e
return r0
L2e:
long r0 = r8.f8241f
r2 = 1
long r0 = r0 + r2
r3.j r2 = r8.f8236a
boolean r0 = r2.n(r0)
if (r0 != 0) goto L3e
r8 = -1
return r8
L3e:
r3.D r0 = r8.f8238c
if (r0 != 0) goto L4f
r3.D r0 = r4.f8283a
if (r0 == 0) goto L4f
r8.f8238c = r0
kotlin.jvm.internal.Intrinsics.checkNotNull(r0)
int r0 = r0.f8249b
r8.f8239d = r0
L4f:
long r0 = r4.f8284b
long r2 = r8.f8241f
long r0 = r0 - r2
long r6 = java.lang.Math.min(r10, r0)
r3.h r2 = r8.f8237b
long r4 = r8.f8241f
r3 = r9
r2.s(r3, r4, r6)
long r9 = r8.f8241f
long r9 = r9 + r6
r8.f8241f = r9
return r6
L66:
java.lang.IllegalStateException r8 = new java.lang.IllegalStateException
java.lang.String r9 = "closed"
r8.<init>(r9)
throw r8
L6e:
java.lang.String r8 = "byteCount < 0: "
java.lang.String r8 = C.w.l(r8, r10)
java.lang.IllegalArgumentException r9 = new java.lang.IllegalArgumentException
java.lang.String r8 = r8.toString()
r9.<init>(r8)
throw r9
*/
throw new UnsupportedOperationException("Method not decompiled: r3.A.read(r3.h, long):long");
}
@Override // r3.I
public final K timeout() {
return this.f8236a.timeout();
}
}

View File

@@ -0,0 +1,17 @@
package r3;
import f0.C0338b;
/* renamed from: r3.a, reason: case insensitive filesystem */
/* loaded from: classes3.dex */
public abstract class AbstractC0569a {
/* renamed from: a, reason: collision with root package name */
public static final byte[] f8269a;
static {
C0579k c0579k = C0579k.f8285d;
f8269a = C0338b.n("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/").f8286a;
C0338b.n("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_");
}
}

View File

@@ -0,0 +1,230 @@
package r3;
import java.nio.ByteBuffer;
import kotlin.jvm.internal.Intrinsics;
/* loaded from: classes3.dex */
public final class B implements InterfaceC0577i {
/* renamed from: a, reason: collision with root package name */
public final G f8242a;
/* renamed from: b, reason: collision with root package name */
public final C0576h f8243b;
/* renamed from: c, reason: collision with root package name */
public boolean f8244c;
/* JADX WARN: Type inference failed for: r2v1, types: [java.lang.Object, r3.h] */
public B(G sink) {
Intrinsics.checkNotNullParameter(sink, "sink");
this.f8242a = sink;
this.f8243b = new Object();
}
@Override // r3.InterfaceC0577i
public final long D(I source) {
Intrinsics.checkNotNullParameter(source, "source");
long j4 = 0;
while (true) {
long read = ((C0572d) source).read(this.f8243b, 8192L);
if (read == -1) {
return j4;
}
j4 += read;
d();
}
}
@Override // r3.InterfaceC0577i
public final InterfaceC0577i E(byte[] source) {
Intrinsics.checkNotNullParameter(source, "source");
if (this.f8244c) {
throw new IllegalStateException("closed");
}
C0576h c0576h = this.f8243b;
Intrinsics.checkNotNullParameter(source, "source");
c0576h.i0(source, 0, source.length);
d();
return this;
}
@Override // r3.InterfaceC0577i
public final InterfaceC0577i F(C0579k byteString) {
Intrinsics.checkNotNullParameter(byteString, "byteString");
if (this.f8244c) {
throw new IllegalStateException("closed");
}
this.f8243b.h0(byteString);
d();
return this;
}
@Override // r3.InterfaceC0577i
public final InterfaceC0577i L(int i, int i4, byte[] source) {
Intrinsics.checkNotNullParameter(source, "source");
if (this.f8244c) {
throw new IllegalStateException("closed");
}
this.f8243b.i0(source, i, i4);
d();
return this;
}
@Override // r3.InterfaceC0577i
public final InterfaceC0577i Q(String string) {
Intrinsics.checkNotNullParameter(string, "string");
if (this.f8244c) {
throw new IllegalStateException("closed");
}
this.f8243b.o0(string);
d();
return this;
}
@Override // r3.InterfaceC0577i
public final InterfaceC0577i R(long j4) {
if (this.f8244c) {
throw new IllegalStateException("closed");
}
this.f8243b.k0(j4);
d();
return this;
}
@Override // r3.InterfaceC0577i
public final C0576h a() {
return this.f8243b;
}
@Override // r3.G, java.io.Closeable, java.lang.AutoCloseable
public final void close() {
G g4 = this.f8242a;
if (this.f8244c) {
return;
}
try {
C0576h c0576h = this.f8243b;
long j4 = c0576h.f8284b;
if (j4 > 0) {
g4.z(c0576h, j4);
}
th = null;
} catch (Throwable th) {
th = th;
}
try {
g4.close();
} catch (Throwable th2) {
if (th == null) {
th = th2;
}
}
this.f8244c = true;
if (th != null) {
throw th;
}
}
public final InterfaceC0577i d() {
if (this.f8244c) {
throw new IllegalStateException("closed");
}
C0576h c0576h = this.f8243b;
long e4 = c0576h.e();
if (e4 > 0) {
this.f8242a.z(c0576h, e4);
}
return this;
}
@Override // r3.InterfaceC0577i
public final InterfaceC0577i f(String string, int i, int i4) {
Intrinsics.checkNotNullParameter(string, "string");
if (this.f8244c) {
throw new IllegalStateException("closed");
}
this.f8243b.p0(string, i, i4);
d();
return this;
}
@Override // r3.InterfaceC0577i, r3.G, java.io.Flushable
public final void flush() {
if (this.f8244c) {
throw new IllegalStateException("closed");
}
C0576h c0576h = this.f8243b;
long j4 = c0576h.f8284b;
G g4 = this.f8242a;
if (j4 > 0) {
g4.z(c0576h, j4);
}
g4.flush();
}
@Override // java.nio.channels.Channel
public final boolean isOpen() {
return !this.f8244c;
}
@Override // r3.InterfaceC0577i
public final InterfaceC0577i m(int i) {
if (this.f8244c) {
throw new IllegalStateException("closed");
}
this.f8243b.n0(i);
d();
return this;
}
@Override // r3.InterfaceC0577i
public final InterfaceC0577i r(int i) {
if (this.f8244c) {
throw new IllegalStateException("closed");
}
this.f8243b.m0(i);
d();
return this;
}
@Override // r3.G
public final K timeout() {
return this.f8242a.timeout();
}
public final String toString() {
return "buffer(" + this.f8242a + ')';
}
@Override // java.nio.channels.WritableByteChannel
public final int write(ByteBuffer source) {
Intrinsics.checkNotNullParameter(source, "source");
if (this.f8244c) {
throw new IllegalStateException("closed");
}
int write = this.f8243b.write(source);
d();
return write;
}
@Override // r3.InterfaceC0577i
public final InterfaceC0577i y(int i) {
if (this.f8244c) {
throw new IllegalStateException("closed");
}
this.f8243b.j0(i);
d();
return this;
}
@Override // r3.G
public final void z(C0576h source, long j4) {
Intrinsics.checkNotNullParameter(source, "source");
if (this.f8244c) {
throw new IllegalStateException("closed");
}
this.f8243b.z(source, j4);
d();
}
}

View File

@@ -0,0 +1,420 @@
package r3;
import a.AbstractC0105a;
import java.io.EOFException;
import java.io.InputStream;
import java.nio.ByteBuffer;
import java.nio.charset.Charset;
import kotlin.KotlinVersion;
import kotlin.jvm.internal.Intrinsics;
import kotlin.jvm.internal.LongCompanionObject;
import kotlin.text.Charsets;
import kotlin.text.Typography;
/* loaded from: classes3.dex */
public final class C implements InterfaceC0578j {
/* renamed from: a, reason: collision with root package name */
public final I f8245a;
/* renamed from: b, reason: collision with root package name */
public final C0576h f8246b;
/* renamed from: c, reason: collision with root package name */
public boolean f8247c;
/* JADX WARN: Type inference failed for: r2v1, types: [java.lang.Object, r3.h] */
public C(I source) {
Intrinsics.checkNotNullParameter(source, "source");
this.f8245a = source;
this.f8246b = new Object();
}
@Override // r3.InterfaceC0578j
public final long A(C0579k targetBytes) {
Intrinsics.checkNotNullParameter(targetBytes, "targetBytes");
Intrinsics.checkNotNullParameter(targetBytes, "targetBytes");
if (this.f8247c) {
throw new IllegalStateException("closed");
}
long j4 = 0;
while (true) {
C0576h c0576h = this.f8246b;
long Z = c0576h.Z(targetBytes, j4);
if (Z != -1) {
return Z;
}
long j5 = c0576h.f8284b;
if (this.f8245a.read(c0576h, 8192L) == -1) {
return -1L;
}
j4 = Math.max(j4, j5);
}
}
@Override // r3.InterfaceC0578j
public final int C(x options) {
Intrinsics.checkNotNullParameter(options, "options");
if (this.f8247c) {
throw new IllegalStateException("closed");
}
while (true) {
C0576h c0576h = this.f8246b;
int c4 = s3.a.c(c0576h, options, true);
if (c4 != -2) {
if (c4 != -1) {
c0576h.l(options.f8317a[c4].d());
return c4;
}
} else if (this.f8245a.read(c0576h, 8192L) == -1) {
break;
}
}
return -1;
}
@Override // r3.InterfaceC0578j
public final boolean H(C0579k bytes) {
int i;
Intrinsics.checkNotNullParameter(bytes, "bytes");
int d4 = bytes.d();
Intrinsics.checkNotNullParameter(bytes, "bytes");
if (this.f8247c) {
throw new IllegalStateException("closed");
}
if (d4 >= 0 && bytes.d() >= d4) {
for (0; i < d4; i + 1) {
long j4 = i;
i = (n(1 + j4) && this.f8246b.O(j4) == bytes.i(i)) ? i + 1 : 0;
}
return true;
}
return false;
}
@Override // r3.InterfaceC0578j
public final C M() {
return AbstractC0105a.d(new A(this));
}
public final long O() {
char c4;
char c5;
char c6;
char c7;
long j4;
P(8L);
C0576h c0576h = this.f8246b;
if (c0576h.f8284b < 8) {
throw new EOFException();
}
D d4 = c0576h.f8283a;
Intrinsics.checkNotNull(d4);
int i = d4.f8249b;
int i4 = d4.f8250c;
if (i4 - i < 8) {
j4 = ((c0576h.readInt() & 4294967295L) << 32) | (4294967295L & c0576h.readInt());
c6 = '(';
c7 = '8';
c4 = '\b';
c5 = 24;
} else {
byte[] bArr = d4.f8248a;
c4 = '\b';
c5 = 24;
c6 = '(';
c7 = '8';
int i5 = i + 7;
long j5 = ((bArr[i] & 255) << 56) | ((bArr[i + 1] & 255) << 48) | ((bArr[i + 2] & 255) << 40) | ((bArr[i + 3] & 255) << 32) | ((bArr[i + 4] & 255) << 24) | ((bArr[i + 5] & 255) << 16) | ((bArr[i + 6] & 255) << 8);
int i6 = i + 8;
long j6 = j5 | (bArr[i5] & 255);
c0576h.f8284b -= 8;
if (i6 == i4) {
c0576h.f8283a = d4.a();
E.a(d4);
} else {
d4.f8249b = i6;
}
j4 = j6;
}
return ((j4 & 255) << c7) | (((-72057594037927936L) & j4) >>> c7) | ((71776119061217280L & j4) >>> c6) | ((280375465082880L & j4) >>> c5) | ((1095216660480L & j4) >>> c4) | ((4278190080L & j4) << c4) | ((16711680 & j4) << c5) | ((65280 & j4) << c6);
}
@Override // r3.InterfaceC0578j
public final void P(long j4) {
if (!n(j4)) {
throw new EOFException();
}
}
@Override // r3.InterfaceC0578j
public final long U(InterfaceC0577i sink) {
C0576h c0576h;
Intrinsics.checkNotNullParameter(sink, "sink");
long j4 = 0;
while (true) {
c0576h = this.f8246b;
if (this.f8245a.read(c0576h, 8192L) == -1) {
break;
}
long e4 = c0576h.e();
if (e4 > 0) {
j4 += e4;
sink.z(c0576h, e4);
}
}
long j5 = c0576h.f8284b;
if (j5 <= 0) {
return j4;
}
long j6 = j4 + j5;
sink.z(c0576h, j5);
return j6;
}
@Override // r3.InterfaceC0578j
public final String W(Charset charset) {
Intrinsics.checkNotNullParameter(charset, "charset");
I i = this.f8245a;
C0576h c0576h = this.f8246b;
c0576h.D(i);
return c0576h.W(charset);
}
@Override // r3.InterfaceC0578j
public final InputStream X() {
return new C0575g(this, 1);
}
public final short Y() {
P(2L);
return this.f8246b.c0();
}
public final String Z(long j4) {
P(j4);
C0576h c0576h = this.f8246b;
c0576h.getClass();
return c0576h.d0(j4, Charsets.UTF_8);
}
@Override // r3.InterfaceC0578j
public final C0576h a() {
return this.f8246b;
}
/* JADX WARN: Multi-variable type inference failed */
/* JADX WARN: Type inference failed for: r13v0, types: [java.lang.Object, r3.h] */
public final String a0(long j4) {
if (j4 < 0) {
throw new IllegalArgumentException(C.w.l("limit < 0: ", j4).toString());
}
long j5 = j4 == LongCompanionObject.MAX_VALUE ? Long.MAX_VALUE : j4 + 1;
long e4 = e((byte) 10, 0L, j5);
C0576h c0576h = this.f8246b;
if (e4 != -1) {
return s3.a.b(c0576h, e4);
}
if (j5 < LongCompanionObject.MAX_VALUE && n(j5) && c0576h.O(j5 - 1) == 13 && n(j5 + 1) && c0576h.O(j5) == 10) {
return s3.a.b(c0576h, j5);
}
?? obj = new Object();
c0576h.s(obj, 0L, Math.min(32, c0576h.f8284b));
throw new EOFException("\\n not found: limit=" + Math.min(c0576h.f8284b, j4) + " content=" + obj.h(obj.f8284b).e() + Typography.ellipsis);
}
@Override // java.io.Closeable, java.lang.AutoCloseable, java.nio.channels.Channel
public final void close() {
if (this.f8247c) {
return;
}
this.f8247c = true;
this.f8245a.close();
this.f8246b.d();
}
public final boolean d() {
if (this.f8247c) {
throw new IllegalStateException("closed");
}
C0576h c0576h = this.f8246b;
return c0576h.x() && this.f8245a.read(c0576h, 8192L) == -1;
}
/* JADX WARN: Removed duplicated region for block: B:20:0x00eb */
/* JADX WARN: Removed duplicated region for block: B:30:0x00ea A[SYNTHETIC] */
/*
Code decompiled incorrectly, please refer to instructions dump.
To view partially-correct add '--show-bad-code' argument
*/
public final long e(byte r21, long r22, long r24) {
/*
Method dump skipped, instructions count: 329
To view this dump add '--comments-level debug' option
*/
throw new UnsupportedOperationException("Method not decompiled: r3.C.e(byte, long, long):long");
}
@Override // r3.InterfaceC0578j
public final C0579k g() {
I i = this.f8245a;
C0576h c0576h = this.f8246b;
c0576h.D(i);
return c0576h.h(c0576h.f8284b);
}
@Override // r3.InterfaceC0578j
public final C0579k h(long j4) {
P(j4);
return this.f8246b.h(j4);
}
@Override // java.nio.channels.Channel
public final boolean isOpen() {
return !this.f8247c;
}
@Override // r3.InterfaceC0578j
public final void l(long j4) {
if (this.f8247c) {
throw new IllegalStateException("closed");
}
while (j4 > 0) {
C0576h c0576h = this.f8246b;
if (c0576h.f8284b == 0 && this.f8245a.read(c0576h, 8192L) == -1) {
throw new EOFException();
}
long min = Math.min(j4, c0576h.f8284b);
c0576h.l(min);
j4 -= min;
}
}
@Override // r3.InterfaceC0578j
public final boolean n(long j4) {
C0576h c0576h;
if (j4 < 0) {
throw new IllegalArgumentException(C.w.l("byteCount < 0: ", j4).toString());
}
if (this.f8247c) {
throw new IllegalStateException("closed");
}
do {
c0576h = this.f8246b;
if (c0576h.f8284b >= j4) {
return true;
}
} while (this.f8245a.read(c0576h, 8192L) != -1);
return false;
}
@Override // java.nio.channels.ReadableByteChannel
public final int read(ByteBuffer sink) {
Intrinsics.checkNotNullParameter(sink, "sink");
C0576h c0576h = this.f8246b;
if (c0576h.f8284b == 0 && this.f8245a.read(c0576h, 8192L) == -1) {
return -1;
}
return c0576h.read(sink);
}
@Override // r3.InterfaceC0578j
public final byte readByte() {
P(1L);
return this.f8246b.readByte();
}
@Override // r3.InterfaceC0578j
public final int readInt() {
P(4L);
return this.f8246b.readInt();
}
@Override // r3.InterfaceC0578j
public final short readShort() {
P(2L);
return this.f8246b.readShort();
}
/* JADX WARN: Code restructure failed: missing block: B:52:0x0122, code lost:
r14.f8284b -= r0;
*/
/* JADX WARN: Code restructure failed: missing block: B:53:0x0128, code lost:
return r9;
*/
/* JADX WARN: Type inference failed for: r0v7, types: [java.lang.Object, r3.h] */
/*
Code decompiled incorrectly, please refer to instructions dump.
To view partially-correct add '--show-bad-code' argument
*/
public final long s() {
/*
Method dump skipped, instructions count: 303
To view this dump add '--comments-level debug' option
*/
throw new UnsupportedOperationException("Method not decompiled: r3.C.s():long");
}
@Override // r3.I
public final K timeout() {
return this.f8245a.timeout();
}
public final String toString() {
return "buffer(" + this.f8245a + ')';
}
@Override // r3.InterfaceC0578j
public final long u(C0579k bytes) {
Intrinsics.checkNotNullParameter(bytes, "bytes");
Intrinsics.checkNotNullParameter(bytes, "bytes");
if (this.f8247c) {
throw new IllegalStateException("closed");
}
long j4 = 0;
while (true) {
C0576h c0576h = this.f8246b;
long Y3 = c0576h.Y(bytes, j4);
if (Y3 != -1) {
return Y3;
}
long j5 = c0576h.f8284b;
if (this.f8245a.read(c0576h, 8192L) == -1) {
return -1L;
}
j4 = Math.max(j4, (j5 - bytes.f8286a.length) + 1);
}
}
@Override // r3.InterfaceC0578j
public final byte[] w() {
I i = this.f8245a;
C0576h c0576h = this.f8246b;
c0576h.D(i);
return c0576h.b0(c0576h.f8284b);
}
public final int x() {
P(4L);
int readInt = this.f8246b.readInt();
return ((readInt & KotlinVersion.MAX_COMPONENT_VALUE) << 24) | (((-16777216) & readInt) >>> 24) | ((16711680 & readInt) >>> 8) | ((65280 & readInt) << 8);
}
@Override // r3.I
public final long read(C0576h sink, long j4) {
Intrinsics.checkNotNullParameter(sink, "sink");
if (j4 >= 0) {
if (!this.f8247c) {
C0576h c0576h = this.f8246b;
if (c0576h.f8284b == 0 && this.f8245a.read(c0576h, 8192L) == -1) {
return -1L;
}
return c0576h.read(sink, Math.min(j4, c0576h.f8284b));
}
throw new IllegalStateException("closed");
}
throw new IllegalArgumentException(C.w.l("byteCount < 0: ", j4).toString());
}
}

View File

@@ -0,0 +1,35 @@
package r3;
import java.util.concurrent.locks.ReentrantLock;
import kotlin.Unit;
/* renamed from: r3.b, reason: case insensitive filesystem */
/* loaded from: classes3.dex */
public final class C0570b extends Thread {
@Override // java.lang.Thread, java.lang.Runnable
public final void run() {
ReentrantLock reentrantLock;
C0573e d4;
while (true) {
try {
reentrantLock = C0573e.h;
reentrantLock.lock();
try {
d4 = m3.l.d();
} finally {
reentrantLock.unlock();
}
} catch (InterruptedException unused) {
}
if (d4 == C0573e.f8277l) {
C0573e.f8277l = null;
return;
}
Unit unit = Unit.INSTANCE;
reentrantLock.unlock();
if (d4 != null) {
d4.j();
}
}
}
}

View File

@@ -0,0 +1,120 @@
package r3;
import java.io.IOException;
import kotlin.Unit;
import kotlin.jvm.internal.Intrinsics;
/* renamed from: r3.c, reason: case insensitive filesystem */
/* loaded from: classes3.dex */
public final class C0571c implements G {
/* renamed from: a, reason: collision with root package name */
public final /* synthetic */ H f8270a;
/* renamed from: b, reason: collision with root package name */
public final /* synthetic */ y f8271b;
public C0571c(H h, y yVar) {
this.f8270a = h;
this.f8271b = yVar;
}
@Override // r3.G, java.io.Closeable, java.lang.AutoCloseable
public final void close() {
y yVar = this.f8271b;
H h = this.f8270a;
h.h();
try {
yVar.close();
Unit unit = Unit.INSTANCE;
if (h.i()) {
throw h.k(null);
}
} catch (IOException e4) {
if (!h.i()) {
throw e4;
}
throw h.k(e4);
} finally {
h.i();
}
}
@Override // r3.G, java.io.Flushable
public final void flush() {
y yVar = this.f8271b;
H h = this.f8270a;
h.h();
try {
yVar.flush();
Unit unit = Unit.INSTANCE;
if (h.i()) {
throw h.k(null);
}
} catch (IOException e4) {
if (!h.i()) {
throw e4;
}
throw h.k(e4);
} finally {
h.i();
}
}
@Override // r3.G
public final K timeout() {
return this.f8270a;
}
public final String toString() {
return "AsyncTimeout.sink(" + this.f8271b + ')';
}
@Override // r3.G
public final void z(C0576h source, long j4) {
Intrinsics.checkNotNullParameter(source, "source");
m3.d.j(source.f8284b, 0L, j4);
while (true) {
long j5 = 0;
if (j4 <= 0) {
return;
}
D d4 = source.f8283a;
Intrinsics.checkNotNull(d4);
while (true) {
if (j5 >= 65536) {
break;
}
j5 += d4.f8250c - d4.f8249b;
if (j5 >= j4) {
j5 = j4;
break;
} else {
d4 = d4.f8253f;
Intrinsics.checkNotNull(d4);
}
}
y yVar = this.f8271b;
H h = this.f8270a;
h.h();
try {
try {
yVar.z(source, j5);
Unit unit = Unit.INSTANCE;
if (h.i()) {
throw h.k(null);
}
j4 -= j5;
} catch (IOException e4) {
if (!h.i()) {
throw e4;
}
throw h.k(e4);
}
} catch (Throwable th) {
h.i();
throw th;
}
}
}
}

View File

@@ -0,0 +1,135 @@
package r3;
import a.AbstractC0105a;
import java.io.IOException;
import java.io.InputStream;
import kotlin.Unit;
import kotlin.jvm.internal.Intrinsics;
/* renamed from: r3.d, reason: case insensitive filesystem */
/* loaded from: classes3.dex */
public final class C0572d implements I {
/* renamed from: a, reason: collision with root package name */
public final /* synthetic */ int f8272a = 1;
/* renamed from: b, reason: collision with root package name */
public final Object f8273b;
/* renamed from: c, reason: collision with root package name */
public final Object f8274c;
public C0572d(InputStream input, K timeout) {
Intrinsics.checkNotNullParameter(input, "input");
Intrinsics.checkNotNullParameter(timeout, "timeout");
this.f8273b = input;
this.f8274c = timeout;
}
@Override // java.io.Closeable, java.lang.AutoCloseable
public final void close() {
Object obj = this.f8273b;
switch (this.f8272a) {
case 0:
C0572d c0572d = (C0572d) this.f8274c;
H h = (H) obj;
h.h();
try {
c0572d.close();
Unit unit = Unit.INSTANCE;
if (h.i()) {
throw h.k(null);
}
return;
} catch (IOException e4) {
if (!h.i()) {
throw e4;
}
throw h.k(e4);
} finally {
h.i();
}
default:
((InputStream) obj).close();
return;
}
}
@Override // r3.I
public final long read(C0576h sink, long j4) {
switch (this.f8272a) {
case 0:
Intrinsics.checkNotNullParameter(sink, "sink");
C0572d c0572d = (C0572d) this.f8274c;
H h = (H) this.f8273b;
h.h();
try {
long read = c0572d.read(sink, j4);
if (h.i()) {
throw h.k(null);
}
return read;
} catch (IOException e4) {
if (h.i()) {
throw h.k(e4);
}
throw e4;
} finally {
h.i();
}
default:
Intrinsics.checkNotNullParameter(sink, "sink");
if (j4 == 0) {
return 0L;
}
if (j4 < 0) {
throw new IllegalArgumentException(C.w.l("byteCount < 0: ", j4).toString());
}
try {
((K) this.f8274c).f();
D g02 = sink.g0(1);
int read2 = ((InputStream) this.f8273b).read(g02.f8248a, g02.f8250c, (int) Math.min(j4, 8192 - g02.f8250c));
if (read2 == -1) {
if (g02.f8249b == g02.f8250c) {
sink.f8283a = g02.a();
E.a(g02);
}
return -1L;
}
g02.f8250c += read2;
long j5 = read2;
sink.f8284b += j5;
return j5;
} catch (AssertionError e5) {
if (AbstractC0105a.E(e5)) {
throw new IOException(e5);
}
throw e5;
}
}
}
@Override // r3.I
public final K timeout() {
switch (this.f8272a) {
case 0:
return (H) this.f8273b;
default:
return (K) this.f8274c;
}
}
public final String toString() {
switch (this.f8272a) {
case 0:
return "AsyncTimeout.source(" + ((C0572d) this.f8274c) + ')';
default:
return "source(" + ((InputStream) this.f8273b) + ')';
}
}
public C0572d(H h, C0572d c0572d) {
this.f8273b = h;
this.f8274c = c0572d;
}
}

View File

@@ -0,0 +1,129 @@
package r3;
import java.util.concurrent.TimeUnit;
import java.util.concurrent.locks.Condition;
import java.util.concurrent.locks.ReentrantLock;
import kotlin.Unit;
import kotlin.jvm.internal.Intrinsics;
/* renamed from: r3.e, reason: case insensitive filesystem */
/* loaded from: classes3.dex */
public class C0573e extends K {
public static final ReentrantLock h;
public static final Condition i;
/* renamed from: j, reason: collision with root package name */
public static final long f8275j;
/* renamed from: k, reason: collision with root package name */
public static final long f8276k;
/* renamed from: l, reason: collision with root package name */
public static C0573e f8277l;
/* renamed from: e, reason: collision with root package name */
public boolean f8278e;
/* renamed from: f, reason: collision with root package name */
public C0573e f8279f;
/* renamed from: g, reason: collision with root package name */
public long f8280g;
static {
ReentrantLock reentrantLock = new ReentrantLock();
h = reentrantLock;
Condition newCondition = reentrantLock.newCondition();
Intrinsics.checkNotNullExpressionValue(newCondition, "newCondition(...)");
i = newCondition;
long millis = TimeUnit.SECONDS.toMillis(60L);
f8275j = millis;
f8276k = TimeUnit.MILLISECONDS.toNanos(millis);
}
/* JADX WARN: Type inference failed for: r6v1, types: [java.lang.Object, r3.e] */
public final void h() {
long j4 = this.f8264c;
boolean z3 = this.f8262a;
if (j4 != 0 || z3) {
ReentrantLock reentrantLock = h;
reentrantLock.lock();
try {
if (this.f8278e) {
throw new IllegalStateException("Unbalanced enter/exit");
}
this.f8278e = true;
if (f8277l == null) {
f8277l = new Object();
Thread thread = new Thread("Okio Watchdog");
thread.setDaemon(true);
thread.start();
}
long nanoTime = System.nanoTime();
if (j4 != 0 && z3) {
this.f8280g = Math.min(j4, c() - nanoTime) + nanoTime;
} else if (j4 != 0) {
this.f8280g = j4 + nanoTime;
} else {
if (!z3) {
throw new AssertionError();
}
this.f8280g = c();
}
long j5 = this.f8280g - nanoTime;
C0573e c0573e = f8277l;
Intrinsics.checkNotNull(c0573e);
while (true) {
C0573e c0573e2 = c0573e.f8279f;
if (c0573e2 == null) {
break;
}
Intrinsics.checkNotNull(c0573e2);
if (j5 < c0573e2.f8280g - nanoTime) {
break;
}
c0573e = c0573e.f8279f;
Intrinsics.checkNotNull(c0573e);
}
this.f8279f = c0573e.f8279f;
c0573e.f8279f = this;
if (c0573e == f8277l) {
i.signal();
}
Unit unit = Unit.INSTANCE;
reentrantLock.unlock();
} catch (Throwable th) {
reentrantLock.unlock();
throw th;
}
}
}
public final boolean i() {
ReentrantLock reentrantLock = h;
reentrantLock.lock();
try {
if (!this.f8278e) {
return false;
}
this.f8278e = false;
C0573e c0573e = f8277l;
while (c0573e != null) {
C0573e c0573e2 = c0573e.f8279f;
if (c0573e2 == this) {
c0573e.f8279f = this.f8279f;
this.f8279f = null;
return false;
}
c0573e = c0573e2;
}
reentrantLock.unlock();
return true;
} finally {
reentrantLock.unlock();
}
}
public void j() {
}
}

View File

@@ -0,0 +1,26 @@
package r3;
import kotlin.jvm.internal.Intrinsics;
/* renamed from: r3.f, reason: case insensitive filesystem */
/* loaded from: classes3.dex */
public final class C0574f implements G {
@Override // r3.G, java.io.Closeable, java.lang.AutoCloseable
public final void close() {
}
@Override // r3.G, java.io.Flushable
public final void flush() {
}
@Override // r3.G
public final K timeout() {
return K.f8261d;
}
@Override // r3.G
public final void z(C0576h source, long j4) {
Intrinsics.checkNotNullParameter(source, "source");
source.l(j4);
}
}

View File

@@ -0,0 +1,102 @@
package r3;
import java.io.IOException;
import java.io.InputStream;
import kotlin.UByte;
import kotlin.jvm.internal.Intrinsics;
/* renamed from: r3.g, reason: case insensitive filesystem */
/* loaded from: classes3.dex */
public final class C0575g extends InputStream {
/* renamed from: a, reason: collision with root package name */
public final /* synthetic */ int f8281a;
/* renamed from: b, reason: collision with root package name */
public final /* synthetic */ InterfaceC0578j f8282b;
public /* synthetic */ C0575g(InterfaceC0578j interfaceC0578j, int i) {
this.f8281a = i;
this.f8282b = interfaceC0578j;
}
private final void d() {
}
@Override // java.io.InputStream
public final int available() {
switch (this.f8281a) {
case 0:
return (int) Math.min(((C0576h) this.f8282b).f8284b, Integer.MAX_VALUE);
default:
C c4 = (C) this.f8282b;
if (c4.f8247c) {
throw new IOException("closed");
}
return (int) Math.min(c4.f8246b.f8284b, Integer.MAX_VALUE);
}
}
@Override // java.io.InputStream, java.io.Closeable, java.lang.AutoCloseable
public final void close() {
switch (this.f8281a) {
case 0:
return;
default:
((C) this.f8282b).close();
return;
}
}
@Override // java.io.InputStream
public final int read() {
switch (this.f8281a) {
case 0:
C0576h c0576h = (C0576h) this.f8282b;
if (c0576h.f8284b > 0) {
return c0576h.readByte() & UByte.MAX_VALUE;
}
return -1;
default:
C c4 = (C) this.f8282b;
if (!c4.f8247c) {
C0576h c0576h2 = c4.f8246b;
if (c0576h2.f8284b == 0 && c4.f8245a.read(c0576h2, 8192L) == -1) {
return -1;
}
return c0576h2.readByte() & UByte.MAX_VALUE;
}
throw new IOException("closed");
}
}
public final String toString() {
switch (this.f8281a) {
case 0:
return ((C0576h) this.f8282b) + ".inputStream()";
default:
return ((C) this.f8282b) + ".inputStream()";
}
}
@Override // java.io.InputStream
public final int read(byte[] sink, int i, int i4) {
switch (this.f8281a) {
case 0:
Intrinsics.checkNotNullParameter(sink, "sink");
return ((C0576h) this.f8282b).a0(sink, i, i4);
default:
Intrinsics.checkNotNullParameter(sink, "data");
C c4 = (C) this.f8282b;
if (!c4.f8247c) {
m3.d.j(sink.length, i, i4);
C0576h c0576h = c4.f8246b;
if (c0576h.f8284b == 0 && c4.f8245a.read(c0576h, 8192L) == -1) {
return -1;
}
return c0576h.a0(sink, i, i4);
}
throw new IOException("closed");
}
}
}

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,358 @@
package r3;
import java.io.Serializable;
import java.security.MessageDigest;
import java.util.Arrays;
import kotlin.UByte;
import kotlin.collections.ArraysKt;
import kotlin.io.encoding.Base64;
import kotlin.jvm.internal.Intrinsics;
import kotlin.text.Charsets;
import kotlin.text.StringsKt;
/* renamed from: r3.k */
/* loaded from: classes3.dex */
public class C0579k implements Serializable, Comparable {
/* renamed from: d */
public static final C0579k f8285d = new C0579k(new byte[0]);
/* renamed from: a */
public final byte[] f8286a;
/* renamed from: b */
public transient int f8287b;
/* renamed from: c */
public transient String f8288c;
public C0579k(byte[] data) {
Intrinsics.checkNotNullParameter(data, "data");
this.f8286a = data;
}
public static int g(C0579k c0579k, C0579k other) {
c0579k.getClass();
Intrinsics.checkNotNullParameter(other, "other");
return c0579k.f(0, other.f8286a);
}
public static int k(C0579k c0579k, C0579k other) {
c0579k.getClass();
Intrinsics.checkNotNullParameter(other, "other");
return c0579k.j(other.f8286a);
}
public static /* synthetic */ C0579k o(C0579k c0579k, int i, int i4, int i5) {
if ((i5 & 1) != 0) {
i = 0;
}
if ((i5 & 2) != 0) {
i4 = -1234567890;
}
return c0579k.n(i, i4);
}
public String a() {
byte[] map = AbstractC0569a.f8269a;
byte[] bArr = this.f8286a;
Intrinsics.checkNotNullParameter(bArr, "<this>");
Intrinsics.checkNotNullParameter(map, "map");
byte[] bArr2 = new byte[((bArr.length + 2) / 3) * 4];
int length = bArr.length - (bArr.length % 3);
int i = 0;
int i4 = 0;
while (i < length) {
byte b4 = bArr[i];
int i5 = i + 2;
byte b5 = bArr[i + 1];
i += 3;
byte b6 = bArr[i5];
bArr2[i4] = map[(b4 & UByte.MAX_VALUE) >> 2];
bArr2[i4 + 1] = map[((b4 & 3) << 4) | ((b5 & UByte.MAX_VALUE) >> 4)];
int i6 = i4 + 3;
bArr2[i4 + 2] = map[((b5 & 15) << 2) | ((b6 & UByte.MAX_VALUE) >> 6)];
i4 += 4;
bArr2[i6] = map[b6 & 63];
}
int length2 = bArr.length - length;
if (length2 == 1) {
byte b7 = bArr[i];
bArr2[i4] = map[(b7 & UByte.MAX_VALUE) >> 2];
bArr2[i4 + 1] = map[(b7 & 3) << 4];
bArr2[i4 + 2] = Base64.padSymbol;
bArr2[i4 + 3] = Base64.padSymbol;
} else if (length2 == 2) {
int i7 = i + 1;
byte b8 = bArr[i];
byte b9 = bArr[i7];
bArr2[i4] = map[(b8 & UByte.MAX_VALUE) >> 2];
bArr2[i4 + 1] = map[((b8 & 3) << 4) | ((b9 & UByte.MAX_VALUE) >> 4)];
bArr2[i4 + 2] = map[(b9 & 15) << 2];
bArr2[i4 + 3] = Base64.padSymbol;
}
Intrinsics.checkNotNullParameter(bArr2, "<this>");
return new String(bArr2, Charsets.UTF_8);
}
@Override // java.lang.Comparable
/* renamed from: b */
public final int compareTo(C0579k other) {
Intrinsics.checkNotNullParameter(other, "other");
int d4 = d();
int d5 = other.d();
int min = Math.min(d4, d5);
for (int i = 0; i < min; i++) {
int i4 = i(i) & UByte.MAX_VALUE;
int i5 = other.i(i) & UByte.MAX_VALUE;
if (i4 != i5) {
return i4 < i5 ? -1 : 1;
}
}
if (d4 == d5) {
return 0;
}
return d4 < d5 ? -1 : 1;
}
public C0579k c(String algorithm) {
Intrinsics.checkNotNullParameter(algorithm, "algorithm");
MessageDigest messageDigest = MessageDigest.getInstance(algorithm);
messageDigest.update(this.f8286a, 0, d());
byte[] digest = messageDigest.digest();
Intrinsics.checkNotNull(digest);
return new C0579k(digest);
}
public int d() {
return this.f8286a.length;
}
public String e() {
byte[] bArr = this.f8286a;
char[] cArr = new char[bArr.length * 2];
int i = 0;
for (byte b4 : bArr) {
int i4 = i + 1;
char[] cArr2 = s3.b.f8473a;
cArr[i] = cArr2[(b4 >> 4) & 15];
i += 2;
cArr[i4] = cArr2[b4 & 15];
}
return StringsKt.concatToString(cArr);
}
public boolean equals(Object obj) {
if (obj == this) {
return true;
}
if (obj instanceof C0579k) {
C0579k c0579k = (C0579k) obj;
int d4 = c0579k.d();
byte[] bArr = this.f8286a;
if (d4 == bArr.length && c0579k.m(0, bArr, 0, bArr.length)) {
return true;
}
}
return false;
}
public int f(int i, byte[] other) {
Intrinsics.checkNotNullParameter(other, "other");
byte[] bArr = this.f8286a;
int length = bArr.length - other.length;
int max = Math.max(i, 0);
if (max > length) {
return -1;
}
while (!m3.d.c(bArr, other, max, 0, other.length)) {
if (max == length) {
return -1;
}
max++;
}
return max;
}
public byte[] h() {
return this.f8286a;
}
public int hashCode() {
int i = this.f8287b;
if (i != 0) {
return i;
}
int hashCode = Arrays.hashCode(this.f8286a);
this.f8287b = hashCode;
return hashCode;
}
public byte i(int i) {
return this.f8286a[i];
}
public int j(byte[] other) {
Intrinsics.checkNotNullParameter(other, "other");
Intrinsics.checkNotNullParameter(this, "<this>");
int d4 = d();
byte[] bArr = this.f8286a;
for (int min = Math.min(d4, bArr.length - other.length); -1 < min; min--) {
if (m3.d.c(bArr, other, min, 0, other.length)) {
return min;
}
}
return -1;
}
public boolean l(int i, C0579k other, int i4) {
Intrinsics.checkNotNullParameter(other, "other");
return other.m(0, this.f8286a, i, i4);
}
public boolean m(int i, byte[] other, int i4, int i5) {
Intrinsics.checkNotNullParameter(other, "other");
if (i < 0) {
return false;
}
byte[] bArr = this.f8286a;
return i <= bArr.length - i5 && i4 >= 0 && i4 <= other.length - i5 && m3.d.c(bArr, other, i, i4, i5);
}
public C0579k n(int i, int i4) {
Intrinsics.checkNotNullParameter(this, "<this>");
if (i4 == -1234567890) {
i4 = d();
}
if (i < 0) {
throw new IllegalArgumentException("beginIndex < 0");
}
byte[] bArr = this.f8286a;
if (i4 > bArr.length) {
throw new IllegalArgumentException(C.w.p(new StringBuilder("endIndex > length("), bArr.length, ')').toString());
}
if (i4 - i >= 0) {
return (i == 0 && i4 == bArr.length) ? this : new C0579k(ArraysKt.copyOfRange(bArr, i, i4));
}
throw new IllegalArgumentException("endIndex < beginIndex");
}
public C0579k p() {
int i = 0;
while (true) {
byte[] bArr = this.f8286a;
if (i >= bArr.length) {
return this;
}
byte b4 = bArr[i];
if (b4 >= 65 && b4 <= 90) {
byte[] copyOf = Arrays.copyOf(bArr, bArr.length);
Intrinsics.checkNotNullExpressionValue(copyOf, "copyOf(this, size)");
copyOf[i] = (byte) (b4 + 32);
for (int i4 = i + 1; i4 < copyOf.length; i4++) {
byte b5 = copyOf[i4];
if (b5 >= 65 && b5 <= 90) {
copyOf[i4] = (byte) (b5 + 32);
}
}
return new C0579k(copyOf);
}
i++;
}
}
public final String q() {
String str = this.f8288c;
if (str != null) {
return str;
}
byte[] h = h();
Intrinsics.checkNotNullParameter(h, "<this>");
String str2 = new String(h, Charsets.UTF_8);
this.f8288c = str2;
return str2;
}
public void r(C0576h buffer, int i) {
Intrinsics.checkNotNullParameter(buffer, "buffer");
Intrinsics.checkNotNullParameter(this, "<this>");
Intrinsics.checkNotNullParameter(buffer, "buffer");
buffer.i0(this.f8286a, 0, i);
}
/* JADX WARN: Code restructure failed: missing block: B:107:0x0102, code lost:
if (r8 == 64) goto L437;
*/
/* JADX WARN: Code restructure failed: missing block: B:133:0x00fa, code lost:
if (r8 == 64) goto L437;
*/
/* JADX WARN: Code restructure failed: missing block: B:135:0x0138, code lost:
if (r8 == 64) goto L437;
*/
/* JADX WARN: Code restructure failed: missing block: B:137:0x013c, code lost:
if (r8 == 64) goto L437;
*/
/* JADX WARN: Code restructure failed: missing block: B:139:0x00da, code lost:
if (r8 == 64) goto L437;
*/
/* JADX WARN: Code restructure failed: missing block: B:167:0x0096, code lost:
if (r8 == 64) goto L437;
*/
/* JADX WARN: Code restructure failed: missing block: B:169:0x00c8, code lost:
if (r8 == 64) goto L437;
*/
/* JADX WARN: Code restructure failed: missing block: B:171:0x0085, code lost:
if (r8 == 64) goto L437;
*/
/* JADX WARN: Code restructure failed: missing block: B:31:0x017b, code lost:
if (r8 == 64) goto L437;
*/
/* JADX WARN: Code restructure failed: missing block: B:82:0x0182, code lost:
if (r8 == 64) goto L437;
*/
/* JADX WARN: Code restructure failed: missing block: B:84:0x0174, code lost:
if (r8 == 64) goto L437;
*/
/* JADX WARN: Code restructure failed: missing block: B:86:0x01b7, code lost:
if (r8 == 64) goto L437;
*/
/* JADX WARN: Code restructure failed: missing block: B:88:0x01ba, code lost:
if (r8 == 64) goto L437;
*/
/* JADX WARN: Code restructure failed: missing block: B:90:0x01bd, code lost:
if (r8 == 64) goto L437;
*/
/* JADX WARN: Code restructure failed: missing block: B:92:0x0148, code lost:
if (r8 == 64) goto L437;
*/
/* JADX WARN: Code restructure failed: missing block: B:94:0x01c0, code lost:
if (r8 == 64) goto L437;
*/
/*
Code decompiled incorrectly, please refer to instructions dump.
To view partially-correct add '--show-bad-code' argument
*/
public java.lang.String toString() {
/*
Method dump skipped, instructions count: 648
To view this dump add '--comments-level debug' option
*/
throw new UnsupportedOperationException("Method not decompiled: r3.C0579k.toString():java.lang.String");
}
}

View File

@@ -0,0 +1,118 @@
package r3;
import java.util.concurrent.locks.ReentrantLock;
import kotlin.Unit;
import kotlin.jvm.internal.Intrinsics;
/* renamed from: r3.l, reason: case insensitive filesystem */
/* loaded from: classes3.dex */
public final class C0580l implements I {
/* renamed from: a, reason: collision with root package name */
public final t f8289a;
/* renamed from: b, reason: collision with root package name */
public long f8290b;
/* renamed from: c, reason: collision with root package name */
public boolean f8291c;
public C0580l(t fileHandle, long j4) {
Intrinsics.checkNotNullParameter(fileHandle, "fileHandle");
this.f8289a = fileHandle;
this.f8290b = j4;
}
@Override // java.io.Closeable, java.lang.AutoCloseable
public final void close() {
if (this.f8291c) {
return;
}
this.f8291c = true;
t tVar = this.f8289a;
ReentrantLock reentrantLock = tVar.f8313c;
reentrantLock.lock();
try {
int i = tVar.f8312b - 1;
tVar.f8312b = i;
if (i == 0 && tVar.f8311a) {
Unit unit = Unit.INSTANCE;
synchronized (tVar) {
tVar.f8314d.close();
}
}
} finally {
reentrantLock.unlock();
}
}
@Override // r3.I
public final long read(C0576h sink, long j4) {
long j5;
long j6;
int i;
Intrinsics.checkNotNullParameter(sink, "sink");
if (this.f8291c) {
throw new IllegalStateException("closed");
}
t tVar = this.f8289a;
long j7 = this.f8290b;
tVar.getClass();
if (j4 < 0) {
throw new IllegalArgumentException(C.w.l("byteCount < 0: ", j4).toString());
}
long j8 = j4 + j7;
long j9 = j7;
while (true) {
if (j9 >= j8) {
j5 = -1;
break;
}
D g02 = sink.g0(1);
byte[] array = g02.f8248a;
int i4 = g02.f8250c;
j5 = -1;
int min = (int) Math.min(j8 - j9, 8192 - i4);
synchronized (tVar) {
Intrinsics.checkNotNullParameter(array, "array");
tVar.f8314d.seek(j9);
i = 0;
while (true) {
if (i >= min) {
break;
}
int read = tVar.f8314d.read(array, i4, min - i);
if (read != -1) {
i += read;
} else if (i == 0) {
i = -1;
}
}
}
if (i == -1) {
if (g02.f8249b == g02.f8250c) {
sink.f8283a = g02.a();
E.a(g02);
}
if (j7 == j9) {
j6 = -1;
}
} else {
g02.f8250c += i;
long j10 = i;
j9 += j10;
sink.f8284b += j10;
}
}
j6 = j9 - j7;
if (j6 != j5) {
this.f8290b += j6;
}
return j6;
}
@Override // r3.I
public final K timeout() {
return K.f8261d;
}
}

View File

@@ -0,0 +1,103 @@
package r3;
import kotlin.collections.ArraysKt;
import kotlin.collections.ArraysKt___ArraysJvmKt;
import kotlin.jvm.internal.Intrinsics;
/* loaded from: classes3.dex */
public final class D {
/* renamed from: a, reason: collision with root package name */
public final byte[] f8248a;
/* renamed from: b, reason: collision with root package name */
public int f8249b;
/* renamed from: c, reason: collision with root package name */
public int f8250c;
/* renamed from: d, reason: collision with root package name */
public boolean f8251d;
/* renamed from: e, reason: collision with root package name */
public final boolean f8252e;
/* renamed from: f, reason: collision with root package name */
public D f8253f;
/* renamed from: g, reason: collision with root package name */
public D f8254g;
public D() {
this.f8248a = new byte[8192];
this.f8252e = true;
this.f8251d = false;
}
public final D a() {
D d4 = this.f8253f;
if (d4 == this) {
d4 = null;
}
D d5 = this.f8254g;
Intrinsics.checkNotNull(d5);
d5.f8253f = this.f8253f;
D d6 = this.f8253f;
Intrinsics.checkNotNull(d6);
d6.f8254g = this.f8254g;
this.f8253f = null;
this.f8254g = null;
return d4;
}
public final void b(D segment) {
Intrinsics.checkNotNullParameter(segment, "segment");
segment.f8254g = this;
segment.f8253f = this.f8253f;
D d4 = this.f8253f;
Intrinsics.checkNotNull(d4);
d4.f8254g = segment;
this.f8253f = segment;
}
public final D c() {
this.f8251d = true;
return new D(this.f8248a, this.f8249b, this.f8250c, true);
}
public final void d(D sink, int i) {
Intrinsics.checkNotNullParameter(sink, "sink");
if (!sink.f8252e) {
throw new IllegalStateException("only owner can write");
}
int i4 = sink.f8250c;
int i5 = i4 + i;
byte[] bArr = sink.f8248a;
if (i5 > 8192) {
if (sink.f8251d) {
throw new IllegalArgumentException();
}
int i6 = sink.f8249b;
if (i5 - i6 > 8192) {
throw new IllegalArgumentException();
}
ArraysKt___ArraysJvmKt.copyInto$default(bArr, bArr, 0, i6, i4, 2, (Object) null);
sink.f8250c -= sink.f8249b;
sink.f8249b = 0;
}
int i7 = sink.f8250c;
int i8 = this.f8249b;
ArraysKt.copyInto(this.f8248a, bArr, i7, i8, i8 + i);
sink.f8250c += i;
this.f8249b += i;
}
public D(byte[] data, int i, int i4, boolean z3) {
Intrinsics.checkNotNullParameter(data, "data");
this.f8248a = data;
this.f8249b = i;
this.f8250c = i4;
this.f8251d = z3;
this.f8252e = false;
}
}

View File

@@ -0,0 +1,69 @@
package r3;
import java.util.concurrent.atomic.AtomicReference;
import kotlin.jvm.internal.Intrinsics;
/* loaded from: classes3.dex */
public abstract class E {
/* renamed from: a, reason: collision with root package name */
public static final D f8255a = new D(new byte[0], 0, 0, false);
/* renamed from: b, reason: collision with root package name */
public static final int f8256b;
/* renamed from: c, reason: collision with root package name */
public static final AtomicReference[] f8257c;
static {
int highestOneBit = Integer.highestOneBit((Runtime.getRuntime().availableProcessors() * 2) - 1);
f8256b = highestOneBit;
AtomicReference[] atomicReferenceArr = new AtomicReference[highestOneBit];
for (int i = 0; i < highestOneBit; i++) {
atomicReferenceArr[i] = new AtomicReference();
}
f8257c = atomicReferenceArr;
}
public static final void a(D segment) {
Intrinsics.checkNotNullParameter(segment, "segment");
if (segment.f8253f != null || segment.f8254g != null) {
throw new IllegalArgumentException("Failed requirement.");
}
if (segment.f8251d) {
return;
}
AtomicReference atomicReference = f8257c[(int) (Thread.currentThread().getId() & (f8256b - 1))];
D d4 = f8255a;
D d5 = (D) atomicReference.getAndSet(d4);
if (d5 == d4) {
return;
}
int i = d5 != null ? d5.f8250c : 0;
if (i >= 65536) {
atomicReference.set(d5);
return;
}
segment.f8253f = d5;
segment.f8249b = 0;
segment.f8250c = i + 8192;
atomicReference.set(segment);
}
public static final D b() {
AtomicReference atomicReference = f8257c[(int) (Thread.currentThread().getId() & (f8256b - 1))];
D d4 = f8255a;
D d5 = (D) atomicReference.getAndSet(d4);
if (d5 == d4) {
return new D();
}
if (d5 == null) {
atomicReference.set(null);
return new D();
}
atomicReference.set(d5.f8253f);
d5.f8253f = null;
d5.f8250c = 0;
return d5;
}
}

View File

@@ -0,0 +1,295 @@
package r3;
import java.security.MessageDigest;
import kotlin.collections.ArraysKt;
import kotlin.jvm.internal.Intrinsics;
/* loaded from: classes3.dex */
public final class F extends C0579k {
/* renamed from: e, reason: collision with root package name */
public final transient byte[][] f8258e;
/* renamed from: f, reason: collision with root package name */
public final transient int[] f8259f;
/* JADX WARN: 'super' call moved to the top of the method (can break code semantics) */
public F(byte[][] segments, int[] directory) {
super(C0579k.f8285d.f8286a);
Intrinsics.checkNotNullParameter(segments, "segments");
Intrinsics.checkNotNullParameter(directory, "directory");
this.f8258e = segments;
this.f8259f = directory;
}
@Override // r3.C0579k
public final String a() {
throw null;
}
@Override // r3.C0579k
public final C0579k c(String algorithm) {
Intrinsics.checkNotNullParameter(algorithm, "algorithm");
MessageDigest messageDigest = MessageDigest.getInstance(algorithm);
byte[][] bArr = this.f8258e;
int length = bArr.length;
int i = 0;
int i4 = 0;
while (i < length) {
int[] iArr = this.f8259f;
int i5 = iArr[length + i];
int i6 = iArr[i];
messageDigest.update(bArr[i], i5, i6 - i4);
i++;
i4 = i6;
}
byte[] digest = messageDigest.digest();
Intrinsics.checkNotNull(digest);
return new C0579k(digest);
}
@Override // r3.C0579k
public final int d() {
return this.f8259f[this.f8258e.length - 1];
}
@Override // r3.C0579k
public final String e() {
return t().e();
}
@Override // r3.C0579k
public final boolean equals(Object obj) {
if (obj == this) {
return true;
}
if (obj instanceof C0579k) {
C0579k c0579k = (C0579k) obj;
if (c0579k.d() == d() && l(0, c0579k, d())) {
return true;
}
}
return false;
}
@Override // r3.C0579k
public final int f(int i, byte[] other) {
Intrinsics.checkNotNullParameter(other, "other");
return t().f(i, other);
}
@Override // r3.C0579k
public final byte[] h() {
return s();
}
@Override // r3.C0579k
public final int hashCode() {
int i = this.f8287b;
if (i != 0) {
return i;
}
byte[][] bArr = this.f8258e;
int length = bArr.length;
int i4 = 0;
int i5 = 1;
int i6 = 0;
while (i4 < length) {
int[] iArr = this.f8259f;
int i7 = iArr[length + i4];
int i8 = iArr[i4];
byte[] bArr2 = bArr[i4];
int i9 = (i8 - i6) + i7;
while (i7 < i9) {
i5 = (i5 * 31) + bArr2[i7];
i7++;
}
i4++;
i6 = i8;
}
this.f8287b = i5;
return i5;
}
@Override // r3.C0579k
public final byte i(int i) {
byte[][] bArr = this.f8258e;
int length = bArr.length - 1;
int[] iArr = this.f8259f;
m3.d.j(iArr[length], i, 1L);
int a2 = s3.d.a(this, i);
return bArr[a2][(i - (a2 == 0 ? 0 : iArr[a2 - 1])) + iArr[bArr.length + a2]];
}
@Override // r3.C0579k
public final int j(byte[] other) {
Intrinsics.checkNotNullParameter(other, "other");
return t().j(other);
}
@Override // r3.C0579k
public final boolean l(int i, C0579k other, int i4) {
Intrinsics.checkNotNullParameter(other, "other");
if (i >= 0 && i <= d() - i4) {
int i5 = i4 + i;
int a2 = s3.d.a(this, i);
int i6 = 0;
while (i < i5) {
int[] iArr = this.f8259f;
int i7 = a2 == 0 ? 0 : iArr[a2 - 1];
int i8 = iArr[a2] - i7;
byte[][] bArr = this.f8258e;
int i9 = iArr[bArr.length + a2];
int min = Math.min(i5, i8 + i7) - i;
if (other.m(i6, bArr[a2], (i - i7) + i9, min)) {
i6 += min;
i += min;
a2++;
}
}
return true;
}
return false;
}
@Override // r3.C0579k
public final boolean m(int i, byte[] other, int i4, int i5) {
Intrinsics.checkNotNullParameter(other, "other");
if (i < 0 || i > d() - i5 || i4 < 0 || i4 > other.length - i5) {
return false;
}
int i6 = i5 + i;
int a2 = s3.d.a(this, i);
while (i < i6) {
int[] iArr = this.f8259f;
int i7 = a2 == 0 ? 0 : iArr[a2 - 1];
int i8 = iArr[a2] - i7;
byte[][] bArr = this.f8258e;
int i9 = iArr[bArr.length + a2];
int min = Math.min(i6, i8 + i7) - i;
if (!m3.d.c(bArr[a2], other, (i - i7) + i9, i4, min)) {
return false;
}
i4 += min;
i += min;
a2++;
}
return true;
}
@Override // r3.C0579k
public final C0579k n(int i, int i4) {
Intrinsics.checkNotNullParameter(this, "<this>");
if (i4 == -1234567890) {
i4 = d();
}
if (i < 0) {
throw new IllegalArgumentException(C.w.i(i, "beginIndex=", " < 0").toString());
}
if (i4 > d()) {
StringBuilder t2 = C.w.t(i4, "endIndex=", " > length(");
t2.append(d());
t2.append(')');
throw new IllegalArgumentException(t2.toString().toString());
}
int i5 = i4 - i;
if (i5 < 0) {
throw new IllegalArgumentException(C.w.k("endIndex=", i4, i, " < beginIndex=").toString());
}
if (i == 0 && i4 == d()) {
return this;
}
if (i == i4) {
return C0579k.f8285d;
}
int a2 = s3.d.a(this, i);
int a4 = s3.d.a(this, i4 - 1);
byte[][] bArr = this.f8258e;
byte[][] bArr2 = (byte[][]) ArraysKt.copyOfRange(bArr, a2, a4 + 1);
int[] iArr = new int[bArr2.length * 2];
int[] iArr2 = this.f8259f;
if (a2 <= a4) {
int i6 = a2;
int i7 = 0;
while (true) {
iArr[i7] = Math.min(iArr2[i6] - i, i5);
int i8 = i7 + 1;
iArr[i7 + bArr2.length] = iArr2[bArr.length + i6];
if (i6 == a4) {
break;
}
i6++;
i7 = i8;
}
}
int i9 = a2 != 0 ? iArr2[a2 - 1] : 0;
int length = bArr2.length;
iArr[length] = (i - i9) + iArr[length];
return new F(bArr2, iArr);
}
@Override // r3.C0579k
public final C0579k p() {
return t().p();
}
@Override // r3.C0579k
public final void r(C0576h buffer, int i) {
Intrinsics.checkNotNullParameter(buffer, "buffer");
int a2 = s3.d.a(this, 0);
int i4 = 0;
while (i4 < i) {
int[] iArr = this.f8259f;
int i5 = a2 == 0 ? 0 : iArr[a2 - 1];
int i6 = iArr[a2] - i5;
byte[][] bArr = this.f8258e;
int i7 = iArr[bArr.length + a2];
int min = Math.min(i, i6 + i5) - i4;
int i8 = (i4 - i5) + i7;
D d4 = new D(bArr[a2], i8, i8 + min, true);
D d5 = buffer.f8283a;
if (d5 == null) {
d4.f8254g = d4;
d4.f8253f = d4;
buffer.f8283a = d4;
} else {
Intrinsics.checkNotNull(d5);
D d6 = d5.f8254g;
Intrinsics.checkNotNull(d6);
d6.b(d4);
}
i4 += min;
a2++;
}
buffer.f8284b += i;
}
public final byte[] s() {
byte[] bArr = new byte[d()];
byte[][] bArr2 = this.f8258e;
int length = bArr2.length;
int i = 0;
int i4 = 0;
int i5 = 0;
while (i < length) {
int[] iArr = this.f8259f;
int i6 = iArr[length + i];
int i7 = iArr[i];
int i8 = i7 - i4;
ArraysKt.copyInto(bArr2[i], bArr, i5, i6, i6 + i8);
i5 += i8;
i++;
i4 = i7;
}
return bArr;
}
public final C0579k t() {
return new C0579k(s());
}
@Override // r3.C0579k
public final String toString() {
return t().toString();
}
}

View File

@@ -0,0 +1,16 @@
package r3;
import java.io.Closeable;
import java.io.Flushable;
/* loaded from: classes3.dex */
public interface G extends Closeable, Flushable {
@Override // java.io.Closeable, java.lang.AutoCloseable
void close();
void flush();
K timeout();
void z(C0576h c0576h, long j4);
}

View File

@@ -0,0 +1,43 @@
package r3;
import a.AbstractC0105a;
import java.io.IOException;
import java.net.Socket;
import java.net.SocketTimeoutException;
import java.util.logging.Level;
import kotlin.jvm.internal.Intrinsics;
/* loaded from: classes3.dex */
public final class H extends C0573e {
/* renamed from: m, reason: collision with root package name */
public final Socket f8260m;
public H(Socket socket) {
Intrinsics.checkNotNullParameter(socket, "socket");
this.f8260m = socket;
}
@Override // r3.C0573e
public final void j() {
Socket socket = this.f8260m;
try {
socket.close();
} catch (AssertionError e4) {
if (!AbstractC0105a.E(e4)) {
throw e4;
}
w.f8315a.log(Level.WARNING, "Failed to close timed out socket " + socket, (Throwable) e4);
} catch (Exception e5) {
w.f8315a.log(Level.WARNING, "Failed to close timed out socket " + socket, (Throwable) e5);
}
}
public final IOException k(IOException iOException) {
SocketTimeoutException socketTimeoutException = new SocketTimeoutException("timeout");
if (iOException != null) {
socketTimeoutException.initCause(iOException);
}
return socketTimeoutException;
}
}

View File

@@ -0,0 +1,10 @@
package r3;
import java.io.Closeable;
/* loaded from: classes3.dex */
public interface I extends Closeable {
long read(C0576h c0576h, long j4);
K timeout();
}

View File

@@ -0,0 +1,32 @@
package r3;
import java.nio.channels.WritableByteChannel;
/* renamed from: r3.i, reason: case insensitive filesystem */
/* loaded from: classes3.dex */
public interface InterfaceC0577i extends G, WritableByteChannel {
long D(I i);
InterfaceC0577i E(byte[] bArr);
InterfaceC0577i F(C0579k c0579k);
InterfaceC0577i L(int i, int i4, byte[] bArr);
InterfaceC0577i Q(String str);
InterfaceC0577i R(long j4);
C0576h a();
InterfaceC0577i f(String str, int i, int i4);
@Override // r3.G, java.io.Flushable
void flush();
InterfaceC0577i m(int i);
InterfaceC0577i r(int i);
InterfaceC0577i y(int i);
}

View File

@@ -0,0 +1,45 @@
package r3;
import java.io.InputStream;
import java.nio.channels.ReadableByteChannel;
import java.nio.charset.Charset;
/* renamed from: r3.j, reason: case insensitive filesystem */
/* loaded from: classes3.dex */
public interface InterfaceC0578j extends I, ReadableByteChannel {
long A(C0579k c0579k);
int C(x xVar);
boolean H(C0579k c0579k);
C M();
void P(long j4);
long U(InterfaceC0577i interfaceC0577i);
String W(Charset charset);
InputStream X();
C0576h a();
C0579k g();
C0579k h(long j4);
void l(long j4);
boolean n(long j4);
byte readByte();
int readInt();
short readShort();
long u(C0579k c0579k);
byte[] w();
}

View File

@@ -0,0 +1,23 @@
package r3;
import java.util.concurrent.TimeUnit;
import kotlin.jvm.internal.Intrinsics;
/* loaded from: classes3.dex */
public final class J extends K {
@Override // r3.K
public final K d(long j4) {
return this;
}
@Override // r3.K
public final void f() {
}
@Override // r3.K
public final K g(long j4) {
TimeUnit unit = TimeUnit.MILLISECONDS;
Intrinsics.checkNotNullParameter(unit, "unit");
return this;
}
}

View File

@@ -0,0 +1,67 @@
package r3;
import java.io.InterruptedIOException;
import java.util.concurrent.TimeUnit;
import kotlin.jvm.internal.Intrinsics;
/* loaded from: classes3.dex */
public class K {
/* renamed from: d, reason: collision with root package name */
public static final J f8261d = new Object();
/* renamed from: a, reason: collision with root package name */
public boolean f8262a;
/* renamed from: b, reason: collision with root package name */
public long f8263b;
/* renamed from: c, reason: collision with root package name */
public long f8264c;
public K a() {
this.f8262a = false;
return this;
}
public K b() {
this.f8264c = 0L;
return this;
}
public long c() {
if (this.f8262a) {
return this.f8263b;
}
throw new IllegalStateException("No deadline");
}
public K d(long j4) {
this.f8262a = true;
this.f8263b = j4;
return this;
}
public boolean e() {
return this.f8262a;
}
public void f() {
if (Thread.currentThread().isInterrupted()) {
throw new InterruptedIOException("interrupted");
}
if (this.f8262a && this.f8263b - System.nanoTime() <= 0) {
throw new InterruptedIOException("deadline reached");
}
}
public K g(long j4) {
TimeUnit unit = TimeUnit.MILLISECONDS;
Intrinsics.checkNotNullParameter(unit, "unit");
if (j4 < 0) {
throw new IllegalArgumentException(C.w.l("timeout < 0: ", j4).toString());
}
this.f8264c = unit.toNanos(j4);
return this;
}
}

View File

@@ -0,0 +1,185 @@
package r3;
import a.AbstractC0105a;
import com.google.firebase.sessions.settings.RemoteSettings;
import f0.C0338b;
import java.io.FileNotFoundException;
import java.io.IOException;
import java.util.List;
import java.util.Map;
import java.util.zip.Inflater;
import kotlin.ExceptionsKt;
import kotlin.collections.CollectionsKt;
import kotlin.jvm.internal.Intrinsics;
/* loaded from: classes3.dex */
public final class L extends n {
/* renamed from: e, reason: collision with root package name */
public static final z f8265e;
/* renamed from: b, reason: collision with root package name */
public final z f8266b;
/* renamed from: c, reason: collision with root package name */
public final u f8267c;
/* renamed from: d, reason: collision with root package name */
public final Map f8268d;
static {
String str = z.f8321b;
f8265e = C0338b.o(RemoteSettings.FORWARD_SLASH_STRING);
}
public L(z zipPath, u fileSystem, Map entries) {
Intrinsics.checkNotNullParameter(zipPath, "zipPath");
Intrinsics.checkNotNullParameter(fileSystem, "fileSystem");
Intrinsics.checkNotNullParameter(entries, "entries");
this.f8266b = zipPath;
this.f8267c = fileSystem;
this.f8268d = entries;
}
@Override // r3.n
public final void a(z path) {
Intrinsics.checkNotNullParameter(path, "path");
throw new IOException("zip file systems are read-only");
}
@Override // r3.n
public final List d(z child) {
Intrinsics.checkNotNullParameter(child, "dir");
z zVar = f8265e;
zVar.getClass();
Intrinsics.checkNotNullParameter(child, "child");
s3.i iVar = (s3.i) this.f8268d.get(s3.c.b(zVar, child, true));
if (iVar != null) {
List list = CollectionsKt.toList(iVar.h);
Intrinsics.checkNotNull(list);
return list;
}
throw new IOException("not a directory: " + child);
}
@Override // r3.n
public final m f(z child) {
m mVar;
Throwable th;
Intrinsics.checkNotNullParameter(child, "path");
z zVar = f8265e;
zVar.getClass();
Intrinsics.checkNotNullParameter(child, "child");
s3.i iVar = (s3.i) this.f8268d.get(s3.c.b(zVar, child, true));
Throwable th2 = null;
if (iVar == null) {
return null;
}
boolean z3 = iVar.f8490b;
m basicMetadata = new m(!z3, z3, null, z3 ? null : Long.valueOf(iVar.f8492d), null, iVar.f8494f, null);
long j4 = iVar.f8495g;
if (j4 == -1) {
return basicMetadata;
}
t j5 = this.f8267c.j(this.f8266b);
try {
C d4 = AbstractC0105a.d(j5.e(j4));
try {
Intrinsics.checkNotNullParameter(d4, "<this>");
Intrinsics.checkNotNullParameter(basicMetadata, "basicMetadata");
mVar = s3.l.e(d4, basicMetadata);
Intrinsics.checkNotNull(mVar);
try {
d4.close();
th = null;
} catch (Throwable th3) {
th = th3;
}
} catch (Throwable th4) {
try {
d4.close();
} catch (Throwable th5) {
ExceptionsKt.addSuppressed(th4, th5);
}
th = th4;
mVar = null;
}
} catch (Throwable th6) {
try {
j5.close();
} catch (Throwable th7) {
ExceptionsKt.addSuppressed(th6, th7);
}
mVar = null;
th2 = th6;
}
if (th != null) {
throw th;
}
Intrinsics.checkNotNull(mVar);
try {
j5.close();
} catch (Throwable th8) {
th2 = th8;
}
if (th2 != null) {
throw th2;
}
Intrinsics.checkNotNull(mVar);
return mVar;
}
@Override // r3.n
public final G g(z file) {
Intrinsics.checkNotNullParameter(file, "file");
throw new IOException("zip file systems are read-only");
}
@Override // r3.n
public final I h(z child) {
Throwable th;
C c4;
Intrinsics.checkNotNullParameter(child, "file");
z zVar = f8265e;
zVar.getClass();
Intrinsics.checkNotNullParameter(child, "child");
s3.i iVar = (s3.i) this.f8268d.get(s3.c.b(zVar, child, true));
if (iVar == null) {
throw new FileNotFoundException("no such file: " + child);
}
t j4 = this.f8267c.j(this.f8266b);
try {
c4 = AbstractC0105a.d(j4.e(iVar.f8495g));
try {
j4.close();
th = null;
} catch (Throwable th2) {
th = th2;
}
} catch (Throwable th3) {
try {
j4.close();
} catch (Throwable th4) {
ExceptionsKt.addSuppressed(th3, th4);
}
th = th3;
c4 = null;
}
if (th != null) {
throw th;
}
Intrinsics.checkNotNull(c4);
Intrinsics.checkNotNullParameter(c4, "<this>");
s3.l.e(c4, null);
int i = iVar.f8493e;
long j5 = iVar.f8492d;
if (i == 0) {
return new s3.f(c4, j5, true);
}
s3.f source = new s3.f(c4, iVar.f8491c, true);
Inflater inflater = new Inflater(true);
Intrinsics.checkNotNullParameter(source, "source");
Intrinsics.checkNotNullParameter(inflater, "inflater");
return new s3.f(new s(AbstractC0105a.d(source), inflater), j5, false);
}
}

View File

@@ -0,0 +1,416 @@
package r3;
import com.google.android.gms.maps.model.BitmapDescriptorFactory;
import java.io.Serializable;
import java.util.ArrayList;
import java.util.HashSet;
import java.util.Iterator;
import java.util.Map;
import kotlin.collections.CollectionsKt___CollectionsKt;
import kotlin.collections.MapsKt;
import kotlin.jvm.internal.Intrinsics;
import x.C0652a;
import x.C0653b;
import x.C0654c;
import x.InterfaceC0655d;
/* loaded from: classes3.dex */
public final class m {
/* renamed from: a, reason: collision with root package name */
public final /* synthetic */ int f8292a = 1;
/* renamed from: b, reason: collision with root package name */
public boolean f8293b;
/* renamed from: c, reason: collision with root package name */
public boolean f8294c;
/* renamed from: d, reason: collision with root package name */
public Object f8295d;
/* renamed from: e, reason: collision with root package name */
public Object f8296e;
/* renamed from: f, reason: collision with root package name */
public Serializable f8297f;
/* renamed from: g, reason: collision with root package name */
public Object f8298g;
public Object h;
public Object i;
public /* synthetic */ m() {
}
/* JADX WARN: Type inference failed for: r10v2, types: [x.k, java.lang.Object] */
public void a(x.e eVar, int i, ArrayList arrayList, x.k kVar) {
x.n nVar = eVar.f8824d;
if (nVar.f8846c == null) {
w.e eVar2 = (w.e) this.f8295d;
if (nVar != eVar2.f8693d) {
x.k kVar2 = kVar;
if (nVar == eVar2.f8695e) {
return;
}
if (kVar == null) {
?? obj = new Object();
obj.f8834a = null;
obj.f8835b = new ArrayList();
obj.f8834a = nVar;
arrayList.add(obj);
kVar2 = obj;
}
nVar.f8846c = kVar2;
kVar2.f8835b.add(nVar);
x.e eVar3 = nVar.h;
Iterator it = eVar3.f8829k.iterator();
while (it.hasNext()) {
InterfaceC0655d interfaceC0655d = (InterfaceC0655d) it.next();
if (interfaceC0655d instanceof x.e) {
a((x.e) interfaceC0655d, i, arrayList, kVar2);
}
}
x.e eVar4 = nVar.i;
Iterator it2 = eVar4.f8829k.iterator();
while (it2.hasNext()) {
InterfaceC0655d interfaceC0655d2 = (InterfaceC0655d) it2.next();
if (interfaceC0655d2 instanceof x.e) {
a((x.e) interfaceC0655d2, i, arrayList, kVar2);
}
}
if (i == 1 && (nVar instanceof x.l)) {
Iterator it3 = ((x.l) nVar).f8836k.f8829k.iterator();
while (it3.hasNext()) {
InterfaceC0655d interfaceC0655d3 = (InterfaceC0655d) it3.next();
if (interfaceC0655d3 instanceof x.e) {
a((x.e) interfaceC0655d3, i, arrayList, kVar2);
}
}
}
Iterator it4 = eVar3.f8830l.iterator();
while (it4.hasNext()) {
a((x.e) it4.next(), i, arrayList, kVar2);
}
Iterator it5 = eVar4.f8830l.iterator();
while (it5.hasNext()) {
a((x.e) it5.next(), i, arrayList, kVar2);
}
if (i == 1 && (nVar instanceof x.l)) {
Iterator it6 = ((x.l) nVar).f8836k.f8830l.iterator();
while (it6.hasNext()) {
a((x.e) it6.next(), i, arrayList, kVar2);
}
}
}
}
}
/* JADX WARN: Removed duplicated region for block: B:137:0x026a A[SYNTHETIC] */
/* JADX WARN: Removed duplicated region for block: B:63:0x018f */
/* JADX WARN: Removed duplicated region for block: B:68:0x0270 A[SYNTHETIC] */
/* JADX WARN: Removed duplicated region for block: B:97:0x0008 A[ADDED_TO_REGION, SYNTHETIC] */
/*
Code decompiled incorrectly, please refer to instructions dump.
To view partially-correct add '--show-bad-code' argument
*/
public void b(w.e r23) {
/*
Method dump skipped, instructions count: 795
To view this dump add '--comments-level debug' option
*/
throw new UnsupportedOperationException("Method not decompiled: r3.m.b(w.e):void");
}
public void c() {
ArrayList arrayList = (ArrayList) this.f8297f;
arrayList.clear();
w.e eVar = (w.e) this.f8296e;
eVar.f8693d.f();
eVar.f8695e.f();
arrayList.add(eVar.f8693d);
arrayList.add(eVar.f8695e);
Iterator it = eVar.f8736q0.iterator();
HashSet hashSet = null;
while (it.hasNext()) {
w.d dVar = (w.d) it.next();
if (dVar instanceof w.h) {
x.n nVar = new x.n(dVar);
dVar.f8693d.f();
dVar.f8695e.f();
nVar.f8849f = ((w.h) dVar).f8798u0;
arrayList.add(nVar);
} else {
if (dVar.x()) {
if (dVar.f8689b == null) {
dVar.f8689b = new C0654c(dVar, 0);
}
if (hashSet == null) {
hashSet = new HashSet();
}
hashSet.add(dVar.f8689b);
} else {
arrayList.add(dVar.f8693d);
}
if (dVar.y()) {
if (dVar.f8691c == null) {
dVar.f8691c = new C0654c(dVar, 1);
}
if (hashSet == null) {
hashSet = new HashSet();
}
hashSet.add(dVar.f8691c);
} else {
arrayList.add(dVar.f8695e);
}
if (dVar instanceof w.i) {
arrayList.add(new x.n(dVar));
}
}
}
if (hashSet != null) {
arrayList.addAll(hashSet);
}
Iterator it2 = arrayList.iterator();
while (it2.hasNext()) {
((x.n) it2.next()).f();
}
Iterator it3 = arrayList.iterator();
while (it3.hasNext()) {
x.n nVar2 = (x.n) it3.next();
if (nVar2.f8845b != eVar) {
nVar2.d();
}
}
ArrayList arrayList2 = (ArrayList) this.i;
arrayList2.clear();
w.e eVar2 = (w.e) this.f8295d;
e(eVar2.f8693d, 0, arrayList2);
e(eVar2.f8695e, 1, arrayList2);
this.f8293b = false;
}
public int d(w.e eVar, int i) {
ArrayList arrayList;
int i4;
long max;
float f2;
w.e eVar2 = eVar;
ArrayList arrayList2 = (ArrayList) this.i;
int size = arrayList2.size();
long j4 = 0;
int i5 = 0;
long j5 = 0;
while (i5 < size) {
x.n nVar = ((x.k) arrayList2.get(i5)).f8834a;
if (!(nVar instanceof C0654c) ? !(i != 0 ? (nVar instanceof x.l) : (nVar instanceof x.j)) : ((C0654c) nVar).f8849f != i) {
x.e eVar3 = (i == 0 ? eVar2.f8693d : eVar2.f8695e).h;
x.e eVar4 = (i == 0 ? eVar2.f8693d : eVar2.f8695e).i;
boolean contains = nVar.h.f8830l.contains(eVar3);
x.e eVar5 = nVar.i;
boolean contains2 = eVar5.f8830l.contains(eVar4);
long j6 = nVar.j();
x.e eVar6 = nVar.h;
if (contains && contains2) {
long b4 = x.k.b(eVar6, j4);
arrayList = arrayList2;
long a2 = x.k.a(eVar5, j4);
long j7 = b4 - j6;
int i6 = eVar5.f8826f;
i4 = i5;
if (j7 >= (-i6)) {
j7 += i6;
}
long j8 = eVar6.f8826f;
long j9 = ((-a2) - j6) - j8;
if (j9 >= j8) {
j9 -= j8;
}
w.d dVar = nVar.f8845b;
if (i == 0) {
f2 = dVar.f8694d0;
} else if (i == 1) {
f2 = dVar.f8696e0;
} else {
dVar.getClass();
f2 = -1.0f;
}
float f4 = (float) (f2 > BitmapDescriptorFactory.HUE_RED ? (((float) j7) / (1.0f - f2)) + (((float) j9) / f2) : 0L);
max = (eVar6.f8826f + ((((f4 * f2) + 0.5f) + j6) + com.google.android.gms.measurement.internal.a.a(1.0f, f2, f4, 0.5f))) - eVar5.f8826f;
} else {
arrayList = arrayList2;
i4 = i5;
max = contains ? Math.max(x.k.b(eVar6, eVar6.f8826f), eVar6.f8826f + j6) : contains2 ? Math.max(-x.k.a(eVar5, eVar5.f8826f), (-eVar5.f8826f) + j6) : (nVar.j() + eVar6.f8826f) - eVar5.f8826f;
}
} else {
arrayList = arrayList2;
max = j4;
i4 = i5;
}
j5 = Math.max(j5, max);
i5 = i4 + 1;
arrayList2 = arrayList;
eVar2 = eVar;
j4 = 0;
}
return (int) j5;
}
public void e(x.n nVar, int i, ArrayList arrayList) {
x.e eVar;
Iterator it = nVar.h.f8829k.iterator();
while (true) {
boolean hasNext = it.hasNext();
eVar = nVar.i;
if (!hasNext) {
break;
}
InterfaceC0655d interfaceC0655d = (InterfaceC0655d) it.next();
if (interfaceC0655d instanceof x.e) {
a((x.e) interfaceC0655d, i, arrayList, null);
} else if (interfaceC0655d instanceof x.n) {
a(((x.n) interfaceC0655d).h, i, arrayList, null);
}
}
Iterator it2 = eVar.f8829k.iterator();
while (it2.hasNext()) {
InterfaceC0655d interfaceC0655d2 = (InterfaceC0655d) it2.next();
if (interfaceC0655d2 instanceof x.e) {
a((x.e) interfaceC0655d2, i, arrayList, null);
} else if (interfaceC0655d2 instanceof x.n) {
a(((x.n) interfaceC0655d2).i, i, arrayList, null);
}
}
if (i == 1) {
Iterator it3 = ((x.l) nVar).f8836k.f8829k.iterator();
while (it3.hasNext()) {
InterfaceC0655d interfaceC0655d3 = (InterfaceC0655d) it3.next();
if (interfaceC0655d3 instanceof x.e) {
a((x.e) interfaceC0655d3, i, arrayList, null);
}
}
}
}
public void f(int i, int i4, int i5, int i6, w.d dVar) {
C0653b c0653b = (C0653b) this.h;
c0653b.f8811a = i;
c0653b.f8812b = i5;
c0653b.f8813c = i4;
c0653b.f8814d = i6;
((androidx.constraintlayout.widget.f) this.f8298g).b(dVar, c0653b);
dVar.O(c0653b.f8815e);
dVar.L(c0653b.f8816f);
dVar.f8667E = c0653b.h;
dVar.I(c0653b.f8817g);
}
public void g() {
m mVar;
C0652a c0652a;
Iterator it = ((w.e) this.f8295d).f8736q0.iterator();
while (it.hasNext()) {
w.d dVar = (w.d) it.next();
if (!dVar.f8687a) {
int[] iArr = dVar.f8715p0;
boolean z3 = false;
int i = iArr[0];
int i4 = iArr[1];
int i5 = dVar.f8717r;
int i6 = dVar.f8718s;
boolean z4 = i == 2 || (i == 3 && i5 == 1);
if (i4 == 2 || (i4 == 3 && i6 == 1)) {
z3 = true;
}
x.f fVar = dVar.f8693d.f8848e;
boolean z5 = fVar.f8828j;
x.f fVar2 = dVar.f8695e.f8848e;
boolean z6 = fVar2.f8828j;
boolean z7 = z4;
if (z5 && z6) {
mVar = this;
mVar.f(1, fVar.f8827g, 1, fVar2.f8827g, dVar);
dVar.f8687a = true;
} else if (z5 && z3) {
mVar = this;
mVar.f(1, fVar.f8827g, 2, fVar2.f8827g, dVar);
if (i4 == 3) {
dVar.f8695e.f8848e.f8831m = dVar.k();
} else {
dVar.f8695e.f8848e.d(dVar.k());
dVar.f8687a = true;
}
} else {
mVar = this;
if (z6 && z7) {
mVar.f(2, fVar.f8827g, 1, fVar2.f8827g, dVar);
if (i == 3) {
dVar.f8693d.f8848e.f8831m = dVar.q();
} else {
dVar.f8693d.f8848e.d(dVar.q());
dVar.f8687a = true;
}
}
}
if (dVar.f8687a && (c0652a = dVar.f8695e.f8837l) != null) {
c0652a.d(dVar.f8688a0);
}
this = mVar;
}
}
}
public String toString() {
String joinToString$default;
switch (this.f8292a) {
case 0:
ArrayList arrayList = new ArrayList();
if (this.f8293b) {
arrayList.add("isRegularFile");
}
if (this.f8294c) {
arrayList.add("isDirectory");
}
Long l4 = (Long) this.f8296e;
if (l4 != null) {
arrayList.add("byteCount=" + l4);
}
Long l5 = (Long) this.f8297f;
if (l5 != null) {
arrayList.add("createdAt=" + l5);
}
Long l6 = (Long) this.f8298g;
if (l6 != null) {
arrayList.add("lastModifiedAt=" + l6);
}
Long l7 = (Long) this.h;
if (l7 != null) {
arrayList.add("lastAccessedAt=" + l7);
}
Map map = (Map) this.i;
if (!map.isEmpty()) {
arrayList.add("extras=" + map);
}
joinToString$default = CollectionsKt___CollectionsKt.joinToString$default(arrayList, ", ", "FileMetadata(", ")", 0, null, null, 56, null);
return joinToString$default;
default:
return super.toString();
}
}
public m(boolean z3, boolean z4, z zVar, Long l4, Long l5, Long l6, Long l7, Map extras) {
Intrinsics.checkNotNullParameter(extras, "extras");
this.f8293b = z3;
this.f8294c = z4;
this.f8295d = zVar;
this.f8296e = l4;
this.f8297f = l5;
this.f8298g = l6;
this.h = l7;
this.i = MapsKt.toMap(extras);
}
public /* synthetic */ m(boolean z3, boolean z4, z zVar, Long l4, Long l5, Long l6, Long l7) {
this(z3, z4, zVar, l4, l5, l6, l7, MapsKt.emptyMap());
}
}

View File

@@ -0,0 +1,68 @@
package r3;
import f0.C0338b;
import java.io.FileNotFoundException;
import java.util.List;
import kotlin.jvm.internal.Intrinsics;
/* loaded from: classes3.dex */
public abstract class n {
/* renamed from: a, reason: collision with root package name */
public static final u f8299a;
/* JADX WARN: Multi-variable type inference failed */
/* JADX WARN: Type inference failed for: r0v1, types: [r3.u] */
/* JADX WARN: Type inference failed for: r0v8 */
/* JADX WARN: Type inference failed for: r0v9 */
static {
?? r02;
try {
Class.forName("java.nio.file.Files");
r02 = new Object();
} catch (ClassNotFoundException unused) {
r02 = new Object();
}
f8299a = r02;
String str = z.f8321b;
String property = System.getProperty("java.io.tmpdir");
Intrinsics.checkNotNullExpressionValue(property, "getProperty(...)");
C0338b.o(property);
ClassLoader classLoader = s3.h.class.getClassLoader();
Intrinsics.checkNotNullExpressionValue(classLoader, "getClassLoader(...)");
new s3.h(classLoader);
}
public abstract void a(z zVar);
public final void b(z path) {
Intrinsics.checkNotNullParameter(path, "path");
a(path);
}
public final boolean c(z path) {
Intrinsics.checkNotNullParameter(path, "path");
Intrinsics.checkNotNullParameter(this, "<this>");
Intrinsics.checkNotNullParameter(path, "path");
return f(path) != null;
}
public abstract List d(z zVar);
public final m e(z path) {
Intrinsics.checkNotNullParameter(path, "path");
Intrinsics.checkNotNullParameter(this, "<this>");
Intrinsics.checkNotNullParameter(path, "path");
m f2 = f(path);
if (f2 != null) {
return f2;
}
throw new FileNotFoundException("no such file: " + path);
}
public abstract m f(z zVar);
public abstract G g(z zVar);
public abstract I h(z zVar);
}

View File

@@ -0,0 +1,40 @@
package r3;
import kotlin.jvm.internal.Intrinsics;
/* loaded from: classes3.dex */
public abstract class o implements G {
/* renamed from: a, reason: collision with root package name */
public final G f8300a;
public o(G delegate) {
Intrinsics.checkNotNullParameter(delegate, "delegate");
this.f8300a = delegate;
}
@Override // r3.G, java.io.Closeable, java.lang.AutoCloseable
public void close() {
this.f8300a.close();
}
@Override // r3.G, java.io.Flushable
public void flush() {
this.f8300a.flush();
}
@Override // r3.G
public final K timeout() {
return this.f8300a.timeout();
}
public final String toString() {
return getClass().getSimpleName() + '(' + this.f8300a + ')';
}
@Override // r3.G
public void z(C0576h source, long j4) {
Intrinsics.checkNotNullParameter(source, "source");
this.f8300a.z(source, j4);
}
}

View File

@@ -0,0 +1,50 @@
package r3;
import java.io.IOException;
import kotlin.Deprecated;
import kotlin.DeprecationLevel;
import kotlin.ReplaceWith;
import kotlin.jvm.JvmName;
import kotlin.jvm.internal.Intrinsics;
/* loaded from: classes3.dex */
public abstract class p implements I {
private final I delegate;
public p(I delegate) {
Intrinsics.checkNotNullParameter(delegate, "delegate");
this.delegate = delegate;
}
@Deprecated(level = DeprecationLevel.ERROR, message = "moved to val", replaceWith = @ReplaceWith(expression = "delegate", imports = {}))
@JvmName(name = "-deprecated_delegate")
/* renamed from: -deprecated_delegate, reason: not valid java name */
public final I m1713deprecated_delegate() {
return this.delegate;
}
@Override // java.io.Closeable, java.lang.AutoCloseable
public void close() throws IOException {
this.delegate.close();
}
@JvmName(name = "delegate")
public final I delegate() {
return this.delegate;
}
@Override // r3.I
public long read(C0576h sink, long j4) {
Intrinsics.checkNotNullParameter(sink, "sink");
return this.delegate.read(sink, j4);
}
@Override // r3.I
public K timeout() {
return this.delegate.timeout();
}
public String toString() {
return getClass().getSimpleName() + '(' + this.delegate + ')';
}
}

View File

@@ -0,0 +1,53 @@
package r3;
import java.util.concurrent.TimeUnit;
import kotlin.jvm.internal.Intrinsics;
/* loaded from: classes3.dex */
public final class q extends K {
/* renamed from: e, reason: collision with root package name */
public K f8301e;
public q(K delegate) {
Intrinsics.checkNotNullParameter(delegate, "delegate");
this.f8301e = delegate;
}
@Override // r3.K
public final K a() {
return this.f8301e.a();
}
@Override // r3.K
public final K b() {
return this.f8301e.b();
}
@Override // r3.K
public final long c() {
return this.f8301e.c();
}
@Override // r3.K
public final K d(long j4) {
return this.f8301e.d(j4);
}
@Override // r3.K
public final boolean e() {
return this.f8301e.e();
}
@Override // r3.K
public final void f() {
this.f8301e.f();
}
@Override // r3.K
public final K g(long j4) {
TimeUnit unit = TimeUnit.MILLISECONDS;
Intrinsics.checkNotNullParameter(unit, "unit");
return this.f8301e.g(j4);
}
}

View File

@@ -0,0 +1,163 @@
package r3;
import java.io.EOFException;
import java.io.IOException;
import java.util.zip.CRC32;
import java.util.zip.Inflater;
import kotlin.UShort;
import kotlin.jvm.internal.Intrinsics;
import kotlin.jvm.internal.LongCompanionObject;
/* loaded from: classes3.dex */
public final class r implements I {
/* renamed from: a, reason: collision with root package name */
public byte f8302a;
/* renamed from: b, reason: collision with root package name */
public final C f8303b;
/* renamed from: c, reason: collision with root package name */
public final Inflater f8304c;
/* renamed from: d, reason: collision with root package name */
public final s f8305d;
/* renamed from: e, reason: collision with root package name */
public final CRC32 f8306e;
public r(I source) {
Intrinsics.checkNotNullParameter(source, "source");
C c4 = new C(source);
this.f8303b = c4;
Inflater inflater = new Inflater(true);
this.f8304c = inflater;
this.f8305d = new s(c4, inflater);
this.f8306e = new CRC32();
}
public static void d(String str, int i, int i4) {
if (i4 != i) {
throw new IOException(C.w.s(new Object[]{str, Integer.valueOf(i4), Integer.valueOf(i)}, 3, "%s: actual 0x%08x != expected 0x%08x", "format(this, *args)"));
}
}
@Override // java.io.Closeable, java.lang.AutoCloseable
public final void close() {
this.f8305d.close();
}
public final void e(C0576h c0576h, long j4, long j5) {
D d4 = c0576h.f8283a;
Intrinsics.checkNotNull(d4);
while (true) {
int i = d4.f8250c;
int i4 = d4.f8249b;
if (j4 < i - i4) {
break;
}
j4 -= i - i4;
d4 = d4.f8253f;
Intrinsics.checkNotNull(d4);
}
while (j5 > 0) {
int min = (int) Math.min(d4.f8250c - r6, j5);
this.f8306e.update(d4.f8248a, (int) (d4.f8249b + j4), min);
j5 -= min;
d4 = d4.f8253f;
Intrinsics.checkNotNull(d4);
j4 = 0;
}
}
@Override // r3.I
public final long read(C0576h sink, long j4) {
r rVar = this;
Intrinsics.checkNotNullParameter(sink, "sink");
if (j4 < 0) {
throw new IllegalArgumentException(C.w.l("byteCount < 0: ", j4).toString());
}
if (j4 == 0) {
return 0L;
}
byte b4 = rVar.f8302a;
CRC32 crc32 = rVar.f8306e;
C c4 = rVar.f8303b;
if (b4 == 0) {
c4.P(10L);
C0576h c0576h = c4.f8246b;
byte O2 = c0576h.O(3L);
boolean z3 = ((O2 >> 1) & 1) == 1;
if (z3) {
rVar.e(c0576h, 0L, 10L);
}
d("ID1ID2", 8075, c4.readShort());
c4.l(8L);
if (((O2 >> 2) & 1) == 1) {
c4.P(2L);
if (z3) {
e(c0576h, 0L, 2L);
}
long c02 = c0576h.c0() & UShort.MAX_VALUE;
c4.P(c02);
if (z3) {
e(c0576h, 0L, c02);
}
c4.l(c02);
}
if (((O2 >> 3) & 1) == 1) {
long e4 = c4.e((byte) 0, 0L, LongCompanionObject.MAX_VALUE);
if (e4 == -1) {
throw new EOFException();
}
if (z3) {
e(c0576h, 0L, e4 + 1);
}
c4.l(e4 + 1);
}
if (((O2 >> 4) & 1) == 1) {
long e5 = c4.e((byte) 0, 0L, LongCompanionObject.MAX_VALUE);
if (e5 == -1) {
throw new EOFException();
}
if (z3) {
rVar = this;
rVar.e(c0576h, 0L, e5 + 1);
} else {
rVar = this;
}
c4.l(e5 + 1);
} else {
rVar = this;
}
if (z3) {
d("FHCRC", c4.Y(), (short) crc32.getValue());
crc32.reset();
}
rVar.f8302a = (byte) 1;
}
if (rVar.f8302a == 1) {
long j5 = sink.f8284b;
long read = rVar.f8305d.read(sink, j4);
if (read != -1) {
rVar.e(sink, j5, read);
return read;
}
rVar.f8302a = (byte) 2;
}
if (rVar.f8302a == 2) {
d("CRC", c4.x(), (int) crc32.getValue());
d("ISIZE", c4.x(), (int) rVar.f8304c.getBytesWritten());
rVar.f8302a = (byte) 3;
if (!c4.d()) {
throw new IOException("gzip finished without exhausting source");
}
}
return -1L;
}
@Override // r3.I
public final K timeout() {
return this.f8303b.f8245a.timeout();
}
}

View File

@@ -0,0 +1,168 @@
package r3;
import java.util.zip.Inflater;
import kotlin.jvm.internal.Intrinsics;
/* loaded from: classes3.dex */
public final class s implements I {
/* renamed from: a, reason: collision with root package name */
public final C f8307a;
/* renamed from: b, reason: collision with root package name */
public final Inflater f8308b;
/* renamed from: c, reason: collision with root package name */
public int f8309c;
/* renamed from: d, reason: collision with root package name */
public boolean f8310d;
public s(C source, Inflater inflater) {
Intrinsics.checkNotNullParameter(source, "source");
Intrinsics.checkNotNullParameter(inflater, "inflater");
this.f8307a = source;
this.f8308b = inflater;
}
@Override // java.io.Closeable, java.lang.AutoCloseable
public final void close() {
if (this.f8310d) {
return;
}
this.f8308b.end();
this.f8310d = true;
this.f8307a.close();
}
/* JADX WARN: Removed duplicated region for block: B:11:0x0088 */
/* JADX WARN: Removed duplicated region for block: B:26:0x0087 A[SYNTHETIC] */
@Override // r3.I
/*
Code decompiled incorrectly, please refer to instructions dump.
To view partially-correct add '--show-bad-code' argument
*/
public final long read(r3.C0576h r12, long r13) {
/*
r11 = this;
java.lang.String r0 = "sink"
kotlin.jvm.internal.Intrinsics.checkNotNullParameter(r12, r0)
L5:
kotlin.jvm.internal.Intrinsics.checkNotNullParameter(r12, r0)
r1 = 0
int r3 = (r13 > r1 ? 1 : (r13 == r1 ? 0 : -1))
if (r3 < 0) goto Lb7
boolean r4 = r11.f8310d
if (r4 != 0) goto Laf
r3.C r4 = r11.f8307a
java.util.zip.Inflater r5 = r11.f8308b
if (r3 != 0) goto L1a
L18:
r9 = r1
goto L83
L1a:
r3 = 1
r3.D r3 = r12.g0(r3) // Catch: java.util.zip.DataFormatException -> La8
int r6 = r3.f8250c // Catch: java.util.zip.DataFormatException -> La8
int r6 = 8192 - r6
long r6 = (long) r6 // Catch: java.util.zip.DataFormatException -> La8
long r6 = java.lang.Math.min(r13, r6) // Catch: java.util.zip.DataFormatException -> La8
int r6 = (int) r6 // Catch: java.util.zip.DataFormatException -> La8
boolean r7 = r5.needsInput() // Catch: java.util.zip.DataFormatException -> La8
if (r7 != 0) goto L30
goto L4a
L30:
boolean r7 = r4.d() // Catch: java.util.zip.DataFormatException -> La8
if (r7 == 0) goto L37
goto L4a
L37:
r3.h r7 = r4.f8246b // Catch: java.util.zip.DataFormatException -> La8
r3.D r7 = r7.f8283a // Catch: java.util.zip.DataFormatException -> La8
kotlin.jvm.internal.Intrinsics.checkNotNull(r7) // Catch: java.util.zip.DataFormatException -> La8
int r8 = r7.f8250c // Catch: java.util.zip.DataFormatException -> La8
int r9 = r7.f8249b // Catch: java.util.zip.DataFormatException -> La8
int r8 = r8 - r9
r11.f8309c = r8 // Catch: java.util.zip.DataFormatException -> La8
byte[] r7 = r7.f8248a // Catch: java.util.zip.DataFormatException -> La8
r5.setInput(r7, r9, r8) // Catch: java.util.zip.DataFormatException -> La8
L4a:
byte[] r7 = r3.f8248a // Catch: java.util.zip.DataFormatException -> La8
int r8 = r3.f8250c // Catch: java.util.zip.DataFormatException -> La8
int r6 = r5.inflate(r7, r8, r6) // Catch: java.util.zip.DataFormatException -> La8
int r7 = r11.f8309c // Catch: java.util.zip.DataFormatException -> La8
if (r7 != 0) goto L57
goto L65
L57:
int r8 = r5.getRemaining() // Catch: java.util.zip.DataFormatException -> La8
int r7 = r7 - r8
int r8 = r11.f8309c // Catch: java.util.zip.DataFormatException -> La8
int r8 = r8 - r7
r11.f8309c = r8 // Catch: java.util.zip.DataFormatException -> La8
long r7 = (long) r7 // Catch: java.util.zip.DataFormatException -> La8
r4.l(r7) // Catch: java.util.zip.DataFormatException -> La8
L65:
if (r6 <= 0) goto L73
int r7 = r3.f8250c // Catch: java.util.zip.DataFormatException -> La8
int r7 = r7 + r6
r3.f8250c = r7 // Catch: java.util.zip.DataFormatException -> La8
long r7 = r12.f8284b // Catch: java.util.zip.DataFormatException -> La8
long r9 = (long) r6 // Catch: java.util.zip.DataFormatException -> La8
long r7 = r7 + r9
r12.f8284b = r7 // Catch: java.util.zip.DataFormatException -> La8
goto L83
L73:
int r6 = r3.f8249b // Catch: java.util.zip.DataFormatException -> La8
int r7 = r3.f8250c // Catch: java.util.zip.DataFormatException -> La8
if (r6 != r7) goto L18
r3.D r6 = r3.a() // Catch: java.util.zip.DataFormatException -> La8
r12.f8283a = r6 // Catch: java.util.zip.DataFormatException -> La8
r3.E.a(r3) // Catch: java.util.zip.DataFormatException -> La8
goto L18
L83:
int r1 = (r9 > r1 ? 1 : (r9 == r1 ? 0 : -1))
if (r1 <= 0) goto L88
return r9
L88:
boolean r1 = r5.finished()
if (r1 != 0) goto La5
boolean r1 = r5.needsDictionary()
if (r1 == 0) goto L95
goto La5
L95:
boolean r1 = r4.d()
if (r1 != 0) goto L9d
goto L5
L9d:
java.io.EOFException r11 = new java.io.EOFException
java.lang.String r12 = "source exhausted prematurely"
r11.<init>(r12)
throw r11
La5:
r11 = -1
return r11
La8:
r11 = move-exception
java.io.IOException r12 = new java.io.IOException
r12.<init>(r11)
throw r12
Laf:
java.lang.IllegalStateException r11 = new java.lang.IllegalStateException
java.lang.String r12 = "closed"
r11.<init>(r12)
throw r11
Lb7:
java.lang.String r11 = "byteCount < 0: "
java.lang.String r11 = C.w.l(r11, r13)
java.lang.IllegalArgumentException r12 = new java.lang.IllegalArgumentException
java.lang.String r11 = r11.toString()
r12.<init>(r11)
throw r12
*/
throw new UnsupportedOperationException("Method not decompiled: r3.s.read(r3.h, long):long");
}
@Override // r3.I
public final K timeout() {
return this.f8307a.f8245a.timeout();
}
}

View File

@@ -0,0 +1,84 @@
package r3;
import java.io.Closeable;
import java.io.RandomAccessFile;
import java.util.concurrent.locks.ReentrantLock;
import kotlin.Unit;
import kotlin.jvm.internal.Intrinsics;
/* loaded from: classes3.dex */
public final class t implements Closeable {
/* renamed from: a, reason: collision with root package name */
public boolean f8311a;
/* renamed from: b, reason: collision with root package name */
public int f8312b;
/* renamed from: c, reason: collision with root package name */
public final ReentrantLock f8313c;
/* renamed from: d, reason: collision with root package name */
public final RandomAccessFile f8314d;
public t(RandomAccessFile randomAccessFile) {
Intrinsics.checkNotNullParameter(randomAccessFile, "randomAccessFile");
this.f8313c = new ReentrantLock();
this.f8314d = randomAccessFile;
}
@Override // java.io.Closeable, java.lang.AutoCloseable
public final void close() {
ReentrantLock reentrantLock = this.f8313c;
reentrantLock.lock();
try {
if (this.f8311a) {
return;
}
this.f8311a = true;
if (this.f8312b != 0) {
return;
}
Unit unit = Unit.INSTANCE;
synchronized (this) {
this.f8314d.close();
}
} finally {
reentrantLock.unlock();
}
}
public final long d() {
long length;
ReentrantLock reentrantLock = this.f8313c;
reentrantLock.lock();
try {
if (this.f8311a) {
throw new IllegalStateException("closed");
}
Unit unit = Unit.INSTANCE;
synchronized (this) {
length = this.f8314d.length();
}
return length;
} finally {
reentrantLock.unlock();
}
}
public final C0580l e(long j4) {
ReentrantLock reentrantLock = this.f8313c;
reentrantLock.lock();
try {
if (this.f8311a) {
throw new IllegalStateException("closed");
}
this.f8312b++;
reentrantLock.unlock();
return new C0580l(this, j4);
} catch (Throwable th) {
reentrantLock.unlock();
throw th;
}
}
}

View File

@@ -0,0 +1,104 @@
package r3;
import java.io.File;
import java.io.FileInputStream;
import java.io.FileNotFoundException;
import java.io.FileOutputStream;
import java.io.IOException;
import java.io.InterruptedIOException;
import java.io.RandomAccessFile;
import java.util.ArrayList;
import java.util.List;
import java.util.logging.Logger;
import kotlin.collections.CollectionsKt;
import kotlin.jvm.internal.Intrinsics;
/* loaded from: classes3.dex */
public class u extends n {
@Override // r3.n
public final void a(z path) {
Intrinsics.checkNotNullParameter(path, "path");
if (Thread.interrupted()) {
throw new InterruptedIOException("interrupted");
}
File e4 = path.e();
if (e4.delete() || !e4.exists()) {
return;
}
throw new IOException("failed to delete " + path);
}
@Override // r3.n
public final List d(z dir) {
Intrinsics.checkNotNullParameter(dir, "dir");
File e4 = dir.e();
String[] list = e4.list();
if (list == null) {
if (e4.exists()) {
throw new IOException("failed to list " + dir);
}
throw new FileNotFoundException("no such file: " + dir);
}
ArrayList arrayList = new ArrayList();
for (String str : list) {
Intrinsics.checkNotNull(str);
arrayList.add(dir.d(str));
}
CollectionsKt.sort(arrayList);
Intrinsics.checkNotNull(arrayList);
return arrayList;
}
@Override // r3.n
public m f(z path) {
Intrinsics.checkNotNullParameter(path, "path");
File e4 = path.e();
boolean isFile = e4.isFile();
boolean isDirectory = e4.isDirectory();
long lastModified = e4.lastModified();
long length = e4.length();
if (!isFile && !isDirectory && lastModified == 0 && length == 0 && !e4.exists()) {
return null;
}
return new m(isFile, isDirectory, null, Long.valueOf(length), null, Long.valueOf(lastModified), null);
}
/* JADX WARN: Type inference failed for: r3v3, types: [java.lang.Object, r3.K] */
@Override // r3.n
public final G g(z file) {
Intrinsics.checkNotNullParameter(file, "file");
File e4 = file.e();
Logger logger = w.f8315a;
Intrinsics.checkNotNullParameter(e4, "<this>");
FileOutputStream fileOutputStream = new FileOutputStream(e4, false);
Intrinsics.checkNotNullParameter(fileOutputStream, "<this>");
return new y(fileOutputStream, new Object());
}
@Override // r3.n
public final I h(z file) {
Intrinsics.checkNotNullParameter(file, "file");
File e4 = file.e();
Logger logger = w.f8315a;
Intrinsics.checkNotNullParameter(e4, "<this>");
return new C0572d(new FileInputStream(e4), K.f8261d);
}
public void i(z source, z target) {
Intrinsics.checkNotNullParameter(source, "source");
Intrinsics.checkNotNullParameter(target, "target");
if (source.e().renameTo(target.e())) {
return;
}
throw new IOException("failed to move " + source + " to " + target);
}
public final t j(z file) {
Intrinsics.checkNotNullParameter(file, "file");
return new t(new RandomAccessFile(file.e(), "r"));
}
public String toString() {
return "JvmSystemFileSystem";
}
}

View File

@@ -0,0 +1,74 @@
package r3;
import f0.C0338b;
import java.io.FileNotFoundException;
import java.io.IOException;
import java.nio.file.FileSystemException;
import java.nio.file.Files;
import java.nio.file.LinkOption;
import java.nio.file.NoSuchFileException;
import java.nio.file.Path;
import java.nio.file.StandardCopyOption;
import java.nio.file.attribute.BasicFileAttributes;
import java.nio.file.attribute.FileTime;
import kotlin.jvm.internal.Intrinsics;
/* loaded from: classes3.dex */
public final class v extends u {
public static Long k(FileTime fileTime) {
long millis = fileTime.toMillis();
Long valueOf = Long.valueOf(millis);
if (millis != 0) {
return valueOf;
}
return null;
}
@Override // r3.u, r3.n
public final m f(z path) {
z zVar;
Intrinsics.checkNotNullParameter(path, "path");
Path nioPath = path.f();
Intrinsics.checkNotNullParameter(nioPath, "nioPath");
try {
BasicFileAttributes readAttributes = Files.readAttributes(nioPath, (Class<BasicFileAttributes>) BasicFileAttributes.class, LinkOption.NOFOLLOW_LINKS);
Path readSymbolicLink = readAttributes.isSymbolicLink() ? Files.readSymbolicLink(nioPath) : null;
boolean isRegularFile = readAttributes.isRegularFile();
boolean isDirectory = readAttributes.isDirectory();
if (readSymbolicLink != null) {
String str = z.f8321b;
Intrinsics.checkNotNullParameter(readSymbolicLink, "<this>");
zVar = C0338b.o(readSymbolicLink.toString());
} else {
zVar = null;
}
Long valueOf = Long.valueOf(readAttributes.size());
FileTime creationTime = readAttributes.creationTime();
Long k4 = creationTime != null ? k(creationTime) : null;
FileTime lastModifiedTime = readAttributes.lastModifiedTime();
Long k5 = lastModifiedTime != null ? k(lastModifiedTime) : null;
FileTime lastAccessTime = readAttributes.lastAccessTime();
return new m(isRegularFile, isDirectory, zVar, valueOf, k4, k5, lastAccessTime != null ? k(lastAccessTime) : null);
} catch (NoSuchFileException | FileSystemException unused) {
return null;
}
}
@Override // r3.u
public final void i(z source, z target) {
Intrinsics.checkNotNullParameter(source, "source");
Intrinsics.checkNotNullParameter(target, "target");
try {
Files.move(source.f(), target.f(), StandardCopyOption.ATOMIC_MOVE, StandardCopyOption.REPLACE_EXISTING);
} catch (UnsupportedOperationException unused) {
throw new IOException("atomic move not supported");
} catch (NoSuchFileException e4) {
throw new FileNotFoundException(e4.getMessage());
}
}
@Override // r3.u
public final String toString() {
return "NioSystemFileSystem";
}
}

View File

@@ -0,0 +1,10 @@
package r3;
import java.util.logging.Logger;
/* loaded from: classes3.dex */
public abstract /* synthetic */ class w {
/* renamed from: a, reason: collision with root package name */
public static final Logger f8315a = Logger.getLogger("okio.Okio");
}

View File

@@ -0,0 +1,57 @@
package r3;
import java.util.RandomAccess;
import kotlin.collections.AbstractList;
/* loaded from: classes3.dex */
public final class x extends AbstractList implements RandomAccess {
/* renamed from: c, reason: collision with root package name */
public static final /* synthetic */ int f8316c = 0;
/* renamed from: a, reason: collision with root package name */
public final C0579k[] f8317a;
/* renamed from: b, reason: collision with root package name */
public final int[] f8318b;
public x(C0579k[] c0579kArr, int[] iArr) {
this.f8317a = c0579kArr;
this.f8318b = iArr;
}
@Override // kotlin.collections.AbstractCollection, java.util.Collection
public final /* bridge */ boolean contains(Object obj) {
if (obj instanceof C0579k) {
return super.contains((C0579k) obj);
}
return false;
}
@Override // kotlin.collections.AbstractList, java.util.List
public final Object get(int i) {
return this.f8317a[i];
}
@Override // kotlin.collections.AbstractList, kotlin.collections.AbstractCollection
/* renamed from: getSize */
public final int get_size() {
return this.f8317a.length;
}
@Override // kotlin.collections.AbstractList, java.util.List
public final /* bridge */ int indexOf(Object obj) {
if (obj instanceof C0579k) {
return super.indexOf((C0579k) obj);
}
return -1;
}
@Override // kotlin.collections.AbstractList, java.util.List
public final /* bridge */ int lastIndexOf(Object obj) {
if (obj instanceof C0579k) {
return super.lastIndexOf((C0579k) obj);
}
return -1;
}
}

View File

@@ -0,0 +1,62 @@
package r3;
import java.io.OutputStream;
import kotlin.jvm.internal.Intrinsics;
/* loaded from: classes3.dex */
public final class y implements G {
/* renamed from: a, reason: collision with root package name */
public final OutputStream f8319a;
/* renamed from: b, reason: collision with root package name */
public final K f8320b;
public y(OutputStream out, K timeout) {
Intrinsics.checkNotNullParameter(out, "out");
Intrinsics.checkNotNullParameter(timeout, "timeout");
this.f8319a = out;
this.f8320b = timeout;
}
@Override // r3.G, java.io.Closeable, java.lang.AutoCloseable
public final void close() {
this.f8319a.close();
}
@Override // r3.G, java.io.Flushable
public final void flush() {
this.f8319a.flush();
}
@Override // r3.G
public final K timeout() {
return this.f8320b;
}
public final String toString() {
return "sink(" + this.f8319a + ')';
}
@Override // r3.G
public final void z(C0576h source, long j4) {
Intrinsics.checkNotNullParameter(source, "source");
m3.d.j(source.f8284b, 0L, j4);
while (j4 > 0) {
this.f8320b.f();
D d4 = source.f8283a;
Intrinsics.checkNotNull(d4);
int min = (int) Math.min(j4, d4.f8250c - d4.f8249b);
this.f8319a.write(d4.f8248a, d4.f8249b, min);
int i = d4.f8249b + min;
d4.f8249b = i;
long j5 = min;
j4 -= j5;
source.f8284b -= j5;
if (i == d4.f8250c) {
source.f8283a = d4.a();
E.a(d4);
}
}
}
}

View File

@@ -0,0 +1,194 @@
package r3;
import f0.C0338b;
import java.io.File;
import java.nio.file.Path;
import java.nio.file.Paths;
import java.util.ArrayList;
import kotlin.jvm.internal.Intrinsics;
/* loaded from: classes3.dex */
public final class z implements Comparable {
/* renamed from: b, reason: collision with root package name */
public static final String f8321b;
/* renamed from: a, reason: collision with root package name */
public final C0579k f8322a;
static {
String separator = File.separator;
Intrinsics.checkNotNullExpressionValue(separator, "separator");
f8321b = separator;
}
public z(C0579k bytes) {
Intrinsics.checkNotNullParameter(bytes, "bytes");
this.f8322a = bytes;
}
public final ArrayList a() {
ArrayList arrayList = new ArrayList();
int a2 = s3.c.a(this);
C0579k c0579k = this.f8322a;
if (a2 == -1) {
a2 = 0;
} else if (a2 < c0579k.d() && c0579k.i(a2) == 92) {
a2++;
}
int d4 = c0579k.d();
int i = a2;
while (a2 < d4) {
if (c0579k.i(a2) == 47 || c0579k.i(a2) == 92) {
arrayList.add(c0579k.n(i, a2));
i = a2 + 1;
}
a2++;
}
if (i < c0579k.d()) {
arrayList.add(c0579k.n(i, c0579k.d()));
}
return arrayList;
}
public final z b() {
C0579k c0579k = s3.c.f8477d;
C0579k c0579k2 = this.f8322a;
if (Intrinsics.areEqual(c0579k2, c0579k)) {
return null;
}
C0579k c0579k3 = s3.c.f8474a;
if (Intrinsics.areEqual(c0579k2, c0579k3)) {
return null;
}
C0579k prefix = s3.c.f8475b;
if (Intrinsics.areEqual(c0579k2, prefix)) {
return null;
}
C0579k suffix = s3.c.f8478e;
c0579k2.getClass();
Intrinsics.checkNotNullParameter(suffix, "suffix");
int d4 = c0579k2.d();
byte[] bArr = suffix.f8286a;
if (c0579k2.l(d4 - bArr.length, suffix, bArr.length) && (c0579k2.d() == 2 || c0579k2.l(c0579k2.d() - 3, c0579k3, 1) || c0579k2.l(c0579k2.d() - 3, prefix, 1))) {
return null;
}
int k4 = C0579k.k(c0579k2, c0579k3);
if (k4 == -1) {
k4 = C0579k.k(c0579k2, prefix);
}
if (k4 == 2 && g() != null) {
if (c0579k2.d() == 3) {
return null;
}
return new z(C0579k.o(c0579k2, 0, 3, 1));
}
if (k4 == 1) {
Intrinsics.checkNotNullParameter(prefix, "prefix");
if (c0579k2.l(0, prefix, prefix.d())) {
return null;
}
}
if (k4 != -1 || g() == null) {
return k4 == -1 ? new z(c0579k) : k4 == 0 ? new z(C0579k.o(c0579k2, 0, 1, 1)) : new z(C0579k.o(c0579k2, 0, k4, 1));
}
if (c0579k2.d() == 2) {
return null;
}
return new z(C0579k.o(c0579k2, 0, 2, 1));
}
/* JADX WARN: Type inference failed for: r1v6, types: [java.lang.Object, r3.h] */
public final z c(z other) {
Intrinsics.checkNotNullParameter(other, "other");
int a2 = s3.c.a(this);
C0579k c0579k = this.f8322a;
z zVar = a2 == -1 ? null : new z(c0579k.n(0, a2));
other.getClass();
int a4 = s3.c.a(other);
C0579k c0579k2 = other.f8322a;
if (!Intrinsics.areEqual(zVar, a4 != -1 ? new z(c0579k2.n(0, a4)) : null)) {
throw new IllegalArgumentException(("Paths of different roots cannot be relative to each other: " + this + " and " + other).toString());
}
ArrayList a5 = a();
ArrayList a6 = other.a();
int min = Math.min(a5.size(), a6.size());
int i = 0;
while (i < min && Intrinsics.areEqual(a5.get(i), a6.get(i))) {
i++;
}
if (i == min && c0579k.d() == c0579k2.d()) {
return C0338b.o(".");
}
if (a6.subList(i, a6.size()).indexOf(s3.c.f8478e) != -1) {
throw new IllegalArgumentException(("Impossible relative path to resolve: " + this + " and " + other).toString());
}
?? obj = new Object();
C0579k c4 = s3.c.c(other);
if (c4 == null && (c4 = s3.c.c(this)) == null) {
c4 = s3.c.f(f8321b);
}
int size = a6.size();
for (int i4 = i; i4 < size; i4++) {
obj.h0(s3.c.f8478e);
obj.h0(c4);
}
int size2 = a5.size();
while (i < size2) {
obj.h0((C0579k) a5.get(i));
obj.h0(c4);
i++;
}
return s3.c.d(obj, false);
}
@Override // java.lang.Comparable
public final int compareTo(Object obj) {
z other = (z) obj;
Intrinsics.checkNotNullParameter(other, "other");
return this.f8322a.compareTo(other.f8322a);
}
/* JADX WARN: Type inference failed for: r0v1, types: [java.lang.Object, r3.h] */
public final z d(String child) {
Intrinsics.checkNotNullParameter(child, "child");
?? obj = new Object();
obj.o0(child);
return s3.c.b(this, s3.c.d(obj, false), false);
}
public final File e() {
return new File(this.f8322a.q());
}
public final boolean equals(Object obj) {
return (obj instanceof z) && Intrinsics.areEqual(((z) obj).f8322a, this.f8322a);
}
public final Path f() {
Path path = Paths.get(this.f8322a.q(), new String[0]);
Intrinsics.checkNotNullExpressionValue(path, "get(...)");
return path;
}
public final Character g() {
C0579k c0579k = s3.c.f8474a;
C0579k c0579k2 = this.f8322a;
if (C0579k.g(c0579k2, c0579k) != -1 || c0579k2.d() < 2 || c0579k2.i(1) != 58) {
return null;
}
char i = (char) c0579k2.i(0);
if (('a' > i || i >= '{') && ('A' > i || i >= '[')) {
return null;
}
return Character.valueOf(i);
}
public final int hashCode() {
return this.f8322a.hashCode();
}
public final String toString() {
return this.f8322a.q();
}
}