正在查看: Cantique de Louanges v12 应用的 MetaData.java JAVA 源代码文件
本页面展示 JAVA 反编译生成的源代码文件,支持语法高亮显示。 仅供安全研究与技术分析使用,严禁用于任何非法用途。请遵守相关法律法规。
正在查看: Cantique de Louanges v12 应用的 MetaData.java JAVA 源代码文件
本页面展示 JAVA 反编译生成的源代码文件,支持语法高亮显示。 仅供安全研究与技术分析使用,严禁用于任何非法用途。请遵守相关法律法规。
package com.startapp.sdk.adsbase.remoteconfig;
import android.content.Context;
import android.os.Build;
import android.os.Handler;
import android.os.Looper;
import androidx.annotation.Nullable;
import com.mbridge.msdk.playercommon.exoplayer2.extractor.ts.PsExtractor;
import com.startapp.json.TypeInfo;
import com.startapp.sdk.ads.external.config.ExternalAdConfig;
import com.startapp.sdk.ads.external.config.ExternalConfig;
import com.startapp.sdk.adsbase.b;
import com.startapp.sdk.adsbase.consent.ConsentConfig;
import com.startapp.sdk.adsbase.crashreport.ANRRemoteConfig;
import com.startapp.sdk.adsbase.model.AdPreferences;
import com.startapp.sdk.components.a;
import com.startapp.sdk.insight.NetworkTestsMetaData;
import com.startapp.sdk.internal.gj;
import com.startapp.sdk.internal.jg;
import com.startapp.sdk.internal.k0;
import com.startapp.sdk.internal.k2;
import com.startapp.sdk.internal.k8;
import com.startapp.sdk.internal.kg;
import com.startapp.sdk.internal.o2;
import com.startapp.sdk.internal.o9;
import com.startapp.sdk.internal.oc;
import com.startapp.sdk.internal.p7;
import com.startapp.sdk.internal.p9;
import com.startapp.sdk.internal.pc;
import com.startapp.sdk.internal.qc;
import com.startapp.sdk.internal.rc;
import com.startapp.sdk.internal.s0;
import com.startapp.sdk.internal.t7;
import com.startapp.sdk.internal.u6;
import com.startapp.sdk.sensors.SensorsData;
import com.startapp.sdk.triggeredlinks.TriggeredLinksMetadata;
import com.unity3d.services.core.network.model.HttpRequest;
import java.io.Serializable;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Collections;
import java.util.HashSet;
import java.util.Iterator;
import java.util.List;
import java.util.Objects;
import java.util.Set;
import java.util.WeakHashMap;
import java.util.concurrent.TimeUnit;
import java.util.concurrent.atomic.AtomicBoolean;
import java.util.concurrent.atomic.AtomicInteger;
public class MetaData implements Serializable {
private static final Object d = new Object();
private static final AtomicBoolean e = new AtomicBoolean();
public static final HashSet f = new HashSet(Collections.singletonList(u6.a));
public static final List g = Arrays.asList("https://adsmetadata.startappservice.com/adsmetadata/api/v1.0/", "https://adsmetadata.mobileadexchange.net/adsmetadata/api/v1.0/", "https://d26xw8rp6mlgfg.cloudfront.net/adsmetadata/api/v1.0/");
public static final String h = "https://req.startappservice.com/1.5/";
public static final int[] i = {60, 60, PsExtractor.VIDEO_STREAM_MASK};
public static final HashSet j = new HashSet(Arrays.asList("com.facebook.katana", "com.yandex.browser"));
private static volatile MetaData k = new MetaData();
private static final AtomicInteger l = new AtomicInteger();
private static final long serialVersionUID = 7698297240206657153L;
private long IABDisplayImpressionDelayInSeconds;
private long IABVideoImpressionDelayInSeconds;
private boolean SupportIABViewability;
private transient boolean a;
@Nullable
private String adClickURL;
@Nullable
@TypeInfo(complex = true, name = "debug")
private AdDebuggerMetadata adDebugger;
private String adPlatformBannerHostSecured;
@Nullable
private String adPlatformHostSecured;
private String adPlatformNativeHostSecured;
private String adPlatformOverlayHostSecured;
private boolean adsPreCachingEnabled;
@Nullable
@TypeInfo(complex = true)
private AdvertisingIdResolverMetadata air;
private boolean alwaysSendToken;
@Nullable
@TypeInfo(complex = true)
private AnalyticsConfig analytics;
@Nullable
@TypeInfo(complex = true)
private ANRRemoteConfig anrConfig;
@Nullable
@TypeInfo(complex = true)
private AppSessionConfig appSession;
private String assetsBaseUrlSecured;
private transient boolean b;
@TypeInfo(complex = true)
private BluetoothConfig btConfig;
private transient List c;
@Nullable
private String calcProd;
private boolean chromeCustomeTabsExternal;
private boolean chromeCustomeTabsInternal;
private boolean closeAdAfterClick;
private boolean compressionEnabled;
@Nullable
@TypeInfo(complex = true)
private ConnectivityHelperMetadata connectivity;
@Nullable
@TypeInfo(complex = true)
private ConsentConfig consentDetails;
private boolean disableSendAdvertisingId;
private boolean dns;
@Nullable
@TypeInfo(complex = true)
private ExternalConfig external;
private double flh;
@Nullable
@TypeInfo(complex = true)
private ComponentInfoEventConfig httpClientInfoEvents;
private double httpPost;
@Nullable
private String impressionURL;
@Nullable
@TypeInfo(complex = true)
private ImpressionsTrackingMetadata impressionsTracking;
private boolean inAppBrowser;
@TypeInfo(type = HashSet.class)
private Set<String> installersList;
private boolean isToken1Mandatory;
@Nullable
private String lastVersion;
@Nullable
@TypeInfo(complex = true)
private LocationMetadata location;
private String metadataUpdateVersion;
@Nullable
@TypeInfo(complex = true)
private MotionMetadata motion;
@Nullable
@TypeInfo(complex = true)
private MraidMetadata mraid;
@Nullable
@TypeInfo(complex = true)
private NetworkDiagnosticConfig netDiag;
@TypeInfo(complex = true)
private NetworkTestsMetaData networkTests;
private int notVisibleBannerReloadInterval;
private boolean omSdkEnabled;
private int[] periodicEventIntMin;
private int[] periodicForegroundEventSec;
private boolean periodicInfoEventEnabled;
private boolean periodicMetaDataEnabled;
private int periodicMetaDataIntervalInMinutes;
@TypeInfo(type = HashSet.class)
private Set<String> preInstalledPackages;
private String profileId;
@Nullable
@TypeInfo(complex = true)
private RcdMetadata rcd;
@Nullable
@TypeInfo(complex = true)
private RscMetadata rsc;
@TypeInfo(complex = true)
private SensorsConfig sensorsConfig;
@Nullable
@TypeInfo(complex = true)
private SensorsData sensorsData;
private int sessionMaxBackgroundTime;
private boolean simpleToken2;
@Nullable
@TypeInfo(complex = true)
private StaleDcConfig staleDc;
private int stopAutoLoadAmount;
private int stopAutoLoadPreCacheAmount;
@Nullable
@TypeInfo(complex = true)
private TelephonyMetadata telephony;
@Nullable
@TypeInfo(complex = true)
private TopicsClientMetadata topics;
@Nullable
private String trackDownloadHost;
@Nullable
@TypeInfo(complex = true)
private TriggeredLinksMetadata triggeredLinks;
private boolean trueNetEnabled;
@Nullable
private String vastRecorderHost;
@Nullable
@TypeInfo(complex = true, name = "wvf")
private WvfMetadata webViewFactory;
private boolean webViewSecured;
@TypeInfo(complex = true)
private SimpleTokenConfig SimpleToken = new SimpleTokenConfig();
@Nullable
@TypeInfo(type = ArrayList.class)
private List<String> metaDataHosts = g;
public MetaData() {
String str = h;
this.adPlatformHostSecured = str;
this.trackDownloadHost = str;
this.sessionMaxBackgroundTime = 1800;
this.profileId = null;
this.installersList = f;
this.preInstalledPackages = j;
this.simpleToken2 = true;
this.alwaysSendToken = true;
this.isToken1Mandatory = true;
this.compressionEnabled = false;
this.periodicMetaDataEnabled = false;
this.periodicMetaDataIntervalInMinutes = 360;
this.periodicInfoEventEnabled = false;
this.periodicEventIntMin = i;
this.inAppBrowser = true;
this.SupportIABViewability = true;
this.IABDisplayImpressionDelayInSeconds = 1L;
this.IABVideoImpressionDelayInSeconds = 2L;
this.sensorsConfig = new SensorsConfig();
this.btConfig = new BluetoothConfig();
this.assetsBaseUrlSecured = "";
this.notVisibleBannerReloadInterval = 3600;
this.analytics = new AnalyticsConfig();
this.a = false;
this.b = false;
this.c = new ArrayList();
this.metadataUpdateVersion = "5.1.0";
this.dns = false;
this.stopAutoLoadAmount = 3;
this.stopAutoLoadPreCacheAmount = 3;
this.trueNetEnabled = false;
this.webViewSecured = true;
this.omSdkEnabled = false;
this.chromeCustomeTabsInternal = true;
this.chromeCustomeTabsExternal = true;
this.disableSendAdvertisingId = false;
this.networkTests = new NetworkTestsMetaData();
this.staleDc = new StaleDcConfig();
this.telephony = new TelephonyMetadata();
this.anrConfig = new ANRRemoteConfig();
this.impressionsTracking = null;
this.connectivity = new ConnectivityHelperMetadata();
this.appSession = new AppSessionConfig();
this.topics = null;
this.mraid = null;
}
public static MetaData C() {
return k;
}
public static Object F() {
return d;
}
private static void a(MetaData metaData) {
synchronized (d) {
metaData.c.addAll(k.c);
k = metaData;
}
}
public static void c(Context context) {
if (e.getAndSet(true)) {
return;
}
MetaData metaData = (MetaData) p7.c(context, "StartappMetadata");
MetaData metaData2 = new MetaData();
if (metaData != null) {
boolean a = gj.a((Serializable) metaData, (Serializable) metaData2);
if (!(true ^ "5.1.0".equals(metaData.metadataUpdateVersion)) && a) {
o9 o9Var = new o9(p9.e);
o9Var.d = "metadata_null";
o9Var.a();
}
metaData.a = false;
metaData.b = false;
metaData.c = new ArrayList();
a(metaData);
} else {
a(metaData2);
}
k.a();
}
public final ImpressionsTrackingMetadata A() {
return this.impressionsTracking;
}
public final Set B() {
return this.installersList;
}
public final String D() {
return this.lastVersion;
}
public final LocationMetadata E() {
return this.location;
}
public final List G() {
List<String> list = this.metaDataHosts;
if (list == null || list.isEmpty()) {
list = g;
}
return Collections.unmodifiableList(list);
}
public final MotionMetadata H() {
return this.motion;
}
public final MraidMetadata I() {
return this.mraid;
}
public final NetworkDiagnosticConfig J() {
return this.netDiag;
}
public final NetworkTestsMetaData K() {
return this.networkTests;
}
public final int L() {
return this.notVisibleBannerReloadInterval;
}
public final int M() {
return this.periodicMetaDataIntervalInMinutes;
}
public final Set N() {
Set set = this.preInstalledPackages;
if (set == null) {
set = j;
}
return Collections.unmodifiableSet(set);
}
public final String O() {
return this.profileId;
}
public final RcdMetadata P() {
return this.rcd;
}
public final RscMetadata Q() {
return this.rsc;
}
public final SensorsConfig R() {
return this.sensorsConfig;
}
public final SensorsData S() {
return this.sensorsData;
}
public final long T() {
return TimeUnit.SECONDS.toMillis(this.sessionMaxBackgroundTime);
}
public final SimpleTokenConfig U() {
return this.SimpleToken;
}
public final StaleDcConfig V() {
return this.staleDc;
}
public final int W() {
return this.stopAutoLoadAmount;
}
public final int X() {
return this.stopAutoLoadPreCacheAmount;
}
public final TelephonyMetadata Y() {
return this.telephony;
}
public final TopicsClientMetadata Z() {
return this.topics;
}
public final String a0() {
String str = this.trackDownloadHost;
return str != null ? str : e();
}
public final int b(Context context) {
return a(context, this.periodicEventIntMin);
}
public final String b0() {
return this.vastRecorderHost;
}
public final WvfMetadata c0() {
return this.webViewFactory;
}
public final AdDebuggerMetadata d() {
return this.adDebugger;
}
public final boolean d0() {
return this.adsPreCachingEnabled;
}
public final String e() {
String str = this.adPlatformHostSecured;
return str != null ? str : h;
}
public final boolean e0() {
return this.alwaysSendToken;
}
public final boolean equals(Object obj) {
if (this == obj) {
return true;
}
if (obj == null || getClass() != obj.getClass()) {
return false;
}
MetaData metaData = (MetaData) obj;
return this.sessionMaxBackgroundTime == metaData.sessionMaxBackgroundTime && this.simpleToken2 == metaData.simpleToken2 && this.alwaysSendToken == metaData.alwaysSendToken && this.isToken1Mandatory == metaData.isToken1Mandatory && this.compressionEnabled == metaData.compressionEnabled && Double.compare(this.httpPost, metaData.httpPost) == 0 && this.periodicMetaDataEnabled == metaData.periodicMetaDataEnabled && this.periodicMetaDataIntervalInMinutes == metaData.periodicMetaDataIntervalInMinutes && this.periodicInfoEventEnabled == metaData.periodicInfoEventEnabled && this.inAppBrowser == metaData.inAppBrowser && this.SupportIABViewability == metaData.SupportIABViewability && this.IABDisplayImpressionDelayInSeconds == metaData.IABDisplayImpressionDelayInSeconds && this.IABVideoImpressionDelayInSeconds == metaData.IABVideoImpressionDelayInSeconds && this.notVisibleBannerReloadInterval == metaData.notVisibleBannerReloadInterval && this.dns == metaData.dns && this.adsPreCachingEnabled == metaData.adsPreCachingEnabled && this.stopAutoLoadAmount == metaData.stopAutoLoadAmount && this.stopAutoLoadPreCacheAmount == metaData.stopAutoLoadPreCacheAmount && this.trueNetEnabled == metaData.trueNetEnabled && this.webViewSecured == metaData.webViewSecured && this.omSdkEnabled == metaData.omSdkEnabled && this.chromeCustomeTabsInternal == metaData.chromeCustomeTabsInternal && this.chromeCustomeTabsExternal == metaData.chromeCustomeTabsExternal && this.closeAdAfterClick == metaData.closeAdAfterClick && this.disableSendAdvertisingId == metaData.disableSendAdvertisingId && Double.compare(this.flh, metaData.flh) == 0 && gj.a((Object) this.SimpleToken, (Object) metaData.SimpleToken) && gj.a((Object) this.consentDetails, (Object) metaData.consentDetails) && gj.a((Object) this.calcProd, (Object) metaData.calcProd) && gj.a(this.metaDataHosts, metaData.metaDataHosts) && gj.a((Object) this.adPlatformHostSecured, (Object) metaData.adPlatformHostSecured) && gj.a((Object) this.trackDownloadHost, (Object) metaData.trackDownloadHost) && gj.a((Object) this.vastRecorderHost, (Object) metaData.vastRecorderHost) && gj.a((Object) this.adPlatformBannerHostSecured, (Object) metaData.adPlatformBannerHostSecured) && gj.a((Object) this.adPlatformOverlayHostSecured, (Object) metaData.adPlatformOverlayHostSecured) && gj.a((Object) this.adPlatformNativeHostSecured, (Object) metaData.adPlatformNativeHostSecured) && gj.a((Object) this.profileId, (Object) metaData.profileId) && gj.a(this.installersList, metaData.installersList) && gj.a(this.preInstalledPackages, metaData.preInstalledPackages) && Arrays.equals(this.periodicEventIntMin, metaData.periodicEventIntMin) && Arrays.equals(this.periodicForegroundEventSec, metaData.periodicForegroundEventSec) && gj.a((Object) this.sensorsConfig, (Object) metaData.sensorsConfig) && gj.a((Object) this.btConfig, (Object) metaData.btConfig) && gj.a((Object) this.external, (Object) metaData.external) && gj.a((Object) this.assetsBaseUrlSecured, (Object) metaData.assetsBaseUrlSecured) && gj.a((Object) this.httpClientInfoEvents, (Object) metaData.httpClientInfoEvents) && gj.a((Object) this.analytics, (Object) metaData.analytics) && gj.a((Object) this.metadataUpdateVersion, (Object) metaData.metadataUpdateVersion) && gj.a((Object) this.networkTests, (Object) metaData.networkTests) && gj.a((Object) this.triggeredLinks, (Object) metaData.triggeredLinks) && gj.a((Object) this.rsc, (Object) metaData.rsc) && gj.a((Object) this.rcd, (Object) metaData.rcd) && gj.a((Object) this.netDiag, (Object) metaData.netDiag) && gj.a((Object) this.staleDc, (Object) metaData.staleDc) && gj.a((Object) this.motion, (Object) metaData.motion) && gj.a((Object) this.sensorsData, (Object) metaData.sensorsData) && gj.a((Object) this.air, (Object) metaData.air) && gj.a((Object) this.telephony, (Object) metaData.telephony) && gj.a((Object) this.anrConfig, (Object) metaData.anrConfig) && gj.a((Object) this.location, (Object) metaData.location) && gj.a((Object) this.impressionsTracking, (Object) metaData.impressionsTracking) && gj.a((Object) this.connectivity, (Object) metaData.connectivity) && gj.a((Object) this.adDebugger, (Object) metaData.adDebugger) && gj.a((Object) this.webViewFactory, (Object) metaData.webViewFactory) && gj.a((Object) this.appSession, (Object) metaData.appSession) && gj.a((Object) this.topics, (Object) metaData.topics) && gj.a((Object) this.mraid, (Object) metaData.mraid) && gj.a((Object) this.lastVersion, (Object) metaData.lastVersion) && gj.a((Object) this.impressionURL, (Object) metaData.impressionURL) && gj.a((Object) this.adClickURL, (Object) metaData.adClickURL);
}
public final AdvertisingIdResolverMetadata f() {
return this.air;
}
public final boolean f0() {
return this.compressionEnabled;
}
public final AnalyticsConfig g() {
return this.analytics;
}
public final boolean g0() {
WeakHashMap weakHashMap = gj.a;
return this.inAppBrowser;
}
public final ANRRemoteConfig h() {
return this.anrConfig;
}
public final boolean h0() {
return this.omSdkEnabled;
}
public final int hashCode() {
Object[] objArr = {this.SimpleToken, this.consentDetails, this.calcProd, this.metaDataHosts, this.adPlatformHostSecured, this.trackDownloadHost, this.vastRecorderHost, this.adPlatformBannerHostSecured, this.adPlatformOverlayHostSecured, this.adPlatformNativeHostSecured, Integer.valueOf(this.sessionMaxBackgroundTime), this.profileId, this.installersList, this.preInstalledPackages, Boolean.valueOf(this.simpleToken2), Boolean.valueOf(this.alwaysSendToken), Boolean.valueOf(this.isToken1Mandatory), Boolean.valueOf(this.compressionEnabled), Double.valueOf(this.httpPost), Boolean.valueOf(this.periodicMetaDataEnabled), Integer.valueOf(this.periodicMetaDataIntervalInMinutes), Boolean.valueOf(this.periodicInfoEventEnabled), this.periodicEventIntMin, this.periodicForegroundEventSec, Boolean.valueOf(this.inAppBrowser), Boolean.valueOf(this.SupportIABViewability), Long.valueOf(this.IABDisplayImpressionDelayInSeconds), Long.valueOf(this.IABVideoImpressionDelayInSeconds), this.sensorsConfig, this.btConfig, this.external, this.assetsBaseUrlSecured, this.httpClientInfoEvents, Integer.valueOf(this.notVisibleBannerReloadInterval), this.analytics, this.metadataUpdateVersion, Boolean.valueOf(this.dns), Boolean.valueOf(this.adsPreCachingEnabled), Integer.valueOf(this.stopAutoLoadAmount), Integer.valueOf(this.stopAutoLoadPreCacheAmount), Boolean.valueOf(this.trueNetEnabled), Boolean.valueOf(this.webViewSecured), Boolean.valueOf(this.omSdkEnabled), Boolean.valueOf(this.chromeCustomeTabsInternal), Boolean.valueOf(this.chromeCustomeTabsExternal), Boolean.valueOf(this.closeAdAfterClick), Boolean.valueOf(this.disableSendAdvertisingId), Double.valueOf(this.flh), this.networkTests, this.triggeredLinks, this.rsc, this.rcd, this.netDiag, this.staleDc, this.motion, this.sensorsData, this.air, this.telephony, this.anrConfig, this.location, this.impressionsTracking, this.connectivity, this.adDebugger, this.webViewFactory, this.appSession, this.topics, this.mraid, this.lastVersion, this.impressionURL, this.adClickURL};
WeakHashMap weakHashMap = gj.a;
return Arrays.deepHashCode(objArr);
}
public final AppSessionConfig i() {
return this.appSession;
}
public final boolean i0() {
return this.periodicForegroundEventSec != null;
}
public final String j() {
String str = this.assetsBaseUrlSecured;
return str != null ? str : "";
}
public final boolean j0() {
return this.periodicInfoEventEnabled;
}
public final BluetoothConfig k() {
return this.btConfig;
}
public final boolean k0() {
return this.periodicMetaDataEnabled;
}
public final String l() {
return this.calcProd;
}
public final boolean l0() {
return this.b;
}
public final boolean m() {
return this.chromeCustomeTabsExternal;
}
public final boolean m0() {
return this.SupportIABViewability;
}
public final boolean n() {
return this.chromeCustomeTabsInternal;
}
public final boolean n0() {
return this.isToken1Mandatory;
}
public final boolean o() {
return this.closeAdAfterClick;
}
public final void o0() {
this.b = true;
}
public final ConnectivityHelperMetadata p() {
return this.connectivity;
}
public final ConsentConfig q() {
return this.consentDetails;
}
public final boolean r() {
return this.disableSendAdvertisingId;
}
public final ExternalConfig s() {
return this.external;
}
public final ExternalAdConfig t() {
ExternalConfig externalConfig = this.external;
if (externalConfig != null) {
return externalConfig.getGoogleads();
}
return null;
}
public final String u() {
int indexOf;
String e2 = k.e();
String str = (Build.VERSION.SDK_INT > 26 || this.webViewSecured) ? HttpRequest.DEFAULT_SCHEME : "http";
if (e2.startsWith(str.concat("://")) || (indexOf = e2.indexOf(58)) == -1) {
return e2;
}
return str + e2.substring(indexOf);
}
public final ComponentInfoEventConfig v() {
return this.httpClientInfoEvents;
}
public final double w() {
return this.httpPost;
}
public final long x() {
return this.IABDisplayImpressionDelayInSeconds;
}
public final long y() {
return this.IABVideoImpressionDelayInSeconds;
}
public final String z() {
return this.impressionURL;
}
public final boolean b() {
return !this.dns;
}
public static void a(Context context, MetaData metaData, MetaDataRequest$RequestReason metaDataRequest$RequestReason, boolean z) {
ArrayList arrayList;
WeakHashMap weakHashMap = gj.a;
synchronized (d) {
arrayList = new ArrayList(k.c);
k.c.clear();
metaData.c = k.c;
metaData.a();
metaData.metadataUpdateVersion = "5.1.0";
p7.b(context, "StartappMetadata", metaData);
metaData.a = false;
metaData.b = true;
if (!gj.a((Object) k, (Object) metaData)) {
z = true;
}
k = metaData;
if (gj.d(context)) {
try {
kg kgVar = (kg) a.a(context).F.a();
int i2 = kgVar.getInt("totalSessions", 0);
jg edit = kgVar.edit();
int i3 = i2 + 1;
edit.a("totalSessions", Integer.valueOf(i3));
edit.a.putInt("totalSessions", i3);
edit.apply();
} catch (Throwable th) {
o9.a(th);
}
}
}
boolean z2 = Math.random() < k.flh;
Handler handler = z2 ? new Handler(Looper.getMainLooper()) : null;
Iterator it = arrayList.iterator();
while (it.hasNext()) {
rc rcVar = (rc) it.next();
if (z2) {
handler.post(new oc(rcVar, metaDataRequest$RequestReason, z));
} else {
rcVar.a(metaDataRequest$RequestReason, z);
}
}
}
public final String c() {
return this.adClickURL;
}
public static void a(MetaDataRequest$RequestReason metaDataRequest$RequestReason) {
ArrayList arrayList;
synchronized (d) {
arrayList = new ArrayList(k.c);
k.c.clear();
k.a = false;
}
Iterator it = arrayList.iterator();
while (it.hasNext()) {
((rc) it.next()).a();
}
}
public final void a(Context context, AdPreferences adPreferences, MetaDataRequest$RequestReason metaDataRequest$RequestReason, boolean z, b bVar, boolean z2) {
if (context == null || metaDataRequest$RequestReason == null) {
if (bVar != null) {
bVar.a(metaDataRequest$RequestReason, false);
return;
}
return;
}
if (!z && bVar != null) {
bVar.a(metaDataRequest$RequestReason, false);
}
synchronized (d) {
if (k.b && !z2) {
if (!z || bVar == null) {
return;
}
bVar.a(metaDataRequest$RequestReason, false);
return;
}
if (!k.a || z2) {
this.a = true;
this.b = false;
final AtomicInteger atomicInteger = l;
Objects.requireNonNull(atomicInteger);
new k8(context, adPreferences, metaDataRequest$RequestReason, new t7() {
@Override
public final Object a() {
return Integer.valueOf(atomicInteger.get());
}
}, atomicInteger.incrementAndGet()).b();
}
if (z && bVar != null) {
k.a(bVar);
}
}
}
public final void a(rc rcVar) {
synchronized (d) {
this.c.add(rcVar);
}
}
public final int a(Context context) {
return a(context, this.periodicForegroundEventSec);
}
private static int a(Context context, int[] iArr) {
if (iArr == null || iArr.length < 3) {
iArr = i;
}
if (s0.a(context, "android.permission.ACCESS_FINE_LOCATION")) {
int i2 = iArr[0];
return i2 <= 0 ? i[0] : i2;
}
if (s0.a(context, "android.permission.ACCESS_COARSE_LOCATION")) {
int i3 = iArr[1];
return i3 <= 0 ? i[1] : i3;
}
return iArr[2];
}
public final String a(AdPreferences.Placement placement) {
int i2 = pc.a[placement.ordinal()];
if (i2 == 1) {
String str = this.adPlatformBannerHostSecured;
return str != null ? str : e();
}
if (i2 == 2) {
String str2 = this.adPlatformOverlayHostSecured;
return str2 != null ? str2 : e();
}
if (i2 != 3) {
return e();
}
String str3 = this.adPlatformNativeHostSecured;
return str3 != null ? str3 : e();
}
public final void a() {
ArrayList arrayList;
String str = this.adPlatformHostSecured;
String str2 = h;
if (str != null) {
str2 = str.replace("%AdPlatformProtocol%", "1.5");
}
this.adPlatformHostSecured = str2;
List<String> list = this.metaDataHosts;
if (list != null) {
arrayList = new ArrayList(list.size());
Iterator<String> it = list.iterator();
while (it.hasNext()) {
String next = it.next();
String replace = next != null ? next.replace("%AdPlatformProtocol%", "1.5") : null;
if (replace != null) {
arrayList.add(replace);
}
}
} else {
arrayList = null;
}
this.metaDataHosts = arrayList;
String str3 = this.adPlatformBannerHostSecured;
this.adPlatformBannerHostSecured = str3 != null ? str3.replace("%AdPlatformProtocol%", "1.5") : null;
String str4 = this.adPlatformOverlayHostSecured;
this.adPlatformOverlayHostSecured = str4 != null ? str4.replace("%AdPlatformProtocol%", "1.5") : null;
String str5 = this.adPlatformNativeHostSecured;
this.adPlatformNativeHostSecured = str5 != null ? str5.replace("%AdPlatformProtocol%", "1.5") : null;
}
public static void a(Context context, String str) {
if (str == null || str.isEmpty()) {
return;
}
if (!k2.a(context, "close_button")) {
WeakHashMap weakHashMap = gj.a;
new o2(context, str.concat("close_button.png"), new qc(context, "close_button"), 0).a();
}
WeakHashMap weakHashMap2 = gj.a;
for (String str2 : k0.h) {
if (!k2.a(context, str2)) {
new o2(context, str + str2 + ".png", new qc(context, str2), 0).a();
}
}
WeakHashMap weakHashMap3 = gj.a;
for (String str3 : k0.i) {
if (!k2.a(context, str3)) {
new o2(context, str + str3 + ".png", new qc(context, str3), 0).a();
}
}
if (k2.a(context, "logo")) {
return;
}
new o2(context, str.concat("logo.png"), new qc(context, "logo"), 0).a();
}
}