use of org.jivesoftware.smack.util.XmlStringBuilder in project Smack by igniterealtime.
the class StreamError method toXML.
@Override
public XmlStringBuilder toXML() {
XmlStringBuilder xml = new XmlStringBuilder();
xml.openElement(ELEMENT);
xml.halfOpenElement(condition.toString()).xmlnsAttribute(NAMESPACE).closeEmptyElement();
addDescriptiveTextsAndExtensions(xml);
xml.closeElement(ELEMENT);
return xml;
}
use of org.jivesoftware.smack.util.XmlStringBuilder in project Smack by igniterealtime.
the class StreamOpen method toXML.
@Override
public XmlStringBuilder toXML() {
XmlStringBuilder xml = new XmlStringBuilder(this);
xml.attribute("to", to);
xml.attribute("xmlns:stream", "http://etherx.jabber.org/streams");
xml.attribute("version", VERSION);
xml.optAttribute("from", from);
xml.optAttribute("id", id);
xml.xmllangAttribute(lang);
xml.rightAngleBracket();
return xml;
}
use of org.jivesoftware.smack.util.XmlStringBuilder in project Smack by igniterealtime.
the class MultipleAddresses method toXML.
@Override
public XmlStringBuilder toXML() {
XmlStringBuilder buf = new XmlStringBuilder(this);
buf.rightAngleBracket();
// Loop through all the addresses and append them to the string buffer
for (Address address : addresses) {
buf.append(address.toXML());
}
buf.closeElement(this);
return buf;
}
use of org.jivesoftware.smack.util.XmlStringBuilder in project Smack by igniterealtime.
the class Destroy method toXML.
@Override
public XmlStringBuilder toXML() {
XmlStringBuilder xml = new XmlStringBuilder(this);
xml.optAttribute("jid", getJid());
xml.rightAngleBracket();
xml.optElement("reason", getReason());
xml.closeElement(this);
return xml;
}
use of org.jivesoftware.smack.util.XmlStringBuilder in project Smack by igniterealtime.
the class GroupChatInvitation method toXML.
@Override
public XmlStringBuilder toXML() {
XmlStringBuilder xml = new XmlStringBuilder(this);
xml.attribute("jid", getRoomAddress());
xml.closeEmptyElement();
return xml;
}
Aggregations