You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Stephan Coboos <cr...@gmx.net> on 2004/12/08 11:34:18 UTC
Regex doesn't work in XPathDirectoryGenerator
Hello,
I'm using the XPathDirectoryGenerator to retrieve all files with name
"book.xml" out of a certain folder. Therefore I'm using the parameter
"xmlFiles" as you can see below:
<map:parameter name="xmlFiles" value="/book\.xml/"/>
But this regex doesn't work because always all files will be scanned.
This doesn't work, too:
<map:parameter name="xmlFiles" value="book\.xml"/>
I'm not very familiar with regular expressions. But to search for all
files with name "book.xml" this should be the reight regex: /book\.xml/
right?
Thanks a lot!
Regards
Stephan
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org
Re: Regex doesn't work in XPathDirectoryGenerator
Posted by Markus Vaterlaus <mv...@gmail.com>.
Hello,
I don't get your setup:
- are there several files called "book.xml" in the same directory
- or are there several direcotries each with a book.xml
- or do several files end with book.xml (e.q first-book.xml, second-book.xml)
However, I think "^book\.xml$" would match all files named book.xml
in a certain directory.
Markus
On Wed, 08 Dec 2004 11:34:18 +0100, Stephan Coboos <cr...@gmx.net> wrote:
> Hello,
>
> I'm using the XPathDirectoryGenerator to retrieve all files with name
> "book.xml" out of a certain folder. Therefore I'm using the parameter
> "xmlFiles" as you can see below:
>
> <map:parameter name="xmlFiles" value="/book\.xml/"/>
>
> But this regex doesn't work because always all files will be scanned.
> This doesn't work, too:
>
> <map:parameter name="xmlFiles" value="book\.xml"/>
>
> I'm not very familiar with regular expressions. But to search for all
> files with name "book.xml" this should be the reight regex: /book\.xml/
> right?
>
> Thanks a lot!
>
> Regards
> Stephan
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
> For additional commands, e-mail: users-help@cocoon.apache.org
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org