package com.ss.android.ugc.aweme.live.livehostimpl;

import X.0c0;
import com.bytedance.android.livesdkapi.host.IHostSlot;
import com.bytedance.covode.number.Covode;
import com.bytedance.frameworks.apm.trace.MethodCollector;
import com.ss.android.ugc.aweme.framework.services.ServiceManager;
import com.ss.android.ugc.aweme.live.ILiveParasiticModuleLaunchService;
import com.ss.android.ugc.aweme.live.LiveOuterService;
import java.util.HashMap;

public class LiveHostSlot implements IHostSlot {
    public volatile boolean LIZ;

    static {
        Covode.recordClassIndex(91238);
    }

    public void onInit() {
    }

    public final synchronized void LIZ() {
        MethodCollector.i(8145);
        if (this.LIZ) {
            MethodCollector.o(8145);
            return;
        }
        if (((Boolean) LiveOuterService.LJJI().LJIIJJI().LIZ("live_enable_launch_parasitic_modules", true)).booleanValue()) {
            try {
                for (ILiveParasiticModuleLaunchService LIZ2 : ServiceManager.get().getServices(ILiveParasiticModuleLaunchService.class)) {
                    LIZ2.LIZ();
                }
            } catch (Throwable th) {
                HashMap hashMap = new HashMap();
                hashMap.put("error_msg", th.getMessage());
                0c0.LIZ("ttlive_live_launch_parasitic_modules", 1, hashMap);
            }
        }
        this.LIZ = true;
        MethodCollector.o(8145);
    }
}
