package com.google.android.play.core.common;

import android.os.Bundle;
import com.bytedance.covode.number.Covode;
import com.bytedance.frameworks.apm.trace.MethodCollector;
import com.google.android.play.core.b.b;
import java.util.Arrays;
import java.util.HashMap;
import java.util.HashSet;
import java.util.Map;
import java.util.Set;

public final class c {
    public static final Set<String> LIZ = new HashSet(Arrays.asList(new String[]{"app_update", "review"}));
    public static final Set<String> LIZIZ = new HashSet(Arrays.asList(new String[]{"native", "unity"}));
    public static final Map<String, Map<String, Integer>> LIZJ = new HashMap();
    public static final b LIZLLL = new b("PlayCoreVersion");

    static {
        Covode.recordClassIndex(44314);
    }

    public static Bundle LIZ(String str) {
        Bundle bundle = new Bundle();
        Map<String, Integer> LIZIZ2 = LIZIZ(str);
        bundle.putInt("playcore_version_code", LIZIZ2.get("java").intValue());
        if (LIZIZ2.containsKey("native")) {
            bundle.putInt("playcore_native_version", LIZIZ2.get("native").intValue());
        }
        if (LIZIZ2.containsKey("unity")) {
            bundle.putInt("playcore_unity_version", LIZIZ2.get("unity").intValue());
        }
        return bundle;
    }

    public static synchronized Map<String, Integer> LIZIZ(String str) {
        Map<String, Integer> map;
        synchronized (c.class) {
            MethodCollector.i(18315);
            Map<String, Map<String, Integer>> map2 = LIZJ;
            if (!map2.containsKey(str)) {
                HashMap hashMap = new HashMap();
                hashMap.put("java", 10900);
                map2.put(str, hashMap);
            }
            map = map2.get(str);
            MethodCollector.o(18315);
        }
        return map;
    }
}
