public XmlStringBuilder prelude(String elementName, String namespace) { halfOpenElement(elementName); xmlnsAttribute(namespace); return this; }
/** * Appends a tag that indicates that an inlined quote section begins. * * @param style the style of the inlined quote * * @return this. */ public XHTMLText appendOpenInlinedQuoteTag(String style) { text.halfOpenElement(Q); text.optAttribute(STYLE, style); text.rightAngleBracket(); return this; }
/** * Appends a tag that indicates that a blockquote section begins. * * @param style the XHTML style of the blockquote * @return this. */ public XHTMLText appendOpenBlockQuoteTag(String style) { text.halfOpenElement(BLOCKQUOTE); text.optAttribute(STYLE, style); text.rightAngleBracket(); return this; }
public XmlStringBuilder toXML() { XmlStringBuilder xml = new XmlStringBuilder(); xml.halfOpenElement("feature"); xml.attribute("var", variable); xml.closeEmptyElement(); return xml; }
@Override public final XmlStringBuilder toXML(String enclosingNamespace) { XmlStringBuilder xml = new XmlStringBuilder(); xml.halfOpenElement(this); xml.attribute(ATTR_CID, getCandidateId()); xml.closeEmptyElement(); return xml; }
protected void addCommonXml(XmlStringBuilder xml) { for (Jid toJid : (to != null ? to : Collections.<Jid>emptySet())) { xml.halfOpenElement(ELEM_TO).attribute(ATTR_JID, toJid).closeEmptyElement(); } ensureTimestampStringSet(); xml.halfOpenElement(ELEM_TIME).attribute(ATTR_STAMP, timestampString).closeEmptyElement(); xml.openElement(ELEM_PAYLOAD); for (ExtensionElement element : payload.values()) { xml.append(element.toXML(getNamespace())); } xml.closeElement(ELEM_PAYLOAD); }
@Override public XmlStringBuilder toXML(String enclosingNamespace) { XmlStringBuilder xml = new XmlStringBuilder(); xml.halfOpenElement(ELEMENT).xmlnsAttribute(NAMESPACE).rightAngleBracket(); xml.optAppend(data); xml.closeElement(ELEMENT); return xml; }
@Override protected void appendXML(XmlStringBuilder buf) { buf.halfOpenElement(METHOD); buf.optAttribute("min", getMin()); buf.optAttribute("max", getMax()); buf.closeEmptyElement(); }
@Override public XmlStringBuilder toXML(String enclosingNamespace) { XmlStringBuilder xml = new XmlStringBuilder().halfOpenElement(ELEMENT).xmlnsAttribute( NAMESPACE).rightAngleBracket(); xml.optAppend(data); xml.closeElement(ELEMENT); return xml; }
@Override public final XmlStringBuilder toXML(String enclosingNamespace) { XmlStringBuilder sb = new XmlStringBuilder(this).rightAngleBracket(); for (Integer id : deviceIds) { sb.halfOpenElement(DEVICE).attribute(ID, id).closeEmptyElement(); } sb.closeElement(this); return sb; }
@Override public XmlStringBuilder toXML(String enclosingNamespace) { XmlStringBuilder xml = new XmlStringBuilder(); xml.halfOpenElement(ELEMENT).xmlnsAttribute(NAMESPACE).rightAngleBracket(); xml.optAppend(authenticationText); xml.closeElement(ELEMENT); return xml; }
@Override public CharSequence toXML(String enclosingNamespace) { XmlStringBuilder xml = new XmlStringBuilder(); String tag = isRoom ? "room" : "user"; xml.halfOpenElement(tag); String action = allow ? "allow" : "deny"; xml.attribute("action", action); xml.rightAngleBracket(); xml.escape(jid); xml.closeElement(tag); return xml; }
@Override public XmlStringBuilder toXML(String enclosingNamespace) { XmlStringBuilder xml = new XmlStringBuilder(); xml.halfOpenElement(this); xml.attribute(ATTR_START, getStart()); xml.attribute(ATTR_END, getEnd()); xml.closeEmptyElement(); return xml; } }
@Override public XmlStringBuilder toXML(String enclosingNamespace) { XmlStringBuilder xml = new XmlStringBuilder(); xml.halfOpenElement(ELEMENT).xmlnsAttribute(NAMESPACE).attribute("mechanism", mechanism).rightAngleBracket(); xml.optAppend(authenticationText); xml.closeElement(ELEMENT); return xml; }
public XmlStringBuilder toXML() { XmlStringBuilder xml = new XmlStringBuilder(); xml.halfOpenElement("identity"); xml.xmllangAttribute(lang); xml.attribute("category", category); xml.optAttribute("name", name); xml.optAttribute("type", type); xml.closeEmptyElement(); return xml; }
@Override public XmlStringBuilder toXML(String enclosingNamespace) { XmlStringBuilder xml = new XmlStringBuilder(); xml.openElement(ELEMENT); xml.halfOpenElement(condition.toString()).xmlnsAttribute(NAMESPACE).closeEmptyElement(); addDescriptiveTextsAndExtensions(xml); xml.closeElement(ELEMENT); return xml; }
@Override public CharSequence toXML(String enclosingNamespace) { XmlStringBuilder xml = new XmlStringBuilder(this); xml.attribute("node", node); xml.rightAngleBracket(); xml.halfOpenElement("affiliation"); xml.attribute("jid", userJid); xml.attribute("affiliation", "none"); xml.closeEmptyElement(); xml.closeElement(this); return xml; }
@Override public CharSequence toXML(String enclosingNamespace) { XmlStringBuilder buf = new XmlStringBuilder(); buf.halfOpenElement(elementName).xmlnsAttribute(namespace).rightAngleBracket(); for (String name : getNames()) { String value = getValue(name); buf.element(name, value); } buf.closeElement(elementName); return buf; }
@Override public XmlStringBuilder toXML(String enclosingNamespace) { XmlStringBuilder xml = new XmlStringBuilder(); xml.halfOpenElement(getElementName()).optXmlLangAttribute(getLanguage()).rightAngleBracket(); xml.escape(subject); xml.closeElement(getElementName()); return xml; }
@Override public CharSequence toXML(String enclosingNamespace) { XmlStringBuilder xml = new XmlStringBuilder(); xml.halfOpenElement(this); xml.xmlnsAttribute(NAMESPACE); xml.optAttribute("queryid", getQueryId()); xml.optAttribute("id", getId()); xml.rightAngleBracket(); xml.element(getForwarded()); xml.closeElement(this); return xml; }