package com.google.gson.stream; import android.graphics.PointF; import android.os.SystemClock; import android.telephony.cdma.CdmaCellLocation; import android.text.TextUtils; import android.util.TypedValue; import android.view.KeyEvent; import android.view.View; import android.view.ViewConfiguration; import com.airbnb.deeplinkdispatch.UrlTreeKt; import com.google.android.gms.maps.model.BitmapDescriptorFactory; import com.pingan.ai.p; import java.io.Closeable; import java.io.Flushable; import java.io.IOException; import java.io.Writer; import java.lang.reflect.Method; import java.util.Arrays; import o.Nhs; import o.xzZ; /* loaded from: classes.dex */ public class JsonWriter implements Closeable, Flushable { private static final String[] HTML_SAFE_REPLACEMENT_CHARS; private static final String[] REPLACEMENT_CHARS; private static long a; private static char b; private static int d; private static int e; private String deferredName; private boolean htmlSafe; private String indent; private boolean lenient; private final Writer out; private String separator; private boolean serializeNulls; private int[] stack = new int[32]; private int stackSize = 0; private static final byte[] $$a = {39, 47, 87, -72}; private static final int $$b = 59; private static int $10 = 0; private static int $11 = 1; private static int c = 1; private static void g(int i, int i2, byte b2, Object[] objArr) { int i3 = i2 + 114; byte[] bArr = $$a; int i4 = i * 2; int i5 = 4 - (b2 * 2); byte[] bArr2 = new byte[i4 + 1]; int i6 = -1; if (bArr == null) { i3 = i4 + i3; i5++; } while (true) { i6++; bArr2[i6] = (byte) i3; if (i6 == i4) { objArr[0] = new String(bArr2, 0); return; } else { i3 += bArr[i5]; i5++; } } } private static void f(char c2, int i, char[] cArr, char[] cArr2, char[] cArr3, Object[] objArr) { int i2 = 2; int i3 = 2 % 2; Nhs nhs = new Nhs(); int length = cArr.length; char[] cArr4 = new char[length]; int length2 = cArr3.length; char[] cArr5 = new char[length2]; System.arraycopy(cArr, 0, cArr4, 0, length); System.arraycopy(cArr3, 0, cArr5, 0, length2); cArr4[0] = (char) (cArr4[0] ^ c2); cArr5[2] = (char) (cArr5[2] + ((char) i)); int length3 = cArr2.length; char[] cArr6 = new char[length3]; nhs.a = 0; int i4 = $10 + 81; $11 = i4 % 128; int i5 = i4 % 2; while (nhs.a < length3) { int i6 = $10 + 5; $11 = i6 % 128; int i7 = i6 % i2; try { Object[] objArr2 = {nhs}; Object obj = xzZ.y.get(263693715); if (obj == null) { obj = ((Class) xzZ.c(46 - (SystemClock.elapsedRealtimeNanos() > 0L ? 1 : (SystemClock.elapsedRealtimeNanos() == 0L ? 0 : -1)), 6 - (ViewConfiguration.getZoomControlsTimeout() > 0L ? 1 : (ViewConfiguration.getZoomControlsTimeout() == 0L ? 0 : -1)), (char) View.resolveSize(0, 0))).getMethod("t", Object.class); xzZ.y.put(263693715, obj); } int intValue = ((Integer) ((Method) obj).invoke(null, objArr2)).intValue(); try { Object[] objArr3 = {nhs}; Object obj2 = xzZ.y.get(-484664112); if (obj2 == null) { Class cls = (Class) xzZ.c(352 - View.resolveSizeAndState(0, 0, 0), (TypedValue.complexToFloat(0) > BitmapDescriptorFactory.HUE_RED ? 1 : (TypedValue.complexToFloat(0) == BitmapDescriptorFactory.HUE_RED ? 0 : -1)) + 5, (char) (KeyEvent.getDeadChar(0, 0) + 52128)); byte b2 = (byte) 0; byte b3 = (byte) (b2 + 1); Object[] objArr4 = new Object[1]; g(b2, b3, (byte) (b3 - 1), objArr4); obj2 = cls.getMethod((String) objArr4[0], Object.class); xzZ.y.put(-484664112, obj2); } int intValue2 = ((Integer) ((Method) obj2).invoke(null, objArr3)).intValue(); try { Object[] objArr5 = {nhs, Integer.valueOf(cArr4[nhs.a % 4] * 32718), Integer.valueOf(cArr5[intValue])}; Object obj3 = xzZ.y.get(430099516); if (obj3 == null) { obj3 = ((Class) xzZ.c(748 - TextUtils.getOffsetAfter("", 0), 6 - (ViewConfiguration.getScrollFriction() > BitmapDescriptorFactory.HUE_RED ? 1 : (ViewConfiguration.getScrollFriction() == BitmapDescriptorFactory.HUE_RED ? 0 : -1)), (char) (ViewConfiguration.getMaximumFlingVelocity() >> 16))).getMethod(p.a, Object.class, Integer.TYPE, Integer.TYPE); xzZ.y.put(430099516, obj3); } ((Method) obj3).invoke(null, objArr5); try { Object[] objArr6 = {Integer.valueOf(cArr4[intValue2] * 32718), Integer.valueOf(cArr5[intValue])}; Object obj4 = xzZ.y.get(1019894806); if (obj4 == null) { Class cls2 = (Class) xzZ.c(View.getDefaultSize(0, 0) + 402, 5 - (PointF.length(BitmapDescriptorFactory.HUE_RED, BitmapDescriptorFactory.HUE_RED) > BitmapDescriptorFactory.HUE_RED ? 1 : (PointF.length(BitmapDescriptorFactory.HUE_RED, BitmapDescriptorFactory.HUE_RED) == BitmapDescriptorFactory.HUE_RED ? 0 : -1)), (char) ((ViewConfiguration.getJumpTapTimeout() >> 16) + 21608)); byte b4 = (byte) 0; byte b5 = b4; Object[] objArr7 = new Object[1]; g(b4, b5, b5, objArr7); obj4 = cls2.getMethod((String) objArr7[0], Integer.TYPE, Integer.TYPE); xzZ.y.put(1019894806, obj4); } cArr5[intValue2] = ((Character) ((Method) obj4).invoke(null, objArr6)).charValue(); cArr4[intValue2] = nhs.c; cArr6[nhs.a] = (char) ((((cArr4[intValue2] ^ cArr2[nhs.a]) ^ (a ^ 9051040786702654117L)) ^ ((int) (e ^ 9051040786702654117L))) ^ ((char) (b ^ 9051040786702654117L))); nhs.a++; int i8 = $11 + 11; $10 = i8 % 128; int i9 = i8 % 2; i2 = 2; } catch (Throwable th) { Throwable cause = th.getCause(); if (cause == null) { throw th; } throw cause; } } catch (Throwable th2) { Throwable cause2 = th2.getCause(); if (cause2 == null) { throw th2; } throw cause2; } } catch (Throwable th3) { Throwable cause3 = th3.getCause(); if (cause3 == null) { throw th3; } throw cause3; } } catch (Throwable th4) { Throwable cause4 = th4.getCause(); if (cause4 == null) { throw th4; } throw cause4; } } objArr[0] = new String(cArr6); } static { d = 0; b(); REPLACEMENT_CHARS = new String[128]; int i = c + 39; d = i % 128; int i2 = i % 2; int i3 = 2 % 2; for (int i4 = 0; i4 <= 31; i4++) { int i5 = c + 83; d = i5 % 128; int i6 = i5 % 2; REPLACEMENT_CHARS[i4] = String.format("\\u%04x", Integer.valueOf(i4)); } String[] strArr = REPLACEMENT_CHARS; strArr[34] = "\\\""; strArr[92] = "\\\\"; strArr[9] = "\\t"; strArr[8] = "\\b"; strArr[10] = "\\n"; strArr[13] = "\\r"; strArr[12] = "\\f"; String[] strArr2 = (String[]) strArr.clone(); HTML_SAFE_REPLACEMENT_CHARS = strArr2; strArr2[60] = "\\u003c"; strArr2[62] = "\\u003e"; strArr2[38] = "\\u0026"; strArr2[61] = "\\u003d"; strArr2[39] = "\\u0027"; } public JsonWriter(Writer writer) { push(6); this.separator = ":"; this.serializeNulls = true; if (writer == null) { throw new NullPointerException("out == null"); } this.out = writer; int i = c + 99; d = i % 128; if (i % 2 == 0) { return; } Object obj = null; obj.hashCode(); throw null; } public final void setIndent(String str) { int i = 2 % 2; int i2 = d + 39; c = i2 % 128; Object obj = null; if (i2 % 2 == 0) { str.length(); obj.hashCode(); throw null; } if (str.length() == 0) { int i3 = d + 7; c = i3 % 128; int i4 = i3 % 2; this.indent = null; this.separator = ":"; return; } this.indent = str; this.separator = ": "; int i5 = c + 47; d = i5 % 128; int i6 = i5 % 2; } public JsonWriter beginArray() throws IOException { int i; char c2; int i2 = 2 % 2; int i3 = d + 59; c = i3 % 128; if (i3 % 2 == 0) { writeDeferredName(); i = 0; c2 = 'D'; } else { writeDeferredName(); i = 1; c2 = '['; } JsonWriter open = open(i, c2); int i4 = d + 35; c = i4 % 128; int i5 = i4 % 2; return open; } public JsonWriter endArray() throws IOException { int i = 2 % 2; int i2 = d + 101; c = i2 % 128; return i2 % 2 == 0 ? close(0, 5, UrlTreeKt.configurablePathSegmentPrefixChar) : close(1, 2, ']'); } public JsonWriter beginObject() throws IOException { char c2; int i = 2; int i2 = 2 % 2; int i3 = c + 107; d = i3 % 128; if (i3 % 2 != 0) { writeDeferredName(); c2 = 'w'; } else { writeDeferredName(); i = 3; c2 = UrlTreeKt.componentParamPrefixChar; } return open(i, c2); } public JsonWriter endObject() throws IOException { int i = 2 % 2; int i2 = c + 57; d = i2 % 128; int i3 = i2 % 2; JsonWriter close = close(3, 5, UrlTreeKt.componentParamSuffixChar); int i4 = d + 7; c = i4 % 128; int i5 = i4 % 2; return close; } private JsonWriter open(int i, char c2) throws IOException { int i2 = 2 % 2; int i3 = c + 31; d = i3 % 128; int i4 = i3 % 2; beforeValue(); push(i); this.out.write(c2); int i5 = c + 123; d = i5 % 128; if (i5 % 2 == 0) { return this; } throw null; } private JsonWriter close(int i, int i2, char c2) throws IOException { int i3 = 2 % 2; int peek = peek(); if (peek != i2) { int i4 = d + 125; c = i4 % 128; int i5 = i4 % 2; if (peek != i) { throw new IllegalStateException("Nesting problem."); } } if (this.deferredName != null) { StringBuilder sb = new StringBuilder("Dangling name: "); sb.append(this.deferredName); throw new IllegalStateException(sb.toString()); } int i6 = c + 125; d = i6 % 128; int i7 = i6 % 2; this.stackSize--; if (peek == i2) { newline(); } this.out.write(c2); return this; } private void push(int i) { int i2 = 2 % 2; int i3 = this.stackSize; int[] iArr = this.stack; if (i3 == iArr.length) { int i4 = d + 3; c = i4 % 128; if (i4 % 2 == 0) { this.stack = Arrays.copyOf(iArr, i3); } else { this.stack = Arrays.copyOf(iArr, i3 << 1); } } int[] iArr2 = this.stack; int i5 = this.stackSize; this.stackSize = i5 + 1; iArr2[i5] = i; int i6 = d + 11; c = i6 % 128; if (i6 % 2 == 0) { int i7 = 64 / 0; } } private int peek() { int i = 2 % 2; int i2 = c + 89; int i3 = i2 % 128; d = i3; int i4 = i2 % 2; int i5 = this.stackSize; if (i5 != 0) { int i6 = i3 + 53; c = i6 % 128; return i6 % 2 == 0 ? this.stack[i5 % 0] : this.stack[i5 - 1]; } throw new IllegalStateException("JsonWriter is closed."); } private void replaceTop(int i) { int i2 = 2 % 2; int i3 = c; int i4 = i3 + 79; d = i4 % 128; int i5 = i4 % 2; this.stack[this.stackSize - 1] = i; int i6 = i3 + 53; d = i6 % 128; int i7 = i6 % 2; } /* JADX WARN: Code restructure failed: missing block: B:10:0x001b, code lost: r1 = r1 + 33; com.google.gson.stream.JsonWriter.c = r1 % 128; */ /* JADX WARN: Code restructure failed: missing block: B:11:0x0022, code lost: if ((r1 % 2) == 0) goto L18; */ /* JADX WARN: Code restructure failed: missing block: B:13:0x0026, code lost: if (r4.stackSize == 0) goto L16; */ /* JADX WARN: Code restructure failed: missing block: B:14:0x0028, code lost: r4.deferredName = r5; */ /* JADX WARN: Code restructure failed: missing block: B:15:0x002a, code lost: return r4; */ /* JADX WARN: Code restructure failed: missing block: B:17:0x0032, code lost: throw new java.lang.IllegalStateException("JsonWriter is closed."); */ /* JADX WARN: Code restructure failed: missing block: B:18:0x0033, code lost: r5 = null; r5.hashCode(); */ /* JADX WARN: Code restructure failed: missing block: B:19:0x0037, code lost: throw null; */ /* JADX WARN: Code restructure failed: missing block: B:21:0x003d, code lost: throw new java.lang.IllegalStateException(); */ /* JADX WARN: Code restructure failed: missing block: B:22:0x0015, code lost: if (r5 != null) goto L8; */ /* JADX WARN: Code restructure failed: missing block: B:4:0x0012, code lost: if (r5 != null) goto L8; */ /* JADX WARN: Code restructure failed: missing block: B:6:0x0045, code lost: throw new java.lang.NullPointerException("name == null"); */ /* JADX WARN: Code restructure failed: missing block: B:9:0x0019, code lost: if (r4.deferredName != null) goto L20; */ /* Code decompiled incorrectly, please refer to instructions dump. To view partially-correct add '--show-bad-code' argument */ public com.google.gson.stream.JsonWriter name(java.lang.String r5) throws java.io.IOException { /* r4 = this; r0 = 2 int r1 = r0 % r0 int r1 = com.google.gson.stream.JsonWriter.d int r2 = r1 + 25 int r3 = r2 % 128 com.google.gson.stream.JsonWriter.c = r3 int r2 = r2 % r0 if (r2 != 0) goto L15 r2 = 96 int r2 = r2 / 0 if (r5 == 0) goto L3e goto L17 L15: if (r5 == 0) goto L3e L17: java.lang.String r2 = r4.deferredName if (r2 != 0) goto L38 int r1 = r1 + 33 int r2 = r1 % 128 com.google.gson.stream.JsonWriter.c = r2 int r1 = r1 % r0 if (r1 == 0) goto L33 int r0 = r4.stackSize if (r0 == 0) goto L2b r4.deferredName = r5 return r4 L2b: java.lang.IllegalStateException r5 = new java.lang.IllegalStateException java.lang.String r0 = "JsonWriter is closed." r5.(r0) throw r5 L33: r5 = 0 r5.hashCode() throw r5 L38: java.lang.IllegalStateException r5 = new java.lang.IllegalStateException r5.() throw r5 L3e: java.lang.NullPointerException r5 = new java.lang.NullPointerException java.lang.String r0 = "name == null" r5.(r0) throw r5 */ throw new UnsupportedOperationException("Method not decompiled: com.google.gson.stream.JsonWriter.name(java.lang.String):com.google.gson.stream.JsonWriter"); } private void writeDeferredName() throws IOException { int i = 2 % 2; int i2 = d; int i3 = i2 + 105; c = i3 % 128; if (i3 % 2 == 0) { throw null; } if (this.deferredName != null) { int i4 = i2 + 9; c = i4 % 128; if (i4 % 2 != 0) { beforeName(); string(this.deferredName); this.deferredName = null; } else { beforeName(); string(this.deferredName); this.deferredName = null; int i5 = 88 / 0; } } } public JsonWriter value(String str) throws IOException { int i = 2 % 2; int i2 = d + 91; c = i2 % 128; Object obj = null; if (i2 % 2 == 0) { obj.hashCode(); throw null; } if (str == null) { JsonWriter nullValue = nullValue(); int i3 = d + 55; c = i3 % 128; if (i3 % 2 != 0) { return nullValue; } throw null; } writeDeferredName(); beforeValue(); string(str); return this; } public JsonWriter jsonValue(String str) throws IOException { int i = 2 % 2; int i2 = c + 75; d = i2 % 128; if (i2 % 2 != 0) { Object obj = null; obj.hashCode(); throw null; } if (str == null) { JsonWriter nullValue = nullValue(); int i3 = d + 53; c = i3 % 128; int i4 = i3 % 2; return nullValue; } writeDeferredName(); beforeValue(); this.out.append((CharSequence) str); return this; } public JsonWriter nullValue() throws IOException { int i = 2 % 2; if (this.deferredName != null) { if (!this.serializeNulls) { this.deferredName = null; return this; } int i2 = c + 67; d = i2 % 128; int i3 = i2 % 2; writeDeferredName(); int i4 = c + 99; d = i4 % 128; int i5 = i4 % 2; } beforeValue(); Writer writer = this.out; Object[] objArr = new Object[1]; f((char) (15722 - (CdmaCellLocation.convertQuartSecToDecDegrees(0) > 0.0d ? 1 : (CdmaCellLocation.convertQuartSecToDecDegrees(0) == 0.0d ? 0 : -1))), TextUtils.indexOf("", "", 0, 0), new char[]{44731, 33575, 27257, 573}, new char[]{48995, 28156, 31310, 57074}, new char[]{18803, 20310, 2949, 43469}, objArr); writer.write(((String) objArr[0]).intern()); return this; } public JsonWriter value(boolean z) throws IOException { String str; int i = 2 % 2; int i2 = d + 117; c = i2 % 128; Object obj = null; if (i2 % 2 != 0) { writeDeferredName(); beforeValue(); Writer writer = this.out; if (z) { int i3 = d + 59; c = i3 % 128; if (i3 % 2 != 0) { str = "true"; } else { obj.hashCode(); throw null; } } else { str = "false"; } writer.write(str); return this; } writeDeferredName(); beforeValue(); obj.hashCode(); throw null; } public JsonWriter value(Boolean bool) throws IOException { String str; int i = 2 % 2; if (bool == null) { int i2 = c + 3; d = i2 % 128; if (i2 % 2 == 0) { return nullValue(); } nullValue(); throw null; } writeDeferredName(); beforeValue(); Writer writer = this.out; if (bool.booleanValue()) { str = "true"; } else { int i3 = c + 95; d = i3 % 128; int i4 = i3 % 2; str = "false"; } writer.write(str); return this; } /* JADX WARN: Code restructure failed: missing block: B:10:0x0049, code lost: throw new java.lang.IllegalArgumentException("Numeric values must be finite, but was ".concat(java.lang.String.valueOf(r4))); */ /* JADX WARN: Code restructure failed: missing block: B:13:0x0037, code lost: if (java.lang.Double.isInfinite(r4) != false) goto L16; */ /* JADX WARN: Code restructure failed: missing block: B:15:0x0031, code lost: if (java.lang.Double.isNaN(r4) == false) goto L13; */ /* JADX WARN: Code restructure failed: missing block: B:8:0x002a, code lost: if ((!java.lang.Double.isNaN(r4)) == true) goto L13; */ /* Code decompiled incorrectly, please refer to instructions dump. To view partially-correct add '--show-bad-code' argument */ public com.google.gson.stream.JsonWriter value(double r4) throws java.io.IOException { /* r3 = this; r0 = 2 int r1 = r0 % r0 int r1 = com.google.gson.stream.JsonWriter.c int r1 = r1 + 51 int r2 = r1 % 128 com.google.gson.stream.JsonWriter.d = r2 int r1 = r1 % r0 if (r1 != 0) goto L60 r3.writeDeferredName() boolean r1 = r3.lenient if (r1 != 0) goto L4a int r1 = com.google.gson.stream.JsonWriter.c int r1 = r1 + 65 int r2 = r1 % 128 com.google.gson.stream.JsonWriter.d = r2 int r1 = r1 % r0 if (r1 == 0) goto L2d boolean r1 = java.lang.Double.isNaN(r4) r2 = 55 int r2 = r2 / 0 r2 = 1 r1 = r1 ^ r2 if (r1 != r2) goto L3a goto L33 L2d: boolean r1 = java.lang.Double.isNaN(r4) if (r1 != 0) goto L3a L33: boolean r1 = java.lang.Double.isInfinite(r4) if (r1 != 0) goto L3a goto L4a L3a: java.lang.IllegalArgumentException r0 = new java.lang.IllegalArgumentException java.lang.String r1 = "Numeric values must be finite, but was " java.lang.String r4 = java.lang.String.valueOf(r4) java.lang.String r4 = r1.concat(r4) r0.(r4) throw r0 L4a: r3.beforeValue() java.io.Writer r1 = r3.out java.lang.String r4 = java.lang.Double.toString(r4) r1.append(r4) int r4 = com.google.gson.stream.JsonWriter.c int r4 = r4 + 93 int r5 = r4 % 128 com.google.gson.stream.JsonWriter.d = r5 int r4 = r4 % r0 return r3 L60: r3.writeDeferredName() r4 = 0 r4.hashCode() throw r4 */ throw new UnsupportedOperationException("Method not decompiled: com.google.gson.stream.JsonWriter.value(double):com.google.gson.stream.JsonWriter"); } public JsonWriter value(long j) throws IOException { int i = 2 % 2; int i2 = d + 71; c = i2 % 128; if (i2 % 2 == 0) { writeDeferredName(); beforeValue(); this.out.write(Long.toString(j)); int i3 = 88 / 0; } else { writeDeferredName(); beforeValue(); this.out.write(Long.toString(j)); } return this; } /* JADX WARN: Code restructure failed: missing block: B:17:0x0042, code lost: if (r1.equals("Infinity") == false) goto L21; */ /* JADX WARN: Code restructure failed: missing block: B:19:0x0051, code lost: if (r1.equals("NaN") != false) goto L24; */ /* JADX WARN: Code restructure failed: missing block: B:21:0x0049, code lost: if (r1.equals("Infinity") == false) goto L21; */ /* Code decompiled incorrectly, please refer to instructions dump. To view partially-correct add '--show-bad-code' argument */ public com.google.gson.stream.JsonWriter value(java.lang.Number r5) throws java.io.IOException { /* r4 = this; r0 = 2 int r1 = r0 % r0 if (r5 != 0) goto L1a int r5 = com.google.gson.stream.JsonWriter.c int r5 = r5 + 29 int r1 = r5 % 128 com.google.gson.stream.JsonWriter.d = r1 int r5 = r5 % r0 if (r5 != 0) goto L15 com.google.gson.stream.JsonWriter r5 = r4.nullValue() return r5 L15: r4.nullValue() r5 = 0 throw r5 L1a: r4.writeDeferredName() java.lang.String r1 = r5.toString() boolean r2 = r4.lenient if (r2 != 0) goto L64 java.lang.String r2 = "-Infinity" boolean r2 = r1.equals(r2) if (r2 != 0) goto L54 int r2 = com.google.gson.stream.JsonWriter.c int r2 = r2 + 63 int r3 = r2 % 128 com.google.gson.stream.JsonWriter.d = r3 int r2 = r2 % r0 java.lang.String r3 = "Infinity" if (r2 == 0) goto L45 boolean r2 = r1.equals(r3) r3 = 79 int r3 = r3 / 0 if (r2 != 0) goto L54 goto L4b L45: boolean r2 = r1.equals(r3) if (r2 != 0) goto L54 L4b: java.lang.String r2 = "NaN" boolean r2 = r1.equals(r2) if (r2 != 0) goto L54 goto L64 L54: java.lang.IllegalArgumentException r0 = new java.lang.IllegalArgumentException java.lang.String r1 = "Numeric values must be finite, but was " java.lang.String r5 = java.lang.String.valueOf(r5) java.lang.String r5 = r1.concat(r5) r0.(r5) throw r0 L64: r4.beforeValue() java.io.Writer r5 = r4.out r5.append(r1) int r5 = com.google.gson.stream.JsonWriter.c int r5 = r5 + 115 int r1 = r5 % 128 com.google.gson.stream.JsonWriter.d = r1 int r5 = r5 % r0 return r4 */ throw new UnsupportedOperationException("Method not decompiled: com.google.gson.stream.JsonWriter.value(java.lang.Number):com.google.gson.stream.JsonWriter"); } public void flush() throws IOException { int i = 2 % 2; int i2 = c + 3; d = i2 % 128; int i3 = i2 % 2; if (this.stackSize == 0) { throw new IllegalStateException("JsonWriter is closed."); } this.out.flush(); int i4 = d + 65; c = i4 % 128; int i5 = i4 % 2; } /* JADX WARN: Code restructure failed: missing block: B:11:0x0033, code lost: if (r5.stack[r1 - 1] != 7) goto L17; */ /* JADX WARN: Code restructure failed: missing block: B:12:0x0035, code lost: r5.stackSize = 0; r4 = r4 + 111; com.google.gson.stream.JsonWriter.c = r4 % 128; */ /* JADX WARN: Code restructure failed: missing block: B:13:0x003f, code lost: if ((r4 % 2) != 0) goto L19; */ /* JADX WARN: Code restructure failed: missing block: B:14:0x0041, code lost: r0 = 69 / 0; */ /* JADX WARN: Code restructure failed: missing block: B:15:0x0044, code lost: return; */ /* JADX WARN: Code restructure failed: missing block: B:16:?, code lost: return; */ /* JADX WARN: Code restructure failed: missing block: B:18:0x0020, code lost: if (r1 <= 1) goto L9; */ /* JADX WARN: Code restructure failed: missing block: B:4:0x0016, code lost: if (r1 <= 1) goto L9; */ /* JADX WARN: Code restructure failed: missing block: B:8:0x0022, code lost: r3 = com.google.gson.stream.JsonWriter.c + 83; r4 = r3 % 128; com.google.gson.stream.JsonWriter.d = r4; r3 = r3 % 2; */ /* JADX WARN: Code restructure failed: missing block: B:9:0x002b, code lost: if (r1 != 1) goto L13; */ @Override // java.io.Closeable, java.lang.AutoCloseable /* Code decompiled incorrectly, please refer to instructions dump. To view partially-correct add '--show-bad-code' argument */ public void close() throws java.io.IOException { /* r5 = this; r0 = 2 int r1 = r0 % r0 int r1 = com.google.gson.stream.JsonWriter.c int r1 = r1 + 117 int r2 = r1 % 128 com.google.gson.stream.JsonWriter.d = r2 int r1 = r1 % r0 r2 = 1 if (r1 == 0) goto L19 java.io.Writer r1 = r5.out r1.close() int r1 = r5.stackSize if (r1 > r2) goto L45 goto L22 L19: java.io.Writer r1 = r5.out r1.close() int r1 = r5.stackSize if (r1 > r2) goto L45 L22: int r3 = com.google.gson.stream.JsonWriter.c int r3 = r3 + 83 int r4 = r3 % 128 com.google.gson.stream.JsonWriter.d = r4 int r3 = r3 % r0 if (r1 != r2) goto L35 int[] r3 = r5.stack int r1 = r1 - r2 r1 = r3[r1] r2 = 7 if (r1 != r2) goto L45 L35: r1 = 0 r5.stackSize = r1 int r4 = r4 + 111 int r2 = r4 % 128 com.google.gson.stream.JsonWriter.c = r2 int r4 = r4 % r0 if (r4 != 0) goto L44 r0 = 69 int r0 = r0 / r1 L44: return L45: java.io.IOException r0 = new java.io.IOException java.lang.String r1 = "Incomplete document" r0.(r1) throw r0 */ throw new UnsupportedOperationException("Method not decompiled: com.google.gson.stream.JsonWriter.close():void"); } /* JADX WARN: Removed duplicated region for block: B:11:0x0049 */ /* Code decompiled incorrectly, please refer to instructions dump. To view partially-correct add '--show-bad-code' argument */ private void string(java.lang.String r10) throws java.io.IOException { /* r9 = this; r0 = 2 int r1 = r0 % r0 boolean r1 = r9.htmlSafe if (r1 == 0) goto La java.lang.String[] r1 = com.google.gson.stream.JsonWriter.HTML_SAFE_REPLACEMENT_CHARS goto L15 La: java.lang.String[] r1 = com.google.gson.stream.JsonWriter.REPLACEMENT_CHARS int r2 = com.google.gson.stream.JsonWriter.c int r2 = r2 + 83 int r3 = r2 % 128 com.google.gson.stream.JsonWriter.d = r3 int r2 = r2 % r0 L15: java.io.Writer r2 = r9.out r3 = 34 r2.write(r3) int r2 = r10.length() r4 = 0 r5 = r4 L22: if (r4 >= r2) goto L63 char r6 = r10.charAt(r4) r7 = 128(0x80, float:1.8E-43) if (r6 >= r7) goto L31 r6 = r1[r6] if (r6 != 0) goto L47 goto L57 L31: r7 = 8232(0x2028, float:1.1535E-41) if (r6 != r7) goto L38 java.lang.String r6 = "\\u2028" goto L47 L38: r7 = 8233(0x2029, float:1.1537E-41) if (r6 != r7) goto L57 int r6 = com.google.gson.stream.JsonWriter.d int r6 = r6 + 13 int r7 = r6 % 128 com.google.gson.stream.JsonWriter.c = r7 int r6 = r6 % r0 java.lang.String r6 = "\\u2029" L47: if (r5 >= r4) goto L50 java.io.Writer r7 = r9.out int r8 = r4 - r5 r7.write(r10, r5, r8) L50: java.io.Writer r5 = r9.out r5.write(r6) int r5 = r4 + 1 L57: int r4 = r4 + 1 int r6 = com.google.gson.stream.JsonWriter.c int r6 = r6 + 21 int r7 = r6 % 128 com.google.gson.stream.JsonWriter.d = r7 int r6 = r6 % r0 goto L22 L63: if (r5 >= r2) goto L6b java.io.Writer r1 = r9.out int r2 = r2 - r5 r1.write(r10, r5, r2) L6b: java.io.Writer r10 = r9.out r10.write(r3) int r10 = com.google.gson.stream.JsonWriter.d int r10 = r10 + 41 int r1 = r10 % 128 com.google.gson.stream.JsonWriter.c = r1 int r10 = r10 % r0 return */ throw new UnsupportedOperationException("Method not decompiled: com.google.gson.stream.JsonWriter.string(java.lang.String):void"); } private void newline() throws IOException { int i = 2 % 2; int i2 = c + 73; d = i2 % 128; if (i2 % 2 != 0) { Object obj = null; obj.hashCode(); throw null; } if (this.indent == null) { return; } this.out.write(10); int i3 = this.stackSize; int i4 = 1; while (i4 < i3) { this.out.write(this.indent); i4++; int i5 = c + 119; d = i5 % 128; int i6 = i5 % 2; } } private void beforeName() throws IOException { int i = 2 % 2; int peek = peek(); if (peek == 5) { int i2 = d + 37; c = i2 % 128; int i3 = i2 % 2; this.out.write(44); } else if (peek != 3) { throw new IllegalStateException("Nesting problem."); } newline(); replaceTop(4); int i4 = c + 15; d = i4 % 128; if (i4 % 2 != 0) { throw null; } } private void beforeValue() throws IOException { int i = 2 % 2; int peek = peek(); if (peek == 1) { replaceTop(2); newline(); return; } if (peek == 2) { this.out.append(','); newline(); int i2 = c + 19; d = i2 % 128; if (i2 % 2 != 0) { int i3 = 49 / 0; return; } return; } if (peek == 4) { this.out.append((CharSequence) this.separator); replaceTop(5); return; } if (peek != 6) { int i4 = d; int i5 = i4 + 77; c = i5 % 128; int i6 = i5 % 2; if (peek != 7) { throw new IllegalStateException("Nesting problem."); } int i7 = i4 + 51; c = i7 % 128; if (i7 % 2 == 0) { throw null; } if (!this.lenient) { throw new IllegalStateException("JSON must have only one top-level value."); } } replaceTop(7); } static void b() { a = -3146105045151542314L; e = 452713125; b = (char) 55973; } public final void setSerializeNulls(boolean z) { int i = 2 % 2; int i2 = d + 103; int i3 = i2 % 128; c = i3; int i4 = i2 % 2; this.serializeNulls = z; int i5 = i3 + 117; d = i5 % 128; if (i5 % 2 != 0) { int i6 = 42 / 0; } } public final void setLenient(boolean z) { int i = 2 % 2; int i2 = c; int i3 = i2 + 101; d = i3 % 128; int i4 = i3 % 2; this.lenient = z; int i5 = i2 + 85; d = i5 % 128; int i6 = i5 % 2; } public final void setHtmlSafe(boolean z) { int i = 2 % 2; int i2 = d; int i3 = i2 + 69; c = i3 % 128; int i4 = i3 % 2; this.htmlSafe = z; if (i4 == 0) { int i5 = 7 / 0; } int i6 = i2 + 25; c = i6 % 128; int i7 = i6 % 2; } public boolean isLenient() { int i = 2 % 2; int i2 = c; int i3 = i2 + 39; d = i3 % 128; int i4 = i3 % 2; boolean z = this.lenient; int i5 = i2 + 51; d = i5 % 128; int i6 = i5 % 2; return z; } public final boolean isHtmlSafe() { int i = 2 % 2; int i2 = c + 109; int i3 = i2 % 128; d = i3; int i4 = i2 % 2; boolean z = this.htmlSafe; int i5 = i3 + 59; c = i5 % 128; int i6 = i5 % 2; return z; } public final boolean getSerializeNulls() { int i = 2 % 2; int i2 = c; int i3 = i2 + 119; d = i3 % 128; if (i3 % 2 != 0) { throw null; } boolean z = this.serializeNulls; int i4 = i2 + 19; d = i4 % 128; int i5 = i4 % 2; return z; } }