package p037.p099;

import java.io.Closeable;
import java.io.IOException;
import java.util.HashMap;
import java.util.Map;

/* JADX INFO: renamed from: މ.ދ.ޝ, reason: contains not printable characters */
/* JADX INFO: loaded from: classes.dex */
public abstract class AbstractC2245 {

    /* JADX INFO: renamed from: ֏, reason: contains not printable characters */
    public final Map<String, Object> f7206 = new HashMap();

    /* JADX INFO: renamed from: ؠ, reason: contains not printable characters */
    public volatile boolean f7207 = false;

    /* JADX INFO: renamed from: ֏, reason: contains not printable characters */
    public <T> T m4303(String str) {
        T t;
        Map<String, Object> map = this.f7206;
        if (map == null) {
            return null;
        }
        synchronized (map) {
            t = (T) this.f7206.get(str);
        }
        return t;
    }

    /* JADX INFO: renamed from: ֏, reason: contains not printable characters */
    public <T> T m4304(String str, T t) {
        Object obj;
        synchronized (this.f7206) {
            obj = this.f7206.get(str);
            if (obj == null) {
                this.f7206.put(str, t);
            }
        }
        if (obj != null) {
            t = (T) obj;
        }
        if (this.f7207 && (t instanceof Closeable)) {
            try {
                t.close();
            } catch (IOException e) {
                throw new RuntimeException(e);
            }
        }
        return t;
    }

    /* JADX INFO: renamed from: ؠ, reason: contains not printable characters */
    public final void m4305() {
        this.f7207 = true;
        Map<String, Object> map = this.f7206;
        if (map != null) {
            synchronized (map) {
                for (Object obj : this.f7206.values()) {
                    if (obj instanceof Closeable) {
                        try {
                            ((Closeable) obj).close();
                        } catch (IOException e) {
                            throw new RuntimeException(e);
                        }
                    }
                }
            }
        }
        mo2103();
    }

    /* JADX INFO: renamed from: ހ */
    public void mo2103() {
    }
}
