package vf;

import xyz.stream.api.database.entity.EpgEntity;

/* JADX INFO: loaded from: classes3.dex */
public final class d extends androidx.room.h {

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

    public final void a(k3.c cVar, EpgEntity epgEntity) {
        switch (this.f33963a) {
            case 0:
                if (epgEntity.getEpgId() == null) {
                    cVar.d(1);
                } else {
                    cVar.a(1, epgEntity.getEpgId().intValue());
                }
                if (epgEntity.getUniKey() == null) {
                    cVar.d(2);
                } else {
                    cVar.s(2, epgEntity.getUniKey());
                }
                if (epgEntity.getTitle() == null) {
                    cVar.d(3);
                } else {
                    cVar.s(3, epgEntity.getTitle());
                }
                if (epgEntity.getDescription() == null) {
                    cVar.d(4);
                } else {
                    cVar.s(4, epgEntity.getDescription());
                }
                if (epgEntity.getStartTime() == null) {
                    cVar.d(5);
                } else {
                    cVar.s(5, epgEntity.getStartTime());
                }
                if (epgEntity.getEndTime() == null) {
                    cVar.d(6);
                } else {
                    cVar.s(6, epgEntity.getEndTime());
                }
                if (epgEntity.getChannelId() == null) {
                    cVar.d(7);
                } else {
                    cVar.a(7, epgEntity.getChannelId().intValue());
                }
                if (epgEntity.getDate() == null) {
                    cVar.d(8);
                } else {
                    cVar.s(8, epgEntity.getDate());
                }
                if (epgEntity.getLanguage() != null) {
                    cVar.s(9, epgEntity.getLanguage());
                } else {
                    cVar.d(9);
                }
                break;
            default:
                if (epgEntity.getEpgId() == null) {
                    cVar.d(1);
                } else {
                    cVar.a(1, epgEntity.getEpgId().intValue());
                }
                if (epgEntity.getUniKey() == null) {
                    cVar.d(2);
                } else {
                    cVar.s(2, epgEntity.getUniKey());
                }
                if (epgEntity.getTitle() == null) {
                    cVar.d(3);
                } else {
                    cVar.s(3, epgEntity.getTitle());
                }
                if (epgEntity.getDescription() == null) {
                    cVar.d(4);
                } else {
                    cVar.s(4, epgEntity.getDescription());
                }
                if (epgEntity.getStartTime() == null) {
                    cVar.d(5);
                } else {
                    cVar.s(5, epgEntity.getStartTime());
                }
                if (epgEntity.getEndTime() == null) {
                    cVar.d(6);
                } else {
                    cVar.s(6, epgEntity.getEndTime());
                }
                if (epgEntity.getChannelId() == null) {
                    cVar.d(7);
                } else {
                    cVar.a(7, epgEntity.getChannelId().intValue());
                }
                if (epgEntity.getDate() == null) {
                    cVar.d(8);
                } else {
                    cVar.s(8, epgEntity.getDate());
                }
                if (epgEntity.getLanguage() != null) {
                    cVar.s(9, epgEntity.getLanguage());
                } else {
                    cVar.d(9);
                }
                break;
        }
    }

    @Override // androidx.room.h
    public final /* bridge */ /* synthetic */ void bind(k3.c cVar, Object obj) {
        switch (this.f33963a) {
            case 0:
                a(cVar, (EpgEntity) obj);
                break;
            default:
                a(cVar, (EpgEntity) obj);
                break;
        }
    }

    @Override // androidx.room.h
    public final String createQuery() {
        switch (this.f33963a) {
            case 0:
                return "INSERT OR IGNORE INTO `epg_entity` (`epg_id`,`uni_key`,`title`,`description`,`start_time`,`end_time`,`channel_id`,`date`,`language`) VALUES (?,?,?,?,?,?,?,?,?)";
            default:
                return "INSERT OR REPLACE INTO `epg_entity` (`epg_id`,`uni_key`,`title`,`description`,`start_time`,`end_time`,`channel_id`,`date`,`language`) VALUES (?,?,?,?,?,?,?,?,?)";
        }
    }
}
