Files
Daniel Elliott f9d20bb3fc Add decompiled APK source code (JADX)
- 28,932 files
- Full Java source code
- Smali files
- Resources

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-02-18 14:52:23 -08:00

224 lines
6.8 KiB
Java

package com.fyber.inneractive.sdk.protobuf;
import com.fyber.inneractive.sdk.protobuf.y;
import java.nio.charset.Charset;
import java.util.AbstractList;
import java.util.Arrays;
import java.util.Collection;
import java.util.RandomAccess;
/* loaded from: classes2.dex */
public final class v extends c<Float> implements y.f, RandomAccess, x0 {
public static final v d;
public float[] b;
public int c;
static {
v vVar = new v(new float[0], 0);
d = vVar;
vVar.a = false;
}
public v() {
this(new float[10], 0);
}
@Override // java.util.AbstractList, java.util.List
public final void add(int i, Object obj) {
int i2;
float floatValue = ((Float) obj).floatValue();
e();
if (i < 0 || i > (i2 = this.c)) {
StringBuilder a = com.fyber.inneractive.sdk.bidder.h.a("Index:", i, ", Size:");
a.append(this.c);
throw new IndexOutOfBoundsException(a.toString());
}
float[] fArr = this.b;
if (i2 < fArr.length) {
System.arraycopy(fArr, i, fArr, i + 1, i2 - i);
} else {
float[] fArr2 = new float[((i2 * 3) / 2) + 1];
System.arraycopy(fArr, 0, fArr2, 0, i);
System.arraycopy(this.b, i, fArr2, i + 1, this.c - i);
this.b = fArr2;
}
this.b[i] = floatValue;
this.c++;
((AbstractList) this).modCount++;
}
@Override // com.fyber.inneractive.sdk.protobuf.c, java.util.AbstractCollection, java.util.Collection, java.util.List
public final boolean addAll(Collection<? extends Float> collection) {
e();
Charset charset = y.a;
collection.getClass();
if (!(collection instanceof v)) {
return super.addAll(collection);
}
v vVar = (v) collection;
int i = vVar.c;
if (i == 0) {
return false;
}
int i2 = this.c;
if (Integer.MAX_VALUE - i2 < i) {
throw new OutOfMemoryError();
}
int i3 = i2 + i;
float[] fArr = this.b;
if (i3 > fArr.length) {
this.b = Arrays.copyOf(fArr, i3);
}
System.arraycopy(vVar.b, 0, this.b, this.c, vVar.c);
this.c = i3;
((AbstractList) this).modCount++;
return true;
}
@Override // java.util.AbstractCollection, java.util.Collection, java.util.List
public final boolean contains(Object obj) {
return indexOf(obj) != -1;
}
@Override // com.fyber.inneractive.sdk.protobuf.c, java.util.AbstractList, java.util.Collection, java.util.List
public final boolean equals(Object obj) {
if (this == obj) {
return true;
}
if (!(obj instanceof v)) {
return super.equals(obj);
}
v vVar = (v) obj;
if (this.c != vVar.c) {
return false;
}
float[] fArr = vVar.b;
for (int i = 0; i < this.c; i++) {
if (Float.floatToIntBits(this.b[i]) != Float.floatToIntBits(fArr[i])) {
return false;
}
}
return true;
}
@Override // java.util.AbstractList, java.util.List
public final int indexOf(Object obj) {
if (!(obj instanceof Float)) {
return -1;
}
float floatValue = ((Float) obj).floatValue();
int i = this.c;
for (int i2 = 0; i2 < i; i2++) {
if (this.b[i2] == floatValue) {
return i2;
}
}
return -1;
}
@Override // com.fyber.inneractive.sdk.protobuf.c, java.util.AbstractList, java.util.List
public final Object remove(int i) {
int i2;
e();
if (i < 0 || i >= (i2 = this.c)) {
StringBuilder a = com.fyber.inneractive.sdk.bidder.h.a("Index:", i, ", Size:");
a.append(this.c);
throw new IndexOutOfBoundsException(a.toString());
}
float[] fArr = this.b;
float f = fArr[i];
if (i < i2 - 1) {
System.arraycopy(fArr, i + 1, fArr, i, (i2 - i) - 1);
}
this.c--;
((AbstractList) this).modCount++;
return Float.valueOf(f);
}
@Override // java.util.AbstractList
public final void removeRange(int i, int i2) {
e();
if (i2 < i) {
throw new IndexOutOfBoundsException("toIndex < fromIndex");
}
float[] fArr = this.b;
System.arraycopy(fArr, i2, fArr, i, this.c - i2);
this.c -= i2 - i;
((AbstractList) this).modCount++;
}
@Override // java.util.AbstractList, java.util.List
public final Object set(int i, Object obj) {
float floatValue = ((Float) obj).floatValue();
e();
if (i < 0 || i >= this.c) {
StringBuilder a = com.fyber.inneractive.sdk.bidder.h.a("Index:", i, ", Size:");
a.append(this.c);
throw new IndexOutOfBoundsException(a.toString());
}
float[] fArr = this.b;
float f = fArr[i];
fArr[i] = floatValue;
return Float.valueOf(f);
}
@Override // java.util.AbstractCollection, java.util.Collection, java.util.List
public final int size() {
return this.c;
}
public v(float[] fArr, int i) {
this.b = fArr;
this.c = i;
}
public final void a(float f) {
e();
int i = this.c;
float[] fArr = this.b;
if (i == fArr.length) {
float[] fArr2 = new float[((i * 3) / 2) + 1];
System.arraycopy(fArr, 0, fArr2, 0, i);
this.b = fArr2;
}
float[] fArr3 = this.b;
int i2 = this.c;
this.c = i2 + 1;
fArr3[i2] = f;
}
@Override // java.util.AbstractList, java.util.List
public final Object get(int i) {
if (i >= 0 && i < this.c) {
return Float.valueOf(this.b[i]);
}
StringBuilder a = com.fyber.inneractive.sdk.bidder.h.a("Index:", i, ", Size:");
a.append(this.c);
throw new IndexOutOfBoundsException(a.toString());
}
@Override // com.fyber.inneractive.sdk.protobuf.c, java.util.AbstractList, java.util.Collection, java.util.List
public final int hashCode() {
int i = 1;
for (int i2 = 0; i2 < this.c; i2++) {
i = (i * 31) + Float.floatToIntBits(this.b[i2]);
}
return i;
}
@Override // com.fyber.inneractive.sdk.protobuf.y.j
/* renamed from: c, reason: merged with bridge method [inline-methods] */
public final v a(int i) {
if (i >= this.c) {
return new v(Arrays.copyOf(this.b, i), this.c);
}
throw new IllegalArgumentException();
}
@Override // com.fyber.inneractive.sdk.protobuf.c, java.util.AbstractList, java.util.AbstractCollection, java.util.Collection, java.util.List
public final boolean add(Object obj) {
a(((Float) obj).floatValue());
return true;
}
}