71 lines
2.3 KiB
Java
71 lines
2.3 KiB
Java
package com.google.common.collect;
|
|
|
|
import com.google.common.collect.RegularImmutableMap;
|
|
import java.util.Map;
|
|
|
|
/* loaded from: classes.dex */
|
|
final class RegularImmutableBiMap<K, V> extends ImmutableBiMap<K, V> {
|
|
static final RegularImmutableBiMap<Object, Object> f = new RegularImmutableBiMap<>();
|
|
private final transient int[] a;
|
|
private final transient Object[] b;
|
|
private final transient int c;
|
|
private final transient int d;
|
|
private final transient RegularImmutableBiMap<V, K> e;
|
|
|
|
/* JADX WARN: Multi-variable type inference failed */
|
|
private RegularImmutableBiMap() {
|
|
this.a = null;
|
|
this.b = new Object[0];
|
|
this.c = 0;
|
|
this.d = 0;
|
|
this.e = this;
|
|
}
|
|
|
|
@Override // com.google.common.collect.ImmutableMap
|
|
ImmutableSet<Map.Entry<K, V>> createEntrySet() {
|
|
return new RegularImmutableMap.EntrySet(this, this.b, this.c, this.d);
|
|
}
|
|
|
|
@Override // com.google.common.collect.ImmutableMap
|
|
ImmutableSet<K> createKeySet() {
|
|
return new RegularImmutableMap.KeySet(this, new RegularImmutableMap.KeysOrValuesAsList(this.b, this.c, this.d));
|
|
}
|
|
|
|
@Override // com.google.common.collect.ImmutableMap, java.util.Map
|
|
public V get(Object obj) {
|
|
return (V) RegularImmutableMap.a(this.a, this.b, this.d, this.c, obj);
|
|
}
|
|
|
|
@Override // com.google.common.collect.ImmutableMap
|
|
boolean isPartialView() {
|
|
return false;
|
|
}
|
|
|
|
@Override // java.util.Map
|
|
public int size() {
|
|
return this.d;
|
|
}
|
|
|
|
@Override // com.google.common.collect.ImmutableBiMap, com.google.common.collect.BiMap
|
|
public ImmutableBiMap<V, K> inverse() {
|
|
return this.e;
|
|
}
|
|
|
|
RegularImmutableBiMap(Object[] objArr, int i) {
|
|
this.b = objArr;
|
|
this.d = i;
|
|
this.c = 0;
|
|
int chooseTableSize = i >= 2 ? ImmutableSet.chooseTableSize(i) : 0;
|
|
this.a = RegularImmutableMap.a(objArr, i, chooseTableSize, 0);
|
|
this.e = new RegularImmutableBiMap<>(RegularImmutableMap.a(objArr, i, chooseTableSize, 1), objArr, i, this);
|
|
}
|
|
|
|
private RegularImmutableBiMap(int[] iArr, Object[] objArr, int i, RegularImmutableBiMap<V, K> regularImmutableBiMap) {
|
|
this.a = iArr;
|
|
this.b = objArr;
|
|
this.c = 1;
|
|
this.d = i;
|
|
this.e = regularImmutableBiMap;
|
|
}
|
|
}
|