Perfume Of Love v2.14.9版本的 MD5 值为:16011aefc5a55805771706ce3b259b4e
以下内容为反编译后的 k.java 源代码,内容仅作参考
package com.ironsource.mediationsdk.utils;
import android.content.Context;
import android.text.TextUtils;
import com.ironsource.environment.StringUtils;
import com.ironsource.mediationsdk.C1344u;
import com.ironsource.mediationsdk.adunit.data.DataKeys;
import com.ironsource.mediationsdk.model.InterstitialPlacement;
import com.ironsource.mediationsdk.model.NetworkSettings;
import com.ironsource.mediationsdk.model.Placement;
import com.ironsource.mediationsdk.model.o;
import com.ironsource.mediationsdk.model.p;
import com.ironsource.mediationsdk.model.q;
import com.ironsource.mediationsdk.model.r;
import com.ironsource.mediationsdk.model.s;
import com.ironsource.mediationsdk.model.t;
import com.ironsource.mediationsdk.model.u;
import com.mbridge.msdk.playercommon.exoplayer2.util.MimeTypes;
import com.onesignal.OSNotificationFormatHelper;
import com.tapjoy.TapjoyConstants;
import com.vungle.warren.model.ReportDBAdapter;
import java.util.HashMap;
import java.util.Iterator;
import java.util.Map;
import org.json.JSONArray;
import org.json.JSONException;
import org.json.JSONObject;
public final class k {
private final int A;
private final boolean B;
private final String C;
private final String D;
private final String E;
private final String F;
private final String G;
private final String H;
private final String I;
private final String J;
private final String K;
private final String L;
private final String M;
private final String N;
private final String O;
private final String P;
private final String Q;
private final String R;
private final String S;
private final String T;
private final String U;
private final String V;
private final String W;
private final String X;
private final String Y;
private final String Z;
public q a;
private final String aA;
private final String aB;
private final String aC;
private final String aD;
private final String aE;
private final String aF;
private final String aG;
private final String aH;
private final String aI;
private final String aJ;
private final String aK;
private final String aL;
private final String aM;
private final String aN;
private final String aO;
private final String aP;
private final String aQ;
private final String aR;
private final String aS;
private final String aT;
private final String aU;
private final String aV;
private final String aW;
private final String aX;
private final String aY;
private final String aZ;
private final String aa;
private final String ab;
private final String ac;
private final String ad;
private final String ae;
private final String af;
private final String ag;
private final String ah;
private final String ai;
private final String aj;
private final String ak;
private final String al;
private final String am;
private final String an;
private final String ao;
private final String ap;
private final String aq;
private final String ar;
private final String as;
private final String at;
private final String au;
private final String av;
private final String aw;
private final String ax;
private final String ay;
private final String az;
public r b;
private final String bA;
private final String bB;
private final String bC;
private final String bD;
private String bE;
private String bF;
private Context bG;
private final String ba;
private final String bb;
private final String bc;
private final String bd;
private final String be;
private final String bf;
private final String bg;
private final String bh;
private final String bi;
private final String bj;
private final String bk;
private final String bl;
private final String bm;
private final String bn;
private final String bo;
private final String bp;
private final String bq;
private final String br;
private final String bs;
private final String bt;
private final String bu;
private final String bv;
private final String bw;
private final String bx;
private final String by;
private final String bz;
public com.ironsource.mediationsdk.model.j c;
public JSONObject d;
public int e;
private final String f;
private final int g;
private final int h;
private final int i;
private final int j;
private final int k;
private final int l;
private final int m;
private final int n;
private final int o;
private final int p;
private final int q;
private final int r;
private final long s;
private final int t;
private final boolean u;
private final boolean v;
private final long w;
private final int x;
private final int y;
private final int z;
public static final class a {
public static final int a = 1;
public static final int b = 2;
public static final int c = 3;
private static final int[] d = {1, 2, 3};
}
public k(Context context, String str, String str2, String str3) {
this.f = "error";
this.g = 3;
this.h = 2;
this.i = 60;
this.j = 10000;
this.k = -1;
this.l = 5000;
this.m = ms.bd.o.Pgl.c.COLLECT_MODE_FINANCE;
this.n = 3;
this.o = 3;
this.p = 3;
this.q = 2;
this.r = 15;
this.s = 10000L;
this.t = 0;
this.u = false;
this.v = false;
this.w = 3000L;
this.x = 30000;
this.y = -1;
this.z = 5000;
this.A = 1;
this.B = false;
this.C = "providerOrder";
this.D = "providerSettings";
this.E = TapjoyConstants.PREF_SERVER_PROVIDED_CONFIGURATIONS;
this.F = IronSourceConstants.EVENTS_GENERIC_PARAMS;
this.G = "adUnits";
this.H = "providerLoadName";
this.I = MimeTypes.BASE_TYPE_APPLICATION;
this.J = "rewardedVideo";
this.K = "interstitial";
this.L = "offerwall";
this.M = "banner";
this.N = "integration";
this.O = "loggers";
this.P = "segment";
this.Q = "events";
this.R = "crashReporter";
this.S = "token";
this.T = "external";
this.U = "mediationTypes";
this.V = "providerDefaultInstance";
this.W = "testSuite";
this.X = "controllerUrl";
this.Y = "settings";
this.Z = "collectBiddingDataTimeout";
this.aa = "collectBiddingDataAsyncEnabled";
this.ab = "maxNumOfAdaptersToLoadOnStart";
this.ac = "advancedLoading";
this.ad = "adapterTimeOutInSeconds";
this.ae = "atim";
this.af = "bannerInterval";
this.ag = "isOneFlow";
this.ah = "loadRVInterval";
this.ai = "expiredDurationInMinutes";
this.aj = "server";
this.ak = "publisher";
this.al = "console";
this.am = "sendUltraEvents";
this.an = "sendEventsToggle";
this.ao = "eventsCompression";
this.ap = "eventsCompressionLevel";
this.aq = "serverEventsURL";
this.ar = "serverEventsType";
this.as = "backupThreshold";
this.at = "maxNumberOfEvents";
this.au = "maxEventsPerBatch";
this.av = "optOut";
this.aw = "optIn";
this.ax = "triggerEvents";
this.ay = "nonConnectivityEvents";
this.az = "shouldSendPublisherLogsOnUIThread";
this.aA = "pixel";
this.aB = "pixelEventsUrl";
this.aC = "pixelEventsEnabled";
this.aD = "placements";
this.aE = ReportDBAdapter.ReportColumns.COLUMN_PLACEMENT_ID;
this.aF = "placementName";
this.aG = "delivery";
this.aH = "isDefault";
this.aI = "capping";
this.aJ = "pacing";
this.aK = "enabled";
this.aL = "maxImpressions";
this.aM = "numOfSeconds";
this.aN = "unit";
this.aO = "virtualItemName";
this.aP = "virtualItemCount";
this.aQ = "uuidEnabled";
this.aR = "abt";
this.aS = "delayLoadFailure";
this.aT = "keysToInclude";
this.aU = "reporterURL";
this.aV = "reporterKeyword";
this.aW = "includeANR";
this.aX = "timeout";
this.aY = "setIgnoreDebugger";
this.aZ = "adSourceName";
this.ba = IronSourceConstants.EVENTS_SUB_PROVIDER_ID;
this.bb = "mpis";
this.bc = "auction";
this.bd = "auctionData";
this.be = "auctioneerURL";
this.bf = "extAuctioneerURL";
this.bg = IronSourceConstants.EVENTS_PROGRAMMATIC;
this.bh = "objectPerWaterfall";
this.bi = "minTimeBeforeFirstAuction";
this.bj = "timeToWaitBeforeAuction";
this.bk = "timeToWaitBeforeLoad";
this.bl = "auctionRetryInterval";
this.bm = "isAuctionOnShowStart";
this.bn = "isLoadWhileShow";
this.bo = IronSourceConstants.AUCTION_TRIALS;
this.bp = "auctionTimeout";
this.bq = "auctionSavedHistory";
this.br = "disableLoadWhileShowSupportFor";
this.bs = "timeToDeleteOldWaterfallAfterAuction";
this.bt = "compressAuctionRequest";
this.bu = "compressAuctionResponse";
this.bv = "encryptionVersion";
this.bw = "shouldSendBannerBURLFromImpression";
this.bx = "optInKeys";
this.by = "tokenGenericParams";
this.bz = "oneToken";
this.bA = "compressToken";
this.bB = "isExternalArmEventsEnabled";
this.bC = "externalArmEventsUrl";
this.bD = "compressExternalToken";
this.e = a.a;
this.bG = context;
try {
this.d = TextUtils.isEmpty(str3) ? new JSONObject() : new JSONObject(str3);
h();
i();
g();
this.bE = TextUtils.isEmpty(str) ? "" : str;
this.bF = TextUtils.isEmpty(str2) ? "" : str2;
} catch (JSONException e) {
e.printStackTrace();
e();
}
}
public k(k kVar) {
this.f = "error";
this.g = 3;
this.h = 2;
this.i = 60;
this.j = 10000;
this.k = -1;
this.l = 5000;
this.m = ms.bd.o.Pgl.c.COLLECT_MODE_FINANCE;
this.n = 3;
this.o = 3;
this.p = 3;
this.q = 2;
this.r = 15;
this.s = 10000L;
this.t = 0;
this.u = false;
this.v = false;
this.w = 3000L;
this.x = 30000;
this.y = -1;
this.z = 5000;
this.A = 1;
this.B = false;
this.C = "providerOrder";
this.D = "providerSettings";
this.E = TapjoyConstants.PREF_SERVER_PROVIDED_CONFIGURATIONS;
this.F = IronSourceConstants.EVENTS_GENERIC_PARAMS;
this.G = "adUnits";
this.H = "providerLoadName";
this.I = MimeTypes.BASE_TYPE_APPLICATION;
this.J = "rewardedVideo";
this.K = "interstitial";
this.L = "offerwall";
this.M = "banner";
this.N = "integration";
this.O = "loggers";
this.P = "segment";
this.Q = "events";
this.R = "crashReporter";
this.S = "token";
this.T = "external";
this.U = "mediationTypes";
this.V = "providerDefaultInstance";
this.W = "testSuite";
this.X = "controllerUrl";
this.Y = "settings";
this.Z = "collectBiddingDataTimeout";
this.aa = "collectBiddingDataAsyncEnabled";
this.ab = "maxNumOfAdaptersToLoadOnStart";
this.ac = "advancedLoading";
this.ad = "adapterTimeOutInSeconds";
this.ae = "atim";
this.af = "bannerInterval";
this.ag = "isOneFlow";
this.ah = "loadRVInterval";
this.ai = "expiredDurationInMinutes";
this.aj = "server";
this.ak = "publisher";
this.al = "console";
this.am = "sendUltraEvents";
this.an = "sendEventsToggle";
this.ao = "eventsCompression";
this.ap = "eventsCompressionLevel";
this.aq = "serverEventsURL";
this.ar = "serverEventsType";
this.as = "backupThreshold";
this.at = "maxNumberOfEvents";
this.au = "maxEventsPerBatch";
this.av = "optOut";
this.aw = "optIn";
this.ax = "triggerEvents";
this.ay = "nonConnectivityEvents";
this.az = "shouldSendPublisherLogsOnUIThread";
this.aA = "pixel";
this.aB = "pixelEventsUrl";
this.aC = "pixelEventsEnabled";
this.aD = "placements";
this.aE = ReportDBAdapter.ReportColumns.COLUMN_PLACEMENT_ID;
this.aF = "placementName";
this.aG = "delivery";
this.aH = "isDefault";
this.aI = "capping";
this.aJ = "pacing";
this.aK = "enabled";
this.aL = "maxImpressions";
this.aM = "numOfSeconds";
this.aN = "unit";
this.aO = "virtualItemName";
this.aP = "virtualItemCount";
this.aQ = "uuidEnabled";
this.aR = "abt";
this.aS = "delayLoadFailure";
this.aT = "keysToInclude";
this.aU = "reporterURL";
this.aV = "reporterKeyword";
this.aW = "includeANR";
this.aX = "timeout";
this.aY = "setIgnoreDebugger";
this.aZ = "adSourceName";
this.ba = IronSourceConstants.EVENTS_SUB_PROVIDER_ID;
this.bb = "mpis";
this.bc = "auction";
this.bd = "auctionData";
this.be = "auctioneerURL";
this.bf = "extAuctioneerURL";
this.bg = IronSourceConstants.EVENTS_PROGRAMMATIC;
this.bh = "objectPerWaterfall";
this.bi = "minTimeBeforeFirstAuction";
this.bj = "timeToWaitBeforeAuction";
this.bk = "timeToWaitBeforeLoad";
this.bl = "auctionRetryInterval";
this.bm = "isAuctionOnShowStart";
this.bn = "isLoadWhileShow";
this.bo = IronSourceConstants.AUCTION_TRIALS;
this.bp = "auctionTimeout";
this.bq = "auctionSavedHistory";
this.br = "disableLoadWhileShowSupportFor";
this.bs = "timeToDeleteOldWaterfallAfterAuction";
this.bt = "compressAuctionRequest";
this.bu = "compressAuctionResponse";
this.bv = "encryptionVersion";
this.bw = "shouldSendBannerBURLFromImpression";
this.bx = "optInKeys";
this.by = "tokenGenericParams";
this.bz = "oneToken";
this.bA = "compressToken";
this.bB = "isExternalArmEventsEnabled";
this.bC = "externalArmEventsUrl";
this.bD = "compressExternalToken";
this.e = a.a;
try {
this.bG = kVar.bG;
this.d = new JSONObject(kVar.d.toString());
this.bE = kVar.bE;
this.bF = kVar.bF;
this.a = kVar.a;
this.b = kVar.b;
this.c = kVar.c;
this.e = kVar.e;
} catch (Exception unused) {
e();
}
}
private static int a(JSONObject jSONObject, JSONObject jSONObject2, String str, int i) {
int i2 = 0;
if (jSONObject.has(str)) {
i2 = jSONObject.optInt(str, 0);
} else if (jSONObject2.has(str)) {
i2 = jSONObject2.optInt(str, 0);
}
return i2 == 0 ? i : i2;
}
private static com.ironsource.mediationsdk.model.o a(JSONObject jSONObject) {
p pVar = null;
if (jSONObject == null) {
return null;
}
o.a aVar = new o.a();
boolean z = true;
aVar.a = jSONObject.optBoolean("delivery", true);
JSONObject optJSONObject = jSONObject.optJSONObject("capping");
if (optJSONObject != null) {
String optString = optJSONObject.optString("unit");
if (!TextUtils.isEmpty(optString)) {
if (p.PER_DAY.toString().equals(optString)) {
pVar = p.PER_DAY;
} else if (p.PER_HOUR.toString().equals(optString)) {
pVar = p.PER_HOUR;
}
}
int optInt = optJSONObject.optInt("maxImpressions", 0);
aVar.a(optJSONObject.optBoolean("enabled", false) && optInt > 0, pVar, optInt);
}
JSONObject optJSONObject2 = jSONObject.optJSONObject("pacing");
if (optJSONObject2 != null) {
int optInt2 = optJSONObject2.optInt("numOfSeconds", 0);
aVar.a((!optJSONObject2.optBoolean("enabled", false) || optInt2 <= 0) ? false : false, optInt2);
}
return aVar.a();
}
private static int[] a(JSONObject jSONObject, String str) {
JSONArray optJSONArray = jSONObject.optJSONArray(str);
if (optJSONArray != null) {
int[] iArr = new int[optJSONArray.length()];
for (int i = 0; i < optJSONArray.length(); i++) {
iArr[i] = optJSONArray.optInt(i);
}
return iArr;
}
return null;
}
private static JSONObject b(JSONObject jSONObject, String str) {
if (jSONObject != null) {
return jSONObject.optJSONObject(str);
}
return null;
}
private void e() {
this.d = new JSONObject();
this.bE = "";
this.bF = "";
this.a = new q();
this.b = r.a();
this.c = new com.ironsource.mediationsdk.model.j();
}
private boolean f() {
JSONObject b;
JSONArray optJSONArray;
JSONObject b2 = b(this.d, "providerOrder");
JSONArray names = b2.names();
if (names == null) {
return true;
}
JSONObject b3 = b(b(this.d, TapjoyConstants.PREF_SERVER_PROVIDED_CONFIGURATIONS), "adUnits");
for (int i = 0; i < names.length(); i++) {
String optString = names.optString(i);
JSONArray optJSONArray2 = b2.optJSONArray(optString);
if (optJSONArray2 != null && optJSONArray2.length() != 0 && (b = b(b3, optString)) != null && ((optJSONArray = b.optJSONArray("placements")) == null || optJSONArray.length() == 0)) {
return false;
}
}
return true;
}
private void g() {
com.ironsource.mediationsdk.model.j jVar;
com.ironsource.mediationsdk.model.j jVar2;
try {
JSONObject b = b(this.d, "providerOrder");
JSONArray optJSONArray = b.optJSONArray("rewardedVideo");
JSONArray optJSONArray2 = b.optJSONArray("interstitial");
JSONArray optJSONArray3 = b.optJSONArray("banner");
this.a = new q();
if (optJSONArray != null && (jVar2 = this.c) != null && jVar2.a != null) {
for (int i = 0; i < optJSONArray.length(); i++) {
String optString = optJSONArray.optString(i);
q qVar = this.a;
if (!TextUtils.isEmpty(optString)) {
qVar.a.add(optString);
}
NetworkSettings a2 = r.a().a(optString);
if (a2 != null) {
a2.setRewardedVideoPriority(i);
}
}
}
if (optJSONArray2 != null && (jVar = this.c) != null && jVar.b != null) {
for (int i2 = 0; i2 < optJSONArray2.length(); i2++) {
String optString2 = optJSONArray2.optString(i2);
q qVar2 = this.a;
if (!TextUtils.isEmpty(optString2)) {
qVar2.b.add(optString2);
}
NetworkSettings a3 = r.a().a(optString2);
if (a3 != null) {
a3.setInterstitialPriority(i2);
}
}
}
if (optJSONArray3 != null) {
for (int i3 = 0; i3 < optJSONArray3.length(); i3++) {
String optString3 = optJSONArray3.optString(i3);
q qVar3 = this.a;
if (!TextUtils.isEmpty(optString3)) {
qVar3.c.add(optString3);
}
NetworkSettings a4 = r.a().a(optString3);
if (a4 != null) {
a4.setBannerPriority(i3);
}
}
}
} catch (Exception e) {
e.printStackTrace();
}
}
private void h() {
String str;
JSONObject jSONObject;
NetworkSettings networkSettings;
r rVar;
String str2 = "Mediation";
try {
this.b = r.a();
JSONObject b = b(this.d, "providerSettings");
Iterator<String> keys = b.keys();
while (keys.hasNext()) {
String next = keys.next();
JSONObject optJSONObject = b.optJSONObject(next);
if (optJSONObject != null) {
boolean optBoolean = optJSONObject.optBoolean("mpis", false);
String optString = optJSONObject.optString(IronSourceConstants.EVENTS_SUB_PROVIDER_ID, "0");
String optString2 = optJSONObject.optString("adSourceName", null);
String optString3 = optJSONObject.optString("providerLoadName", next);
String optString4 = optJSONObject.optString("providerDefaultInstance", optString3);
JSONObject b2 = b(optJSONObject, "adUnits");
JSONObject b3 = b(optJSONObject, MimeTypes.BASE_TYPE_APPLICATION);
JSONObject b4 = b(b2, "rewardedVideo");
JSONObject b5 = b(b2, "interstitial");
JSONObject b6 = b(b2, "banner");
JSONObject mergeJsons = IronSourceUtils.mergeJsons(b4, b3);
JSONObject mergeJsons2 = IronSourceUtils.mergeJsons(b5, b3);
JSONObject mergeJsons3 = IronSourceUtils.mergeJsons(b6, b3);
if (this.b.b(next)) {
NetworkSettings a2 = this.b.a(next);
JSONObject rewardedVideoSettings = a2.getRewardedVideoSettings();
JSONObject interstitialSettings = a2.getInterstitialSettings();
JSONObject bannerSettings = a2.getBannerSettings();
a2.setRewardedVideoSettings(IronSourceUtils.mergeJsons(rewardedVideoSettings, mergeJsons));
a2.setInterstitialSettings(IronSourceUtils.mergeJsons(interstitialSettings, mergeJsons2));
a2.setBannerSettings(IronSourceUtils.mergeJsons(bannerSettings, mergeJsons3));
a2.setIsMultipleInstances(optBoolean);
a2.setSubProviderId(optString);
a2.setAdSourceNameForEvents(optString2);
} else {
String lowerCase = StringUtils.toLowerCase(optString3);
if (this.b.b(str2) && (StringUtils.toLowerCase(IronSourceConstants.SUPERSONIC_CONFIG_NAME).equals(lowerCase) || StringUtils.toLowerCase(IronSourceConstants.IRONSOURCE_CONFIG_NAME).equals(lowerCase))) {
NetworkSettings a3 = this.b.a(str2);
str = str2;
jSONObject = b;
networkSettings = new NetworkSettings(next, optString3, optString4, b3, IronSourceUtils.mergeJsons(new JSONObject(a3.getRewardedVideoSettings().toString()), mergeJsons), IronSourceUtils.mergeJsons(new JSONObject(a3.getInterstitialSettings().toString()), mergeJsons2), IronSourceUtils.mergeJsons(new JSONObject(a3.getBannerSettings().toString()), mergeJsons3));
networkSettings.setIsMultipleInstances(optBoolean);
networkSettings.setSubProviderId(optString);
networkSettings.setAdSourceNameForEvents(optString2);
rVar = this.b;
} else {
str = str2;
jSONObject = b;
networkSettings = new NetworkSettings(next, optString3, optString4, b3, mergeJsons, mergeJsons2, mergeJsons3);
networkSettings.setIsMultipleInstances(optBoolean);
networkSettings.setSubProviderId(optString);
networkSettings.setAdSourceNameForEvents(optString2);
rVar = this.b;
}
rVar.a(networkSettings);
}
} else {
str = str2;
jSONObject = b;
}
str2 = str;
b = jSONObject;
}
this.b.b();
} catch (Exception e) {
e.printStackTrace();
}
}
private void i() {
Exception exc;
JSONObject jSONObject;
JSONObject jSONObject2;
String str;
String str2;
int i;
boolean z;
String str3;
int[] iArr;
int[] iArr2;
int[] iArr3;
int[] iArr4;
String str4;
String str5;
c cVar;
k kVar;
s sVar;
Placement placement;
String str6;
String str7;
com.ironsource.mediationsdk.model.l lVar;
JSONObject jSONObject3;
k kVar2;
String str8;
String str9;
com.ironsource.mediationsdk.model.h hVar;
String str10;
String str11;
String str12;
com.ironsource.mediationsdk.model.m mVar;
boolean z2;
t tVar;
JSONObject b;
int[] iArr5;
int[] iArr6;
int[] iArr7;
int[] iArr8;
JSONArray jSONArray;
com.ironsource.mediationsdk.model.n nVar;
boolean z3;
boolean z4;
boolean optBoolean;
JSONArray optJSONArray;
int[] iArr9;
JSONArray optJSONArray2;
int[] iArr10;
JSONArray optJSONArray3;
int[] iArr11;
JSONArray optJSONArray4;
int[] iArr12;
String str13;
JSONObject jSONObject4;
c cVar2;
JSONObject jSONObject5;
JSONArray jSONArray2;
String str14;
com.ironsource.mediationsdk.model.i iVar;
int i2;
boolean z5;
int[] iArr13;
int[] iArr14;
int[] iArr15;
int[] iArr16;
JSONObject jSONObject6;
c cVar3;
JSONObject jSONObject7;
String str15;
JSONArray jSONArray3;
InterstitialPlacement interstitialPlacement;
try {
JSONObject b2 = b(this.d, TapjoyConstants.PREF_SERVER_PROVIDED_CONFIGURATIONS);
JSONObject b3 = b(b2, "adUnits");
JSONObject b4 = b(b2, MimeTypes.BASE_TYPE_APPLICATION);
JSONObject b5 = b(b3, "rewardedVideo");
JSONObject b6 = b(b3, "interstitial");
JSONObject b7 = b(b3, "offerwall");
JSONObject b8 = b(b3, "banner");
JSONObject b9 = b(b4, "events");
JSONObject b10 = b(b4, "loggers");
JSONObject b11 = b(b4, "token");
JSONObject b12 = b(b4, "segment");
JSONObject b13 = b(b4, "auction");
JSONObject b14 = b(b4, "crashReporter");
JSONObject b15 = b(b4, "settings");
JSONObject b16 = b(b4, "external");
JSONObject b17 = b(b9, "pixel");
if (b4 != null) {
jSONObject = b12;
jSONObject2 = b14;
IronSourceUtils.saveBooleanToSharedPrefs(this.bG, "uuidEnabled", b4.optBoolean("uuidEnabled", true));
} else {
jSONObject = b12;
jSONObject2 = b14;
}
if (b9 != null) {
String optString = b9.optString("abt");
if (!TextUtils.isEmpty(optString)) {
com.ironsource.mediationsdk.events.e.d().q = optString;
com.ironsource.mediationsdk.events.i.d().q = optString;
}
}
String str16 = "serverEventsType";
JSONObject jSONObject8 = b13;
String str17 = "optIn";
String str18 = "optOut";
if (b5 != null) {
try {
JSONArray optJSONArray5 = b5.optJSONArray("placements");
str = "placements";
JSONObject b18 = b(b5, "events");
str2 = "events";
JSONArray jSONArray4 = optJSONArray5;
boolean optBoolean2 = b5.optBoolean("collectBiddingDataAsyncEnabled", false);
long optLong = b5.optLong("collectBiddingDataTimeout", 3000L);
int a2 = a(b5, b4, "maxNumOfAdaptersToLoadOnStart", 2);
int a3 = a(b5, b4, "advancedLoading", 0);
if (a3 > 0) {
i = a3;
z = true;
} else {
i = a2;
z = false;
}
int a4 = a(b5, b4, "adapterTimeOutInSeconds", 60);
int a5 = a(b5, b4, "loadRVInterval", ms.bd.o.Pgl.c.COLLECT_MODE_FINANCE);
int a6 = a(b5, b4, "expiredDurationInMinutes", -1);
int a7 = a(b5, b4, "delayLoadFailure", 3);
JSONObject mergeJsons = IronSourceUtils.mergeJsons(b18, b9);
boolean optBoolean3 = mergeJsons.optBoolean("sendUltraEvents", false);
boolean optBoolean4 = mergeJsons.optBoolean("sendEventsToggle", false);
boolean optBoolean5 = mergeJsons.optBoolean("eventsCompression", false);
int optInt = mergeJsons.optInt("eventsCompressionLevel", -1);
String optString2 = mergeJsons.optString("serverEventsURL", "");
String optString3 = mergeJsons.optString("serverEventsType", "");
int optInt2 = mergeJsons.optInt("backupThreshold", -1);
int optInt3 = mergeJsons.optInt("maxNumberOfEvents", -1);
int optInt4 = mergeJsons.optInt("maxEventsPerBatch", 5000);
JSONArray optJSONArray6 = mergeJsons.optJSONArray(str18);
if (optJSONArray6 != null) {
int[] iArr17 = new int[optJSONArray6.length()];
str18 = str18;
str3 = "maxEventsPerBatch";
for (int i3 = 0; i3 < optJSONArray6.length(); i3++) {
iArr17[i3] = optJSONArray6.optInt(i3);
}
iArr = iArr17;
} else {
str18 = str18;
str3 = "maxEventsPerBatch";
iArr = null;
}
JSONArray optJSONArray7 = mergeJsons.optJSONArray(str17);
if (optJSONArray7 != null) {
int[] iArr18 = new int[optJSONArray7.length()];
str17 = str17;
for (int i4 = 0; i4 < optJSONArray7.length(); i4++) {
iArr18[i4] = optJSONArray7.optInt(i4);
}
iArr2 = iArr18;
} else {
str17 = str17;
iArr2 = null;
}
JSONArray optJSONArray8 = mergeJsons.optJSONArray("triggerEvents");
if (optJSONArray8 != null) {
int[] iArr19 = new int[optJSONArray8.length()];
for (int i5 = 0; i5 < optJSONArray8.length(); i5++) {
iArr19[i5] = optJSONArray8.optInt(i5);
}
iArr3 = iArr19;
} else {
iArr3 = null;
}
JSONArray optJSONArray9 = mergeJsons.optJSONArray("nonConnectivityEvents");
if (optJSONArray9 != null) {
int[] iArr20 = new int[optJSONArray9.length()];
for (int i6 = 0; i6 < optJSONArray9.length(); i6++) {
iArr20[i6] = optJSONArray9.optInt(i6);
}
iArr4 = iArr20;
} else {
iArr4 = null;
}
com.ironsource.mediationsdk.model.e eVar = new com.ironsource.mediationsdk.model.e(optBoolean3, optBoolean4, optBoolean5, optInt, optString2, optString3, optInt2, optInt3, optInt4, iArr, iArr2, iArr3, iArr4);
if (jSONObject8 != null) {
JSONObject b19 = b(jSONObject8, "rewardedVideo");
String optString4 = jSONObject8.optString("auctionData", "");
String optString5 = jSONObject8.optString("auctioneerURL", "");
String optString6 = jSONObject8.optString("extAuctioneerURL", "");
int optInt5 = jSONObject8.optInt(IronSourceConstants.AUCTION_TRIALS, 2);
long optLong2 = jSONObject8.optLong("auctionTimeout", 10000L);
int optInt6 = jSONObject8.optInt("auctionSavedHistory", 15);
boolean optBoolean6 = jSONObject8.optBoolean("compressAuctionRequest", false);
boolean optBoolean7 = jSONObject8.optBoolean("compressAuctionResponse", false);
int optInt7 = jSONObject8.optInt("encryptionVersion", 1);
jSONObject8 = jSONObject8;
str4 = "maxNumberOfEvents";
str5 = "backupThreshold";
c cVar4 = new c(optString4, optString5, optString6, optInt5, optInt6, optLong2, b19.optBoolean(IronSourceConstants.EVENTS_PROGRAMMATIC, false), b19.optInt("minTimeBeforeFirstAuction", 2000), b19.optInt("auctionRetryInterval", 30000), b19.optInt("timeToWaitBeforeAuction", 5000), b19.optInt("timeToWaitBeforeLoad", 50), b19.optBoolean("isAuctionOnShowStart", false), b19.optBoolean("isLoadWhileShow", false), b19.optInt("timeToDeleteOldWaterfallAfterAuction", 30000), optBoolean6, optBoolean7, b19.optBoolean("objectPerWaterfall", false), optInt7, false);
JSONArray optJSONArray10 = b19.optJSONArray("disableLoadWhileShowSupportFor");
if (optJSONArray10 != null) {
for (int i7 = 0; i7 < optJSONArray10.length(); i7++) {
String optString7 = optJSONArray10.optString(i7);
if (!TextUtils.isEmpty(optString7)) {
cVar4.o.add(optString7);
}
}
}
cVar = cVar4;
} else {
str4 = "maxNumberOfEvents";
str5 = "backupThreshold";
cVar = new c();
}
s sVar2 = new s(i, z, a4, a5, a6, eVar, cVar, a7, optBoolean2, optLong);
if (jSONArray4 != null) {
int i8 = 0;
while (i8 < jSONArray4.length()) {
JSONArray jSONArray5 = jSONArray4;
JSONObject optJSONObject = jSONArray5.optJSONObject(i8);
if (optJSONObject != null) {
int optInt8 = optJSONObject.optInt(ReportDBAdapter.ReportColumns.COLUMN_PLACEMENT_ID, -1);
String optString8 = optJSONObject.optString("placementName", "");
boolean optBoolean8 = optJSONObject.optBoolean("isDefault", false);
String optString9 = optJSONObject.optString("virtualItemName", "");
int optInt9 = optJSONObject.optInt("virtualItemCount", -1);
com.ironsource.mediationsdk.model.o a8 = a(optJSONObject);
if (optInt8 >= 0 && !TextUtils.isEmpty(optString8) && !TextUtils.isEmpty(optString9) && optInt9 > 0) {
placement = new Placement(optInt8, optString8, optBoolean8, optString9, optInt9, a8);
if (a8 != null) {
kVar = this;
try {
j.a(kVar.bG, placement);
} catch (Exception e) {
exc = e;
exc.printStackTrace();
return;
}
}
if (placement != null && placement != null) {
sVar2.a.add(placement);
if (sVar2.j != null && !placement.isPlacementId(0)) {
}
sVar2.j = placement;
}
i8++;
jSONArray4 = jSONArray5;
}
}
placement = null;
if (placement != null) {
sVar2.a.add(placement);
if (sVar2.j != null) {
}
sVar2.j = placement;
}
i8++;
jSONArray4 = jSONArray5;
}
}
kVar = this;
sVar = sVar2;
} catch (Exception e2) {
e = e2;
exc = e;
exc.printStackTrace();
return;
}
} else {
str2 = "events";
str = "placements";
str3 = "maxEventsPerBatch";
str4 = "maxNumberOfEvents";
str5 = "backupThreshold";
kVar = this;
sVar = null;
}
if (b6 != null) {
String str19 = str;
JSONArray optJSONArray11 = b6.optJSONArray(str19);
String str20 = str2;
JSONObject b20 = b(b6, str20);
str2 = str20;
boolean optBoolean9 = b6.optBoolean("collectBiddingDataAsyncEnabled", false);
str = str19;
JSONArray jSONArray6 = optJSONArray11;
long optLong3 = b6.optLong("collectBiddingDataTimeout", 3000L);
int a9 = a(b6, b4, "maxNumOfAdaptersToLoadOnStart", 2);
int a10 = a(b6, b4, "advancedLoading", 0);
if (a10 > 0) {
i2 = a10;
z5 = true;
} else {
i2 = a9;
z5 = false;
}
int a11 = a(b6, b4, "adapterTimeOutInSeconds", 60);
int a12 = a(b6, b4, "delayLoadFailure", 3);
JSONObject mergeJsons2 = IronSourceUtils.mergeJsons(b20, b9);
boolean optBoolean10 = mergeJsons2.optBoolean("sendEventsToggle", false);
boolean optBoolean11 = mergeJsons2.optBoolean("eventsCompression", false);
int optInt10 = mergeJsons2.optInt("eventsCompressionLevel", -1);
String optString10 = mergeJsons2.optString("serverEventsURL", "");
String optString11 = mergeJsons2.optString("serverEventsType", "");
String str21 = str5;
int optInt11 = mergeJsons2.optInt(str21, -1);
String str22 = str4;
int optInt12 = mergeJsons2.optInt(str22, -1);
String str23 = str3;
int optInt13 = mergeJsons2.optInt(str23, 5000);
str3 = str23;
String str24 = str18;
JSONArray optJSONArray12 = mergeJsons2.optJSONArray(str24);
if (optJSONArray12 != null) {
str18 = str24;
int[] iArr21 = new int[optJSONArray12.length()];
str5 = str21;
str4 = str22;
for (int i9 = 0; i9 < optJSONArray12.length(); i9++) {
iArr21[i9] = optJSONArray12.optInt(i9);
}
iArr13 = iArr21;
} else {
str5 = str21;
str4 = str22;
str18 = str24;
iArr13 = null;
}
String str25 = str17;
JSONArray optJSONArray13 = mergeJsons2.optJSONArray(str25);
if (optJSONArray13 != null) {
int[] iArr22 = new int[optJSONArray13.length()];
str17 = str25;
for (int i10 = 0; i10 < optJSONArray13.length(); i10++) {
iArr22[i10] = optJSONArray13.optInt(i10);
}
iArr14 = iArr22;
} else {
str17 = str25;
iArr14 = null;
}
JSONArray optJSONArray14 = mergeJsons2.optJSONArray("triggerEvents");
if (optJSONArray14 != null) {
int[] iArr23 = new int[optJSONArray14.length()];
for (int i11 = 0; i11 < optJSONArray14.length(); i11++) {
iArr23[i11] = optJSONArray14.optInt(i11);
}
iArr15 = iArr23;
} else {
iArr15 = null;
}
JSONArray optJSONArray15 = mergeJsons2.optJSONArray("nonConnectivityEvents");
if (optJSONArray15 != null) {
int[] iArr24 = new int[optJSONArray15.length()];
for (int i12 = 0; i12 < optJSONArray15.length(); i12++) {
iArr24[i12] = optJSONArray15.optInt(i12);
}
iArr16 = iArr24;
} else {
iArr16 = null;
}
com.ironsource.mediationsdk.model.e eVar2 = new com.ironsource.mediationsdk.model.e(false, optBoolean10, optBoolean11, optInt10, optString10, optString11, optInt11, optInt12, optInt13, iArr13, iArr14, iArr15, iArr16);
if (jSONObject8 != null) {
jSONObject6 = jSONObject8;
JSONObject b21 = b(jSONObject6, "interstitial");
str7 = "eventsCompression";
cVar3 = new c(jSONObject6.optString("auctionData", ""), jSONObject6.optString("auctioneerURL", ""), jSONObject6.optString("extAuctioneerURL", ""), jSONObject6.optInt(IronSourceConstants.AUCTION_TRIALS, 2), jSONObject6.optInt("auctionSavedHistory", 15), jSONObject6.optLong("auctionTimeout", 10000L), b21.optBoolean(IronSourceConstants.EVENTS_PROGRAMMATIC, false), b21.optInt("minTimeBeforeFirstAuction", 2000), 0L, 0L, 0L, true, true, 0, jSONObject6.optBoolean("compressAuctionRequest", false), jSONObject6.optBoolean("compressAuctionResponse", false), b21.optBoolean("objectPerWaterfall", false), jSONObject6.optInt("encryptionVersion", 1), false);
} else {
str7 = "eventsCompression";
jSONObject6 = jSONObject8;
cVar3 = new c();
}
com.ironsource.mediationsdk.model.l lVar2 = new com.ironsource.mediationsdk.model.l(i2, z5, a11, eVar2, cVar3, a12, optBoolean9, optLong3);
if (jSONArray6 != null) {
int i13 = 0;
while (i13 < jSONArray6.length()) {
JSONArray jSONArray7 = jSONArray6;
JSONObject optJSONObject2 = jSONArray7.optJSONObject(i13);
if (optJSONObject2 != null) {
jSONArray3 = jSONArray7;
int optInt14 = optJSONObject2.optInt(ReportDBAdapter.ReportColumns.COLUMN_PLACEMENT_ID, -1);
String optString12 = optJSONObject2.optString("placementName", "");
jSONObject7 = jSONObject6;
str15 = str16;
boolean optBoolean12 = optJSONObject2.optBoolean("isDefault", false);
com.ironsource.mediationsdk.model.o a13 = a(optJSONObject2);
if (optInt14 >= 0 && !TextUtils.isEmpty(optString12)) {
interstitialPlacement = new InterstitialPlacement(optInt14, optString12, optBoolean12, a13);
if (a13 != null) {
j.a(kVar.bG, interstitialPlacement);
}
if (interstitialPlacement != null && interstitialPlacement != null) {
lVar2.a.add(interstitialPlacement);
if (lVar2.j == null || interstitialPlacement.isPlacementId(0)) {
lVar2.j = interstitialPlacement;
}
}
i13++;
jSONArray6 = jSONArray3;
jSONObject6 = jSONObject7;
str16 = str15;
}
} else {
jSONObject7 = jSONObject6;
str15 = str16;
jSONArray3 = jSONArray7;
}
interstitialPlacement = null;
if (interstitialPlacement != null) {
lVar2.a.add(interstitialPlacement);
if (lVar2.j == null) {
}
lVar2.j = interstitialPlacement;
}
i13++;
jSONArray6 = jSONArray3;
jSONObject6 = jSONObject7;
str16 = str15;
}
}
jSONObject8 = jSONObject6;
str6 = str16;
lVar = lVar2;
} else {
str6 = "serverEventsType";
str7 = "eventsCompression";
lVar = null;
}
if (b8 != null) {
String str26 = str;
try {
JSONArray optJSONArray16 = b8.optJSONArray(str26);
String str27 = str2;
JSONObject b22 = b(b8, str27);
int a14 = a(b8, b4, "maxNumOfAdaptersToLoadOnStart", 1);
str2 = str27;
long optLong4 = b8.has("atim") ? b8.optLong("atim", 0L) : b4.has("atim") ? b4.optLong("atim", 0L) : 0L;
long j = optLong4 == 0 ? 10000L : optLong4;
int a15 = a(b8, b4, "delayLoadFailure", 3);
int a16 = a(b8, b4, "bannerInterval", 60);
if (b8.has("isOneFlow")) {
z3 = false;
optBoolean = b8.optBoolean("isOneFlow", false);
} else {
z3 = false;
if (b4.has("isOneFlow")) {
optBoolean = b4.optBoolean("isOneFlow", false);
} else {
z4 = false;
boolean optBoolean13 = b8.optBoolean("collectBiddingDataAsyncEnabled", z3);
long optLong5 = b8.optLong("collectBiddingDataTimeout", 3000L);
JSONObject mergeJsons3 = IronSourceUtils.mergeJsons(b22, b9);
boolean optBoolean14 = mergeJsons3.optBoolean("sendEventsToggle", false);
boolean optBoolean15 = mergeJsons3.optBoolean(str7, false);
int optInt15 = mergeJsons3.optInt("eventsCompressionLevel", -1);
String optString13 = mergeJsons3.optString("serverEventsURL", "");
str8 = str6;
String optString14 = mergeJsons3.optString(str8, "");
String str28 = str5;
int optInt16 = mergeJsons3.optInt(str28, -1);
String str29 = str4;
int optInt17 = mergeJsons3.optInt(str29, -1);
String str30 = str3;
int optInt18 = mergeJsons3.optInt(str30, 5000);
jSONObject3 = b4;
String str31 = str18;
optJSONArray = mergeJsons3.optJSONArray(str31);
if (optJSONArray == null) {
str = str26;
int[] iArr25 = new int[optJSONArray.length()];
str3 = str30;
str18 = str31;
for (int i14 = 0; i14 < optJSONArray.length(); i14++) {
iArr25[i14] = optJSONArray.optInt(i14);
}
iArr9 = iArr25;
} else {
str = str26;
str3 = str30;
str18 = str31;
iArr9 = null;
}
String str32 = str17;
optJSONArray2 = mergeJsons3.optJSONArray(str32);
if (optJSONArray2 == null) {
int[] iArr26 = new int[optJSONArray2.length()];
str17 = str32;
for (int i15 = 0; i15 < optJSONArray2.length(); i15++) {
iArr26[i15] = optJSONArray2.optInt(i15);
}
iArr10 = iArr26;
} else {
str17 = str32;
iArr10 = null;
}
optJSONArray3 = mergeJsons3.optJSONArray("triggerEvents");
if (optJSONArray3 == null) {
int[] iArr27 = new int[optJSONArray3.length()];
for (int i16 = 0; i16 < optJSONArray3.length(); i16++) {
iArr27[i16] = optJSONArray3.optInt(i16);
}
iArr11 = iArr27;
} else {
iArr11 = null;
}
optJSONArray4 = mergeJsons3.optJSONArray("nonConnectivityEvents");
if (optJSONArray4 == null) {
int[] iArr28 = new int[optJSONArray4.length()];
for (int i17 = 0; i17 < optJSONArray4.length(); i17++) {
iArr28[i17] = optJSONArray4.optInt(i17);
}
iArr12 = iArr28;
} else {
iArr12 = null;
}
com.ironsource.mediationsdk.model.e eVar3 = new com.ironsource.mediationsdk.model.e(false, optBoolean14, optBoolean15, optInt15, optString13, optString14, optInt16, optInt17, optInt18, iArr9, iArr10, iArr11, iArr12);
if (jSONObject8 == null) {
jSONObject4 = jSONObject8;
JSONObject b23 = b(jSONObject4, "banner");
if (b23 != null) {
str9 = str28;
str13 = str29;
cVar2 = new c(jSONObject4.optString("auctionData", ""), jSONObject4.optString("auctioneerURL", ""), jSONObject4.optString("extAuctioneerURL", ""), jSONObject4.optInt(IronSourceConstants.AUCTION_TRIALS, 2), jSONObject4.optInt("auctionSavedHistory", 15), jSONObject4.optLong("auctionTimeout", 10000L), b23.optBoolean(IronSourceConstants.EVENTS_PROGRAMMATIC, false), b23.optInt("minTimeBeforeFirstAuction", 2000), 0L, 0L, 0L, true, true, 0, jSONObject4.optBoolean("compressAuctionRequest", false), jSONObject4.optBoolean("compressAuctionResponse", false), b23.optBoolean("objectPerWaterfall", false), jSONObject4.optInt("encryptionVersion", 1), b23.optBoolean("shouldSendBannerBURLFromImpression", true));
} else {
str9 = str28;
str13 = str29;
cVar2 = new c();
}
} else {
str9 = str28;
str13 = str29;
jSONObject4 = jSONObject8;
cVar2 = new c();
}
com.ironsource.mediationsdk.model.h hVar2 = new com.ironsource.mediationsdk.model.h(a14, j, eVar3, a16, cVar2, a15, z4, optBoolean13, optLong5);
if (optJSONArray16 != null) {
int i18 = 0;
while (i18 < optJSONArray16.length()) {
JSONObject optJSONObject3 = optJSONArray16.optJSONObject(i18);
if (optJSONObject3 != null) {
jSONArray2 = optJSONArray16;
int optInt19 = optJSONObject3.optInt(ReportDBAdapter.ReportColumns.COLUMN_PLACEMENT_ID, -1);
String optString15 = optJSONObject3.optString("placementName", "");
str14 = str13;
jSONObject5 = jSONObject4;
boolean optBoolean16 = optJSONObject3.optBoolean("isDefault", false);
com.ironsource.mediationsdk.model.o a17 = a(optJSONObject3);
if (optInt19 >= 0 && !TextUtils.isEmpty(optString15)) {
iVar = new com.ironsource.mediationsdk.model.i(optInt19, optString15, optBoolean16, a17);
if (a17 != null) {
try {
j.a(this.bG, iVar);
} catch (Exception e3) {
e = e3;
exc = e;
exc.printStackTrace();
return;
}
}
if (iVar != null && iVar != null) {
hVar2.d.add(iVar);
if (hVar2.e != null && !iVar.isPlacementId(0)) {
}
hVar2.e = iVar;
}
i18++;
optJSONArray16 = jSONArray2;
jSONObject4 = jSONObject5;
str13 = str14;
}
} else {
jSONObject5 = jSONObject4;
jSONArray2 = optJSONArray16;
str14 = str13;
}
iVar = null;
if (iVar != null) {
hVar2.d.add(iVar);
if (hVar2.e != null) {
}
hVar2.e = iVar;
}
i18++;
optJSONArray16 = jSONArray2;
jSONObject4 = jSONObject5;
str13 = str14;
}
}
jSONObject8 = jSONObject4;
str4 = str13;
kVar2 = this;
hVar = hVar2;
}
}
z4 = optBoolean;
boolean optBoolean132 = b8.optBoolean("collectBiddingDataAsyncEnabled", z3);
long optLong52 = b8.optLong("collectBiddingDataTimeout", 3000L);
JSONObject mergeJsons32 = IronSourceUtils.mergeJsons(b22, b9);
boolean optBoolean142 = mergeJsons32.optBoolean("sendEventsToggle", false);
boolean optBoolean152 = mergeJsons32.optBoolean(str7, false);
int optInt152 = mergeJsons32.optInt("eventsCompressionLevel", -1);
String optString132 = mergeJsons32.optString("serverEventsURL", "");
str8 = str6;
String optString142 = mergeJsons32.optString(str8, "");
String str282 = str5;
int optInt162 = mergeJsons32.optInt(str282, -1);
String str292 = str4;
int optInt172 = mergeJsons32.optInt(str292, -1);
String str302 = str3;
int optInt182 = mergeJsons32.optInt(str302, 5000);
jSONObject3 = b4;
String str312 = str18;
optJSONArray = mergeJsons32.optJSONArray(str312);
if (optJSONArray == null) {
}
String str322 = str17;
optJSONArray2 = mergeJsons32.optJSONArray(str322);
if (optJSONArray2 == null) {
}
optJSONArray3 = mergeJsons32.optJSONArray("triggerEvents");
if (optJSONArray3 == null) {
}
optJSONArray4 = mergeJsons32.optJSONArray("nonConnectivityEvents");
if (optJSONArray4 == null) {
}
com.ironsource.mediationsdk.model.e eVar32 = new com.ironsource.mediationsdk.model.e(false, optBoolean142, optBoolean152, optInt152, optString132, optString142, optInt162, optInt172, optInt182, iArr9, iArr10, iArr11, iArr12);
if (jSONObject8 == null) {
}
com.ironsource.mediationsdk.model.h hVar22 = new com.ironsource.mediationsdk.model.h(a14, j, eVar32, a16, cVar2, a15, z4, optBoolean132, optLong52);
if (optJSONArray16 != null) {
}
jSONObject8 = jSONObject4;
str4 = str13;
kVar2 = this;
hVar = hVar22;
} catch (Exception e4) {
e = e4;
exc = e;
exc.printStackTrace();
return;
}
} else {
jSONObject3 = b4;
kVar2 = kVar;
str8 = str6;
str9 = str5;
hVar = null;
}
if (b7 != null) {
str12 = str2;
JSONObject mergeJsons4 = IronSourceUtils.mergeJsons(b(b7, str12), b9);
boolean optBoolean17 = mergeJsons4.optBoolean("sendEventsToggle", false);
boolean optBoolean18 = mergeJsons4.optBoolean(str7, false);
int optInt20 = mergeJsons4.optInt("eventsCompressionLevel", -1);
String optString16 = mergeJsons4.optString("serverEventsURL", "");
String optString17 = mergeJsons4.optString(str8, "");
int optInt21 = mergeJsons4.optInt(str9, -1);
int optInt22 = mergeJsons4.optInt(str4, -1);
int optInt23 = mergeJsons4.optInt(str3, 5000);
str11 = str18;
JSONArray optJSONArray17 = mergeJsons4.optJSONArray(str11);
if (optJSONArray17 != null) {
int[] iArr29 = new int[optJSONArray17.length()];
for (int i19 = 0; i19 < optJSONArray17.length(); i19++) {
iArr29[i19] = optJSONArray17.optInt(i19);
}
iArr5 = iArr29;
} else {
iArr5 = null;
}
str10 = str17;
JSONArray optJSONArray18 = mergeJsons4.optJSONArray(str10);
if (optJSONArray18 != null) {
int[] iArr30 = new int[optJSONArray18.length()];
for (int i20 = 0; i20 < optJSONArray18.length(); i20++) {
iArr30[i20] = optJSONArray18.optInt(i20);
}
iArr6 = iArr30;
} else {
iArr6 = null;
}
JSONArray optJSONArray19 = mergeJsons4.optJSONArray("triggerEvents");
if (optJSONArray19 != null) {
int[] iArr31 = new int[optJSONArray19.length()];
for (int i21 = 0; i21 < optJSONArray19.length(); i21++) {
iArr31[i21] = optJSONArray19.optInt(i21);
}
iArr7 = iArr31;
} else {
iArr7 = null;
}
JSONArray optJSONArray20 = mergeJsons4.optJSONArray("nonConnectivityEvents");
if (optJSONArray20 != null) {
int[] iArr32 = new int[optJSONArray20.length()];
for (int i22 = 0; i22 < optJSONArray20.length(); i22++) {
iArr32[i22] = optJSONArray20.optInt(i22);
}
iArr8 = iArr32;
} else {
iArr8 = null;
}
com.ironsource.mediationsdk.model.m mVar2 = new com.ironsource.mediationsdk.model.m(new com.ironsource.mediationsdk.model.e(false, optBoolean17, optBoolean18, optInt20, optString16, optString17, optInt21, optInt22, optInt23, iArr5, iArr6, iArr7, iArr8));
mVar2.d = b7;
JSONArray optJSONArray21 = b7.optJSONArray(str);
if (optJSONArray21 != null) {
int i23 = 0;
while (i23 < optJSONArray21.length()) {
JSONObject optJSONObject4 = optJSONArray21.optJSONObject(i23);
if (optJSONObject4 != null) {
int optInt24 = optJSONObject4.optInt(ReportDBAdapter.ReportColumns.COLUMN_PLACEMENT_ID, -1);
String optString18 = optJSONObject4.optString("placementName", "");
jSONArray = optJSONArray21;
boolean optBoolean19 = optJSONObject4.optBoolean("isDefault", false);
if (optInt24 >= 0 && !TextUtils.isEmpty(optString18)) {
nVar = new com.ironsource.mediationsdk.model.n(optInt24, optString18, optBoolean19);
if (nVar != null && nVar != null) {
mVar2.a.add(nVar);
if (mVar2.b != null && !nVar.isPlacementId(0)) {
}
mVar2.b = nVar;
}
i23++;
optJSONArray21 = jSONArray;
}
} else {
jSONArray = optJSONArray21;
}
nVar = null;
if (nVar != null) {
mVar2.a.add(nVar);
if (mVar2.b != null) {
}
mVar2.b = nVar;
}
i23++;
optJSONArray21 = jSONArray;
}
}
mVar = mVar2;
} else {
str10 = str17;
str11 = str18;
str12 = str2;
mVar = null;
}
o oVar = new o();
if (b11 != null) {
JSONArray optJSONArray22 = b11.optJSONArray("optInKeys");
if (optJSONArray22 != null) {
for (int i24 = 0; i24 < optJSONArray22.length(); i24++) {
String optString19 = optJSONArray22.optString(i24);
if (!TextUtils.isEmpty(optString19)) {
oVar.a.add(optString19);
}
}
}
JSONObject optJSONObject5 = b11.optJSONObject("tokenGenericParams");
if (optJSONObject5 != null) {
oVar.c = optJSONObject5;
}
oVar.d = b11.optBoolean("oneToken", false);
oVar.e = b11.optBoolean("compressToken", true);
}
i iVar2 = new i();
if (b17 != null) {
String optString20 = b17.optString("pixelEventsUrl", "https://outcome-ssp.supersonicads.com/mediation?adUnit=3");
z2 = b17.optBoolean("pixelEventsEnabled", true);
iVar2.a(optString20);
} else {
z2 = true;
}
iVar2.a(z2);
if (z2) {
iVar2.a(a(b9, str11));
iVar2.b(a(b9, str10));
iVar2.b(b9.optBoolean(str7, false));
iVar2.a(b9.optInt("eventsCompressionLevel", -1));
}
com.ironsource.mediationsdk.model.g gVar = new com.ironsource.mediationsdk.model.g(b10.optInt("server", 3), b10.optInt("publisher", 3), b10.optInt("console", 3), b10.optBoolean("shouldSendPublisherLogsOnUIThread", false));
com.ironsource.mediationsdk.model.d dVar = new com.ironsource.mediationsdk.model.d();
if (jSONObject2 != null) {
JSONObject jSONObject9 = jSONObject2;
dVar.a = jSONObject9.optBoolean("enabled", false);
dVar.c = jSONObject9.optString("reporterURL", "");
dVar.d = jSONObject9.optString("reporterKeyword", "");
dVar.e = jSONObject9.optBoolean("includeANR", false);
dVar.f = jSONObject9.optInt("timeout", 5000);
dVar.g = jSONObject9.optBoolean("setIgnoreDebugger", false);
JSONArray optJSONArray23 = jSONObject9.optJSONArray("keysToInclude");
if (optJSONArray23 != null) {
for (int i25 = 0; i25 < optJSONArray23.length(); i25++) {
String optString21 = optJSONArray23.optString(i25);
if (!TextUtils.isEmpty(optString21)) {
dVar.b.add(optString21);
}
}
}
}
if (jSONObject != null) {
JSONObject jSONObject10 = jSONObject;
tVar = new t(jSONObject10.optString("name", ""), jSONObject10.optString("id", "-1"), jSONObject10.optJSONObject(OSNotificationFormatHelper.PAYLOAD_OS_ROOT_CUSTOM));
} else {
tVar = null;
}
b bVar = new b();
if (b15 != null) {
bVar = new b(b15.optBoolean("isExternalArmEventsEnabled", true), b15.optString("externalArmEventsUrl", "https://outcome-arm-ext-med-ext.sonic-us.supersonicads.com/aemData"), b15.optBoolean("sid", true), b15.optBoolean("radvid", false), b15.optInt("uaeh", 0));
}
b bVar2 = bVar;
com.ironsource.mediationsdk.model.f fVar = new com.ironsource.mediationsdk.model.f();
if (b16 != null) {
JSONObject optJSONObject6 = b16.optJSONObject("mediationTypes");
Map hashMap = new HashMap();
if (optJSONObject6 != null) {
hashMap = IronSourceUtils.parseJsonToStringMap(optJSONObject6);
}
b16.optBoolean("compressExternalToken", false);
fVar = new com.ironsource.mediationsdk.model.f(hashMap);
}
com.ironsource.mediationsdk.model.c cVar5 = new com.ironsource.mediationsdk.model.c(gVar, tVar, oVar, jSONObject3.optBoolean("integration", false), dVar, bVar2, fVar, iVar2, jSONObject8 != null ? new com.ironsource.mediationsdk.model.b(jSONObject8.optString("auctionData")) : new com.ironsource.mediationsdk.model.b());
u uVar = new u();
JSONObject b24 = b(b2, "testSuite");
if (b24 != null) {
uVar.a(b24.optString("controllerUrl"));
}
kVar2.c = new com.ironsource.mediationsdk.model.j(sVar, lVar, mVar, hVar, cVar5, uVar);
JSONObject b25 = b(b9, IronSourceConstants.EVENTS_GENERIC_PARAMS);
if (b25 != null && (b = b(b25, str12)) != null) {
b25.remove(str12);
Map<String, String> parseJsonToStringMap = IronSourceUtils.parseJsonToStringMap(b);
com.ironsource.mediationsdk.events.i.d().b(parseJsonToStringMap);
com.ironsource.mediationsdk.events.e.d().b(parseJsonToStringMap);
}
if (b25 != null) {
Map<String, String> parseJsonToStringMap2 = IronSourceUtils.parseJsonToStringMap(b25);
com.ironsource.mediationsdk.events.i.d().a(parseJsonToStringMap2);
com.ironsource.mediationsdk.events.e.d().a(parseJsonToStringMap2);
}
} catch (Exception e5) {
e = e5;
}
}
public final C1344u a() {
return new C1344u(this.bE, this.bF);
}
public final boolean b() {
JSONObject jSONObject = this.d;
return (((((jSONObject != null) && !jSONObject.has("error")) && this.a != null) && this.b != null) && this.c != null) && f();
}
public final boolean c() {
return !TextUtils.isEmpty(this.c.f.a());
}
public final boolean d() {
return this.c.e.c.d;
}
public final String toString() {
JSONObject jSONObject = new JSONObject();
try {
jSONObject.put("appKey", this.bE);
jSONObject.put(DataKeys.USER_ID, this.bF);
jSONObject.put("response", this.d);
} catch (JSONException e) {
e.printStackTrace();
}
return jSONObject.toString();
}
}