Subject: Re: [xsl] Need to read a complete Folder with different XML files From: Florent Georges <lists@xxxxxxxxxxxx> Date: Mon, 6 Dec 2010 11:46:09 +0000 (GMT) |
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/
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: [xsl] Need to read a complete F, Stefan Krause | Thread | [xsl] reg XSD generation using XSL, Silent lights |
Re: [xsl] Need to read a complete F, Stefan Krause | Date | [xsl] reg XSD generation using XSL, Silent lights |
Month |