Thanks - my application involves running N number of XQuery
expressions with the same document. So it seems like it will be most efficient
to do the DOM parse once by passing a DOMSource to
bindDocument(QName varName, javax.xml.transform.Source value,
confess that the meaning of the XQItemType third argument is not very clear.
The only problem with setSourceParserClass is that its
scope may be too wide, especially if you want to use a specialized parser such
as TagSoup for parsing HTML.
void bindDocument(QName varname, Source value, XQItemType type)
allows you to supply any kind of Souce, including a SAXSource; you can
initialize a SAXSource with the XMLReader (=parser) that you want to use for
that specific document.
What is the right way to choose a parser for
xquery using xqj?
The javadoc for net.sf.saxonica.Configuration somewhat discourages the
use of method setSourceParserClass.
planning to use Configuration.setURIResolver(...) and
Those seem to be ways to control what type of parser is
used. Is there another way (property, etc.)?
Thanks - Paul Copeland