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

import X.2HN;
import X.AnonymousClass7U3;
import X.AnonymousClass7bK;
import X.AnonymousClass7bM;
import X.AnonymousClass7bS;
import X.AnonymousClass7bT;
import X.AnonymousClass7bU;
import X.AnonymousClass7bV;
import X.AnonymousClass7c0;
import X.AnonymousClass7c1;
import X.AnonymousClass7dQ;
import X.C02937ba;
import X.C03187bz;
import X.C03207cb;
import X.C03217cc;
import X.C03227cd;
import X.C03237ce;
import X.C03247cf;
import X.C03267ch;
import X.C03277ci;
import X.C03287cj;
import X.C11217we;
import X.C11227wf;
import X.C11237wg;
import X.C11247wh;
import X.C11257wi;
import X.C11267wj;
import X.C11277wk;
import X.C11287wl;
import X.C11297wm;
import X.C11307wn;
import X.Ls0;
import X.M12;
import android.app.Application;
import android.os.SystemClock;
import android.text.TextUtils;
import com.bytedance.covode.number.Covode;
import com.ss.android.ugc.aweme.playereventreporter.VideoInfo;
import com.ss.android.ugc.aweme.simreporter.InitInfo;
import com.ss.android.ugc.aweme.simreporter.api.ISimReporterConfig;
import com.ss.android.ugc.aweme.simreporter.callback.UpdateCallback;
import com.ss.android.ugc.aweme.simreporter.service.IPlayerEventReportService;
import com.ss.android.ugc.aweme.simreporterdt.report.IPlayerEventReporter;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.LinkedHashMap;
import java.util.List;
import java.util.Objects;
import java.util.concurrent.Callable;
import kotlin.h.b.n;

public final class SimDtReportService implements IPlayerEventReportService {
    public final AnonymousClass7U3 executorService;
    public boolean isDecodeBuffering;
    public final LinkedHashMap<String, List<Long>> mBufferingTimeRecords;
    public final LinkedHashMap<String, List<Long>> mPausedTimeRecords;
    public final LinkedHashMap<String, Long> mVideoBufferingStartTimeMap;
    public final LinkedHashMap<String, Boolean> mVideoFirstBufferingCrossFirstFrame;
    public final LinkedHashMap<String, Long> mVideoFirstFrameTimeMap;
    public final LinkedHashMap<String, Boolean> mVideoHasRendered;
    public final LinkedHashMap<String, Boolean> mVideoIsNetworkBuffering;
    public final LinkedHashMap<String, Long> mVideoPausedTimeMap;
    public final LinkedHashMap<String, String> mVideoPendingRenderMap;
    public final LinkedHashMap<String, Long> mVideoPrepareTimeMap;
    public AnonymousClass7bS pm;
    public IPlayerEventReporter reporter;
    public ISimReporterConfig reporterConfig;
    public int totalDecodeBufferCount;
    public long totalDecodeBufferTime;
    public int totalNetBufferCount;
    public long videoDecodeBufferingStartTime;
    public int videoResponseHasReportedCount;

    static {
        Covode.recordClassIndex(114609);
    }

    public SimDtReportService() {
        this((IPlayerEventReporter) null, 1, (2HN) null);
    }

    public final void init(Application application, InitInfo initInfo) {
    }

    public final void reportBufferLength(String str, long j) {
    }

    public final void reportCdnIP(String str, String str2) {
    }

    public final void reportSeekEnd(String str) {
    }

    public final void reportSeekStart(String str, double d) {
    }

    public final void reportVideoResolution(String str, int i, int i2) {
    }

    public final int getVideoResponseHasReportedCount() {
        return this.videoResponseHasReportedCount;
    }

    public final void release() {
        AnonymousClass7bS r2 = this.pm;
        r2.LIZ = null;
        r2.LIZIZ = null;
        r2.LIZJ.clear();
        r2.LIZLLL = null;
        this.reporter = null;
    }

    public final void setVideoResponseHasReportedCount(int i) {
        this.videoResponseHasReportedCount = i;
    }

    public final void initConfig(ISimReporterConfig iSimReporterConfig) {
        M12.LIZ(iSimReporterConfig);
        this.reporterConfig = iSimReporterConfig;
    }

    public final void setUpdateCallback(UpdateCallback updateCallback) {
        IPlayerEventReporter iPlayerEventReporter = this.reporter;
        if (iPlayerEventReporter != null) {
            iPlayerEventReporter.LIZ(updateCallback);
        }
    }

    private final long getVideoBufferingStartTime(String str) {
        Long l;
        if (!TextUtils.isEmpty(str)) {
            LinkedHashMap<String, Long> linkedHashMap = this.mVideoBufferingStartTimeMap;
            Objects.requireNonNull(linkedHashMap, "null cannot be cast to non-null type kotlin.collections.Map<K, *>");
            if (linkedHashMap.containsKey(str) && (l = this.mVideoBufferingStartTimeMap.get(str)) != null) {
                return l.longValue();
            }
        }
        return -1;
    }

    private final boolean getVideoFirstBufferingCrossFirstFrame(String str) {
        Boolean bool;
        if (!TextUtils.isEmpty(str)) {
            LinkedHashMap<String, Boolean> linkedHashMap = this.mVideoFirstBufferingCrossFirstFrame;
            Objects.requireNonNull(linkedHashMap, "null cannot be cast to non-null type kotlin.collections.Map<K, *>");
            if (linkedHashMap.containsKey(str) && (bool = this.mVideoFirstBufferingCrossFirstFrame.get(str)) != null) {
                return bool.booleanValue();
            }
        }
        return false;
    }

    private final long getVideoFirstFrameTime(String str) {
        Long l;
        if (!TextUtils.isEmpty(str)) {
            LinkedHashMap<String, Long> linkedHashMap = this.mVideoFirstFrameTimeMap;
            Objects.requireNonNull(linkedHashMap, "null cannot be cast to non-null type kotlin.collections.Map<K, *>");
            if (linkedHashMap.containsKey(str) && (l = this.mVideoFirstFrameTimeMap.get(str)) != null) {
                return l.longValue();
            }
        }
        return -1;
    }

    private final boolean getVideoRenderedStatus(String str) {
        Boolean bool;
        if (!TextUtils.isEmpty(str)) {
            LinkedHashMap<String, Boolean> linkedHashMap = this.mVideoHasRendered;
            Objects.requireNonNull(linkedHashMap, "null cannot be cast to non-null type kotlin.collections.Map<K, *>");
            if (linkedHashMap.containsKey(str) && (bool = this.mVideoHasRendered.get(str)) != null) {
                return bool.booleanValue();
            }
        }
        return false;
    }

    private final boolean isNetworkBuffering(String str) {
        Boolean bool;
        if (!TextUtils.isEmpty(str)) {
            LinkedHashMap<String, Boolean> linkedHashMap = this.mVideoIsNetworkBuffering;
            Objects.requireNonNull(linkedHashMap, "null cannot be cast to non-null type kotlin.collections.Map<K, *>");
            if (linkedHashMap.containsKey(str) && (bool = this.mVideoIsNetworkBuffering.get(str)) != null) {
                return bool.booleanValue();
            }
        }
        return false;
    }

    public SimDtReportService(IPlayerEventReporter iPlayerEventReporter) {
        this.reporter = iPlayerEventReporter;
        this.pm = new AnonymousClass7bS();
        this.executorService = new AnonymousClass7U3(AnonymousClass7dQ.LIZIZ);
        this.reporterConfig = new C03287cj();
        this.mVideoFirstBufferingCrossFirstFrame = new C11247wh();
        this.mVideoHasRendered = new C11267wj();
        this.mVideoIsNetworkBuffering = new C11277wk();
        this.mVideoPendingRenderMap = new C11307wn();
        this.mVideoPrepareTimeMap = new C11297wm();
        this.mVideoFirstFrameTimeMap = new C11257wi();
        this.mVideoPausedTimeMap = new C11287wl();
        this.mVideoBufferingStartTimeMap = new C11237wg();
        this.mPausedTimeRecords = new C11227wf();
        this.mBufferingTimeRecords = new C11217we();
    }

    public final void reportVideoPlaying(String str) {
        if (!TextUtils.isEmpty(str)) {
            LinkedHashMap<String, Long> linkedHashMap = this.mVideoPausedTimeMap;
            if (str == null) {
                n.LIZIZ();
            }
            Long l = linkedHashMap.get(str);
            if (l != null && l.longValue() >= 0) {
                if (SystemClock.elapsedRealtime() > l.longValue()) {
                    long elapsedRealtime = SystemClock.elapsedRealtime() - l.longValue();
                    if (!TextUtils.isEmpty(str)) {
                        List list = this.mPausedTimeRecords.get(str);
                        if (list == null) {
                            list = new ArrayList();
                        }
                        list.add(Long.valueOf(elapsedRealtime));
                        this.mPausedTimeRecords.put(str, list);
                    }
                }
                this.pm.LJFF(str);
            }
        }
    }

    private final void updateVideoBufferingStartTime(String str, long j) {
        setVideoBufferingStartTime(str, Long.valueOf(j));
    }

    private final void setVideoBufferingStartTime(String str, Long l) {
        if (!TextUtils.isEmpty(str) && l != null && l.longValue() > 0) {
            LinkedHashMap<String, Long> linkedHashMap = this.mVideoBufferingStartTimeMap;
            if (str == null) {
                n.LIZIZ();
            }
            linkedHashMap.put(str, l);
        }
    }

    public final void reportVideoOnResume(String str, VideoInfo videoInfo) {
        Boolean bool;
        if (!TextUtils.isEmpty(str) && (bool = this.mVideoIsNetworkBuffering.get(str)) != null && bool.booleanValue()) {
            LinkedHashMap<String, Long> linkedHashMap = this.mVideoBufferingStartTimeMap;
            Objects.requireNonNull(linkedHashMap, "null cannot be cast to non-null type kotlin.collections.Map<K, *>");
            if (linkedHashMap.containsKey(str)) {
                LinkedHashMap<String, Long> linkedHashMap2 = this.mVideoBufferingStartTimeMap;
                if (str == null) {
                    n.LIZIZ();
                }
                linkedHashMap2.put(str, Long.valueOf(SystemClock.elapsedRealtime()));
            }
        }
    }

    public final void reportVideoPlayStart(String str, Callable<AnonymousClass7bT> callable) {
        M12.LIZ(callable);
        if (!TextUtils.isEmpty(str)) {
            this.executorService.LIZ(new C03267ch(this, callable, str));
            LinkedHashMap<String, Long> linkedHashMap = this.mVideoPrepareTimeMap;
            if (str == null) {
                n.LIZIZ();
            }
            linkedHashMap.put(str, Long.valueOf(SystemClock.elapsedRealtime()));
            this.mVideoPendingRenderMap.put(str, str);
            this.mVideoBufferingStartTimeMap.remove(str);
            this.mVideoIsNetworkBuffering.remove(str);
            this.mVideoFirstBufferingCrossFirstFrame.remove(str);
            this.mBufferingTimeRecords.remove(str);
            this.mVideoPausedTimeMap.remove(str);
            this.mVideoHasRendered.remove(str);
            this.mVideoFirstFrameTimeMap.remove(str);
            this.mPausedTimeRecords.remove(str);
            this.isDecodeBuffering = false;
            this.videoDecodeBufferingStartTime = 0;
            this.totalNetBufferCount = 0;
            this.totalDecodeBufferCount++;
            this.totalDecodeBufferTime = 0;
        }
    }

    /* JADX WARNING: Removed duplicated region for block: B:40:0x00c3  */
    /* JADX WARNING: Removed duplicated region for block: B:53:0x00f1  */
    /* JADX WARNING: Removed duplicated region for block: B:60:0x0111  */
    /* JADX WARNING: Removed duplicated region for block: B:67:0x012e  */
    /* JADX WARNING: Removed duplicated region for block: B:70:0x0140 A[ADDED_TO_REGION] */
    /* Code decompiled incorrectly, please refer to instructions dump. */
    public final void reportVideoPause(java.lang.String r19, X.C03307cl r20) {
        /*
            r18 = this;
            r0 = r18
            r6 = r19
            r1 = r6
            boolean r1 = android.text.TextUtils.isEmpty(r1)
            if (r1 == 0) goto L_0x000c
            return
        L_0x000c:
            X.7bS r1 = r0.pm
            r1.LJ(r6)
            java.util.LinkedHashMap<java.lang.String, java.lang.Long> r1 = r0.mVideoFirstFrameTimeMap
            java.lang.Object r9 = r1.get(r6)
            java.lang.Long r9 = (java.lang.Long) r9
            r1 = 0
            if (r9 == 0) goto L_0x0043
            long r4 = r9.longValue()
            int r3 = (r4 > r1 ? 1 : (r4 == r1 ? 0 : -1))
            if (r3 <= 0) goto L_0x0043
            long r7 = android.os.SystemClock.elapsedRealtime()
            long r4 = r9.longValue()
            int r3 = (r7 > r4 ? 1 : (r7 == r4 ? 0 : -1))
            if (r3 <= 0) goto L_0x0043
            java.util.LinkedHashMap<java.lang.String, java.lang.Long> r5 = r0.mVideoPausedTimeMap
            if (r6 != 0) goto L_0x0038
            kotlin.h.b.n.LIZIZ()
        L_0x0038:
            long r3 = android.os.SystemClock.elapsedRealtime()
            java.lang.Long r3 = java.lang.Long.valueOf(r3)
            r5.put(r6, r3)
        L_0x0043:
            java.util.LinkedHashMap<java.lang.String, java.util.List<java.lang.Long>> r4 = r0.mBufferingTimeRecords
            java.lang.String r3 = "null cannot be cast to non-null type kotlin.collections.Map<K, *>"
            java.util.Objects.requireNonNull(r4, r3)
            boolean r3 = r4.containsKey(r6)
            if (r3 == 0) goto L_0x0072
            java.util.LinkedHashMap<java.lang.String, java.util.List<java.lang.Long>> r3 = r0.mBufferingTimeRecords
            java.lang.Object r3 = r3.get(r6)
            java.util.List r3 = (java.util.List) r3
            if (r3 == 0) goto L_0x0072
            java.util.Iterator r5 = r3.iterator()
            r13 = 0
        L_0x0060:
            boolean r3 = r5.hasNext()
            if (r3 == 0) goto L_0x0074
            java.lang.Object r3 = r5.next()
            java.lang.Number r3 = (java.lang.Number) r3
            long r3 = r3.longValue()
            long r13 = r13 + r3
            goto L_0x0060
        L_0x0072:
            r13 = 0
        L_0x0074:
            java.util.LinkedHashMap<java.lang.String, java.lang.Long> r3 = r0.mVideoBufferingStartTimeMap
            java.lang.Object r3 = r3.get(r6)
            java.lang.Long r3 = (java.lang.Long) r3
            java.lang.String r10 = ""
            if (r3 == 0) goto L_0x0088
            long r7 = r3.longValue()
            int r4 = (r7 > r1 ? 1 : (r7 == r1 ? 0 : -1))
            if (r4 > 0) goto L_0x0198
        L_0x0088:
            java.util.LinkedHashMap<java.lang.String, java.lang.Boolean> r4 = r0.mVideoFirstBufferingCrossFirstFrame
            java.lang.Object r4 = r4.get(r6)
            java.lang.Boolean r4 = (java.lang.Boolean) r4
            if (r4 == 0) goto L_0x0198
            boolean r4 = r4.booleanValue()
            if (r4 == 0) goto L_0x0198
            com.ss.android.ugc.aweme.simreporter.api.ISimReporterConfig r4 = r0.reporterConfig
            java.lang.Boolean r4 = r4.LIZIZ()
            kotlin.h.b.n.LIZIZ(r4, r10)
            boolean r4 = r4.booleanValue()
            if (r4 == 0) goto L_0x0198
            java.util.LinkedHashMap<java.lang.String, java.lang.Long> r4 = r0.mVideoFirstFrameTimeMap
            java.lang.Object r4 = r4.get(r6)
            if (r4 == 0) goto L_0x0198
            java.util.LinkedHashMap<java.lang.String, java.lang.Long> r3 = r0.mVideoFirstFrameTimeMap
            java.lang.Object r3 = r3.get(r6)
            if (r3 != 0) goto L_0x00ba
            kotlin.h.b.n.LIZIZ()
        L_0x00ba:
            java.lang.Long r3 = (java.lang.Long) r3
            r4 = 1
            r17 = 1
        L_0x00bf:
            java.util.LinkedHashMap<java.lang.String, java.lang.Boolean> r4 = r0.mVideoIsNetworkBuffering
            if (r6 != 0) goto L_0x00c6
            kotlin.h.b.n.LIZIZ()
        L_0x00c6:
            java.lang.Object r9 = r4.get(r6)
            java.lang.Boolean r9 = (java.lang.Boolean) r9
            if (r9 == 0) goto L_0x00d4
            boolean r4 = r9.booleanValue()
            if (r4 != 0) goto L_0x00d8
        L_0x00d4:
            boolean r4 = r0.isDecodeBuffering
            if (r4 == 0) goto L_0x00fa
        L_0x00d8:
            if (r3 == 0) goto L_0x00eb
            long r7 = r3.longValue()
            int r4 = (r7 > r1 ? 1 : (r7 == r1 ? 0 : -1))
            if (r4 <= 0) goto L_0x00eb
            long r13 = android.os.SystemClock.elapsedRealtime()
            long r4 = r3.longValue()
            long r13 = r13 - r4
        L_0x00eb:
            long r4 = r0.videoDecodeBufferingStartTime
            int r7 = (r4 > r1 ? 1 : (r4 == r1 ? 0 : -1))
            if (r7 == 0) goto L_0x00fa
            long r4 = android.os.SystemClock.elapsedRealtime()
            long r7 = r0.videoDecodeBufferingStartTime
            long r4 = r4 - r7
            r0.totalDecodeBufferTime = r4
        L_0x00fa:
            com.ss.android.ugc.aweme.simreporter.api.ISimReporterConfig r4 = r0.reporterConfig
            java.lang.Boolean r7 = r4.LIZJ()
            int r4 = r0.totalNetBufferCount
            if (r4 <= 0) goto L_0x011b
            int r4 = (r13 > r1 ? 1 : (r13 == r1 ? 0 : -1))
            if (r4 <= 0) goto L_0x011b
            kotlin.h.b.n.LIZIZ(r7, r10)
            boolean r4 = r7.booleanValue()
            if (r4 == 0) goto L_0x011b
            r16 = 1
            java.lang.String r15 = "leave"
            r11 = r18
            r12 = r6
            r11.reportBlock(r12, r13, r15, r16, r17)
        L_0x011b:
            int r4 = r0.totalDecodeBufferCount
            if (r4 <= 0) goto L_0x013a
            long r4 = r0.totalDecodeBufferTime
            int r8 = (r4 > r1 ? 1 : (r4 == r1 ? 0 : -1))
            if (r8 <= 0) goto L_0x013a
            kotlin.h.b.n.LIZIZ(r7, r10)
            boolean r4 = r7.booleanValue()
            if (r4 == 0) goto L_0x013a
            long r13 = r0.totalDecodeBufferTime
            r16 = 0
            java.lang.String r15 = "leave"
            r11 = r18
            r12 = r6
            r11.reportBlock(r12, r13, r15, r16, r17)
        L_0x013a:
            boolean r4 = r7.booleanValue()
            if (r4 != 0) goto L_0x018e
            if (r9 == 0) goto L_0x0172
            boolean r4 = r9.booleanValue()
            if (r4 == 0) goto L_0x0172
            if (r3 == 0) goto L_0x0172
            long r7 = r3.longValue()
            int r4 = (r7 > r1 ? 1 : (r7 == r1 ? 0 : -1))
            if (r4 < 0) goto L_0x0172
            long r13 = android.os.SystemClock.elapsedRealtime()
            long r3 = r3.longValue()
            long r13 = r13 - r3
            r16 = 1
            java.lang.String r15 = "leave"
            r11 = r18
            r12 = r6
            r11.reportBlock(r12, r13, r15, r16, r17)
            java.util.LinkedHashMap<java.lang.String, java.lang.Long> r5 = r0.mVideoBufferingStartTimeMap
            long r3 = android.os.SystemClock.elapsedRealtime()
            java.lang.Long r3 = java.lang.Long.valueOf(r3)
            r5.put(r6, r3)
        L_0x0172:
            boolean r3 = r0.isDecodeBuffering
            if (r3 == 0) goto L_0x018e
            long r4 = r0.videoDecodeBufferingStartTime
            int r3 = (r4 > r1 ? 1 : (r4 == r1 ? 0 : -1))
            if (r3 <= 0) goto L_0x018e
            long r7 = android.os.SystemClock.elapsedRealtime()
            long r3 = r0.videoDecodeBufferingStartTime
            long r7 = r7 - r3
            r10 = 0
            java.lang.String r9 = "leave"
            r5 = r18
            r6 = r6
            r11 = r17
            r5.reportBlock(r6, r7, r9, r10, r11)
        L_0x018e:
            r0.videoDecodeBufferingStartTime = r1
            r3 = 0
            r0.totalNetBufferCount = r3
            r0.totalDecodeBufferCount = r3
            r0.totalDecodeBufferTime = r1
            return
        L_0x0198:
            r17 = 0
            goto L_0x00bf
        */
        throw new UnsupportedOperationException("Method not decompiled: com.ss.android.ugc.aweme.simreporterdt.SimDtReportService.reportVideoPause(java.lang.String, X.7cl):void");
    }

    /* JADX INFO: this call moved to the top of the method (can break code semantics) */
    public /* synthetic */ SimDtReportService(IPlayerEventReporter iPlayerEventReporter, int i, 2HN r4) {
        this((i & 1) != 0 ? new AnonymousClass7bK() : iPlayerEventReporter);
    }

    public final void reportVideoPlayFirstFinish(String str, Callable<C03187bz> callable, HashMap<String, Object> hashMap) {
        M12.LIZ(callable);
        this.executorService.LIZ(new C03237ce(this, str, callable));
    }

    public final void reportVideoPlayTime(String str, Callable<AnonymousClass7c0> callable, HashMap<String, Object> hashMap) {
        M12.LIZ(callable);
        this.executorService.LIZ(new C03247cf(this, str, callable));
    }

    public final void reportVideoResponse(String str, int i, C02937ba r6) {
        String str2;
        if (this.videoResponseHasReportedCount < 10) {
            AnonymousClass7c1 LIZ = this.pm.LIZ(str);
            VideoInfo LIZIZ = this.pm.LIZIZ(str);
            if (!TextUtils.isEmpty(str) && LIZIZ != null) {
                if (LIZ != null) {
                    str2 = LIZ.LIZ;
                } else {
                    str2 = null;
                }
                r6.LIZJ = str2;
                IPlayerEventReporter iPlayerEventReporter = this.reporter;
                if (iPlayerEventReporter != null) {
                    iPlayerEventReporter.LIZ(i, LIZIZ, r6);
                }
                this.videoResponseHasReportedCount++;
            }
        }
    }

    /* JADX WARNING: Removed duplicated region for block: B:34:0x009f  */
    /* JADX WARNING: Removed duplicated region for block: B:37:0x00aa  */
    /* JADX WARNING: Removed duplicated region for block: B:40:0x00c2  */
    /* JADX WARNING: Removed duplicated region for block: B:52:0x00ed A[ADDED_TO_REGION] */
    /* Code decompiled incorrectly, please refer to instructions dump. */
    public final void reportVideoPause(java.lang.String r20, java.util.concurrent.Callable<X.AnonymousClass7bV> r21, X.C03307cl r22) {
        /*
            r19 = this;
            r0 = r19
            r0 = r0
            r13 = r21
            X.M12.LIZ(r13)
            r12 = r20
            r1 = r12
            boolean r1 = android.text.TextUtils.isEmpty(r1)
            if (r1 == 0) goto L_0x0012
            return
        L_0x0012:
            X.7bS r1 = r0.pm
            r1.LJ(r12)
            long r10 = r0.getVideoFirstFrameTime(r12)
            r1 = 0
            int r6 = (r10 > r1 ? 1 : (r10 == r1 ? 0 : -1))
            if (r6 <= 0) goto L_0x003b
            long r4 = android.os.SystemClock.elapsedRealtime()
            int r3 = (r4 > r10 ? 1 : (r4 == r10 ? 0 : -1))
            if (r3 <= 0) goto L_0x003b
            java.util.LinkedHashMap<java.lang.String, java.lang.Long> r5 = r0.mVideoPausedTimeMap
            if (r12 != 0) goto L_0x0030
            kotlin.h.b.n.LIZIZ()
        L_0x0030:
            long r3 = android.os.SystemClock.elapsedRealtime()
            java.lang.Long r3 = java.lang.Long.valueOf(r3)
            r5.put(r12, r3)
        L_0x003b:
            java.util.LinkedHashMap<java.lang.String, java.util.List<java.lang.Long>> r4 = r0.mBufferingTimeRecords
            java.lang.String r3 = "null cannot be cast to non-null type kotlin.collections.Map<K, *>"
            java.util.Objects.requireNonNull(r4, r3)
            boolean r3 = r4.containsKey(r12)
            if (r3 == 0) goto L_0x006a
            java.util.LinkedHashMap<java.lang.String, java.util.List<java.lang.Long>> r3 = r0.mBufferingTimeRecords
            java.lang.Object r3 = r3.get(r12)
            java.util.List r3 = (java.util.List) r3
            if (r3 == 0) goto L_0x006a
            java.util.Iterator r5 = r3.iterator()
            r14 = 0
        L_0x0058:
            boolean r3 = r5.hasNext()
            if (r3 == 0) goto L_0x006c
            java.lang.Object r3 = r5.next()
            java.lang.Number r3 = (java.lang.Number) r3
            long r3 = r3.longValue()
            long r14 = r14 + r3
            goto L_0x0058
        L_0x006a:
            r14 = 0
        L_0x006c:
            long r4 = r0.getVideoBufferingStartTime(r12)
            java.lang.String r8 = ""
            r7 = 0
            int r3 = (r4 > r1 ? 1 : (r4 == r1 ? 0 : -1))
            if (r3 > 0) goto L_0x0125
            boolean r3 = r0.getVideoFirstBufferingCrossFirstFrame(r12)
            if (r3 == 0) goto L_0x0125
            com.ss.android.ugc.aweme.simreporter.api.ISimReporterConfig r3 = r0.reporterConfig
            java.lang.Boolean r3 = r3.LIZIZ()
            kotlin.h.b.n.LIZIZ(r3, r8)
            boolean r3 = r3.booleanValue()
            if (r3 == 0) goto L_0x0125
            if (r6 <= 0) goto L_0x0125
            r3 = 1
            r18 = 1
        L_0x0091:
            boolean r9 = r0.isNetworkBuffering(r12)
            if (r9 != 0) goto L_0x009b
            boolean r3 = r0.isDecodeBuffering
            if (r3 == 0) goto L_0x00b3
        L_0x009b:
            int r3 = (r10 > r1 ? 1 : (r10 == r1 ? 0 : -1))
            if (r3 <= 0) goto L_0x00a4
            long r14 = android.os.SystemClock.elapsedRealtime()
            long r14 = r14 - r10
        L_0x00a4:
            long r3 = r0.videoDecodeBufferingStartTime
            int r5 = (r3 > r1 ? 1 : (r3 == r1 ? 0 : -1))
            if (r5 == 0) goto L_0x00b3
            long r3 = android.os.SystemClock.elapsedRealtime()
            long r5 = r0.videoDecodeBufferingStartTime
            long r3 = r3 - r5
            r0.totalDecodeBufferTime = r3
        L_0x00b3:
            com.ss.android.ugc.aweme.simreporter.api.ISimReporterConfig r3 = r0.reporterConfig
            java.lang.Boolean r3 = r3.LIZJ()
            kotlin.h.b.n.LIZIZ(r3, r8)
            boolean r3 = r3.booleanValue()
            if (r3 == 0) goto L_0x00ed
            int r3 = r0.totalNetBufferCount
            if (r3 <= 0) goto L_0x00d2
            int r3 = (r14 > r1 ? 1 : (r14 == r1 ? 0 : -1))
            if (r3 <= 0) goto L_0x00d2
            r17 = 1
            java.lang.String r16 = "leave"
            r11 = r0
            r11.reportBlock(r12, r13, r14, r16, r17, r18)
        L_0x00d2:
            int r3 = r0.totalDecodeBufferCount
            if (r3 <= 0) goto L_0x00e4
            long r14 = r0.totalDecodeBufferTime
            int r3 = (r14 > r1 ? 1 : (r14 == r1 ? 0 : -1))
            if (r3 <= 0) goto L_0x00e4
            r17 = 0
            java.lang.String r16 = "leave"
            r11 = r0
            r11.reportBlock(r12, r13, r14, r16, r17, r18)
        L_0x00e4:
            r0.videoDecodeBufferingStartTime = r1
            r0.totalNetBufferCount = r7
            r0.totalDecodeBufferCount = r7
            r0.totalDecodeBufferTime = r1
            return
        L_0x00ed:
            if (r9 == 0) goto L_0x010b
            int r3 = (r10 > r1 ? 1 : (r10 == r1 ? 0 : -1))
            if (r3 < 0) goto L_0x010b
            long r14 = android.os.SystemClock.elapsedRealtime()
            long r14 = r14 - r10
            r17 = 1
            java.lang.String r16 = "leave"
            r11 = r0
            r12 = r12
            r13 = r13
            r18 = r18
            r11.reportBlock(r12, r13, r14, r16, r17, r18)
            long r3 = android.os.SystemClock.elapsedRealtime()
            r0.updateVideoBufferingStartTime(r12, r3)
        L_0x010b:
            boolean r3 = r0.isDecodeBuffering
            if (r3 == 0) goto L_0x00e4
            long r3 = r0.videoDecodeBufferingStartTime
            int r5 = (r3 > r1 ? 1 : (r3 == r1 ? 0 : -1))
            if (r5 <= 0) goto L_0x00e4
            long r14 = android.os.SystemClock.elapsedRealtime()
            long r3 = r0.videoDecodeBufferingStartTime
            long r14 = r14 - r3
            r17 = 0
            java.lang.String r16 = "leave"
            r11 = r0
            r11.reportBlock(r12, r13, r14, r16, r17, r18)
            goto L_0x00e4
        L_0x0125:
            r10 = r4
            r18 = 0
            goto L_0x0091
        */
        throw new UnsupportedOperationException("Method not decompiled: com.ss.android.ugc.aweme.simreporterdt.SimDtReportService.reportVideoPause(java.lang.String, java.util.concurrent.Callable, X.7cl):void");
    }

    /* JADX WARNING: Removed duplicated region for block: B:55:0x0113  */
    /* JADX WARNING: Removed duplicated region for block: B:67:? A[RETURN, SYNTHETIC] */
    /* Code decompiled incorrectly, please refer to instructions dump. */
    public final void reportVideoBuffering(java.lang.String r17, boolean r18, boolean r19, java.util.concurrent.Callable<X.AnonymousClass7bV> r20) {
        /*
            r16 = this;
            r3 = r16
            r10 = r20
            X.M12.LIZ(r10)
            r8 = r17
            r0 = r8
            boolean r0 = android.text.TextUtils.isEmpty(r0)
            if (r0 == 0) goto L_0x0011
            return
        L_0x0011:
            java.util.LinkedHashMap<java.lang.String, java.lang.Boolean> r0 = r3.mVideoHasRendered
            if (r8 != 0) goto L_0x0018
            kotlin.h.b.n.LIZIZ()
        L_0x0018:
            java.lang.Object r2 = r0.get(r8)
            java.lang.Boolean r2 = (java.lang.Boolean) r2
            r7 = 0
            r4 = 1
            r5 = r19
            if (r18 == 0) goto L_0x0038
            if (r5 == 0) goto L_0x0038
            java.util.LinkedHashMap<java.lang.String, java.lang.Boolean> r1 = r3.mVideoFirstBufferingCrossFirstFrame
            if (r2 == 0) goto L_0x0030
            boolean r0 = r2.booleanValue()
            if (r0 != 0) goto L_0x00bc
        L_0x0030:
            r0 = 1
        L_0x0031:
            java.lang.Boolean r0 = java.lang.Boolean.valueOf(r0)
            r1.put(r8, r0)
        L_0x0038:
            if (r2 == 0) goto L_0x0040
            boolean r0 = r2.booleanValue()
            if (r0 != 0) goto L_0x0041
        L_0x0040:
            return
        L_0x0041:
            r0 = 0
            if (r18 == 0) goto L_0x007f
            if (r5 == 0) goto L_0x00bf
            java.util.LinkedHashMap<java.lang.String, java.lang.Boolean> r0 = r3.mVideoIsNetworkBuffering
            java.lang.Object r0 = r0.get(r8)
            java.lang.Boolean r0 = (java.lang.Boolean) r0
            if (r0 == 0) goto L_0x0057
            boolean r0 = r0.booleanValue()
            if (r0 != 0) goto L_0x0072
        L_0x0057:
            java.util.LinkedHashMap<java.lang.String, java.lang.Long> r2 = r3.mVideoBufferingStartTimeMap
            long r0 = android.os.SystemClock.elapsedRealtime()
            java.lang.Long r0 = java.lang.Long.valueOf(r0)
            r2.put(r8, r0)
            java.util.LinkedHashMap<java.lang.String, java.lang.Boolean> r1 = r3.mVideoIsNetworkBuffering
            java.lang.Boolean r0 = java.lang.Boolean.valueOf(r4)
            r1.put(r8, r0)
            int r0 = r3.totalNetBufferCount
            int r0 = r0 + r4
            r3.totalNetBufferCount = r0
        L_0x0072:
            r9 = 1
            r11 = -1
            r14 = 1
            r15 = 0
            java.lang.String r13 = ""
            r7 = r16
            r7.reportBlock(r8, r9, r10, r11, r13, r14, r15)
            return
        L_0x007f:
            r3.isDecodeBuffering = r5
            if (r5 == 0) goto L_0x009b
            long r0 = android.os.SystemClock.elapsedRealtime()
            r3.videoDecodeBufferingStartTime = r0
            int r0 = r3.totalDecodeBufferCount
            int r0 = r0 + r4
            r3.totalDecodeBufferCount = r0
            r9 = 1
            r11 = -1
            r14 = 0
            r15 = 0
            java.lang.String r13 = ""
            r7 = r16
            r7.reportBlock(r8, r9, r10, r11, r13, r14, r15)
            return
        L_0x009b:
            long r4 = r3.videoDecodeBufferingStartTime
            int r2 = (r4 > r0 ? 1 : (r4 == r0 ? 0 : -1))
            if (r2 == 0) goto L_0x0040
            long r11 = android.os.SystemClock.elapsedRealtime()
            long r4 = r3.videoDecodeBufferingStartTime
            long r11 = r11 - r4
            long r4 = r3.totalDecodeBufferTime
            long r4 = r4 + r11
            r3.totalDecodeBufferTime = r4
            r3.videoDecodeBufferingStartTime = r0
            r9 = 0
            r0 = 0
            r0 = 0
            java.lang.String r13 = "resume"
            r7 = r16
            r14 = 0
            r15 = 0
            r7.reportBlock(r8, r9, r10, r11, r13, r14, r15)
            goto L_0x0040
        L_0x00bc:
            r0 = 0
            goto L_0x0031
        L_0x00bf:
            java.util.LinkedHashMap<java.lang.String, java.lang.Long> r2 = r3.mVideoBufferingStartTimeMap
            java.lang.Object r6 = r2.get(r8)
            java.lang.Long r6 = (java.lang.Long) r6
            if (r6 == 0) goto L_0x00d1
            long r4 = r6.longValue()
            int r2 = (r4 > r0 ? 1 : (r4 == r0 ? 0 : -1))
            if (r2 > 0) goto L_0x0156
        L_0x00d1:
            java.util.LinkedHashMap<java.lang.String, java.lang.Boolean> r2 = r3.mVideoFirstBufferingCrossFirstFrame
            java.lang.Object r2 = r2.get(r8)
            java.lang.Boolean r2 = (java.lang.Boolean) r2
            if (r2 == 0) goto L_0x0156
            boolean r2 = r2.booleanValue()
            if (r2 == 0) goto L_0x0156
            com.ss.android.ugc.aweme.simreporter.api.ISimReporterConfig r2 = r3.reporterConfig
            java.lang.Boolean r4 = r2.LIZIZ()
            java.lang.String r2 = ""
            kotlin.h.b.n.LIZIZ(r4, r2)
            boolean r2 = r4.booleanValue()
            if (r2 == 0) goto L_0x0156
            java.util.LinkedHashMap<java.lang.String, java.lang.Long> r2 = r3.mVideoFirstFrameTimeMap
            java.lang.Object r2 = r2.get(r8)
            if (r2 == 0) goto L_0x0156
            java.util.LinkedHashMap<java.lang.String, java.lang.Long> r2 = r3.mVideoFirstFrameTimeMap
            java.lang.Object r6 = r2.get(r8)
            if (r6 != 0) goto L_0x0105
            kotlin.h.b.n.LIZIZ()
        L_0x0105:
            java.lang.Long r6 = (java.lang.Long) r6
            r15 = 1
        L_0x0108:
            if (r6 == 0) goto L_0x0112
            long r4 = r6.longValue()
            int r2 = (r4 > r0 ? 1 : (r4 == r0 ? 0 : -1))
            if (r2 > 0) goto L_0x0113
        L_0x0112:
            return
        L_0x0113:
            java.util.LinkedHashMap<java.lang.String, java.lang.Boolean> r1 = r3.mVideoIsNetworkBuffering
            java.lang.Boolean r0 = java.lang.Boolean.valueOf(r7)
            r1.put(r8, r0)
            long r4 = android.os.SystemClock.elapsedRealtime()
            long r1 = r6.longValue()
            int r0 = (r4 > r1 ? 1 : (r4 == r1 ? 0 : -1))
            if (r0 <= 0) goto L_0x0112
            long r11 = android.os.SystemClock.elapsedRealtime()
            long r0 = r6.longValue()
            long r11 = r11 - r0
            java.util.LinkedHashMap<java.lang.String, java.util.List<java.lang.Long>> r0 = r3.mBufferingTimeRecords
            java.lang.Object r1 = r0.get(r8)
            java.util.List r1 = (java.util.List) r1
            if (r1 != 0) goto L_0x0140
            java.util.ArrayList r1 = new java.util.ArrayList
            r1.<init>()
        L_0x0140:
            java.lang.Long r0 = java.lang.Long.valueOf(r11)
            r1.add(r0)
            java.util.LinkedHashMap<java.lang.String, java.util.List<java.lang.Long>> r0 = r3.mBufferingTimeRecords
            r0.put(r8, r1)
            r9 = 0
            r14 = 1
            java.lang.String r13 = "resume"
            r7 = r16
            r7.reportBlock(r8, r9, r10, r11, r13, r14, r15)
            goto L_0x0112
        L_0x0156:
            r15 = 0
            goto L_0x0108
        */
        throw new UnsupportedOperationException("Method not decompiled: com.ss.android.ugc.aweme.simreporterdt.SimDtReportService.reportVideoBuffering(java.lang.String, boolean, boolean, java.util.concurrent.Callable):void");
    }

    private final void reportBlock(String str, long j, String str2, boolean z, int i) {
        String str3 = str;
        if (!TextUtils.isEmpty(str3)) {
            long j2 = j;
            boolean z2 = z;
            if (z2) {
                if (j2 < 200) {
                    return;
                }
            } else if (j2 <= 200) {
                return;
            }
            this.executorService.LIZ(new C03277ci(this, str3, i, j2, str2, z2));
        }
    }

    public final void reportPlayFailed(String str, Callable<AnonymousClass7bU> callable, HashMap<String, Object> hashMap, Callable<HashMap<String, Object>> callable2, boolean z) {
        Callable<AnonymousClass7bU> callable3 = callable;
        Callable<HashMap<String, Object>> callable4 = callable2;
        M12.LIZ(callable3, callable4);
        String str2 = str;
        if (!TextUtils.isEmpty(str2)) {
            LinkedHashMap<String, String> linkedHashMap = this.mVideoPendingRenderMap;
            Objects.requireNonNull(linkedHashMap, "null cannot be cast to non-null type kotlin.collections.Map<K, *>");
            boolean containsKey = linkedHashMap.containsKey(str2);
            long elapsedRealtime = SystemClock.elapsedRealtime();
            this.executorService.LIZ(new C03217cc(this, str2, this.mVideoPrepareTimeMap.get(str2), containsKey, z, elapsedRealtime, callable4, hashMap, callable3));
        }
    }

    public final void reportRenderFirstFrame(String str, Callable<AnonymousClass7bM> callable, HashMap<String, Object> hashMap, Callable<HashMap<String, Object>> callable2, boolean z) {
        Callable<AnonymousClass7bM> callable3 = callable;
        Callable<HashMap<String, Object>> callable4 = callable2;
        M12.LIZ(callable3, callable4);
        String str2 = str;
        if (!TextUtils.isEmpty(str2)) {
            LinkedHashMap<String, String> linkedHashMap = this.mVideoPendingRenderMap;
            Objects.requireNonNull(linkedHashMap, "null cannot be cast to non-null type kotlin.collections.MutableMap<K, V>");
            Ls0.LJI(linkedHashMap).remove(str2);
            long elapsedRealtime = SystemClock.elapsedRealtime();
            LinkedHashMap<String, Long> linkedHashMap2 = this.mVideoFirstFrameTimeMap;
            if (str2 == null) {
                n.LIZIZ();
            }
            linkedHashMap2.put(str2, Long.valueOf(elapsedRealtime));
            this.mVideoHasRendered.put(str2, true);
            Long l = this.mVideoPrepareTimeMap.get(str2);
            if (l != null && l.longValue() > 0) {
                this.executorService.LIZ(new C03207cb(this, str2, callable3, elapsedRealtime, l, z, callable4, hashMap));
            }
        }
    }

    /* JADX WARNING: Removed duplicated region for block: B:47:0x011c  */
    /* JADX WARNING: Removed duplicated region for block: B:50:0x0129  */
    /* Code decompiled incorrectly, please refer to instructions dump. */
    public final void reportVideoStop(java.lang.String r28, java.util.concurrent.Callable<X.AnonymousClass7bN> r29, java.util.HashMap<java.lang.String, java.lang.Object> r30, java.util.concurrent.Callable<java.util.HashMap<java.lang.String, java.lang.Object>> r31, boolean r32) {
        /*
            r27 = this;
            r7 = r27
            r9 = r29
            r8 = r31
            X.M12.LIZ(r9, r8)
            r10 = r28
            r0 = r10
            boolean r0 = android.text.TextUtils.isEmpty(r0)
            if (r0 == 0) goto L_0x0013
            return
        L_0x0013:
            X.4nL r6 = new X.4nL
            r6.<init>()
            r4 = 0
            r6.element = r4
            java.util.LinkedHashMap<java.lang.String, java.util.List<java.lang.Long>> r0 = r7.mBufferingTimeRecords
            java.lang.String r11 = "null cannot be cast to non-null type kotlin.collections.Map<K, *>"
            java.util.Objects.requireNonNull(r0, r11)
            boolean r1 = r0.containsKey(r10)
            r0 = 0
            if (r1 == 0) goto L_0x004e
            java.util.LinkedHashMap<java.lang.String, java.util.List<java.lang.Long>> r0 = r7.mBufferingTimeRecords
            java.lang.Object r0 = r0.get(r10)
            java.util.List r0 = (java.util.List) r0
            if (r0 == 0) goto L_0x004e
            java.util.Iterator r12 = r0.iterator()
        L_0x0038:
            boolean r0 = r12.hasNext()
            if (r0 == 0) goto L_0x004e
            java.lang.Object r0 = r12.next()
            java.lang.Number r0 = (java.lang.Number) r0
            long r2 = r0.longValue()
            long r0 = r6.element
            long r0 = r0 + r2
            r6.element = r0
            goto L_0x0038
        L_0x004e:
            X.4nL r12 = new X.4nL
            r12.<init>()
            r12.element = r4
            java.util.LinkedHashMap<java.lang.String, java.util.List<java.lang.Long>> r0 = r7.mPausedTimeRecords
            java.util.Objects.requireNonNull(r0, r11)
            boolean r0 = r0.containsKey(r10)
            if (r0 == 0) goto L_0x0084
            java.util.LinkedHashMap<java.lang.String, java.util.List<java.lang.Long>> r0 = r7.mPausedTimeRecords
            java.lang.Object r0 = r0.get(r10)
            java.util.List r0 = (java.util.List) r0
            if (r0 == 0) goto L_0x0084
            java.util.Iterator r13 = r0.iterator()
        L_0x006e:
            boolean r0 = r13.hasNext()
            if (r0 == 0) goto L_0x0084
            java.lang.Object r0 = r13.next()
            java.lang.Number r0 = (java.lang.Number) r0
            long r2 = r0.longValue()
            long r0 = r12.element
            long r0 = r0 + r2
            r12.element = r0
            goto L_0x006e
        L_0x0084:
            java.util.LinkedHashMap<java.lang.String, java.lang.Boolean> r0 = r7.mVideoIsNetworkBuffering
            java.lang.Object r14 = r0.get(r10)
            java.lang.Boolean r14 = (java.lang.Boolean) r14
            java.util.LinkedHashMap<java.lang.String, java.lang.Long> r0 = r7.mVideoPrepareTimeMap
            java.lang.Object r15 = r0.get(r10)
            java.lang.Long r15 = (java.lang.Long) r15
            if (r15 == 0) goto L_0x009e
            long r1 = r15.longValue()
            int r0 = (r1 > r4 ? 1 : (r1 == r4 ? 0 : -1))
            if (r0 > 0) goto L_0x009f
        L_0x009e:
            return
        L_0x009f:
            long r2 = android.os.SystemClock.elapsedRealtime()
            X.4nL r13 = new X.4nL
            r13.<init>()
            java.util.LinkedHashMap<java.lang.String, java.lang.Boolean> r0 = r7.mVideoHasRendered
            java.lang.Object r0 = r0.get(r10)
            if (r0 == 0) goto L_0x016e
            java.util.LinkedHashMap<java.lang.String, java.lang.Boolean> r0 = r7.mVideoHasRendered
            java.lang.Object r0 = r0.get(r10)
            if (r0 != 0) goto L_0x00bb
            kotlin.h.b.n.LIZIZ()
        L_0x00bb:
            java.lang.Boolean r0 = (java.lang.Boolean) r0
            boolean r0 = r0.booleanValue()
            if (r0 == 0) goto L_0x016e
            java.util.LinkedHashMap<java.lang.String, java.lang.Long> r0 = r7.mVideoFirstFrameTimeMap
            java.util.Objects.requireNonNull(r0, r11)
            boolean r0 = r0.containsKey(r10)
            if (r0 == 0) goto L_0x016e
            java.util.LinkedHashMap<java.lang.String, java.lang.Long> r0 = r7.mVideoFirstFrameTimeMap
            java.lang.Object r0 = r0.get(r10)
            if (r0 != 0) goto L_0x00d9
            kotlin.h.b.n.LIZIZ()
        L_0x00d9:
            java.lang.Number r0 = (java.lang.Number) r0
            long r16 = r0.longValue()
            int r0 = (r16 > r4 ? 1 : (r16 == r4 ? 0 : -1))
            if (r0 <= 0) goto L_0x016e
            java.util.LinkedHashMap<java.lang.String, java.lang.Long> r0 = r7.mVideoFirstFrameTimeMap
            java.lang.Object r0 = r0.get(r10)
            if (r0 != 0) goto L_0x00ee
            kotlin.h.b.n.LIZIZ()
        L_0x00ee:
            java.lang.Number r0 = (java.lang.Number) r0
            long r0 = r0.longValue()
            long r16 = r15.longValue()
            long r0 = r0 - r16
        L_0x00fa:
            r13.element = r0
            X.4nL r0 = new X.4nL
            r0.<init>()
            java.util.LinkedHashMap<java.lang.String, java.lang.Long> r1 = r7.mVideoFirstFrameTimeMap
            java.util.Objects.requireNonNull(r1, r11)
            boolean r1 = r1.containsKey(r10)
            if (r1 == 0) goto L_0x0169
            java.util.LinkedHashMap<java.lang.String, java.lang.Long> r1 = r7.mVideoFirstFrameTimeMap
            java.lang.Object r1 = r1.get(r10)
            if (r1 == 0) goto L_0x0169
            java.util.LinkedHashMap<java.lang.String, java.lang.Long> r1 = r7.mVideoFirstFrameTimeMap
            java.lang.Object r1 = r1.get(r10)
            if (r1 != 0) goto L_0x011f
            kotlin.h.b.n.LIZIZ()
        L_0x011f:
            java.lang.Number r1 = (java.lang.Number) r1
            long r16 = r1.longValue()
            int r1 = (r16 > r4 ? 1 : (r16 == r4 ? 0 : -1))
            if (r1 <= 0) goto L_0x0169
            java.util.LinkedHashMap<java.lang.String, java.lang.Long> r1 = r7.mVideoFirstFrameTimeMap
            java.lang.Object r1 = r1.get(r10)
            if (r1 != 0) goto L_0x0134
            kotlin.h.b.n.LIZIZ()
        L_0x0134:
            java.lang.Number r1 = (java.lang.Number) r1
            long r4 = r1.longValue()
        L_0x013a:
            long r2 = r2 - r4
            r0.element = r2
            java.util.LinkedHashMap<java.lang.String, java.lang.String> r1 = r7.mVideoPendingRenderMap
            java.util.Objects.requireNonNull(r1, r11)
            boolean r18 = r1.containsKey(r10)
            X.7U3 r2 = r7.executorService
            X.7ca r1 = new X.7ca
            r15 = r27
            r20 = r30
            r19 = r32
            r21 = r13
            r22 = r9
            r23 = r6
            r24 = r14
            r25 = r0
            r26 = r12
            r16 = r10
            r17 = r8
            r14 = r1
            r14.<init>(r15, r16, r17, r18, r19, r20, r21, r22, r23, r24, r25, r26)
            r2.LIZ(r1)
            goto L_0x009e
        L_0x0169:
            long r4 = r15.longValue()
            goto L_0x013a
        L_0x016e:
            long r16 = r15.longValue()
            long r0 = r2 - r16
            goto L_0x00fa
        */
        throw new UnsupportedOperationException("Method not decompiled: com.ss.android.ugc.aweme.simreporterdt.SimDtReportService.reportVideoStop(java.lang.String, java.util.concurrent.Callable, java.util.HashMap, java.util.concurrent.Callable, boolean):void");
    }

    /*  JADX ERROR: JadxRuntimeException in pass: CodeShrinkVisitor
        jadx.core.utils.exceptions.JadxRuntimeException: Don't wrap MOVE or CONST insns: 0x0007: MOVE  (r3v0 java.util.concurrent.Callable<X.7bV>) = (r12v0 java.util.concurrent.Callable<X.7bV>)
        	at jadx.core.dex.instructions.args.InsnArg.wrapArg(InsnArg.java:164)
        	at jadx.core.dex.visitors.shrink.CodeShrinkVisitor.assignInline(CodeShrinkVisitor.java:133)
        	at jadx.core.dex.visitors.shrink.CodeShrinkVisitor.checkInline(CodeShrinkVisitor.java:118)
        	at jadx.core.dex.visitors.shrink.CodeShrinkVisitor.shrinkBlock(CodeShrinkVisitor.java:65)
        	at jadx.core.dex.visitors.shrink.CodeShrinkVisitor.shrinkMethod(CodeShrinkVisitor.java:43)
        	at jadx.core.dex.visitors.shrink.CodeShrinkVisitor.visit(CodeShrinkVisitor.java:35)
        */
    private final void reportBlock(java.lang.String r11, java.util.concurrent.Callable<X.AnonymousClass7bV> r12, long r13, java.lang.String r15, boolean r16, int r17) {
        /*
            r10 = this;
            r4 = r11
            boolean r0 = android.text.TextUtils.isEmpty(r4)
            if (r0 != 0) goto L_0x000a
            r3 = r12
            if (r3 != 0) goto L_0x000c
        L_0x000a:
            r0 = r10
            return
        L_0x000c:
            r1 = 200(0xc8, double:9.9E-322)
            r6 = r13
            r9 = r16
            if (r9 == 0) goto L_0x0018
            int r0 = (r6 > r1 ? 1 : (r6 == r1 ? 0 : -1))
            if (r0 >= 0) goto L_0x001d
            return
        L_0x0018:
            int r0 = (r6 > r1 ? 1 : (r6 == r1 ? 0 : -1))
            if (r0 > 0) goto L_0x001d
            return
        L_0x001d:
            r0 = r10
            X.7U3 r0 = r0.executorService
            X.7cg r1 = new X.7cg
            r2 = r10
            r8 = r15
            r5 = r17
            r1.<init>(r2, r3, r4, r5, r6, r8, r9)
            r0.LIZ(r1)
            return
        */
        throw new UnsupportedOperationException("Method not decompiled: com.ss.android.ugc.aweme.simreporterdt.SimDtReportService.reportBlock(java.lang.String, java.util.concurrent.Callable, long, java.lang.String, boolean, int):void");
    }

    private final void reportBlock(String str, boolean z, Callable<AnonymousClass7bV> callable, long j, String str2, boolean z2, int i) {
        String str3 = str;
        if (!TextUtils.isEmpty(str3)) {
            boolean z3 = z2;
            long j2 = j;
            if (z3) {
                if (j2 < 200) {
                    return;
                }
            } else if (j2 <= 200) {
                return;
            }
            this.executorService.LIZ(new C03227cd(this, str3, callable, z3, z, i, j2, str2));
        }
    }
}
