- 28,932 files - Full Java source code - Smali files - Resources Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
69 lines
2.2 KiB
Java
69 lines
2.2 KiB
Java
package com.ironsource.sdk.controller;
|
|
|
|
import android.content.Context;
|
|
import com.ironsource.ce;
|
|
import com.ironsource.el;
|
|
import com.ironsource.mj;
|
|
import com.ironsource.sdk.utils.Logger;
|
|
import com.ironsource.sdk.utils.SDKUtils;
|
|
import com.ironsource.v8;
|
|
import com.ironsource.wp;
|
|
import org.json.JSONException;
|
|
import org.json.JSONObject;
|
|
|
|
/* loaded from: classes4.dex */
|
|
public class i {
|
|
private static final String c = "i";
|
|
private static final String d = "getDeviceData";
|
|
private static final String e = "deviceDataFunction";
|
|
private static final String f = "deviceDataParams";
|
|
private static final String g = "success";
|
|
private static final String h = "fail";
|
|
private Context a;
|
|
private final ce b = el.N().f();
|
|
|
|
public static class b {
|
|
String a;
|
|
JSONObject b;
|
|
String c;
|
|
String d;
|
|
|
|
private b() {
|
|
}
|
|
}
|
|
|
|
public i(Context context) {
|
|
this.a = context;
|
|
}
|
|
|
|
private b a(String str) throws JSONException {
|
|
JSONObject jSONObject = new JSONObject(str);
|
|
b bVar = new b();
|
|
bVar.a = jSONObject.optString(e);
|
|
bVar.b = jSONObject.optJSONObject(f);
|
|
bVar.c = jSONObject.optString("success");
|
|
bVar.d = jSONObject.optString("fail");
|
|
return bVar;
|
|
}
|
|
|
|
private wp a() {
|
|
wp wpVar = new wp();
|
|
wpVar.b(SDKUtils.encodeString(v8.i.i0), SDKUtils.encodeString(String.valueOf(this.b.c())));
|
|
wpVar.b(SDKUtils.encodeString(v8.i.j0), SDKUtils.encodeString(String.valueOf(this.b.h(this.a))));
|
|
wpVar.b(SDKUtils.encodeString(v8.i.k0), SDKUtils.encodeString(String.valueOf(this.b.G(this.a))));
|
|
wpVar.b(SDKUtils.encodeString(v8.i.l0), SDKUtils.encodeString(String.valueOf(this.b.l(this.a))));
|
|
wpVar.b(SDKUtils.encodeString(v8.i.m0), SDKUtils.encodeString(String.valueOf(this.b.c(this.a))));
|
|
wpVar.b(SDKUtils.encodeString(v8.i.n0), SDKUtils.encodeString(String.valueOf(this.b.d(this.a))));
|
|
return wpVar;
|
|
}
|
|
|
|
public void a(String str, mj mjVar) throws Exception {
|
|
b a2 = a(str);
|
|
if (d.equals(a2.a)) {
|
|
mjVar.a(true, a2.c, a());
|
|
return;
|
|
}
|
|
Logger.i(c, "unhandled API request " + str);
|
|
}
|
|
}
|