mirror of
https://github.com/VibedByKaKi/alexandroid.git
synced 2026-11-15 18:37:17 +01:00
68 lines
3.6 KiB
Java
68 lines
3.6 KiB
Java
package androidx.paging;
|
|
|
|
import androidx.annotation.IntRange;
|
|
import androidx.exifinterface.media.ExifInterface;
|
|
import com.dee.app.metrics.MetricsConstants;
|
|
import defpackage.a$$ExternalSyntheticOutline0;
|
|
import java.util.List;
|
|
import kotlin.Metadata;
|
|
import kotlin.collections.AbstractList;
|
|
import kotlin.text.Regex$$ExternalSyntheticBUOutline0;
|
|
import org.jetbrains.annotations.NotNull;
|
|
import org.jetbrains.annotations.Nullable;
|
|
|
|
/* compiled from: r8-map-id-b9432e0f623b4a4bff4ba50a8a24c4aafad2c1e11092747b9fb5e6a22af5a940 */
|
|
@Metadata(d1 = {"\u0000\u001c\n\u0002\u0018\u0002\n\u0000\n\u0002\u0018\u0002\n\u0000\n\u0002\u0010\b\n\u0002\b\u0002\n\u0002\u0010 \n\u0002\b\f\u0018\u0000*\u0004\b\u0000\u0010\u00012\n\u0012\u0006\u0012\u0004\u0018\u0001H\u00010\u0002B'\u0012\b\b\u0001\u0010\u0003\u001a\u00020\u0004\u0012\b\b\u0001\u0010\u0005\u001a\u00020\u0004\u0012\f\u0010\u0006\u001a\b\u0012\u0004\u0012\u00028\u00000\u0007¢\u0006\u0002\u0010\bJ\u0018\u0010\u0010\u001a\u0004\u0018\u00018\u00002\u0006\u0010\u0011\u001a\u00020\u0004H\u0096\u0002¢\u0006\u0002\u0010\u0012R\u0017\u0010\u0006\u001a\b\u0012\u0004\u0012\u00028\u00000\u0007¢\u0006\b\n\u0000\u001a\u0004\b\t\u0010\nR\u0011\u0010\u0005\u001a\u00020\u0004¢\u0006\b\n\u0000\u001a\u0004\b\u000b\u0010\fR\u0011\u0010\u0003\u001a\u00020\u0004¢\u0006\b\n\u0000\u001a\u0004\b\r\u0010\fR\u0014\u0010\u000e\u001a\u00020\u00048VX\u0096\u0004¢\u0006\u0006\u001a\u0004\b\u000f\u0010\f¨\u0006\u0013"}, d2 = {"Landroidx/paging/ItemSnapshotList;", ExifInterface.GPS_DIRECTION_TRUE, "Lkotlin/collections/AbstractList;", "placeholdersBefore", "", "placeholdersAfter", "items", "", "(IILjava/util/List;)V", "getItems", "()Ljava/util/List;", "getPlaceholdersAfter", "()I", "getPlaceholdersBefore", "size", "getSize", MetricsConstants.Method.CACHE_GET, "index", "(I)Ljava/lang/Object;", "paging-common"}, k = 1, mv = {1, 8, 0}, xi = 48)
|
|
/* loaded from: classes14.dex */
|
|
public final class ItemSnapshotList<T> extends AbstractList<T> {
|
|
|
|
@NotNull
|
|
private final List<T> items;
|
|
private final int placeholdersAfter;
|
|
private final int placeholdersBefore;
|
|
|
|
/* JADX WARN: Multi-variable type inference failed */
|
|
public ItemSnapshotList(@IntRange(from = 0) int i, @IntRange(from = 0) int i2, @NotNull List<? extends T> list) {
|
|
list.getClass();
|
|
this.placeholdersBefore = i;
|
|
this.placeholdersAfter = i2;
|
|
this.items = list;
|
|
}
|
|
|
|
@Override // kotlin.collections.AbstractList, java.util.List
|
|
@Nullable
|
|
public T get(int index) {
|
|
if (index >= 0 && index < this.placeholdersBefore) {
|
|
return null;
|
|
}
|
|
int i = this.placeholdersBefore;
|
|
if (index < this.items.size() + i && i <= index) {
|
|
return this.items.get(index - this.placeholdersBefore);
|
|
}
|
|
int size = this.items.size() + this.placeholdersBefore;
|
|
if (index < size() && size <= index) {
|
|
return null;
|
|
}
|
|
Regex$$ExternalSyntheticBUOutline0.m(size(), a$$ExternalSyntheticOutline0.m0m(index, "Illegal attempt to access index ", " in ItemSnapshotList of size "));
|
|
return null;
|
|
}
|
|
|
|
@NotNull
|
|
public final List<T> getItems() {
|
|
return this.items;
|
|
}
|
|
|
|
public final int getPlaceholdersAfter() {
|
|
return this.placeholdersAfter;
|
|
}
|
|
|
|
public final int getPlaceholdersBefore() {
|
|
return this.placeholdersBefore;
|
|
}
|
|
|
|
@Override // kotlin.collections.AbstractList, kotlin.collections.AbstractCollection
|
|
/* renamed from: getSize */
|
|
public int get_size() {
|
|
return this.items.size() + this.placeholdersBefore + this.placeholdersAfter;
|
|
}
|
|
}
|