use of net.sf.saxon.type.ItemType in project intellij-community by JetBrains.
the class Saxon9StyleFrame method createValue.
private Value createValue(ValueFacade expression) throws XPathException {
final TypeHierarchy typeHierarchy = myXPathContext.getConfiguration().getTypeHierarchy();
final ItemType itemType = expression.getItemType(typeHierarchy);
final SequenceIterator it = expression.iterate(myXPathContext);
Item value = null;
if (it.next() != null) {
value = it.current();
}
if (it.next() == null) {
return new SingleValue(value, itemType);
}
return new SequenceValue(value, it, itemType);
}
Aggregations