Mercurial > dive4elements > river
view artifacts/doc/conf/floodmap.xml @ 5890:6ea004d51203
Datacage: Introduced <dc:group epxr="xpath" type="type"> ... </dc:group> and XPath function dc:group-key().
This splits the current result set into groups formed by expr. The type defaults to string.
Afterwards all these groups are iterated by there natural order.
The dc:group-key() gives access to the result of the grouping expression that forms a group.
Say, you have a result set like this:
name | description
-----+------------
a | foo
a | bar
b | baz
b | bla
c | blub
you can use:
<dc:group expr="$name">
<group name="{dc:group-key()}">
<dc:for-each>
<description value="{$description}"/>
</dc:for-each>
</group>
</dc:group>
to create:
<group name="a">
<description name="foo"/>
<description name="bar"/>
</group>
<group name="b">
<description name="baz"/>
<description name="bla"/>
</group>
<group name="c">
<description name="blub"/>
</group>
author | Sascha L. Teichmann <teichmann@intevation.de> |
---|---|
date | Thu, 02 May 2013 20:52:18 +0200 |
parents | 5aa05a7a34b7 |
children | 4713bc0cc0ee |
line wrap: on
line source
<?xml version="1.0" encoding="UTF-8" ?> <floodmap> <shapefile-path value="${artifacts.config.dir}/../shapefiles"/> <mapserver> <server path="http://example.com/cgi-bin/"/> <mapfile path="${artifacts.config.dir}/../flys.map"/> <templates path="${artifacts.config.dir}/mapserver/"/> <map-template path="mapfile.vm"/> </mapserver> <velocity> <logfile path="${artifacts.config.dir}/../velocity.log"/> </velocity> <river name="Saar"> <srid value="31467"/> <dgm-srid value="31466"/> <river-wms url="http://example.com/cgi-bin/river-wms" layers="Saar"/> <background-wms url="http://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> </river> <river name="Mosel"> <srid value="31467"/> <dgm-srid value="31466"/> <river-wms url="http://example.com/cgi-bin/river-wms" layers="Mosel"/> <background-wms url="http://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> </river> <river name="Elbe"> <srid value="31467"/> <dgm-srid value="31467"/> <river-wms url="http://example.com/cgi-bin/river-wms" layers="Elbe"/> <background-wms url="http://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> </river> <river name="Donau"> <srid value="31467"/> <dgm-srid value="25833"/> <river-wms url="http://example.com/cgi-bin/river-wms" layers="Donau"/> <background-wms url="http://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> </river> <river name="Donau (Regensburg Nordarm)"> <srid value="31467"/> <dgm-srid value="25833"/> <river-wms url="http://example.com/cgi-bin/river-wms" layers="Donau (Regensburg Nordarm)"/> <background-wms url="http://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> </river> <river name="Donau (Schleusenkanäle)"> <srid value="31467"/> <dgm-srid value="25833"/> <river-wms url="http://example.com/cgi-bin/river-wms" layers="Donau (Schleusenkanäle)"/> <background-wms url="http://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> </river> <river name="Fulda (Winter)"> <srid value="31467"/> <dgm-srid value="31467"/> <river-wms url="http://example.com/cgi-bin/river-wms" layers="Fulda (Winter)"/> <background-wms url="http://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> </river> <river name="Fulda (Sommer)"> <srid value="31467"/> <dgm-srid value="31467"/> <river-wms url="http://example.com/cgi-bin/river-wms" layers="Fulda (Sommer)"/> <background-wms url="http://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> </river> <river name="Lahn"> <srid value="31467"/> <dgm-srid value="31467"/> <river-wms url="http://example.com/cgi-bin/river-wms" layers="Lahn"/> <background-wms url="http://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> </river> <river name="Main"> <srid value="31467"/> <dgm-srid value="31467"/> <river-wms url="http://example.com/cgi-bin/river-wms" layers="Main"/> <background-wms url="http://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> </river> <river name="Main (Wehrarm Limbach)"> <srid value="31467"/> <dgm-srid value="31467"/> <river-wms url="http://example.com/cgi-bin/river-wms" layers="Main (Wehrarm Limbach)"/> <background-wms url="http://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> </river> <river name="Main (Wehrarm Volkach)"> <srid value="31467"/> <dgm-srid value="31467"/> <river-wms url="http://example.com/cgi-bin/river-wms" layers="Main (Wehrarm Volkach)"/> <background-wms url="http://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> </river> <river name="Neckar"> <srid value="31467"/> <dgm-srid value="31467"/> <river-wms url="http://example.com/cgi-bin/river-wms" layers="Neckar"/> <background-wms url="http://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> </river> <river name="Neckar (über Wehrarme)"> <srid value="31467"/> <dgm-srid value="31467"/> <river-wms url="http://example.com/cgi-bin/river-wms" layers="Neckar (über Wehrarme)"/> <background-wms url="http://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> </river> <river name="Rhein"> <srid value="31467"/> <dgm-srid value="31467"/> <river-wms url="http://example.com/cgi-bin/river-wms" layers="Rhein"/> <background-wms url="http://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> </river> <river name="Saale"> <srid value="31467"/> <dgm-srid value="31467"/> <river-wms url="http://example.com/cgi-bin/river-wms" layers="Saale"/> <background-wms url="http://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> </river> <river name="Saale-Thüringen"> <srid value="31467"/> <dgm-srid value="31468"/> <river-wms url="http://example.com/cgi-bin/river-wms" layers="Saale-Thüringen"/> <background-wms url="http://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> </river> <river name="Saar (Wiltinger Bogen)"> <srid value="31467"/> <dgm-srid value="31466"/> <river-wms url="http://example.com/cgi-bin/river-wms" layers="Saar (Wiltinger Bogen)"/> <background-wms url="http://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> </river> <river name="Werra (Winter)"> <srid value="31467"/> <dgm-srid value="31467"/> <river-wms url="http://example.com/cgi-bin/river-wms" layers="Werra (Winter)"/> <background-wms url="http://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> </river> <river name="Werra (Sommer)"> <srid value="31467"/> <dgm-srid value="31467"/> <river-wms url="http://example.com/cgi-bin/river-wms" layers="Werra (Sommer)"/> <background-wms url="http://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> </river> <river name="Weser"> <srid value="31467"/> <dgm-srid value="31467"/> <river-wms url="http://example.com/cgi-bin/river-wms" layers="Weser"/> <background-wms url="http://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> </river> </floodmap>