public boolean hasNext() { return pipe.moreDocuments(); } public XdmNode next() throws TransformerException {
public void run() throws SaxonApiException { super.run(); while (source.moreDocuments()) { XdmNode node = source.read(); } } }
protected void copyInputs() throws SaxonApiException { for (String port : inputs.keySet()) { if (!port.startsWith("|")) { String wport = port + "|"; WritablePipe pipe = outputs.get(wport); for (ReadablePipe reader : inputs.get(port)) { while (reader.moreDocuments()) { XdmNode doc = reader.read(); pipe.write(doc); logger.trace(MessageFormatter.nodeMessage(step.getNode(), "Compound input copy from " + reader + " to " + pipe)); } } } } }
protected void copyInputs() throws SaxonApiException { for (String port : inputs.keySet()) { if (!port.startsWith("|")) { String wport = port + "|"; WritablePipe pipe = outputs.get(wport); for (ReadablePipe reader : inputs.get(port)) { while (reader.moreDocuments()) { XdmNode doc = reader.read(); pipe.write(doc); logger.trace(MessageFormatter.nodeMessage(step.getNode(), "Compound input copy from " + reader + " to " + pipe)); } } } } }
protected void copyInputs() throws SaxonApiException { for (String port : inputs.keySet()) { if (!port.startsWith("|") && !"error".equals(port)) { String wport = port + "|"; WritablePipe pipe = outputs.get(wport); for (ReadablePipe reader : inputs.get(port)) { while (reader.moreDocuments()) { XdmNode doc = reader.read(); pipe.write(doc); logger.trace(MessageFormatter.nodeMessage(step.getNode(), "Compound input copy from " + reader + " to " + pipe)); } } } } }
public void run() throws SaxonApiException { super.run(); while (source.moreDocuments()) { XdmNode node = source.read(); } } }
private void doReplace() throws SaxonApiException { while (replacement.moreDocuments()) { matcher.addSubtree(replacement.read()); } replacement.resetReader(); } }
private void doReplace() throws SaxonApiException { while (replacement.moreDocuments()) { matcher.addSubtree(replacement.read()); } replacement.resetReader(); } }
public void run() throws SaxonApiException { super.run(); while (source.moreDocuments()) { XdmNode doc = source.read(); logger.trace("Identity step " + step.getName() + " read " + doc.getDocumentURI()); result.write(doc); } } }
public void run() throws SaxonApiException { super.run(); while (source.moreDocuments()) { XdmNode doc = source.read(); logger.trace("Identity step " + step.getName() + " read " + doc.getDocumentURI()); result.write(doc); } } }
private void doInsert() throws SaxonApiException { while (insertion.moreDocuments()) { XdmNode doc = insertion.read(); XdmSequenceIterator iter = doc.axisIterator(Axis.CHILD); while (iter.hasNext()) { XdmNode child = (XdmNode) iter.next(); matcher.addSubtree(child); } } insertion.resetReader(); } }
private void doInsert() throws SaxonApiException { while (insertion.moreDocuments()) { XdmNode doc = insertion.read(); XdmSequenceIterator iter = doc.axisIterator(Axis.CHILD); while (iter.hasNext()) { XdmNode child = (XdmNode) iter.next(); matcher.addSubtree(child); } } insertion.resetReader(); } }
public void run() throws SaxonApiException { super.run(); HashSet<String> excludeUris = S9apiUtils.excludeInlinePrefixes(step.getNode(), getOption(_prefixes).getString()); while (source.moreDocuments()) { XdmNode doc = source.read(); logger.trace(MessageFormatter.nodeMessage(step.getNode(), "Namespace-delete step " + step.getName() + " read " + doc.getDocumentURI())); doc = S9apiUtils.removeNamespaces(runtime, doc, excludeUris, false); result.write(doc); } } }
public void run() throws SaxonApiException { super.run(); HashSet<String> excludeUris = S9apiUtils.excludeInlinePrefixes(step.getNode(), getOption(_prefixes).getString()); while (source.moreDocuments()) { XdmNode doc = source.read(); logger.trace(MessageFormatter.nodeMessage(step.getNode(), "Namespace-delete step " + step.getName() + " read " + doc.getDocumentURI())); doc = S9apiUtils.removeNamespaces(runtime, doc, excludeUris, false); result.write(doc); } } }
public void run() throws SaxonApiException { super.run(); XdmNode doc = source.read(); RuntimeValue base = getOption(_base_uri); if (base != null) { setBaseURI = base.getBaseURI().resolve(base.getString()); } logger.trace(MessageFormatter.nodeMessage(doc, "Making URIs absolute against: " + setBaseURI)); matcher = new ProcessMatch(runtime, this); matcher.match(doc, getOption(_match)); if (source.moreDocuments()) { throw XProcException.dynamicError(6, "Reading source on " + getStep().getName()); } result.write(matcher.getResult()); }
public void run() throws SaxonApiException { super.run(); matcher = new ProcessMatch(runtime, this); matcher.match(source.read(), getOption(_match)); if (source.moreDocuments()) { throw XProcException.dynamicError(6, "Reading source on " + getStep().getName()); } result.write(matcher.getResult()); }
public void run() throws SaxonApiException { super.run(); matcher = new ProcessMatch(runtime, this); matcher.match(source.read(), getOption(_match)); if (source.moreDocuments()) { throw XProcException.dynamicError(6, "Reading source on " + getStep().getName()); } result.write(matcher.getResult()); }
public void run() throws SaxonApiException { super.run(); for (Tuple t : params) { if (!"".equals(encoded)) { encoded += "&"; } encoded += t.name.getLocalName() + "=" + encode(t.value.getString()); } matcher = new ProcessMatch(runtime, this); matcher.match(source.read(), getOption(_match)); if (source.moreDocuments()) { throw XProcException.dynamicError(6, "Reading source on " + getStep().getName()); } result.write(matcher.getResult()); }
private void runSimple() throws SaxonApiException { TreeWriter treeWriter = new TreeWriter(runtime); treeWriter.startDocument(step.getNode().getBaseURI()); treeWriter.addStartElement(wrapper); treeWriter.startContent(); while (source.moreDocuments()) { XdmNode node = source.read(); treeWriter.addSubtree(node); } treeWriter.addEndElement(); treeWriter.endDocument(); XdmNode doc = treeWriter.getResult(); result.write(doc); }
private void runSimple() throws SaxonApiException { TreeWriter treeWriter = new TreeWriter(runtime); treeWriter.startDocument(step.getNode().getBaseURI()); treeWriter.addStartElement(wrapper); treeWriter.startContent(); while (source.moreDocuments()) { XdmNode node = source.read(); treeWriter.addSubtree(node); } treeWriter.addEndElement(); treeWriter.endDocument(); XdmNode doc = treeWriter.getResult(); result.write(doc); }