DataStore store = runtime.getDataStore();
URI id = store.writeEntry(href, base, contentType, new DataWriter() {
public void store(OutputStream content) throws IOException {
OutputStream out = new BufferedOutputStream(content);
try {
processor.format(source.read(),out,contentType);
} catch (SaxonApiException e) {
throw new XProcException(step.getNode(), "Failed to process FO document", e);
} finally {
out.close();
}