红果免费短剧 v6.2.3.32版本的 MD5 值为:a6b05492607eab2c8a25f26d2f238ae0

以下内容为反编译后的 ab.java 源代码,内容仅作参考


package com.dragon.read.app.launch.task;

import android.app.Application;
import android.content.Intent;
import android.text.TextUtils;
import android.util.Log;
import com.bytedance.router.SmartRouter;
import com.bytedance.router.listener.error.ErrorType;
import com.dragon.read.app.App;
import com.dragon.read.base.util.LogWrapper;
import com.dragon.read.component.biz.api.NsCommunityApi;
import com.dragon.read.component.biz.api.NsSearchApi;
import com.dragon.read.component.biz.api.NsUgApi;
import com.dragon.read.report.PageRecorder;
import com.dragon.read.util.DebugManager;
import com.dragon.read.util.cs;
import com.ss.android.common.util.ToolUtils;
import java.io.Serializable;
import org.json.JSONObject;

public class ab {
    public void a(Application application) {
        SmartRouter.configRouter(com.dragon.read.router.b.f80435a).a(new String[]{"http", "sslocal"});
        SmartRouter.init(application);
        LogWrapper.info("RouterInitializer", "SmartRouter init", new Object[0]);
        SmartRouter.addInterceptor(new com.dragon.read.teenmode.d());
        SmartRouter.addInterceptor(new com.dragon.read.router.a.c());
        SmartRouter.addInterceptor(NsCommunityApi.IMPL.newSocialInterceptor());
        SmartRouter.addInterceptor(new com.dragon.read.router.a.b());
        SmartRouter.addInterceptor(new com.dragon.read.router.a.f());
        SmartRouter.addInterceptor(new com.dragon.read.router.a.e());
        SmartRouter.addInterceptor(NsSearchApi.IMPL.obtainRouterInterceptor());
        if (!DebugManager.isOfficialBuild()) {
            try {
                SmartRouter.addInterceptor((com.bytedance.router.c.a) com.a.a("com.dragon.read.pages.debug.router.interceptor.DevToolInterceptor").newInstance());
            } catch (Exception e) {
                e.printStackTrace();
            }
        }
        SmartRouter.setOnErrorListener(new com.bytedance.router.listener.error.b() {
            @Override
            public void a(ErrorType errorType, final com.bytedance.router.d dVar, Exception exc) {
                PageRecorder pageRecorder;
                boolean z;
                if (dVar == null) {
                    return;
                }
                LogWrapper.error("RouterInitializer", "route error:" + dVar.f25489c, new Object[0]);
                LogWrapper.error("RouterInitializer", Log.getStackTraceString(new Exception("route error")), new Object[0]);
                if (!App.isAppOpened()) {
                    Intent intent = dVar.f25488b;
                    Serializable serializable = null;
                    if (intent != null) {
                        Serializable serializableExtra = intent.getSerializableExtra("enter_from");
                        if (serializableExtra instanceof PageRecorder) {
                            pageRecorder = (PageRecorder) serializableExtra;
                            if (pageRecorder != null) {
                                serializable = pageRecorder.getExtraInfoMap().get("from_deeplink_opt");
                            }
                            if (serializable == null && TextUtils.equals("1", serializable.toString())) {
                                z = true;
                            } else {
                                z = false;
                            }
                            boolean isAppRealOpen = App.isAppRealOpen();
                            LogWrapper.debug("RouterInitializer", "pageRecorder= %s", pageRecorder);
                            LogWrapper.info("RouterInitializer", "fromDeepLink= %b, hasOpenApp= %b", Boolean.valueOf(z), Boolean.valueOf(isAppRealOpen));
                            NsUgApi.IMPL.getRouteMonitorService().b(z, dVar.f25489c);
                            if (z) {
                                if (!isAppRealOpen) {
                                    com.dragon.read.util.j.b(App.context(), pageRecorder);
                                    return;
                                }
                                return;
                            }
                        }
                    }
                    pageRecorder = null;
                    if (pageRecorder != null) {
                    }
                    if (serializable == null) {
                    }
                    z = false;
                    boolean isAppRealOpen2 = App.isAppRealOpen();
                    LogWrapper.debug("RouterInitializer", "pageRecorder= %s", pageRecorder);
                    LogWrapper.info("RouterInitializer", "fromDeepLink= %b, hasOpenApp= %b", Boolean.valueOf(z), Boolean.valueOf(isAppRealOpen2));
                    NsUgApi.IMPL.getRouteMonitorService().b(z, dVar.f25489c);
                    if (z) {
                    }
                }
                final String str = dVar.f;
                if (ToolUtils.isMainProcess(App.context()) && str != null && str.length() <= 50) {
                    cs.a(new cs.a() {
                        @Override
                        public JSONObject fetch() throws Exception {
                            return new JSONObject().put("route_error", dVar.e + "://" + str + dVar.g);
                        }
                    });
                }
                if (!TextUtils.isEmpty(dVar.f25489c) && !dVar.f25489c.equals("https://reading.snssdk.com/reading_offline/drweb/page/scan-code.html?hide_nav_bar=1&hide_status_bar=1&need_custom_brightness=1&custom_brightness=1&version_code=6.2.3.32")) {
                    SmartRouter.buildRoute(App.context(), "https://reading.snssdk.com/reading_offline/drweb/page/scan-code.html?hide_nav_bar=1&hide_status_bar=1&need_custom_brightness=1&custom_brightness=1&version_code=6.2.3.32").open();
                }
            }
        });
    }
}