思特奇智慧酒店云平台 v0.0.5版本的 MD5 值为:dedb172bb322639d79d7e0e26262fb5c
以下内容为反编译后的 CapsExtension.java 源代码,内容仅作参考
package org.jivesoftware.smackx.caps.packet;
import org.jivesoftware.smack.packet.ExtensionElement;
import org.jivesoftware.smack.packet.Stanza;
import org.jivesoftware.smack.roster.packet.RosterVer;
import org.jivesoftware.smack.util.XmlStringBuilder;
public class CapsExtension implements ExtensionElement {
public static final String ELEMENT = "c";
public static final String NAMESPACE = "http://jabber.org/protocol/caps";
public final String hash;
public final String node;
public final String ver;
public CapsExtension(String str, String str2, String str3) {
this.node = str;
this.ver = str2;
this.hash = str3;
}
public static CapsExtension from(Stanza stanza) {
return (CapsExtension) stanza.getExtension("c", "http://jabber.org/protocol/caps");
}
@Override
public String getElementName() {
return "c";
}
public String getHash() {
return this.hash;
}
@Override
public String getNamespace() {
return "http://jabber.org/protocol/caps";
}
public String getNode() {
return this.node;
}
public String getVer() {
return this.ver;
}
@Override
public XmlStringBuilder toXML(String str) {
XmlStringBuilder xmlStringBuilder = new XmlStringBuilder((ExtensionElement) this);
xmlStringBuilder.attribute("hash", this.hash).attribute("node", this.node).attribute(RosterVer.ELEMENT, this.ver);
xmlStringBuilder.closeEmptyElement();
return xmlStringBuilder;
}
}