Re: Resolve Local XSD with Xerces?

Hi Tony,

You're probably better off asking specific questions on Xerces on the
xerces-dev list [1].

> I'm using the Xerces parser to parse my XML documents and I would like
> to redirect the schemalocation to a local xsd defined by my server.  The
> Entity Resolver will work for dtds, but what can I use to redirect the
> location of an xsd?

I'm not sure if you can use an entity resolver for the location of an XML
Schema but I know that you can specify the location of the schema through
the http://apache.org/xml/properties/schema/external-schemaLocation or
http://apache.org/xml/properties/schema/external-noNamespaceSchemaLocation
properties [2]. If you set one of these properties this will override the
schema specified in the instance document through schemaLocation or
noNamespaceSchemaLocation.

Cheers,
/Eddie

[1] http://xml.apache.org/mail.html
[2] http://xml.apache.org/xerces2-j/properties.html

Received on Tuesday, 4 June 2002 19:37:22 UTC