- Added realracing3-community.apk (71.57 MB) - Removed 32-bit support (armeabi-v7a) - Only includes arm64-v8a libraries - Decompiled source code included - Added README-community.md with analysis
56 lines
2.1 KiB
Java
56 lines
2.1 KiB
Java
package com.mbridge.msdk.playercommon.exoplayer2.util;
|
|
|
|
import org.xmlpull.v1.XmlPullParser;
|
|
import org.xmlpull.v1.XmlPullParserException;
|
|
|
|
/* loaded from: classes4.dex */
|
|
public final class XmlPullParserUtil {
|
|
private XmlPullParserUtil() {
|
|
}
|
|
|
|
public static boolean isEndTag(XmlPullParser xmlPullParser, String str) throws XmlPullParserException {
|
|
return isEndTag(xmlPullParser) && xmlPullParser.getName().equals(str);
|
|
}
|
|
|
|
public static boolean isEndTag(XmlPullParser xmlPullParser) throws XmlPullParserException {
|
|
return xmlPullParser.getEventType() == 3;
|
|
}
|
|
|
|
public static boolean isStartTag(XmlPullParser xmlPullParser, String str) throws XmlPullParserException {
|
|
return isStartTag(xmlPullParser) && xmlPullParser.getName().equals(str);
|
|
}
|
|
|
|
public static boolean isStartTag(XmlPullParser xmlPullParser) throws XmlPullParserException {
|
|
return xmlPullParser.getEventType() == 2;
|
|
}
|
|
|
|
public static boolean isStartTagIgnorePrefix(XmlPullParser xmlPullParser, String str) throws XmlPullParserException {
|
|
return isStartTag(xmlPullParser) && stripPrefix(xmlPullParser.getName()).equals(str);
|
|
}
|
|
|
|
public static String getAttributeValue(XmlPullParser xmlPullParser, String str) {
|
|
int attributeCount = xmlPullParser.getAttributeCount();
|
|
for (int i = 0; i < attributeCount; i++) {
|
|
if (xmlPullParser.getAttributeName(i).equals(str)) {
|
|
return xmlPullParser.getAttributeValue(i);
|
|
}
|
|
}
|
|
return null;
|
|
}
|
|
|
|
public static String getAttributeValueIgnorePrefix(XmlPullParser xmlPullParser, String str) {
|
|
int attributeCount = xmlPullParser.getAttributeCount();
|
|
for (int i = 0; i < attributeCount; i++) {
|
|
if (stripPrefix(xmlPullParser.getAttributeName(i)).equals(str)) {
|
|
return xmlPullParser.getAttributeValue(i);
|
|
}
|
|
}
|
|
return null;
|
|
}
|
|
|
|
private static String stripPrefix(String str) {
|
|
int indexOf = str.indexOf(58);
|
|
return indexOf == -1 ? str : str.substring(indexOf + 1);
|
|
}
|
|
}
|