package n;

import androidx.annotation.Nullable;
import java.util.HashMap;
import java.util.Map;

/* JADX INFO: loaded from: classes.dex */
public final class a extends g {

    /* JADX INFO: renamed from: e, reason: collision with root package name */
    public final HashMap f30702e = new HashMap();

    @Override // n.g
    public final Object c(Object obj) {
        Object objC = super.c(obj);
        this.f30702e.remove(obj);
        return objC;
    }

    @Nullable
    public Map.Entry<Object, Object> ceil(Object obj) {
        HashMap map = this.f30702e;
        if (map.containsKey(obj)) {
            return ((c) map.get(obj)).f30707d;
        }
        return null;
    }

    public final Object f(Object obj, Object obj2) {
        c cVar = get(obj);
        if (cVar != null) {
            return cVar.f30705b;
        }
        HashMap map = this.f30702e;
        c cVar2 = new c(obj, obj2);
        this.f30716d++;
        c cVar3 = this.f30714b;
        if (cVar3 == null) {
            this.f30713a = cVar2;
            this.f30714b = cVar2;
        } else {
            cVar3.f30706c = cVar2;
            cVar2.f30707d = cVar3;
            this.f30714b = cVar2;
        }
        map.put(obj, cVar2);
        return null;
    }

    @Override // n.g
    @Nullable
    public c get(Object obj) {
        return (c) this.f30702e.get(obj);
    }
}
