what-the-bank/sources/o/liJ.java

109 lines
4.6 KiB
Java

package o;
import android.content.Context;
import android.util.Xml;
import androidx.constraintlayout.widget.ConstraintLayout;
import java.io.IOException;
import java.lang.reflect.Constructor;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.Iterator;
import org.xmlpull.v1.XmlPullParser;
import org.xmlpull.v1.XmlPullParserException;
/* loaded from: classes.dex */
public final class liJ {
private static HashMap<String, Constructor<? extends AbstractC0558JiG>> b;
HashMap<Integer, ArrayList<AbstractC0558JiG>> c = new HashMap<>();
static {
HashMap<String, Constructor<? extends AbstractC0558JiG>> hashMap = new HashMap<>();
b = hashMap;
try {
hashMap.put("KeyAttribute", C11446efW.class.getConstructor(new Class[0]));
b.put("KeyPosition", LHE.class.getConstructor(new Class[0]));
b.put("KeyCycle", C14118fnE.class.getConstructor(new Class[0]));
b.put("KeyTimeCycle", QQt.class.getConstructor(new Class[0]));
b.put("KeyTrigger", AZC.class.getConstructor(new Class[0]));
} catch (NoSuchMethodException unused) {
}
}
public final void b(AbstractC0558JiG abstractC0558JiG) {
if (!this.c.containsKey(Integer.valueOf(abstractC0558JiG.a))) {
this.c.put(Integer.valueOf(abstractC0558JiG.a), new ArrayList<>());
}
ArrayList<AbstractC0558JiG> arrayList = this.c.get(Integer.valueOf(abstractC0558JiG.a));
if (arrayList != null) {
arrayList.add(abstractC0558JiG);
}
}
public liJ() {
}
public liJ(Context context, XmlPullParser xmlPullParser) {
try {
int eventType = xmlPullParser.getEventType();
AbstractC0558JiG abstractC0558JiG = null;
while (eventType != 1) {
if (eventType == 2) {
String name = xmlPullParser.getName();
if (b.containsKey(name)) {
try {
Constructor<? extends AbstractC0558JiG> constructor = b.get(name);
if (constructor != null) {
AbstractC0558JiG newInstance = constructor.newInstance(new Object[0]);
try {
newInstance.kC_(context, Xml.asAttributeSet(xmlPullParser));
b(newInstance);
} catch (Exception unused) {
}
abstractC0558JiG = newInstance;
} else {
StringBuilder sb = new StringBuilder();
sb.append("Keymaker for ");
sb.append(name);
sb.append(" not found");
throw new NullPointerException(sb.toString());
break;
}
} catch (Exception unused2) {
continue;
}
} else if (name.equalsIgnoreCase("CustomAttribute")) {
if (abstractC0558JiG != null && abstractC0558JiG.d != null) {
Prc.a(context, xmlPullParser, abstractC0558JiG.d);
}
} else if (name.equalsIgnoreCase("CustomMethod") && abstractC0558JiG != null && abstractC0558JiG.d != null) {
Prc.a(context, xmlPullParser, abstractC0558JiG.d);
}
} else if (eventType == 3 && "KeyFrameSet".equals(xmlPullParser.getName())) {
return;
}
eventType = xmlPullParser.next();
}
} catch (IOException | XmlPullParserException unused3) {
}
}
public final void d(C15870jKt c15870jKt) {
ArrayList<AbstractC0558JiG> arrayList = this.c.get(Integer.valueOf(c15870jKt.i));
if (arrayList != null) {
c15870jKt.l.addAll(arrayList);
}
ArrayList<AbstractC0558JiG> arrayList2 = this.c.get(-1);
if (arrayList2 != null) {
Iterator<AbstractC0558JiG> it = arrayList2.iterator();
while (it.hasNext()) {
AbstractC0558JiG next = it.next();
String str = ((ConstraintLayout.Sts) c15870jKt.x.getLayoutParams()).f6383o;
String str2 = next.b;
if (str2 != null && str != null && str.matches(str2)) {
c15870jKt.l.add(next);
}
}
}
}
}