52 lines
1.7 KiB
Java
52 lines
1.7 KiB
Java
package com.google.android.gms.internal.measurement;
|
|
|
|
import java.util.Collections;
|
|
import java.util.Iterator;
|
|
import java.util.TreeMap;
|
|
|
|
/* loaded from: classes.dex */
|
|
public final class zzz {
|
|
final TreeMap<Integer, zzao> zza = new TreeMap<>();
|
|
final TreeMap<Integer, zzao> zzb = new TreeMap<>();
|
|
|
|
private static final int zzc(zzg zzgVar, zzao zzaoVar, zzap zzapVar) {
|
|
zzap zza = zzaoVar.zza(zzgVar, Collections.singletonList(zzapVar));
|
|
if (zza instanceof zzah) {
|
|
return zzh.zzb(zza.zzh().doubleValue());
|
|
}
|
|
return -1;
|
|
}
|
|
|
|
public final void zza(String str, int i, zzao zzaoVar, String str2) {
|
|
TreeMap<Integer, zzao> treeMap;
|
|
if ("create".equals(str2)) {
|
|
treeMap = this.zzb;
|
|
} else {
|
|
if (!"edit".equals(str2)) {
|
|
String valueOf = String.valueOf(str2);
|
|
throw new IllegalStateException(valueOf.length() != 0 ? "Unknown callback type: ".concat(valueOf) : new String("Unknown callback type: "));
|
|
}
|
|
treeMap = this.zza;
|
|
}
|
|
if (treeMap.containsKey(Integer.valueOf(i))) {
|
|
i = treeMap.lastKey().intValue() + 1;
|
|
}
|
|
treeMap.put(Integer.valueOf(i), zzaoVar);
|
|
}
|
|
|
|
public final void zzb(zzg zzgVar, zzab zzabVar) {
|
|
zzl zzlVar = new zzl(zzabVar);
|
|
for (Integer num : this.zza.keySet()) {
|
|
zzaa clone = zzabVar.zzb().clone();
|
|
int zzc = zzc(zzgVar, this.zza.get(num), zzlVar);
|
|
if (zzc == 2 || zzc == -1) {
|
|
zzabVar.zzf(clone);
|
|
}
|
|
}
|
|
Iterator<Integer> it = this.zzb.keySet().iterator();
|
|
while (it.hasNext()) {
|
|
zzc(zzgVar, this.zzb.get(it.next()), zzlVar);
|
|
}
|
|
}
|
|
}
|