package xyz.stream.utils;

import java.util.HashMap;

/* JADX INFO: loaded from: classes3.dex */
public final /* synthetic */ class j implements Runnable {

    /* JADX INFO: renamed from: a, reason: collision with root package name */
    public final /* synthetic */ int f36148a;

    /* JADX INFO: renamed from: b, reason: collision with root package name */
    public final /* synthetic */ String f36149b;

    /* JADX INFO: renamed from: c, reason: collision with root package name */
    public final /* synthetic */ int f36150c;

    /* JADX INFO: renamed from: d, reason: collision with root package name */
    public final /* synthetic */ String f36151d;

    public /* synthetic */ j(String str, int i10, String str2, int i11) {
        this.f36148a = i11;
        this.f36149b = str;
        this.f36150c = i10;
        this.f36151d = str2;
    }

    @Override // java.lang.Runnable
    public final void run() {
        int i10 = this.f36148a;
        int i11 = this.f36150c;
        String str = this.f36151d;
        String str2 = this.f36149b;
        switch (i10) {
            case 0:
                try {
                    HashMap map = new HashMap();
                    map.put("start_time", str2);
                    map.put("end_time", kotlinx.coroutines.flow.h.C());
                    map.put("duration", kotlinx.coroutines.flow.h.r(str2, kotlinx.coroutines.flow.h.C()) + ", " + e.d().b() + ", " + i11 + "_" + str);
                    map.put("total_time", Long.valueOf(kotlinx.coroutines.flow.h.s(str2, kotlinx.coroutines.flow.h.C())));
                    map.put("channel_id", Integer.valueOf(i11));
                    map.put("channel_name", str);
                    kotlinx.coroutines.y.R("live_play_finish", map);
                } catch (Exception e10) {
                    h.c(e10.getMessage());
                    return;
                }
                break;
            case 1:
                try {
                    HashMap map2 = new HashMap();
                    map2.put("start_time", str2);
                    map2.put("end_time", kotlinx.coroutines.flow.h.C());
                    map2.put("duration", kotlinx.coroutines.flow.h.r(str2, kotlinx.coroutines.flow.h.C()) + ", " + e.d().b() + ", " + i11 + "_" + str);
                    map2.put("total_time", Long.valueOf(kotlinx.coroutines.flow.h.s(str2, kotlinx.coroutines.flow.h.C())));
                    map2.put("channel_id", Integer.valueOf(i11));
                    map2.put("channel_name", str);
                    kotlinx.coroutines.y.R("live_playing", map2);
                } catch (Exception e11) {
                    h.c(e11.getMessage());
                }
                break;
            default:
                try {
                    HashMap map3 = new HashMap();
                    map3.put("start_time", str2);
                    map3.put("end_time", kotlinx.coroutines.flow.h.C());
                    map3.put("duration", kotlinx.coroutines.flow.h.r(str2, kotlinx.coroutines.flow.h.C()) + ", " + e.d().b() + ", " + str);
                    map3.put("total_time", Long.valueOf(kotlinx.coroutines.flow.h.s(str2, kotlinx.coroutines.flow.h.C())));
                    map3.put("imdb_id", str);
                    map3.put("video_id", Integer.valueOf(i11));
                    kotlinx.coroutines.y.R("vod_play_stuck", map3);
                } catch (Exception e12) {
                    h.c(e12.getMessage());
                    return;
                }
                break;
        }
    }

    public /* synthetic */ j(String str, String str2, int i10) {
        this.f36148a = 2;
        this.f36149b = str;
        this.f36151d = str2;
        this.f36150c = i10;
    }
}
