| | |
| | | |
| | | import com.google.gson.Gson; |
| | | import com.google.gson.JsonObject; |
| | | import com.hdl.hdlhttp.HxHttpConfig; |
| | | import com.hdl.linkpm.sdk.HDLLinkPMSdk; |
| | | import com.hdl.linkpm.sdk.user.HDLLinkPMUser; |
| | | import com.hdl.linkpm.sdk.user.callback.IOnReloginListener; |
| | |
| | | import io.dcloud.feature.sdk.DCSDKInitConfig; |
| | | import io.dcloud.feature.sdk.DCUniMPSDK; |
| | | import io.dcloud.feature.sdk.Interface.IDCUniMPPreInitCallback; |
| | | import okhttp3.logging.HttpLoggingInterceptor; |
| | | |
| | | public class HDLApp extends Application { |
| | | //控制打印 Debug模式打印 |
| | |
| | | initHDLLinkPMSdk(); |
| | | HDLLinkLocalSdk.getInstance().init(getInstance()); |
| | | initSocket(); |
| | | //4.初始化OKHttpLog 是否开启 |
| | | // setOKHttpLogOpen(isLogEnabled); |
| | | |
| | | } |
| | | |
| | | /** |
| | |
| | | HDLUdpConnect.getInstance().initUdp(); |
| | | } |
| | | |
| | | /** |
| | | * 初始化OKHttpLog |
| | | */ |
| | | private void setOKHttpLogOpen(Boolean isOpen) { |
| | | if (isOpen) { |
| | | HttpLoggingInterceptor httpLoggingInterceptor = new HttpLoggingInterceptor(); |
| | | httpLoggingInterceptor.level(HttpLoggingInterceptor.Level.BODY); |
| | | HxHttpConfig.getInstance().addInterceptor(httpLoggingInterceptor); |
| | | } |
| | | } |
| | | // /** |
| | | // * 初始化uni app mqtt |
| | | // */ |