}
// Otherwise we must create a union iterator, add the nodes from
// all the DOMs to this iterator, and return the union in the end.
else if (arg instanceof DTMAxisIterator) {
UnionIterator union = new UnionIterator(dom);
DTMAxisIterator iterator = (DTMAxisIterator)arg;
int node;
while ((node = iterator.next()) != DTM.NULL) {
String uri = dom.getStringValueX(node);
// Get the URI from this node if no xml URI base is set
if ((xmlURI == null) || xmlURI.equals("")) {
xmlURI = dom.getDocumentURI(node);
int sep = xmlURI.lastIndexOf('\\') + 1;