addAttribute(workAttrs, ID_ATTR_NAME, oed.xmiId);
// Add other attributes
Iterator<XmlAttribute> attrIt = oed.attributes.iterator();
while (attrIt.hasNext()) {
XmlAttribute attr = (XmlAttribute) attrIt.next();
addAttribute(workAttrs, attr.name, attr.value);
}
// serialize element
startElement(oed.elementName, workAttrs, oed.childElements.size());
//serialize features encoded as child elements
Iterator<XmlElementNameAndContents> childElemIt = oed.childElements.iterator();
while (childElemIt.hasNext()) {
XmlElementNameAndContents child = childElemIt.next();
workAttrs.clear();
Iterator attrIter = child.attributes.iterator();
while (attrIter.hasNext()) {
XmlAttribute attr =(XmlAttribute)attrIter.next();
addAttribute(workAttrs, attr.name, attr.value);
}
if (child.contents != null) {
startElement(child.name, workAttrs, 1);