Subject: Re: [xsl] The collection() function From: "Andrew Welch" <andrew.j.welch@xxxxxxxxx> Date: Wed, 16 May 2007 10:10:20 +0100 |
I have a feeling that the implementation of collection() in Saxon could be improved for documents with a DTD. I don't think their loading can be turned off?
If a directory contains just a handful of XHTML documents loading DTDs over the net, even the most simple use of collection() like for generating a list of filenames in a directory can take minutes. When I delete the DTD declarations as a test, the function is generating the same list in a few seconds.
Kernow has a CustomStandardCollectionURIResolver which uses a CustomEntityResolver just for this purpose - it caches the DTDs referenced in the XML files when they're read using the collection() function.
This way they are only fetched once per transform and then re-used. If you prefer you can save local copies and point Kernow at the local directory so that it doesn't access the net at all.
Kernow can now be run 3 ways - using the GUI, called from Java using its API or run from Ant so it has the potential to slot in wherever you are currently using Saxon.
cheers andrew
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
RE: [xsl] The collection() function, Michael Kay | Thread | RE: [xsl] The collection() function, Michael Kay |
Re: [xsl] EXE verson of Saxon, David Carlisle | Date | Re: [xsl] EXE verson of Saxon, Abel Braaksma |
Month |