Mercurial > dive4elements > river
changeset 5700:4ed36858fe0f
merged.
author | Raimund Renkert <rrenkert@intevation.de> |
---|---|
date | Mon, 15 Apr 2013 11:17:50 +0200 |
parents | 5fca0d0d8aac (current diff) 74ebef99772d (diff) |
children | 56897ceb5589 |
files | |
diffstat | 7 files changed, 117 insertions(+), 90 deletions(-) [+] |
line wrap: on
line diff
--- a/flys-artifacts/doc/conf/floodmap.xml Mon Apr 15 11:16:39 2013 +0200 +++ b/flys-artifacts/doc/conf/floodmap.xml Mon Apr 15 11:17:50 2013 +0200 @@ -2,7 +2,7 @@ <floodmap> <shapefile-path value="${artifacts.config.dir}/../shapefiles"/> <mapserver> - <server path="https://flys3-devel.bafg.de/cgi-bin/"/> + <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"/> @@ -15,127 +15,127 @@ <river name="Saar"> <srid value="31467"/> <dgm-srid value="31466"/> - <river-wms url="https://flys3-devel.bafg.de/cgi-bin/river-wms" layers="Saar"/> - <background-wms url="https://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> + <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="https://flys3-devel.bafg.de/cgi-bin/river-wms" layers="Mosel"/> - <background-wms url="https://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> + <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="https://flys3-devel.bafg.de/cgi-bin/river-wms" layers="Elbe"/> - <background-wms url="https://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> + <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="https://flys3-devel.bafg.de/cgi-bin/river-wms" layers="Donau"/> - <background-wms url="https://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> + <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="https://flys3-devel.bafg.de/cgi-bin/river-wms" layers="Donau (Regensburg Nordarm)"/> - <background-wms url="https://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> + <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="https://flys3-devel.bafg.de/cgi-bin/river-wms" layers="Donau (Schleusenkanäle)"/> - <background-wms url="https://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> + <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="https://flys3-devel.bafg.de/cgi-bin/river-wms" layers="Fulda (Winter)"/> - <background-wms url="https://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> + <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="https://flys3-devel.bafg.de/cgi-bin/river-wms" layers="Fulda (Sommer)"/> - <background-wms url="https://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> + <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="https://flys3-devel.bafg.de/cgi-bin/river-wms" layers="Lahn"/> - <background-wms url="https://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> + <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="https://flys3-devel.bafg.de/cgi-bin/river-wms" layers="Main"/> - <background-wms url="https://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> + <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="https://flys3-devel.bafg.de/cgi-bin/river-wms" layers="Main (Wehrarm Limbach)"/> - <background-wms url="https://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> + <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="https://flys3-devel.bafg.de/cgi-bin/river-wms" layers="Main (Wehrarm Volkach)"/> - <background-wms url="https://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> + <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="https://flys3-devel.bafg.de/cgi-bin/river-wms" layers="Neckar"/> - <background-wms url="https://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> + <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="https://flys3-devel.bafg.de/cgi-bin/river-wms" layers="Neckar (über Wehrarme)"/> - <background-wms url="https://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> + <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="https://flys3-devel.bafg.de/cgi-bin/river-wms" layers="Rhein"/> - <background-wms url="https://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> + <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="https://flys3-devel.bafg.de/cgi-bin/river-wms" layers="Saale"/> - <background-wms url="https://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> + <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="https://flys3-devel.bafg.de/cgi-bin/river-wms" layers="Saale-Thüringen"/> - <background-wms url="https://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> + <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="https://flys3-devel.bafg.de/cgi-bin/river-wms" layers="Saar (Wiltinger Bogen)"/> - <background-wms url="https://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> + <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="https://flys3-devel.bafg.de/cgi-bin/river-wms" layers="Werra (Winter)"/> - <background-wms url="https://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> + <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="https://flys3-devel.bafg.de/cgi-bin/river-wms" layers="Werra (Sommer)"/> - <background-wms url="https://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> + <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="https://flys3-devel.bafg.de/cgi-bin/river-wms" layers="Weser"/> - <background-wms url="https://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> + <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>
--- a/flys-artifacts/doc/conf/rivermap.xml Mon Apr 15 11:16:39 2013 +0200 +++ b/flys-artifacts/doc/conf/rivermap.xml Mon Apr 15 11:17:50 2013 +0200 @@ -2,7 +2,7 @@ <!--// configuration fragment for static river WMS //--> <rivermap> <mapserver> - <server path="https://flys3-devel.bafg.de/cgi-bin/"/> + <server path="http://example.com/cgi-bin/"/> <mapfile path="${artifacts.config.dir}/../rivers.map"/> <templates path="${artifacts.config.dir}/mapserver/"/> <map-template path="river-mapfile.vm"/> @@ -14,117 +14,117 @@ <river name="Saar"> <srid value="31467"/> - <river-wms url="https://flys3-devel.bafg.de/cgi-bin/river-wms" layers="Saar"/> - <background-wms url="https://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> + <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"/> - <river-wms url="https://flys3-devel.bafg.de/cgi-bin/river-wms" layers="Mosel"/> - <background-wms url="https://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> + <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"/> - <river-wms url="https://flys3-devel.bafg.de/cgi-bin/river-wms" layers="Elbe"/> - <background-wms url="https://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> + <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"/> - <river-wms url="https://flys3-devel.bafg.de/cgi-bin/river-wms" layers="Donau"/> - <background-wms url="https://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> + <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"/> - <river-wms url="https://flys3-devel.bafg.de/cgi-bin/river-wms" layers="Donau (Regensburg Nordarm)"/> - <background-wms url="https://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> + <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"/> - <river-wms url="https://flys3-devel.bafg.de/cgi-bin/river-wms" layers="Donau (Schleusenkanäle)"/> - <background-wms url="https://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> + <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"/> - <river-wms url="https://flys3-devel.bafg.de/cgi-bin/river-wms" layers="Fulda (Winter)"/> - <background-wms url="https://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> + <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"/> - <river-wms url="https://flys3-devel.bafg.de/cgi-bin/river-wms" layers="Fulda (Sommer)"/> - <background-wms url="https://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> + <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"/> - <river-wms url="https://flys3-devel.bafg.de/cgi-bin/river-wms" layers="Lahn"/> - <background-wms url="https://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> + <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"/> - <river-wms url="https://flys3-devel.bafg.de/cgi-bin/river-wms" layers="Main"/> - <background-wms url="https://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> + <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"/> - <river-wms url="https://flys3-devel.bafg.de/cgi-bin/river-wms" layers="Main (Wehrarm Limbach)"/> - <background-wms url="https://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> + <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"/> - <river-wms url="https://flys3-devel.bafg.de/cgi-bin/river-wms" layers="Main (Wehrarm Volkach)"/> - <background-wms url="https://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> + <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"/> - <river-wms url="https://flys3-devel.bafg.de/cgi-bin/river-wms" layers="Neckar"/> - <background-wms url="https://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> + <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"/> - <river-wms url="https://flys3-devel.bafg.de/cgi-bin/river-wms" layers="Neckar (über Wehrarme)"/> - <background-wms url="https://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> + <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"/> - <river-wms url="https://flys3-devel.bafg.de/cgi-bin/river-wms" layers="Rhein"/> - <background-wms url="https://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> + <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"/> - <river-wms url="https://flys3-devel.bafg.de/cgi-bin/river-wms" layers="Saale"/> - <background-wms url="https://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> + <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"/> - <river-wms url="https://flys3-devel.bafg.de/cgi-bin/river-wms" layers="Saale-Thüringen"/> - <background-wms url="https://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> + <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"/> - <river-wms url="https://flys3-devel.bafg.de/cgi-bin/river-wms" layers="Saar (Wiltinger Bogen)"/> - <background-wms url="https://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> + <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"/> - <river-wms url="https://flys3-devel.bafg.de/cgi-bin/river-wms" layers="Werra (Winter)"/> - <background-wms url="https://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> + <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"/> - <river-wms url="https://flys3-devel.bafg.de/cgi-bin/river-wms" layers="Werra (Sommer)"/> - <background-wms url="https://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> + <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"/> - <river-wms url="https://flys3-devel.bafg.de/cgi-bin/river-wms" layers="Weser"/> - <background-wms url="https://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> + <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> <river name="Oder"> <srid value="31467"/> - <river-wms url="https://flys3-devel.bafg.de/cgi-bin/river-wms" layers="Oder"/> - <background-wms url="https://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> + <river-wms url="http://example.com/cgi-bin/river-wms" layers="Oder"/> + <background-wms url="http://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> </river> <river name="Havel"> <srid value="31467"/> - <river-wms url="https://flys3-devel.bafg.de/cgi-bin/river-wms" layers="Havel"/> - <background-wms url="https://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> + <river-wms url="http://example.com/cgi-bin/river-wms" layers="Havel"/> + <background-wms url="http://osm.intevation.de/mapcache/?" layers="OSM-WMS-Dienst"/> </river> </rivermap>
--- a/flys-artifacts/src/main/java/de/intevation/flys/artifacts/states/minfo/SedimentLoadYearSelect.java Mon Apr 15 11:16:39 2013 +0200 +++ b/flys-artifacts/src/main/java/de/intevation/flys/artifacts/states/minfo/SedimentLoadYearSelect.java Mon Apr 15 11:17:50 2013 +0200 @@ -2,9 +2,15 @@ import org.apache.log4j.Logger; +import de.intevation.artifacts.Artifact; + +import de.intevation.flys.artifacts.FLYSArtifact; + +import de.intevation.flys.artifacts.access.SedimentLoadAccess; import de.intevation.flys.artifacts.states.DefaultState; +/** State in which to fetch years for sedminent load calculation. */ public class SedimentLoadYearSelect extends DefaultState { @@ -18,9 +24,25 @@ public SedimentLoadYearSelect() { } + + /** Year Select Widget. */ @Override protected String getUIProvider() { return "minfo.sedimentload_year_select"; } + + @Override + public boolean validate(Artifact artifact) + throws IllegalArgumentException + { + SedimentLoadAccess access = new SedimentLoadAccess((FLYSArtifact) artifact, null); + + // Second year should be later than first. + if (access.getPeriod()[1] < access.getPeriod()[0]) + throw new IllegalArgumentException("error_years_wrong"); + + return true; + } } +// vim:set ts=4 sw=4 si et sta sts=4 fenc=utf-8 :
--- a/flys-client/src/main/java/de/intevation/flys/client/client/FLYSConstants.java Mon Apr 15 11:16:39 2013 +0200 +++ b/flys-client/src/main/java/de/intevation/flys/client/client/FLYSConstants.java Mon Apr 15 11:17:50 2013 +0200 @@ -594,6 +594,8 @@ // ERRORS + String error_years_wrong(); + String error_read_minmax_values(); String error_validate_range();
--- a/flys-client/src/main/java/de/intevation/flys/client/client/FLYSConstants.properties Mon Apr 15 11:16:39 2013 +0200 +++ b/flys-client/src/main/java/de/intevation/flys/client/client/FLYSConstants.properties Mon Apr 15 11:17:50 2013 +0200 @@ -307,6 +307,7 @@ ele_window_geometry_error = The geometry is not supported: unexpected_exception = There occured an unexpected exception +error_years_wrong = The second year needs to be bigger than the first year. error_read_minmax_values = Error while reading min/max values for the location input. error_validate_range = The value $1 needs to be smaller than $3 and bigger than $2. error_validate_date_range = Start date needs to be before end date.
--- a/flys-client/src/main/java/de/intevation/flys/client/client/FLYSConstants_de.properties Mon Apr 15 11:16:39 2013 +0200 +++ b/flys-client/src/main/java/de/intevation/flys/client/client/FLYSConstants_de.properties Mon Apr 15 11:17:50 2013 +0200 @@ -307,6 +307,7 @@ ele_window_geometry_error = Die Geometrie wird nicht unterst\u00fctzt: unexpected_exception = Ein unerwarteter Fehler ist aufgetreten +error_years_wrong = Das zweite Jahr muss gr\u00f6\u00dfer als das erste sein. error_read_minmax_values = Fehler beim Lesen der min/max Werte. Es kann keine Validierung der eingegebenen Strecke durchgef\u00fchrt werden. error_validate_range = Der Wert $1 muss kleiner als $3 und gr\u00f6\u00dfer als $2 sein. error_validate_date_range = Anfangsdatum muss fr\u00fcher sein als Enddatum.
--- a/flys-client/src/main/java/de/intevation/flys/client/client/FLYSConstants_en.properties Mon Apr 15 11:16:39 2013 +0200 +++ b/flys-client/src/main/java/de/intevation/flys/client/client/FLYSConstants_en.properties Mon Apr 15 11:17:50 2013 +0200 @@ -305,6 +305,7 @@ ele_window_geometry_error = The geometry is not supported: unexpected_exception = There occured an unexpected exception +error_years_wrong = The second year needs to be bigger than the first year. error_read_minmax_values = Error while reading min/max values for the location input. error_validate_range = The value $1 needs to be smaller than $3 and bigger than $2. error_validate_date_range = Start date needs to be before end date.