CryptoMessage v1.3.2版本的 MD5 值为:66c611ce56a11450659dc23697562928
以下内容为反编译后的 UserTuneProvider.java 源代码,内容仅作参考
package org.jivesoftware.smackx.usertune.provider;
import java.io.IOException;
import org.jivesoftware.smack.packet.XmlEnvironment;
import org.jivesoftware.smack.parsing.SmackParsingException;
import org.jivesoftware.smack.provider.ExtensionElementProvider;
import org.jivesoftware.smack.xml.XmlPullParser;
import org.jivesoftware.smack.xml.XmlPullParserException;
import org.jivesoftware.smackx.jingle_filetransfer.element.Range;
import org.jivesoftware.smackx.usertune.element.UserTuneElement;
public class UserTuneProvider extends ExtensionElementProvider<UserTuneElement> {
public static final UserTuneProvider INSTANCE = new UserTuneProvider();
@Override
public UserTuneElement parse(XmlPullParser xmlPullParser, int i, XmlEnvironment xmlEnvironment) throws XmlPullParserException, IOException, SmackParsingException {
UserTuneElement.Builder builder = UserTuneElement.getBuilder();
XmlPullParser.TagEvent nextTag = xmlPullParser.nextTag();
while (true) {
int i2 = AnonymousClass1.$SwitchMap$org$jivesoftware$smack$xml$XmlPullParser$TagEvent[nextTag.ordinal()];
if (i2 == 1) {
String name = xmlPullParser.getName();
if ("http://jabber.org/protocol/tune".equals(xmlPullParser.getNamespace())) {
while (nextTag == XmlPullParser.TagEvent.START_ELEMENT) {
name.hashCode();
char c = 65535;
switch (name.hashCode()) {
case -1409097913:
if (name.equals("artist")) {
c = 0;
break;
}
break;
case -1106363674:
if (name.equals(Range.ATTR_LENGTH)) {
c = 1;
break;
}
break;
case -938102371:
if (name.equals("rating")) {
c = 2;
break;
}
break;
case -896505829:
if (name.equals("source")) {
c = 3;
break;
}
break;
case 116076:
if (name.equals("uri")) {
c = 4;
break;
}
break;
case 110371416:
if (name.equals("title")) {
c = 5;
break;
}
break;
case 110621003:
if (name.equals("track")) {
c = 6;
break;
}
break;
}
while (nextTag == XmlPullParser.TagEvent.START_ELEMENT) {
}
}
}
} else if (i2 == 2 && xmlPullParser.getDepth() == i) {
return builder.build();
}
}
}
public static class AnonymousClass1 {
static final int[] $SwitchMap$org$jivesoftware$smack$xml$XmlPullParser$TagEvent;
static {
int[] iArr = new int[XmlPullParser.TagEvent.values().length];
$SwitchMap$org$jivesoftware$smack$xml$XmlPullParser$TagEvent = iArr;
try {
iArr[XmlPullParser.TagEvent.START_ELEMENT.ordinal()] = 1;
} catch (NoSuchFieldError unused) {
}
try {
$SwitchMap$org$jivesoftware$smack$xml$XmlPullParser$TagEvent[XmlPullParser.TagEvent.END_ELEMENT.ordinal()] = 2;
} catch (NoSuchFieldError unused2) {
}
}
}
}