> Try using the format
Thanks Michael. That works great.
I will summarize what I learned about XML catalogs (using SAXON) on the xml-dev list, soon.
From: Michael Kay [mailto:mike@...]
Sent: Monday, July 26, 2010 12:31 PM
To: Mailing list for the SAXON XSLT and XQuery processor
Subject: Re: [saxon] Does SAXON support the use of XML catalogs with XML Schema validation? If yes, what am I doing wrong?
Saxon dereferences URIs referring to schema documents using the
SchemaURIResolver interface, which is modelled on the JAXP URIResolver,
but not identical. In fact the standard (default) SchemaURIResolver is a
wrapper around a URIResolver, so if you register the Apache
CatalogResolver as the standard URIResolver for the Configuration, then
it should all just work.
On 26/07/2010 14:33, Costello, Roger L. wrote:
> Hi Michael,
> I have successfully gotten SAXON to use an XML catalog when processing an XSLT document.
> Now I would like SAXON to use an XML catalog when validating an XML document against an XML Schema (for example, I want the catalog to specify how to replace the URL in @schemaLocation with a different URL). Thus far I have been unsuccessful. I am running the validation from a DOS command line. Here's what I tried:
> java -classpath saxon9ee.jar;C:\SAXON-license\;resolver.jar \
> -Dxml.catalog.files=catalog.xml \
> -Dxml.catalog.verbosity=1 \
> com.saxonica.Validate \
> -r org.apache.xml.resolver.tools.CatalogResolver \
> -x org.apache.xml.resolver.tools.ResolvingXMLReader \
> -t BookStore.xml
Try using the format
etc. The older "-r classname" format (space-separated) is retained on some command line interfaces, but not necessarily on this one; the error message suggests an attempt to load a class with a zero-length name.
The Palm PDK Hot Apps Program offers developers who use the
Plug-In Development Kit to bring their C/C++ apps to Palm for a share
of $1 Million in cash or HP Products. Visit us here for more details:
saxon-help mailing list archived at http://saxon.markmail.org/