package com.google.common.collect; import com.google.common.collect.Maps; import java.util.Iterator; import java.util.Map; import java.util.Set; /* loaded from: classes.dex */ final class WellBehavedMap extends ForwardingMap { private final Map a; private Set> b; private final class EntrySet extends Maps.EntrySet { private EntrySet() { } @Override // com.google.common.collect.Maps.EntrySet Map c() { return WellBehavedMap.this; } @Override // java.util.AbstractCollection, java.util.Collection, java.lang.Iterable, java.util.Set public Iterator> iterator() { return new TransformedIterator>(WellBehavedMap.this.keySet().iterator()) { // from class: com.google.common.collect.WellBehavedMap.EntrySet.1 @Override // com.google.common.collect.TransformedIterator /* bridge */ /* synthetic */ Object a(Object obj) { return a((AnonymousClass1) obj); } @Override // com.google.common.collect.TransformedIterator Map.Entry a(final K k) { return new AbstractMapEntry() { // from class: com.google.common.collect.WellBehavedMap.EntrySet.1.1 @Override // com.google.common.collect.AbstractMapEntry, java.util.Map.Entry public K getKey() { return (K) k; } @Override // com.google.common.collect.AbstractMapEntry, java.util.Map.Entry public V getValue() { return WellBehavedMap.this.get(k); } /* JADX WARN: Multi-variable type inference failed */ @Override // com.google.common.collect.AbstractMapEntry, java.util.Map.Entry public V setValue(V v) { return (V) WellBehavedMap.this.put(k, v); } }; } }; } } private WellBehavedMap(Map map) { this.a = map; } static WellBehavedMap a(Map map) { return new WellBehavedMap<>(map); } @Override // com.google.common.collect.ForwardingMap, java.util.Map public Set> entrySet() { Set> set = this.b; if (set != null) { return set; } EntrySet entrySet = new EntrySet(); this.b = entrySet; return entrySet; } /* JADX INFO: Access modifiers changed from: protected */ @Override // com.google.common.collect.ForwardingMap, com.google.common.collect.ForwardingObject public Map delegate() { return this.a; } }