- 28,932 files - Full Java source code - Smali files - Resources Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
82 lines
3.0 KiB
Java
82 lines
3.0 KiB
Java
package com.applovin.impl;
|
|
|
|
import com.applovin.impl.sdk.utils.JsonUtils;
|
|
import com.applovin.impl.vi;
|
|
import com.facebook.devicerequests.internal.DeviceRequestsHelper;
|
|
import java.util.Map;
|
|
import org.json.JSONArray;
|
|
import org.json.JSONObject;
|
|
|
|
/* loaded from: classes.dex */
|
|
class zl extends yl {
|
|
@Override // java.lang.Runnable
|
|
public void run() {
|
|
if (com.applovin.impl.sdk.n.a()) {
|
|
this.c.d(this.b, "Submitting user data...");
|
|
}
|
|
Map c = e4.c(this.a);
|
|
JSONObject jSONObject = new JSONObject();
|
|
c(jSONObject);
|
|
b(jSONObject);
|
|
if (((Boolean) this.a.a(sj.H5)).booleanValue() || ((Boolean) this.a.a(sj.B5)).booleanValue()) {
|
|
JsonUtils.putAll(jSONObject, (Map<String, ?>) c);
|
|
c = null;
|
|
}
|
|
a(c, jSONObject);
|
|
}
|
|
|
|
public zl(com.applovin.impl.sdk.j jVar) {
|
|
super("TaskApiSubmitData", jVar);
|
|
}
|
|
|
|
private void c(JSONObject jSONObject) {
|
|
com.applovin.impl.sdk.k y = this.a.y();
|
|
Map l = y.l();
|
|
yp.a("platform", "type", l);
|
|
yp.a("api_level", "sdk_version", l);
|
|
JsonUtils.putObject(jSONObject, DeviceRequestsHelper.DEVICE_INFO_PARAM, new JSONObject(l));
|
|
Map A = y.A();
|
|
yp.a("sdk_version", "applovin_sdk_version", A);
|
|
yp.a("ia", "installed_at", A);
|
|
JsonUtils.putObject(jSONObject, "app_info", new JSONObject(A));
|
|
}
|
|
|
|
/* JADX INFO: Access modifiers changed from: private */
|
|
public void a(JSONObject jSONObject) {
|
|
JSONObject jSONObject2 = JsonUtils.getJSONObject(JsonUtils.getJSONArray(jSONObject, "results", new JSONArray()), 0, new JSONObject());
|
|
this.a.h0().a(sj.g, JsonUtils.getString(jSONObject2, "device_id", ""));
|
|
this.a.h0().a(sj.k, JsonUtils.getString(jSONObject2, "device_token", ""));
|
|
e4.a(jSONObject2, this.a);
|
|
this.a.D().b();
|
|
}
|
|
|
|
private void b(JSONObject jSONObject) {
|
|
if (((Boolean) this.a.a(sj.P4)).booleanValue()) {
|
|
JsonUtils.putJSONObjectIfValid(jSONObject, "stats", this.a.D().c());
|
|
}
|
|
}
|
|
|
|
public class a extends dn {
|
|
public a(com.applovin.impl.sdk.network.a aVar, com.applovin.impl.sdk.j jVar) {
|
|
super(aVar, jVar);
|
|
}
|
|
|
|
@Override // com.applovin.impl.dn, com.applovin.impl.d4.e
|
|
public void a(String str, int i, String str2, JSONObject jSONObject) {
|
|
e4.a(i, this.a);
|
|
}
|
|
|
|
@Override // com.applovin.impl.dn, com.applovin.impl.d4.e
|
|
public void a(String str, JSONObject jSONObject, int i) {
|
|
zl.this.a(jSONObject);
|
|
}
|
|
}
|
|
|
|
private void a(Map map, JSONObject jSONObject) {
|
|
a aVar = new a(com.applovin.impl.sdk.network.a.a(this.a).b(e4.b("2.0/device", this.a)).a(e4.a("2.0/device", this.a)).b(map).a(jSONObject).c("POST").b(((Boolean) this.a.a(sj.O5)).booleanValue()).a((Object) new JSONObject()).a(((Integer) this.a.a(sj.r3)).intValue()).a(vi.a.a(((Integer) this.a.a(sj.z5)).intValue())).a(), this.a);
|
|
aVar.c(sj.N0);
|
|
aVar.b(sj.O0);
|
|
this.a.j0().a(aVar);
|
|
}
|
|
}
|