package com.ym.zxhcsdk.manager;

import android.app.Activity;

import com.ym.zxhcsdk.HcAppliContext;
import com.ym.zxhcsdk.ZXHCConstant;

public class ZXHCADManager {
    private static volatile ZXHCADManager sInstance;
    private ZXHCADManager() {

    }

    public static ZXHCADManager getInstance() {
        if (sInstance == null) {
            synchronized (ZXHCADManager.class) {
                if (sInstance == null) {
                    sInstance = new ZXHCADManager();
                }
            }
        }
        return sInstance;
    }
    //1.3.5 修改上报链接替换
    //1.3.6 删除aar中的FileProvider
    public boolean InitAd(Activity context, String appId,boolean isDebug){
        ZXHCConstant.ZXHC_APPID = appId;
        HcAppliContext.init(context);
        ZXHCConstant.IS_DEBUG = isDebug;
        if (ZXHCConstant.IS_DEBUG){
            ZXHCConstant.BASE_URL = "http://sspv2test.zhangxinhuichuan.com/ssp/v1/ads";
        }else {
            ZXHCConstant.BASE_URL = "http://sspv2.zhangxinhuichuan.com/ssp/v1/ads";
        }

        return true;
    }

}
