package com.revenuecat.purchases.paywalls.components.common;

import com.revenuecat.purchases.InternalRevenueCatAPI;
import com.revenuecat.purchases.utils.serializers.GoogleListSerializer;
import com.revenuecat.purchases.utils.serializers.URLSerializer;
import g5.a;
import i5.g;
import j5.b;
import java.net.URL;
import java.util.List;
import java.util.Map;
import k5.H;
import k5.P;
import k5.a0;
import k5.e0;
import kotlin.jvm.internal.h;
import kotlin.jvm.internal.o;
import q.AbstractC2761L;
import w4.InterfaceC3141c;
import x4.y;

/* JADX INFO: loaded from: classes3.dex */
@InternalRevenueCatAPI
public final class PaywallComponentsData {
    private final URL assetBaseURL;
    private final ComponentsConfig componentsConfig;
    private final Map<LocaleId, Map<LocalizationKey, LocalizationData>> componentsLocalizations;
    private final String defaultLocaleIdentifier;
    private final ExitOffers exitOffers;
    private final String id;
    private final ProductChangeConfig productChangeConfig;
    private final int revision;
    private final String templateName;
    private final List<String> zeroDecimalPlaceCountries;
    public static final Companion Companion = new Companion(null);
    private static final a[] $childSerializers = {null, null, null, null, new H(LocaleId$$serializer.INSTANCE, new H(LocalizationKey$$serializer.INSTANCE, LocalizationDataSerializer.INSTANCE)), null, null, null, null, null};

    public static final class Companion {
        public /* synthetic */ Companion(h hVar) {
            this();
        }

        public final a serializer() {
            return PaywallComponentsData$$serializer.INSTANCE;
        }

        private Companion() {
        }
    }

    @InterfaceC3141c
    public /* synthetic */ PaywallComponentsData(int i6, String str, String str2, URL url, ComponentsConfig componentsConfig, Map map, String str3, int i7, List list, ExitOffers exitOffers, ProductChangeConfig productChangeConfig, a0 a0Var, h hVar) {
        this(i6, str, str2, url, componentsConfig, (Map<LocaleId, ? extends Map<LocalizationKey, ? extends LocalizationData>>) map, str3, i7, (List<String>) list, exitOffers, productChangeConfig, a0Var);
    }

    public static /* synthetic */ void getAssetBaseURL$annotations() {
    }

    public static /* synthetic */ void getComponentsConfig$annotations() {
    }

    public static /* synthetic */ void getComponentsLocalizations$annotations() {
    }

    /* JADX INFO: renamed from: getDefaultLocaleIdentifier-uqtKvyA$annotations, reason: not valid java name */
    public static /* synthetic */ void m616getDefaultLocaleIdentifieruqtKvyA$annotations() {
    }

    public static /* synthetic */ void getExitOffers$annotations() {
    }

    public static /* synthetic */ void getProductChangeConfig$annotations() {
    }

    public static /* synthetic */ void getTemplateName$annotations() {
    }

    public static /* synthetic */ void getZeroDecimalPlaceCountries$annotations() {
    }

    public static final /* synthetic */ void write$Self$purchases_defaultsBc8Release(PaywallComponentsData paywallComponentsData, b bVar, g gVar) {
        a[] aVarArr = $childSerializers;
        if (bVar.g(gVar) || paywallComponentsData.id != null) {
            bVar.E(gVar, 0, e0.f20048a, paywallComponentsData.id);
        }
        bVar.A(gVar, 1, paywallComponentsData.templateName);
        bVar.z(gVar, 2, URLSerializer.INSTANCE, paywallComponentsData.assetBaseURL);
        bVar.z(gVar, 3, ComponentsConfig$$serializer.INSTANCE, paywallComponentsData.componentsConfig);
        bVar.z(gVar, 4, aVarArr[4], paywallComponentsData.componentsLocalizations);
        bVar.z(gVar, 5, LocaleId$$serializer.INSTANCE, LocaleId.m571boximpl(paywallComponentsData.defaultLocaleIdentifier));
        if (bVar.g(gVar) || paywallComponentsData.revision != 0) {
            bVar.w(6, paywallComponentsData.revision, gVar);
        }
        if (bVar.g(gVar) || !o.c(paywallComponentsData.zeroDecimalPlaceCountries, y.f26065a)) {
            bVar.z(gVar, 7, GoogleListSerializer.INSTANCE, paywallComponentsData.zeroDecimalPlaceCountries);
        }
        if (bVar.g(gVar) || paywallComponentsData.exitOffers != null) {
            bVar.E(gVar, 8, ExitOffers$$serializer.INSTANCE, paywallComponentsData.exitOffers);
        }
        if (!bVar.g(gVar) && paywallComponentsData.productChangeConfig == null) {
            return;
        }
        bVar.E(gVar, 9, ProductChangeConfigSerializer.INSTANCE, paywallComponentsData.productChangeConfig);
    }

    public boolean equals(Object obj) {
        if (this == obj) {
            return true;
        }
        if (!(obj instanceof PaywallComponentsData)) {
            return false;
        }
        PaywallComponentsData paywallComponentsData = (PaywallComponentsData) obj;
        return o.c(this.id, paywallComponentsData.id) && o.c(this.templateName, paywallComponentsData.templateName) && o.c(this.assetBaseURL, paywallComponentsData.assetBaseURL) && o.c(this.componentsConfig, paywallComponentsData.componentsConfig) && o.c(this.componentsLocalizations, paywallComponentsData.componentsLocalizations) && LocaleId.m574equalsimpl0(this.defaultLocaleIdentifier, paywallComponentsData.defaultLocaleIdentifier) && this.revision == paywallComponentsData.revision && o.c(this.zeroDecimalPlaceCountries, paywallComponentsData.zeroDecimalPlaceCountries) && o.c(this.exitOffers, paywallComponentsData.exitOffers) && o.c(this.productChangeConfig, paywallComponentsData.productChangeConfig);
    }

    public final /* synthetic */ URL getAssetBaseURL() {
        return this.assetBaseURL;
    }

    public final /* synthetic */ ComponentsConfig getComponentsConfig() {
        return this.componentsConfig;
    }

    public final /* synthetic */ Map getComponentsLocalizations() {
        return this.componentsLocalizations;
    }

    /* JADX INFO: renamed from: getDefaultLocaleIdentifier-uqtKvyA, reason: not valid java name */
    public final /* synthetic */ String m617getDefaultLocaleIdentifieruqtKvyA() {
        return this.defaultLocaleIdentifier;
    }

    public final /* synthetic */ ExitOffers getExitOffers() {
        return this.exitOffers;
    }

    public final /* synthetic */ String getId() {
        return this.id;
    }

    public final /* synthetic */ ProductChangeConfig getProductChangeConfig() {
        return this.productChangeConfig;
    }

    public final /* synthetic */ int getRevision() {
        return this.revision;
    }

    public final /* synthetic */ String getTemplateName() {
        return this.templateName;
    }

    public final /* synthetic */ List getZeroDecimalPlaceCountries() {
        return this.zeroDecimalPlaceCountries;
    }

    public int hashCode() {
        String str = this.id;
        int iC = AbstractC2761L.c(this.zeroDecimalPlaceCountries, (((LocaleId.m575hashCodeimpl(this.defaultLocaleIdentifier) + A0.a.d(this.componentsLocalizations, (this.componentsConfig.hashCode() + ((this.assetBaseURL.hashCode() + AbstractC2761L.b((str == null ? 0 : str.hashCode()) * 31, 31, this.templateName)) * 31)) * 31, 31)) * 31) + this.revision) * 31, 31);
        ExitOffers exitOffers = this.exitOffers;
        int iHashCode = (iC + (exitOffers == null ? 0 : exitOffers.hashCode())) * 31;
        ProductChangeConfig productChangeConfig = this.productChangeConfig;
        return iHashCode + (productChangeConfig != null ? productChangeConfig.hashCode() : 0);
    }

    public String toString() {
        return "PaywallComponentsData(id=" + this.id + ", templateName=" + this.templateName + ", assetBaseURL=" + this.assetBaseURL + ", componentsConfig=" + this.componentsConfig + ", componentsLocalizations=" + this.componentsLocalizations + ", defaultLocaleIdentifier=" + ((Object) LocaleId.m576toStringimpl(this.defaultLocaleIdentifier)) + ", revision=" + this.revision + ", zeroDecimalPlaceCountries=" + this.zeroDecimalPlaceCountries + ", exitOffers=" + this.exitOffers + ", productChangeConfig=" + this.productChangeConfig + ')';
    }

    public /* synthetic */ PaywallComponentsData(String str, String str2, URL url, ComponentsConfig componentsConfig, Map map, String str3, int i6, List list, ExitOffers exitOffers, ProductChangeConfig productChangeConfig, h hVar) {
        this(str, str2, url, componentsConfig, map, str3, i6, list, exitOffers, productChangeConfig);
    }

    /* JADX WARN: Multi-variable type inference failed */
    private PaywallComponentsData(int i6, String str, String str2, URL url, ComponentsConfig componentsConfig, Map<LocaleId, ? extends Map<LocalizationKey, ? extends LocalizationData>> map, String str3, int i7, List<String> list, ExitOffers exitOffers, ProductChangeConfig productChangeConfig, a0 a0Var) {
        if (62 != (i6 & 62)) {
            P.h(i6, 62, PaywallComponentsData$$serializer.INSTANCE.getDescriptor());
            throw null;
        }
        if ((i6 & 1) == 0) {
            this.id = null;
        } else {
            this.id = str;
        }
        this.templateName = str2;
        this.assetBaseURL = url;
        this.componentsConfig = componentsConfig;
        this.componentsLocalizations = map;
        this.defaultLocaleIdentifier = str3;
        if ((i6 & 64) == 0) {
            this.revision = 0;
        } else {
            this.revision = i7;
        }
        if ((i6 & 128) == 0) {
            this.zeroDecimalPlaceCountries = y.f26065a;
        } else {
            this.zeroDecimalPlaceCountries = list;
        }
        if ((i6 & 256) == 0) {
            this.exitOffers = null;
        } else {
            this.exitOffers = exitOffers;
        }
        if ((i6 & 512) == 0) {
            this.productChangeConfig = null;
        } else {
            this.productChangeConfig = productChangeConfig;
        }
    }

    /* JADX WARN: Multi-variable type inference failed */
    private PaywallComponentsData(String str, String templateName, URL assetBaseURL, ComponentsConfig componentsConfig, Map<LocaleId, ? extends Map<LocalizationKey, ? extends LocalizationData>> componentsLocalizations, String defaultLocaleIdentifier, int i6, List<String> zeroDecimalPlaceCountries, ExitOffers exitOffers, ProductChangeConfig productChangeConfig) {
        o.h(templateName, "templateName");
        o.h(assetBaseURL, "assetBaseURL");
        o.h(componentsConfig, "componentsConfig");
        o.h(componentsLocalizations, "componentsLocalizations");
        o.h(defaultLocaleIdentifier, "defaultLocaleIdentifier");
        o.h(zeroDecimalPlaceCountries, "zeroDecimalPlaceCountries");
        this.id = str;
        this.templateName = templateName;
        this.assetBaseURL = assetBaseURL;
        this.componentsConfig = componentsConfig;
        this.componentsLocalizations = componentsLocalizations;
        this.defaultLocaleIdentifier = defaultLocaleIdentifier;
        this.revision = i6;
        this.zeroDecimalPlaceCountries = zeroDecimalPlaceCountries;
        this.exitOffers = exitOffers;
        this.productChangeConfig = productChangeConfig;
    }

    public /* synthetic */ PaywallComponentsData(String str, String str2, URL url, ComponentsConfig componentsConfig, Map map, String str3, int i6, List list, ExitOffers exitOffers, ProductChangeConfig productChangeConfig, int i7, h hVar) {
        this((i7 & 1) != 0 ? null : str, str2, url, componentsConfig, map, str3, (i7 & 64) != 0 ? 0 : i6, (i7 & 128) != 0 ? y.f26065a : list, (i7 & 256) != 0 ? null : exitOffers, (i7 & 512) != 0 ? null : productChangeConfig, null);
    }
}
