package com.ironsource; import kotlin.jvm.internal.Intrinsics; import org.json.JSONObject; /* loaded from: classes2.dex */ public final class n8 { private final op a; private final gi b; private final m6 c; private final kl d; private final s3 e; public n8(JSONObject configurations) { Intrinsics.checkNotNullParameter(configurations, "configurations"); this.a = new op(a(configurations, "rewarded")); this.b = new gi(a(configurations, "interstitial")); this.c = new m6(a(configurations, "banner")); this.d = new kl(a(configurations, "nativeAd")); JSONObject optJSONObject = configurations.optJSONObject("application"); this.e = new s3(optJSONObject == null ? new JSONObject() : optJSONObject); } private final JSONObject a(JSONObject jSONObject, String str) { JSONObject optJSONObject = jSONObject.optJSONObject("adFormats"); JSONObject optJSONObject2 = optJSONObject != null ? optJSONObject.optJSONObject(str) : null; return optJSONObject2 == null ? new JSONObject() : optJSONObject2; } public final s3 a() { return this.e; } public final m6 b() { return this.c; } public final gi c() { return this.b; } public final kl d() { return this.d; } public final op e() { return this.a; } }