Claudia Smith wrote:
Hi,
I have a requirement to read the complete folder which consist
of different xml files and then use XSLT to work on each file
on the folder. The structure of the xml for each file is the
same.
The usual solutions are:
1/ write your stylesheet to make one transform and configure
your processing environment to call it once per file
2/ pass all the files as document nodes in a param, and loop
over them in the stylesheet
3/ pass all the files as file names (strings or URIs) in a
param, and loop over them in the stylesheet (using doc()
then processing each doc)
4/ using an implementation-defined mechanism like Saxon's
globbing support for collection(), so you can write
something like: collection('dir?select=*.xml'), see
http://saxonica.com/documentation/sourcedocs/collections.xml
5/ using filesystem-related extension functions, like the
EXPath File module, see http://expath.org/spec/file
The actual choice depends on what control you have on your
calling environment and what extensions your processor actually
supports.
Regards,
--
Florent Georges
http://fgeorges.org/
--~------------------------------------------------------------------
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--