///DocumentInfo saxonDocInfo = qp.buildDocument(new DocumentWrapper(_parentDecomposition.getInternalDataDocument(), null));
DocumentInfo saxonDocInfo = qp.buildDocument(new StreamSource(
new StringReader(outputter.outputString(document))));
DynamicQueryContext dynamicQueryContext = new DynamicQueryContext();
dynamicQueryContext.setContextNode(saxonDocInfo);
resultObj = xQueryExpression.evaluateSingle(dynamicQueryContext);
NodeInfo nodeInfo = (NodeInfo) resultObj;
//my code to parse SAXON resulting XML tree and produce a string
//because saxons QueryResult class isn't yet able to produce the desired string from anything
//but the root node
if (nodeInfo != null) {