package com.ironsource;

import com.ironsource.mediationsdk.impressionData.ImpressionData;
import java.util.ArrayList;
import java.util.List;
import org.json.JSONException;
import org.json.JSONObject;
/* loaded from: classes7.dex */
public class j5 {
    public static final String A = "nurl";
    public static final String o = "adMarkup";
    public static final String p = "instance";
    public static final String q = "adData";
    public static final String r = "price";
    public static final String s = "serverData";
    public static final String t = "loadTimeout";
    public static final String u = "order";
    public static final String v = "show";
    public static final String w = "price";
    public static final String x = "notifications";
    public static final String y = "burl";
    public static final String z = "lurl";

    /* renamed from: a  reason: collision with root package name */
    private String f2456a;
    private String b;
    private JSONObject c;
    private String d;
    private Integer e;
    private int f;
    private int g;
    private int h;
    private final List<String> i;
    private final List<String> j;
    private final List<String> k;
    private ImpressionData l;
    private xk m;
    private boolean n;

    public j5(String str) {
        this.f2456a = null;
        this.b = "";
        this.c = null;
        this.d = "";
        this.e = null;
        this.f = -1;
        this.g = -1;
        this.h = -1;
        this.i = new ArrayList();
        this.j = new ArrayList();
        this.k = new ArrayList();
        this.l = null;
        this.m = null;
        this.n = true;
        this.f2456a = str;
    }

    public j5(JSONObject jSONObject) {
        this(jSONObject, -1, null);
    }

    /* JADX WARN: Removed duplicated region for block: B:15:0x0083 A[Catch: Exception -> 0x00e3, TryCatch #0 {Exception -> 0x00e3, blocks: (B:3:0x0044, B:5:0x004a, B:6:0x0050, B:8:0x0056, B:12:0x0069, B:13:0x006b, B:15:0x0083, B:16:0x0096, B:18:0x00b4, B:20:0x00be, B:22:0x00c6, B:23:0x00d5, B:9:0x005b, B:11:0x0061), top: B:28:0x0044 }] */
    /* JADX WARN: Removed duplicated region for block: B:18:0x00b4 A[Catch: Exception -> 0x00e3, TryCatch #0 {Exception -> 0x00e3, blocks: (B:3:0x0044, B:5:0x004a, B:6:0x0050, B:8:0x0056, B:12:0x0069, B:13:0x006b, B:15:0x0083, B:16:0x0096, B:18:0x00b4, B:20:0x00be, B:22:0x00c6, B:23:0x00d5, B:9:0x005b, B:11:0x0061), top: B:28:0x0044 }] */
    /* JADX WARN: Removed duplicated region for block: B:19:0x00bd  */
    /* JADX WARN: Removed duplicated region for block: B:22:0x00c6 A[Catch: Exception -> 0x00e3, TryCatch #0 {Exception -> 0x00e3, blocks: (B:3:0x0044, B:5:0x004a, B:6:0x0050, B:8:0x0056, B:12:0x0069, B:13:0x006b, B:15:0x0083, B:16:0x0096, B:18:0x00b4, B:20:0x00be, B:22:0x00c6, B:23:0x00d5, B:9:0x005b, B:11:0x0061), top: B:28:0x0044 }] */
    /*
        Code decompiled incorrectly, please refer to instructions dump.
        To view partially-correct add '--show-bad-code' argument
    */
    public j5(org.json.JSONObject r16, int r17, org.json.JSONObject r18) {
        /*
            Method dump skipped, instructions count: 262
            To view this dump add '--comments-level debug' option
        */
        throw new UnsupportedOperationException("Method not decompiled: com.ironsource.j5.<init>(org.json.JSONObject, int, org.json.JSONObject):void");
    }

    private void a(JSONObject jSONObject, int i) {
        this.f = i;
        this.g = i;
        this.h = i;
        if (jSONObject != null) {
            int optInt = jSONObject.optInt(v, i);
            this.g = optInt;
            this.h = jSONObject.optInt("price", optInt);
        }
    }

    private void a(JSONObject jSONObject, String str, List<String> list) throws JSONException {
        if (jSONObject.has(str)) {
            list.addAll(jj.b(jSONObject.getJSONArray(str)));
        }
    }

    public ImpressionData a(String str) {
        ImpressionData impressionData = this.l;
        if (impressionData != null) {
            ImpressionData impressionData2 = new ImpressionData(impressionData);
            impressionData2.replaceMacroForPlacementWithValue(com.ironsource.mediationsdk.d.r, str);
            return impressionData2;
        }
        return null;
    }

    public JSONObject a() {
        return this.c;
    }

    public List<String> b() {
        return this.i;
    }

    public String c() {
        return this.f2456a;
    }

    public xk d() {
        return this.m;
    }

    public int e() {
        return this.f;
    }

    public Integer f() {
        return this.e;
    }

    public List<String> g() {
        return this.j;
    }

    public List<String> h() {
        return this.k;
    }

    public String i() {
        return this.d;
    }

    public int j() {
        return this.h;
    }

    public String k() {
        return this.b;
    }

    public int l() {
        return this.g;
    }

    public boolean m() {
        return this.n;
    }
}
