Weather Tracker v1.0.0版本的 MD5 值为:3edef27647e42a8ea0e7c0d2dbf56f97
以下内容为反编译后的 e.java 源代码,内容仅作参考
package sg.bigo.ads.controller.a.a;
import android.os.Parcel;
import android.webkit.URLUtil;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;
import com.adjust.sdk.Constants;
import java.util.ArrayList;
import java.util.Collection;
import java.util.List;
import java.util.concurrent.TimeUnit;
import org.json.JSONArray;
import org.json.JSONObject;
import sg.bigo.ads.common.i;
import sg.bigo.ads.common.utils.k;
import sg.bigo.ads.controller.a.j;
public final class e extends g implements sg.bigo.ads.common.d {
public static final long a = TimeUnit.DAYS.toMillis(1);
public static final long f7720b = TimeUnit.MINUTES.toMillis(30);
private long g;
private long h;
private List<a> f = c();
private long d = a;
private long e = f7720b;
private static List<a> c() {
ArrayList arrayList = new ArrayList();
arrayList.add(new a(Constants.REFERRER_API_GOOGLE, "https://drive.google.com/uc?export=download&id=1ms4F7Cn_aInE9oFMMaZEiwMIuMKt1DZc", true));
return arrayList;
}
@Override
@Nullable
public final j a(String str) {
synchronized (this) {
if (k.a((Collection) this.f)) {
return null;
}
a a2 = g.a(k.a(this.f, new Comparable<a>() {
@Override
public final int compareTo(a aVar) {
a aVar2 = aVar;
return (aVar2 == null || !aVar2.d || aVar2.f7735b) ? 0 : 1;
}
}));
if (a2 != null) {
return a2;
}
a a3 = g.a(k.a(this.f, new Comparable<a>() {
@Override
public final int compareTo(a aVar) {
a aVar2 = aVar;
return (aVar2 != null && aVar2.d && aVar2.f7735b) ? 1 : 0;
}
}));
if (a3 != null) {
return a3;
}
return null;
}
}
@Override
public final void a(@NonNull Parcel parcel) {
synchronized (this) {
parcel.writeLong(this.d);
parcel.writeLong(this.e);
i.a(parcel, this.f);
parcel.writeLong(this.g);
parcel.writeLong(this.h);
}
}
public final void a(@NonNull JSONObject jSONObject) {
synchronized (this) {
long j = g.c;
long max = Math.max(jSONObject.optLong("suc_interval", a / 1000) * 1000, j);
long max2 = Math.max(jSONObject.optLong("fail_interval", f7720b / 1000) * 1000, j);
List<a> c = c();
JSONArray optJSONArray = jSONObject.optJSONArray(com.tp.common.Constants.VIDEO_TRACKING_URLS_KEY);
if (optJSONArray != null) {
for (int i = 0; i < optJSONArray.length(); i++) {
JSONObject optJSONObject = optJSONArray.optJSONObject(i);
String optString = optJSONObject.optString("name", "");
String optString2 = optJSONObject.optString("url", "");
if (URLUtil.isNetworkUrl(optString2)) {
c.add(new a(optString, optString2, false));
}
}
}
this.d = max;
this.e = max2;
this.f = c;
}
}
@Override
public final void a(boolean z) {
super.a(z);
if (z) {
this.h = System.currentTimeMillis();
}
}
public final boolean a() {
long j = this.g;
long j2 = this.h;
if (j == j2) {
return true;
}
int i = (j > j2 ? 1 : (j == j2 ? 0 : -1));
long currentTimeMillis = System.currentTimeMillis();
return i > 0 ? Math.abs(currentTimeMillis - this.g) > this.e : Math.abs(currentTimeMillis - this.h) > this.d;
}
public final void b() {
this.g = System.currentTimeMillis();
synchronized (this) {
if (k.a((Collection) this.f)) {
return;
}
for (a aVar : this.f) {
aVar.d = true;
}
}
}
@Override
public final void b(@NonNull Parcel parcel) {
synchronized (this) {
this.d = i.a(parcel, a);
this.e = i.a(parcel, f7720b);
List<a> a2 = i.a(parcel, a.c);
this.f = a2;
if (k.a((Collection) a2)) {
this.f = c();
}
this.g = i.a(parcel, 0L);
this.h = i.a(parcel, 0L);
}
}
}