In the upcoming release of Xerces-J we are going to be including OASIS XML Catalog [1] support which will allow users to resolve locations for their schemas (using their target namespaces), DTDs and other external entities using a catalog.  The XML Commons resolver [2] which implements XML Catalogs will be included with the distribution and used by the parser to resolve URIs.  

We plan on exposing this feature through a new parser property, probably something like: http://apache.org/xml/properties/xml-catalog-manager.  The class which corresponds to this property will encapsulate the XML Commons catalogs and have methods which resolve external identifiers and other URIs using a list of catalogs the user sets on this object.  It will also allow the user to specify their preference for system or public matches in the catalog and their preference for whether they wish Xerces to resolve the literal system identifier (this is the system id as it appeared in the document) or the expanded system identifier (this is the system id after it has been absolutized against some base URI).  Based on Norman Walsh's comments [3] the literal system identifier should be used but since the spec doesn't say anything about it, it's better to give the user the option. The default would be to use the literal system id.  It is intended that the user will be able to share the Xerces xml-catalog-manager with several parsers as well as using it stand-alone to resolve other URIs.  The catalog spec defines a processing instruction which may appear in instance documents which would specify additional catalogs for the parser to use.  This won't be supported in this release but may be in a future one if there is enough interest from users.

[1] http://www.oasis-open.org/committees/entity/spec.html
[2] http://xml.apache.org/commons/components/resolver/index.html
[3] http://lists.oasis-open.org/archives/entity-resolution-comment/200304/msg00008.html

Michael Glavassevich
XML Parser Development
IBM Toronto Lab
E-mail: [EMAIL PROTECTED]

E-mail: [EMAIL PROTECTED]

Reply via email to