Element r = javatype.getOwnerDocument().createElementNS(OXMTNS, "xml-type");
r.setAttribute("name", xmlType.name());
r.setAttribute("namespace", xmlType.namespace());
StringBuilder propOrdr = new StringBuilder();
if (xmlType.propOrder() != null) {
for (int pi = 0; pi < xmlType.propOrder().length; pi++) {
propOrdr.append(xmlType.propOrder()[pi]);
propOrdr.append(" ");
}
}
r.setAttribute("prop-order", propOrdr.toString().trim());