On Wed, Apr 28, 2004 at 01:25:55PM -0500, Tony Collen wrote:
> Leszek Gawron wrote:
> >Why doesn't <map:generate type="{1}"/> work ? I cannot find the
> >explanation in
> >the archives. I am currently porting all my xsp generators to Java based
> >(compile time errors were a real nightmare). I am not able to use flow
> >here -
> >I need to use the pull model - the generator gets data from database,
> >applies
> >non trivial logic and then outputs the sax events.
> >
> >I use cocoon as a second tier which provides data for my C++ clients (http
> >protocol). The documents generated for offline synchronization contains
> >sometimes 10k+ nodes (files reach 2.5 MB )
> >
> >I cannot use jxtg as I heavily mix iterative data retrieval from database
> >and
> >data manipulation.
> >
> >Previously (with xsps) I could do <map:generate type="serverpages"
> >src="{1}.xsp"/>. With java generators this turns into a sitemap nightmare.
> > lg
> >
>
>
> Hmm, What about writing a selector to choose which generator to use?
>
>
What is the point of this ?
still I have to do :
<map:match pattern="data/*">
<map:select type="custom">
<map:when test="goods">
<map:generate type="goods"/>
</map:when>
<map:when test="contractors">
<map:generate type="contractors"/>
</map:when>
<!-- 40 more -->
<map:when test="stock">
<map:generate type="stock"/>
</map:when>
</map:select>
<map:serialize/>
</map:match>
even now without a custom selector I can do:
<map:match pattern="data/*">
<map:match patter="data/goods">
<map:generate type="goods"/>
</map:match>
<map:match patter="data/contractors">
<map:generate type="contractors"/>
</map:match>
<!-- 40 more -->
<map:match patter="data/stock">
<map:generate type="stock"/>
</map:match>
<map:serialize/>
</map:match>
but this is huge and grows every time I add some new functionality. With xsps
I haven't touched the sitemap for months.
--
__
| / \ | Leszek Gawron // \\
\_\\ //_/ [EMAIL PROTECTED] _\\()//_
.'/()\'. Phone: +48(501)720812 / // \\ \
\\ // recursive: adj; see recursive | \__/ |