write the descriptor class to a DOM tree and return it
Element roleMapNode = (Element) super.writeDescriptor(parent, nodeName, descriptor);
appendTextChild(roleMapNode, RuntimeTagNames.DESCRIPTION, descriptor.getDescription());
setAttribute(roleMapNode, RuntimeTagNames.MAP_ID, (String) descriptor.getValue(RoleMap.MAP_ID));
// map-element*
MapElement[] maps = descriptor.getMapElement();
if (maps.length>0) {
MapElementNode men = new MapElementNode();
for (int i=0;i<maps.length;i++) {
men.writeDescriptor(roleMapNode, RuntimeTagNames.MAP_ELEMENT, maps[i]);
}
}
return roleMapNode;