package xyz.stream.download;

import androidx.annotation.NonNull;
import androidx.room.RoomDatabase;
import androidx.room.h;
import androidx.room.w0;
import java.util.ArrayList;
import java.util.Collections;
import java.util.List;
import sd.l;
import tv.danmaku.ijk.media.player.IjkMediaMeta;
import xyz.stream.download.config.InnerConstant;

/* JADX INFO: loaded from: classes3.dex */
public final class DownloadDao_Impl implements DownloadDao {
    private final RoomDatabase __db;
    private final h __insertAdapterOfDownloadFile = new h() { // from class: xyz.stream.download.DownloadDao_Impl.1
        @Override // androidx.room.h
        @NonNull
        public String createQuery() {
            return "INSERT OR ABORT INTO `download_file` (`id`,`video_id`,`episode_id`,`download_id`,`download_url`,`file_path`,`file_name`,`status`,`source_type`,`progress`,`total_bytes`,`current_bytes`,`backdrop_path`,`episode_pic`,`episode_runtime`,`title`,`duration`,`role_id`,`created_at`) VALUES (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)";
        }

        @Override // androidx.room.h
        public void bind(@NonNull k3.c cVar, DownloadFile downloadFile) {
            if (downloadFile.getId() == null) {
                cVar.d(1);
            } else {
                cVar.a(1, downloadFile.getId().intValue());
            }
            if (downloadFile.getVideoId() == null) {
                cVar.d(2);
            } else {
                cVar.a(2, downloadFile.getVideoId().intValue());
            }
            if (downloadFile.getEpisodeId() == null) {
                cVar.d(3);
            } else {
                cVar.a(3, downloadFile.getEpisodeId().intValue());
            }
            if (downloadFile.getDownloadId() == null) {
                cVar.d(4);
            } else {
                cVar.s(4, downloadFile.getDownloadId());
            }
            if (downloadFile.getDownloadUrl() == null) {
                cVar.d(5);
            } else {
                cVar.s(5, downloadFile.getDownloadUrl());
            }
            if (downloadFile.getFilePath() == null) {
                cVar.d(6);
            } else {
                cVar.s(6, downloadFile.getFilePath());
            }
            if (downloadFile.getFileName() == null) {
                cVar.d(7);
            } else {
                cVar.s(7, downloadFile.getFileName());
            }
            if (downloadFile.getStatus() == null) {
                cVar.d(8);
            } else {
                cVar.a(8, downloadFile.getStatus().intValue());
            }
            if (downloadFile.getSourceType() == null) {
                cVar.d(9);
            } else {
                cVar.a(9, downloadFile.getSourceType().intValue());
            }
            if (downloadFile.getProgress() == null) {
                cVar.d(10);
            } else {
                cVar.a(10, downloadFile.getProgress().intValue());
            }
            if (downloadFile.getTotalBytes() == null) {
                cVar.d(11);
            } else {
                cVar.a(11, downloadFile.getTotalBytes().intValue());
            }
            if (downloadFile.getCurrentBytes() == null) {
                cVar.d(12);
            } else {
                cVar.a(12, downloadFile.getCurrentBytes().intValue());
            }
            if (downloadFile.getBackdropPath() == null) {
                cVar.d(13);
            } else {
                cVar.s(13, downloadFile.getBackdropPath());
            }
            if (downloadFile.getEpisodePic() == null) {
                cVar.d(14);
            } else {
                cVar.s(14, downloadFile.getEpisodePic());
            }
            if (downloadFile.getEpisodeRuntime() == null) {
                cVar.d(15);
            } else {
                cVar.a(15, downloadFile.getEpisodeRuntime().intValue());
            }
            if (downloadFile.getTitle() == null) {
                cVar.d(16);
            } else {
                cVar.s(16, downloadFile.getTitle());
            }
            if (downloadFile.getDuration() == null) {
                cVar.d(17);
            } else {
                cVar.s(17, downloadFile.getDuration());
            }
            if (downloadFile.getRoleId() == null) {
                cVar.d(18);
            } else {
                cVar.s(18, downloadFile.getRoleId());
            }
            if (downloadFile.getCreatedAt() == null) {
                cVar.d(19);
            } else {
                cVar.a(19, downloadFile.getCreatedAt().intValue());
            }
        }
    };
    private final androidx.room.g __deleteAdapterOfDownloadFile = new androidx.room.g() { // from class: xyz.stream.download.DownloadDao_Impl.2
        @Override // androidx.room.g
        @NonNull
        public String createQuery() {
            return "DELETE FROM `download_file` WHERE `id` = ?";
        }

        @Override // androidx.room.g
        public void bind(@NonNull k3.c cVar, DownloadFile downloadFile) {
            if (downloadFile.getId() == null) {
                cVar.d(1);
            } else {
                cVar.a(1, downloadFile.getId().intValue());
            }
        }
    };
    private final androidx.room.g __updateAdapterOfDownloadFile = new androidx.room.g() { // from class: xyz.stream.download.DownloadDao_Impl.3
        @Override // androidx.room.g
        @NonNull
        public String createQuery() {
            return "UPDATE OR REPLACE `download_file` SET `id` = ?,`video_id` = ?,`episode_id` = ?,`download_id` = ?,`download_url` = ?,`file_path` = ?,`file_name` = ?,`status` = ?,`source_type` = ?,`progress` = ?,`total_bytes` = ?,`current_bytes` = ?,`backdrop_path` = ?,`episode_pic` = ?,`episode_runtime` = ?,`title` = ?,`duration` = ?,`role_id` = ?,`created_at` = ? WHERE `id` = ?";
        }

        @Override // androidx.room.g
        public void bind(@NonNull k3.c cVar, DownloadFile downloadFile) {
            if (downloadFile.getId() == null) {
                cVar.d(1);
            } else {
                cVar.a(1, downloadFile.getId().intValue());
            }
            if (downloadFile.getVideoId() == null) {
                cVar.d(2);
            } else {
                cVar.a(2, downloadFile.getVideoId().intValue());
            }
            if (downloadFile.getEpisodeId() == null) {
                cVar.d(3);
            } else {
                cVar.a(3, downloadFile.getEpisodeId().intValue());
            }
            if (downloadFile.getDownloadId() == null) {
                cVar.d(4);
            } else {
                cVar.s(4, downloadFile.getDownloadId());
            }
            if (downloadFile.getDownloadUrl() == null) {
                cVar.d(5);
            } else {
                cVar.s(5, downloadFile.getDownloadUrl());
            }
            if (downloadFile.getFilePath() == null) {
                cVar.d(6);
            } else {
                cVar.s(6, downloadFile.getFilePath());
            }
            if (downloadFile.getFileName() == null) {
                cVar.d(7);
            } else {
                cVar.s(7, downloadFile.getFileName());
            }
            if (downloadFile.getStatus() == null) {
                cVar.d(8);
            } else {
                cVar.a(8, downloadFile.getStatus().intValue());
            }
            if (downloadFile.getSourceType() == null) {
                cVar.d(9);
            } else {
                cVar.a(9, downloadFile.getSourceType().intValue());
            }
            if (downloadFile.getProgress() == null) {
                cVar.d(10);
            } else {
                cVar.a(10, downloadFile.getProgress().intValue());
            }
            if (downloadFile.getTotalBytes() == null) {
                cVar.d(11);
            } else {
                cVar.a(11, downloadFile.getTotalBytes().intValue());
            }
            if (downloadFile.getCurrentBytes() == null) {
                cVar.d(12);
            } else {
                cVar.a(12, downloadFile.getCurrentBytes().intValue());
            }
            if (downloadFile.getBackdropPath() == null) {
                cVar.d(13);
            } else {
                cVar.s(13, downloadFile.getBackdropPath());
            }
            if (downloadFile.getEpisodePic() == null) {
                cVar.d(14);
            } else {
                cVar.s(14, downloadFile.getEpisodePic());
            }
            if (downloadFile.getEpisodeRuntime() == null) {
                cVar.d(15);
            } else {
                cVar.a(15, downloadFile.getEpisodeRuntime().intValue());
            }
            if (downloadFile.getTitle() == null) {
                cVar.d(16);
            } else {
                cVar.s(16, downloadFile.getTitle());
            }
            if (downloadFile.getDuration() == null) {
                cVar.d(17);
            } else {
                cVar.s(17, downloadFile.getDuration());
            }
            if (downloadFile.getRoleId() == null) {
                cVar.d(18);
            } else {
                cVar.s(18, downloadFile.getRoleId());
            }
            if (downloadFile.getCreatedAt() == null) {
                cVar.d(19);
            } else {
                cVar.a(19, downloadFile.getCreatedAt().intValue());
            }
            if (downloadFile.getId() == null) {
                cVar.d(20);
            } else {
                cVar.a(20, downloadFile.getId().intValue());
            }
        }
    };

    public DownloadDao_Impl(@NonNull RoomDatabase roomDatabase) {
        this.__db = roomDatabase;
    }

    @NonNull
    public static List<Class<?>> getRequiredConverters() {
        return Collections.emptyList();
    }

    /* JADX INFO: Access modifiers changed from: private */
    public /* synthetic */ Object lambda$deleteDownloadTask$1(DownloadFile downloadFile, k3.a aVar) {
        this.__deleteAdapterOfDownloadFile.handle(aVar, downloadFile);
        return null;
    }

    /* JADX INFO: Access modifiers changed from: private */
    public static /* synthetic */ Object lambda$deleteDownloadTaskByDownloadId$6(int i10, k3.a aVar) throws Exception {
        k3.c cVarJ = aVar.J("DELETE FROM download_file WHERE download_id = ?");
        try {
            cVarJ.a(1, i10);
            cVarJ.G();
            cVarJ.close();
            return null;
        } catch (Throwable th) {
            cVarJ.close();
            throw th;
        }
    }

    /* JADX INFO: Access modifiers changed from: private */
    public static /* synthetic */ List lambda$getAllDownloadTask$3(k3.a aVar) throws Exception {
        int i10;
        ArrayList arrayList;
        Integer numValueOf;
        String strA;
        String strA2;
        int i11;
        int i12;
        int i13;
        Integer numValueOf2;
        int i14;
        String strA3;
        int i15;
        String strA4;
        int i16;
        int i17;
        String strA5;
        int i18;
        int i19;
        int i20;
        k3.c cVarJ = aVar.J("SELECT * FROM download_file");
        try {
            int iC = androidx.room.util.f.c(cVarJ, InnerConstant.Db.f36069id);
            int iC2 = androidx.room.util.f.c(cVarJ, "video_id");
            int iC3 = androidx.room.util.f.c(cVarJ, "episode_id");
            int iC4 = androidx.room.util.f.c(cVarJ, "download_id");
            int iC5 = androidx.room.util.f.c(cVarJ, "download_url");
            int iC6 = androidx.room.util.f.c(cVarJ, "file_path");
            int iC7 = androidx.room.util.f.c(cVarJ, "file_name");
            int iC8 = androidx.room.util.f.c(cVarJ, "status");
            int iC9 = androidx.room.util.f.c(cVarJ, "source_type");
            int iC10 = androidx.room.util.f.c(cVarJ, "progress");
            int iC11 = androidx.room.util.f.c(cVarJ, "total_bytes");
            int iC12 = androidx.room.util.f.c(cVarJ, "current_bytes");
            int iC13 = androidx.room.util.f.c(cVarJ, "backdrop_path");
            int iC14 = androidx.room.util.f.c(cVarJ, "episode_pic");
            int iC15 = androidx.room.util.f.c(cVarJ, "episode_runtime");
            int iC16 = androidx.room.util.f.c(cVarJ, IjkMediaMeta.IJKM_KEY_TITLE);
            int iC17 = androidx.room.util.f.c(cVarJ, "duration");
            int iC18 = androidx.room.util.f.c(cVarJ, "role_id");
            int iC19 = androidx.room.util.f.c(cVarJ, "created_at");
            ArrayList arrayList2 = new ArrayList();
            while (cVarJ.G()) {
                Integer numValueOf3 = null;
                if (cVarJ.isNull(iC)) {
                    i10 = iC14;
                    arrayList = arrayList2;
                    numValueOf = null;
                } else {
                    i10 = iC14;
                    arrayList = arrayList2;
                    numValueOf = Integer.valueOf((int) cVarJ.getLong(iC));
                }
                Integer numValueOf4 = cVarJ.isNull(iC2) ? null : Integer.valueOf((int) cVarJ.getLong(iC2));
                Integer numValueOf5 = cVarJ.isNull(iC3) ? null : Integer.valueOf((int) cVarJ.getLong(iC3));
                String strA6 = cVarJ.isNull(iC4) ? null : cVarJ.A(iC4);
                String strA7 = cVarJ.isNull(iC5) ? null : cVarJ.A(iC5);
                String strA8 = cVarJ.isNull(iC6) ? null : cVarJ.A(iC6);
                String strA9 = cVarJ.isNull(iC7) ? null : cVarJ.A(iC7);
                Integer numValueOf6 = cVarJ.isNull(iC8) ? null : Integer.valueOf((int) cVarJ.getLong(iC8));
                Integer numValueOf7 = cVarJ.isNull(iC9) ? null : Integer.valueOf((int) cVarJ.getLong(iC9));
                Integer numValueOf8 = cVarJ.isNull(iC10) ? null : Integer.valueOf((int) cVarJ.getLong(iC10));
                Integer numValueOf9 = cVarJ.isNull(iC11) ? null : Integer.valueOf((int) cVarJ.getLong(iC11));
                Integer numValueOf10 = cVarJ.isNull(iC12) ? null : Integer.valueOf((int) cVarJ.getLong(iC12));
                if (cVarJ.isNull(iC13)) {
                    iC14 = i10;
                    strA = null;
                } else {
                    strA = cVarJ.A(iC13);
                    iC14 = i10;
                }
                if (cVarJ.isNull(iC14)) {
                    i11 = iC15;
                    strA2 = null;
                } else {
                    strA2 = cVarJ.A(iC14);
                    i11 = iC15;
                }
                if (cVarJ.isNull(i11)) {
                    i12 = iC2;
                    i13 = iC3;
                    i14 = iC16;
                    numValueOf2 = null;
                } else {
                    i12 = iC2;
                    i13 = iC3;
                    numValueOf2 = Integer.valueOf((int) cVarJ.getLong(i11));
                    i14 = iC16;
                }
                if (cVarJ.isNull(i14)) {
                    i15 = iC17;
                    strA3 = null;
                } else {
                    strA3 = cVarJ.A(i14);
                    i15 = iC17;
                }
                if (cVarJ.isNull(i15)) {
                    i16 = iC;
                    i17 = iC18;
                    strA4 = null;
                } else {
                    strA4 = cVarJ.A(i15);
                    i16 = iC;
                    i17 = iC18;
                }
                if (cVarJ.isNull(i17)) {
                    iC18 = i17;
                    i18 = iC19;
                    strA5 = null;
                } else {
                    iC18 = i17;
                    strA5 = cVarJ.A(i17);
                    i18 = iC19;
                }
                if (cVarJ.isNull(i18)) {
                    i19 = i14;
                    i20 = i15;
                } else {
                    i19 = i14;
                    i20 = i15;
                    numValueOf3 = Integer.valueOf((int) cVarJ.getLong(i18));
                }
                ArrayList arrayList3 = arrayList;
                arrayList3.add(new DownloadFile(numValueOf, numValueOf4, numValueOf5, strA6, strA7, strA8, strA9, numValueOf6, numValueOf7, numValueOf8, numValueOf9, numValueOf10, strA, strA2, numValueOf2, strA3, strA4, numValueOf3, strA5));
                iC2 = i12;
                iC15 = i11;
                arrayList2 = arrayList3;
                iC3 = i13;
                int i21 = i20;
                iC19 = i18;
                iC = i16;
                iC16 = i19;
                iC17 = i21;
            }
            return arrayList2;
        } finally {
            cVarJ.close();
        }
    }

    /* JADX INFO: Access modifiers changed from: private */
    public static /* synthetic */ DownloadFile lambda$getDownloadTaskByUrl$5(String str, k3.a aVar) throws Exception {
        int i10;
        int i11;
        Integer numValueOf;
        String strA;
        int i12;
        String strA2;
        int i13;
        Integer numValueOf2;
        int i14;
        String strA3;
        int i15;
        String strA4;
        int i16;
        k3.c cVarJ = aVar.J("SELECT * FROM download_file WHERE download_url = ?");
        try {
            if (str == null) {
                cVarJ.d(1);
            } else {
                cVarJ.s(1, str);
            }
            int iC = androidx.room.util.f.c(cVarJ, InnerConstant.Db.f36069id);
            int iC2 = androidx.room.util.f.c(cVarJ, "video_id");
            int iC3 = androidx.room.util.f.c(cVarJ, "episode_id");
            int iC4 = androidx.room.util.f.c(cVarJ, "download_id");
            int iC5 = androidx.room.util.f.c(cVarJ, "download_url");
            int iC6 = androidx.room.util.f.c(cVarJ, "file_path");
            int iC7 = androidx.room.util.f.c(cVarJ, "file_name");
            int iC8 = androidx.room.util.f.c(cVarJ, "status");
            int iC9 = androidx.room.util.f.c(cVarJ, "source_type");
            int iC10 = androidx.room.util.f.c(cVarJ, "progress");
            int iC11 = androidx.room.util.f.c(cVarJ, "total_bytes");
            int iC12 = androidx.room.util.f.c(cVarJ, "current_bytes");
            int iC13 = androidx.room.util.f.c(cVarJ, "backdrop_path");
            int iC14 = androidx.room.util.f.c(cVarJ, "episode_pic");
            int iC15 = androidx.room.util.f.c(cVarJ, "episode_runtime");
            int iC16 = androidx.room.util.f.c(cVarJ, IjkMediaMeta.IJKM_KEY_TITLE);
            int iC17 = androidx.room.util.f.c(cVarJ, "duration");
            int iC18 = androidx.room.util.f.c(cVarJ, "role_id");
            int iC19 = androidx.room.util.f.c(cVarJ, "created_at");
            DownloadFile downloadFile = null;
            if (cVarJ.G()) {
                if (cVarJ.isNull(iC)) {
                    i10 = iC14;
                    i11 = iC19;
                    numValueOf = null;
                } else {
                    i10 = iC14;
                    i11 = iC19;
                    numValueOf = Integer.valueOf((int) cVarJ.getLong(iC));
                }
                Integer numValueOf3 = cVarJ.isNull(iC2) ? null : Integer.valueOf((int) cVarJ.getLong(iC2));
                Integer numValueOf4 = cVarJ.isNull(iC3) ? null : Integer.valueOf((int) cVarJ.getLong(iC3));
                String strA5 = cVarJ.isNull(iC4) ? null : cVarJ.A(iC4);
                String strA6 = cVarJ.isNull(iC5) ? null : cVarJ.A(iC5);
                String strA7 = cVarJ.isNull(iC6) ? null : cVarJ.A(iC6);
                String strA8 = cVarJ.isNull(iC7) ? null : cVarJ.A(iC7);
                Integer numValueOf5 = cVarJ.isNull(iC8) ? null : Integer.valueOf((int) cVarJ.getLong(iC8));
                Integer numValueOf6 = cVarJ.isNull(iC9) ? null : Integer.valueOf((int) cVarJ.getLong(iC9));
                Integer numValueOf7 = cVarJ.isNull(iC10) ? null : Integer.valueOf((int) cVarJ.getLong(iC10));
                Integer numValueOf8 = cVarJ.isNull(iC11) ? null : Integer.valueOf((int) cVarJ.getLong(iC11));
                Integer numValueOf9 = cVarJ.isNull(iC12) ? null : Integer.valueOf((int) cVarJ.getLong(iC12));
                if (cVarJ.isNull(iC13)) {
                    i12 = i10;
                    strA = null;
                } else {
                    strA = cVarJ.A(iC13);
                    i12 = i10;
                }
                if (cVarJ.isNull(i12)) {
                    i13 = iC15;
                    strA2 = null;
                } else {
                    strA2 = cVarJ.A(i12);
                    i13 = iC15;
                }
                if (cVarJ.isNull(i13)) {
                    i14 = iC16;
                    numValueOf2 = null;
                } else {
                    numValueOf2 = Integer.valueOf((int) cVarJ.getLong(i13));
                    i14 = iC16;
                }
                if (cVarJ.isNull(i14)) {
                    i15 = iC17;
                    strA3 = null;
                } else {
                    strA3 = cVarJ.A(i14);
                    i15 = iC17;
                }
                if (cVarJ.isNull(i15)) {
                    i16 = iC18;
                    strA4 = null;
                } else {
                    strA4 = cVarJ.A(i15);
                    i16 = iC18;
                }
                String strA9 = cVarJ.isNull(i16) ? null : cVarJ.A(i16);
                int i17 = i11;
                downloadFile = new DownloadFile(numValueOf, numValueOf3, numValueOf4, strA5, strA6, strA7, strA8, numValueOf5, numValueOf6, numValueOf7, numValueOf8, numValueOf9, strA, strA2, numValueOf2, strA3, strA4, cVarJ.isNull(i17) ? null : Integer.valueOf((int) cVarJ.getLong(i17)), strA9);
            }
            cVarJ.close();
            return downloadFile;
        } catch (Throwable th) {
            cVarJ.close();
            throw th;
        }
    }

    /* JADX INFO: Access modifiers changed from: private */
    public static /* synthetic */ DownloadFile lambda$getDownloadTaskByVideoId$4(int i10, k3.a aVar) throws Exception {
        int i11;
        int i12;
        Integer numValueOf;
        String strA;
        int i13;
        String strA2;
        int i14;
        Integer numValueOf2;
        int i15;
        String strA3;
        int i16;
        String strA4;
        int i17;
        k3.c cVarJ = aVar.J("SELECT * FROM download_file WHERE video_id = ?");
        try {
            cVarJ.a(1, i10);
            int iC = androidx.room.util.f.c(cVarJ, InnerConstant.Db.f36069id);
            int iC2 = androidx.room.util.f.c(cVarJ, "video_id");
            int iC3 = androidx.room.util.f.c(cVarJ, "episode_id");
            int iC4 = androidx.room.util.f.c(cVarJ, "download_id");
            int iC5 = androidx.room.util.f.c(cVarJ, "download_url");
            int iC6 = androidx.room.util.f.c(cVarJ, "file_path");
            int iC7 = androidx.room.util.f.c(cVarJ, "file_name");
            int iC8 = androidx.room.util.f.c(cVarJ, "status");
            int iC9 = androidx.room.util.f.c(cVarJ, "source_type");
            int iC10 = androidx.room.util.f.c(cVarJ, "progress");
            int iC11 = androidx.room.util.f.c(cVarJ, "total_bytes");
            int iC12 = androidx.room.util.f.c(cVarJ, "current_bytes");
            int iC13 = androidx.room.util.f.c(cVarJ, "backdrop_path");
            int iC14 = androidx.room.util.f.c(cVarJ, "episode_pic");
            int iC15 = androidx.room.util.f.c(cVarJ, "episode_runtime");
            int iC16 = androidx.room.util.f.c(cVarJ, IjkMediaMeta.IJKM_KEY_TITLE);
            int iC17 = androidx.room.util.f.c(cVarJ, "duration");
            int iC18 = androidx.room.util.f.c(cVarJ, "role_id");
            int iC19 = androidx.room.util.f.c(cVarJ, "created_at");
            DownloadFile downloadFile = null;
            if (cVarJ.G()) {
                if (cVarJ.isNull(iC)) {
                    i11 = iC14;
                    i12 = iC19;
                    numValueOf = null;
                } else {
                    i11 = iC14;
                    i12 = iC19;
                    numValueOf = Integer.valueOf((int) cVarJ.getLong(iC));
                }
                Integer numValueOf3 = cVarJ.isNull(iC2) ? null : Integer.valueOf((int) cVarJ.getLong(iC2));
                Integer numValueOf4 = cVarJ.isNull(iC3) ? null : Integer.valueOf((int) cVarJ.getLong(iC3));
                String strA5 = cVarJ.isNull(iC4) ? null : cVarJ.A(iC4);
                String strA6 = cVarJ.isNull(iC5) ? null : cVarJ.A(iC5);
                String strA7 = cVarJ.isNull(iC6) ? null : cVarJ.A(iC6);
                String strA8 = cVarJ.isNull(iC7) ? null : cVarJ.A(iC7);
                Integer numValueOf5 = cVarJ.isNull(iC8) ? null : Integer.valueOf((int) cVarJ.getLong(iC8));
                Integer numValueOf6 = cVarJ.isNull(iC9) ? null : Integer.valueOf((int) cVarJ.getLong(iC9));
                Integer numValueOf7 = cVarJ.isNull(iC10) ? null : Integer.valueOf((int) cVarJ.getLong(iC10));
                Integer numValueOf8 = cVarJ.isNull(iC11) ? null : Integer.valueOf((int) cVarJ.getLong(iC11));
                Integer numValueOf9 = cVarJ.isNull(iC12) ? null : Integer.valueOf((int) cVarJ.getLong(iC12));
                if (cVarJ.isNull(iC13)) {
                    i13 = i11;
                    strA = null;
                } else {
                    strA = cVarJ.A(iC13);
                    i13 = i11;
                }
                if (cVarJ.isNull(i13)) {
                    i14 = iC15;
                    strA2 = null;
                } else {
                    strA2 = cVarJ.A(i13);
                    i14 = iC15;
                }
                if (cVarJ.isNull(i14)) {
                    i15 = iC16;
                    numValueOf2 = null;
                } else {
                    numValueOf2 = Integer.valueOf((int) cVarJ.getLong(i14));
                    i15 = iC16;
                }
                if (cVarJ.isNull(i15)) {
                    i16 = iC17;
                    strA3 = null;
                } else {
                    strA3 = cVarJ.A(i15);
                    i16 = iC17;
                }
                if (cVarJ.isNull(i16)) {
                    i17 = iC18;
                    strA4 = null;
                } else {
                    strA4 = cVarJ.A(i16);
                    i17 = iC18;
                }
                String strA9 = cVarJ.isNull(i17) ? null : cVarJ.A(i17);
                int i18 = i12;
                downloadFile = new DownloadFile(numValueOf, numValueOf3, numValueOf4, strA5, strA6, strA7, strA8, numValueOf5, numValueOf6, numValueOf7, numValueOf8, numValueOf9, strA, strA2, numValueOf2, strA3, strA4, cVarJ.isNull(i18) ? null : Integer.valueOf((int) cVarJ.getLong(i18)), strA9);
            }
            return downloadFile;
        } finally {
            cVarJ.close();
        }
    }

    /* JADX INFO: Access modifiers changed from: private */
    public /* synthetic */ Object lambda$insertDownloadTask$0(DownloadFile downloadFile, k3.a aVar) {
        this.__insertAdapterOfDownloadFile.insert(aVar, downloadFile);
        return null;
    }

    /* JADX INFO: Access modifiers changed from: private */
    public /* synthetic */ Object lambda$updateDownloadTask$2(DownloadFile downloadFile, k3.a aVar) {
        this.__updateAdapterOfDownloadFile.handle(aVar, downloadFile);
        return null;
    }

    @Override // xyz.stream.download.DownloadDao
    public void deleteDownloadTask(DownloadFile downloadFile) {
        androidx.room.util.b.b(this.__db, false, true, new a(this, downloadFile, 1));
    }

    @Override // xyz.stream.download.DownloadDao
    public void deleteDownloadTaskByDownloadId(int i10) {
        androidx.room.util.b.b(this.__db, false, true, new h3.d(i10, 8));
    }

    @Override // xyz.stream.download.DownloadDao
    public List<DownloadFile> getAllDownloadTask() {
        return (List) androidx.room.util.b.b(this.__db, true, false, new w0(9));
    }

    @Override // xyz.stream.download.DownloadDao
    public DownloadFile getDownloadTaskByUrl(final String str) {
        return (DownloadFile) androidx.room.util.b.b(this.__db, true, false, new l() { // from class: xyz.stream.download.b
            @Override // sd.l
            public final Object invoke(Object obj) {
                return DownloadDao_Impl.lambda$getDownloadTaskByUrl$5(str, (k3.a) obj);
            }
        });
    }

    @Override // xyz.stream.download.DownloadDao
    public DownloadFile getDownloadTaskByVideoId(int i10) {
        return (DownloadFile) androidx.room.util.b.b(this.__db, true, false, new h3.d(i10, 7));
    }

    @Override // xyz.stream.download.DownloadDao
    public void insertDownloadTask(DownloadFile downloadFile) {
        androidx.room.util.b.b(this.__db, false, true, new a(this, downloadFile, 2));
    }

    @Override // xyz.stream.download.DownloadDao
    public void updateDownloadTask(DownloadFile downloadFile) {
        androidx.room.util.b.b(this.__db, false, true, new a(this, downloadFile, 0));
    }
}
