// OMDocType doctype = (OMDocType)node;
// factory.createOMDocType(omdoc, doctype.getValue());
// break;
case OMNode.ELEMENT_NODE:
Element el = (Element)node;
omdoc.addChild((OMNode)el.clone());
break;
case OMNode.PI_NODE:
OMProcessingInstruction pi = (OMProcessingInstruction)node;
factory.createOMProcessingInstruction(omdoc, pi.getTarget(), pi.getValue());
break;