I'm currently setting up a system for company-wide resolution of XML 
and related entities. It has to work cross-platform (Linux/Win32) and 
support SGML Open Catalog as well as XML Catalog. It will be used by 
emacs+psgml, Epic 4.2, FrameMaker7, saxon et.al., libxml2 (xsltproc), 
and probably also XXE.

It's nice to see that XXE uses the Sun resolver classes for entity 
resolution; it holds the promise that other xml/xslt processing tools 
that use the Sun resolver can use a common set of resolver properties.

In my test, I didn't find paths relative to catalogs to be a problem; 
should it be? The set of pre-configured catalogs does not suggest so.

But I have a couple of gripes though. 

One is caused by the the Sun resolver classes: If my XML catalog files 
have DOCTYPE declarations, entity resolution will fail if an XML Catalog
DTD is not around (and BTW, the one at [1] is out of sync with the spec 
at [2]. I like to keep the DOCTYPE declarations because it makes it a 
lot easier to maintain the catalogs. Should I keep local copies of the 
XML Catalog DTD, should I just comment-out the DOCTYPE when I'm finished 
editing a catalog, or is there a more elegant solution? BTW, what is the 
best way to control the Sun resolver as used by XXE?

The other glitch appear to be caused by the part of XXE (and xsdvalid) 
that validates and serializes the DTD. Even if the XML catalog says 
prefer="public", something in XXE tries to resolve the systemID. Well, 
we tend to use URNs like "urn:x-oasis:docbook-xml-v4.1.2" for system 
identifiers in our documents (as suggested by Norman Walsh in [3]) in 
order to avoid picking up random DTDs. But XXE dies with the message 
that it doesn't grok the 'urn:' protocol (which it wasn't supposed to 
anyway). I might of course just use 'junk' as the system identifier,
but OTOH, libxml2 resolves URN-type system identifiers just fine.

[1] http://www.oasis-open.org/committees/entity/release/1.0/catalog.dtd
[2] http://www.oasis-open.org/committees/entity/spec.html).
[3] http://wwws.sun.com/software/xml/developers/resolver/article/

kind regards
Peter Ring
Magnus Informatik A/S
A Wolters Kluwer Company


-----Original Message-----
From: Hussein Shafie [mailto:[email protected]]
Sent: 9. september 2002 12:41
To: Kevin Flynn
Cc: xmleditor-support at xmlmind.com
Subject: Re: Using catalogs with XXE 2


Kevin Flynn wrote:
> 
> I should have said so in my first mail, but better late than never: XXE 2
> looks  VERY good. I have a few minor gripes about the GUI (still too
> mouse-dependent for me), but I imagine that I will be able to get round
much
> of that with customizations when the more detailed doc turns up.
> 
> I use XXE to edit documents based on our own DTDs, and I'm trying to make
> use of the catalog functionality to point to these DTDs. I have the
> following questions/comments:
> 
> As far as I can see, if I specify a relative path to a DTD in a catalog
> file, then that path is interpreted relative to XXE's config catalog, and
> not relative to the actual location of the catalog file. Is that correct?

Correct. This is a very common pratice (and in my opinion a very good
one).


> It would seem to me to be more useful if it were relative to the catalog
> location. I have all my documents and the DTDs they use located in a CVS
> tree that is mounted with different paths by different people. If paths
were
> interpreted relative to the catalog file location, then I could place a
> catalog file at the top of this tree. All users then have to do would be
to
> point XXE to the catalog file. As it is, they will need to have their own
> catalog file that specifies absolute paths to each DTD (I think).

I think that your documents should reference the ``standard universal
DTD location'' (W3C or Oasis or for your custom DTDs, DTDs on a
centralized HTTP server). This will work fine if the consumers of your
documents use XML catalog enabled software.

Reply via email to