Permalink
Browse files

Make sure parameters are passed as untypedAtomic values so that numbe…

…rs don't end up looking like strings.
  • Loading branch information...
ndw committed Sep 24, 2015
1 parent af3b415 commit 96692113393692cbb2f631a749570b4c78ba455d
@@ -158,7 +158,7 @@ public void run() throws SaxonApiException {
transformer = exec.load();
for (QName name : params.keySet()) {
RuntimeValue v = params.get(name);
- transformer.setParameter(name, new XdmAtomicValue(v.getString()));
+ transformer.setParameter(name, v.getUntypedAtomic(runtime));
}
transformer.setInitialContextNode(sourceXML);
result = new XdmDestination();
@@ -133,7 +133,7 @@ public void run() throws SaxonApiException {
if (runtime.getAllowGeneralExpressions()) {
xqeval.setExternalVariable(name, v.getValue());
} else {
- xqeval.setExternalVariable(name, new XdmAtomicValue(v.getString()));
+ xqeval.setExternalVariable(name, v.getUntypedAtomic(runtime));
}
}
@@ -211,7 +211,7 @@ public void run() throws SaxonApiException {
if (runtime.getAllowGeneralExpressions()) {
transformer.setParameter(name, v.getValue());
} else {
- transformer.setParameter(name, new XdmAtomicValue(v.getString()));
+ transformer.setParameter(name, v.getUntypedAtomic(runtime));
}
}

0 comments on commit 9669211

Please sign in to comment.