package com.ss.android.ugc.aweme.services;

import X.FLI;
import X.Lnj;
import android.app.Application;
import com.bytedance.covode.number.Covode;
import com.bytedance.frameworks.apm.trace.MethodCollector;
import com.bytedance.ies.powerlist.IPowerContext;
import kotlin.h.b.n;

public final class PowerContextImpl implements IPowerContext {
    static {
        Covode.recordClassIndex(105153);
    }

    public final Application getApplication() {
        Application LIZ = FLI.LIZ();
        n.LIZIZ(LIZ, "");
        return LIZ;
    }

    public static IPowerContext createIPowerContextbyMonsterPlugin(boolean z) {
        MethodCollector.i(2458);
        IPowerContext iPowerContext = (IPowerContext) Lnj.LIZ(IPowerContext.class, z);
        if (iPowerContext != null) {
            MethodCollector.o(2458);
            return iPowerContext;
        }
        Object LIZIZ = Lnj.LIZIZ(IPowerContext.class, z);
        if (LIZIZ != null) {
            IPowerContext iPowerContext2 = (IPowerContext) LIZIZ;
            MethodCollector.o(2458);
            return iPowerContext2;
        }
        if (Lnj.aA == null) {
            synchronized (IPowerContext.class) {
                try {
                    if (Lnj.aA == null) {
                        Lnj.aA = new PowerContextImpl();
                    }
                } catch (Throwable th) {
                    MethodCollector.o(2458);
                    throw th;
                }
            }
        }
        PowerContextImpl powerContextImpl = (PowerContextImpl) Lnj.aA;
        MethodCollector.o(2458);
        return powerContextImpl;
    }
}
