public XMLWriter attribute(Utf8String name, String value) {
        if ((value == null) || value.isEmpty()) return this;
        allowAttribute();
        return w(SPACE).w(name).w(ATTRIBUTE_START).wTranscode(XML.xmlEscape(value, true)).w(ATTRIBUTE_END);
    }
Writes an attribute by XML.xmlEscape(value.toString(),false)

@param name the name of the attribute. An exception is thrown if this is null
@param value the value of the attribute. This method does nothing if the value is null or empty
vespajlib/src/main/java/com/yahoo/text/XMLWriter.java