changeset 335:e964a3d8f7bc

Some Refactoring work done. Moved Transition to State gnv-artifacts/trunk@401 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author Tim Englich <tim.englich@intevation.de>
date Tue, 08 Dec 2009 08:39:03 +0000
parents e37930705daa
children 1b9ca0f2d498
files gnv-artifacts/ChangeLog gnv-artifacts/doc/conf/products/horizontalcrosssection/conf_mesh.xml gnv-artifacts/doc/conf/products/horizontalprofile/conf_instantaneouspoint.xml gnv-artifacts/doc/conf/products/horizontalprofile/conf_mesh.xml gnv-artifacts/doc/conf/products/timeseries/conf_mesh.xml gnv-artifacts/doc/conf/products/timeseries/conf_timeseriespoint.xml gnv-artifacts/doc/conf/products/verticalcrosssection/conf_mesh.xml gnv-artifacts/doc/conf/products/verticalprofile/conf_instantaneouspoint.xml gnv-artifacts/doc/conf/products/verticalprofile/conf_mesh.xml gnv-artifacts/doc/conf/products/verticalprofile/conf_timeseriespoint.xml gnv-artifacts/src/main/java/de/intevation/gnv/artifacts/GNVArtifactBase.java gnv-artifacts/src/main/java/de/intevation/gnv/artifacts/fis/FISArtifact.java gnv-artifacts/src/main/java/de/intevation/gnv/artifacts/fis/product/DefaultProduct.java gnv-artifacts/src/main/java/de/intevation/gnv/artifacts/fis/product/Product.java gnv-artifacts/src/main/java/de/intevation/gnv/chart/AbstractXYLineChart.java gnv-artifacts/src/main/java/de/intevation/gnv/chart/ChartFactory.java gnv-artifacts/src/main/java/de/intevation/gnv/chart/HorizontalCrossSectionChartFactory.java gnv-artifacts/src/main/java/de/intevation/gnv/chart/HorizontalProfileChartFactory.java gnv-artifacts/src/main/java/de/intevation/gnv/chart/TimeSeriesChart.java gnv-artifacts/src/main/java/de/intevation/gnv/chart/VerticalCrossSectionChartFactory.java gnv-artifacts/src/main/java/de/intevation/gnv/chart/VerticalProfileChart.java gnv-artifacts/src/main/java/de/intevation/gnv/chart/VerticalProfileChartFactory.java gnv-artifacts/src/main/java/de/intevation/gnv/exports/DefaultDataCollector.java gnv-artifacts/src/main/java/de/intevation/gnv/exports/DefaultExport.java gnv-artifacts/src/main/java/de/intevation/gnv/exports/Export.java gnv-artifacts/src/main/java/de/intevation/gnv/exports/ShapeDataCollector.java gnv-artifacts/src/main/java/de/intevation/gnv/exports/SimpleOdvDataCollector.java gnv-artifacts/src/main/java/de/intevation/gnv/state/CoordinateSelectionState.java gnv-artifacts/src/main/java/de/intevation/gnv/state/DefaultInputData.java gnv-artifacts/src/main/java/de/intevation/gnv/state/DefaultInputValue.java gnv-artifacts/src/main/java/de/intevation/gnv/state/DefaultOutputMode.java gnv-artifacts/src/main/java/de/intevation/gnv/state/DefaultState.java gnv-artifacts/src/main/java/de/intevation/gnv/state/InputData.java gnv-artifacts/src/main/java/de/intevation/gnv/state/InputValue.java gnv-artifacts/src/main/java/de/intevation/gnv/state/MinMaxState.java gnv-artifacts/src/main/java/de/intevation/gnv/state/OutputMode.java gnv-artifacts/src/main/java/de/intevation/gnv/state/OutputState.java gnv-artifacts/src/main/java/de/intevation/gnv/state/OutputStateBase.java gnv-artifacts/src/main/java/de/intevation/gnv/state/SingleInputState.java gnv-artifacts/src/main/java/de/intevation/gnv/state/State.java gnv-artifacts/src/main/java/de/intevation/gnv/state/StateBase.java gnv-artifacts/src/main/java/de/intevation/gnv/state/StateFactory.java gnv-artifacts/src/main/java/de/intevation/gnv/state/describedata/DefaultKeyValueDescribeData.java gnv-artifacts/src/main/java/de/intevation/gnv/state/describedata/DefaultMinMaxDescribeData.java gnv-artifacts/src/main/java/de/intevation/gnv/state/describedata/DefaultSingleValueDescribeData.java gnv-artifacts/src/main/java/de/intevation/gnv/state/describedata/DescribeData.java gnv-artifacts/src/main/java/de/intevation/gnv/state/describedata/KeyValueDescibeData.java gnv-artifacts/src/main/java/de/intevation/gnv/state/describedata/MinMaxDescribeData.java gnv-artifacts/src/main/java/de/intevation/gnv/state/describedata/NamedArrayList.java gnv-artifacts/src/main/java/de/intevation/gnv/state/describedata/NamedCollection.java gnv-artifacts/src/main/java/de/intevation/gnv/state/describedata/SingleValueDescribeData.java gnv-artifacts/src/main/java/de/intevation/gnv/state/exception/StateException.java gnv-artifacts/src/main/java/de/intevation/gnv/state/profile/horizontal/HorizontalProfileOutputState.java gnv-artifacts/src/main/java/de/intevation/gnv/state/profile/horizontal/NorthSouthEastWestState.java gnv-artifacts/src/main/java/de/intevation/gnv/state/profile/horizontalcrosssection/HorizontalCrossSectionMeshOutputState.java gnv-artifacts/src/main/java/de/intevation/gnv/state/profile/vertical/VerticalProfileOutputState.java gnv-artifacts/src/main/java/de/intevation/gnv/state/profile/verticalcrosssection/VerticalCrossSectionOutputState.java gnv-artifacts/src/main/java/de/intevation/gnv/state/timeseries/TimeSeriesOutputState.java gnv-artifacts/src/main/java/de/intevation/gnv/statistics/HorizontalProfileStatistics.java gnv-artifacts/src/main/java/de/intevation/gnv/statistics/Statistics.java gnv-artifacts/src/main/java/de/intevation/gnv/statistics/TimeseriesStatistics.java gnv-artifacts/src/main/java/de/intevation/gnv/statistics/VerticalProfileStatistics.java gnv-artifacts/src/main/java/de/intevation/gnv/transition/CoordinateSelectionTransition.java gnv-artifacts/src/main/java/de/intevation/gnv/transition/DefaultInputData.java gnv-artifacts/src/main/java/de/intevation/gnv/transition/DefaultInputValue.java gnv-artifacts/src/main/java/de/intevation/gnv/transition/DefaultOutputMode.java gnv-artifacts/src/main/java/de/intevation/gnv/transition/DefaultTransition.java gnv-artifacts/src/main/java/de/intevation/gnv/transition/InputData.java gnv-artifacts/src/main/java/de/intevation/gnv/transition/InputValue.java gnv-artifacts/src/main/java/de/intevation/gnv/transition/MinMaxTransition.java gnv-artifacts/src/main/java/de/intevation/gnv/transition/OutputMode.java gnv-artifacts/src/main/java/de/intevation/gnv/transition/OutputTransition.java gnv-artifacts/src/main/java/de/intevation/gnv/transition/OutputTransitionBase.java gnv-artifacts/src/main/java/de/intevation/gnv/transition/SingleInputTransition.java gnv-artifacts/src/main/java/de/intevation/gnv/transition/Transition.java gnv-artifacts/src/main/java/de/intevation/gnv/transition/TransitionBase.java gnv-artifacts/src/main/java/de/intevation/gnv/transition/TransitionFactory.java gnv-artifacts/src/main/java/de/intevation/gnv/transition/describedata/DefaultKeyValueDescribeData.java gnv-artifacts/src/main/java/de/intevation/gnv/transition/describedata/DefaultMinMaxDescribeData.java gnv-artifacts/src/main/java/de/intevation/gnv/transition/describedata/DefaultSingleValueDescribeData.java gnv-artifacts/src/main/java/de/intevation/gnv/transition/describedata/DescribeData.java gnv-artifacts/src/main/java/de/intevation/gnv/transition/describedata/KeyValueDescibeData.java gnv-artifacts/src/main/java/de/intevation/gnv/transition/describedata/MinMaxDescribeData.java gnv-artifacts/src/main/java/de/intevation/gnv/transition/describedata/NamedArrayList.java gnv-artifacts/src/main/java/de/intevation/gnv/transition/describedata/NamedCollection.java gnv-artifacts/src/main/java/de/intevation/gnv/transition/describedata/SingleValueDescribeData.java gnv-artifacts/src/main/java/de/intevation/gnv/transition/exception/TransitionException.java gnv-artifacts/src/main/java/de/intevation/gnv/transition/profile/horizontal/HorizontalProfileOutputTransition.java gnv-artifacts/src/main/java/de/intevation/gnv/transition/profile/horizontal/NorthSouthEastWestTransition.java gnv-artifacts/src/main/java/de/intevation/gnv/transition/profile/horizontalcrosssection/HorizontalCrossSectionMeshOutputTransition.java gnv-artifacts/src/main/java/de/intevation/gnv/transition/profile/vertical/VerticalProfileOutputTransition.java gnv-artifacts/src/main/java/de/intevation/gnv/transition/profile/verticalcrosssection/VerticalCrossSectionOutputTransition.java gnv-artifacts/src/main/java/de/intevation/gnv/transition/timeseries/TimeSeriesOutputTransition.java gnv-artifacts/src/main/java/de/intevation/gnv/utils/ArtifactXMLUtilities.java gnv-artifacts/src/test/ressources/horizontalProfile_mesh/horizontalprofile_step_10_feed.xml gnv-artifacts/src/test/ressources/timeseries_mesh/timeseries_step_08_feed.xml gnv-artifacts/src/test/ressources/verticalcrosssection_mesh/verticalcrosssection_step_07_feed.xml gnv-artifacts/src/test/ressources/verticalcrosssection_mesh/verticalcrosssection_step_08_feed.xml gnv-artifacts/src/test/ressources/verticalprofile_mesh/verticalprofile_step_10_feed.xml
diffstat 99 files changed, 4348 insertions(+), 4311 deletions(-) [+]
line wrap: on
line diff
--- a/gnv-artifacts/ChangeLog	Mon Dec 07 17:03:24 2009 +0000
+++ b/gnv-artifacts/ChangeLog	Tue Dec 08 08:39:03 2009 +0000
@@ -1,3 +1,39 @@
+2009-12-08  Tim Englich  <tim.englich@intevation.de>
+
+	* doc/conf/products/*.xml: 
+	  Switched all Package and Classnames to the new Names.
+	* src/main/java/de/intevation/gnv/artifacts/GNVArtifactBase.java: 
+	  Switched Imports from de.intevation.gnv.transition to de.intevation.gnv.state
+	  and renamed all Mebers and local Variables from *transition* to *state*
+	* src/main/java/de/intevation/gnv/utils/ArtifactXMLUtilities.java: 
+	  Changed the Class for the loggeer from TimeseriesoutputTransition
+	  to ArtifactXMLUtilities because it was wrong.
+	* src/main/java/de/intevation/gnv/artifacts/fis/FISArtifact.java, 
+	  src/main/java/de/intevation/gnv/artifacts/fis/product/DefaultProduct.java,
+	  src/main/java/de/intevation/gnv/artifacts/fis/product/Product.java, 
+	  src/main/java/de/intevation/gnv/statistics/VerticalProfileStatistics.java, 
+	  src/main/java/de/intevation/gnv/statistics/TimeseriesStatistics.java, 
+	  src/main/java/de/intevation/gnv/statistics/Statistics.java, 
+	  src/main/java/de/intevation/gnv/statistics/HorizontalProfileStatistics.java, 
+	  src/main/java/de/intevation/gnv/exports/SimpleOdvDataCollector.java, 
+	  src/main/java/de/intevation/gnv/exports/ShapeDataCollector.java, 
+	  src/main/java/de/intevation/gnv/exports/Export.java, 
+	  src/main/java/de/intevation/gnv/exports/DefaultExport.java, 
+	  src/main/java/de/intevation/gnv/exports/DefaultDataCollector.java, 
+	  src/main/java/de/intevation/gnv/chart/VerticalProfileChartFactory.java, 
+	  src/main/java/de/intevation/gnv/chart/VerticalProfileChart.java, 
+	  src/main/java/de/intevation/gnv/chart/VerticalCrossSectionChartFactory.java, 
+	  src/main/java/de/intevation/gnv/chart/TimeSeriesChart.java, 
+	  src/main/java/de/intevation/gnv/chart/HorizontalProfileChartFactory.java, 
+	  src/main/java/de/intevation/gnv/chart/HorizontalCrossSectionChartFactory.java, 
+	  src/main/java/de/intevation/gnv/chart/ChartFactory.java, 
+	  src/main/java/de/intevation/gnv/chart/AbstractXYLineChart.java: 
+	  Changed import from de.intevation.gnv.transition.* to de.intevation.gnv.state.*
+	  according to refactoring Work in the Transitionsmodel.
+	* de.intevation.gnv.transition.* 
+	  Moved to de.intevation.gnv.state.* 
+	  and renamed all Mebers,  local Variables, and Methodsignatures from *transition* to *state*
+
 2009-12-07  Ingo Weinzierl <ingo.weinzierl@intevation.de>
 
 	* src/main/java/de/intevation/gnv/transition/timeseries/TimeSeriesOutputTransition.java:
--- a/gnv-artifacts/doc/conf/products/horizontalcrosssection/conf_mesh.xml	Mon Dec 07 17:03:24 2009 +0000
+++ b/gnv-artifacts/doc/conf/products/horizontalcrosssection/conf_mesh.xml	Tue Dec 08 08:39:03 2009 +0000
@@ -1,103 +1,103 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <artifact name="horizontalCrossSectionMesh">
-    <transitions>
-        <transition id="horizontalcrosssection_area" description="horizontalcrosssection_area_one" transition="de.intevation.gnv.transition.DefaultTransition">
+    <states>
+        <state id="horizontalcrosssection_area" description="horizontalcrosssection_area_one" state="de.intevation.gnv.state.DefaultState">
             <queryID>area_filter</queryID>
             <dataname>areaid</dataname>
             <data-multiselect>false</data-multiselect>
              <data-noselect>true</data-noselect>
-            <reachableTransitions>
-                   <transition>horizontalcrosssection_subarea</transition>
-                   <transition>horizontalcrosssection_mesh_without_geom</transition>
-            </reachableTransitions>
+            <reachablestates>
+                   <state>horizontalcrosssection_subarea</state>
+                   <state>horizontalcrosssection_mesh_without_geom</state>
+            </reachablestates>
             <inputvalues>
                 <inputvalue name="sourceid" type="Integer" multiselect="false" usedinquery="0"/>
                 <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                 <inputvalue name="areaid" type="Integer" multiselect="false" usedinquery="0"/>
             </inputvalues>
-        </transition>
+        </state>
         
-        <transition id="horizontalcrosssection_subarea" description="horizontalcrosssection_area_one" transition="de.intevation.gnv.transition.DefaultTransition">
+        <state id="horizontalcrosssection_subarea" description="horizontalcrosssection_area_one" state="de.intevation.gnv.state.DefaultState">
             <queryID>subarea_filter</queryID>
             <dataname>subareaid</dataname>
             <data-multiselect>false</data-multiselect>
-            <reachableTransitions>
-                   <transition>horizontalcrosssection_mesh</transition>
-            </reachableTransitions>
+            <reachablestates>
+                   <state>horizontalcrosssection_mesh</state>
+            </reachablestates>
             <inputvalues>
                 <inputvalue name="sourceid" type="Integer" multiselect="false" usedinquery="0"/>
                 <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                 <inputvalue name="areaid" type="Integer" multiselect="false" usedinquery="1"/>
                 <inputvalue name="subareaid" type="Integer" multiselect="false" usedinquery="0"/>
             </inputvalues>
-        </transition>
+        </state>
         
-        <transition id="horizontalcrosssection_mesh_without_geom" description="horizontalcrosssection_mesh" transition="de.intevation.gnv.transition.DefaultTransition">
+        <state id="horizontalcrosssection_mesh_without_geom" description="horizontalcrosssection_mesh" state="de.intevation.gnv.state.DefaultState">
             <queryID>verticalprofile_mesh</queryID>
             <dataname>meshid</dataname>
             <data-multiselect>false</data-multiselect>
-            <reachableTransitions>
-                   <transition>horizontalcrosssection_meshpoint_depth</transition>
-            </reachableTransitions>
+            <reachablestates>
+                   <state>horizontalcrosssection_meshpoint_depth</state>
+            </reachablestates>
             <inputvalues>
                 <inputvalue name="subareaid" type="Integer" multiselect="false" usedinquery="0"/>
                 <inputvalue name="sourceid" type="Integer" multiselect="false" usedinquery="1"/>
                 <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                 <inputvalue name="meshid" type="Integer" multiselect="false" usedinquery="0"/>
             </inputvalues>
-        </transition>
+        </state>
         
-        <transition id="horizontalcrosssection_mesh" description="horizontalcrosssection_mesh" transition="de.intevation.gnv.transition.DefaultTransition">
+        <state id="horizontalcrosssection_mesh" description="horizontalcrosssection_mesh" state="de.intevation.gnv.state.DefaultState">
             <queryID>verticalprofile_mesh_with_area</queryID>
             <dataname>meshid</dataname>
             <data-multiselect>false</data-multiselect>
-            <reachableTransitions>
-                   <transition>horizontalcrosssection_meshpoint_depth</transition>
-            </reachableTransitions>
+            <reachablestates>
+                   <state>horizontalcrosssection_meshpoint_depth</state>
+            </reachablestates>
             <inputvalues>
                 <inputvalue name="subareaid" type="Integer" multiselect="false" usedinquery="0"/>
                 <inputvalue name="sourceid" type="Integer" multiselect="false" usedinquery="1"/>
                 <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                 <inputvalue name="meshid" type="Integer" multiselect="false" usedinquery="0"/>
             </inputvalues>
-        </transition>
+        </state>
         
-        <transition id="horizontalcrosssection_meshpoint_depth" description="horizontalcrosssection_meshpoint_depth" transition="de.intevation.gnv.transition.DefaultTransition">
+        <state id="horizontalcrosssection_meshpoint_depth" description="horizontalcrosssection_meshpoint_depth" state="de.intevation.gnv.state.DefaultState">
             <queryID>horizontalcrosssection_meshpoint_depth</queryID>
             <dataname>depthid</dataname>
             <data-multiselect>false</data-multiselect>
-            <reachableTransitions>
-                <transition>horizontalcrosssection_meshpoint_parameter</transition>
-            </reachableTransitions>
+            <reachablestates>
+                <state>horizontalcrosssection_meshpoint_parameter</state>
+            </reachablestates>
             <inputvalues>
                  <inputvalue name="meshid" type="Integer" multiselect="false" usedinquery="1"/>
                  <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                  <inputvalue name="depthid" type="Integer" multiselect="false" usedinquery="0"/>
             </inputvalues>
-        </transition>
+        </state>
 
-        <transition id="horizontalcrosssection_meshpoint_parameter" description="horizontalcrosssection_meshpoint_parameter" transition="de.intevation.gnv.transition.DefaultTransition">
+        <state id="horizontalcrosssection_meshpoint_parameter" description="horizontalcrosssection_meshpoint_parameter" state="de.intevation.gnv.state.DefaultState">
             <queryID>verticalprofile_mesh_parameter</queryID>
             <dataname>parameterid</dataname>
             <data-multiselect>false</data-multiselect>
-            <reachableTransitions>
-                <transition>horizontalcrosssection_mesh_date</transition>
-            </reachableTransitions>
+            <reachablestates>
+                <state>horizontalcrosssection_mesh_date</state>
+            </reachablestates>
             <inputvalues>
                  <inputvalue name="meshid" type="Integer" multiselect="false" usedinquery="1"/>
                  <inputvalue name="depthid" type="Integer" multiselect="false" usedinquery="0"/>
                  <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                  <inputvalue name="parameterid" type="Integer" multiselect="false" usedinquery="0" />
             </inputvalues>
-        </transition>
+        </state>
         
-        <transition id="horizontalcrosssection_mesh_date" description="horizontalcrosssection_mesh_date" transition="de.intevation.gnv.transition.DefaultTransition">
+        <state id="horizontalcrosssection_mesh_date" description="horizontalcrosssection_mesh_date" state="de.intevation.gnv.state.DefaultState">
            <queryID>horizontalcrosssection_mesh_date</queryID>
            <dataname>dateid</dataname>
            <data-multiselect>false</data-multiselect>
-           <reachableTransitions>
-                <transition>horizontalcrosssection_mesh_calculate_results</transition>
-           </reachableTransitions>
+           <reachablestates>
+                <state>horizontalcrosssection_mesh_calculate_results</state>
+           </reachablestates>
            <inputvalues>
                <inputvalue name="meshid" type="Integer" multiselect="false" usedinquery="1"/>
                <inputvalue name="depthid" type="Integer" multiselect="false" usedinquery="0"/>
@@ -105,9 +105,9 @@
                <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                <inputvalue name="dateid" type="Date" multiselect="false" usedinquery="0" />
            </inputvalues>
-        </transition>
+        </state>
         
-        <transition id="horizontalcrosssection_mesh_calculate_results" description="horizontalcrosssection_mesh_calculate_results" transition="de.intevation.gnv.transition.profile.horizontalcrosssection.HorizontalCrossSectionMeshOutputTransition">
+        <state id="horizontalcrosssection_mesh_calculate_results" description="horizontalcrosssection_mesh_calculate_results" state="de.intevation.gnv.state.profile.horizontalcrosssection.HorizontalCrossSectionMeshOutputState">
             <queryID>horizontalcrosssection_mesh_data</queryID>
             <queryID-odv>horizontalcrosssection_mesh_odv_data</queryID-odv>
             <inputvalues>
@@ -134,7 +134,7 @@
                 <outputsMode name="csv" description="CSV-Export der Daten" mime-type="text/plain"/>
                 <outputsMode name="odv" description="ODV-Export der Daten" mime-type="text/plain"/>
             </outputsModes>
-        </transition>
+        </state>
         
-    </transitions>
+    </states>
 </artifact>
--- a/gnv-artifacts/doc/conf/products/horizontalprofile/conf_instantaneouspoint.xml	Mon Dec 07 17:03:24 2009 +0000
+++ b/gnv-artifacts/doc/conf/products/horizontalprofile/conf_instantaneouspoint.xml	Tue Dec 08 08:39:03 2009 +0000
@@ -1,59 +1,59 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <artifact name="horizontalProfileInstantaneousPoint">
-   <transitions>
-        <transition id="horizontalprofile_instantaneouspoint_area" description="horizontalprofile_instantaneouspoint_area" transition="de.intevation.gnv.transition.DefaultTransition">
+   <states>
+        <state id="horizontalprofile_instantaneouspoint_area" description="horizontalprofile_instantaneouspoint_area" state="de.intevation.gnv.state.DefaultState">
             <queryID>area_filter</queryID>
             <dataname>areaid</dataname>
             <data-multiselect>false</data-multiselect>
              <data-noselect>true</data-noselect>
-            <reachableTransitions>
-                   <transition>horizontalprofile_instantaneouspoint_subarea</transition>
-                   <transition>horizontalprofile_instantaneouspoint_vehicle_without_geom</transition>
-            </reachableTransitions>
+            <reachablestates>
+                   <state>horizontalprofile_instantaneouspoint_subarea</state>
+                   <state>horizontalprofile_instantaneouspoint_vehicle_without_geom</state>
+            </reachablestates>
             <inputvalues>
                 <inputvalue name="sourceid" type="Integer" multiselect="false" usedinquery="0"/>
                 <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                 <inputvalue name="areaid" type="Integer" multiselect="false" usedinquery="0"/>
             </inputvalues>
-        </transition>
+        </state>
         
-        <transition id="horizontalprofile_instantaneouspoint_subarea" description="horizontalprofile_instantaneouspoint_subarea" transition="de.intevation.gnv.transition.DefaultTransition">
+        <state id="horizontalprofile_instantaneouspoint_subarea" description="horizontalprofile_instantaneouspoint_subarea" state="de.intevation.gnv.state.DefaultState">
             <queryID>subarea_filter</queryID>
             <dataname>subareaid</dataname>
             <data-multiselect>false</data-multiselect>
-            <reachableTransitions>
-                   <transition>horizontalprofile_instantaneouspoint_vehicle</transition>
-            </reachableTransitions>
+            <reachablestates>
+                   <state>horizontalprofile_instantaneouspoint_vehicle</state>
+            </reachablestates>
             <inputvalues>
                 <inputvalue name="sourceid" type="Integer" multiselect="false" usedinquery="0"/>
                 <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                 <inputvalue name="areaid" type="Integer" multiselect="false" usedinquery="1"/>
                 <inputvalue name="subareaid" type="Integer" multiselect="false" usedinquery="0"/>
             </inputvalues>
-       </transition>
+       </state>
         
         <!-- Anfang Sonderfall Ablaufsteuerung mit Anwendung des Gebietsfilters  -->
-       <transition id="horizontalprofile_instantaneouspoint_vehicle" description="horizontalprofile_instantaneouspoint_vehicle" transition="de.intevation.gnv.transition.DefaultTransition">
+       <state id="horizontalprofile_instantaneouspoint_vehicle" description="horizontalprofile_instantaneouspoint_vehicle" state="de.intevation.gnv.state.DefaultState">
            <queryID>horizontalprofile_instantaneouspoint_vehicle_with_area</queryID>
            <dataname>vehicleid</dataname>
            <data-multiselect>false</data-multiselect>
-           <reachableTransitions>
-               <transition>horizontalprofile_instantaneouspoint_cruise_with_area</transition>
-           </reachableTransitions>
+           <reachablestates>
+               <state>horizontalprofile_instantaneouspoint_cruise_with_area</state>
+           </reachablestates>
            <inputvalues>
                <inputvalue name="sourceid" type="Integer" multiselect="false"/>
                <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                <inputvalue name="subareaid" type="Integer" multiselect="false" usedinquery="1"/>
                <inputvalue name="vehicleid" type="Integer" multiselect="false" usedinquery="0"/>
            </inputvalues>
-       </transition>
-       <transition id="horizontalprofile_instantaneouspoint_cruise_with_area" description="horizontalprofile_instantaneouspoint_cruise_with_area" transition="de.intevation.gnv.transition.DefaultTransition">
+       </state>
+       <state id="horizontalprofile_instantaneouspoint_cruise_with_area" description="horizontalprofile_instantaneouspoint_cruise_with_area" state="de.intevation.gnv.state.DefaultState">
            <queryID>horizontalprofile_instantaneouspoint_cruise_with_area</queryID>
            <dataname>cruiseid</dataname>
            <data-multiselect>false</data-multiselect>
-           <reachableTransitions>
-                  <transition>horizontalprofile_instantaneouspoint_track_with_area</transition>
-           </reachableTransitions>
+           <reachablestates>
+                  <state>horizontalprofile_instantaneouspoint_track_with_area</state>
+           </reachablestates>
            <inputvalues>
                <inputvalue name="sourceid" type="Integer" multiselect="false"/>
                <inputvalue name="vehicleid" type="Integer" multiselect="false"/>
@@ -61,85 +61,85 @@
                <inputvalue name="subareaid" type="Integer" multiselect="false" usedinquery="1"/>
                <inputvalue name="cruiseid" type="Integer" multiselect="false" usedinquery="0" />
            </inputvalues>
-       </transition>
-       <transition id="horizontalprofile_instantaneouspoint_track_with_area" description="horizontalprofile_instantaneouspoint_track_with_area" transition="de.intevation.gnv.transition.DefaultTransition">
+       </state>
+       <state id="horizontalprofile_instantaneouspoint_track_with_area" description="horizontalprofile_instantaneouspoint_track_with_area" state="de.intevation.gnv.state.DefaultState">
            <queryID>horizontalprofile_instantaneouspoint_track_with_area</queryID>
            <dataname>trackid</dataname>
            <data-multiselect>false</data-multiselect>
-           <reachableTransitions>
-                  <transition>horizontalprofile_instantaneouspoint_surveyinfo</transition>
-           </reachableTransitions>Eisklimatologie
+           <reachablestates>
+                  <state>horizontalprofile_instantaneouspoint_surveyinfo</state>
+           </reachablestates>Eisklimatologie
            <inputvalues>
                <inputvalue name="cruiseid" type="Integer" multiselect="false" usedinquery="1" />
                <inputvalue name="subareaid" type="Integer" multiselect="false" usedinquery="1"/>
                <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                <inputvalue name="trackid" type="Integer" multiselect="false" usedinquery="0" />
            </inputvalues>
-       </transition>
+       </state>
        <!-- Ende Sonderfall Ablaufsteuerung mit Anwendung des Gebietsfilters  -->
        
-       <transition id="horizontalprofile_instantaneouspoint_vehicle_without_geom" description="horizontalprofile_instantaneouspoint_vehicle_without_geom" transition="de.intevation.gnv.transition.DefaultTransition">
+       <state id="horizontalprofile_instantaneouspoint_vehicle_without_geom" description="horizontalprofile_instantaneouspoint_vehicle_without_geom" state="de.intevation.gnv.state.DefaultState">
            <queryID>horizontalprofile_instantaneouspoint_vehicle</queryID>
            <dataname>vehicleid</dataname>
            <data-multiselect>false</data-multiselect>
-           <reachableTransitions>
-               <transition>horizontalprofile_instantaneouspoint_cruise</transition>
-           </reachableTransitions>
+           <reachablestates>
+               <state>horizontalprofile_instantaneouspoint_cruise</state>
+           </reachablestates>
            <inputvalues>
                <inputvalue name="sourceid" type="Integer" multiselect="false"/>
                <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                <inputvalue name="vehicleid" type="Integer" multiselect="false"  usedinquery="0"/>
            </inputvalues>
-       </transition>
+       </state>
        
-       <transition id="horizontalprofile_instantaneouspoint_cruise" description="horizontalprofile_instantaneouspoint_cruise" transition="de.intevation.gnv.transition.DefaultTransition">
+       <state id="horizontalprofile_instantaneouspoint_cruise" description="horizontalprofile_instantaneouspoint_cruise" state="de.intevation.gnv.state.DefaultState">
            <queryID>horizontalprofile_instantaneouspoint_cruise</queryID>
            <dataname>cruiseid</dataname>
            <data-multiselect>false</data-multiselect>
-           <reachableTransitions>
-                  <transition>horizontalprofile_instantaneouspoint_track</transition>
-           </reachableTransitions>
+           <reachablestates>
+                  <state>horizontalprofile_instantaneouspoint_track</state>
+           </reachablestates>
            <inputvalues>
                <inputvalue name="vehicleid" type="Integer" multiselect="false"/>
                <inputvalue name="sourceid" type="Integer" multiselect="false"/>
                <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                <inputvalue name="cruiseid" type="Integer" multiselect="false" usedinquery="0" />
            </inputvalues>
-       </transition>
-       <transition id="horizontalprofile_instantaneouspoint_track" description="horizontalprofile_instantaneouspoint_track" transition="de.intevation.gnv.transition.DefaultTransition">
+       </state>
+       <state id="horizontalprofile_instantaneouspoint_track" description="horizontalprofile_instantaneouspoint_track" state="de.intevation.gnv.state.DefaultState">
            <queryID>horizontalprofile_instantaneouspoint_track</queryID>
            <dataname>trackid</dataname>
            <data-multiselect>false</data-multiselect>
-           <reachableTransitions>
-                  <transition>horizontalprofile_instantaneouspoint_surveyinfo</transition>
-           </reachableTransitions>Eisklimatologie
+           <reachablestates>
+                  <state>horizontalprofile_instantaneouspoint_surveyinfo</state>
+           </reachablestates>Eisklimatologie
            <inputvalues>
                <inputvalue name="cruiseid" type="Integer" multiselect="false" usedinquery="1" />
                <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                <inputvalue name="trackid" type="Integer" multiselect="false" usedinquery="0" />
            </inputvalues>
-       </transition>
-       <transition id="horizontalprofile_instantaneouspoint_surveyinfo" description="horizontalprofile_instantaneouspoint_surveyinfo" transition="de.intevation.gnv.transition.DefaultTransition">
+       </state>
+       <state id="horizontalprofile_instantaneouspoint_surveyinfo" description="horizontalprofile_instantaneouspoint_surveyinfo" state="de.intevation.gnv.state.DefaultState">
            <queryID>horizontalprofile_instantaneouspoint_surveyinfo</queryID>
            <dataname>surveyid</dataname>
            <data-multiselect>false</data-multiselect>
-           <reachableTransitions>
-                  <transition>horizontalprofile_instantaneouspoint_parameter</transition>
-           </reachableTransitions>
+           <reachablestates>
+                  <state>horizontalprofile_instantaneouspoint_parameter</state>
+           </reachablestates>
            <inputvalues>
                <inputvalue name="cruiseid" type="Integer" multiselect="false" usedinquery="0" />
                <inputvalue name="trackid" type="Integer" multiselect="false" usedinquery="1" />
                <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                <inputvalue name="surveyid" type="Integer" multiselect="false" usedinquery="0" />
            </inputvalues>
-       </transition>
-       <transition id="horizontalprofile_instantaneouspoint_parameter" description="horizontalprofile_instantaneouspoint_parameter" transition="de.intevation.gnv.transition.DefaultTransition">
+       </state>
+       <state id="horizontalprofile_instantaneouspoint_parameter" description="horizontalprofile_instantaneouspoint_parameter" state="de.intevation.gnv.state.DefaultState">
            <queryID>horizontalprofile_instantaneouspoint_parameter</queryID>
            <dataname>parameterid</dataname>
            <data-multiselect>true</data-multiselect>
-           <reachableTransitions>
-                  <transition>horizontalprofile_instantaneouspoint_depth</transition>
-           </reachableTransitions>
+           <reachablestates>
+                  <state>horizontalprofile_instantaneouspoint_depth</state>
+           </reachablestates>
            <inputvalues>
                <inputvalue name="cruiseid" type="Integer" multiselect="false" usedinquery="0" />
                <inputvalue name="trackid" type="Integer" multiselect="false" usedinquery="0" />
@@ -147,14 +147,14 @@
                <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                <inputvalue name="parameterid" type="Integer" multiselect="true" usedinquery="0" />
            </inputvalues>
-       </transition>
-       <transition id="horizontalprofile_instantaneouspoint_depth" description="horizontalprofile_instantaneouspoint_depth" transition="de.intevation.gnv.transition.DefaultTransition">
+       </state>
+       <state id="horizontalprofile_instantaneouspoint_depth" description="horizontalprofile_instantaneouspoint_depth" state="de.intevation.gnv.state.DefaultState">
            <queryID>horizontalprofile_instantaneouspoint_depth</queryID>
            <dataname>measurementid</dataname>
            <data-multiselect>true</data-multiselect>
-           <reachableTransitions>
-                  <transition>horizontalprofile_instantaneouspoint_calculate_results</transition>
-           </reachableTransitions>
+           <reachablestates>
+                  <state>horizontalprofile_instantaneouspoint_calculate_results</state>
+           </reachablestates>
            <inputvalues>
                <inputvalue name="cruiseid" type="Integer" multiselect="false" usedinquery="0" />
                <inputvalue name="trackid" type="Integer" multiselect="false" usedinquery="0" />
@@ -163,8 +163,8 @@
                <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                <inputvalue name="measurementid" type="Double" multiselect="true" usedinquery="0" />
            </inputvalues>
-       </transition>
-       <transition id="horizontalprofile_instantaneouspoint_calculate_results" description="horizontalprofile_instantaneouspoint_calculate_results" transition="de.intevation.gnv.transition.profile.horizontal.HorizontalProfileOutputTransition">
+       </state>
+       <state id="horizontalprofile_instantaneouspoint_calculate_results" description="horizontalprofile_instantaneouspoint_calculate_results" state="de.intevation.gnv.state.profile.horizontal.HorizontalProfileOutputState">
            <queryID>horizontalprofile_instantaneouspoint_chart_data</queryID>
            <queryID-odv>horizontalprofile_instantaneouspoint_odv_data</queryID-odv>
            <inputvalues>
@@ -193,6 +193,6 @@
                <outputsMode name="odv" description="ODV-Export der Daten" mime-type="text/plain"/>
                <outputsMode name="statistics" description="Statistik zu den Daten" mime-type="text/xml"/>
            </outputsModes>
-       </transition>
-   </transitions>
+       </state>
+   </states>
 </artifact>
--- a/gnv-artifacts/doc/conf/products/horizontalprofile/conf_mesh.xml	Mon Dec 07 17:03:24 2009 +0000
+++ b/gnv-artifacts/doc/conf/products/horizontalprofile/conf_mesh.xml	Tue Dec 08 08:39:03 2009 +0000
@@ -1,112 +1,112 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <artifact name="horizontalProfileMesh">
-  <transitions>
-        <transition id="horizontalprofile_mesh_area" description="horizontalprofile_mesh_area_one" transition="de.intevation.gnv.transition.DefaultTransition">
+  <states>
+        <state id="horizontalprofile_mesh_area" description="horizontalprofile_mesh_area_one" state="de.intevation.gnv.state.DefaultState">
                <queryID>area_filter</queryID>
                <dataname>areaid</dataname>
                <data-multiselect>false</data-multiselect>
                 <data-noselect>true</data-noselect>
-               <reachableTransitions>
-                      <transition>horizontalprofile_mesh_subarea</transition>
-                      <transition>horizontalprofile_mesh_without_geom</transition>
-               </reachableTransitions>
+               <reachablestates>
+                      <state>horizontalprofile_mesh_subarea</state>
+                      <state>horizontalprofile_mesh_without_geom</state>
+               </reachablestates>
                <inputvalues>
                    <inputvalue name="sourceid" type="Integer" multiselect="false" usedinquery="0"/>
                    <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                    <inputvalue name="areaid" type="Integer" multiselect="false" usedinquery="0"/>
                </inputvalues>
-          </transition>
-          <transition id="horizontalprofile_mesh_subarea" description="horizontalprofile_mesh_subaera" transition="de.intevation.gnv.transition.DefaultTransition">
+          </state>
+          <state id="horizontalprofile_mesh_subarea" description="horizontalprofile_mesh_subaera" state="de.intevation.gnv.state.DefaultState">
                <queryID>subarea_filter</queryID>
                <dataname>subareaid</dataname>
                <data-multiselect>false</data-multiselect>
-               <reachableTransitions>
-                      <transition>horizontalprofile_mesh</transition>
-               </reachableTransitions>
+               <reachablestates>
+                      <state>horizontalprofile_mesh</state>
+               </reachablestates>
                <inputvalues>
                    <inputvalue name="sourceid" type="Integer" multiselect="false" usedinquery="0"/>
                    <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                    <inputvalue name="areaid" type="Integer" multiselect="false" usedinquery="1"/>
                    <inputvalue name="subareaid" type="Integer" multiselect="false" usedinquery="0"/>
                </inputvalues>
-         </transition>
+         </state>
          
-         <transition id="horizontalprofile_mesh_without_geom" description="horizontalprofile_mesh_without_geom" transition="de.intevation.gnv.transition.DefaultTransition">
+         <state id="horizontalprofile_mesh_without_geom" description="horizontalprofile_mesh_without_geom" state="de.intevation.gnv.state.DefaultState">
               <queryID>verticalprofile_mesh</queryID>
               <dataname>meshid</dataname>
               <data-multiselect>false</data-multiselect>
-              <reachableTransitions>
-                     <transition>horizontalprofile_mesh_coordinate</transition>
-              </reachableTransitions>
+              <reachablestates>
+                     <state>horizontalprofile_mesh_coordinate</state>
+              </reachablestates>
               <inputvalues>
                   <inputvalue name="sourceid" type="Integer" multiselect="false" usedinquery="1"/>
                   <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                   <inputvalue name="meshid" type="Integer" multiselect="false" usedinquery="0"/>
               </inputvalues>
-          </transition>
+          </state>
           
-        <transition id="horizontalprofile_mesh" description="horizontalprofile_mesh" transition="de.intevation.gnv.transition.DefaultTransition">
+        <state id="horizontalprofile_mesh" description="horizontalprofile_mesh" state="de.intevation.gnv.state.DefaultState">
            <queryID>verticalprofile_mesh_with_area</queryID>
            <dataname>meshid</dataname>
            <data-multiselect>false</data-multiselect>
-           <reachableTransitions>
-                  <transition>horizontalprofile_mesh_coordinate</transition>
-           </reachableTransitions>
+           <reachablestates>
+                  <state>horizontalprofile_mesh_coordinate</state>
+           </reachablestates>
            <inputvalues>
                <inputvalue name="sourceid" type="Integer" multiselect="false" usedinquery="1"/>
                <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                <inputvalue name="subareaid" type="Integer" multiselect="false" usedinquery="1"/>
                <inputvalue name="meshid" type="Integer" multiselect="false" usedinquery="0"/>
            </inputvalues>
-       </transition>
+       </state>
        
-       <transition id="horizontalprofile_mesh_coordinate" description="horizontalprofile_mesh_coordinate" transition="de.intevation.gnv.transition.SingleInputTransition">
+       <state id="horizontalprofile_mesh_coordinate" description="horizontalprofile_mesh_coordinate" state="de.intevation.gnv.state.SingleInputState">
            <dataname>mesh_coordinate</dataname>
            <data-multiselect>false</data-multiselect>
-           <reachableTransitions>
-                  <transition>horizontalprofile_mesh_point</transition>
-           </reachableTransitions>
+           <reachablestates>
+                  <state>horizontalprofile_mesh_point</state>
+           </reachablestates>
            <inputvalues>
                 <inputvalue name="meshid" type="Integer" multiselect="false"/>
                 <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                 <inputvalue name="mesh_coordinate" type="Coordinate" multiselect="false" usedinquery="0"/>
            </inputvalues>
-       </transition>
+       </state>
        
-       <transition id="horizontalprofile_mesh_point" description="horizontalprofile_mesh_point" transition="de.intevation.gnv.transition.CoordinateSelectionTransition">
+       <state id="horizontalprofile_mesh_point" description="horizontalprofile_mesh_point" state="de.intevation.gnv.state.CoordinateSelectionState">
            <queryID>verticalprofile_mesh_point</queryID>
            <dataname>mesh_point</dataname>
            <data-multiselect>false</data-multiselect>
-           <reachableTransitions>
-               <transition>horizontalprofile_mesh_axis</transition>
-           </reachableTransitions>
+           <reachablestates>
+               <state>horizontalprofile_mesh_axis</state>
+           </reachablestates>
            <inputvalues>
                 <inputvalue name="meshid" type="Integer" multiselect="false"/>
                 <inputvalue name="mesh_coordinate" type="Coordinate" multiselect="false"/>
                 <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                 <inputvalue name="mesh_point" type="Integer" multiselect="false" usedinquery="0"/>
            </inputvalues>
-       </transition>
-        <transition id="horizontalprofile_mesh_axis" description="horizontalprofile_mesh_point" transition="de.intevation.gnv.transition.profile.horizontal.NorthSouthEastWestTransition">
+       </state>
+        <state id="horizontalprofile_mesh_axis" description="horizontalprofile_mesh_point" state="de.intevation.gnv.state.profile.horizontal.NorthSouthEastWestState">
           <dataname>axisid</dataname>
            <data-multiselect>false</data-multiselect>
-           <reachableTransitions>
-               <transition>horizontalprofile_meshpoint_parameter</transition>
-           </reachableTransitions>
+           <reachablestates>
+               <state>horizontalprofile_meshpoint_parameter</state>
+           </reachablestates>
            <inputvalues>
                 <inputvalue name="meshid" type="Integer" multiselect="false"/>
                 <inputvalue name="mesh_point" type="Integer" multiselect="false"/>
                 <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                 <inputvalue name="axisid" type="AttributeName" multiselect="false" usedinquery="0"/>
            </inputvalues>
-       </transition>
-       <transition id="horizontalprofile_meshpoint_parameter" description="horizontalprofile_meshpoint_parameter" transition="de.intevation.gnv.transition.DefaultTransition">
+       </state>
+       <state id="horizontalprofile_meshpoint_parameter" description="horizontalprofile_meshpoint_parameter" state="de.intevation.gnv.state.DefaultState">
            <queryID>verticalprofile_mesh_parameter</queryID>
            <dataname>parameterid</dataname>
            <data-multiselect>true</data-multiselect>
-           <reachableTransitions>
-               <transition>horizontalprofile_meshpoint_depth</transition>
-           </reachableTransitions>
+           <reachablestates>
+               <state>horizontalprofile_meshpoint_depth</state>
+           </reachablestates>
            <inputvalues>
                 <inputvalue name="meshid" type="Integer" multiselect="false" usedinquery="1"/>
                 <inputvalue name="mesh_point" type="Integer" multiselect="false" usedinquery="0"/>
@@ -114,16 +114,16 @@
                 <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                 <inputvalue name="parameterid" type="Integer" multiselect="true" useinquery="0"/>
            </inputvalues>
-       </transition>
+       </state>
        
        
-        <transition id="horizontalprofile_meshpoint_depth" description="horizontalprofile_meshpoint_depth" transition="de.intevation.gnv.transition.DefaultTransition">
+        <state id="horizontalprofile_meshpoint_depth" description="horizontalprofile_meshpoint_depth" state="de.intevation.gnv.state.DefaultState">
            <queryID>horizontalprofile_meshpoint_depth</queryID>
            <dataname>depthid</dataname>
            <data-multiselect>true</data-multiselect>
-           <reachableTransitions>
-               <transition>horizontalprofile_mesh_date</transition>
-           </reachableTransitions>
+           <reachablestates>
+               <state>horizontalprofile_mesh_date</state>
+           </reachablestates>
            <inputvalues>
                 <inputvalue name="meshid" type="Integer" multiselect="false" usedinquery="1"/>
                 <inputvalue name="mesh_point" type="Integer" multiselect="false" usedinquery="2"/>
@@ -132,15 +132,15 @@
                 <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                 <inputvalue name="depthid" type="Integer" multiselect="true"  usedinquery="0"/>
            </inputvalues>
-       </transition>
+       </state>
        
-       <transition id="horizontalprofile_mesh_date" description="horizontalprofile_mesh_date" transition="de.intevation.gnv.transition.DefaultTransition">
+       <state id="horizontalprofile_mesh_date" description="horizontalprofile_mesh_date" state="de.intevation.gnv.state.DefaultState">
            <queryID>verticalprofile_mesh_date</queryID>
            <dataname>dateid</dataname>
            <data-multiselect>true</data-multiselect>
-           <reachableTransitions>
-                <transition>horizontalprofile_mesh_calculate_results</transition>
-           </reachableTransitions>
+           <reachablestates>
+                <state>horizontalprofile_mesh_calculate_results</state>
+           </reachablestates>
            <inputvalues>
                <inputvalue name="meshid" type="Integer" multiselect="false" usedinquery="1"/>
                <inputvalue name="mesh_point" type="Integer" multiselect="false" usedinquery="0"/>
@@ -150,9 +150,9 @@
                <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                <inputvalue name="dateid" type="Date" multiselect="true" usedinquery="0"/>
            </inputvalues>
-       </transition>
+       </state>
        
-       <transition id="horizontalprofile_mesh_calculate_results" description="horizontalprofile_mesh_calculate_results" transition="de.intevation.gnv.transition.profile.horizontal.HorizontalProfileOutputTransition">
+       <state id="horizontalprofile_mesh_calculate_results" description="horizontalprofile_mesh_calculate_results" state="de.intevation.gnv.state.profile.horizontal.HorizontalProfileOutputState">
            <queryID>horizontalprofile_mesh_chart_data</queryID>
            <queryID-odv>horizontalprofile_mesh_odv_data</queryID-odv>
            <inputvalues>
@@ -182,6 +182,6 @@
                <outputsMode name="odv" description="ODV-Export der Daten" mime-type="text/plain"/>
                <outputsMode name="statistics" description="Statistik zu den Daten" mime-type="text/xml"/>
            </outputsModes>
-       </transition>
-    </transitions>
+       </state>
+    </states>
 </artifact>
--- a/gnv-artifacts/doc/conf/products/timeseries/conf_mesh.xml	Mon Dec 07 17:03:24 2009 +0000
+++ b/gnv-artifacts/doc/conf/products/timeseries/conf_mesh.xml	Tue Dec 08 08:39:03 2009 +0000
@@ -1,115 +1,115 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <artifact name="timeSeriesMesh">
-    <transitions>
-        <transition id="timeseries_mesh_area" description="timeseries_mesh_area_one" transition="de.intevation.gnv.transition.DefaultTransition">
+    <states>
+        <state id="timeseries_mesh_area" description="timeseries_mesh_area_one" state="de.intevation.gnv.state.DefaultState">
             <queryID>area_filter</queryID>
             <dataname>areaid</dataname>
             <data-multiselect>false</data-multiselect>
              <data-noselect>true</data-noselect>
-            <reachableTransitions>
-                   <transition>timeseries_mesh_subarea</transition>
-                   <transition>timeseries_mesh_without_geom</transition>
-            </reachableTransitions>
+            <reachablestates>
+                   <state>timeseries_mesh_subarea</state>
+                   <state>timeseries_mesh_without_geom</state>
+            </reachablestates>
             <inputvalues>
                 <inputvalue name="sourceid" type="Integer" multiselect="false" usedinquery="0"/>
                 <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                 <inputvalue name="areaid" type="Integer" multiselect="false" usedinquery="0"/>
             </inputvalues>
-        </transition>
-        <transition id="timeseries_mesh_subarea" description="timeseries_mesh_subaera" transition="de.intevation.gnv.transition.DefaultTransition">
+        </state>
+        <state id="timeseries_mesh_subarea" description="timeseries_mesh_subaera" state="de.intevation.gnv.state.DefaultState">
             <queryID>subarea_filter</queryID>
             <dataname>subareaid</dataname>
             <data-multiselect>false</data-multiselect>
-            <reachableTransitions>
-                   <transition>timeseries_mesh</transition>
-            </reachableTransitions>
+            <reachablestates>
+                   <state>timeseries_mesh</state>
+            </reachablestates>
             <inputvalues>
                 <inputvalue name="sourceid" type="Integer" multiselect="false" usedinquery="0"/>
                 <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                 <inputvalue name="areaid" type="Integer" multiselect="false" usedinquery="1"/>
                 <inputvalue name="subareaid" type="Integer" multiselect="false" usedinquery="1"/>
             </inputvalues>
-        </transition>
+        </state>
         
-         <transition id="timeseries_mesh_without_geom" description="timeseries_mesh_without_geom" transition="de.intevation.gnv.transition.DefaultTransition">
+         <state id="timeseries_mesh_without_geom" description="timeseries_mesh_without_geom" state="de.intevation.gnv.state.DefaultState">
              <queryID>verticalprofile_mesh</queryID>
              <dataname>meshid</dataname>
              <data-multiselect>false</data-multiselect>
-             <reachableTransitions>
-                    <transition>timeseries_mesh_coordinate</transition>
-             </reachableTransitions>
+             <reachablestates>
+                    <state>timeseries_mesh_coordinate</state>
+             </reachablestates>
              <inputvalues>
                  <inputvalue name="sourceid" type="Integer" multiselect="false" usedinquery="1"/>
                  <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                  <inputvalue name="meshid" type="Integer" multiselect="false" usedinquery="0"/>
              </inputvalues>
-         </transition>
+         </state>
                 
-        <transition id="timeseries_mesh" description="timeseries_mesh" transition="de.intevation.gnv.transition.DefaultTransition">
+        <state id="timeseries_mesh" description="timeseries_mesh" state="de.intevation.gnv.state.DefaultState">
             <queryID>verticalprofile_mesh_with_area</queryID>
             <dataname>meshid</dataname>
             <data-multiselect>false</data-multiselect>
-            <reachableTransitions>
-                   <transition>timeseries_mesh_coordinate</transition>
-            </reachableTransitions>
+            <reachablestates>
+                   <state>timeseries_mesh_coordinate</state>
+            </reachablestates>
             <inputvalues>
                 <inputvalue name="sourceid" type="Integer" multiselect="false" usedinquery="1"/>
                 <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                 <inputvalue name="subareaid" type="Integer" multiselect="false" usedinquery="1"/>
                 <inputvalue name="meshid" type="Integer" multiselect="false" usedinquery="0"/>
             </inputvalues>
-        </transition>
+        </state>
         
-        <transition id="timeseries_mesh_coordinate" description="timeseries_mesh_coordinate" transition="de.intevation.gnv.transition.SingleInputTransition">
+        <state id="timeseries_mesh_coordinate" description="timeseries_mesh_coordinate" state="de.intevation.gnv.state.SingleInputState">
             <dataname>mesh_coordinate</dataname>
             <data-multiselect>false</data-multiselect>
-            <reachableTransitions>
-                   <transition>timeseries_meshpoint</transition>
-            </reachableTransitions>
+            <reachablestates>
+                   <state>timeseries_meshpoint</state>
+            </reachablestates>
             <inputvalues>
                  <inputvalue name="meshid" type="Integer" multiselect="false" usedinquery="0"/>
                  <inputvalue name="mesh_coordinate" type="Coordinate" multiselect="false" usedinquery="0"/>
                  <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
             </inputvalues>
-        </transition>
+        </state>
         
-        <transition id="timeseries_meshpoint" description="timeseries_meshpoint" transition="de.intevation.gnv.transition.CoordinateSelectionTransition">
+        <state id="timeseries_meshpoint" description="timeseries_meshpoint" state="de.intevation.gnv.state.CoordinateSelectionState">
             <queryID>timeseries_meshpoint</queryID>
             <dataname>mesh_point</dataname>
             <data-multiselect>false</data-multiselect>
-            <reachableTransitions>
-                <transition>timeseries_meshpoint_depth</transition>
-            </reachableTransitions>
+            <reachablestates>
+                <state>timeseries_meshpoint_depth</state>
+            </reachablestates>
             <inputvalues>
                  <inputvalue name="meshid" type="Integer" multiselect="false"/>
                  <inputvalue name="mesh_coordinate" type="Coordinate" multiselect="false" usedinquery="1"/>
                  <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                  <inputvalue name="mesh_point" type="Integer" multiselect="false" usedinquery="0"/>
             </inputvalues>
-        </transition>
+        </state>
         
-        <transition id="timeseries_meshpoint_depth" description="timeseries_meshpoint_depth" transition="de.intevation.gnv.transition.DefaultTransition">
+        <state id="timeseries_meshpoint_depth" description="timeseries_meshpoint_depth" state="de.intevation.gnv.state.DefaultState">
             <queryID>timeseries_meshpoint_depth</queryID>
             <dataname>depthid</dataname>
             <data-multiselect>true</data-multiselect>
-            <reachableTransitions>
-                <transition>timeseries_meshpoint_parameter</transition>
-            </reachableTransitions>
+            <reachablestates>
+                <state>timeseries_meshpoint_parameter</state>
+            </reachablestates>
             <inputvalues>
                  <inputvalue name="meshid" type="Integer" multiselect="false"/>
                  <inputvalue name="mesh_point" type="Integer" multiselect="false" usedinquery="2"/>
                  <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                  <inputvalue name="depthid" type="Integer" multiselect="false" usedinquery="0"/>
             </inputvalues>
-        </transition>
+        </state>
 
-        <transition id="timeseries_meshpoint_parameter" description="timeseries_meshpoint_parameter" transition="de.intevation.gnv.transition.DefaultTransition">
+        <state id="timeseries_meshpoint_parameter" description="timeseries_meshpoint_parameter" state="de.intevation.gnv.state.DefaultState">
             <queryID>timeseries_mesh_parameter</queryID>
             <dataname>parameterid</dataname>
             <data-multiselect>true</data-multiselect>
-            <reachableTransitions>
-                <transition>timeseries_meshpoint_interval</transition>
-            </reachableTransitions>
+            <reachablestates>
+                <state>timeseries_meshpoint_interval</state>
+            </reachablestates>
             <inputvalues>
                  <inputvalue name="meshid" type="Integer" multiselect="false" usedinquery="1"/>
                  <inputvalue name="depthid" type="Integer" multiselect="false" usedinquery="0"/>
@@ -117,15 +117,15 @@
                  <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                  <inputvalue name="parameterid" type="Integer" multiselect="false" usedinquery="0"/>
             </inputvalues>
-        </transition>
+        </state>
         
-        <transition id="timeseries_meshpoint_interval" description="timeseries_interval" transition="de.intevation.gnv.transition.MinMaxTransition">
+        <state id="timeseries_meshpoint_interval" description="timeseries_interval" state="de.intevation.gnv.state.MinMaxState">
             <queryID>timeseries_mesh_interval</queryID>
             <dataname>timeinterval</dataname>
             <data-multiselect>false</data-multiselect>
-            <reachableTransitions>
-                <transition>timeseries_meshpoint_calculate_results</transition>
-            </reachableTransitions>
+            <reachablestates>
+                <state>timeseries_meshpoint_calculate_results</state>
+            </reachablestates>
             <inputvalues>
                 <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                  <inputvalue name="meshid" type="Integer" multiselect="false" usedinquery="1"/>
@@ -135,9 +135,9 @@
                   <inputvalue name="minvalue" type="Date" multiselect="false" usedinquery="0"/>
                  <inputvalue name="maxvalue" type="Date" multiselect="false" usedinquery="0"/>
             </inputvalues>
-        </transition>
+        </state>
         
-        <transition id="timeseries_meshpoint_calculate_results" description="timeseries_interval" transition="de.intevation.gnv.transition.timeseries.TimeSeriesOutputTransition">
+        <state id="timeseries_meshpoint_calculate_results" description="timeseries_interval" state="de.intevation.gnv.state.timeseries.TimeSeriesOutputState">
             <queryID>timeseries_mesh_chart_data</queryID>
             <queryID-odv>timeseries_mesh_odv_data</queryID-odv>
             <inputvalues>
@@ -167,7 +167,7 @@
                 <outputsMode name="odv" description="ODV-Export der Daten" mime-type="text/plain"/>
                 <outputsMode name="statistics" description="Statistik zu den Daten" mime-type="text/xml"/>
             </outputsModes>
-        </transition>
+        </state>
         
-    </transitions>
+    </states>
 </artifact>
--- a/gnv-artifacts/doc/conf/products/timeseries/conf_timeseriespoint.xml	Mon Dec 07 17:03:24 2009 +0000
+++ b/gnv-artifacts/doc/conf/products/timeseries/conf_timeseriespoint.xml	Tue Dec 08 08:39:03 2009 +0000
@@ -7,25 +7,25 @@
       * Statistics
       * CSV
       * ODV -->
-    <transitions>
+    <states>
         
-        <!--  The required Transitionsteps which must be done until rendering
-              the OutputFormats. Each Transition is represented one required 
+        <!--  The required statesteps which must be done until rendering
+              the OutputFormats. Each state is represented one required 
               Step. One Steps can consume specified InputParameters an after 
               that it can calculate new Data which will be used as possible 
-              InputValues in the next Transition-Step from each Transition it 
-              is only possible to move to those Transitions which are Configured 
-              in the rechableTransitions-Tag  -->
+              InputValues in the next state-Step from each state it 
+              is only possible to move to those states which are Configured 
+              in the rechablestates-Tag  -->
               
-         <!-- Description of the Transition-Attributes:
-              * id: The id of the Transition. This must be unique in one Artifact.
-                    It is used to reference the Transition eg. in 
-                    reachableTransitions.
-              * description: A short description which should describe the Transition
-              * transition: The Class which must be load to handle the required logic,
+         <!-- Description of the state-Attributes:
+              * id: The id of the state. This must be unique in one Artifact.
+                    It is used to reference the state eg. in 
+                    reachablestates.
+              * description: A short description which should describe the state
+              * state: The Class which must be load to handle the required logic,
                             This class will be load using reflection. -->
               
-        <transition id="timeseries_area" description="timeseries_area_one" transition="de.intevation.gnv.transition.DefaultTransition">
+        <state id="timeseries_area" description="timeseries_area_one" state="de.intevation.gnv.state.DefaultState">
             
             <!-- The QueryID which identifies the Query which is configured in 
                  the Queries-Properties-File.
@@ -34,7 +34,7 @@
                  Configuration.-->
             <queryID>area_filter</queryID>
             
-            <!-- The ID of the Data which will be fetched using this Transition.
+            <!-- The ID of the Data which will be fetched using this state.
                  The Name must be unique in one Artifact.
                  The Name is used for the localization and must be set into the
                  several PropertiesFiles for the localization.  -->
@@ -42,29 +42,29 @@
             
             <!-- This Flag will be used to switch between single and
                  multiselect possibility of the Data which will be fetched 
-                 using this transition.  -->
+                 using this state.  -->
             <data-multiselect>false</data-multiselect>
             
             <!-- Optional Flag which can be used to set that is is possible 
                  to select no entry in the Data which will be fetched using
-                 this transition. -->
+                 this state. -->
             <data-noselect>true</data-noselect>
             
-            <reachableTransitions>
-                   <!-- reachableTransitions are those Transition which can be
-                        reached as next Step. The Transition notifies in 
-                        describe-output which Transitions can be reached.
-                        The User / calling program can choose which Transition 
+            <reachablestates>
+                   <!-- reachablestates are those state which can be
+                        reached as next Step. The state notifies in 
+                        describe-output which states can be reached.
+                        The User / calling program can choose which state 
                         he/it wants to use next  -->
-                   <transition>timeseries_subarea</transition>
-                   <transition>timeseries_without_geom</transition>
-            </reachableTransitions>
+                   <state>timeseries_subarea</state>
+                   <state>timeseries_without_geom</state>
+            </reachablestates>
             
             <inputvalues>
                 <!-- At this place it is necessary to configure the Elements
-                     which must be feed and can be used in this transition.
+                     which must be feed and can be used in this state.
                      It is possible to set if the Values should be used in 
-                     the DatabaseQuery of this Transition and how often it
+                     the DatabaseQuery of this state and how often it
                      must be used.
                      The order of the Elements is also the Order of usage setting
                      the Values into the SQL-Query. -->
@@ -72,15 +72,15 @@
                 <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                 <inputvalue name="areaid" type="Integer" multiselect="false" usedinquery="0"/>
             </inputvalues>
-        </transition>
+        </state>
         
-        <transition id="timeseries_subarea" description="timeseries_subaera" transition="de.intevation.gnv.transition.DefaultTransition">
+        <state id="timeseries_subarea" description="timeseries_subaera" state="de.intevation.gnv.state.DefaultState">
             <queryID>subarea_filter</queryID>
             <dataname>subareaid</dataname>
             <data-multiselect>false</data-multiselect>
-            <reachableTransitions>
-                   <transition>timeseries_timeseriespoint</transition>
-            </reachableTransitions>
+            <reachablestates>
+                   <state>timeseries_timeseriespoint</state>
+            </reachablestates>
 
             <inputvalues>
                 <inputvalue name="sourceid" type="Integer" multiselect="false" usedinquery="0"/>
@@ -88,73 +88,73 @@
                 <inputvalue name="areaid" type="Integer" multiselect="false" usedinquery="1"/>
                 <inputvalue name="subareaid" type="Integer" multiselect="false" usedinquery="0"/>
             </inputvalues>
-        </transition>
+        </state>
         
-        <transition id="timeseries_without_geom" description="timeseries_mesh_without_geom" transition="de.intevation.gnv.transition.DefaultTransition">
+        <state id="timeseries_without_geom" description="timeseries_mesh_without_geom" state="de.intevation.gnv.state.DefaultState">
            <queryID>timeseries_timeseriespoint</queryID>
            <dataname>featureid</dataname>
            <data-multiselect>false</data-multiselect>
-           <reachableTransitions>
-                  <transition>timeseries_parameter</transition>
-           </reachableTransitions>
+           <reachablestates>
+                  <state>timeseries_parameter</state>
+           </reachablestates>
            <inputvalues>
                <inputvalue name="sourceid" type="Integer" multiselect="false" usedinquery="1"/>
                <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                <inputvalue name="featureid" type="Integer" multiselect="false" usedinquery="0"/>
            </inputvalues>
-       </transition>
+       </state>
         
-        <transition id="timeseries_timeseriespoint" description="timeseries_timeseriespoint" transition="de.intevation.gnv.transition.DefaultTransition">
+        <state id="timeseries_timeseriespoint" description="timeseries_timeseriespoint" state="de.intevation.gnv.state.DefaultState">
             <queryID>timeseries_timeseriespoint_with_area</queryID>
             <dataname>featureid</dataname>
             <data-multiselect>false</data-multiselect>
-            <reachableTransitions>
-                <transition>timeseries_parameter</transition>
-            </reachableTransitions>
+            <reachablestates>
+                <state>timeseries_parameter</state>
+            </reachablestates>
             <inputvalues>
                 <inputvalue name="sourceid" type="Integer" multiselect="false" usedinquery="1"/>
                 <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                 <inputvalue name="subareaid" type="Integer" multiselect="false" usedinquery="1"/>
                 <inputvalue name="featureid" type="Integer" multiselect="false" usedinquery="0"/>
             </inputvalues>
-        </transition>
+        </state>
         
-        <transition id="timeseries_parameter" description="timeseries_parameter" transition="de.intevation.gnv.transition.DefaultTransition">
+        <state id="timeseries_parameter" description="timeseries_parameter" state="de.intevation.gnv.state.DefaultState">
             <queryID>timeseries_parameter</queryID>
             <dataname>parameterid</dataname>
             <data-multiselect>true</data-multiselect>
-            <reachableTransitions>
-                <transition>timeseries_depth_height</transition>
-            </reachableTransitions>
+            <reachablestates>
+                <state>timeseries_depth_height</state>
+            </reachablestates>
             <inputvalues>
                 <inputvalue name="featureid" type="Integer" multiselect="false"/>
                 <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                 <inputvalue name="parameterid" type="Integer" multiselect="true" usedinquery="0"/>
             </inputvalues>
-        </transition>           
+        </state>           
         
-         <transition id="timeseries_depth_height" description="timeseries_depth_height" transition="de.intevation.gnv.transition.DefaultTransition">
+         <state id="timeseries_depth_height" description="timeseries_depth_height" state="de.intevation.gnv.state.DefaultState">
             <queryID>timeseries_depth_height</queryID>
             <dataname>measurementid</dataname>
             <data-multiselect>true</data-multiselect>
-            <reachableTransitions>
-                 <transition>timeseries_interval</transition>
-            </reachableTransitions>
+            <reachablestates>
+                 <state>timeseries_interval</state>
+            </reachablestates>
             <inputvalues>
                 <inputvalue name="featureid" type="Integer" multiselect="false"/>
                 <inputvalue name="parameterid" type="Integer" multiselect="true"/>
                 <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                 <inputvalue name="measurementid" type="Integer" multiselect="true" usedinquery="0"/>
             </inputvalues>
-        </transition>
+        </state>
         
-        <transition id="timeseries_interval" description="timeseries_interval" transition="de.intevation.gnv.transition.MinMaxTransition">
+        <state id="timeseries_interval" description="timeseries_interval" state="de.intevation.gnv.state.MinMaxState">
             <queryID>timeseries_interval</queryID>
             <dataname>timeinterval</dataname>
             <data-multiselect>false</data-multiselect>
-            <reachableTransitions>
-                <transition>timeseries_calculate_results</transition>
-            </reachableTransitions>
+            <reachablestates>
+                <state>timeseries_calculate_results</state>
+            </reachablestates>
             <inputvalues>
                 <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                 <inputvalue name="parameterid" type="Integer" multiselect="true"/>
@@ -162,12 +162,12 @@
                 <inputvalue name="minvalue" type="Date" multiselect="false" usedinquery="0"/>
                 <inputvalue name="maxvalue" type="Date" multiselect="false" usedinquery="0"/>
             </inputvalues>
-        </transition>
+        </state>
         
-        <!--  Last Transition is the Output-Transition. At this place the differen OutputModes are configured.
+        <!--  Last state is the Output-state. At this place the differen OutputModes are configured.
               For each OutputMode it might be necessary to configure separat Databasequery which collect the
               Data. -->
-        <transition id="timeseries_calculate_results" description="timeseries_interval" transition="de.intevation.gnv.transition.timeseries.TimeSeriesOutputTransition">
+        <state id="timeseries_calculate_results" description="timeseries_interval" state="de.intevation.gnv.state.timeseries.TimeSeriesOutputState">
             <queryID>timeseries_chart_data</queryID>
             <queryID-odv>timeseries_odv_data</queryID-odv>
             <inputvalues>
@@ -193,7 +193,7 @@
             <!--  Definition of the TimeGaps which are required to render the Charts properly.
                   each Parameter in each FIS can have   -->
             <time-gap-definition xlink:href="${artifacts.config.dir}/products/timeseries/timegap_definition.xml" />
-        </transition>
+        </state>
         
-    </transitions>
+    </states>
 </artifact>
--- a/gnv-artifacts/doc/conf/products/verticalcrosssection/conf_mesh.xml	Mon Dec 07 17:03:24 2009 +0000
+++ b/gnv-artifacts/doc/conf/products/verticalcrosssection/conf_mesh.xml	Tue Dec 08 08:39:03 2009 +0000
@@ -1,112 +1,112 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <artifact name="verticalCrossSectionMesh">
-     <transitions>
-        <transition id="verticalcrosssection_mesh_area" description="verticalcrosssection_mesh_area_one" transition="de.intevation.gnv.transition.DefaultTransition">
+     <states>
+        <state id="verticalcrosssection_mesh_area" description="verticalcrosssection_mesh_area_one" state="de.intevation.gnv.state.DefaultState">
                <queryID>area_filter</queryID>
                <dataname>areaid</dataname>
                <data-multiselect>false</data-multiselect>
                 <data-noselect>true</data-noselect>
-               <reachableTransitions>
-                      <transition>verticalcrosssection_mesh_subarea</transition>
-                      <transition>verticalcrosssection_mesh_without_geom</transition>
-               </reachableTransitions>
+               <reachablestates>
+                      <state>verticalcrosssection_mesh_subarea</state>
+                      <state>verticalcrosssection_mesh_without_geom</state>
+               </reachablestates>
                <inputvalues>
                    <inputvalue name="sourceid" type="Integer" multiselect="false" usedinquery="0"/>
                    <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                    <inputvalue name="areaid" type="Integer" multiselect="false" usedinquery="0"/>
                </inputvalues>
-          </transition>
-          <transition id="verticalcrosssection_mesh_subarea" description="verticalcrosssection_mesh_area_one" transition="de.intevation.gnv.transition.DefaultTransition">
+          </state>
+          <state id="verticalcrosssection_mesh_subarea" description="verticalcrosssection_mesh_area_one" state="de.intevation.gnv.state.DefaultState">
                <queryID>subarea_filter</queryID>
                <dataname>subareaid</dataname>
                <data-multiselect>false</data-multiselect>
-               <reachableTransitions>
-                      <transition>verticalcrosssection_mesh</transition>
-               </reachableTransitions>
+               <reachablestates>
+                      <state>verticalcrosssection_mesh</state>
+               </reachablestates>
                <inputvalues>
                    <inputvalue name="sourceid" type="Integer" multiselect="false" usedinquery="0"/>
                    <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                    <inputvalue name="areaid" type="Integer" multiselect="false" usedinquery="1"/>
                    <inputvalue name="subareaid" type="Integer" multiselect="false" usedinquery="0"/>
                </inputvalues>
-         </transition>
+         </state>
          
-         <transition id="verticalcrosssection_mesh_without_geom" description="verticalcrosssection_mesh" transition="de.intevation.gnv.transition.DefaultTransition">
+         <state id="verticalcrosssection_mesh_without_geom" description="verticalcrosssection_mesh" state="de.intevation.gnv.state.DefaultState">
               <queryID>verticalprofile_mesh</queryID>
               <dataname>meshid</dataname>
               <data-multiselect>false</data-multiselect>
-              <reachableTransitions>
-                     <transition>verticalcrosssection_mesh_coordinate</transition>
-              </reachableTransitions>
+              <reachablestates>
+                     <state>verticalcrosssection_mesh_coordinate</state>
+              </reachablestates>
               <inputvalues>
                   <inputvalue name="sourceid" type="Integer" multiselect="false" usedinquery="1"/>
                   <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                    <inputvalue name="meshid" type="Integer" multiselect="false" usedinquery="0"/>
               </inputvalues>
-          </transition>
+          </state>
          
-         <transition id="verticalcrosssection_mesh" description="verticalcrosssection_mesh" transition="de.intevation.gnv.transition.DefaultTransition">
+         <state id="verticalcrosssection_mesh" description="verticalcrosssection_mesh" state="de.intevation.gnv.state.DefaultState">
              <queryID>verticalprofile_mesh_with_area</queryID>
              <dataname>meshid</dataname>
              <data-multiselect>false</data-multiselect>
-             <reachableTransitions>
-                    <transition>verticalcrosssection_mesh_coordinate</transition>
-             </reachableTransitions>
+             <reachablestates>
+                    <state>verticalcrosssection_mesh_coordinate</state>
+             </reachablestates>
              <inputvalues>
                  <inputvalue name="sourceid" type="Integer" multiselect="false" usedinquery="1"/>
                  <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                  <inputvalue name="subareaid" type="Integer" multiselect="false" usedinquery="1"/>
                  <inputvalue name="meshid" type="Integer" multiselect="false" usedinquery="0"/>
              </inputvalues>
-         </transition>
+         </state>
          
-         <transition id="verticalcrosssection_mesh_coordinate" description="verticalcrosssection_mesh_coordinate" transition="de.intevation.gnv.transition.SingleInputTransition">
+         <state id="verticalcrosssection_mesh_coordinate" description="verticalcrosssection_mesh_coordinate" state="de.intevation.gnv.state.SingleInputState">
              <dataname>mesh_coordinate</dataname>
              <data-multiselect>false</data-multiselect>
-             <reachableTransitions>
-                    <transition>verticalcrosssection_mesh_point</transition>
-             </reachableTransitions>
+             <reachablestates>
+                    <state>verticalcrosssection_mesh_point</state>
+             </reachablestates>
              <inputvalues>
                   <inputvalue name="meshid" type="Integer" multiselect="false" usedinquery="1"/>
                   <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                   <inputvalue name="mesh_coordinate" type="Coordinate" multiselect="false" usedinquery="0"/>
              </inputvalues>
-         </transition>
+         </state>
          
-         <transition id="verticalcrosssection_mesh_point" description="verticalcrosssection_mesh__point" transition="de.intevation.gnv.transition.CoordinateSelectionTransition">
+         <state id="verticalcrosssection_mesh_point" description="verticalcrosssection_mesh__point" state="de.intevation.gnv.state.CoordinateSelectionState">
              <queryID>verticalprofile_mesh_point</queryID>
              <dataname>mesh_point</dataname>
              <data-multiselect>false</data-multiselect>
-             <reachableTransitions>
-                 <transition>verticalcrosssection_mesh_axis</transition>
-             </reachableTransitions>
+             <reachablestates>
+                 <state>verticalcrosssection_mesh_axis</state>
+             </reachablestates>
              <inputvalues>
                   <inputvalue name="meshid" type="Integer" multiselect="false" usedinquery="1"/>
                   <inputvalue name="mesh_coordinate" type="Coordinate" multiselect="false" usedinquery="1"/>
                   <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                   <inputvalue name="mesh_point" type="Integer" multiselect="false" usedinquery="0"/>
              </inputvalues>
-         </transition>
-          <transition id="verticalcrosssection_mesh_axis" description="verticalcrosssection_mesh_axis" transition="de.intevation.gnv.transition.profile.horizontal.NorthSouthEastWestTransition">
+         </state>
+          <state id="verticalcrosssection_mesh_axis" description="verticalcrosssection_mesh_axis" state="de.intevation.gnv.state.profile.horizontal.NorthSouthEastWestState">
             <dataname>axisid</dataname>
              <data-multiselect>false</data-multiselect>
-             <reachableTransitions>
-                 <transition>verticalcrosssection_mesh_parameter</transition>
-             </reachableTransitions>
+             <reachablestates>
+                 <state>verticalcrosssection_mesh_parameter</state>
+             </reachablestates>
              <inputvalues>
                   <inputvalue name="meshid" type="Integer" multiselect="false" usedinquery="1"/>
                   <inputvalue name="mesh_point" type="Integer" multiselect="false" usedinquery="1"/>
                   <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                   <inputvalue name="axisid" type="AttributeName" multiselect="false" usedinquery="0"/>
              </inputvalues>
-         </transition>
-         <transition id="verticalcrosssection_mesh_parameter" description="verticalcrosssection_mesh_parameter" transition="de.intevation.gnv.transition.DefaultTransition">
+         </state>
+         <state id="verticalcrosssection_mesh_parameter" description="verticalcrosssection_mesh_parameter" state="de.intevation.gnv.state.DefaultState">
              <queryID>verticalprofile_mesh_parameter</queryID>
              <dataname>parameterid</dataname>
              <data-multiselect>false</data-multiselect>
-             <reachableTransitions>
-                 <transition>verticalcrosssection_mesh_date</transition>
-             </reachableTransitions>
+             <reachablestates>
+                 <state>verticalcrosssection_mesh_date</state>
+             </reachablestates>
              <inputvalues>
                   <inputvalue name="meshid" type="Integer" multiselect="false" usedinquery="1"/>
                   <inputvalue name="mesh_point" type="Integer" multiselect="false" usedinquery="0"/>
@@ -114,16 +114,16 @@
                   <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                   <inputvalue name="parameterid" type="Integer" multiselect="true"  usedinquery="0"/>
              </inputvalues>
-         </transition>
+         </state>
          
          
-         <transition id="verticalcrosssection_mesh_date" description="verticalcrosssection_mesh_date" transition="de.intevation.gnv.transition.DefaultTransition">
+         <state id="verticalcrosssection_mesh_date" description="verticalcrosssection_mesh_date" state="de.intevation.gnv.state.DefaultState">
              <queryID>verticalcrosssection_mesh_date</queryID>
              <dataname>dateid</dataname>
              <data-multiselect>false</data-multiselect>
-             <reachableTransitions>
-                  <transition>verticalcrosssection_mesh_calculate_results</transition>
-             </reachableTransitions>
+             <reachablestates>
+                  <state>verticalcrosssection_mesh_calculate_results</state>
+             </reachablestates>
              <inputvalues>
                  <inputvalue name="meshid" type="Integer" multiselect="false" usedinquery="1"/>
                  <inputvalue name="mesh_point" type="Integer" multiselect="false" usedinquery="0"/>
@@ -132,9 +132,9 @@
                  <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                  <inputvalue name="dateid" type="Date" multiselect="true" usedinquery="0"/>
              </inputvalues>
-         </transition>
+         </state>
          
-         <transition id="verticalcrosssection_mesh_calculate_results" description="verticalcrosssection_mesh_calculate_results" transition="de.intevation.gnv.transition.profile.verticalcrosssection.VerticalCrossSectionOutputTransition">
+         <state id="verticalcrosssection_mesh_calculate_results" description="verticalcrosssection_mesh_calculate_results" state="de.intevation.gnv.state.profile.verticalcrosssection.VerticalCrossSectionOutputState">
              <queryID>verticalcrosssection_mesh_chart_data</queryID>
              <queryID-odv>verticalcrosssection_mesh_odv_data</queryID-odv>
              <inputvalues>
@@ -161,6 +161,6 @@
                  <outputsMode name="svg" description="PDF-Export der Daten" mime-type="image/svg+xml"/>
                  <outputsMode name="csv" description="CSV-Export der Daten" mime-type="text/plain"/>
              </outputsModes>
-         </transition>
-     </transitions>
+         </state>
+     </states>
 </artifact>
--- a/gnv-artifacts/doc/conf/products/verticalprofile/conf_instantaneouspoint.xml	Mon Dec 07 17:03:24 2009 +0000
+++ b/gnv-artifacts/doc/conf/products/verticalprofile/conf_instantaneouspoint.xml	Tue Dec 08 08:39:03 2009 +0000
@@ -1,54 +1,54 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <artifact name="verticalProfileInstantaneousPoint">
-   <transitions>
-     <transition id="verticalprofile_instantaneouspoint_series" description="verticalprofile_instantaneouspoint_series" transition="de.intevation.gnv.transition.DefaultTransition">
+   <states>
+     <state id="verticalprofile_instantaneouspoint_series" description="verticalprofile_instantaneouspoint_series" state="de.intevation.gnv.state.DefaultState">
          <queryID>verticalprofile_instantaneouspoint_series</queryID>
          <dataname>seriesid</dataname>
          <data-multiselect>false</data-multiselect>
-         <reachableTransitions>
-             <transition>verticalprofile_instantaneouspoint_point</transition>
-         </reachableTransitions>
+         <reachablestates>
+             <state>verticalprofile_instantaneouspoint_point</state>
+         </reachablestates>
          <inputvalues>
              <inputvalue name="sourceid" type="Integer" multiselect="false" usedinquery="1"/>
               <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
               <inputvalue name="seriesid" type="Integer" multiselect="false" usedinquery="0"/>
          </inputvalues>
-     </transition>
-     <transition id="verticalprofile_instantaneouspoint_point" description="verticalprofile_instantaneouspoint_point" transition="de.intevation.gnv.transition.CoordinateSelectionTransition">
+     </state>
+     <state id="verticalprofile_instantaneouspoint_point" description="verticalprofile_instantaneouspoint_point" state="de.intevation.gnv.state.CoordinateSelectionState">
          <queryID>verticalprofile_instantaneouspoint_point</queryID>
          <dataname>instantaneouspoint_point</dataname>
          <data-multiselect>false</data-multiselect>
-         <reachableTransitions>
-             <transition>verticalprofile_instantaneouspoint_parameter</transition>
-         </reachableTransitions>
+         <reachablestates>
+             <state>verticalprofile_instantaneouspoint_parameter</state>
+         </reachablestates>
          <inputvalues>
               <inputvalue name="seriesid" type="Integer" multiselect="false" usedinquery="1"/>
               <inputvalue name="sourceid" type="Integer" multiselect="false" usedinquery="1"/>
               <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
               <inputvalue name="instantaneouspoint_point" type="Integer" multiselect="false" usedinquery="0"/>
          </inputvalues>
-     </transition>
-     <transition id="verticalprofile_instantaneouspoint_parameter" description="verticalprofile_instantaneouspoint_parameter" transition="de.intevation.gnv.transition.DefaultTransition">
+     </state>
+     <state id="verticalprofile_instantaneouspoint_parameter" description="verticalprofile_instantaneouspoint_parameter" state="de.intevation.gnv.state.DefaultState">
          <queryID>verticalprofile_instantaneouspoint_parameter</queryID>
          <dataname>parameterid</dataname>
          <data-multiselect>true</data-multiselect>
-         <reachableTransitions>
-             <transition>verticalprofile_instantaneouspoint_minmaxdepth</transition>
-         </reachableTransitions>
+         <reachablestates>
+             <state>verticalprofile_instantaneouspoint_minmaxdepth</state>
+         </reachablestates>
          <inputvalues>
               <inputvalue name="seriesid" type="Integer" multiselect="false" usedinquery="0" />
               <inputvalue name="instantaneouspoint_point" type="Integer" multiselect="false" usedinquery="1"/>
               <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
               <inputvalue name="parameterid" type="Integer" multiselect="true" usedinquery="0"/>
          </inputvalues>
-     </transition>
-     <transition id="verticalprofile_instantaneouspoint_minmaxdepth" description="verticalprofile_instantaneouspoint_minmaxdepth" transition="de.intevation.gnv.transition.MinMaxTransition">
+     </state>
+     <state id="verticalprofile_instantaneouspoint_minmaxdepth" description="verticalprofile_instantaneouspoint_minmaxdepth" state="de.intevation.gnv.state.MinMaxState">
          <queryID>verticalprofile_instantaneouspoint_minmaxdepth</queryID>
          <dataname>depthrange</dataname>
          <data-multiselect>true</data-multiselect>
-         <reachableTransitions>
-             <transition>verticalprofile_instantaneouspoint_calculate_results</transition>
-         </reachableTransitions>
+         <reachablestates>
+             <state>verticalprofile_instantaneouspoint_calculate_results</state>
+         </reachablestates>
          <inputvalues>
               <inputvalue name="seriesid" type="Integer" multiselect="false" usedinquery="0" />
               <inputvalue name="instantaneouspoint_point" type="Integer" multiselect="false" usedinquery="1"/>
@@ -57,8 +57,8 @@
               <inputvalue name="minvalue" type="Double" multiselect="false" usedinquery="0"/>
               <inputvalue name="maxvalue" type="Double" multiselect="false" usedinquery="0"/>
          </inputvalues>
-     </transition>
-     <transition id="verticalprofile_instantaneouspoint_calculate_results" description="verticalprofile_mesh_calculate_results" transition="de.intevation.gnv.transition.profile.vertical.VerticalProfileOutputTransition">
+     </state>
+     <state id="verticalprofile_instantaneouspoint_calculate_results" description="verticalprofile_mesh_calculate_results" state="de.intevation.gnv.state.profile.vertical.VerticalProfileOutputState">
          <queryID>verticalprofile_instantaneouspoint_chart_data</queryID>
          <queryID-odv>verticalprofile_instantaneouspoint_odv_data</queryID-odv>
          <inputvalues>
@@ -87,6 +87,6 @@
              <outputsMode name="odv" description="ODV-Export der Daten" mime-type="text/plain"/>
              <outputsMode name="statistics" description="Statistik zu den Daten" mime-type="text/xml"/>
          </outputsModes>
-     </transition>
-  </transitions>
+     </state>
+  </states>
 </artifact>
--- a/gnv-artifacts/doc/conf/products/verticalprofile/conf_mesh.xml	Mon Dec 07 17:03:24 2009 +0000
+++ b/gnv-artifacts/doc/conf/products/verticalprofile/conf_mesh.xml	Tue Dec 08 08:39:03 2009 +0000
@@ -1,115 +1,115 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <artifact name="verticalProfileMesh">
-   <transitions>
-       <transition id="verticalprofile_mesh_area" description="verticalprofile_mesh_area_one" transition="de.intevation.gnv.transition.DefaultTransition">
+   <states>
+       <state id="verticalprofile_mesh_area" description="verticalprofile_mesh_area_one" state="de.intevation.gnv.state.DefaultState">
            <queryID>area_filter</queryID>
            <dataname>areaid</dataname>
            <data-multiselect>false</data-multiselect>
             <data-noselect>true</data-noselect>
-           <reachableTransitions>
-                  <transition>verticalprofile_mesh_subarea</transition>
-                  <transition>verticalprofile_mesh_without_geom</transition>
-           </reachableTransitions>
+           <reachablestates>
+                  <state>verticalprofile_mesh_subarea</state>
+                  <state>verticalprofile_mesh_without_geom</state>
+           </reachablestates>
            <inputvalues>
                <inputvalue name="sourceid" type="Integer" multiselect="false" usedinquery="0"/>
                <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                <inputvalue name="areaid" type="Integer" multiselect="false" usedinquery="0"/>
            </inputvalues>
-       </transition>
-       <transition id="verticalprofile_mesh_subarea" description="verticalprofile_mesh_subaera" transition="de.intevation.gnv.transition.DefaultTransition">
+       </state>
+       <state id="verticalprofile_mesh_subarea" description="verticalprofile_mesh_subaera" state="de.intevation.gnv.state.DefaultState">
            <queryID>subarea_filter</queryID>
            <dataname>subareaid</dataname>
            <data-multiselect>false</data-multiselect>
-           <reachableTransitions>
-                  <transition>verticalprofile_mesh</transition>
-           </reachableTransitions>
+           <reachablestates>
+                  <state>verticalprofile_mesh</state>
+           </reachablestates>
            <inputvalues>
                <inputvalue name="sourceid" type="Integer" multiselect="false" usedinquery="0"/>
                <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                <inputvalue name="areaid" type="Integer" multiselect="false" usedinquery="1"/>
                <inputvalue name="subareaid" type="Integer" multiselect="false" usedinquery="0"/>
            </inputvalues>
-       </transition>
+       </state>
        
-        <transition id="verticalprofile_mesh_without_geom" description="timeseries_mesh_without_geom" transition="de.intevation.gnv.transition.DefaultTransition">
+        <state id="verticalprofile_mesh_without_geom" description="timeseries_mesh_without_geom" state="de.intevation.gnv.state.DefaultState">
             <queryID>verticalprofile_mesh</queryID>
             <dataname>meshid</dataname>
             <data-multiselect>false</data-multiselect>
-            <reachableTransitions>
-                   <transition>verticalprofile_mesh_coordinate</transition>
-            </reachableTransitions>
+            <reachablestates>
+                   <state>verticalprofile_mesh_coordinate</state>
+            </reachablestates>
             <inputvalues>
                 <inputvalue name="sourceid" type="Integer" multiselect="false" usedinquery="1"/>
                 <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                 <inputvalue name="meshid" type="Integer" multiselect="false" usedinquery="0"/>
             </inputvalues>
-        </transition>
+        </state>
                
-       <transition id="verticalprofile_mesh" description="verticalprofile_mesh" transition="de.intevation.gnv.transition.DefaultTransition">
+       <state id="verticalprofile_mesh" description="verticalprofile_mesh" state="de.intevation.gnv.state.DefaultState">
            <queryID>verticalprofile_mesh_with_area</queryID>
            <dataname>meshid</dataname>
            <data-multiselect>false</data-multiselect>
-           <reachableTransitions>
-                  <transition>verticalprofile_mesh_coordinate</transition>
-           </reachableTransitions>
+           <reachablestates>
+                  <state>verticalprofile_mesh_coordinate</state>
+           </reachablestates>
            <inputvalues>
                <inputvalue name="sourceid" type="Integer" multiselect="false" usedinquery="1"/>
                <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                <inputvalue name="subareaid" type="Integer" multiselect="false" usedinquery="1"/>
                <inputvalue name="meshid" type="Integer" multiselect="false" usedinquery="0"/>
            </inputvalues>
-       </transition>
+       </state>
        
-       <transition id="verticalprofile_mesh_coordinate" description="verticalprofile_mesh_coordinate" transition="de.intevation.gnv.transition.SingleInputTransition">
+       <state id="verticalprofile_mesh_coordinate" description="verticalprofile_mesh_coordinate" state="de.intevation.gnv.state.SingleInputState">
            <dataname>mesh_coordinate</dataname>
            <data-multiselect>false</data-multiselect>
-           <reachableTransitions>
-                  <transition>verticalprofile_mesh_point</transition>
-           </reachableTransitions>
+           <reachablestates>
+                  <state>verticalprofile_mesh_point</state>
+           </reachablestates>
            <inputvalues>
                 <inputvalue name="meshid" type="Integer" multiselect="false" usedinquery="1"/>
                 <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                 <inputvalue name="mesh_coordinate" type="Coordinate" multiselect="false" usedinquery="0"/>
            </inputvalues>
-       </transition>
+       </state>
        
-       <transition id="verticalprofile_mesh_point" description="verticalprofile_mesh_point" transition="de.intevation.gnv.transition.CoordinateSelectionTransition">
+       <state id="verticalprofile_mesh_point" description="verticalprofile_mesh_point" state="de.intevation.gnv.state.CoordinateSelectionState">
            <queryID>verticalprofile_mesh_point</queryID>
            <dataname>mesh_point</dataname>
            <data-multiselect>false</data-multiselect>
-           <reachableTransitions>
-               <transition>verticalprofile_mesh_mindepth</transition>
-           </reachableTransitions>
+           <reachablestates>
+               <state>verticalprofile_mesh_mindepth</state>
+           </reachablestates>
            <inputvalues>
                 <inputvalue name="meshid" type="Integer" multiselect="false" usedinquery="1"/>
                 <inputvalue name="mesh_coordinate" type="Coordinate" multiselect="false" usedinquery="1"/>
                 <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                 <inputvalue name="mesh_point" type="Integer" multiselect="false" usedinquery="0"/>
            </inputvalues>
-       </transition>
+       </state>
        
-        <transition id="verticalprofile_mesh_mindepth" description="verticalprofile_mesh_mindepth" transition="de.intevation.gnv.transition.DefaultTransition">
+        <state id="verticalprofile_mesh_mindepth" description="verticalprofile_mesh_mindepth" state="de.intevation.gnv.state.DefaultState">
             <queryID>verticalprofile_mesh_mindepth</queryID>
             <dataname>mindepthid</dataname>
             <data-multiselect>false</data-multiselect>
-            <reachableTransitions>
-                <transition>verticalprofile_mesh_maxdepth</transition>
-            </reachableTransitions>
+            <reachablestates>
+                <state>verticalprofile_mesh_maxdepth</state>
+            </reachablestates>
             <inputvalues>
                 <inputvalue name="meshid" type="Integer" multiselect="false" usedinquery="1"/>
                 <inputvalue name="mesh_point" type="Integer" multiselect="false" usedinquery="2"/>
                 <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                 <inputvalue name="mindepthid" type="Double" multiselect="false" usedinquery="0"/>
             </inputvalues>
-        </transition>
+        </state>
         
-        <transition id="verticalprofile_mesh_maxdepth" description="verticalprofile_mesh_maxdepth" transition="de.intevation.gnv.transition.DefaultTransition">
+        <state id="verticalprofile_mesh_maxdepth" description="verticalprofile_mesh_maxdepth" state="de.intevation.gnv.state.DefaultState">
             <queryID>verticalprofile_mesh_maxdepth</queryID>
             <dataname>maxdepthid</dataname>
             <data-multiselect>false</data-multiselect>
-            <reachableTransitions>
-                <transition>verticalprofile_meshpoint_parameter</transition>
-            </reachableTransitions>
+            <reachablestates>
+                <state>verticalprofile_meshpoint_parameter</state>
+            </reachablestates>
             <inputvalues>
                 <inputvalue name="meshid" type="Integer" multiselect="false" usedinquery="1"/>
                 <inputvalue name="mesh_point" type="Integer" multiselect="false" usedinquery="2"/>
@@ -117,14 +117,14 @@
                 <inputvalue name="mindepthid" type="Double" multiselect="false" usedinquery="1"/>
                 <inputvalue name="maxdepthid" type="Double" multiselect="false" usedinquery="0"/>
             </inputvalues>
-        </transition>
-       <transition id="verticalprofile_meshpoint_parameter" description="verticalprofile_meshpoint_parameter" transition="de.intevation.gnv.transition.DefaultTransition">
+        </state>
+       <state id="verticalprofile_meshpoint_parameter" description="verticalprofile_meshpoint_parameter" state="de.intevation.gnv.state.DefaultState">
            <queryID>verticalprofile_mesh_parameter</queryID>
            <dataname>parameterid</dataname>
            <data-multiselect>true</data-multiselect>
-           <reachableTransitions>
-               <transition>verticalprofile_mesh_date</transition>
-           </reachableTransitions>
+           <reachablestates>
+               <state>verticalprofile_mesh_date</state>
+           </reachablestates>
            <inputvalues>
                 <inputvalue name="meshid" type="Integer" multiselect="false" usedinquery="1"/>
                 <inputvalue name="mesh_point" type="Integer" multiselect="false" usedinquery="0"/>
@@ -133,15 +133,15 @@
                 <inputvalue name="maxdepthid" type="Double" multiselect="false" usedinquery="0"/>
                 <inputvalue name="parameterid" type="Integer" multiselect="true" usedinquery="0" />
            </inputvalues>
-       </transition>
+       </state>
        
-       <transition id="verticalprofile_mesh_date" description="verticalprofile_mesh_date" transition="de.intevation.gnv.transition.DefaultTransition">
+       <state id="verticalprofile_mesh_date" description="verticalprofile_mesh_date" state="de.intevation.gnv.state.DefaultState">
            <queryID>verticalprofile_mesh_date</queryID>
            <dataname>dateid</dataname>
            <data-multiselect>true</data-multiselect>
-           <reachableTransitions>
-                <transition>verticalprofile_mesh_calculate_results</transition>
-           </reachableTransitions>
+           <reachablestates>
+                <state>verticalprofile_mesh_calculate_results</state>
+           </reachablestates>
            <inputvalues>
                <inputvalue name="meshid" type="Integer" multiselect="false" usedinquery="1"/>
                <inputvalue name="mesh_point" type="Integer" multiselect="false" usedinquery="0"/>
@@ -151,9 +151,9 @@
                <inputvalue name="maxdepthid" type="Double" multiselect="false" usedinquery="0"/>
                <inputvalue name="dateid" type="Date" multiselect="true" usedinquery="0"/>
            </inputvalues>
-       </transition>
+       </state>
        
-       <transition id="verticalprofile_mesh_calculate_results" description="verticalprofile_mesh_calculate_results" transition="de.intevation.gnv.transition.profile.vertical.VerticalProfileOutputTransition">
+       <state id="verticalprofile_mesh_calculate_results" description="verticalprofile_mesh_calculate_results" state="de.intevation.gnv.state.profile.vertical.VerticalProfileOutputState">
            <queryID>verticalprofile_mesh_chart_data</queryID>
            <queryID-odv>verticalprofile_mesh_odv_data</queryID-odv>
            <inputvalues>
@@ -183,6 +183,6 @@
                <outputsMode name="odv" description="ODV-Export der Daten" mime-type="text/plain"/>
                <outputsMode name="statistics" description="Statistik zu den Daten" mime-type="text/xml"/>
            </outputsModes>
-       </transition>
-   </transitions>
+       </state>
+   </states>
 </artifact>
--- a/gnv-artifacts/doc/conf/products/verticalprofile/conf_timeseriespoint.xml	Mon Dec 07 17:03:24 2009 +0000
+++ b/gnv-artifacts/doc/conf/products/verticalprofile/conf_timeseriespoint.xml	Tue Dec 08 08:39:03 2009 +0000
@@ -1,102 +1,102 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <artifact name="verticalProfile">
-    <transitions>
-        <transition id="verticalprofile_area" description="verticalprofile_area_one" transition="de.intevation.gnv.transition.DefaultTransition">
+    <states>
+        <state id="verticalprofile_area" description="verticalprofile_area_one" state="de.intevation.gnv.state.DefaultState">
             <queryID>area_filter</queryID>
             <dataname>areaid</dataname>
             <data-multiselect>false</data-multiselect>
              <data-noselect>true</data-noselect>
-            <reachableTransitions>
-                   <transition>verticalprofile_subarea</transition>
-                   <transition>verticalprofile_without_geom</transition>
-            </reachableTransitions>
+            <reachablestates>
+                   <state>verticalprofile_subarea</state>
+                   <state>verticalprofile_without_geom</state>
+            </reachablestates>
             <inputvalues>
                 <inputvalue name="sourceid" type="Integer" multiselect="false" usedinquery="0"/>
                 <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                  <inputvalue name="areaid" type="Integer" multiselect="false" usedinquery="0"/>
             </inputvalues>
-        </transition>
+        </state>
         
-        <transition id="verticalprofile_subarea" description="verticalprofile_subaera" transition="de.intevation.gnv.transition.DefaultTransition">
+        <state id="verticalprofile_subarea" description="verticalprofile_subaera" state="de.intevation.gnv.state.DefaultState">
             <queryID>subarea_filter</queryID>
             <dataname>subareaid</dataname>
             <data-multiselect>false</data-multiselect>
-            <reachableTransitions>
-                   <transition>verticalprofile_timeseriespoint</transition>
-            </reachableTransitions>
+            <reachablestates>
+                   <state>verticalprofile_timeseriespoint</state>
+            </reachablestates>
             <inputvalues>
                 <inputvalue name="sourceid" type="Integer" multiselect="false" usedinquery="0"/>
                 <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                 <inputvalue name="areaid" type="Integer" multiselect="false" usedinquery="1"/>
                 <inputvalue name="subareaid" type="Integer" multiselect="false" usedinquery="0"/>
             </inputvalues>
-        </transition>
+        </state>
         
-        <transition id="verticalprofile_without_geom" description="verticalprofile_without_geom" transition="de.intevation.gnv.transition.DefaultTransition">
+        <state id="verticalprofile_without_geom" description="verticalprofile_without_geom" state="de.intevation.gnv.state.DefaultState">
             <queryID>verticalprofile_point</queryID>
             <dataname>featureid</dataname>
             <data-multiselect>false</data-multiselect>
-            <reachableTransitions>
-                   <transition>verticalprofile_parameter</transition>
-            </reachableTransitions>
+            <reachablestates>
+                   <state>verticalprofile_parameter</state>
+            </reachablestates>
             <inputvalues>
                 <inputvalue name="sourceid" type="Integer" multiselect="false" usedinquery="1"/>
                 <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                 <inputvalue name="featureid" type="Integer" multiselect="false" usedinquery="0"/>
             </inputvalues>
-        </transition>
+        </state>
         
-        <transition id="verticalprofile_timeseriespoint" description="timeseries_timeseriespoint" transition="de.intevation.gnv.transition.DefaultTransition">
+        <state id="verticalprofile_timeseriespoint" description="timeseries_timeseriespoint" state="de.intevation.gnv.state.DefaultState">
             <queryID>timeseries_timeseriespoint_with_area</queryID>
             <dataname>featureid</dataname>
             <data-multiselect>false</data-multiselect>
-            <reachableTransitions>
-                <transition>verticalprofile_parameter</transition>
-            </reachableTransitions>
+            <reachablestates>
+                <state>verticalprofile_parameter</state>
+            </reachablestates>
             <inputvalues>
                 <inputvalue name="sourceid" type="Integer" multiselect="false" usedinquery="1"/>
                 <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                 <inputvalue name="subareaid" type="Integer" multiselect="false" usedinquery="1"/>
                 <inputvalue name="featureid" type="Integer" multiselect="false" usedinquery="0"/>
             </inputvalues>
-        </transition>
+        </state>
         
-        <transition id="verticalprofile_parameter" description="timeseries_parameter" transition="de.intevation.gnv.transition.DefaultTransition">
+        <state id="verticalprofile_parameter" description="timeseries_parameter" state="de.intevation.gnv.state.DefaultState">
             <queryID>verticalprofile_parameter</queryID>
             <dataname>parameterid</dataname>
             <data-multiselect>true</data-multiselect>
-            <reachableTransitions>
-                <transition>verticalprofile_date</transition>
-            </reachableTransitions>
+            <reachablestates>
+                <state>verticalprofile_date</state>
+            </reachablestates>
             <inputvalues>
                 <inputvalue name="featureid" type="Integer" multiselect="false"  usedinquery="1"/>
                 <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                 <inputvalue name="parameterid" type="Integer" multiselect="true"  usedinquery="0"/>
             </inputvalues>
-        </transition>
+        </state>
         
-        <transition id="verticalprofile_date" description="verticalprofile_date" transition="de.intevation.gnv.transition.DefaultTransition">
+        <state id="verticalprofile_date" description="verticalprofile_date" state="de.intevation.gnv.state.DefaultState">
             <queryID>verticalprofile_date</queryID>
             <dataname>dateid</dataname>
             <data-multiselect>true</data-multiselect>
-            <reachableTransitions>
-                 <transition>verticalprofile_minmaxdepth</transition>
-            </reachableTransitions>
+            <reachablestates>
+                 <state>verticalprofile_minmaxdepth</state>
+            </reachablestates>
             <inputvalues>
                 <inputvalue name="featureid" type="Integer" multiselect="false"  usedinquery="1"/>
                 <inputvalue name="parameterid" type="Integer" multiselect="true" usedinquery="1"/>
                 <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
                 <inputvalue name="dateid" type="Date" multiselect="true" usedinquery="0"/>
             </inputvalues>
-        </transition>
+        </state>
         
-        <transition id="verticalprofile_minmaxdepth" description="verticalprofile_minmaxdepth" transition="de.intevation.gnv.transition.MinMaxTransition">
+        <state id="verticalprofile_minmaxdepth" description="verticalprofile_minmaxdepth" state="de.intevation.gnv.state.MinMaxState">
             <queryID>verticalprofile_minmaxdepth</queryID>
             <dataname>depthrange</dataname>
             <data-multiselect>true</data-multiselect>
-            <reachableTransitions>
-                 <transition>verticalprofile_calculate_results</transition>
-            </reachableTransitions>
+            <reachablestates>
+                 <state>verticalprofile_calculate_results</state>
+            </reachablestates>
             <inputvalues>
                 <inputvalue name="featureid" type="Integer" multiselect="false" usedinquery="1"/>
                 <inputvalue name="parameterid" type="Integer" multiselect="true" usedinquery="1"/>
@@ -105,9 +105,9 @@
                 <inputvalue name="minvalue" type="Double" multiselect="false" usedinquery="0"/>
                 <inputvalue name="maxvalue" type="Double" multiselect="false" usedinquery="0"/>
             </inputvalues>
-        </transition>
+        </state>
         
-        <transition id="verticalprofile_calculate_results" description="verticalprofile_calculate_results" transition="de.intevation.gnv.transition.profile.vertical.VerticalProfileOutputTransition">
+        <state id="verticalprofile_calculate_results" description="verticalprofile_calculate_results" state="de.intevation.gnv.state.profile.vertical.VerticalProfileOutputState">
             <queryID>verticalprofile_chart_data</queryID>
             <queryID-odv>verticalprofile_odv_data</queryID-odv>
             <inputvalues>
@@ -136,6 +136,6 @@
                 <outputsMode name="odv" description="ODV-Export der Daten" mime-type="text/plain"/>
                 <outputsMode name="statistics" description="Statistik zu den Daten" mime-type="text/xml"/>
             </outputsModes>
-        </transition>
-    </transitions>
+        </state>
+    </states>
 </artifact>
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/artifacts/GNVArtifactBase.java	Mon Dec 07 17:03:24 2009 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/artifacts/GNVArtifactBase.java	Tue Dec 08 08:39:03 2009 +0000
@@ -26,14 +26,14 @@
 import de.intevation.artifacts.CallContext;
 import de.intevation.artifacts.CallMeta;
 import de.intevation.gnv.artifacts.context.GNVArtifactContext;
-import de.intevation.gnv.transition.DefaultInputData;
-import de.intevation.gnv.transition.InputData;
-import de.intevation.gnv.transition.InputValue;
-import de.intevation.gnv.transition.OutputMode;
-import de.intevation.gnv.transition.OutputTransition;
-import de.intevation.gnv.transition.Transition;
-import de.intevation.gnv.transition.TransitionFactory;
-import de.intevation.gnv.transition.exception.TransitionException;
+import de.intevation.gnv.state.DefaultInputData;
+import de.intevation.gnv.state.InputData;
+import de.intevation.gnv.state.InputValue;
+import de.intevation.gnv.state.OutputMode;
+import de.intevation.gnv.state.OutputState;
+import de.intevation.gnv.state.State;
+import de.intevation.gnv.state.StateFactory;
+import de.intevation.gnv.state.exception.StateException;
 import de.intevation.gnv.utils.ArtifactXMLUtilities;
 
 /**
@@ -63,14 +63,14 @@
                                                               + "']";
 
     /**
-     * The current Transition
+     * The current State
      */
-    protected Transition current = null;
+    protected State current = null;
 
     /**
-     * The Transitions that can be used
+     * The States that can be used
      */
-    protected Map<String, Transition> transitions = null;
+    protected Map<String, State> states = null;
 
     /**
      * The Name of the Artifact
@@ -96,12 +96,12 @@
         Document result = XMLUtils.newDocument();
         try {
             if (this.current != null) {
-                String transitionName = this.readTransitionName(target);
-                log.debug("Transitionsname: " + transitionName);
-                if (this.current.isTransitionReachable(transitionName)) {
+                String stateName = this.readStateName(target);
+                log.debug("Statename: " + stateName);
+                if (this.current.isStateReachable(stateName)) {
                     try {
-                        Transition nextStep = this.transitions
-                                .get(transitionName);
+                        State nextStep = this.states
+                                .get(stateName);
                         // 1.Ergebnisse Berechnen
                         this.current.advance(super.identifier, context.getMeta());
                         // 2. Ergebnisse Übergeben
@@ -116,7 +116,7 @@
                         result = new ArtifactXMLUtilities()
                                 .createSuccessReport("Advance success",
                                         XMLUtils.newDocument());
-                    } catch (TransitionException e) {
+                    } catch (StateException e) {
                         log.error(e, e);
                         result = new ArtifactXMLUtilities()
                                 .createExceptionReport(e
@@ -130,7 +130,7 @@
                             msg, XMLUtils.newDocument());
                 }
             } else {
-                String msg = "Kein Transitionsschritt aktiviert.";
+                String msg = "Kein State aktiviert.";
                 log.error(msg);
                 result = new ArtifactXMLUtilities().createExceptionReport(msg,
                         XMLUtils.newDocument());
@@ -151,7 +151,7 @@
             result = new ArtifactXMLUtilities()
             .createSuccessReport("Initialize success",
                     XMLUtils.newDocument());
-        } catch (TransitionException e) {
+        } catch (StateException e) {
             log.error(e,e);
             result = new ArtifactXMLUtilities().createExceptionReport(e
                     .getLocalizedMessage(), XMLUtils.newDocument());
@@ -159,7 +159,7 @@
         return result;
     }
 
-    protected String readTransitionName(Document document) {
+    protected String readStateName(Document document) {
         String returnValue = Config.getStringXPath(document,
                 "action/target/@name");
         return returnValue;
@@ -205,12 +205,12 @@
                             XMLUtils.newDocument());
                 }
             } else {
-                String msg = "No Transition instantiated";
+                String msg = "No State instantiated";
                 log.warn(msg);
                 result = new ArtifactXMLUtilities().createExceptionReport(msg,
                         XMLUtils.newDocument());
             }
-        } catch (TransitionException e) {
+        } catch (StateException e) {
             log.error(e, e);
             result = new ArtifactXMLUtilities().createExceptionReport(e
                     .getLocalizedMessage(), XMLUtils.newDocument());
@@ -238,17 +238,17 @@
             Document doc = gnvContext.getConfig();
             Node artifactNode = this.getConfigurationFragment(doc);
                         
-            NodeList transitionList = Config.getNodeSetXPath(artifactNode,
-                    "transitions/transition");
-            this.transitions = new HashMap<String, Transition>(transitionList
+            NodeList stateList = Config.getNodeSetXPath(artifactNode,
+                    "states/state");
+            this.states = new HashMap<String, State>(stateList
                     .getLength());
-            for (int i = 0; i < transitionList.getLength(); i++) {
-                Transition tmpTransition = TransitionFactory.getInstance()
-                        .createTransition(transitionList.item(i));
-                if (tmpTransition != null) {
-                    this.transitions.put(tmpTransition.getID(), tmpTransition);
+            for (int i = 0; i < stateList.getLength(); i++) {
+                State tmpState = StateFactory.getInstance()
+                        .createState(stateList.item(i));
+                if (tmpState != null) {
+                    this.states.put(tmpState.getID(), tmpState);
                     if (this.current == null) {
-                        this.current = tmpTransition;
+                        this.current = tmpState;
                     }
                 }
             }
@@ -308,7 +308,7 @@
         Element stateNode = xmlUtilities.createArtifactElement(document,
                 "reachable-states");
         if (this.current != null) {
-            Iterator<String> states = this.current.reachableTransitions()
+            Iterator<String> states = this.current.reachableStates()
                     .iterator();
             while (states.hasNext()) {
                 String value = states.next();
@@ -316,7 +316,7 @@
                         document, "state");
                 currentNode.setAttribute("name", value);
                 log.debug("Reachable State: " + value);
-                currentNode.setAttribute("description", transitions.get(value)
+                currentNode.setAttribute("description", this.states.get(value)
                         .getDescription());
                 stateNode.appendChild(currentNode);
             }
@@ -368,8 +368,8 @@
         log.debug("GNVArtifactBase.createOutputs");
         Element outputsNode = xmlUtilities.createArtifactElement(document,
                 "outputs");
-        if (this.current instanceof OutputTransition) {
-            Collection<OutputMode> outputModes = ((OutputTransition) this.current)
+        if (this.current instanceof OutputState) {
+            Collection<OutputMode> outputModes = ((OutputState) this.current)
                     .getOutputModes();
             if (outputModes != null) {
                 Iterator<OutputMode> it = outputModes.iterator();
@@ -457,13 +457,13 @@
         log.debug("TGNVArtifactBase.out");
         try {
 
-            if (current != null && current instanceof OutputTransition) {
-                ((OutputTransition) current)
+            if (current != null && current instanceof OutputState) {
+                ((OutputState) current)
                         .out(format, this.parseInputData(
                                 format, "/action/out/params/input"),
                                 outputStream, super.identifier, context.getMeta());
             }
-        } catch (TransitionException e) {
+        } catch (StateException e) {
             log.error(e, e);
             throw new IOException(e.getMessage());
         }
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/artifacts/fis/FISArtifact.java	Mon Dec 07 17:03:24 2009 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/artifacts/fis/FISArtifact.java	Tue Dec 08 08:39:03 2009 +0000
@@ -29,8 +29,8 @@
 import de.intevation.gnv.artifacts.fis.product.DefaultProduct;
 import de.intevation.gnv.artifacts.fis.product.Product;
 import de.intevation.gnv.artifacts.ressource.RessourceFactory;
-import de.intevation.gnv.transition.DefaultInputData;
-import de.intevation.gnv.transition.InputData;
+import de.intevation.gnv.state.DefaultInputData;
+import de.intevation.gnv.state.InputData;
 import de.intevation.gnv.utils.ArtifactFactoryUtilities;
 import de.intevation.gnv.utils.ArtifactXMLUtilities;
 
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/artifacts/fis/product/DefaultProduct.java	Mon Dec 07 17:03:24 2009 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/artifacts/fis/product/DefaultProduct.java	Tue Dec 08 08:39:03 2009 +0000
@@ -6,7 +6,7 @@
 import java.util.Collection;
 
 import de.intevation.artifacts.ArtifactFactory;
-import de.intevation.gnv.transition.InputData;
+import de.intevation.gnv.state.InputData;
 
 /**
  * @author Tim Englich <tim.englich@intevation.de>
@@ -14,6 +14,11 @@
  */
 public class DefaultProduct implements Product {
 
+    /**
+     * The UID of this Class
+     */
+    private static final long serialVersionUID = 6473812725442092770L;
+
     private String name = null;
 
     private Collection<InputData> parameter = null;
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/artifacts/fis/product/Product.java	Mon Dec 07 17:03:24 2009 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/artifacts/fis/product/Product.java	Tue Dec 08 08:39:03 2009 +0000
@@ -7,7 +7,7 @@
 import java.util.Collection;
 
 import de.intevation.artifacts.ArtifactFactory;
-import de.intevation.gnv.transition.InputData;
+import de.intevation.gnv.state.InputData;
 
 /**
  * @author Tim Englich <tim.englich@intevation.de>
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/chart/AbstractXYLineChart.java	Mon Dec 07 17:03:24 2009 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/chart/AbstractXYLineChart.java	Tue Dec 08 08:39:03 2009 +0000
@@ -23,7 +23,7 @@
 import org.jfree.data.general.Series;
 
 import de.intevation.gnv.geobackend.base.Result;
-import de.intevation.gnv.transition.describedata.KeyValueDescibeData;
+import de.intevation.gnv.state.describedata.KeyValueDescibeData;
 
 
 /**
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/chart/ChartFactory.java	Mon Dec 07 17:03:24 2009 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/chart/ChartFactory.java	Tue Dec 08 08:39:03 2009 +0000
@@ -44,8 +44,8 @@
 
 import de.intevation.gnv.chart.exception.TechnicalChartException;
 import de.intevation.gnv.geobackend.base.Result;
+import de.intevation.gnv.state.describedata.KeyValueDescibeData;
 import de.intevation.gnv.timeseries.gap.TimeGap;
-import de.intevation.gnv.transition.describedata.KeyValueDescibeData;
 
 /**
  * The class <code>ChartFactory</code> fulfills the following purposes:
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/chart/HorizontalCrossSectionChartFactory.java	Mon Dec 07 17:03:24 2009 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/chart/HorizontalCrossSectionChartFactory.java	Tue Dec 08 08:39:03 2009 +0000
@@ -24,7 +24,7 @@
 
 import de.intevation.gnv.chart.exception.TechnicalChartException;
 import de.intevation.gnv.geobackend.base.Result;
-import de.intevation.gnv.transition.describedata.KeyValueDescibeData;
+import de.intevation.gnv.state.describedata.KeyValueDescibeData;
 
 /**
  * 
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/chart/HorizontalProfileChartFactory.java	Mon Dec 07 17:03:24 2009 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/chart/HorizontalProfileChartFactory.java	Tue Dec 08 08:39:03 2009 +0000
@@ -27,7 +27,7 @@
 
 import de.intevation.gnv.chart.exception.TechnicalChartException;
 import de.intevation.gnv.geobackend.base.Result;
-import de.intevation.gnv.transition.describedata.KeyValueDescibeData;
+import de.intevation.gnv.state.describedata.KeyValueDescibeData;
 import de.intevation.gnv.utils.DistanceCalculator;
 
 /**
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/chart/TimeSeriesChart.java	Mon Dec 07 17:03:24 2009 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/chart/TimeSeriesChart.java	Tue Dec 08 08:39:03 2009 +0000
@@ -23,7 +23,7 @@
 import org.jfree.data.time.TimeSeriesCollection;
 
 import de.intevation.gnv.geobackend.base.Result;
-import de.intevation.gnv.transition.describedata.KeyValueDescibeData;
+import de.intevation.gnv.state.describedata.KeyValueDescibeData;
 import de.intevation.gnv.timeseries.gap.TimeGap;
 
 
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/chart/VerticalCrossSectionChartFactory.java	Mon Dec 07 17:03:24 2009 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/chart/VerticalCrossSectionChartFactory.java	Tue Dec 08 08:39:03 2009 +0000
@@ -24,7 +24,7 @@
 
 import de.intevation.gnv.chart.exception.TechnicalChartException;
 import de.intevation.gnv.geobackend.base.Result;
-import de.intevation.gnv.transition.describedata.KeyValueDescibeData;
+import de.intevation.gnv.state.describedata.KeyValueDescibeData;
 
 /**
  * 
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/chart/VerticalProfileChart.java	Mon Dec 07 17:03:24 2009 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/chart/VerticalProfileChart.java	Tue Dec 08 08:39:03 2009 +0000
@@ -9,7 +9,6 @@
 
 import org.jfree.chart.ChartTheme;
 import org.jfree.chart.axis.Axis;
-import org.jfree.chart.axis.NumberAxis;
 import org.jfree.chart.plot.XYPlot;
 import org.jfree.chart.plot.PlotOrientation;
 import org.jfree.data.xy.XYSeries;
@@ -17,7 +16,7 @@
 import org.jfree.data.xy.XYSeriesCollection;
 
 import de.intevation.gnv.geobackend.base.Result;
-import de.intevation.gnv.transition.describedata.KeyValueDescibeData;
+import de.intevation.gnv.state.describedata.KeyValueDescibeData;
 
 
 /**
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/chart/VerticalProfileChartFactory.java	Mon Dec 07 17:03:24 2009 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/chart/VerticalProfileChartFactory.java	Tue Dec 08 08:39:03 2009 +0000
@@ -41,7 +41,7 @@
 
 import de.intevation.gnv.chart.exception.TechnicalChartException;
 import de.intevation.gnv.geobackend.base.Result;
-import de.intevation.gnv.transition.describedata.KeyValueDescibeData;
+import de.intevation.gnv.state.describedata.KeyValueDescibeData;
 
 /**
  * 
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/exports/DefaultDataCollector.java	Mon Dec 07 17:03:24 2009 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/exports/DefaultDataCollector.java	Tue Dec 08 08:39:03 2009 +0000
@@ -7,7 +7,7 @@
 
 import de.intevation.gnv.geobackend.base.Result;
 import de.intevation.gnv.geobackend.base.ResultDescriptor;
-import de.intevation.gnv.transition.exception.TransitionException;
+import de.intevation.gnv.state.exception.StateException;
 
 
 /**
@@ -31,7 +31,7 @@
     }
 
     public String[] getData(Result result)
-    throws TransitionException {
+    throws StateException {
 
         if (rd == null)
             init(result);
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/exports/DefaultExport.java	Mon Dec 07 17:03:24 2009 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/exports/DefaultExport.java	Tue Dec 08 08:39:03 2009 +0000
@@ -12,11 +12,9 @@
 import java.io.OutputStreamWriter;
 import java.io.OutputStream;
 
-import de.intevation.gnv.exports.Export.Profile;
-
 import de.intevation.gnv.geobackend.base.Result;
 
-import de.intevation.gnv.transition.exception.TransitionException;
+import de.intevation.gnv.state.exception.StateException;
 
 /**
  * @author Sascha L. Teichmann (sascha.teichmann@intevation.de)
@@ -38,7 +36,7 @@
         Collection result,
         CSVWriter  writer
     )
-    throws TransitionException {
+    throws StateException {
         log.debug("create content for export.");
         Iterator<Result> it = result.iterator();
 
@@ -61,13 +59,13 @@
     throws
         IOException,
         UnsupportedEncodingException,
-        TransitionException 
+        StateException 
     {
         if (result == null) {
             String msg = "No data given for generation of " +
                 profile.getType() + " file.";
             log.error(msg);
-            throw new TransitionException(msg);
+            throw new StateException(msg);
         }
 
         CSVWriter writer = new CSVWriter(
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/exports/Export.java	Mon Dec 07 17:03:24 2009 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/exports/Export.java	Tue Dec 08 08:39:03 2009 +0000
@@ -7,7 +7,7 @@
 import java.io.UnsupportedEncodingException;
 
 import de.intevation.gnv.geobackend.base.Result;
-import de.intevation.gnv.transition.exception.TransitionException;
+import de.intevation.gnv.state.exception.StateException;
 
 /**
  * @author Sascha L. Teichmann (sascha.teichmann@intevation.de)
@@ -27,7 +27,7 @@
 
     public interface DataCollector {
         String[] getData(Result result)
-        throws TransitionException;
+        throws StateException;
     }
 
     public void create(
@@ -35,6 +35,6 @@
         OutputStream outputStream, 
         Collection   result
     )
-    throws IOException, UnsupportedEncodingException, TransitionException;
+    throws IOException, UnsupportedEncodingException, StateException;
 
 }
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/exports/ShapeDataCollector.java	Mon Dec 07 17:03:24 2009 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/exports/ShapeDataCollector.java	Tue Dec 08 08:39:03 2009 +0000
@@ -7,7 +7,7 @@
 import com.vividsolutions.jts.geom.Point;
 
 import de.intevation.gnv.geobackend.base.Result;
-import de.intevation.gnv.transition.exception.TransitionException;
+import de.intevation.gnv.state.exception.StateException;
 
 
 /**
@@ -25,7 +25,7 @@
     }
 
     public String[] getData(Result result) 
-    throws TransitionException {
+    throws StateException {
 
         if (rd == null)
             init(result);
@@ -50,7 +50,7 @@
         }
         catch (ParseException pe) {
             log.error(pe, pe);
-            throw new TransitionException(
+            throw new StateException(
                 "Error occured while parsing a Point from WKT.");
         }
     }
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/exports/SimpleOdvDataCollector.java	Mon Dec 07 17:03:24 2009 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/exports/SimpleOdvDataCollector.java	Tue Dec 08 08:39:03 2009 +0000
@@ -10,7 +10,7 @@
 import com.vividsolutions.jts.geom.Point;
 
 import de.intevation.gnv.geobackend.base.Result;
-import de.intevation.gnv.transition.exception.TransitionException;
+import de.intevation.gnv.state.exception.StateException;
 
 /**
  * @author Ingo Weinzierl (ingo.weinzierl@intevation.de)
@@ -31,7 +31,7 @@
     }
 
     public String[] getData(Result result)
-    throws TransitionException
+    throws StateException
     {
         if (rd == null)
             init(result);
@@ -62,12 +62,12 @@
         }
         catch (ParseException pe) {
             log.error(pe, pe);
-            throw new TransitionException(
+            throw new StateException(
                 "Error occured while parsing source data.");
         }
         catch (java.text.ParseException pe) {
             log.error(pe, pe);
-            throw new TransitionException(
+            throw new StateException(
                 "Error occured while parsing source data.");
         }
     }
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/state/CoordinateSelectionState.java	Tue Dec 08 08:39:03 2009 +0000
@@ -0,0 +1,138 @@
+/**
+ *
+ */
+package de.intevation.gnv.state;
+
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.Iterator;
+
+import org.apache.log4j.Logger;
+
+import com.vividsolutions.jts.geom.Point;
+import com.vividsolutions.jts.io.ParseException;
+import com.vividsolutions.jts.io.WKTReader;
+
+import de.intevation.gnv.geobackend.base.Result;
+import de.intevation.gnv.state.describedata.DefaultKeyValueDescribeData;
+import de.intevation.gnv.state.describedata.KeyValueDescibeData;
+import de.intevation.gnv.state.describedata.NamedArrayList;
+import de.intevation.gnv.state.describedata.NamedCollection;
+import de.intevation.gnv.utils.InputValidator;
+import de.intevation.gnv.utils.exception.ValidationException;
+
+/**
+ * @author Tim Englich <tim.englich@intevation.de>
+ *
+ */
+public class CoordinateSelectionState extends StateBase {
+
+    /**
+     * the logger, used to log exceptions and additonaly information
+     */
+    private static Logger log = Logger.getLogger(CoordinateSelectionState.class);
+    
+    /**
+     * The UID of this Class
+     */
+    private static final long serialVersionUID = 6318923553625195063L;
+
+    /**
+     * Constructor
+     */
+    public CoordinateSelectionState() {
+        super();
+    }
+
+    @Override
+    protected void purifyResult(Collection<Result> result, String uuid) {
+        log.debug("CoordinateSelectionState.purifyResult");
+        Collection<Object> describeData = this.getDescibeData(uuid);
+        if (describeData == null) {
+            describeData = new ArrayList<Object>();
+        }
+        NamedCollection<KeyValueDescibeData> keyValueDescibeData = this
+                .extractKVP(result, "FEATUREID", "SHAPE");
+        describeData.add(keyValueDescibeData);
+        this.setDescibeData(uuid, describeData);
+    }
+    
+    @Override
+    protected String prepareInputData4RegionDBQuery(String value) {
+        log.debug("CoordinateSelectionState.prepareInputData4RegionDBQuery");
+        double distance=0.;
+        String returnValue = null;
+        try {
+            Point center = new InputValidator().getPointValue(value);
+            String meshIDValue = super.inputData.get("meshid").getValue();
+            int segments = 97;
+            int meshid = new Integer(meshIDValue);
+            if (meshid == 3 || meshid == 5){ // TODO nicht hier festbrennen.
+                distance = 0.15; //nord-ostsee 6nm // 97 Stützpunkte
+            }else if (meshid == 1 || meshid == 4){
+                distance = 0.03; //Kuestenmodell 1 nm
+            }else if (meshid == 2 || meshid == 321){
+                distance = 0.3; //SST Karten ca 20km
+            }else if (meshid == 641){
+                distance = 0.3; //Eisdaten Klima
+            }
+            returnValue = center.buffer(distance,segments).toText();
+        } catch (NumberFormatException e) {
+            log.error(e,e);
+        } catch (ValidationException e) {
+            log.error(e,e);
+        }
+        return returnValue;
+        
+    }
+    
+    /**
+     * @see de.intevation.gnv.state.StateBase#extractKVP(java.util.Collection, java.lang.String, java.lang.String)
+     */
+    @Override
+    protected NamedCollection<KeyValueDescibeData> extractKVP(
+            Collection<Result> result,
+            String keyid,
+            String valueid) {
+        Iterator<Result> rit = result.iterator();
+        NamedCollection<KeyValueDescibeData> keyValueDescibeData = new NamedArrayList<KeyValueDescibeData>(
+        this.dataName, result.size());
+        keyValueDescibeData.setMultiSelect(this.dataMultiSelect);
+        String prevKey = null;
+        while (rit.hasNext()) {
+            Result resultValue = rit.next();
+            String key = resultValue.getString(keyid);
+            if(prevKey == null || !prevKey.equals(key)){ // müssen wir so machen, da die sde kein select distinct auf layern zulässt.
+                String geomString = this.convert2DisplayCoordinate(resultValue.getString(valueid));
+                String value = geomString;
+                if (resultValue.getResultDescriptor().getColumnIndex("VALUE") > 0){
+                    value = resultValue.getString("VALUE") + " - "+value;
+                }
+                
+                
+                keyValueDescibeData.add(new DefaultKeyValueDescribeData(key,value ));
+            }
+            prevKey = key;
+        }
+        return keyValueDescibeData;
+    }
+    
+    protected String convert2DisplayCoordinate(String wkt){
+        String formattedCoordinate = null;
+        try {
+            Point p = (Point)new WKTReader().read(wkt);
+            double lat = p.getY();
+            double lon =p.getX();
+            String nord="N";
+            String ost="E";
+            if (lat <0 ){nord="S"; lat=-lat;}
+            if (lon <0 ){ost="W"; lon=-lon;}
+            formattedCoordinate =  String.format("%1$02d°%2$1S %3$05.2f' %4$03d°%5$1S %6$05.2f'",
+                                  (int)lat, nord,60.*(lat-((int)lat)),(int)lon,ost,60.*(lon-((int)lon)));
+        } catch (ParseException e) {
+            log.error(e,e);
+        }
+        
+        return formattedCoordinate;
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/state/DefaultInputData.java	Tue Dec 08 08:39:03 2009 +0000
@@ -0,0 +1,56 @@
+/**
+ *
+ */
+package de.intevation.gnv.state;
+
+/**
+ * @author Tim Englich <tim.englich@intevation.de>
+ * 
+ */
+public class DefaultInputData implements InputData {
+
+    /**
+     *
+     */
+    private static final long serialVersionUID = 4308041648698108066L;
+    private String name = null;
+    private String value = null;
+
+    /**
+     * Constructor
+     */
+    public DefaultInputData(String name, String value) {
+        this.name = name;
+        this.value = value;
+    }
+
+    /**
+     * @see de.intevation.gnv.state.InputData#getName()
+     */
+    public String getName() {
+        return this.name;
+    }
+
+    /**
+     * @see de.intevation.gnv.state.InputData#getValue()
+     */
+    public String getValue() {
+        return this.value;
+    }
+
+    /**
+     * @see java.lang.Object#toString()
+     */
+    @Override
+    public String toString() {
+        return this.name + "==> " + this.value;
+    }
+
+    /**
+     * @see de.intevation.gnv.state.InputData#concartValue(java.lang.String)
+     */
+    public void concartValue(String value) {
+        this.value = this.value + " , " + value;
+    }
+
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/state/DefaultInputValue.java	Tue Dec 08 08:39:03 2009 +0000
@@ -0,0 +1,78 @@
+/**
+ *
+ */
+package de.intevation.gnv.state;
+
+/**
+ * @author Tim Englich <tim.englich@intevation.de>
+ * 
+ */
+public class DefaultInputValue implements InputValue {
+
+    /**
+     * The UID of this Class.
+     */
+    private static final long serialVersionUID = -8518824299166180986L;
+    private String name = null;
+    private String type = null;
+    private boolean multiselect = false;
+    private int usedInQueries = 1;
+    private String defaultValue = "N/N";
+
+    public DefaultInputValue(String name, String type, String defaultValue,
+                             boolean multiselect) {
+        this(name, type, multiselect, 1);
+        this.defaultValue = defaultValue;
+
+    }
+
+    /**
+     * Constructor
+     */
+    public DefaultInputValue(String name, String type, boolean multiselect,
+                             int usedInQueries) {
+        this.name = name;
+        this.type = type;
+        this.multiselect = multiselect;
+        this.usedInQueries = usedInQueries;
+    }
+
+    /**
+     * @see de.intevation.gnv.state.InputValue#getName()
+     */
+    public String getName() {
+        return this.name;
+    }
+
+    /**
+     * @see de.intevation.gnv.state.InputValue#getType()
+     */
+    public String getType() {
+        return this.type;
+    }
+
+    /**
+     * @see java.lang.Object#toString()
+     */
+    @Override
+    public String toString() {
+        return "InputValue " + this.name + " ==> " + this.type
+               + "==> multiselect: " + this.multiselect;
+    }
+
+    /**
+     * @see de.intevation.gnv.state.InputValue#isMultiselect()
+     */
+    public boolean isMultiselect() {
+        return this.multiselect;
+    }
+
+    public int usedInQueries() {
+        return this.usedInQueries;
+    }
+
+    public String getDefaultValue() {
+        return this.defaultValue;
+    }
+
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/state/DefaultOutputMode.java	Tue Dec 08 08:39:03 2009 +0000
@@ -0,0 +1,76 @@
+/**
+ *
+ */
+package de.intevation.gnv.state;
+
+import java.util.Collection;
+
+/**
+ * @author Tim Englich <tim.englich@intevation.de>
+ * 
+ */
+public class DefaultOutputMode implements OutputMode {
+
+    /**
+     * The UID of this Class.
+     */
+    private static final long serialVersionUID = -6459085460904827056L;
+    private String name = null;
+    private String description = null;
+    private String mimeType = null;
+    private Collection<InputValue> inputParameters = null;
+
+    /**
+     * Constructor
+     * 
+     * @param name
+     * @param description
+     * @param mimeType
+     */
+    public DefaultOutputMode(String name, String description, String mimeType,
+                             Collection<InputValue> inputParameters) {
+        super();
+        this.name = name;
+        this.description = description;
+        this.mimeType = mimeType;
+        this.inputParameters = inputParameters;
+    }
+
+    /**
+     * @see de.intevation.gnv.state.OutputMode#getDescription()
+     */
+    public String getDescription() {
+        return this.description;
+    }
+
+    /**
+     * @see de.intevation.gnv.state.OutputMode#getMimeType()
+     */
+    public String getMimeType() {
+        return this.mimeType;
+    }
+
+    /**
+     * @see de.intevation.gnv.state.OutputMode#getName()
+     */
+    public String getName() {
+        return this.name;
+    }
+
+    /**
+     * @see java.lang.Object#toString()
+     */
+    @Override
+    public String toString() {
+        return "Name: " + this.name + " ; Description: " + this.description
+               + " ; Mime-Type: " + this.mimeType;
+    }
+
+    /**
+     * @see de.intevation.gnv.state.OutputMode#getInputParameters()
+     */
+    public Collection<InputValue> getInputParameters() {
+        return this.inputParameters;
+    }
+
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/state/DefaultState.java	Tue Dec 08 08:39:03 2009 +0000
@@ -0,0 +1,23 @@
+/**
+ *
+ */
+package de.intevation.gnv.state;
+
+/**
+ * @author Tim Englich <tim.englich@intevation.de>
+ * 
+ */
+public class DefaultState extends StateBase {
+
+    /**
+     * The UID of this Class
+     */
+    private static final long serialVersionUID = 8934030362091576766L;
+
+    /**
+     * Constructor
+     */
+    public DefaultState() {
+    }
+
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/state/InputData.java	Tue Dec 08 08:39:03 2009 +0000
@@ -0,0 +1,19 @@
+/**
+ *
+ */
+package de.intevation.gnv.state;
+
+import java.io.Serializable;
+
+/**
+ * @author Tim Englich <tim.englich@intevation.de>
+ * 
+ */
+public interface InputData extends Serializable {
+
+    public String getName();
+
+    public String getValue();
+
+    public void concartValue(String value);
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/state/InputValue.java	Tue Dec 08 08:39:03 2009 +0000
@@ -0,0 +1,24 @@
+/**
+ *
+ */
+package de.intevation.gnv.state;
+
+import java.io.Serializable;
+
+/**
+ * @author Tim Englich <tim.englich@intevation.de>
+ * 
+ */
+public interface InputValue extends Serializable {
+
+    public String getName();
+
+    public String getType();
+
+    public String getDefaultValue();
+
+    public boolean isMultiselect();
+
+    public int usedInQueries();
+
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/state/MinMaxState.java	Tue Dec 08 08:39:03 2009 +0000
@@ -0,0 +1,62 @@
+/**
+ *
+ */
+package de.intevation.gnv.state;
+
+import java.util.ArrayList;
+import java.util.Collection;
+
+import org.apache.log4j.Logger;
+
+import de.intevation.gnv.geobackend.base.Result;
+import de.intevation.gnv.state.describedata.DefaultMinMaxDescribeData;
+import de.intevation.gnv.state.describedata.DescribeData;
+
+/**
+ * @author Tim Englich <tim.englich@intevation.de>
+ * 
+ */
+public class MinMaxState extends StateBase {
+
+    /**
+     * The UID of this Class
+     */
+    private static final long serialVersionUID = -3525903792105187408L;
+    /**
+     * the logger, used to log exceptions and additonaly information
+     */
+    private static Logger log = Logger.getLogger(MinMaxState.class);
+
+    /**
+     * Constructor
+     */
+    public MinMaxState() {
+        super();
+    }
+
+    /**
+     * @see de.intevation.gnv.state.StateBase#purifyResult(java.util.Collection,
+     *      java.lang.String)
+     */
+    @Override
+    protected void purifyResult(Collection<Result> result, String uuid) {
+        log.debug("MinMaxState.purifyResult");
+        Collection<Object> describeData = this.getDescibeData(uuid);
+        if (describeData == null) {
+            describeData = new ArrayList<Object>();
+        }
+        if (result != null && result.size() == 1) {
+            
+            Result value = result.iterator().next();
+            DescribeData values = new DefaultMinMaxDescribeData(this.dataName, 
+                                                               value.getObject("MIN"), 
+                                                               value.getObject("MAX"));
+            log.debug(values.toString());
+            describeData.add(values);
+        } else {
+            log.warn("Result cannot be handled as MinMax Resultset");
+        }
+        this.setDescibeData(uuid, describeData);
+    }
+
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/state/OutputMode.java	Tue Dec 08 08:39:03 2009 +0000
@@ -0,0 +1,22 @@
+/**
+ *
+ */
+package de.intevation.gnv.state;
+
+import java.io.Serializable;
+import java.util.Collection;
+
+/**
+ * @author Tim Englich <tim.englich@intevation.de>
+ * 
+ */
+public interface OutputMode extends Serializable {
+
+    public String getName();
+
+    public String getDescription();
+
+    public String getMimeType();
+
+    public Collection<InputValue> getInputParameters();
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/state/OutputState.java	Tue Dec 08 08:39:03 2009 +0000
@@ -0,0 +1,38 @@
+/**
+ *
+ */
+package de.intevation.gnv.state;
+
+import java.io.OutputStream;
+import java.util.Collection;
+
+import org.w3c.dom.Document;
+
+import de.intevation.artifacts.CallMeta;
+import de.intevation.gnv.state.exception.StateException;
+
+/**
+ * @author Tim Englich <tim.englich@intevation.de>
+ * 
+ */
+public interface OutputState extends State {
+
+    /**
+     * Returns the Rendered Result of an State.
+     * 
+     * @param outputMode
+     *            The Mode that should be produces (Chart, Map, ...)
+     * @return The Bytecode of the Result
+     * @throws StateException
+     */
+    public void out(Document format, Collection<InputData> inputData,
+                    OutputStream outputStream, String uuid, CallMeta callMeta)
+                                                                              throws StateException;
+
+    /**
+     * Delivers the provided OutputModes of an State
+     * 
+     * @return the provided OutputModes of an State
+     */
+    public Collection<OutputMode> getOutputModes();
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/state/OutputStateBase.java	Tue Dec 08 08:39:03 2009 +0000
@@ -0,0 +1,273 @@
+/**
+ *
+ */
+package de.intevation.gnv.state;
+
+import java.io.OutputStream;
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.Locale;
+
+
+import org.apache.log4j.Logger;
+import org.w3c.dom.Document;
+import org.w3c.dom.Element;
+import org.w3c.dom.Node;
+import org.w3c.dom.NodeList;
+
+import de.intevation.artifactdatabase.Config;
+import de.intevation.artifacts.CallMeta;
+import de.intevation.gnv.artifacts.cache.CacheFactory;
+import de.intevation.gnv.artifacts.ressource.RessourceFactory;
+import de.intevation.gnv.geobackend.base.Result;
+import de.intevation.gnv.geobackend.base.query.QueryExecutor;
+import de.intevation.gnv.geobackend.base.query.QueryExecutorFactory;
+import de.intevation.gnv.geobackend.base.query.exception.QueryException;
+import de.intevation.gnv.state.exception.StateException;
+
+/**
+ * @author Tim Englich <tim.englich@intevation.de>
+ * 
+ */
+public abstract class OutputStateBase extends StateBase implements
+                                                                 OutputState {
+
+    /**
+     * The UID of this Class
+     */
+    private static final long serialVersionUID = -1718732895737303823L;
+
+    /**
+     * the logger, used to log exceptions and additonaly information
+     */
+    private static Logger log = Logger.getLogger(OutputStateBase.class);
+
+    /**
+     * The different Outputmodes which are provided by an OutputState
+     */
+    protected Collection<OutputMode> outputModes = null;
+    
+    protected String queryODVID = null;
+
+    /**
+     * Constructor
+     */
+    public OutputStateBase() {
+        super();
+    }
+
+    /**
+     * @see de.intevation.gnv.state.OutputState#getOutputModes()
+     */
+    public Collection<OutputMode> getOutputModes() {
+        log.debug("OutputStateBase.getOutputModes");
+        return this.outputModes;
+    }
+
+    /**
+     * @see de.intevation.gnv.state.StateBase#setup(org.w3c.dom.Node)
+     */
+    @Override
+    public void setup(Node configuration) {
+        log.debug("OutputStateBase.setup");
+        super.setup(configuration);
+        
+        this.queryODVID = Config.getStringXPath(configuration,"queryID-odv");
+        
+        NodeList outputModeList = Config.getNodeSetXPath(configuration,
+                "outputsModes/outputsMode");
+        if (outputModeList != null) {
+            log.debug(outputModeList.getLength() + " were found.");
+            this.outputModes = new ArrayList<OutputMode>(outputModeList
+                    .getLength());
+            for (int i = 0; i < outputModeList.getLength(); i++) {
+                Element currentNode = (Element)outputModeList.item(i);
+                String name = currentNode.getAttribute("name");
+                String description =currentNode.getAttribute("description");
+                String mimeType = currentNode.getAttribute("mime-type");
+                NodeList inputValuesList = Config.getNodeSetXPath(currentNode,
+                        "parameters/inputvalue");
+                Collection<InputValue> inputParameters = null;
+                if (inputValuesList != null) {
+                    inputParameters = new ArrayList<InputValue>(inputValuesList
+                            .getLength());
+                    for (int j = 0; j < inputValuesList.getLength(); j++) {
+                        Element currentInputValuesNode = (Element)inputValuesList.item(j);
+                        String inputValueName = currentInputValuesNode.getAttribute("name");
+                        String inputValueType = currentInputValuesNode.getAttribute("type");
+                        String defaultValue =currentInputValuesNode.getAttribute("value");
+                        boolean isMultiselect = false;
+                        InputValue inputValue = new DefaultInputValue(
+                                inputValueName, inputValueType, defaultValue,
+                                isMultiselect);
+                        inputParameters.add(inputValue);
+                    }
+                }
+
+                OutputMode outputMode = new DefaultOutputMode(name,
+                        description, mimeType, inputParameters);
+                log.debug(outputMode.toString());
+                this.outputModes.add(outputMode);
+
+            }
+        }
+    }
+
+    /**
+     * @see de.intevation.gnv.state.StateBase#advance()
+     */
+    @Override
+    public void advance(String uuid, CallMeta callMeta)
+                                                       throws StateException {
+    }
+
+    @Override
+    public void initialize(String uuid, CallMeta callMeta)
+                                                          throws StateException {
+    }
+
+    public void out(Document format, Collection<InputData> inputData,
+                    OutputStream outputStream, String uuid, CallMeta callMeta)
+                                                                              throws StateException {
+    }
+
+    /**
+     * @see de.intevation.gnv.state.OutputState#out(java.lang.String,
+     *      java.util.Collection, java.io.OutputStream)
+     */
+    public void out(String outputMode, Collection<InputData> inputData,
+                    OutputStream outputStream) throws StateException {
+    }
+
+    /**
+     * @return
+     */
+    protected Collection<Result> getChartResult(String uuid) {
+        log.debug("OutputStateBase.getChartResult");
+        Collection<Result> result = null;
+        if (CacheFactory.getInstance().isInitialized()) {
+            String key = uuid + super.getID();
+            log.debug("Hash for Queryelements: " + key);
+            net.sf.ehcache.Element value = CacheFactory.getInstance().getCache().get(key);
+            if (value != null) {
+                result = (Collection<Result>) (value.getObjectValue());
+            }else{
+                result = this.getData(this.queryID);
+                if (CacheFactory.getInstance().isInitialized()) {
+                    CacheFactory.getInstance().getCache().put(new net.sf.ehcache.Element(key, result));
+                }
+                
+            }
+        }
+        return result;
+    }
+
+    protected Object getChartFromCache(String uuid) {
+        log.debug("Fetch chart [" + uuid + "] from cache");
+        CacheFactory cacheFactory = CacheFactory.getInstance();
+        if (cacheFactory.isInitialized()) {
+            String key = "chart_" + uuid + super.getID();
+            net.sf.ehcache.Element object = cacheFactory.getCache().get(key);
+
+            if (object != null) {
+                return object.getObjectValue();
+            }
+        }
+        return null;
+    }
+    
+    protected Collection<Result> getODVResult(String uuid) {
+        log.debug("OutputStateBase.getODVResult");
+        // TODO add Caching? I think it's not nessessary
+        Collection<Result> returnValue = null;
+        if (this.queryODVID != null){
+            returnValue = this.getData(this.queryODVID);
+        }else{
+            log.warn("No Query for ODV Data is defined.");
+        }
+        return returnValue;
+    }
+
+    /**
+     * @param returnValue
+     * @return
+     */
+    private Collection<Result> getData(String queryID) {
+        log.debug("OutputStateBase.getData");
+        Collection<Result> returnValue = null;
+        try {
+            String[] filterValues = this.generateFilterValuesFromInputData();
+            try {
+                QueryExecutor queryExecutor = QueryExecutorFactory
+                                              .getInstance()
+                                              .getQueryExecutor();
+                returnValue  = queryExecutor.executeQuery(queryID,filterValues);
+            } catch (RuntimeException e) {
+                log.error(e, e);
+            }
+        } catch (QueryException e) {
+            log.error(e, e);
+        }
+        return returnValue;
+    }
+    
+    protected void removeChartResult(String uuid) {
+        log.debug("OutputStateBase.getChartResult");
+        if (CacheFactory.getInstance().isInitialized()) {
+            String key = uuid + super.getID();
+            log.debug("Hash for Queryelements: " + key);
+            net.sf.ehcache.Element value = CacheFactory.getInstance().getCache().get(key);
+            if (value != null) {
+                CacheFactory.getInstance().getCache().remove(key);
+            }
+        }
+    }
+
+    protected void removeChart(String uuid) {
+        log.debug("OutputStateBase.removeChart from cache");
+
+        CacheFactory cacheFactory = CacheFactory.getInstance();
+        if (cacheFactory.isInitialized()) {
+            String key = "chart_" + uuid + super.getID();
+            net.sf.ehcache.Element object = cacheFactory.getCache().get(key);
+            if (object != null)
+                cacheFactory.getCache().remove(key);
+        }
+    }
+
+    protected void purifyChart(Object chart, String uuid) {
+        log.debug("Prufify chart [" + uuid + "]");
+        CacheFactory cacheFactory = CacheFactory.getInstance();
+        if (cacheFactory.isInitialized()) {
+            String key = "chart_" + uuid + getID();
+            cacheFactory.getCache().put(new net.sf.ehcache.Element(key, chart));
+        }
+    }
+
+    /**
+     * @see de.intevation.gnv.state.StateBase#putInputData(java.util.Collection, java.lang.String)
+     */
+    @Override
+    public void putInputData(Collection<InputData> inputData, 
+                             String uuid)
+                                         throws StateException {
+        log.debug("OutputStateBase.putInputData");
+        this.removeChartResult(uuid);
+        this.removeChart(uuid);
+        super.putInputData(inputData, uuid);
+    }
+
+    public void out(String outputMode, Collection<InputData> inputData,
+                    OutputStream outputStream, String uuid, CallMeta callMeta)
+                                                                              throws StateException {
+    }
+
+
+    protected String getMessage(Locale locale, String key, String value) {
+        return RessourceFactory.getInstance().getRessource(
+            locale,
+            key,
+            value
+        );
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/state/SingleInputState.java	Tue Dec 08 08:39:03 2009 +0000
@@ -0,0 +1,59 @@
+/**
+ *
+ */
+package de.intevation.gnv.state;
+
+import java.util.ArrayList;
+import java.util.Collection;
+
+import org.apache.log4j.Logger;
+
+import de.intevation.gnv.geobackend.base.Result;
+import de.intevation.gnv.state.describedata.DefaultSingleValueDescribeData;
+
+/**
+ * @author Tim Englich <tim.englich@intevation.de>
+ * 
+ */
+public class SingleInputState extends StateBase {
+
+    /**
+     * the logger, used to log exceptions and additonaly information
+     */
+    private static Logger log = Logger.getLogger(SingleInputState.class);
+
+    /**
+     *
+     */
+    private static final long serialVersionUID = -6169497306324917318L;
+
+    /**
+     * Constructor
+     */
+    public SingleInputState() {
+    }
+
+    /**
+     * @see de.intevation.gnv.state.StateBase#purifyResult(java.util.Collection,
+     *      java.lang.String)
+     */
+    @Override
+    protected void purifyResult(Collection<Result> result, String uuid) {
+        log.debug("SingleInputState.purifyResult");
+        Collection<Object> describeData = this.getDescibeData(uuid);
+        if (describeData == null) {
+            describeData = new ArrayList<Object>();
+        }
+        String value = null;
+        if (result != null && result.size() == 1) {
+            Result tmpItem = result.iterator().next();
+            value = tmpItem.getObject("MAX").toString();
+        } else {
+            value = "";
+        }
+
+        describeData.add(new DefaultSingleValueDescribeData(this.dataName,value));
+        this.setDescibeData(uuid, describeData);
+    }
+
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/state/State.java	Tue Dec 08 08:39:03 2009 +0000
@@ -0,0 +1,51 @@
+/**
+ *
+ */
+package de.intevation.gnv.state;
+
+import java.io.Serializable;
+import java.util.Collection;
+
+import org.w3c.dom.Document;
+import org.w3c.dom.Node;
+
+import de.intevation.artifacts.CallMeta;
+import de.intevation.gnv.state.exception.StateException;
+
+/**
+ * @author Tim Englich <tim.englich@intevation.de>
+ * 
+ */
+public interface State extends Serializable {
+
+    public void setup(Node configuration);
+
+    public Collection<String> reachableStates();
+
+    public boolean isStateReachable(String stateID);
+
+    public String getID();
+
+    public String getDescription();
+
+    public void describe(Document document, Node rootNode, 
+                         CallMeta callMeta, String uuid);
+
+    public void setParent(State state);
+
+    public State getParent();
+
+    public Collection<InputValue> getRequiredInputValues();
+
+    public void putInputData(Collection<InputData> inputData, 
+                             String uuid)throws StateException;
+
+    public Collection<InputData> getInputData() throws StateException;
+
+    public void advance(String uuid, CallMeta callMeta)
+                                                    throws StateException;
+    public void initialize(String uuid, CallMeta callMeta)
+                                                    throws StateException;
+    
+
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/state/StateBase.java	Tue Dec 08 08:39:03 2009 +0000
@@ -0,0 +1,788 @@
+/**
+ *
+ */
+package de.intevation.gnv.state;
+
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.Date;
+import java.util.GregorianCalendar;
+import java.util.HashMap;
+import java.util.HashSet;
+import java.util.Iterator;
+import java.util.List;
+import java.util.Map;
+import java.util.Set;
+
+import org.apache.log4j.Logger;
+import org.w3c.dom.Document;
+import org.w3c.dom.Element;
+import org.w3c.dom.Node;
+import org.w3c.dom.NodeList;
+
+import de.intevation.artifactdatabase.Config;
+import de.intevation.artifacts.CallMeta;
+import de.intevation.gnv.artifacts.GNVArtifactBase;
+import de.intevation.gnv.artifacts.cache.CacheFactory;
+import de.intevation.gnv.artifacts.ressource.RessourceFactory;
+import de.intevation.gnv.geobackend.base.Result;
+import de.intevation.gnv.geobackend.base.query.QueryExecutor;
+import de.intevation.gnv.geobackend.base.query.QueryExecutorFactory;
+import de.intevation.gnv.geobackend.base.query.exception.QueryException;
+import de.intevation.gnv.geobackend.util.DateUtils;
+import de.intevation.gnv.state.describedata.DefaultKeyValueDescribeData;
+import de.intevation.gnv.state.describedata.KeyValueDescibeData;
+import de.intevation.gnv.state.describedata.MinMaxDescribeData;
+import de.intevation.gnv.state.describedata.NamedArrayList;
+import de.intevation.gnv.state.describedata.NamedCollection;
+import de.intevation.gnv.state.describedata.SingleValueDescribeData;
+import de.intevation.gnv.state.exception.StateException;
+import de.intevation.gnv.utils.ArtifactXMLUtilities;
+import de.intevation.gnv.utils.InputValidator;
+
+/**
+ * @author Tim Englich <tim.englich@intevation.de>
+ * 
+ */
+public abstract class StateBase implements State {
+
+    
+
+    /**
+     * The UID of this Class
+     */
+    private static final long serialVersionUID = 2411169179001645426L;
+
+    /**
+     * the logger, used to log exceptions and additonaly information
+     */
+    private static Logger log = Logger.getLogger(GNVArtifactBase.class);
+    
+    private final static String MINVALUEFIELDNAME = "minvalue";
+    private final static String MAXVALUEFIELDNAME = "maxvalue";
+    
+    private final static String NODATASELECTIONKEY = "n/n";
+    
+    private final static String DESCRIBEDATAKEY = "_DESCRIBEDATA";
+
+    private String id = null;
+
+    private String description = null;
+
+    protected String dataName = null;
+
+    protected boolean dataMultiSelect = false;
+    
+    protected boolean dataNoSelect = false;
+
+    protected String queryID = null;
+
+    private Collection<String> reachableStates = null;
+
+    protected Collection<String> inputValueNames = null;
+
+    private Map<String, InputValue> inputValues = null;
+
+    private State parent = null;
+
+    protected Map<String, InputData> inputData = null;
+    
+
+    /**
+     * Constructor
+     */
+    public StateBase() {
+        super();
+    }
+
+    /**
+     * @see de.intevation.gnv.state.State#getID()
+     */
+    public String getID() {
+        return this.id;
+    }
+
+    /**
+     * @see de.intevation.gnv.state.State#getDescription()
+     */
+    public String getDescription() {
+        return this.description;
+    }
+
+    /**
+     * @see de.intevation.gnv.state.State#reachableStates()
+     */
+    public Collection<String> reachableStates() {
+        
+        if (this.couldAlternativeStateUsed()){
+            Iterator<String> it = this.reachableStates.iterator();
+            String transValue = null;
+            while (it.hasNext()){
+                transValue = it.next();
+            }
+            Collection<String> returnValue = new ArrayList<String>(1);
+            returnValue.add(transValue);
+            return returnValue;
+        }else{
+            return this.reachableStates;
+        }
+        
+    }
+
+    /**
+     * @return
+     */
+    private boolean couldAlternativeStateUsed() {
+     // TODO das muss hier noch etwas freier gestaltet werden.
+        String key = this.dataName;
+        boolean returnValue=this.inputData != null &&
+                            this.inputData.containsKey(key) && 
+                            this.inputData.get(key).getValue().
+                                                    equals(NODATASELECTIONKEY);
+        return returnValue;
+    }
+
+    /**
+     * @see de.intevation.gnv.state.State#getRequiredInputValues()
+     */
+    public Collection<InputValue> getRequiredInputValues() {
+        return this.inputValues.values();
+    }
+
+    /**
+     * @see de.intevation.gnv.state.State#setup(org.w3c.dom.Node)
+     */
+    public void setup(Node configuration) {
+        log.debug("StateBase.setup");
+        this.id = ((Element)configuration).getAttribute("id");
+        this.description = ((Element)configuration).getAttribute("description");
+
+        log.info("State-ID = " + this.id);
+        NodeList nodes = Config.getNodeSetXPath(configuration,
+                "reachablestates/state");
+        this.reachableStates = new ArrayList<String>(nodes.getLength());
+        for (int i = 0; i < nodes.getLength(); i++) {
+            String reachableState = nodes.item(i).getTextContent();
+            log.info("ReachableState ==> " + reachableState);
+            this.reachableStates.add(reachableState);
+
+        }
+        
+        NodeList inputValuesNodes = Config.getNodeSetXPath(configuration,
+                "inputvalues/inputvalue");
+        this.inputValues = new HashMap<String, InputValue>(inputValuesNodes
+                .getLength());
+        this.inputValueNames = new ArrayList<String>(inputValuesNodes
+                .getLength());
+        for (int i = 0; i < inputValuesNodes.getLength(); i++) {
+            Element inputValueNode = (Element)inputValuesNodes.item(i);
+            String usedinQueryValue = inputValueNode.getAttribute("usedinquery");
+            int usedinQuery = 1;
+            if (usedinQueryValue != null) {
+                try {
+                    usedinQuery = Integer.parseInt(usedinQueryValue);
+                } catch (NumberFormatException e) {
+                    log
+                            .warn("Used in Query Value cannot be transformed into a Number");
+                }
+            }
+            InputValue inputValue = new DefaultInputValue(inputValueNode.getAttribute("name"), 
+                                                          inputValueNode.getAttribute("type"), 
+                                                          Boolean.parseBoolean(inputValueNode.
+                                                          getAttribute("multiselect")), usedinQuery);
+            log.debug(inputValue.toString());
+            this.inputValues.put(inputValue.getName(), inputValue);
+            this.inputValueNames.add(inputValue.getName());
+        }
+
+        this.queryID = Config.getStringXPath(configuration, "queryID");
+        log.info("QueryID ==> " + this.queryID);
+
+        this.dataName = Config.getStringXPath(configuration, "dataname");
+
+        String dataMultiSelectValue = Config.getStringXPath(configuration,
+                                                           "data-multiselect");
+        if (dataMultiSelectValue != null) {
+            this.dataMultiSelect = Boolean.parseBoolean(dataMultiSelectValue);
+        }
+        
+        String dataNoSelectValue =Config.getStringXPath(configuration,
+                                                        "data-noselect");
+        if (dataNoSelectValue != null) {
+            this. dataNoSelect = Boolean.parseBoolean(dataNoSelectValue);
+        }
+        
+    }
+
+    /**
+     * @see de.intevation.gnv.state.State#getParent()
+     */
+    public State getParent() {
+        return this.parent;
+    }
+
+    /**
+     * @see de.intevation.gnv.state.State#setParent(de.intevation.gnv.state.State)
+     */
+    public void setParent(State state) {
+        this.parent = state;
+    }
+
+    /**
+     * @see de.intevation.gnv.state.State#putInputData(java.util.Collection)
+     */
+    public void putInputData(Collection<InputData> inputData, String uuid)
+                                                                          throws StateException {
+        log.debug("StateBase.putInputData");
+        if (inputData != null) {
+            Iterator<InputData> it = inputData.iterator();
+            InputValidator iv = new InputValidator();
+            while (it.hasNext()) {
+                InputData tmpItem = it.next();
+                InputValue inputValue = this.inputValues.get(tmpItem.getName());
+                if (inputValue != null) {
+                    if (this.inputData == null) {
+                        this.inputData = new HashMap<String, InputData>(
+                                inputData.size());
+                    }
+                    
+                    boolean valid = iv.isInputValid(tmpItem.getValue(),
+                            inputValue.getType());
+                    if (valid) {
+                        if (tmpItem.getName().equals(MINVALUEFIELDNAME)){
+                            String minValue = tmpItem.getValue();
+                            String maxValue = this.getInputValue4ID(inputData, MAXVALUEFIELDNAME);
+                            valid = iv.isInputValid(maxValue,inputValue.getType());
+                            if (!valid){
+                                String errMsg = "Wrong input for " + tmpItem.getValue()
+                                                + " is not an " + inputValue.getType()
+                                                + " Value.";
+                                log.warn(errMsg);
+                                throw new StateException(errMsg);
+                            }
+                            
+                            valid = iv.isInputValid(minValue, 
+                                    maxValue,
+                                    inputValue.getType());
+                            if (!valid){
+                                String errMsg = "MaxValue-Input is less than MinValue-Input ";
+                                log.warn(errMsg);
+                                throw new StateException(errMsg);
+                            }
+                        }else if (tmpItem.getName().equals(MAXVALUEFIELDNAME)){
+                            String minValue = this.getInputValue4ID(inputData, MINVALUEFIELDNAME);
+                            String maxValue = tmpItem.getValue();
+                            valid = iv.isInputValid(minValue,inputValue.getType());
+                            if (!valid){
+                                String errMsg = "Wrong input for " + tmpItem.getValue()
+                                                + " is not an " + inputValue.getType()
+                                                + " Value.";
+                                log.warn(errMsg);
+                                throw new StateException(errMsg);
+                            }
+                            
+                            valid = iv.isInputValid(minValue, 
+                                                    maxValue,
+                                                    inputValue.getType());
+                            if (!valid){
+                                String errMsg = "MaxValue-Input is less than MinValue-Input ";
+                                log.warn(errMsg);
+                                throw new StateException(errMsg);
+                            }
+                        }
+                        this.setSelection(tmpItem, uuid);
+                        this.inputData.put(tmpItem.getName(), tmpItem);
+                    } else {
+                        String errMsg = "Wrong input for " + tmpItem.getValue()
+                                        + " is not an " + inputValue.getType()
+                                        + " Value.";
+                        log.warn(errMsg);
+                        throw new StateException(errMsg);
+                    }
+
+                } else {
+                    String errMsg = "No Inputvalue given for Inputdata "
+                                    + tmpItem.getName();
+                    log.warn(errMsg + "Value will be ignored");
+
+                }
+            }
+        } else {
+            log.warn("No Inputdata given");
+        }
+    }
+    
+    private String getInputValue4ID(Collection<InputData> inputData, String inputName){
+        Iterator<InputData> it = inputData.iterator();
+        while (it.hasNext()) {
+            InputData tmpItem = it.next();
+            if (tmpItem.getName().equals(inputName)){
+                return tmpItem.getValue();
+            }
+        }
+        return null;
+    }
+
+    private void setSelection(InputData inputData, String uuid) {
+        log.debug("StateBase.setSelection");
+
+        Object o = this.getDescribeData(inputData.getName(),uuid);
+        if (o != null) {
+            if (o instanceof Collection<?>) {
+                Collection<KeyValueDescibeData> values = (Collection<KeyValueDescibeData>) o;
+
+                String value = inputData.getValue();
+                String[] selectedValues = value.split(",");
+                Set<String> selectedItems = new HashSet<String>(
+                        selectedValues.length);
+                for (int i = 0; i < selectedValues.length; i++) {
+                    selectedItems.add(selectedValues[i].trim());
+                }
+                // Selektion umsetzen
+                Iterator<KeyValueDescibeData> it = values.iterator();
+                while (it.hasNext()) {
+                    KeyValueDescibeData data = it.next();
+                    String key = "" + data.getKey();
+                    boolean selected = selectedItems.contains(key);
+                    data.setSelected(selected);
+                }
+            } else if (o instanceof MinMaxDescribeData) {
+                MinMaxDescribeData data = (MinMaxDescribeData) o;
+                if (inputData.getName().equals(MINVALUEFIELDNAME)) {
+                    data.setMinValue(inputData.getValue());
+                }
+                if (inputData.getName().equals(MAXVALUEFIELDNAME)) {
+                    data.setMaxValue(inputData.getValue());
+                }
+            } else if (o instanceof SingleValueDescribeData) {
+                ((SingleValueDescribeData)o).setValue(inputData.getValue());
+            }
+        }
+    }
+
+    private Object getDescribeData(String name, String uuid) {
+        log.debug("StateBase.getDescribeData");
+        Collection<Object> descibeData = this.getDescibeData(uuid);
+        if (descibeData != null) {
+            Iterator<Object> it = descibeData.iterator();
+            while (it.hasNext()) {
+                Object o = it.next();
+                if (o instanceof NamedCollection<?>) {
+                    if (name.equals(((NamedCollection<?>) o).getName())) {
+                        return o;
+                    }
+                } else if (o instanceof MinMaxDescribeData) {
+                    if (name.equals(((MinMaxDescribeData) o).getMinName())) {
+                        return o;
+                    }
+                    if (name.equals(((MinMaxDescribeData) o).getMaxName())) {
+                        return o;
+                    }
+                }else if (o instanceof SingleValueDescribeData) {
+                    if (name.equals(((SingleValueDescribeData)o).getName())){
+                        return o;
+                    }
+                }
+            }
+        }
+        return null;
+
+    }
+
+    /**
+     * @see de.intevation.gnv.state.State#isStateReachable(java.lang.String)
+     */
+    public boolean isStateReachable(String stateID) {
+        log.debug("StateBase.isStateReachable");
+        boolean returnValue = false;
+        Iterator<String> states = reachableStates.iterator();
+        while (states.hasNext()) {
+            if (states.next().equals(stateID)) {
+                log.debug("State " + stateID + " wird unterstützt.");
+                returnValue = true;
+                break;
+            }
+        }
+        return returnValue;
+    }
+
+    /**
+     * @see de.intevation.gnv.state.State#advance(java.lang.String,
+     *      de.intevation.artifacts.CallMeta)
+     */
+    public void advance(String uuid, CallMeta callMeta)
+                                                   throws StateException {
+    }
+    
+    public void initialize(String uuid, CallMeta callMeta)
+                                                   throws StateException {
+        log.debug("StateBase.initialize");
+        try {
+            String[] filterValues = this
+                    .generateFilterValuesFromInputData();
+            Collection<Result> result = null;
+            try {
+                if (this.queryID != null) {
+                    QueryExecutor queryExecutor = QueryExecutorFactory
+                            .getInstance().getQueryExecutor();
+                    result = queryExecutor.executeQuery(this.queryID,
+                            filterValues);
+                }
+                this.purifyResult(result, uuid);
+            } catch (RuntimeException e) {
+                log.error(e, e);
+            }
+        } catch (QueryException e) {
+            log.error(e, e);
+            throw new StateException(e);
+        }
+    }
+
+    /**
+     * @return
+     */
+    protected String[] generateFilterValuesFromInputData() {
+        List<String> list = new ArrayList<String>();
+        Iterator<String> it = this.inputValueNames.iterator();
+        while (it.hasNext()) {
+            String value = it.next();
+            InputData data = this.inputData.get(value);
+            if (data != null
+                && this.inputValues.containsKey(data.getName())) {
+                int size = this.inputValues.get(data.getName())
+                        .usedInQueries();
+                String type = this.inputValues.get(data.getName())
+                        .getType();
+                String requestValue = data.getValue();
+                if (type.equalsIgnoreCase("string")) {
+                    requestValue = this
+                            .prepareInputData4DBQuery(requestValue);
+                } else if (type.equalsIgnoreCase("date")) {
+                    requestValue = this
+                            .prepareInputData4DateDBQuery(requestValue);
+                } else if (type.equalsIgnoreCase("coordinate")){
+                    requestValue = this
+                    .prepareInputData4RegionDBQuery(requestValue);
+                }
+                for (int j = 0; j < size; j++) {
+                    list.add(requestValue);
+                }
+            }
+        }
+        String[] filterValues = list.toArray(new String[0]);
+        return filterValues;
+    }
+    
+    protected String prepareInputData4RegionDBQuery(String value){
+        return value;
+    }
+
+    private String prepareInputData4DateDBQuery(String value) {
+        log.debug("StateBase.prepareInputData4DateDBQuery");
+        if (value != null) {
+            String[] values = value.split(",");
+            String newValue = "";
+            for (int i = 0; i < values.length; i++) {
+                if (newValue.length() > 0) {
+                    newValue = newValue + " , ";
+                }
+                // TODO JUST HACK FIND A BETTER RESOLUTION
+                newValue = newValue + "to_date('" + values[i].trim()
+                           + "', 'YYYY.MM.DD HH24:MI:SS')";
+            }
+            return newValue;
+        }
+
+        return value;
+    }
+
+    private String prepareInputData4DBQuery(String value) {
+        log.debug("StateBase.prepareInputData4DBQuery");
+        if (value != null) {
+            String[] values = value.split(",");
+            String newValue = "";
+            for (int i = 0; i < values.length; i++) {
+                if (newValue.length() > 0) {
+                    newValue = newValue + " , ";
+                }
+                newValue = newValue + "'" + values[i].trim() + "'";
+            }
+            return newValue;
+        }
+
+        return value;
+
+    }
+
+    /**
+     * @param result
+     */
+    protected void purifyResult(Collection<Result> result, String uuid) {
+        log.debug("StateBase.purifyResult");
+        Collection<Object> describeData = this.getDescibeData(uuid);
+        if (describeData == null) {
+            describeData = new ArrayList<Object>();
+        }
+        NamedCollection<KeyValueDescibeData> keyValueDescibeData = extractKVP(result, "KEY", "VALUE");
+        describeData.add(keyValueDescibeData); 
+        this.setDescibeData(uuid, describeData);
+    }
+
+    /**
+     * @param result
+     * @return
+     */
+    protected NamedCollection<KeyValueDescibeData> extractKVP(Collection<Result> result,
+                                                              String keyid,
+                                                              String valueid) {
+        Iterator<Result> rit = result.iterator();
+        int dataSize = (this.dataNoSelect ? result.size()+1 : result.size());
+        
+        NamedCollection<KeyValueDescibeData> keyValueDescibeData = new NamedArrayList<KeyValueDescibeData>(
+                this.dataName, dataSize);
+        keyValueDescibeData.setMultiSelect(this.dataMultiSelect);
+        
+        if (this.dataNoSelect){
+            keyValueDescibeData.add(new DefaultKeyValueDescribeData(NODATASELECTIONKEY, 
+                                                                    "No Selection"));
+        }
+        boolean initialized = false;
+        int keyPos= 0;
+        int valuePos = 1;
+        String previousKey = null;
+        while (rit.hasNext()) {
+            Result resultValue = rit.next();
+            if (!initialized){
+                keyPos = resultValue.getResultDescriptor().getColumnIndex(keyid);
+                valuePos = resultValue.getResultDescriptor().getColumnIndex(valueid);
+                if (valuePos < 0){
+                    valuePos = 1;
+                }
+                initialized = true;
+            }
+            String tmpKey = resultValue.getString(keyPos);
+            // TODO: HACK da die ARCSDE kein DISTINCT auf räumlichen Anfragen unterstützt.
+            if (previousKey == null || !tmpKey.equals(previousKey)){
+                previousKey = tmpKey;
+                keyValueDescibeData.add(new DefaultKeyValueDescribeData(tmpKey, resultValue.getString(valuePos)));
+            }
+        }
+        return keyValueDescibeData;
+    }
+
+    /**
+     * @see de.intevation.gnv.state.State#describe(org.w3c.dom.Document,
+     *      org.w3c.dom.Node, de.intevation.artifacts.CallMeta,
+     *      java.lang.String)
+     */
+    public void describe(Document document, Node rootNode, CallMeta callMeta,String uuid) {
+        log.debug("StateBase.describe");
+        Collection<Object> descibeData = this.getDescibeData(uuid);
+        if (descibeData != null) {
+            ArtifactXMLUtilities xmlutilities = new ArtifactXMLUtilities();
+            Iterator<Object> it = descibeData.iterator();
+            Node staticNode = xmlutilities.createArtifactElement(document,
+                    "static");
+            Node dynamic = xmlutilities.createArtifactElement(document,
+                    "dynamic");
+            rootNode.appendChild(staticNode);
+            rootNode.appendChild(dynamic);
+            while (it.hasNext()) {
+
+                Object o = it.next();
+                if (o instanceof Collection<?>) {
+                    String name = null;
+                    boolean multiselect = false;
+                    if (o instanceof NamedCollection<?>) {
+                        NamedCollection<?> nc = ((NamedCollection<?>) o);
+                        name = nc.getName();
+                        multiselect = nc.isMultiSelect();
+                    } else {
+                        Object[] names = this.inputValueNames.toArray();
+                        name = names[names.length - 1].toString();
+                    }
+
+                    Element selectNode = xmlutilities.createXFormElement(
+                            document, multiselect ? "select" : "select1");
+                    selectNode.setAttribute("ref", name);
+
+                    Element lableNode = xmlutilities.createXFormElement(
+                            document, "label");
+                    lableNode.setTextContent(RessourceFactory.getInstance()
+                            .getRessource(callMeta.getLanguages(), name, name));
+                    Element choiceNode = xmlutilities.createXFormElement(
+                            document, "choices");
+
+                    Collection<KeyValueDescibeData> values = (Collection<KeyValueDescibeData>) o;
+                    Iterator<KeyValueDescibeData> resultIt = values.iterator();
+                    while (resultIt.hasNext()) {
+                        KeyValueDescibeData result = resultIt.next();
+                        Element itemNode = xmlutilities.createXFormElement(
+                                document, "item");
+
+                        if (result.isSelected()) {
+                            itemNode.setAttribute("selected", "true");
+                        }
+
+                        Element choiceLableNode = xmlutilities
+                                .createXFormElement(document, "label");
+                        choiceLableNode.setTextContent(result.getValue());
+                        itemNode.appendChild(choiceLableNode);
+
+                        Element choicValueNode = xmlutilities
+                                .createXFormElement(document, "value");
+                        choicValueNode.setTextContent("" + result.getKey());
+                        itemNode.appendChild(choicValueNode);
+                        choiceNode.appendChild(itemNode);
+                    }
+                    selectNode.appendChild(lableNode);
+                    selectNode.appendChild(choiceNode);
+
+                    if (!it.hasNext() && this.dataName != null) {
+                        dynamic.appendChild(selectNode);
+                    } else {
+                        staticNode.appendChild(selectNode);
+                    }
+
+                } else if (o instanceof MinMaxDescribeData) {
+                    MinMaxDescribeData minMaxDescibeData = (MinMaxDescribeData) o;
+                    Object min = minMaxDescibeData.getMinValue();
+                    Object max = minMaxDescibeData.getMaxValue();
+                    if (min instanceof GregorianCalendar) {
+                        Date d = ((GregorianCalendar) min).getTime();
+                        min = DateUtils.getPatternedDateAmer(d);
+                    }
+
+                    if (max instanceof GregorianCalendar) {
+                        Date d = ((GregorianCalendar) max).getTime();
+                        max = DateUtils.getPatternedDateAmer(d);
+                    }
+                    
+                    Element groupNode = xmlutilities.createXFormElement(
+                            document, "group");
+                    groupNode.setAttribute("ref", minMaxDescibeData.getName());
+                    Element groupNodeLableNode = xmlutilities
+                            .createXFormElement(document, "label");
+                    groupNodeLableNode.setTextContent(RessourceFactory
+                            .getInstance().getRessource(
+                                    callMeta.getLanguages(),
+                                    minMaxDescibeData.getName(),
+                                    minMaxDescibeData.getName()));
+                    groupNode.appendChild(groupNodeLableNode);
+
+                    Element inputMinNode = xmlutilities.createXFormElement(
+                            document, "input");
+                    inputMinNode.setAttribute("ref", MINVALUEFIELDNAME);
+                    Element inputMinLableNode = xmlutilities
+                            .createXFormElement(document, "label");
+                    inputMinLableNode.setTextContent(RessourceFactory
+                            .getInstance().getRessource(
+                                    callMeta.getLanguages(), MINVALUEFIELDNAME,
+                                    MINVALUEFIELDNAME));
+                    inputMinNode.appendChild(inputMinLableNode);
+
+                    Element inputMinValueNode = xmlutilities
+                            .createXFormElement(document, "value");
+                    inputMinValueNode.setTextContent(min.toString());
+                    inputMinNode.appendChild(inputMinValueNode);
+
+                    Element inputMaxNode = xmlutilities.createXFormElement(
+                            document, "input");
+                    inputMaxNode.setAttribute("ref", MAXVALUEFIELDNAME);
+                    Element inputMaxLableNode = xmlutilities
+                            .createXFormElement(document, "label");
+                    inputMaxLableNode.setTextContent(RessourceFactory
+                            .getInstance().getRessource(
+                                    callMeta.getLanguages(), MAXVALUEFIELDNAME,
+                                    MAXVALUEFIELDNAME));
+                    inputMaxNode.appendChild(inputMaxLableNode);
+
+                    Element inputMaxValueNode = xmlutilities
+                            .createXFormElement(document, "value");
+                    inputMaxValueNode.setTextContent(max.toString());
+                    inputMaxNode.appendChild(inputMaxValueNode);
+
+                    groupNode.appendChild(inputMinNode);
+                    groupNode.appendChild(inputMaxNode);
+                    
+                    if (!it.hasNext() && this.dataName != null) {
+                        dynamic.appendChild(groupNode);
+                    } else {
+                        staticNode.appendChild(groupNode);
+                    }
+                } else if (o instanceof SingleValueDescribeData) {
+
+                    SingleValueDescribeData svdb = (SingleValueDescribeData) o;
+                    
+                    Element groupNode = xmlutilities.createXFormElement(
+                            document, "group");
+                    groupNode.setAttribute("ref",  svdb.getName());
+                    Element groupNodeLableNode = xmlutilities
+                            .createXFormElement(document, "label");
+                    groupNodeLableNode.setTextContent(RessourceFactory
+                            .getInstance().getRessource(
+                                    callMeta.getLanguages(),
+                                    svdb.getName(),
+                                    svdb.getName()));
+                    groupNode.appendChild(groupNodeLableNode);
+
+                    Element inputNode = xmlutilities.createXFormElement(
+                            document, "input");
+                    inputNode.setAttribute("ref", svdb.getName());
+
+                    Element inputLableNode = xmlutilities.createXFormElement(
+                            document, "label");
+                    inputLableNode.setTextContent("");
+                    inputNode.appendChild(inputLableNode);
+
+                    Element inputValueNode = xmlutilities.createXFormElement(
+                            document, "value");
+                    inputValueNode.setTextContent(svdb.getValue());
+                    inputNode.appendChild(inputValueNode);
+
+                    groupNode.appendChild(inputNode);
+                    if (!it.hasNext() && this.dataName != null) {
+                        dynamic.appendChild(groupNode);
+                    } else {
+                        staticNode.appendChild(groupNode);
+                    }
+                }
+
+            }
+        }
+    }
+
+    /**
+     * @see de.intevation.gnv.state.State#getDescibeData()
+     */
+    protected Collection<Object> getDescibeData(String uuid) {
+        if (CacheFactory.getInstance().isInitialized()) {
+            String key = uuid + DESCRIBEDATAKEY;
+            log.debug("Hash for Queryelements: " + key);
+            net.sf.ehcache.Element value = CacheFactory.getInstance().getCache().get(key);
+            if (value != null) {
+                return (Collection<Object>) (value.getObjectValue());
+            }
+        }
+        return null;
+    }
+    
+    /**
+     * @see de.intevation.gnv.state.State#getDescibeData()
+     */
+    protected void setDescibeData(String uuid, Collection<Object> describeData) {
+        
+        if (CacheFactory.getInstance().isInitialized()) {
+            String key = uuid + DESCRIBEDATAKEY;
+            log.debug("Hash for Queryelements: " + key);
+            CacheFactory.getInstance().getCache().put(new net.sf.ehcache.Element(key, describeData));
+        }
+    }
+
+    /**
+     * @see de.intevation.gnv.state.State#getInputData()
+     */
+    public Collection<InputData> getInputData() throws StateException {
+        return this.inputData != null ? this.inputData.values() : null;
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/state/StateFactory.java	Tue Dec 08 08:39:03 2009 +0000
@@ -0,0 +1,55 @@
+/**
+ *
+ */
+package de.intevation.gnv.state;
+
+import org.apache.log4j.Logger;
+import org.w3c.dom.Node;
+
+import de.intevation.gnv.artifacts.GNVArtifactBase;
+
+/**
+ * @author Tim Englich <tim.englich@intevation.de>
+ * 
+ */
+public class StateFactory {
+
+    /**
+     * the logger, used to log exceptions and additonaly information
+     */
+    private static Logger log = Logger.getLogger(GNVArtifactBase.class);
+
+    private static StateFactory instance = null;
+
+    /**
+     * Constructor
+     */
+    public StateFactory() {
+        super();
+    }
+
+    public static StateFactory getInstance() {
+        if (instance == null) {
+            instance = new StateFactory();
+        }
+        return instance;
+    }
+
+    public State createState(Node configuration) {
+        log.debug("StateFactory.createState");
+        State state = null;
+        try {
+            String classname = ((org.w3c.dom.Element)configuration).getAttribute("state");
+            state = (State) (Class.forName(classname).newInstance());
+            state.setup(configuration);
+        } catch (InstantiationException e) {
+            log.error(e, e);
+        } catch (IllegalAccessException e) {
+            log.error(e, e);
+        } catch (ClassNotFoundException e) {
+            log.error(e, e);
+        }
+        return state;
+    }
+
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/state/describedata/DefaultKeyValueDescribeData.java	Tue Dec 08 08:39:03 2009 +0000
@@ -0,0 +1,57 @@
+/**
+ *
+ */
+package de.intevation.gnv.state.describedata;
+
+/**
+ * @author Tim Englich <tim.englich@intevation.de>
+ * 
+ */
+public class DefaultKeyValueDescribeData implements KeyValueDescibeData {
+
+    /**
+     *
+     */
+    private static final long serialVersionUID = -924469415242703108L;
+
+    private String key;
+
+    private String value = null;
+
+    private boolean selected = false;
+
+    public DefaultKeyValueDescribeData(String key, String value) {
+        super();
+        this.key = key;
+        this.value = value;
+    }
+
+    /**
+     * @see de.intevation.gnv.state.describedata.KeyValueDescibeData#getKey()
+     */
+    public String getKey() {
+        return this.key;
+    }
+
+    /**
+     * @see de.intevation.gnv.state.describedata.KeyValueDescibeData#getValue()
+     */
+    public String getValue() {
+        return this.value;
+    }
+
+    /**
+     * @see de.intevation.gnv.state.describedata.KeyValueDescibeData#isSelected()
+     */
+    public boolean isSelected() {
+        return this.selected;
+    }
+
+    /**
+     * @see de.intevation.gnv.state.describedata.KeyValueDescibeData#setSelected(boolean)
+     */
+    public void setSelected(boolean selected) {
+        this.selected = selected;
+    }
+
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/state/describedata/DefaultMinMaxDescribeData.java	Tue Dec 08 08:39:03 2009 +0000
@@ -0,0 +1,92 @@
+/**
+ *
+ */
+package de.intevation.gnv.state.describedata;
+
+/**
+ * @author Tim Englich <tim.englich@intevation.de>
+ * 
+ */
+public class DefaultMinMaxDescribeData implements MinMaxDescribeData {
+
+    /**
+     *
+     */
+    private static final long serialVersionUID = -2917176219029052295L;
+
+    private Object minValue = null;
+
+    private Object maxValue = null;
+    
+    private String name = null; 
+
+    private final static String minName = "minvalue";
+
+    private final static String maxName = "maxvalue";
+
+    /**
+     * Constructor
+     */
+    public DefaultMinMaxDescribeData(String name, Object minValue, Object maxValue) {
+        super();
+        this.name = name;
+        this.minValue = minValue;
+        this.maxValue = maxValue;
+    }
+
+    /**
+     * @see de.intevation.gnv.state.describedata.MinMaxDescribeData#getMaxValue()
+     */
+    public Object getMaxValue() {
+        return this.maxValue;
+    }
+
+    /**
+     * @see de.intevation.gnv.state.describedata.MinMaxDescribeData#getMinValue()
+     */
+    public Object getMinValue() {
+        return this.minValue;
+    }
+
+    /**
+     * @see java.lang.Object#toString()
+     */
+    @Override
+    public String toString() {
+        return "MIN: " + this.minValue.toString() + " ; MAX: "
+               + this.maxValue.toString();
+    }
+
+    /**
+     * @see de.intevation.gnv.state.describedata.MinMaxDescribeData#getName()
+     */
+    public String getMinName() {
+        return minName;
+    }
+
+    /**
+     * @see de.intevation.gnv.state.describedata.MinMaxDescribeData#getMaxName()
+     */
+    public String getMaxName() {
+        return maxName;
+    }
+
+    /**
+     * @see de.intevation.gnv.state.describedata.MinMaxDescribeData#setMaxValue(java.lang.Object)
+     */
+    public void setMaxValue(Object maxValue) {
+        this.maxValue = maxValue;
+    }
+
+    /**
+     * @see de.intevation.gnv.state.describedata.MinMaxDescribeData#setMinValue(java.lang.Object)
+     */
+    public void setMinValue(Object minValue) {
+        this.minValue = minValue;
+    }
+
+    public String getName() {
+       return this.name;
+    }
+
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/state/describedata/DefaultSingleValueDescribeData.java	Tue Dec 08 08:39:03 2009 +0000
@@ -0,0 +1,51 @@
+/**
+ *
+ */
+package de.intevation.gnv.state.describedata;
+
+/**
+ * @author Tim Englich <tim.englich@intevation.de>
+ * 
+ */
+public class DefaultSingleValueDescribeData implements SingleValueDescribeData {
+
+    /**
+     *
+     */
+    private static final long serialVersionUID = 3580176842483316917L;
+
+    private String name = null;
+
+    private String value = null;
+
+    /**
+     * Constructor
+     * 
+     * @param name
+     * @param value
+     */
+    public DefaultSingleValueDescribeData(String name, String value) {
+        super();
+        this.name = name;
+        this.value = value;
+    }
+
+    /**
+     * @see de.intevation.gnv.state.describedata.SingleValueDescribeData#getName()
+     */
+    public String getName() {
+        return this.name;
+    }
+
+    /**
+     * @see de.intevation.gnv.state.describedata.SingleValueDescribeData#getValue()
+     */
+    public String getValue() {
+        return this.value;
+    }
+
+    public void setValue(String value) {
+        this.value = value;
+    }
+
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/state/describedata/DescribeData.java	Tue Dec 08 08:39:03 2009 +0000
@@ -0,0 +1,16 @@
+/**
+ *
+ */
+package de.intevation.gnv.state.describedata;
+
+import java.io.Serializable;
+
+/**
+ * Markerinterface
+ * 
+ * @author Tim Englich <tim.englich@intevation.de>
+ * 
+ */
+public interface DescribeData extends Serializable {
+
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/state/describedata/KeyValueDescibeData.java	Tue Dec 08 08:39:03 2009 +0000
@@ -0,0 +1,22 @@
+/**
+ *
+ */
+package de.intevation.gnv.state.describedata;
+
+import java.io.Serializable;
+
+/**
+ * @author Tim Englich <tim.englich@intevation.de>
+ * 
+ */
+public interface KeyValueDescibeData extends Serializable {
+
+    public String getKey();
+
+    public String getValue();
+
+    public boolean isSelected();
+
+    public void setSelected(boolean selected);
+
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/state/describedata/MinMaxDescribeData.java	Tue Dec 08 08:39:03 2009 +0000
@@ -0,0 +1,26 @@
+/**
+ *
+ */
+package de.intevation.gnv.state.describedata;
+
+/**
+ * @author Tim Englich <tim.englich@intevation.de>
+ * 
+ */
+public interface MinMaxDescribeData extends DescribeData {
+
+    public Object getMinValue();
+
+    public Object getMaxValue();
+
+    public void setMinValue(Object minValue);
+
+    public void setMaxValue(Object maxValue);
+
+    public String getName();
+    
+    public String getMinName();
+
+    public String getMaxName();
+
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/state/describedata/NamedArrayList.java	Tue Dec 08 08:39:03 2009 +0000
@@ -0,0 +1,71 @@
+/**
+ *
+ */
+package de.intevation.gnv.state.describedata;
+
+import java.util.ArrayList;
+import java.util.Collection;
+
+/**
+ * @author Tim Englich <tim.englich@intevation.de>
+ * 
+ */
+public class NamedArrayList<E> extends ArrayList<E> implements
+                                                   NamedCollection<E> {
+    /**
+     *
+     */
+    private static final long serialVersionUID = 8172229594749676354L;
+
+    private String name = null;
+
+    private boolean multiSelect = false;
+
+    /**
+     * Constructor
+     */
+    public NamedArrayList(String name) {
+        this.name = name;
+    }
+
+    /**
+     * Constructor
+     * 
+     * @param initialCapacity
+     */
+    public NamedArrayList(String name, int initialCapacity) {
+        super(initialCapacity);
+        this.name = name;
+    }
+
+    /**
+     * Constructor
+     * 
+     * @param c
+     */
+    public NamedArrayList(String name, Collection<E> c) {
+        super(c);
+        this.name = name;
+    }
+
+    /**
+     * @see de.intevation.gnv.state.describedata.NamedCollection#getName()
+     */
+    public String getName() {
+        return this.name;
+    }
+
+    /**
+     * @see de.intevation.gnv.state.describedata.NamedCollection#isMultiSelect()
+     */
+    public boolean isMultiSelect() {
+        return multiSelect;
+    }
+
+    /**
+     * @see de.intevation.gnv.state.describedata.NamedCollection#setMultiSelect(boolean)
+     */
+    public void setMultiSelect(boolean multiSelect) {
+        this.multiSelect = multiSelect;
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/state/describedata/NamedCollection.java	Tue Dec 08 08:39:03 2009 +0000
@@ -0,0 +1,19 @@
+/**
+ *
+ */
+package de.intevation.gnv.state.describedata;
+
+import java.util.Collection;
+
+/**
+ * @author Tim Englich <tim.englich@intevation.de>
+ * 
+ */
+public interface NamedCollection<E> extends Collection<E> {
+
+    public String getName();
+
+    public boolean isMultiSelect();
+
+    public void setMultiSelect(boolean multiSelect);
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/state/describedata/SingleValueDescribeData.java	Tue Dec 08 08:39:03 2009 +0000
@@ -0,0 +1,17 @@
+/**
+ *
+ */
+package de.intevation.gnv.state.describedata;
+
+/**
+ * @author Tim Englich <tim.englich@intevation.de>
+ * 
+ */
+public interface SingleValueDescribeData extends DescribeData {
+
+    public String getName();
+
+    public String getValue();
+    
+    public void setValue(String value);
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/state/exception/StateException.java	Tue Dec 08 08:39:03 2009 +0000
@@ -0,0 +1,52 @@
+/**
+ *
+ */
+package de.intevation.gnv.state.exception;
+
+/**
+ * @author Tim Englich <tim.englich@intevation.de>
+ * 
+ */
+public class StateException extends Exception {
+
+    /**
+     * The UID of the Class
+     */
+    private static final long serialVersionUID = -1635921702746050244L;
+
+    /**
+     * Constructor
+     */
+    public StateException() {
+        super();
+    }
+
+    /**
+     * Constructor
+     * 
+     * @param message
+     */
+    public StateException(String message) {
+        super(message);
+    }
+
+    /**
+     * Constructor
+     * 
+     * @param cause
+     */
+    public StateException(Throwable cause) {
+        super(cause);
+    }
+
+    /**
+     * Constructor
+     * 
+     * @param message
+     * @param cause
+     */
+    public StateException(String message, Throwable cause) {
+        super(message, cause);
+    }
+
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/state/profile/horizontal/HorizontalProfileOutputState.java	Tue Dec 08 08:39:03 2009 +0000
@@ -0,0 +1,285 @@
+/**
+ *
+ */
+package de.intevation.gnv.state.profile.horizontal;
+
+import com.vividsolutions.jts.geom.Point;
+import com.vividsolutions.jts.io.WKTReader;
+import com.vividsolutions.jts.io.ParseException;
+
+import java.io.IOException;
+import java.io.OutputStream;
+import java.io.UnsupportedEncodingException;
+import java.text.SimpleDateFormat;
+import java.util.Collection;
+import java.util.Date;
+import java.util.Iterator;
+import java.util.Locale;
+
+import org.apache.log4j.Logger;
+
+import de.intevation.gnv.chart.Chart;
+import de.intevation.gnv.chart.ChartLabels;
+import de.intevation.gnv.chart.HorizontalProfileChart;
+import de.intevation.gnv.geobackend.base.Result;
+import de.intevation.gnv.state.describedata.KeyValueDescibeData;
+import de.intevation.gnv.state.exception.StateException;
+import de.intevation.gnv.state.timeseries.TimeSeriesOutputState;
+import de.intevation.gnv.statistics.HorizontalProfileStatistics;
+import de.intevation.gnv.statistics.Statistics;
+
+import de.intevation.gnv.exports.DefaultExport;
+import de.intevation.gnv.exports.ShapeDataCollector;
+import de.intevation.gnv.exports.DefaultProfile;
+import de.intevation.gnv.exports.Export.Profile;
+
+/**
+ * @author Tim Englich <tim.englich@intevation.de>
+ * 
+ */
+public class HorizontalProfileOutputState extends
+                                              TimeSeriesOutputState {
+    /**
+     * The UID of this class
+     */
+    private static final long serialVersionUID = 4401516087492028840L;
+
+    private static Logger log = Logger
+    .getLogger(HorizontalProfileOutputState.class);
+
+    public static final String DATE_FORMAT = "yyyy.MM.dd HH:mm:ss";
+
+    public static final String [] CHART_TITLE_META = {
+        "CRUISE",
+        "DEPTH",
+        "SHAPE"
+    };
+
+
+    public static final String [] CHART_TITLE_META_RESSOURCES = {
+        "cruiseid",
+        "depth",
+        "coordinate"
+    };
+
+    public static final String [] TIMESERIES_CSV_PROFILE_NAMES = {
+        "SHAPE",
+        "YORDINATE",
+        "GROUP1",
+        "GROUP2",
+        "GROUP3"
+    };
+
+    public static final Profile TIMESERIES_CSV_PROFILE =
+        new DefaultProfile(
+            null,
+            ',',
+            '"',
+            '"',
+            "CSV",
+            "ISO-8859-1");
+
+    /**
+     * Constructor
+     */
+    public HorizontalProfileOutputState() {
+        super();
+        super.domainLable = "Distance [km]";
+    }
+
+
+    @Override
+    protected Chart getChart(
+        ChartLabels  chartLables,
+        Collection   parameters,
+        Collection   measurements,
+        Collection   dates,
+        Collection   result,
+        Locale       locale,
+        String       uuid,
+        boolean      linesVisible,
+        boolean      shapesVisible
+    ) {
+        Chart chart = null;
+
+        if (CACHE_CHART) {
+            log.info("Try to get horizontalprofile chart from cache.");
+            chart = (Chart) getChartFromCache(uuid);
+        }
+
+        if (chart != null)
+            return chart;
+
+        log.info("Chart not in cache yet.");
+        chart = new HorizontalProfileChart(
+            chartLables,
+            createStyle(),
+            parameters,
+            measurements,
+            dates,
+            result,
+            null,
+            locale,
+            linesVisible,
+            shapesVisible
+        );
+        chart.generateChart();
+
+        if (CACHE_CHART) {
+            log.info("Put chart into cache.");
+            purifyChart(chart, uuid);
+        }
+
+        return chart;
+    }
+
+
+    /**
+     * @see de.intevation.gnv.state.timeseries.TimeSeriesOutputState#getStatisticsGenerator()
+     */
+    @Override
+    protected Statistics getStatisticsGenerator() {
+        return new HorizontalProfileStatistics();
+    }
+
+    @Override
+    protected void createCSV(OutputStream outputStream,
+                             Collection<Result> chartResult)
+                                                            throws UnsupportedEncodingException,
+                                                            IOException,
+                                                            StateException {
+       
+        log.debug("createCSV for HorizontalProfileOutputState.");
+        DefaultExport export = new DefaultExport(
+            new ShapeDataCollector(TIMESERIES_CSV_PROFILE_NAMES));
+
+        export.create(TIMESERIES_CSV_PROFILE, outputStream, chartResult);
+    }
+
+
+    protected String createChartTitle(Locale locale, String uuid) {
+        String fisName = getFisName(locale);
+        log.debug("created title for horizontal profile chart: " + fisName);
+
+        return fisName;
+    }
+
+
+    protected String createChartSubtitle(Locale locale, String uuid) {
+        log.debug("create chart subtitle.");
+        String subtitle = createTimePeriod(locale, uuid);
+
+        // ODV results contain meta information about cruise, station and so on
+        Collection results = getODVResult(uuid);
+        if (results != null) {
+            Iterator iter   = results.iterator();
+            Result   result = iter.hasNext() ? (Result) iter.next() : null;
+
+            subtitle += subtitle.length() != 0 ? "\n" : "";
+            subtitle += createMetaChartSubtitle(locale, result);
+        }
+
+        return subtitle;
+    }
+
+
+    protected String createMetaChartSubtitle(Locale locale, Result result) {
+        log.debug("Fetch meta information and put it into subtitle.");
+        if (result == null)
+            return "";
+
+        StringBuilder meta      = new StringBuilder();
+        WKTReader     wktReader = new WKTReader();
+
+
+        for (int i = 0; i < CHART_TITLE_META.length; i++) {
+            String qry = CHART_TITLE_META[i];
+
+            if (qry.equals("SHAPE")) {
+                try {
+                    Point p = (Point) wktReader.read(result.getString(qry));
+
+                    meta.append(getMessage(locale,"coordinate","coordinate"));
+                    meta.append(": ");
+
+                    log.debug(
+                        "Add " + qry + " to meta information of subtitle: "
+                        + p.toString()
+                    );
+                    meta.append(p.getX() + ", " + p.getY());
+                }
+                catch (ParseException pe) {
+                    log.warn("Error while parsing point.", pe);
+                }
+            }
+            else {
+                log.debug(
+                    "Add " + qry + " to meta information of subtitle: "
+                    + result.getString(qry)
+                );
+                meta.append(getMessage(
+                    locale,
+                    CHART_TITLE_META_RESSOURCES[i],
+                    CHART_TITLE_META_RESSOURCES[i]
+                ));
+                meta.append(": ");
+                meta.append(result.getString(qry));
+            }
+
+            if (i != CHART_TITLE_META.length-1)
+                meta.append("\n");
+        }
+
+        log.debug("Meta title for chart: " + meta.toString());
+        return meta.toString();
+    }
+
+
+    protected String createTimePeriod(Locale locale, String uuid) {
+        log.debug("create time period for chart subtitle.");
+        String subTitle = null;
+        Date startDate  = null;
+        Date endDate    = null;
+
+        Collection          dates  = getDates(uuid);
+        if (dates == null) {
+            log.debug("No time period for subtitle.");
+            return "";
+        }
+
+        SimpleDateFormat    format = new SimpleDateFormat(DATE_FORMAT);
+        KeyValueDescibeData data   = null;
+
+        Iterator iter = dates.iterator();
+        while (iter.hasNext()) {
+            try {
+                data = (KeyValueDescibeData)iter.next();
+
+                if (!data.isSelected())
+                    continue;
+
+                Date current = format.parse(data.getValue());
+                long time    = current.getTime();
+
+                if (startDate == null) {
+                    startDate = current;
+                    endDate   = current;
+                }
+                else if (time < startDate.getTime()) {
+                    startDate = current;
+                }
+                else if (time > endDate.getTime()) {
+                    endDate = current;
+                }
+            }
+            catch (java.text.ParseException pe) {
+                log.warn("Error while parsing date: " + data.getValue(), pe);
+            }
+        }
+
+        subTitle = format.format(startDate) + " - " + format.format(endDate);
+        log.debug("created title for horizontal profile chart: " + subTitle);
+
+        return subTitle;
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/state/profile/horizontal/NorthSouthEastWestState.java	Tue Dec 08 08:39:03 2009 +0000
@@ -0,0 +1,67 @@
+/**
+ *
+ */
+package de.intevation.gnv.state.profile.horizontal;
+
+import java.util.ArrayList;
+import java.util.Collection;
+
+import de.intevation.artifacts.CallMeta;
+import de.intevation.gnv.artifacts.ressource.RessourceFactory;
+import de.intevation.gnv.geobackend.base.Result;
+import de.intevation.gnv.state.StateBase;
+import de.intevation.gnv.state.describedata.DefaultKeyValueDescribeData;
+import de.intevation.gnv.state.describedata.KeyValueDescibeData;
+import de.intevation.gnv.state.describedata.NamedArrayList;
+import de.intevation.gnv.state.describedata.NamedCollection;
+import de.intevation.gnv.state.exception.StateException;
+
+/**
+ * @author Tim Englich <tim.englich@intevation.de>
+ * 
+ */
+public class NorthSouthEastWestState extends StateBase {
+
+    
+    /**
+     * The UID of this Class
+     */
+    private static final long serialVersionUID = -7989531326553305293L;
+
+    /**
+     * Constructor
+     */
+    public NorthSouthEastWestState() {
+    }
+
+    /**
+     * @see de.intevation.gnv.state.StateBase#purifyResult(java.util.Collection, java.lang.String)
+     */
+    @Override
+    protected void purifyResult(Collection<Result> result, String uuid) {
+    }
+    
+    /**
+     * @see de.intevation.gnv.state.StateBase#initialize(java.lang.String, de.intevation.artifacts.CallMeta)
+     */
+    @Override
+    public void initialize(String uuid, CallMeta callMeta)
+                                                          throws StateException {
+        Collection<Object> describeData = this.getDescibeData(uuid);
+        if (describeData == null) {
+            describeData = new ArrayList<Object>();
+        }
+        NamedCollection<KeyValueDescibeData> keyValueDescibeData = new NamedArrayList<KeyValueDescibeData>(
+                this.dataName, 2);
+        keyValueDescibeData.setMultiSelect(super.dataMultiSelect);
+        keyValueDescibeData.add(new DefaultKeyValueDescribeData("IPOSITION",
+                RessourceFactory.getInstance().getRessource(
+                        callMeta.getLanguages(), "iposition", "iposition")));
+        keyValueDescibeData.add(new DefaultKeyValueDescribeData("JPOSITION",
+                RessourceFactory.getInstance().getRessource(
+                        callMeta.getLanguages(), "jposition", "jposition")));
+        describeData.add(keyValueDescibeData);
+    }
+
+
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/state/profile/horizontalcrosssection/HorizontalCrossSectionMeshOutputState.java	Tue Dec 08 08:39:03 2009 +0000
@@ -0,0 +1,143 @@
+/**
+ *
+ */
+package de.intevation.gnv.state.profile.horizontalcrosssection;
+
+import java.io.IOException;
+import java.io.OutputStream;
+import java.io.OutputStreamWriter;
+import java.io.UnsupportedEncodingException;
+import java.util.Collection;
+import java.util.Iterator;
+import java.util.Locale;
+
+import org.apache.log4j.Logger;
+
+import au.com.bytecode.opencsv.CSVWriter;
+import de.intevation.gnv.chart.Chart;
+import de.intevation.gnv.chart.ChartLabels;
+import de.intevation.gnv.geobackend.base.Result;
+import de.intevation.gnv.state.exception.StateException;
+import de.intevation.gnv.state.timeseries.TimeSeriesOutputState;
+import de.intevation.gnv.statistics.Statistics;
+
+/**
+ * @author Tim Englich <tim.englich@intevation.de>
+ * 
+ */
+public class HorizontalCrossSectionMeshOutputState 
+                                      extends TimeSeriesOutputState {
+
+    private static Logger log = Logger
+    .getLogger(HorizontalCrossSectionMeshOutputState.class);
+    
+    /**
+     * The UID of this Class
+     */
+    private static final long serialVersionUID = 3233620652465061860L;
+
+    /**
+     * Constructor
+     */
+    public HorizontalCrossSectionMeshOutputState() {
+        super();
+        super.domainLable = "Latitude [m]";
+    }
+
+    @Override
+    protected Chart getChart(
+        ChartLabels  chartLables,
+        Collection   parameters,
+        Collection   measurements,
+        Collection   dates,
+        Collection   result,
+        Locale       locale,
+        String       uuid,
+        boolean      linesVisible,
+        boolean      shapesVisible
+    ) {
+        Chart chart = null;
+
+        if (CACHE_CHART) {
+            log.info("Try to get horizontalcrosssection chart from cache.");
+            chart = (Chart) getChartFromCache(uuid);
+        }
+
+        if (chart != null)
+            return chart;
+
+        log.info("Chart not in cache yet.");
+        
+        log.warn("This sort of chart is not implemented yet.");
+        /* TODO Implement a special chart for this sort of charts.
+        chart = new HorizontalProfileChart(
+            chartLables,
+            chartTheme,
+            parameters,
+            measurements,
+            result,
+            dates,
+            locale
+        );
+        chart.generateChart();
+
+        if (CACHE_CHART) {
+            log.info("Put chart into cache.");
+            purifyChart(chart, uuid);
+        }
+        */
+
+        return chart;
+    }
+
+
+    /**
+     * @see de.intevation.gnv.state.timeseries.TimeSeriesOutputState#getStatisticsGenerator()
+     */
+    @Override
+    protected Statistics getStatisticsGenerator() {
+        return null; //Statistiken werden nicht für diesen Out-Typ unterstützt.
+    }
+    
+    /**
+     * @see de.intevation.gnv.state.timeseries.TimeSeriesOutputState#createCSV(java.io.OutputStream,
+     *      java.util.Collection)
+     */
+    @Override
+    protected void createCSV(OutputStream outputStream,
+                             Collection<Result> chartResult)
+                                            throws UnsupportedEncodingException,
+                                                   IOException,
+                                                   StateException {
+        if (chartResult != null) {
+            try {
+                CSVWriter writer = new CSVWriter(new OutputStreamWriter(
+                        outputStream, "ISO-8859-1"), ','); 
+                // USE THIS ENCODING BECAUSE OF
+                // PROBLEMS WITH EXCEL AND UTF-8
+                Iterator<Result> it = chartResult.iterator();
+                while (it.hasNext()) {
+                    Result result = it.next();
+                    int i = 0;
+                    String[] entries = new String[5];
+                    entries[i++] = result.getString("SHAPE");
+                    entries[i++] = result.getString("YORDINATE");
+                    entries[i++] = result.getString("IPOSITION");
+                    entries[i++] = result.getString("JPOSITION");
+                    entries[i++] = result.getString("KPOSITION");
+                    writer.writeNext(entries);
+                }
+                writer.close();
+            } catch (Exception e) {
+                log.error(e,e);
+                throw new StateException(
+                "Exception occured while parsing an Point from WKT.");
+            }
+        } else {
+            log.error("No Data given for generating an CSV-File.");
+            throw new StateException(
+                    "No Data given for generating an CSV-File.");
+        }
+    }
+
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/state/profile/vertical/VerticalProfileOutputState.java	Tue Dec 08 08:39:03 2009 +0000
@@ -0,0 +1,100 @@
+/**
+ *
+ */
+package de.intevation.gnv.state.profile.vertical;
+
+import java.util.Collection;
+import java.util.Locale;
+
+import org.apache.log4j.Logger;
+
+import de.intevation.gnv.chart.Chart;
+import de.intevation.gnv.chart.ChartLabels;
+import de.intevation.gnv.chart.VerticalProfileChart;
+import de.intevation.gnv.state.timeseries.TimeSeriesOutputState;
+import de.intevation.gnv.statistics.Statistics;
+import de.intevation.gnv.statistics.VerticalProfileStatistics;
+
+/**
+ * @author Tim Englich <tim.englich@intevation.de>
+ * 
+ */
+public class VerticalProfileOutputState extends TimeSeriesOutputState {
+    /**
+     * The UID of this class
+     */
+    private static final long serialVersionUID = 4401516087492028840L;
+
+    private static Logger log = Logger
+            .getLogger(TimeSeriesOutputState.class);
+
+    /**
+     * Constructor
+     */
+    public VerticalProfileOutputState() {
+        super();
+        super.domainLable = "Depth [m]";
+    }
+
+    
+    @Override
+    protected Chart getChart(
+        ChartLabels chartLables,
+        Collection  parameters,
+        Collection  measurements,
+        Collection  dates,
+        Collection  result,
+        Locale      locale,
+        String      uuid,
+        boolean     linesVisible,
+        boolean     shapesVisible
+    ) {
+        Chart chart = null;
+
+        if (CACHE_CHART) {
+            log.info("Try to get verticalprofile chart from cache.");
+            chart = (Chart) getChartFromCache(uuid);
+        }
+
+        if (chart != null)
+            return chart;
+
+        log.info("Chart not in cache yet.");
+        chart = new VerticalProfileChart(
+            chartLables,
+            this.createStyle(),
+            parameters,
+            measurements,
+            dates,
+            result,
+            null,
+            locale,
+            linesVisible,
+            shapesVisible
+        );
+        chart.generateChart();
+
+        if (CACHE_CHART) {
+            log.info("Put chart into cache.");
+            purifyChart(chart, uuid);
+        }
+
+        return chart;
+    }
+
+
+    protected String createChartSubtitle(Locale locale, String uuid) {
+        return getSelectedFeatureName(uuid);
+    }
+
+
+
+    /**
+     * @see de.intevation.gnv.state.timeseries.TimeSeriesOutputState#getStatisticsGenerator()
+     */
+    @Override
+    protected Statistics getStatisticsGenerator() {
+        return new VerticalProfileStatistics();
+    }
+
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/state/profile/verticalcrosssection/VerticalCrossSectionOutputState.java	Tue Dec 08 08:39:03 2009 +0000
@@ -0,0 +1,177 @@
+/**
+ *
+ */
+package de.intevation.gnv.state.profile.verticalcrosssection;
+
+import java.io.IOException;
+import java.io.OutputStream;
+import java.io.OutputStreamWriter;
+import java.io.UnsupportedEncodingException;
+import java.util.Collection;
+import java.util.Iterator;
+import java.util.Locale;
+
+import org.apache.log4j.Logger;
+
+import au.com.bytecode.opencsv.CSVWriter;
+
+import com.vividsolutions.jts.geom.Point;
+import com.vividsolutions.jts.io.ParseException;
+import com.vividsolutions.jts.io.WKTReader;
+
+import de.intevation.gnv.chart.Chart;
+import de.intevation.gnv.chart.ChartLabels;
+import de.intevation.gnv.chart.ChartStyle;
+import de.intevation.gnv.chart.VerticalCrossSectionChartFactory;
+import de.intevation.gnv.chart.exception.TechnicalChartException;
+import de.intevation.gnv.geobackend.base.Result;
+import de.intevation.gnv.state.describedata.KeyValueDescibeData;
+import de.intevation.gnv.state.exception.StateException;
+import de.intevation.gnv.state.timeseries.TimeSeriesOutputState;
+import de.intevation.gnv.statistics.Statistics;
+import de.intevation.gnv.statistics.VerticalProfileStatistics;
+
+/**
+ * @author Tim Englich <tim.englich@intevation.de>
+ * 
+ */
+public class VerticalCrossSectionOutputState extends TimeSeriesOutputState {
+
+    private static Logger log = Logger
+    .getLogger(VerticalCrossSectionOutputState.class);
+    
+    /**
+     * The UID of this Class
+     */
+    private static final long serialVersionUID = 3233620652465061860L;
+
+    /**
+     * Constructor
+     */
+    public VerticalCrossSectionOutputState() {
+        super();
+        super.domainLable = "Depth [m]";
+    }
+
+    @Override
+    protected Chart getChart(
+        ChartLabels  chartLables,
+        Collection   parameters,
+        Collection   measurements,
+        Collection   dates,
+        Collection   result,
+        Locale       locale,
+        String       uuid,
+        boolean      linesVisible,
+        boolean      shapesVisible
+    ) {
+        Chart chart = null;
+
+        if (CACHE_CHART) {
+            log.info("Try to get verticalcrosssection chart from cache.");
+            chart = (Chart) getChartFromCache(uuid);
+        }
+
+        if (chart != null)
+            return chart;
+
+        log.info("Chart not in cache yet.");
+        
+        log.warn("This sort of chart is not implemented yet.");
+        /* TODO Implement a special chart for this sort of charts.
+        chart = new VerticalProfileChart(
+            chartLables,
+            chartTheme,
+            parameters,
+            measurements,
+            result,
+            dates,
+            locale
+        );
+        chart.generateChart();
+
+        if (CACHE_CHART) {
+            log.info("Put chart into cache.");
+            purifyChart(chart, uuid);
+        }
+        */
+
+        return chart;
+    }
+
+    /**
+     * @see de.intevation.gnv.state.timeseries.TimeSeriesOutputState#createChart(java.io.OutputStream,
+     *      java.util.Collection, java.util.Collection, java.lang.String,
+     *      de.intevation.gnv.chart.ChartStyle,
+     *      de.intevation.gnv.chart.ChartLabels)
+     */
+    /*
+    @Override
+    protected void createChart(OutputStream outputStream,
+                               Collection<KeyValueDescibeData> parameters,
+                               Collection<KeyValueDescibeData> measurements,
+                               Collection<KeyValueDescibeData> dates,
+                               ChartStyle chartStyle, ChartLabels chartLables,
+                               String uuid) throws IOException,
+                                           TechnicalChartException {
+        new VerticalCrossSectionChartFactory().createProfileChart(chartLables,
+                chartStyle, parameters, measurements, dates, outputStream, this
+                        .getChartResult(uuid));
+    }
+    */
+
+    /**
+     * @see de.intevation.gnv.state.timeseries.TimeSeriesOutputState#getStatisticsGenerator()
+     */
+    @Override
+    protected Statistics getStatisticsGenerator() {
+        return new VerticalProfileStatistics();
+    }
+    
+    /**
+     * @see de.intevation.gnv.state.timeseries.TimeSeriesOutputState#createCSV(java.io.OutputStream, java.util.Collection)
+     */
+    @Override
+    protected void createCSV(OutputStream outputStream,
+                             Collection<Result> chartResult)
+                                                            throws UnsupportedEncodingException,
+                                                            IOException,
+                                                            StateException {
+        if (chartResult != null) {
+            try {
+                CSVWriter writer = new CSVWriter(new OutputStreamWriter(
+                        outputStream, "ISO-8859-1"), ','); 
+                // USE THIS ENCODING BECAUSE OF
+                // PROBLEMS WITH EXCEL AND UTF-8
+                Iterator<Result> it = chartResult.iterator();
+                WKTReader wktReader = new WKTReader();
+                while (it.hasNext()) {
+                    Result result = it.next();
+                    int i = 0;
+                    String[] entries = new String[9];
+                    Point p = (Point)wktReader.read(result.getString("SHAPE"));
+                    entries[i++] = ""+p.getX();
+                    entries[i++] = ""+p.getY();
+                    entries[i++] = result.getString("Z");
+                    entries[i++] = result.getString("YORDINATE");
+                    entries[i++] = result.getString("GROUP1");
+                    entries[i++] = result.getString("GROUP2");
+                    entries[i++] = result.getString("IPOSITION");
+                    entries[i++] = result.getString("JPOSITION");
+                    entries[i++] = result.getString("KPOSITION");
+                    writer.writeNext(entries);
+                }
+                writer.close();
+            } catch (ParseException e) {
+                log.error(e,e);
+                throw new StateException(
+                "Exception occured while parsing an Point from WKT.");
+            }
+        } else {
+            log.error("No Data given for generating an CSV-File.");
+            throw new StateException(
+                    "No Data given for generating an CSV-File.");
+        }
+    }
+
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/state/timeseries/TimeSeriesOutputState.java	Tue Dec 08 08:39:03 2009 +0000
@@ -0,0 +1,835 @@
+/**
+ *
+ */
+package de.intevation.gnv.state.timeseries;
+
+import java.io.IOException;
+import java.io.File;
+import java.io.OutputStream;
+import java.io.FileOutputStream;
+import java.io.UnsupportedEncodingException;
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.Iterator;
+import java.util.List;
+import java.util.Locale;
+import java.util.Vector;
+
+import javax.xml.transform.Transformer;
+import javax.xml.transform.TransformerConfigurationException;
+import javax.xml.transform.TransformerException;
+import javax.xml.transform.TransformerFactory;
+import javax.xml.transform.TransformerFactoryConfigurationError;
+import javax.xml.transform.dom.DOMSource;
+import javax.xml.transform.stream.StreamResult;
+
+import org.apache.log4j.Logger;
+import org.w3c.dom.Document;
+import org.w3c.dom.Element;
+import org.w3c.dom.Node;
+import org.w3c.dom.NodeList;
+
+import org.jfree.chart.ChartTheme;
+
+import au.com.bytecode.opencsv.CSVWriter;
+import de.intevation.artifactdatabase.Config;
+import de.intevation.artifactdatabase.XMLUtils;
+import de.intevation.artifacts.CallMeta;
+import de.intevation.artifacts.PreferredLocale;
+import de.intevation.gnv.artifacts.ressource.RessourceFactory;
+import de.intevation.gnv.chart.Chart;
+import de.intevation.gnv.chart.ChartLabels;
+import de.intevation.gnv.chart.TimeSeriesChart;
+import de.intevation.gnv.chart.XMLChartTheme;
+import de.intevation.gnv.chart.exception.TechnicalChartException;
+import de.intevation.gnv.exports.ChartExportHelper;
+import de.intevation.gnv.exports.DefaultExport;
+import de.intevation.gnv.exports.DefaultDataCollector;
+import de.intevation.gnv.exports.SimpleOdvDataCollector;
+import de.intevation.gnv.exports.DefaultProfile;
+import de.intevation.gnv.exports.Export.Profile;
+import de.intevation.gnv.geobackend.base.Result;
+import de.intevation.gnv.state.InputData;
+import de.intevation.gnv.state.OutputStateBase;
+import de.intevation.gnv.state.describedata.KeyValueDescibeData;
+import de.intevation.gnv.state.describedata.NamedCollection;
+import de.intevation.gnv.state.exception.StateException;
+import de.intevation.gnv.statistics.Statistic;
+import de.intevation.gnv.statistics.StatisticSet;
+import de.intevation.gnv.statistics.Statistics;
+import de.intevation.gnv.statistics.TimeseriesStatistics;
+import de.intevation.gnv.statistics.exception.StatisticsException;
+import de.intevation.gnv.timeseries.gap.DefaultTimeGap;
+import de.intevation.gnv.timeseries.gap.TimeGap;
+import de.intevation.gnv.utils.ArtifactXMLUtilities;
+
+
+/**
+ * @author Tim Englich <tim.englich@intevation.de>
+ * 
+ */
+public class TimeSeriesOutputState extends OutputStateBase {
+
+    protected static final boolean CACHE_CHART =
+        Boolean.parseBoolean(System.getProperty("cache.chart", "false"));
+
+    protected static final boolean PDF_FORMAT_LANDSCAPE =
+        Boolean.parseBoolean(System.getProperty("export.pdf.landscape","true"));
+
+    protected static final String[] IMG_EXPORT_FORMAT = {
+        "PNG", "JPEG", "GIF"
+    };
+
+    /**
+     * The UID of this Class
+     */
+    private static final long serialVersionUID = 4178407570503098858L;
+
+    /**
+     * the logger, used to log exceptions and additonaly information
+     */
+    private static Logger log = Logger
+            .getLogger(TimeSeriesOutputState.class);
+
+    private static List<TimeGap> timeGapDefinitions = null;
+
+    protected String domainLable = "Zeit [UTC]";
+
+    protected String featureValuesName = "featureid";
+    protected String parameterValuesName = "parameterid";
+    protected String measuremenValueName = "measurementid";
+    protected String dateValueName = "dateid";
+    
+    public static final String [] TIMESERIES_CSV_PROFILE_NAMES = {
+        "XORDINATE",
+        "YORDINATE",
+        "GROUP1",
+        "GROUP2",
+        "GROUP3"
+    };
+    
+    public static final String [] TIMESERIES_ODV_PROFILE_NAMES = {
+          "CRUISE",
+          "STATION",
+          "TYPE",
+          "SHAPE",
+          "BOTDEPTH",
+          "DEPTH",
+          "TIMEVALUE",
+          "DATAVALUE",
+          "PARAMETER"
+    };
+
+
+    public static final String [] ODV_COLUMN_HEADER = {
+        "Cruise",
+        "Station",
+        "Type",
+        "Longitude [deegrees_east]",
+        "Latitude [deegrees_north]",
+        "Bot. Depth [m]",
+        "Depth [m]",
+        "Date/Time",
+        "Value",
+        "Parameterid"
+    };
+
+    /**
+     * Profile for exporting data to cvs
+     */
+    public static final Profile TIMESERIES_CSV_PROFILE =
+        new DefaultProfile(
+            null,
+            ',',
+            '"',
+            '"',
+            "CSV",
+            "ISO-8859-1");
+
+    /**
+     * Profile for exporting data to odv
+     * TODO Change TIMESERIES_PROFILE_NAMES, which belong to CSV exports
+     */
+    public static final Profile TIMESERIES_ODV_PROFILE =
+        new DefaultProfile(
+            ODV_COLUMN_HEADER,
+            '\t',
+            CSVWriter.NO_QUOTE_CHARACTER,
+            CSVWriter.NO_ESCAPE_CHARACTER,
+            "ODV",
+            "ISO-8859-1");
+
+    /**
+     * Constructor
+     */
+    public TimeSeriesOutputState() {
+        super();
+    }
+
+    /**
+     * @see de.intevation.gnv.transition.OutputTransition#out(java.lang.String,
+     *      java.util.Collection, java.io.OutputStream, java.lang.String,
+     *      de.intevation.artifacts.CallMeta)
+     */
+    public void out(
+        Document format,
+        Collection<InputData> inputData,
+        OutputStream outputStream,
+        String uuid,
+        CallMeta callMeta
+    ) throws StateException
+    {
+        log.debug("TimeSeriesOutputTransition.out");
+
+        String outputMode = Config.getStringXPath(
+            format,
+            "action/out/@name"
+        );
+        String mimeType   = Config.getStringXPath(
+            format,
+            "action/out/mime-type/@value"
+        );
+
+        try {
+            if (outputMode.equalsIgnoreCase("chart")) {
+                log.debug("Chart will be generated.");
+                int chartWidth = 600;
+                int chartHeight = 400;
+                try {
+                    if (inputData != null) {
+                        Iterator<InputData> it = inputData.iterator();
+                        while (it.hasNext()) {
+                            InputData ip = it.next();
+                            if (ip.getName().equalsIgnoreCase("width")) {
+                                chartWidth = Integer.parseInt(ip.getValue());
+                            } else if (ip.getName().equalsIgnoreCase("height")) {
+                                chartHeight = Integer.parseInt(ip.getValue());
+                            }
+                        }
+                    }
+                } catch (NumberFormatException e) {
+                    log.error(e, e);
+                    throw new StateException(e);
+                }
+
+                PreferredLocale[] locales = callMeta.getLanguages();
+                Locale[] serverLocales    =
+                    RessourceFactory.getInstance().getLocales();
+                Locale locale             =
+                    callMeta.getPreferredLocale(serverLocales);
+
+                log.debug(
+                    "Best locale - regarding intersection of server and " +
+                    "browser locales -  is " + locale.toString()
+                );
+
+                Collection parameters   = this.getCleanedParameters(uuid);
+                Collection measurements = this.getMeasurements(uuid);
+                Collection dates        = this.getDates(uuid);
+
+                ChartLabels chartLables = new ChartLabels(
+                    createChartTitle(locale, uuid),
+                    createChartSubtitle(locale, uuid),
+                    domainLable
+                );
+
+                String exportFormat = getExportFormat(mimeType);
+
+                // TODO Remove this and parse input data
+                boolean linesVisible = true;
+                boolean shapesVisible = true;
+
+                this.createChart(
+                    outputStream,
+                    parameters,
+                    measurements,
+                    dates,
+                    chartLables,
+                    uuid,
+                    exportFormat,
+                    locale,
+                    chartWidth,
+                    chartHeight,
+                    linesVisible,
+                    shapesVisible
+                );
+            }
+            else if (outputMode.equalsIgnoreCase("pdf")) {
+                log.debug("Output mode == pdf");
+
+                Locale[] serverLocales    =
+                    RessourceFactory.getInstance().getLocales();
+                Locale locale             =
+                    callMeta.getPreferredLocale(serverLocales);
+
+                // TODO Remove this and parse input data
+                boolean linesVisible = true;
+                boolean shapesVisible = true;
+
+                log.debug(
+                    "Best locale - regarding intersection of server and " +
+                    "browser locales -  is " + locale.toString()
+                );
+
+                createPDF(
+                    outputStream,
+                    getCleanedParameters(uuid),
+                    getMeasurements(uuid),
+                    getDates(uuid),
+                    new ChartLabels(
+                        createChartTitle(locale, uuid),
+                        createChartSubtitle(locale, uuid),
+                        domainLable),
+                    uuid,
+                    "A4",
+                    true,
+                    locale,
+                    linesVisible,
+                    shapesVisible
+                );
+            }
+            else if (outputMode.equalsIgnoreCase("svg")) {
+                log.debug("Output mode == svg");
+                int width  = 600;
+                int height = 400;
+
+                // TODO Remove this and parse input data
+                boolean linesVisible = true;
+                boolean shapesVisible = true;
+
+                Locale[] serverLocales    =
+                    RessourceFactory.getInstance().getLocales();
+                Locale locale             =
+                    callMeta.getPreferredLocale(serverLocales);
+
+                log.debug(
+                    "Best locale - regarding intersection of server and " +
+                    "browser locales -  is " + locale.toString()
+                );
+
+                createSVG(
+                    outputStream,
+                    getCleanedParameters(uuid),
+                    getMeasurements(uuid),
+                    getDates(uuid),
+                    new ChartLabels(
+                        createChartTitle(locale, uuid),
+                        createChartSubtitle(locale, uuid),
+                        domainLable
+                    ),
+                    uuid,
+                    locale,
+                    width,
+                    height,
+                    linesVisible,
+                    shapesVisible
+                );
+            }
+            else if (outputMode.equalsIgnoreCase("csv")) {
+                log.debug("CSV-File will be generated.");
+                Collection<Result> chartResult = this.getChartResult(uuid);
+                this.createCSV(outputStream, chartResult);
+            } else if (outputMode.equalsIgnoreCase("statistics")) {
+                log.debug("Statistics will be generated.");
+                Statistics s = getStatisticsGenerator();
+                Collection<Result> chartResult = this.getChartResult(uuid);
+                Collection<KeyValueDescibeData> parameters = 
+                                                this.getParameters(uuid);
+                Collection<KeyValueDescibeData> measurements = 
+                                                this.getMeasurements(uuid);
+                Collection<KeyValueDescibeData> dates = 
+                                                this.getDates(uuid);
+                Collection<StatisticSet> statistics = 
+                                      s.calculateStatistics(chartResult,
+                                                            parameters,
+                                                            measurements,
+                                                            dates);
+                Document doc = this.writeStatistics2XML(statistics);
+                this.writeDocument2OutputStream(doc, outputStream);
+            } else if (outputMode.equalsIgnoreCase("odv")) {
+                
+                Collection<Result> odvResult = this.getODVResult(uuid);
+                this.createODV(outputStream, odvResult);
+            }
+        } catch (IOException e) {
+            log.error(e, e);
+            throw new StateException(e);
+        } catch (TechnicalChartException e) {
+            log.error(e, e);
+            throw new StateException(e);
+        } catch (StatisticsException e) {
+            log.error(e, e);
+            throw new StateException(e);
+        }
+    }
+
+
+    protected String getExportFormat(String mime) {
+        for(int i = 0; i < IMG_EXPORT_FORMAT.length; i++) {
+            if (mime.trim().toUpperCase().indexOf(IMG_EXPORT_FORMAT[i]) > 0)
+                return IMG_EXPORT_FORMAT[i];
+        }
+
+        // no format found relating to mimeType, default export as PNG
+        return IMG_EXPORT_FORMAT[0];
+    }
+
+
+    protected Collection getCleanedParameters(Collection parameters) {
+        Iterator iter        = parameters.iterator();
+        Collection parameter = new Vector(parameters);
+        while (iter.hasNext()) {
+            KeyValueDescibeData data = (KeyValueDescibeData)iter.next();
+            if (!data.isSelected())
+                parameter.remove(data);
+        }
+
+        return parameter;
+    }
+
+
+    protected Collection getCleanedParameters(String uuid) {
+        return getCleanedParameters(getParameters(uuid));
+    }
+
+
+    /**
+     * @param outputStream
+     * @param chartResult
+     * @throws UnsupportedEncodingException
+     * @throws IOException
+     * @throws StateException
+     */
+    protected void createCSV(OutputStream outputStream,
+                            Collection<Result> chartResult)
+                                                          throws UnsupportedEncodingException,
+                                                          IOException,
+                                                          StateException {
+        DefaultExport export = new DefaultExport(new DefaultDataCollector(
+            TIMESERIES_CSV_PROFILE_NAMES));
+
+        export.create(TIMESERIES_CSV_PROFILE, outputStream, chartResult);
+    }
+
+    /**
+     * TODO Result is not used at the moment. Change result with correct data.
+     */
+    protected void createODV(OutputStream outputStream, Collection result)
+    throws IOException, StateException {
+
+        DefaultExport export = new DefaultExport(new SimpleOdvDataCollector(
+            TIMESERIES_ODV_PROFILE_NAMES));
+
+        if (result == null)
+            log.error("#################### RESULT == NULL #################");
+        export.create(TIMESERIES_ODV_PROFILE, outputStream, result);
+    }
+
+    /**
+     * @return
+     */
+    protected Statistics getStatisticsGenerator() {
+        Statistics s = new TimeseriesStatistics();
+        return s;
+    }
+
+    protected void writeDocument2OutputStream(Document document, OutputStream os) {
+
+        try {
+            TransformerFactory transformerFactory = TransformerFactory
+                    .newInstance();
+            Transformer transformer = transformerFactory.newTransformer();
+            DOMSource source = new DOMSource(document);
+            StreamResult result = new StreamResult(os);
+            transformer.transform(source, result);
+        } catch (TransformerConfigurationException e) {
+            log.error(e, e);
+        } catch (TransformerFactoryConfigurationError e) {
+            log.error(e, e);
+        } catch (TransformerException e) {
+            log.error(e, e);
+        }
+    }
+
+    protected Document writeStatistics2XML( Collection<StatisticSet> statistic) {
+        ArtifactXMLUtilities xmlUtilities = new ArtifactXMLUtilities();
+        Document doc = XMLUtils.newDocument();
+        if (statistic != null) {
+            Node statisticResults = xmlUtilities.createArtifactElement(doc,
+                    "statistics");
+            doc.appendChild(statisticResults);
+            Iterator<StatisticSet> it = statistic.iterator();
+            while (it.hasNext()) {
+                StatisticSet set = it.next();
+                Element setElement = xmlUtilities.createArtifactElement(doc,
+                                                                       "statistic");
+                setElement.setAttribute("name", set.getName());
+                
+                Iterator<Statistic> sit = set.getStatistics().iterator();
+                while (sit.hasNext()){
+                    Statistic s = sit.next();
+                    Element result = xmlUtilities.createArtifactElement(doc,
+                    "statistic-value");
+                    result.setAttribute("name", s.getKey());
+                    result.setAttribute("value", s.getStringValue());
+                    setElement.appendChild(result);
+                }
+                statisticResults.appendChild(setElement);
+            }
+
+        }
+        return doc;
+    }
+
+
+    protected String getSelectedFeatureName(String uuid) {
+        Collection values = getCollection(featureValuesName, uuid);
+
+        if (values != null) {
+            Iterator it = values.iterator();
+
+            while (it.hasNext()) {
+                KeyValueDescibeData data = (KeyValueDescibeData) it.next();
+
+                if (data.isSelected()) {
+                    return data.getValue();
+                }
+            }
+        }
+        return null;
+    }
+
+
+    /**
+     * @param outputStream
+     * @param parameters
+     * @param measurements
+     * @param timeSeriesName
+     * @param chartStyle
+     * @param chartLables
+     * @throws IOException
+     * @throws TechnicalChartException
+     */
+    protected void createChart(
+        OutputStream outputStream,
+        Collection   parameters,
+        Collection   measurements,
+        Collection   dates,
+        ChartLabels  chartLables,
+        String       uuid,
+        String       exportFormat,
+        Locale       locale,
+        int          width,
+        int          height,
+        boolean      linesVisible,
+        boolean      shapesVisible
+    )
+    throws IOException, TechnicalChartException
+    {
+        log.debug("Create chart.");
+        Chart chart = getChart(
+            chartLables,
+            parameters,
+            measurements,
+            dates,
+            getChartResult(uuid),
+            locale, // Locale
+            uuid,
+            linesVisible,
+            shapesVisible
+        );
+
+        if (chart == null) {
+            log.error("Could not initialize chart.");
+            return;
+        }
+
+        log.debug(
+            "export chart as " + exportFormat +
+            " in " + width + "x" + height
+        );
+
+        ChartExportHelper.exportImage(
+            outputStream,
+            chart.generateChart(),
+            exportFormat,
+            width,
+            height
+        );
+    }
+
+
+    protected void createPDF(
+        OutputStream outputStream,
+        Collection   parameters,
+        Collection   measurements,
+        Collection   dates,
+        ChartLabels  chartLables,
+        String       uuid,
+        String       exportFormat,
+        boolean      landscape,
+        Locale       locale,
+        boolean      linesVisible,
+        boolean      shapesVisible
+    ) {
+        Chart chart = getChart(
+            chartLables,
+            parameters,
+            measurements,
+            dates,
+            getChartResult(uuid),
+            locale,
+            uuid,
+            linesVisible,
+            shapesVisible
+        );
+
+        if (chart == null) {
+            log.error("Could not initialize chart.");
+            return;
+        }
+
+        ChartExportHelper.exportPDF(
+            outputStream,
+            chart.generateChart(),
+            "A4",
+            PDF_FORMAT_LANDSCAPE,
+            50F, 50F, 50F, 50F
+        );
+
+        try {
+            OutputStream toFile = new FileOutputStream("/vol1/home/iweinzierl/tmp/test.svg");
+            ChartExportHelper.exportSVG(
+                toFile,
+                chart.generateChart(),
+                null,
+                600, 400
+            );
+            toFile.flush();
+            toFile.close();
+        }
+        catch(Exception e) { log.debug("ERROR WHLILE TEST."); }
+    }
+
+
+    protected void createSVG(
+        OutputStream outputStream,
+        Collection   parameters,
+        Collection   measurements,
+        Collection   dates,
+        ChartLabels  chartLables,
+        String       uuid,
+        Locale       locale,
+        int          width,
+        int          height,
+        boolean      linesVisible,
+        boolean      shapesVisible
+    ) {
+        Chart chart = getChart(
+            chartLables,
+            parameters,
+            measurements,
+            dates,
+            getChartResult(uuid),
+            locale,
+            uuid,
+            linesVisible,
+            shapesVisible
+        );
+
+        if (chart == null) {
+            log.error("Could not initialize chart.");
+            return;
+        }
+
+        ChartExportHelper.exportSVG(
+            outputStream,
+            chart.generateChart(),
+            null,
+            600, 400
+        );
+
+        log.debug("svg export finished.");
+    }
+
+
+    protected Chart getChart(
+        ChartLabels  chartLables,
+        Collection   parameters,
+        Collection   measurements,
+        Collection   dates,
+        Collection   result,
+        Locale       locale,
+        String       uuid,
+        boolean      linesVisible,
+        boolean      shapesVisible
+    ) {
+        Chart chart = null;
+
+        if (CACHE_CHART) {
+            log.info("Try to get timeseries chart from cache.");
+            chart = (Chart) getChartFromCache(uuid);
+        }
+
+        if (chart != null)
+            return chart;
+
+        log.info("Chart not in cache yet.");
+        chart = new TimeSeriesChart(
+            chartLables,
+            createStyle(),
+            parameters,
+            measurements,
+            dates,
+            result,
+            timeGapDefinitions,
+            locale,
+            linesVisible,
+            shapesVisible
+        );
+        chart.generateChart();
+
+        if (CACHE_CHART) {
+            log.info("Put chart into cache.");
+            purifyChart(chart, uuid);
+        }
+
+        return chart;
+    }
+
+    protected ChartTheme createStyle() {
+        XMLChartTheme theme = null;
+
+        Document template = Config.getChartTemplate();
+        String   name     = Config.getStringXPath(
+            template,
+            "theme/name/@value"
+        );
+
+        theme  = new XMLChartTheme(name);
+        theme.applyXMLConfiguration(template);
+
+        return theme;
+    }
+
+
+    protected String createChartTitle(Locale locale, String uuid) {
+        return getFisName(locale);
+
+    }
+
+
+    protected String createChartSubtitle(Locale locale, String uuid) {
+        return getSelectedFeatureName(uuid);
+    }
+
+
+    protected String getFisName(Locale locale) {
+        String    returnValue = "";
+        InputData input       = inputData.get("fisname");
+
+        if (input != null) {
+            String value = input.getValue();
+
+            returnValue = RessourceFactory.getInstance().getRessource(
+                locale,
+                value,
+                value
+            );
+        }
+        return returnValue;
+    }
+
+
+    protected Collection<KeyValueDescibeData> getParameters(String uuid) {
+        return this.getCollection(parameterValuesName, uuid);
+    }
+
+    protected Collection<KeyValueDescibeData> getMeasurements(String uuid) {
+        return this.getCollection(measuremenValueName, uuid);
+    }
+    protected Collection<KeyValueDescibeData> getDates(String uuid) {
+        return this.getCollection(dateValueName,uuid);
+    }
+
+    @Override
+    public void setup(Node configuration) {
+        super.setup(configuration);
+        String featureNameValue = Config.getStringXPath(configuration,
+                "value-names/value-name[@name='feature']/@value");
+        if (featureNameValue != null) {
+            this.featureValuesName = featureNameValue;
+        }
+        String parameterNameValue = Config.getStringXPath(configuration,
+                "value-names/value-name[@name='parameter']/@value");
+        if (parameterNameValue != null) {
+            this.parameterValuesName = parameterNameValue;
+        }
+        String measurementNameValue = Config.getStringXPath(configuration,
+                "value-names/value-name[@name='measurement']/@value");
+        if (measurementNameValue != null) {
+            this.measuremenValueName = measurementNameValue;
+        }
+        
+        String dateNameValue = Config.getStringXPath(configuration,
+        "value-names/value-name[@name='date']/@value");
+        if (dateNameValue != null) {
+            this.dateValueName = dateNameValue;
+        }
+        if (timeGapDefinitions == null){
+            Element gapDefinition =  (Element)Config.getNodeXPath(configuration,
+                                                                 "time-gap-definition");
+            synchronized (this.getClass()) {
+                if (gapDefinition != null){
+                    String link = gapDefinition.getAttribute("xlink:href");
+                    if (link != null ){
+                        String absolutFileName = Config.replaceConfigDir(link);
+                        gapDefinition = (Element)new ArtifactXMLUtilities().
+                                                     readConfiguration(absolutFileName);
+                    }
+                    
+                    NodeList gapDefinitions = Config.getNodeSetXPath(gapDefinition, 
+                                                                    "/time-gaps/time-gap");
+                    if (gapDefinition != null){
+                        timeGapDefinitions = new ArrayList<TimeGap>(gapDefinitions.
+                                                                    getLength());
+                        for (int i = 0; i < gapDefinitions.getLength(); i++){
+                            Element gapNode = (Element)gapDefinitions.item(i);
+                            String unit = gapNode.getAttribute("unit");
+                            int key = Integer.parseInt(gapNode.getAttribute("key"));
+                            int value = Integer.parseInt(gapNode.getAttribute("gap"));
+                            log.info("Add new Timegap: "+key+" "+value+" "+ unit);
+                            timeGapDefinitions.add(new DefaultTimeGap(unit, 
+                                                                      key, 
+                                                                      value));
+                        }
+                    }
+                    
+                }
+            }
+        }
+    }
+    
+    /**
+     * @param collectionName
+     * @return
+     */
+    protected Collection<KeyValueDescibeData> getCollection(
+                                                            String collectionName, 
+                                                            String uuid) {
+        Iterator<Object> it = this.getDescibeData(uuid).iterator();
+        while (it.hasNext()) {
+
+            Object o = it.next();
+
+            if (o instanceof NamedCollection<?>) {
+                NamedCollection<KeyValueDescibeData> nc = (NamedCollection<KeyValueDescibeData>) o;
+                if (nc.getName().equals(collectionName)) {
+                    return nc;
+                }
+            }
+        }
+        return null;
+    }
+}
+// vim:set ts=4 sw=4 si et sta sts=4 fenc=utf-8 :
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/statistics/HorizontalProfileStatistics.java	Mon Dec 07 17:03:24 2009 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/statistics/HorizontalProfileStatistics.java	Tue Dec 08 08:39:03 2009 +0000
@@ -13,7 +13,7 @@
 import com.vividsolutions.jts.io.WKTReader;
 
 import de.intevation.gnv.geobackend.base.Result;
-import de.intevation.gnv.transition.describedata.KeyValueDescibeData;
+import de.intevation.gnv.state.describedata.KeyValueDescibeData;
 import de.intevation.gnv.utils.DistanceCalculator;
 
 /**
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/statistics/Statistics.java	Mon Dec 07 17:03:24 2009 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/statistics/Statistics.java	Tue Dec 08 08:39:03 2009 +0000
@@ -18,8 +18,8 @@
 import java.util.Collection;
 
 import de.intevation.gnv.geobackend.base.Result;
+import de.intevation.gnv.state.describedata.KeyValueDescibeData;
 import de.intevation.gnv.statistics.exception.StatisticsException;
-import de.intevation.gnv.transition.describedata.KeyValueDescibeData;
 
 /**
  * The interface <code>Statistics</code> fulfills the following purposes:
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/statistics/TimeseriesStatistics.java	Mon Dec 07 17:03:24 2009 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/statistics/TimeseriesStatistics.java	Tue Dec 08 08:39:03 2009 +0000
@@ -25,8 +25,8 @@
 import org.apache.log4j.Logger;
 
 import de.intevation.gnv.geobackend.base.Result;
+import de.intevation.gnv.state.describedata.KeyValueDescibeData;
 import de.intevation.gnv.statistics.exception.StatisticsException;
-import de.intevation.gnv.transition.describedata.KeyValueDescibeData;
 
 /**
  * The class <code>TimeseriesStatistics</code> fulfills the following purposes:
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/statistics/VerticalProfileStatistics.java	Mon Dec 07 17:03:24 2009 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/statistics/VerticalProfileStatistics.java	Tue Dec 08 08:39:03 2009 +0000
@@ -7,7 +7,7 @@
 import java.util.Collection;
 
 import de.intevation.gnv.geobackend.base.Result;
-import de.intevation.gnv.transition.describedata.KeyValueDescibeData;
+import de.intevation.gnv.state.describedata.KeyValueDescibeData;
 
 /**
  * @author Tim Englich <tim.englich@intevation.de>
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/transition/CoordinateSelectionTransition.java	Mon Dec 07 17:03:24 2009 +0000
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,138 +0,0 @@
-/**
- *
- */
-package de.intevation.gnv.transition;
-
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.Iterator;
-
-import org.apache.log4j.Logger;
-
-import com.vividsolutions.jts.geom.Point;
-import com.vividsolutions.jts.io.ParseException;
-import com.vividsolutions.jts.io.WKTReader;
-
-import de.intevation.gnv.geobackend.base.Result;
-import de.intevation.gnv.transition.describedata.DefaultKeyValueDescribeData;
-import de.intevation.gnv.transition.describedata.KeyValueDescibeData;
-import de.intevation.gnv.transition.describedata.NamedArrayList;
-import de.intevation.gnv.transition.describedata.NamedCollection;
-import de.intevation.gnv.utils.InputValidator;
-import de.intevation.gnv.utils.exception.ValidationException;
-
-/**
- * @author Tim Englich <tim.englich@intevation.de>
- *
- */
-public class CoordinateSelectionTransition extends TransitionBase {
-
-    /**
-     * the logger, used to log exceptions and additonaly information
-     */
-    private static Logger log = Logger.getLogger(CoordinateSelectionTransition.class);
-    
-    /**
-     * The UID of this Class
-     */
-    private static final long serialVersionUID = 6318923553625195063L;
-
-    /**
-     * Constructor
-     */
-    public CoordinateSelectionTransition() {
-        super();
-    }
-
-    @Override
-    protected void purifyResult(Collection<Result> result, String uuid) {
-        log.debug("CoordinateSelectionTransition.purifyResult");
-        Collection<Object> describeData = this.getDescibeData(uuid);
-        if (describeData == null) {
-            describeData = new ArrayList<Object>();
-        }
-        NamedCollection<KeyValueDescibeData> keyValueDescibeData = this
-                .extractKVP(result, "FEATUREID", "SHAPE");
-        describeData.add(keyValueDescibeData);
-        this.setDescibeData(uuid, describeData);
-    }
-    
-    @Override
-    protected String prepareInputData4RegionDBQuery(String value) {
-        log.debug("CoordinateSelectionTransition.prepareInputData4RegionDBQuery");
-        double distance=0.;
-        String returnValue = null;
-        try {
-            Point center = new InputValidator().getPointValue(value);
-            String meshIDValue = super.inputData.get("meshid").getValue();
-            int segments = 97;
-            int meshid = new Integer(meshIDValue);
-            if (meshid == 3 || meshid == 5){ // TODO nicht hier festbrennen.
-                distance = 0.15; //nord-ostsee 6nm // 97 Stützpunkte
-            }else if (meshid == 1 || meshid == 4){
-                distance = 0.03; //Kuestenmodell 1 nm
-            }else if (meshid == 2 || meshid == 321){
-                distance = 0.3; //SST Karten ca 20km
-            }else if (meshid == 641){
-                distance = 0.3; //Eisdaten Klima
-            }
-            returnValue = center.buffer(distance,segments).toText();
-        } catch (NumberFormatException e) {
-            log.error(e,e);
-        } catch (ValidationException e) {
-            log.error(e,e);
-        }
-        return returnValue;
-        
-    }
-    
-    /**
-     * @see de.intevation.gnv.transition.TransitionBase#extractKVP(java.util.Collection, java.lang.String, java.lang.String)
-     */
-    @Override
-    protected NamedCollection<KeyValueDescibeData> extractKVP(
-            Collection<Result> result,
-            String keyid,
-            String valueid) {
-        Iterator<Result> rit = result.iterator();
-        NamedCollection<KeyValueDescibeData> keyValueDescibeData = new NamedArrayList<KeyValueDescibeData>(
-        this.dataName, result.size());
-        keyValueDescibeData.setMultiSelect(this.dataMultiSelect);
-        String prevKey = null;
-        while (rit.hasNext()) {
-            Result resultValue = rit.next();
-            String key = resultValue.getString(keyid);
-            if(prevKey == null || !prevKey.equals(key)){ // müssen wir so machen, da die sde kein select distinct auf layern zulässt.
-                String geomString = this.convert2DisplayCoordinate(resultValue.getString(valueid));
-                String value = geomString;
-                if (resultValue.getResultDescriptor().getColumnIndex("VALUE") > 0){
-                    value = resultValue.getString("VALUE") + " - "+value;
-                }
-                
-                
-                keyValueDescibeData.add(new DefaultKeyValueDescribeData(key,value ));
-            }
-            prevKey = key;
-        }
-        return keyValueDescibeData;
-    }
-    
-    protected String convert2DisplayCoordinate(String wkt){
-        String formattedCoordinate = null;
-        try {
-            Point p = (Point)new WKTReader().read(wkt);
-            double lat = p.getY();
-            double lon =p.getX();
-            String nord="N";
-            String ost="E";
-            if (lat <0 ){nord="S"; lat=-lat;}
-            if (lon <0 ){ost="W"; lon=-lon;}
-            formattedCoordinate =  String.format("%1$02d°%2$1S %3$05.2f' %4$03d°%5$1S %6$05.2f'",
-                                  (int)lat, nord,60.*(lat-((int)lat)),(int)lon,ost,60.*(lon-((int)lon)));
-        } catch (ParseException e) {
-            log.error(e,e);
-        }
-        
-        return formattedCoordinate;
-    }
-}
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/transition/DefaultInputData.java	Mon Dec 07 17:03:24 2009 +0000
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,56 +0,0 @@
-/**
- *
- */
-package de.intevation.gnv.transition;
-
-/**
- * @author Tim Englich <tim.englich@intevation.de>
- * 
- */
-public class DefaultInputData implements InputData {
-
-    /**
-     *
-     */
-    private static final long serialVersionUID = 4308041648698108066L;
-    private String name = null;
-    private String value = null;
-
-    /**
-     * Constructor
-     */
-    public DefaultInputData(String name, String value) {
-        this.name = name;
-        this.value = value;
-    }
-
-    /**
-     * @see de.intevation.gnv.transition.InputData#getName()
-     */
-    public String getName() {
-        return this.name;
-    }
-
-    /**
-     * @see de.intevation.gnv.transition.InputData#getValue()
-     */
-    public String getValue() {
-        return this.value;
-    }
-
-    /**
-     * @see java.lang.Object#toString()
-     */
-    @Override
-    public String toString() {
-        return this.name + "==> " + this.value;
-    }
-
-    /**
-     * @see de.intevation.gnv.transition.InputData#concartValue(java.lang.String)
-     */
-    public void concartValue(String value) {
-        this.value = this.value + " , " + value;
-    }
-
-}
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/transition/DefaultInputValue.java	Mon Dec 07 17:03:24 2009 +0000
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,78 +0,0 @@
-/**
- *
- */
-package de.intevation.gnv.transition;
-
-/**
- * @author Tim Englich <tim.englich@intevation.de>
- * 
- */
-public class DefaultInputValue implements InputValue {
-
-    /**
-     * The UID of this Class.
-     */
-    private static final long serialVersionUID = -8518824299166180986L;
-    private String name = null;
-    private String type = null;
-    private boolean multiselect = false;
-    private int usedInQueries = 1;
-    private String defaultValue = "N/N";
-
-    public DefaultInputValue(String name, String type, String defaultValue,
-                             boolean multiselect) {
-        this(name, type, multiselect, 1);
-        this.defaultValue = defaultValue;
-
-    }
-
-    /**
-     * Constructor
-     */
-    public DefaultInputValue(String name, String type, boolean multiselect,
-                             int usedInQueries) {
-        this.name = name;
-        this.type = type;
-        this.multiselect = multiselect;
-        this.usedInQueries = usedInQueries;
-    }
-
-    /**
-     * @see de.intevation.gnv.transition.InputValue#getName()
-     */
-    public String getName() {
-        return this.name;
-    }
-
-    /**
-     * @see de.intevation.gnv.transition.InputValue#getType()
-     */
-    public String getType() {
-        return this.type;
-    }
-
-    /**
-     * @see java.lang.Object#toString()
-     */
-    @Override
-    public String toString() {
-        return "InputValue " + this.name + " ==> " + this.type
-               + "==> multiselect: " + this.multiselect;
-    }
-
-    /**
-     * @see de.intevation.gnv.transition.InputValue#isMultiselect()
-     */
-    public boolean isMultiselect() {
-        return this.multiselect;
-    }
-
-    public int usedInQueries() {
-        return this.usedInQueries;
-    }
-
-    public String getDefaultValue() {
-        return this.defaultValue;
-    }
-
-}
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/transition/DefaultOutputMode.java	Mon Dec 07 17:03:24 2009 +0000
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,76 +0,0 @@
-/**
- *
- */
-package de.intevation.gnv.transition;
-
-import java.util.Collection;
-
-/**
- * @author Tim Englich <tim.englich@intevation.de>
- * 
- */
-public class DefaultOutputMode implements OutputMode {
-
-    /**
-     * The UID of this Class.
-     */
-    private static final long serialVersionUID = -6459085460904827056L;
-    private String name = null;
-    private String description = null;
-    private String mimeType = null;
-    private Collection<InputValue> inputParameters = null;
-
-    /**
-     * Constructor
-     * 
-     * @param name
-     * @param description
-     * @param mimeType
-     */
-    public DefaultOutputMode(String name, String description, String mimeType,
-                             Collection<InputValue> inputParameters) {
-        super();
-        this.name = name;
-        this.description = description;
-        this.mimeType = mimeType;
-        this.inputParameters = inputParameters;
-    }
-
-    /**
-     * @see de.intevation.gnv.transition.OutputMode#getDescription()
-     */
-    public String getDescription() {
-        return this.description;
-    }
-
-    /**
-     * @see de.intevation.gnv.transition.OutputMode#getMimeType()
-     */
-    public String getMimeType() {
-        return this.mimeType;
-    }
-
-    /**
-     * @see de.intevation.gnv.transition.OutputMode#getName()
-     */
-    public String getName() {
-        return this.name;
-    }
-
-    /**
-     * @see java.lang.Object#toString()
-     */
-    @Override
-    public String toString() {
-        return "Name: " + this.name + " ; Description: " + this.description
-               + " ; Mime-Type: " + this.mimeType;
-    }
-
-    /**
-     * @see de.intevation.gnv.transition.OutputMode#getInputParameters()
-     */
-    public Collection<InputValue> getInputParameters() {
-        return this.inputParameters;
-    }
-
-}
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/transition/DefaultTransition.java	Mon Dec 07 17:03:24 2009 +0000
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,23 +0,0 @@
-/**
- *
- */
-package de.intevation.gnv.transition;
-
-/**
- * @author Tim Englich <tim.englich@intevation.de>
- * 
- */
-public class DefaultTransition extends TransitionBase {
-
-    /**
-     * The UID of this Class
-     */
-    private static final long serialVersionUID = 8934030362091576766L;
-
-    /**
-     * Constructor
-     */
-    public DefaultTransition() {
-    }
-
-}
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/transition/InputData.java	Mon Dec 07 17:03:24 2009 +0000
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,19 +0,0 @@
-/**
- *
- */
-package de.intevation.gnv.transition;
-
-import java.io.Serializable;
-
-/**
- * @author Tim Englich <tim.englich@intevation.de>
- * 
- */
-public interface InputData extends Serializable {
-
-    public String getName();
-
-    public String getValue();
-
-    public void concartValue(String value);
-}
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/transition/InputValue.java	Mon Dec 07 17:03:24 2009 +0000
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,24 +0,0 @@
-/**
- *
- */
-package de.intevation.gnv.transition;
-
-import java.io.Serializable;
-
-/**
- * @author Tim Englich <tim.englich@intevation.de>
- * 
- */
-public interface InputValue extends Serializable {
-
-    public String getName();
-
-    public String getType();
-
-    public String getDefaultValue();
-
-    public boolean isMultiselect();
-
-    public int usedInQueries();
-
-}
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/transition/MinMaxTransition.java	Mon Dec 07 17:03:24 2009 +0000
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,62 +0,0 @@
-/**
- *
- */
-package de.intevation.gnv.transition;
-
-import java.util.ArrayList;
-import java.util.Collection;
-
-import org.apache.log4j.Logger;
-
-import de.intevation.gnv.geobackend.base.Result;
-import de.intevation.gnv.transition.describedata.DefaultMinMaxDescribeData;
-import de.intevation.gnv.transition.describedata.DescribeData;
-
-/**
- * @author Tim Englich <tim.englich@intevation.de>
- * 
- */
-public class MinMaxTransition extends TransitionBase {
-
-    /**
-     * The UID of this Class
-     */
-    private static final long serialVersionUID = -3525903792105187408L;
-    /**
-     * the logger, used to log exceptions and additonaly information
-     */
-    private static Logger log = Logger.getLogger(MinMaxTransition.class);
-
-    /**
-     * Constructor
-     */
-    public MinMaxTransition() {
-        super();
-    }
-
-    /**
-     * @see de.intevation.gnv.transition.TransitionBase#purifyResult(java.util.Collection,
-     *      java.lang.String)
-     */
-    @Override
-    protected void purifyResult(Collection<Result> result, String uuid) {
-        log.debug("MinMaxTransition.purifyResult");
-        Collection<Object> describeData = this.getDescibeData(uuid);
-        if (describeData == null) {
-            describeData = new ArrayList<Object>();
-        }
-        if (result != null && result.size() == 1) {
-            
-            Result value = result.iterator().next();
-            DescribeData values = new DefaultMinMaxDescribeData(this.dataName, 
-                                                               value.getObject("MIN"), 
-                                                               value.getObject("MAX"));
-            log.debug(values.toString());
-            describeData.add(values);
-        } else {
-            log.warn("Result cannot be handled as MinMax Resultset");
-        }
-        this.setDescibeData(uuid, describeData);
-    }
-
-}
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/transition/OutputMode.java	Mon Dec 07 17:03:24 2009 +0000
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,22 +0,0 @@
-/**
- *
- */
-package de.intevation.gnv.transition;
-
-import java.io.Serializable;
-import java.util.Collection;
-
-/**
- * @author Tim Englich <tim.englich@intevation.de>
- * 
- */
-public interface OutputMode extends Serializable {
-
-    public String getName();
-
-    public String getDescription();
-
-    public String getMimeType();
-
-    public Collection<InputValue> getInputParameters();
-}
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/transition/OutputTransition.java	Mon Dec 07 17:03:24 2009 +0000
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,38 +0,0 @@
-/**
- *
- */
-package de.intevation.gnv.transition;
-
-import java.io.OutputStream;
-import java.util.Collection;
-
-import org.w3c.dom.Document;
-
-import de.intevation.artifacts.CallMeta;
-import de.intevation.gnv.transition.exception.TransitionException;
-
-/**
- * @author Tim Englich <tim.englich@intevation.de>
- * 
- */
-public interface OutputTransition extends Transition {
-
-    /**
-     * Returns the Rendered Result of an Transition.
-     * 
-     * @param outputMode
-     *            The Mode that should be produces (Chart, Map, ...)
-     * @return The Bytecode of the Result
-     * @throws TransitionException
-     */
-    public void out(Document format, Collection<InputData> inputData,
-                    OutputStream outputStream, String uuid, CallMeta callMeta)
-                                                                              throws TransitionException;
-
-    /**
-     * Delivers the provided OutputModes of an Transition
-     * 
-     * @return the provided OutputModes of an Transition
-     */
-    public Collection<OutputMode> getOutputModes();
-}
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/transition/OutputTransitionBase.java	Mon Dec 07 17:03:24 2009 +0000
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,273 +0,0 @@
-/**
- *
- */
-package de.intevation.gnv.transition;
-
-import java.io.OutputStream;
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.Locale;
-
-
-import org.apache.log4j.Logger;
-import org.w3c.dom.Document;
-import org.w3c.dom.Element;
-import org.w3c.dom.Node;
-import org.w3c.dom.NodeList;
-
-import de.intevation.artifactdatabase.Config;
-import de.intevation.artifacts.CallMeta;
-import de.intevation.gnv.artifacts.cache.CacheFactory;
-import de.intevation.gnv.artifacts.ressource.RessourceFactory;
-import de.intevation.gnv.geobackend.base.Result;
-import de.intevation.gnv.geobackend.base.query.QueryExecutor;
-import de.intevation.gnv.geobackend.base.query.QueryExecutorFactory;
-import de.intevation.gnv.geobackend.base.query.exception.QueryException;
-import de.intevation.gnv.transition.exception.TransitionException;
-
-/**
- * @author Tim Englich <tim.englich@intevation.de>
- * 
- */
-public abstract class OutputTransitionBase extends TransitionBase implements
-                                                                 OutputTransition {
-
-    /**
-     * The UID of this Class
-     */
-    private static final long serialVersionUID = -1718732895737303823L;
-
-    /**
-     * the logger, used to log exceptions and additonaly information
-     */
-    private static Logger log = Logger.getLogger(OutputTransitionBase.class);
-
-    /**
-     * The different Outputmodes which are provided by an OutputTransition
-     */
-    protected Collection<OutputMode> outputModes = null;
-    
-    protected String queryODVID = null;
-
-    /**
-     * Constructor
-     */
-    public OutputTransitionBase() {
-        super();
-    }
-
-    /**
-     * @see de.intevation.gnv.transition.OutputTransition#getOutputModes()
-     */
-    public Collection<OutputMode> getOutputModes() {
-        log.debug("OutputTransitionBase.getOutputModes");
-        return this.outputModes;
-    }
-
-    /**
-     * @see de.intevation.gnv.transition.TransitionBase#setup(org.w3c.dom.Node)
-     */
-    @Override
-    public void setup(Node configuration) {
-        log.debug("OutputTransitionBase.setup");
-        super.setup(configuration);
-        
-        this.queryODVID = Config.getStringXPath(configuration,"queryID-odv");
-        
-        NodeList outputModeList = Config.getNodeSetXPath(configuration,
-                "outputsModes/outputsMode");
-        if (outputModeList != null) {
-            log.debug(outputModeList.getLength() + " were found.");
-            this.outputModes = new ArrayList<OutputMode>(outputModeList
-                    .getLength());
-            for (int i = 0; i < outputModeList.getLength(); i++) {
-                Element currentNode = (Element)outputModeList.item(i);
-                String name = currentNode.getAttribute("name");
-                String description =currentNode.getAttribute("description");
-                String mimeType = currentNode.getAttribute("mime-type");
-                NodeList inputValuesList = Config.getNodeSetXPath(currentNode,
-                        "parameters/inputvalue");
-                Collection<InputValue> inputParameters = null;
-                if (inputValuesList != null) {
-                    inputParameters = new ArrayList<InputValue>(inputValuesList
-                            .getLength());
-                    for (int j = 0; j < inputValuesList.getLength(); j++) {
-                        Element currentInputValuesNode = (Element)inputValuesList.item(j);
-                        String inputValueName = currentInputValuesNode.getAttribute("name");
-                        String inputValueType = currentInputValuesNode.getAttribute("type");
-                        String defaultValue =currentInputValuesNode.getAttribute("value");
-                        boolean isMultiselect = false;
-                        InputValue inputValue = new DefaultInputValue(
-                                inputValueName, inputValueType, defaultValue,
-                                isMultiselect);
-                        inputParameters.add(inputValue);
-                    }
-                }
-
-                OutputMode outputMode = new DefaultOutputMode(name,
-                        description, mimeType, inputParameters);
-                log.debug(outputMode.toString());
-                this.outputModes.add(outputMode);
-
-            }
-        }
-    }
-
-    /**
-     * @see de.intevation.gnv.transition.TransitionBase#advance()
-     */
-    @Override
-    public void advance(String uuid, CallMeta callMeta)
-                                                       throws TransitionException {
-    }
-
-    @Override
-    public void initialize(String uuid, CallMeta callMeta)
-                                                          throws TransitionException {
-    }
-
-    public void out(Document format, Collection<InputData> inputData,
-                    OutputStream outputStream, String uuid, CallMeta callMeta)
-                                                                              throws TransitionException {
-    }
-
-    /**
-     * @see de.intevation.gnv.transition.OutputTransition#out(java.lang.String,
-     *      java.util.Collection, java.io.OutputStream)
-     */
-    public void out(String outputMode, Collection<InputData> inputData,
-                    OutputStream outputStream) throws TransitionException {
-    }
-
-    /**
-     * @return
-     */
-    protected Collection<Result> getChartResult(String uuid) {
-        log.debug("OutputTransitionBase.getChartResult");
-        Collection<Result> result = null;
-        if (CacheFactory.getInstance().isInitialized()) {
-            String key = uuid + super.getID();
-            log.debug("Hash for Queryelements: " + key);
-            net.sf.ehcache.Element value = CacheFactory.getInstance().getCache().get(key);
-            if (value != null) {
-                result = (Collection<Result>) (value.getObjectValue());
-            }else{
-                result = this.getData(this.queryID);
-                if (CacheFactory.getInstance().isInitialized()) {
-                    CacheFactory.getInstance().getCache().put(new net.sf.ehcache.Element(key, result));
-                }
-                
-            }
-        }
-        return result;
-    }
-
-    protected Object getChartFromCache(String uuid) {
-        log.debug("Fetch chart [" + uuid + "] from cache");
-        CacheFactory cacheFactory = CacheFactory.getInstance();
-        if (cacheFactory.isInitialized()) {
-            String key = "chart_" + uuid + super.getID();
-            net.sf.ehcache.Element object = cacheFactory.getCache().get(key);
-
-            if (object != null) {
-                return object.getObjectValue();
-            }
-        }
-        return null;
-    }
-    
-    protected Collection<Result> getODVResult(String uuid) {
-        log.debug("OutputTransitionBase.getODVResult");
-        // TODO add Caching? I think it's not nessessary
-        Collection<Result> returnValue = null;
-        if (this.queryODVID != null){
-            returnValue = this.getData(this.queryODVID);
-        }else{
-            log.warn("No Query for ODV Data is defined.");
-        }
-        return returnValue;
-    }
-
-    /**
-     * @param returnValue
-     * @return
-     */
-    private Collection<Result> getData(String queryID) {
-        log.debug("OutputTransitionBase.getData");
-        Collection<Result> returnValue = null;
-        try {
-            String[] filterValues = this.generateFilterValuesFromInputData();
-            try {
-                QueryExecutor queryExecutor = QueryExecutorFactory
-                                              .getInstance()
-                                              .getQueryExecutor();
-                returnValue  = queryExecutor.executeQuery(queryID,filterValues);
-            } catch (RuntimeException e) {
-                log.error(e, e);
-            }
-        } catch (QueryException e) {
-            log.error(e, e);
-        }
-        return returnValue;
-    }
-    
-    protected void removeChartResult(String uuid) {
-        log.debug("OutputTransitionBase.getChartResult");
-        if (CacheFactory.getInstance().isInitialized()) {
-            String key = uuid + super.getID();
-            log.debug("Hash for Queryelements: " + key);
-            net.sf.ehcache.Element value = CacheFactory.getInstance().getCache().get(key);
-            if (value != null) {
-                CacheFactory.getInstance().getCache().remove(key);
-            }
-        }
-    }
-
-    protected void removeChart(String uuid) {
-        log.debug("OutputTransitionBase.removeChart from cache");
-
-        CacheFactory cacheFactory = CacheFactory.getInstance();
-        if (cacheFactory.isInitialized()) {
-            String key = "chart_" + uuid + super.getID();
-            net.sf.ehcache.Element object = cacheFactory.getCache().get(key);
-            if (object != null)
-                cacheFactory.getCache().remove(key);
-        }
-    }
-
-    protected void purifyChart(Object chart, String uuid) {
-        log.debug("Prufify chart [" + uuid + "]");
-        CacheFactory cacheFactory = CacheFactory.getInstance();
-        if (cacheFactory.isInitialized()) {
-            String key = "chart_" + uuid + getID();
-            cacheFactory.getCache().put(new net.sf.ehcache.Element(key, chart));
-        }
-    }
-
-    /**
-     * @see de.intevation.gnv.transition.TransitionBase#putInputData(java.util.Collection, java.lang.String)
-     */
-    @Override
-    public void putInputData(Collection<InputData> inputData, 
-                             String uuid)
-                                         throws TransitionException {
-        log.debug("OutputTransitionBase.putInputData");
-        this.removeChartResult(uuid);
-        this.removeChart(uuid);
-        super.putInputData(inputData, uuid);
-    }
-
-    public void out(String outputMode, Collection<InputData> inputData,
-                    OutputStream outputStream, String uuid, CallMeta callMeta)
-                                                                              throws TransitionException {
-    }
-
-
-    protected String getMessage(Locale locale, String key, String value) {
-        return RessourceFactory.getInstance().getRessource(
-            locale,
-            key,
-            value
-        );
-    }
-}
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/transition/SingleInputTransition.java	Mon Dec 07 17:03:24 2009 +0000
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,59 +0,0 @@
-/**
- *
- */
-package de.intevation.gnv.transition;
-
-import java.util.ArrayList;
-import java.util.Collection;
-
-import org.apache.log4j.Logger;
-
-import de.intevation.gnv.geobackend.base.Result;
-import de.intevation.gnv.transition.describedata.DefaultSingleValueDescribeData;
-
-/**
- * @author Tim Englich <tim.englich@intevation.de>
- * 
- */
-public class SingleInputTransition extends TransitionBase {
-
-    /**
-     * the logger, used to log exceptions and additonaly information
-     */
-    private static Logger log = Logger.getLogger(SingleInputTransition.class);
-
-    /**
-     *
-     */
-    private static final long serialVersionUID = -6169497306324917318L;
-
-    /**
-     * Constructor
-     */
-    public SingleInputTransition() {
-    }
-
-    /**
-     * @see de.intevation.gnv.transition.TransitionBase#purifyResult(java.util.Collection,
-     *      java.lang.String)
-     */
-    @Override
-    protected void purifyResult(Collection<Result> result, String uuid) {
-        log.debug("SingleInputTransition.purifyResult");
-        Collection<Object> describeData = this.getDescibeData(uuid);
-        if (describeData == null) {
-            describeData = new ArrayList<Object>();
-        }
-        String value = null;
-        if (result != null && result.size() == 1) {
-            Result tmpItem = result.iterator().next();
-            value = tmpItem.getObject("MAX").toString();
-        } else {
-            value = "";
-        }
-
-        describeData.add(new DefaultSingleValueDescribeData(this.dataName,value));
-        this.setDescibeData(uuid, describeData);
-    }
-
-}
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/transition/Transition.java	Mon Dec 07 17:03:24 2009 +0000
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,51 +0,0 @@
-/**
- *
- */
-package de.intevation.gnv.transition;
-
-import java.io.Serializable;
-import java.util.Collection;
-
-import org.w3c.dom.Document;
-import org.w3c.dom.Node;
-
-import de.intevation.artifacts.CallMeta;
-import de.intevation.gnv.transition.exception.TransitionException;
-
-/**
- * @author Tim Englich <tim.englich@intevation.de>
- * 
- */
-public interface Transition extends Serializable {
-
-    public void setup(Node configuration);
-
-    public Collection<String> reachableTransitions();
-
-    public boolean isTransitionReachable(String transitionID);
-
-    public String getID();
-
-    public String getDescription();
-
-    public void describe(Document document, Node rootNode, 
-                         CallMeta callMeta, String uuid);
-
-    public void setParent(Transition transition);
-
-    public Transition getParent();
-
-    public Collection<InputValue> getRequiredInputValues();
-
-    public void putInputData(Collection<InputData> inputData, 
-                             String uuid)throws TransitionException;
-
-    public Collection<InputData> getInputData() throws TransitionException;
-
-    public void advance(String uuid, CallMeta callMeta)
-                                                    throws TransitionException;
-    public void initialize(String uuid, CallMeta callMeta)
-                                                    throws TransitionException;
-    
-
-}
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/transition/TransitionBase.java	Mon Dec 07 17:03:24 2009 +0000
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,789 +0,0 @@
-/**
- *
- */
-package de.intevation.gnv.transition;
-
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.Date;
-import java.util.GregorianCalendar;
-import java.util.HashMap;
-import java.util.HashSet;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Map;
-import java.util.Set;
-
-import org.apache.log4j.Logger;
-import org.w3c.dom.Document;
-import org.w3c.dom.Element;
-import org.w3c.dom.Node;
-import org.w3c.dom.NodeList;
-
-import de.intevation.artifactdatabase.Config;
-import de.intevation.artifacts.CallMeta;
-import de.intevation.gnv.artifacts.GNVArtifactBase;
-import de.intevation.gnv.artifacts.cache.CacheFactory;
-import de.intevation.gnv.artifacts.ressource.RessourceFactory;
-import de.intevation.gnv.geobackend.base.Result;
-import de.intevation.gnv.geobackend.base.query.QueryExecutor;
-import de.intevation.gnv.geobackend.base.query.QueryExecutorFactory;
-import de.intevation.gnv.geobackend.base.query.exception.QueryException;
-import de.intevation.gnv.geobackend.util.DateUtils;
-import de.intevation.gnv.transition.describedata.DefaultKeyValueDescribeData;
-import de.intevation.gnv.transition.describedata.KeyValueDescibeData;
-import de.intevation.gnv.transition.describedata.MinMaxDescribeData;
-import de.intevation.gnv.transition.describedata.NamedArrayList;
-import de.intevation.gnv.transition.describedata.NamedCollection;
-import de.intevation.gnv.transition.describedata.SingleValueDescribeData;
-import de.intevation.gnv.transition.exception.TransitionException;
-import de.intevation.gnv.utils.ArtifactXMLUtilities;
-import de.intevation.gnv.utils.InputValidator;
-
-/**
- * @author Tim Englich <tim.englich@intevation.de>
- * 
- */
-public abstract class TransitionBase implements Transition {
-
-    
-
-    /**
-     * The UID of this Class
-     */
-    private static final long serialVersionUID = 2411169179001645426L;
-
-    /**
-     * the logger, used to log exceptions and additonaly information
-     */
-    private static Logger log = Logger.getLogger(GNVArtifactBase.class);
-    
-    private final static String MINVALUEFIELDNAME = "minvalue";
-    private final static String MAXVALUEFIELDNAME = "maxvalue";
-    
-    private final static String NODATASELECTIONKEY = "n/n";
-    
-    private final static String DESCRIBEDATAKEY = "_DESCRIBEDATA";
-
-    private String id = null;
-
-    private String description = null;
-
-    protected String dataName = null;
-
-    protected boolean dataMultiSelect = false;
-    
-    protected boolean dataNoSelect = false;
-
-    protected String queryID = null;
-
-    private Collection<String> reachableTransitions = null;
-
-    protected Collection<String> inputValueNames = null;
-
-    private Map<String, InputValue> inputValues = null;
-
-    private Transition parent = null;
-
-    protected Map<String, InputData> inputData = null;
-    
-
-    /**
-     * Constructor
-     */
-    public TransitionBase() {
-        super();
-    }
-
-    /**
-     * @see de.intevation.gnv.transition.Transition#getID()
-     */
-    public String getID() {
-        return this.id;
-    }
-
-    /**
-     * @see de.intevation.gnv.transition.Transition#getDescription()
-     */
-    public String getDescription() {
-        return this.description;
-    }
-
-    /**
-     * @see de.intevation.gnv.transition.Transition#reachableTransitions()
-     */
-    public Collection<String> reachableTransitions() {
-        
-        if (this.couldAlternativeTransitionUsed()){
-            Iterator<String> it = this.reachableTransitions.iterator();
-            String transValue = null;
-            while (it.hasNext()){
-                transValue = it.next();
-            }
-            Collection<String> returnValue = new ArrayList<String>(1);
-            returnValue.add(transValue);
-            return returnValue;
-        }else{
-            return this.reachableTransitions;
-        }
-        
-    }
-
-    /**
-     * @return
-     */
-    private boolean couldAlternativeTransitionUsed() {
-     // TODO das muss hier noch etwas freier gestaltet werden.
-        String key = this.dataName;
-        boolean returnValue= /*this.alternativeTransition != null &&*/ 
-                            this.inputData != null &&
-                            this.inputData.containsKey(key) && 
-                            this.inputData.get(key).getValue().
-                                                    equals(NODATASELECTIONKEY);
-        return returnValue;
-    }
-
-    /**
-     * @see de.intevation.gnv.transition.Transition#getRequiredInputValues()
-     */
-    public Collection<InputValue> getRequiredInputValues() {
-        return this.inputValues.values();
-    }
-
-    /**
-     * @see de.intevation.gnv.transition.Transition#setup(org.w3c.dom.Node)
-     */
-    public void setup(Node configuration) {
-        log.debug("TransitionBase.setup");
-        this.id = ((Element)configuration).getAttribute("id");
-        this.description = ((Element)configuration).getAttribute("description");
-
-        log.info("Transition-ID = " + this.id);
-        NodeList nodes = Config.getNodeSetXPath(configuration,
-                "reachableTransitions/transition");
-        this.reachableTransitions = new ArrayList<String>(nodes.getLength());
-        for (int i = 0; i < nodes.getLength(); i++) {
-            String reachableTransition = nodes.item(i).getTextContent();
-            log.info("ReachableTransition ==> " + reachableTransition);
-            this.reachableTransitions.add(reachableTransition);
-
-        }
-        
-        NodeList inputValuesNodes = Config.getNodeSetXPath(configuration,
-                "inputvalues/inputvalue");
-        this.inputValues = new HashMap<String, InputValue>(inputValuesNodes
-                .getLength());
-        this.inputValueNames = new ArrayList<String>(inputValuesNodes
-                .getLength());
-        for (int i = 0; i < inputValuesNodes.getLength(); i++) {
-            Element inputValueNode = (Element)inputValuesNodes.item(i);
-            String usedinQueryValue = inputValueNode.getAttribute("usedinquery");
-            int usedinQuery = 1;
-            if (usedinQueryValue != null) {
-                try {
-                    usedinQuery = Integer.parseInt(usedinQueryValue);
-                } catch (NumberFormatException e) {
-                    log
-                            .warn("Used in Query Value cannot be transformed into a Number");
-                }
-            }
-            InputValue inputValue = new DefaultInputValue(inputValueNode.getAttribute("name"), 
-                                                          inputValueNode.getAttribute("type"), 
-                                                          Boolean.parseBoolean(inputValueNode.
-                                                          getAttribute("multiselect")), usedinQuery);
-            log.debug(inputValue.toString());
-            this.inputValues.put(inputValue.getName(), inputValue);
-            this.inputValueNames.add(inputValue.getName());
-        }
-
-        this.queryID = Config.getStringXPath(configuration, "queryID");
-        log.info("QueryID ==> " + this.queryID);
-
-        this.dataName = Config.getStringXPath(configuration, "dataname");
-
-        String dataMultiSelectValue = Config.getStringXPath(configuration,
-                                                           "data-multiselect");
-        if (dataMultiSelectValue != null) {
-            this.dataMultiSelect = Boolean.parseBoolean(dataMultiSelectValue);
-        }
-        
-        String dataNoSelectValue =Config.getStringXPath(configuration,
-                                                        "data-noselect");
-        if (dataNoSelectValue != null) {
-            this. dataNoSelect = Boolean.parseBoolean(dataNoSelectValue);
-        }
-        
-    }
-
-    /**
-     * @see de.intevation.gnv.transition.Transition#getParent()
-     */
-    public Transition getParent() {
-        return this.parent;
-    }
-
-    /**
-     * @see de.intevation.gnv.transition.Transition#setParent(de.intevation.gnv.transition.Transition)
-     */
-    public void setParent(Transition transition) {
-        this.parent = transition;
-    }
-
-    /**
-     * @see de.intevation.gnv.transition.Transition#putInputData(java.util.Collection)
-     */
-    public void putInputData(Collection<InputData> inputData, String uuid)
-                                                                          throws TransitionException {
-        log.debug("TransitionBase.putInputData");
-        if (inputData != null) {
-            Iterator<InputData> it = inputData.iterator();
-            InputValidator iv = new InputValidator();
-            while (it.hasNext()) {
-                InputData tmpItem = it.next();
-                InputValue inputValue = this.inputValues.get(tmpItem.getName());
-                if (inputValue != null) {
-                    if (this.inputData == null) {
-                        this.inputData = new HashMap<String, InputData>(
-                                inputData.size());
-                    }
-                    
-                    boolean valid = iv.isInputValid(tmpItem.getValue(),
-                            inputValue.getType());
-                    if (valid) {
-                        if (tmpItem.getName().equals(MINVALUEFIELDNAME)){
-                            String minValue = tmpItem.getValue();
-                            String maxValue = this.getInputValue4ID(inputData, MAXVALUEFIELDNAME);
-                            valid = iv.isInputValid(maxValue,inputValue.getType());
-                            if (!valid){
-                                String errMsg = "Wrong input for " + tmpItem.getValue()
-                                                + " is not an " + inputValue.getType()
-                                                + " Value.";
-                                log.warn(errMsg);
-                                throw new TransitionException(errMsg);
-                            }
-                            
-                            valid = iv.isInputValid(minValue, 
-                                    maxValue,
-                                    inputValue.getType());
-                            if (!valid){
-                                String errMsg = "MaxValue-Input is less than MinValue-Input ";
-                                log.warn(errMsg);
-                                throw new TransitionException(errMsg);
-                            }
-                        }else if (tmpItem.getName().equals(MAXVALUEFIELDNAME)){
-                            String minValue = this.getInputValue4ID(inputData, MINVALUEFIELDNAME);
-                            String maxValue = tmpItem.getValue();
-                            valid = iv.isInputValid(minValue,inputValue.getType());
-                            if (!valid){
-                                String errMsg = "Wrong input for " + tmpItem.getValue()
-                                                + " is not an " + inputValue.getType()
-                                                + " Value.";
-                                log.warn(errMsg);
-                                throw new TransitionException(errMsg);
-                            }
-                            
-                            valid = iv.isInputValid(minValue, 
-                                                    maxValue,
-                                                    inputValue.getType());
-                            if (!valid){
-                                String errMsg = "MaxValue-Input is less than MinValue-Input ";
-                                log.warn(errMsg);
-                                throw new TransitionException(errMsg);
-                            }
-                        }
-                        this.setSelection(tmpItem, uuid);
-                        this.inputData.put(tmpItem.getName(), tmpItem);
-                    } else {
-                        String errMsg = "Wrong input for " + tmpItem.getValue()
-                                        + " is not an " + inputValue.getType()
-                                        + " Value.";
-                        log.warn(errMsg);
-                        throw new TransitionException(errMsg);
-                    }
-
-                } else {
-                    String errMsg = "No Inputvalue given for Inputdata "
-                                    + tmpItem.getName();
-                    log.warn(errMsg + "Value will be ignored");
-
-                }
-            }
-        } else {
-            log.warn("No Inputdata given");
-        }
-    }
-    
-    private String getInputValue4ID(Collection<InputData> inputData, String inputName){
-        Iterator<InputData> it = inputData.iterator();
-        while (it.hasNext()) {
-            InputData tmpItem = it.next();
-            if (tmpItem.getName().equals(inputName)){
-                return tmpItem.getValue();
-            }
-        }
-        return null;
-    }
-
-    private void setSelection(InputData inputData, String uuid) {
-        log.debug("TransitionBase.setSelection");
-
-        Object o = this.getDescribeData(inputData.getName(),uuid);
-        if (o != null) {
-            if (o instanceof Collection<?>) {
-                Collection<KeyValueDescibeData> values = (Collection<KeyValueDescibeData>) o;
-
-                String value = inputData.getValue();
-                String[] selectedValues = value.split(",");
-                Set<String> selectedItems = new HashSet<String>(
-                        selectedValues.length);
-                for (int i = 0; i < selectedValues.length; i++) {
-                    selectedItems.add(selectedValues[i].trim());
-                }
-                // Selektion umsetzen
-                Iterator<KeyValueDescibeData> it = values.iterator();
-                while (it.hasNext()) {
-                    KeyValueDescibeData data = it.next();
-                    String key = "" + data.getKey();
-                    boolean selected = selectedItems.contains(key);
-                    data.setSelected(selected);
-                }
-            } else if (o instanceof MinMaxDescribeData) {
-                MinMaxDescribeData data = (MinMaxDescribeData) o;
-                if (inputData.getName().equals(MINVALUEFIELDNAME)) {
-                    data.setMinValue(inputData.getValue());
-                }
-                if (inputData.getName().equals(MAXVALUEFIELDNAME)) {
-                    data.setMaxValue(inputData.getValue());
-                }
-            } else if (o instanceof SingleValueDescribeData) {
-                ((SingleValueDescribeData)o).setValue(inputData.getValue());
-            }
-        }
-    }
-
-    private Object getDescribeData(String name, String uuid) {
-        log.debug("TransitionBase.getDescribeData");
-        Collection<Object> descibeData = this.getDescibeData(uuid);
-        if (descibeData != null) {
-            Iterator<Object> it = descibeData.iterator();
-            while (it.hasNext()) {
-                Object o = it.next();
-                if (o instanceof NamedCollection<?>) {
-                    if (name.equals(((NamedCollection<?>) o).getName())) {
-                        return o;
-                    }
-                } else if (o instanceof MinMaxDescribeData) {
-                    if (name.equals(((MinMaxDescribeData) o).getMinName())) {
-                        return o;
-                    }
-                    if (name.equals(((MinMaxDescribeData) o).getMaxName())) {
-                        return o;
-                    }
-                }else if (o instanceof SingleValueDescribeData) {
-                    if (name.equals(((SingleValueDescribeData)o).getName())){
-                        return o;
-                    }
-                }
-            }
-        }
-        return null;
-
-    }
-
-    /**
-     * @see de.intevation.gnv.transition.Transition#isTransitionReachable(java.lang.String)
-     */
-    public boolean isTransitionReachable(String transitionID) {
-        log.debug("TransitionBase.isTransitionReachable");
-        boolean returnValue = false;
-        Iterator<String> transitions = reachableTransitions.iterator();
-        while (transitions.hasNext()) {
-            if (transitions.next().equals(transitionID)) {
-                log.debug("Transition " + transitionID + " wird unterstützt.");
-                returnValue = true;
-                break;
-            }
-        }
-        return returnValue;
-    }
-
-    /**
-     * @see de.intevation.gnv.transition.Transition#advance(java.lang.String,
-     *      de.intevation.artifacts.CallMeta)
-     */
-    public void advance(String uuid, CallMeta callMeta)
-                                                   throws TransitionException {
-    }
-    
-    public void initialize(String uuid, CallMeta callMeta)
-                                                   throws TransitionException {
-        log.debug("TransitionBase.initialize");
-        try {
-            String[] filterValues = this
-                    .generateFilterValuesFromInputData();
-            Collection<Result> result = null;
-            try {
-                if (this.queryID != null) {
-                    QueryExecutor queryExecutor = QueryExecutorFactory
-                            .getInstance().getQueryExecutor();
-                    result = queryExecutor.executeQuery(this.queryID,
-                            filterValues);
-                }
-                this.purifyResult(result, uuid);
-            } catch (RuntimeException e) {
-                log.error(e, e);
-            }
-        } catch (QueryException e) {
-            log.error(e, e);
-            throw new TransitionException(e);
-        }
-    }
-
-    /**
-     * @return
-     */
-    protected String[] generateFilterValuesFromInputData() {
-        List<String> list = new ArrayList<String>();
-        Iterator<String> it = this.inputValueNames.iterator();
-        while (it.hasNext()) {
-            String value = it.next();
-            InputData data = this.inputData.get(value);
-            if (data != null
-                && this.inputValues.containsKey(data.getName())) {
-                int size = this.inputValues.get(data.getName())
-                        .usedInQueries();
-                String type = this.inputValues.get(data.getName())
-                        .getType();
-                String requestValue = data.getValue();
-                if (type.equalsIgnoreCase("string")) {
-                    requestValue = this
-                            .prepareInputData4DBQuery(requestValue);
-                } else if (type.equalsIgnoreCase("date")) {
-                    requestValue = this
-                            .prepareInputData4DateDBQuery(requestValue);
-                } else if (type.equalsIgnoreCase("coordinate")){
-                    requestValue = this
-                    .prepareInputData4RegionDBQuery(requestValue);
-                }
-                for (int j = 0; j < size; j++) {
-                    list.add(requestValue);
-                }
-            }
-        }
-        String[] filterValues = list.toArray(new String[0]);
-        return filterValues;
-    }
-    
-    protected String prepareInputData4RegionDBQuery(String value){
-        return value;
-    }
-
-    private String prepareInputData4DateDBQuery(String value) {
-        log.debug("TransitionBase.prepareInputData4DateDBQuery");
-        if (value != null) {
-            String[] values = value.split(",");
-            String newValue = "";
-            for (int i = 0; i < values.length; i++) {
-                if (newValue.length() > 0) {
-                    newValue = newValue + " , ";
-                }
-                // TODO JUST HACK FIND A BETTER RESOLUTION
-                newValue = newValue + "to_date('" + values[i].trim()
-                           + "', 'YYYY.MM.DD HH24:MI:SS')";
-            }
-            return newValue;
-        }
-
-        return value;
-    }
-
-    private String prepareInputData4DBQuery(String value) {
-        log.debug("TransitionBase.prepareInputData4DBQuery");
-        if (value != null) {
-            String[] values = value.split(",");
-            String newValue = "";
-            for (int i = 0; i < values.length; i++) {
-                if (newValue.length() > 0) {
-                    newValue = newValue + " , ";
-                }
-                newValue = newValue + "'" + values[i].trim() + "'";
-            }
-            return newValue;
-        }
-
-        return value;
-
-    }
-
-    /**
-     * @param result
-     */
-    protected void purifyResult(Collection<Result> result, String uuid) {
-        log.debug("TransitionBase.purifyResult");
-        Collection<Object> describeData = this.getDescibeData(uuid);
-        if (describeData == null) {
-            describeData = new ArrayList<Object>();
-        }
-        NamedCollection<KeyValueDescibeData> keyValueDescibeData = extractKVP(result, "KEY", "VALUE");
-        describeData.add(keyValueDescibeData); 
-        this.setDescibeData(uuid, describeData);
-    }
-
-    /**
-     * @param result
-     * @return
-     */
-    protected NamedCollection<KeyValueDescibeData> extractKVP(Collection<Result> result,
-                                                              String keyid,
-                                                              String valueid) {
-        Iterator<Result> rit = result.iterator();
-        int dataSize = (this.dataNoSelect ? result.size()+1 : result.size());
-        
-        NamedCollection<KeyValueDescibeData> keyValueDescibeData = new NamedArrayList<KeyValueDescibeData>(
-                this.dataName, dataSize);
-        keyValueDescibeData.setMultiSelect(this.dataMultiSelect);
-        
-        if (this.dataNoSelect){
-            keyValueDescibeData.add(new DefaultKeyValueDescribeData(NODATASELECTIONKEY, 
-                                                                    "No Selection"));
-        }
-        boolean initialized = false;
-        int keyPos= 0;
-        int valuePos = 1;
-        String previousKey = null;
-        while (rit.hasNext()) {
-            Result resultValue = rit.next();
-            if (!initialized){
-                keyPos = resultValue.getResultDescriptor().getColumnIndex(keyid);
-                valuePos = resultValue.getResultDescriptor().getColumnIndex(valueid);
-                if (valuePos < 0){
-                    valuePos = 1;
-                }
-                initialized = true;
-            }
-            String tmpKey = resultValue.getString(keyPos);
-            // TODO: HACK da die ARCSDE kein DISTINCT auf räumlichen Anfragen unterstützt.
-            if (previousKey == null || !tmpKey.equals(previousKey)){
-                previousKey = tmpKey;
-                keyValueDescibeData.add(new DefaultKeyValueDescribeData(tmpKey, resultValue.getString(valuePos)));
-            }
-        }
-        return keyValueDescibeData;
-    }
-
-    /**
-     * @see de.intevation.gnv.transition.Transition#describe(org.w3c.dom.Document,
-     *      org.w3c.dom.Node, de.intevation.artifacts.CallMeta,
-     *      java.lang.String)
-     */
-    public void describe(Document document, Node rootNode, CallMeta callMeta,String uuid) {
-        log.debug("TransitionBase.describe");
-        Collection<Object> descibeData = this.getDescibeData(uuid);
-        if (descibeData != null) {
-            ArtifactXMLUtilities xmlutilities = new ArtifactXMLUtilities();
-            Iterator<Object> it = descibeData.iterator();
-            Node staticNode = xmlutilities.createArtifactElement(document,
-                    "static");
-            Node dynamic = xmlutilities.createArtifactElement(document,
-                    "dynamic");
-            rootNode.appendChild(staticNode);
-            rootNode.appendChild(dynamic);
-            while (it.hasNext()) {
-
-                Object o = it.next();
-                if (o instanceof Collection<?>) {
-                    String name = null;
-                    boolean multiselect = false;
-                    if (o instanceof NamedCollection<?>) {
-                        NamedCollection<?> nc = ((NamedCollection<?>) o);
-                        name = nc.getName();
-                        multiselect = nc.isMultiSelect();
-                    } else {
-                        Object[] names = this.inputValueNames.toArray();
-                        name = names[names.length - 1].toString();
-                    }
-
-                    Element selectNode = xmlutilities.createXFormElement(
-                            document, multiselect ? "select" : "select1");
-                    selectNode.setAttribute("ref", name);
-
-                    Element lableNode = xmlutilities.createXFormElement(
-                            document, "label");
-                    lableNode.setTextContent(RessourceFactory.getInstance()
-                            .getRessource(callMeta.getLanguages(), name, name));
-                    Element choiceNode = xmlutilities.createXFormElement(
-                            document, "choices");
-
-                    Collection<KeyValueDescibeData> values = (Collection<KeyValueDescibeData>) o;
-                    Iterator<KeyValueDescibeData> resultIt = values.iterator();
-                    while (resultIt.hasNext()) {
-                        KeyValueDescibeData result = resultIt.next();
-                        Element itemNode = xmlutilities.createXFormElement(
-                                document, "item");
-
-                        if (result.isSelected()) {
-                            itemNode.setAttribute("selected", "true");
-                        }
-
-                        Element choiceLableNode = xmlutilities
-                                .createXFormElement(document, "label");
-                        choiceLableNode.setTextContent(result.getValue());
-                        itemNode.appendChild(choiceLableNode);
-
-                        Element choicValueNode = xmlutilities
-                                .createXFormElement(document, "value");
-                        choicValueNode.setTextContent("" + result.getKey());
-                        itemNode.appendChild(choicValueNode);
-                        choiceNode.appendChild(itemNode);
-                    }
-                    selectNode.appendChild(lableNode);
-                    selectNode.appendChild(choiceNode);
-
-                    if (!it.hasNext() && this.dataName != null) {
-                        dynamic.appendChild(selectNode);
-                    } else {
-                        staticNode.appendChild(selectNode);
-                    }
-
-                } else if (o instanceof MinMaxDescribeData) {
-                    MinMaxDescribeData minMaxDescibeData = (MinMaxDescribeData) o;
-                    Object min = minMaxDescibeData.getMinValue();
-                    Object max = minMaxDescibeData.getMaxValue();
-                    if (min instanceof GregorianCalendar) {
-                        Date d = ((GregorianCalendar) min).getTime();
-                        min = DateUtils.getPatternedDateAmer(d);
-                    }
-
-                    if (max instanceof GregorianCalendar) {
-                        Date d = ((GregorianCalendar) max).getTime();
-                        max = DateUtils.getPatternedDateAmer(d);
-                    }
-                    
-                    Element groupNode = xmlutilities.createXFormElement(
-                            document, "group");
-                    groupNode.setAttribute("ref", minMaxDescibeData.getName());
-                    Element groupNodeLableNode = xmlutilities
-                            .createXFormElement(document, "label");
-                    groupNodeLableNode.setTextContent(RessourceFactory
-                            .getInstance().getRessource(
-                                    callMeta.getLanguages(),
-                                    minMaxDescibeData.getName(),
-                                    minMaxDescibeData.getName()));
-                    groupNode.appendChild(groupNodeLableNode);
-
-                    Element inputMinNode = xmlutilities.createXFormElement(
-                            document, "input");
-                    inputMinNode.setAttribute("ref", MINVALUEFIELDNAME);
-                    Element inputMinLableNode = xmlutilities
-                            .createXFormElement(document, "label");
-                    inputMinLableNode.setTextContent(RessourceFactory
-                            .getInstance().getRessource(
-                                    callMeta.getLanguages(), MINVALUEFIELDNAME,
-                                    MINVALUEFIELDNAME));
-                    inputMinNode.appendChild(inputMinLableNode);
-
-                    Element inputMinValueNode = xmlutilities
-                            .createXFormElement(document, "value");
-                    inputMinValueNode.setTextContent(min.toString());
-                    inputMinNode.appendChild(inputMinValueNode);
-
-                    Element inputMaxNode = xmlutilities.createXFormElement(
-                            document, "input");
-                    inputMaxNode.setAttribute("ref", MAXVALUEFIELDNAME);
-                    Element inputMaxLableNode = xmlutilities
-                            .createXFormElement(document, "label");
-                    inputMaxLableNode.setTextContent(RessourceFactory
-                            .getInstance().getRessource(
-                                    callMeta.getLanguages(), MAXVALUEFIELDNAME,
-                                    MAXVALUEFIELDNAME));
-                    inputMaxNode.appendChild(inputMaxLableNode);
-
-                    Element inputMaxValueNode = xmlutilities
-                            .createXFormElement(document, "value");
-                    inputMaxValueNode.setTextContent(max.toString());
-                    inputMaxNode.appendChild(inputMaxValueNode);
-
-                    groupNode.appendChild(inputMinNode);
-                    groupNode.appendChild(inputMaxNode);
-                    
-                    if (!it.hasNext() && this.dataName != null) {
-                        dynamic.appendChild(groupNode);
-                    } else {
-                        staticNode.appendChild(groupNode);
-                    }
-                } else if (o instanceof SingleValueDescribeData) {
-
-                    SingleValueDescribeData svdb = (SingleValueDescribeData) o;
-                    
-                    Element groupNode = xmlutilities.createXFormElement(
-                            document, "group");
-                    groupNode.setAttribute("ref",  svdb.getName());
-                    Element groupNodeLableNode = xmlutilities
-                            .createXFormElement(document, "label");
-                    groupNodeLableNode.setTextContent(RessourceFactory
-                            .getInstance().getRessource(
-                                    callMeta.getLanguages(),
-                                    svdb.getName(),
-                                    svdb.getName()));
-                    groupNode.appendChild(groupNodeLableNode);
-
-                    Element inputNode = xmlutilities.createXFormElement(
-                            document, "input");
-                    inputNode.setAttribute("ref", svdb.getName());
-
-                    Element inputLableNode = xmlutilities.createXFormElement(
-                            document, "label");
-                    inputLableNode.setTextContent("");
-                    inputNode.appendChild(inputLableNode);
-
-                    Element inputValueNode = xmlutilities.createXFormElement(
-                            document, "value");
-                    inputValueNode.setTextContent(svdb.getValue());
-                    inputNode.appendChild(inputValueNode);
-
-                    groupNode.appendChild(inputNode);
-                    if (!it.hasNext() && this.dataName != null) {
-                        dynamic.appendChild(groupNode);
-                    } else {
-                        staticNode.appendChild(groupNode);
-                    }
-                }
-
-            }
-        }
-    }
-
-    /**
-     * @see de.intevation.gnv.transition.Transition#getDescibeData()
-     */
-    protected Collection<Object> getDescibeData(String uuid) {
-        if (CacheFactory.getInstance().isInitialized()) {
-            String key = uuid + DESCRIBEDATAKEY;
-            log.debug("Hash for Queryelements: " + key);
-            net.sf.ehcache.Element value = CacheFactory.getInstance().getCache().get(key);
-            if (value != null) {
-                return (Collection<Object>) (value.getObjectValue());
-            }
-        }
-        return null;
-    }
-    
-    /**
-     * @see de.intevation.gnv.transition.Transition#getDescibeData()
-     */
-    protected void setDescibeData(String uuid, Collection<Object> describeData) {
-        
-        if (CacheFactory.getInstance().isInitialized()) {
-            String key = uuid + DESCRIBEDATAKEY;
-            log.debug("Hash for Queryelements: " + key);
-            CacheFactory.getInstance().getCache().put(new net.sf.ehcache.Element(key, describeData));
-        }
-    }
-
-    /**
-     * @see de.intevation.gnv.transition.Transition#getInputData()
-     */
-    public Collection<InputData> getInputData() throws TransitionException {
-        return this.inputData != null ? this.inputData.values() : null;
-    }
-}
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/transition/TransitionFactory.java	Mon Dec 07 17:03:24 2009 +0000
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,55 +0,0 @@
-/**
- *
- */
-package de.intevation.gnv.transition;
-
-import org.apache.log4j.Logger;
-import org.w3c.dom.Node;
-
-import de.intevation.gnv.artifacts.GNVArtifactBase;
-
-/**
- * @author Tim Englich <tim.englich@intevation.de>
- * 
- */
-public class TransitionFactory {
-
-    /**
-     * the logger, used to log exceptions and additonaly information
-     */
-    private static Logger log = Logger.getLogger(GNVArtifactBase.class);
-
-    private static TransitionFactory instance = null;
-
-    /**
-     * Constructor
-     */
-    public TransitionFactory() {
-        super();
-    }
-
-    public static TransitionFactory getInstance() {
-        if (instance == null) {
-            instance = new TransitionFactory();
-        }
-        return instance;
-    }
-
-    public Transition createTransition(Node configuration) {
-        log.debug("TransitionFactory.createTransition");
-        Transition transition = null;
-        try {
-            String classname = ((org.w3c.dom.Element)configuration).getAttribute("transition");
-            transition = (Transition) (Class.forName(classname).newInstance());
-            transition.setup(configuration);
-        } catch (InstantiationException e) {
-            log.error(e, e);
-        } catch (IllegalAccessException e) {
-            log.error(e, e);
-        } catch (ClassNotFoundException e) {
-            log.error(e, e);
-        }
-        return transition;
-    }
-
-}
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/transition/describedata/DefaultKeyValueDescribeData.java	Mon Dec 07 17:03:24 2009 +0000
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,57 +0,0 @@
-/**
- *
- */
-package de.intevation.gnv.transition.describedata;
-
-/**
- * @author Tim Englich <tim.englich@intevation.de>
- * 
- */
-public class DefaultKeyValueDescribeData implements KeyValueDescibeData {
-
-    /**
-     *
-     */
-    private static final long serialVersionUID = -924469415242703108L;
-
-    private String key;
-
-    private String value = null;
-
-    private boolean selected = false;
-
-    public DefaultKeyValueDescribeData(String key, String value) {
-        super();
-        this.key = key;
-        this.value = value;
-    }
-
-    /**
-     * @see de.intevation.gnv.transition.describedata.KeyValueDescibeData#getKey()
-     */
-    public String getKey() {
-        return this.key;
-    }
-
-    /**
-     * @see de.intevation.gnv.transition.describedata.KeyValueDescibeData#getValue()
-     */
-    public String getValue() {
-        return this.value;
-    }
-
-    /**
-     * @see de.intevation.gnv.transition.describedata.KeyValueDescibeData#isSelected()
-     */
-    public boolean isSelected() {
-        return this.selected;
-    }
-
-    /**
-     * @see de.intevation.gnv.transition.describedata.KeyValueDescibeData#setSelected(boolean)
-     */
-    public void setSelected(boolean selected) {
-        this.selected = selected;
-    }
-
-}
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/transition/describedata/DefaultMinMaxDescribeData.java	Mon Dec 07 17:03:24 2009 +0000
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,92 +0,0 @@
-/**
- *
- */
-package de.intevation.gnv.transition.describedata;
-
-/**
- * @author Tim Englich <tim.englich@intevation.de>
- * 
- */
-public class DefaultMinMaxDescribeData implements MinMaxDescribeData {
-
-    /**
-     *
-     */
-    private static final long serialVersionUID = -2917176219029052295L;
-
-    private Object minValue = null;
-
-    private Object maxValue = null;
-    
-    private String name = null; 
-
-    private final static String minName = "minvalue";
-
-    private final static String maxName = "maxvalue";
-
-    /**
-     * Constructor
-     */
-    public DefaultMinMaxDescribeData(String name, Object minValue, Object maxValue) {
-        super();
-        this.name = name;
-        this.minValue = minValue;
-        this.maxValue = maxValue;
-    }
-
-    /**
-     * @see de.intevation.gnv.transition.describedata.MinMaxDescribeData#getMaxValue()
-     */
-    public Object getMaxValue() {
-        return this.maxValue;
-    }
-
-    /**
-     * @see de.intevation.gnv.transition.describedata.MinMaxDescribeData#getMinValue()
-     */
-    public Object getMinValue() {
-        return this.minValue;
-    }
-
-    /**
-     * @see java.lang.Object#toString()
-     */
-    @Override
-    public String toString() {
-        return "MIN: " + this.minValue.toString() + " ; MAX: "
-               + this.maxValue.toString();
-    }
-
-    /**
-     * @see de.intevation.gnv.transition.describedata.MinMaxDescribeData#getName()
-     */
-    public String getMinName() {
-        return minName;
-    }
-
-    /**
-     * @see de.intevation.gnv.transition.describedata.MinMaxDescribeData#getMaxName()
-     */
-    public String getMaxName() {
-        return maxName;
-    }
-
-    /**
-     * @see de.intevation.gnv.transition.describedata.MinMaxDescribeData#setMaxValue(java.lang.Object)
-     */
-    public void setMaxValue(Object maxValue) {
-        this.maxValue = maxValue;
-    }
-
-    /**
-     * @see de.intevation.gnv.transition.describedata.MinMaxDescribeData#setMinValue(java.lang.Object)
-     */
-    public void setMinValue(Object minValue) {
-        this.minValue = minValue;
-    }
-
-    public String getName() {
-       return this.name;
-    }
-
-}
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/transition/describedata/DefaultSingleValueDescribeData.java	Mon Dec 07 17:03:24 2009 +0000
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,51 +0,0 @@
-/**
- *
- */
-package de.intevation.gnv.transition.describedata;
-
-/**
- * @author Tim Englich <tim.englich@intevation.de>
- * 
- */
-public class DefaultSingleValueDescribeData implements SingleValueDescribeData {
-
-    /**
-     *
-     */
-    private static final long serialVersionUID = 3580176842483316917L;
-
-    private String name = null;
-
-    private String value = null;
-
-    /**
-     * Constructor
-     * 
-     * @param name
-     * @param value
-     */
-    public DefaultSingleValueDescribeData(String name, String value) {
-        super();
-        this.name = name;
-        this.value = value;
-    }
-
-    /**
-     * @see de.intevation.gnv.transition.describedata.SingleValueDescribeData#getName()
-     */
-    public String getName() {
-        return this.name;
-    }
-
-    /**
-     * @see de.intevation.gnv.transition.describedata.SingleValueDescribeData#getValue()
-     */
-    public String getValue() {
-        return this.value;
-    }
-
-    public void setValue(String value) {
-        this.value = value;
-    }
-
-}
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/transition/describedata/DescribeData.java	Mon Dec 07 17:03:24 2009 +0000
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,16 +0,0 @@
-/**
- *
- */
-package de.intevation.gnv.transition.describedata;
-
-import java.io.Serializable;
-
-/**
- * Markerinterface
- * 
- * @author Tim Englich <tim.englich@intevation.de>
- * 
- */
-public interface DescribeData extends Serializable {
-
-}
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/transition/describedata/KeyValueDescibeData.java	Mon Dec 07 17:03:24 2009 +0000
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,22 +0,0 @@
-/**
- *
- */
-package de.intevation.gnv.transition.describedata;
-
-import java.io.Serializable;
-
-/**
- * @author Tim Englich <tim.englich@intevation.de>
- * 
- */
-public interface KeyValueDescibeData extends Serializable {
-
-    public String getKey();
-
-    public String getValue();
-
-    public boolean isSelected();
-
-    public void setSelected(boolean selected);
-
-}
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/transition/describedata/MinMaxDescribeData.java	Mon Dec 07 17:03:24 2009 +0000
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,26 +0,0 @@
-/**
- *
- */
-package de.intevation.gnv.transition.describedata;
-
-/**
- * @author Tim Englich <tim.englich@intevation.de>
- * 
- */
-public interface MinMaxDescribeData extends DescribeData {
-
-    public Object getMinValue();
-
-    public Object getMaxValue();
-
-    public void setMinValue(Object minValue);
-
-    public void setMaxValue(Object maxValue);
-
-    public String getName();
-    
-    public String getMinName();
-
-    public String getMaxName();
-
-}
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/transition/describedata/NamedArrayList.java	Mon Dec 07 17:03:24 2009 +0000
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,71 +0,0 @@
-/**
- *
- */
-package de.intevation.gnv.transition.describedata;
-
-import java.util.ArrayList;
-import java.util.Collection;
-
-/**
- * @author Tim Englich <tim.englich@intevation.de>
- * 
- */
-public class NamedArrayList<E> extends ArrayList<E> implements
-                                                   NamedCollection<E> {
-    /**
-     *
-     */
-    private static final long serialVersionUID = 8172229594749676354L;
-
-    private String name = null;
-
-    private boolean multiSelect = false;
-
-    /**
-     * Constructor
-     */
-    public NamedArrayList(String name) {
-        this.name = name;
-    }
-
-    /**
-     * Constructor
-     * 
-     * @param initialCapacity
-     */
-    public NamedArrayList(String name, int initialCapacity) {
-        super(initialCapacity);
-        this.name = name;
-    }
-
-    /**
-     * Constructor
-     * 
-     * @param c
-     */
-    public NamedArrayList(String name, Collection<E> c) {
-        super(c);
-        this.name = name;
-    }
-
-    /**
-     * @see de.intevation.gnv.transition.describedata.NamedCollection#getName()
-     */
-    public String getName() {
-        return this.name;
-    }
-
-    /**
-     * @see de.intevation.gnv.transition.describedata.NamedCollection#isMultiSelect()
-     */
-    public boolean isMultiSelect() {
-        return multiSelect;
-    }
-
-    /**
-     * @see de.intevation.gnv.transition.describedata.NamedCollection#setMultiSelect(boolean)
-     */
-    public void setMultiSelect(boolean multiSelect) {
-        this.multiSelect = multiSelect;
-    }
-}
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/transition/describedata/NamedCollection.java	Mon Dec 07 17:03:24 2009 +0000
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,19 +0,0 @@
-/**
- *
- */
-package de.intevation.gnv.transition.describedata;
-
-import java.util.Collection;
-
-/**
- * @author Tim Englich <tim.englich@intevation.de>
- * 
- */
-public interface NamedCollection<E> extends Collection<E> {
-
-    public String getName();
-
-    public boolean isMultiSelect();
-
-    public void setMultiSelect(boolean multiSelect);
-}
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/transition/describedata/SingleValueDescribeData.java	Mon Dec 07 17:03:24 2009 +0000
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,17 +0,0 @@
-/**
- *
- */
-package de.intevation.gnv.transition.describedata;
-
-/**
- * @author Tim Englich <tim.englich@intevation.de>
- * 
- */
-public interface SingleValueDescribeData extends DescribeData {
-
-    public String getName();
-
-    public String getValue();
-    
-    public void setValue(String value);
-}
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/transition/exception/TransitionException.java	Mon Dec 07 17:03:24 2009 +0000
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,52 +0,0 @@
-/**
- *
- */
-package de.intevation.gnv.transition.exception;
-
-/**
- * @author Tim Englich <tim.englich@intevation.de>
- * 
- */
-public class TransitionException extends Exception {
-
-    /**
-     * The UID of the Class
-     */
-    private static final long serialVersionUID = -1635921702746050244L;
-
-    /**
-     * Constructor
-     */
-    public TransitionException() {
-        super();
-    }
-
-    /**
-     * Constructor
-     * 
-     * @param message
-     */
-    public TransitionException(String message) {
-        super(message);
-    }
-
-    /**
-     * Constructor
-     * 
-     * @param cause
-     */
-    public TransitionException(Throwable cause) {
-        super(cause);
-    }
-
-    /**
-     * Constructor
-     * 
-     * @param message
-     * @param cause
-     */
-    public TransitionException(String message, Throwable cause) {
-        super(message, cause);
-    }
-
-}
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/transition/profile/horizontal/HorizontalProfileOutputTransition.java	Mon Dec 07 17:03:24 2009 +0000
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,285 +0,0 @@
-/**
- *
- */
-package de.intevation.gnv.transition.profile.horizontal;
-
-import com.vividsolutions.jts.geom.Point;
-import com.vividsolutions.jts.io.WKTReader;
-import com.vividsolutions.jts.io.ParseException;
-
-import java.io.IOException;
-import java.io.OutputStream;
-import java.io.UnsupportedEncodingException;
-import java.text.SimpleDateFormat;
-import java.util.Collection;
-import java.util.Date;
-import java.util.Iterator;
-import java.util.Locale;
-
-import org.apache.log4j.Logger;
-
-import de.intevation.gnv.chart.Chart;
-import de.intevation.gnv.chart.ChartLabels;
-import de.intevation.gnv.chart.HorizontalProfileChart;
-import de.intevation.gnv.geobackend.base.Result;
-import de.intevation.gnv.statistics.HorizontalProfileStatistics;
-import de.intevation.gnv.statistics.Statistics;
-import de.intevation.gnv.transition.exception.TransitionException;
-import de.intevation.gnv.transition.timeseries.TimeSeriesOutputTransition;
-
-import de.intevation.gnv.exports.DefaultExport;
-import de.intevation.gnv.exports.ShapeDataCollector;
-import de.intevation.gnv.exports.DefaultProfile;
-import de.intevation.gnv.exports.Export.Profile;
-import de.intevation.gnv.transition.describedata.KeyValueDescibeData;
-
-/**
- * @author Tim Englich <tim.englich@intevation.de>
- * 
- */
-public class HorizontalProfileOutputTransition extends
-                                              TimeSeriesOutputTransition {
-    /**
-     * The UID of this class
-     */
-    private static final long serialVersionUID = 4401516087492028840L;
-
-    private static Logger log = Logger
-    .getLogger(HorizontalProfileOutputTransition.class);
-
-    public static final String DATE_FORMAT = "yyyy.MM.dd HH:mm:ss";
-
-    public static final String [] CHART_TITLE_META = {
-        "CRUISE",
-        "DEPTH",
-        "SHAPE"
-    };
-
-
-    public static final String [] CHART_TITLE_META_RESSOURCES = {
-        "cruiseid",
-        "depth",
-        "coordinate"
-    };
-
-    public static final String [] TIMESERIES_CSV_PROFILE_NAMES = {
-        "SHAPE",
-        "YORDINATE",
-        "GROUP1",
-        "GROUP2",
-        "GROUP3"
-    };
-
-    public static final Profile TIMESERIES_CSV_PROFILE =
-        new DefaultProfile(
-            null,
-            ',',
-            '"',
-            '"',
-            "CSV",
-            "ISO-8859-1");
-
-    /**
-     * Constructor
-     */
-    public HorizontalProfileOutputTransition() {
-        super();
-        super.domainLable = "Distance [km]";
-    }
-
-
-    @Override
-    protected Chart getChart(
-        ChartLabels  chartLables,
-        Collection   parameters,
-        Collection   measurements,
-        Collection   dates,
-        Collection   result,
-        Locale       locale,
-        String       uuid,
-        boolean      linesVisible,
-        boolean      shapesVisible
-    ) {
-        Chart chart = null;
-
-        if (CACHE_CHART) {
-            log.info("Try to get horizontalprofile chart from cache.");
-            chart = (Chart) getChartFromCache(uuid);
-        }
-
-        if (chart != null)
-            return chart;
-
-        log.info("Chart not in cache yet.");
-        chart = new HorizontalProfileChart(
-            chartLables,
-            createStyle(),
-            parameters,
-            measurements,
-            dates,
-            result,
-            null,
-            locale,
-            linesVisible,
-            shapesVisible
-        );
-        chart.generateChart();
-
-        if (CACHE_CHART) {
-            log.info("Put chart into cache.");
-            purifyChart(chart, uuid);
-        }
-
-        return chart;
-    }
-
-
-    /**
-     * @see de.intevation.gnv.transition.timeseries.TimeSeriesOutputTransition#getStatisticsGenerator()
-     */
-    @Override
-    protected Statistics getStatisticsGenerator() {
-        return new HorizontalProfileStatistics();
-    }
-
-    @Override
-    protected void createCSV(OutputStream outputStream,
-                             Collection<Result> chartResult)
-                                                            throws UnsupportedEncodingException,
-                                                            IOException,
-                                                            TransitionException {
-       
-        log.debug("createCSV for HorizontalProfileOutputTransition.");
-        DefaultExport export = new DefaultExport(
-            new ShapeDataCollector(TIMESERIES_CSV_PROFILE_NAMES));
-
-        export.create(TIMESERIES_CSV_PROFILE, outputStream, chartResult);
-    }
-
-
-    protected String createChartTitle(Locale locale, String uuid) {
-        String fisName = getFisName(locale);
-        log.debug("created title for horizontal profile chart: " + fisName);
-
-        return fisName;
-    }
-
-
-    protected String createChartSubtitle(Locale locale, String uuid) {
-        log.debug("create chart subtitle.");
-        String subtitle = createTimePeriod(locale, uuid);
-
-        // ODV results contain meta information about cruise, station and so on
-        Collection results = getODVResult(uuid);
-        if (results != null) {
-            Iterator iter   = results.iterator();
-            Result   result = iter.hasNext() ? (Result) iter.next() : null;
-
-            subtitle += subtitle.length() != 0 ? "\n" : "";
-            subtitle += createMetaChartSubtitle(locale, result);
-        }
-
-        return subtitle;
-    }
-
-
-    protected String createMetaChartSubtitle(Locale locale, Result result) {
-        log.debug("Fetch meta information and put it into subtitle.");
-        if (result == null)
-            return "";
-
-        StringBuilder meta      = new StringBuilder();
-        WKTReader     wktReader = new WKTReader();
-
-
-        for (int i = 0; i < CHART_TITLE_META.length; i++) {
-            String qry = CHART_TITLE_META[i];
-
-            if (qry.equals("SHAPE")) {
-                try {
-                    Point p = (Point) wktReader.read(result.getString(qry));
-
-                    meta.append(getMessage(locale,"coordinate","coordinate"));
-                    meta.append(": ");
-
-                    log.debug(
-                        "Add " + qry + " to meta information of subtitle: "
-                        + p.toString()
-                    );
-                    meta.append(p.getX() + ", " + p.getY());
-                }
-                catch (ParseException pe) {
-                    log.warn("Error while parsing point.", pe);
-                }
-            }
-            else {
-                log.debug(
-                    "Add " + qry + " to meta information of subtitle: "
-                    + result.getString(qry)
-                );
-                meta.append(getMessage(
-                    locale,
-                    CHART_TITLE_META_RESSOURCES[i],
-                    CHART_TITLE_META_RESSOURCES[i]
-                ));
-                meta.append(": ");
-                meta.append(result.getString(qry));
-            }
-
-            if (i != CHART_TITLE_META.length-1)
-                meta.append("\n");
-        }
-
-        log.debug("Meta title for chart: " + meta.toString());
-        return meta.toString();
-    }
-
-
-    protected String createTimePeriod(Locale locale, String uuid) {
-        log.debug("create time period for chart subtitle.");
-        String subTitle = null;
-        Date startDate  = null;
-        Date endDate    = null;
-
-        Collection          dates  = getDates(uuid);
-        if (dates == null) {
-            log.debug("No time period for subtitle.");
-            return "";
-        }
-
-        SimpleDateFormat    format = new SimpleDateFormat(DATE_FORMAT);
-        KeyValueDescibeData data   = null;
-
-        Iterator iter = dates.iterator();
-        while (iter.hasNext()) {
-            try {
-                data = (KeyValueDescibeData)iter.next();
-
-                if (!data.isSelected())
-                    continue;
-
-                Date current = format.parse(data.getValue());
-                long time    = current.getTime();
-
-                if (startDate == null) {
-                    startDate = current;
-                    endDate   = current;
-                }
-                else if (time < startDate.getTime()) {
-                    startDate = current;
-                }
-                else if (time > endDate.getTime()) {
-                    endDate = current;
-                }
-            }
-            catch (java.text.ParseException pe) {
-                log.warn("Error while parsing date: " + data.getValue(), pe);
-            }
-        }
-
-        subTitle = format.format(startDate) + " - " + format.format(endDate);
-        log.debug("created title for horizontal profile chart: " + subTitle);
-
-        return subTitle;
-    }
-}
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/transition/profile/horizontal/NorthSouthEastWestTransition.java	Mon Dec 07 17:03:24 2009 +0000
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,67 +0,0 @@
-/**
- *
- */
-package de.intevation.gnv.transition.profile.horizontal;
-
-import java.util.ArrayList;
-import java.util.Collection;
-
-import de.intevation.artifacts.CallMeta;
-import de.intevation.gnv.artifacts.ressource.RessourceFactory;
-import de.intevation.gnv.geobackend.base.Result;
-import de.intevation.gnv.transition.TransitionBase;
-import de.intevation.gnv.transition.describedata.DefaultKeyValueDescribeData;
-import de.intevation.gnv.transition.describedata.KeyValueDescibeData;
-import de.intevation.gnv.transition.describedata.NamedArrayList;
-import de.intevation.gnv.transition.describedata.NamedCollection;
-import de.intevation.gnv.transition.exception.TransitionException;
-
-/**
- * @author Tim Englich <tim.englich@intevation.de>
- * 
- */
-public class NorthSouthEastWestTransition extends TransitionBase {
-
-    
-    /**
-     * The UID of this Class
-     */
-    private static final long serialVersionUID = -7989531326553305293L;
-
-    /**
-     * Constructor
-     */
-    public NorthSouthEastWestTransition() {
-    }
-
-    /**
-     * @see de.intevation.gnv.transition.TransitionBase#purifyResult(java.util.Collection, java.lang.String)
-     */
-    @Override
-    protected void purifyResult(Collection<Result> result, String uuid) {
-    }
-    
-    /**
-     * @see de.intevation.gnv.transition.TransitionBase#initialize(java.lang.String, de.intevation.artifacts.CallMeta)
-     */
-    @Override
-    public void initialize(String uuid, CallMeta callMeta)
-                                                          throws TransitionException {
-        Collection<Object> describeData = this.getDescibeData(uuid);
-        if (describeData == null) {
-            describeData = new ArrayList<Object>();
-        }
-        NamedCollection<KeyValueDescibeData> keyValueDescibeData = new NamedArrayList<KeyValueDescibeData>(
-                this.dataName, 2);
-        keyValueDescibeData.setMultiSelect(super.dataMultiSelect);
-        keyValueDescibeData.add(new DefaultKeyValueDescribeData("IPOSITION",
-                RessourceFactory.getInstance().getRessource(
-                        callMeta.getLanguages(), "iposition", "iposition")));
-        keyValueDescibeData.add(new DefaultKeyValueDescribeData("JPOSITION",
-                RessourceFactory.getInstance().getRessource(
-                        callMeta.getLanguages(), "jposition", "jposition")));
-        describeData.add(keyValueDescibeData);
-    }
-
-
-}
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/transition/profile/horizontalcrosssection/HorizontalCrossSectionMeshOutputTransition.java	Mon Dec 07 17:03:24 2009 +0000
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,143 +0,0 @@
-/**
- *
- */
-package de.intevation.gnv.transition.profile.horizontalcrosssection;
-
-import java.io.IOException;
-import java.io.OutputStream;
-import java.io.OutputStreamWriter;
-import java.io.UnsupportedEncodingException;
-import java.util.Collection;
-import java.util.Iterator;
-import java.util.Locale;
-
-import org.apache.log4j.Logger;
-
-import au.com.bytecode.opencsv.CSVWriter;
-import de.intevation.gnv.chart.Chart;
-import de.intevation.gnv.chart.ChartLabels;
-import de.intevation.gnv.geobackend.base.Result;
-import de.intevation.gnv.statistics.Statistics;
-import de.intevation.gnv.transition.exception.TransitionException;
-import de.intevation.gnv.transition.timeseries.TimeSeriesOutputTransition;
-
-/**
- * @author Tim Englich <tim.englich@intevation.de>
- * 
- */
-public class HorizontalCrossSectionMeshOutputTransition 
-                                      extends TimeSeriesOutputTransition {
-
-    private static Logger log = Logger
-    .getLogger(HorizontalCrossSectionMeshOutputTransition.class);
-    
-    /**
-     * The UID of this Class
-     */
-    private static final long serialVersionUID = 3233620652465061860L;
-
-    /**
-     * Constructor
-     */
-    public HorizontalCrossSectionMeshOutputTransition() {
-        super();
-        super.domainLable = "Latitude [m]";
-    }
-
-    @Override
-    protected Chart getChart(
-        ChartLabels  chartLables,
-        Collection   parameters,
-        Collection   measurements,
-        Collection   dates,
-        Collection   result,
-        Locale       locale,
-        String       uuid,
-        boolean      linesVisible,
-        boolean      shapesVisible
-    ) {
-        Chart chart = null;
-
-        if (CACHE_CHART) {
-            log.info("Try to get horizontalcrosssection chart from cache.");
-            chart = (Chart) getChartFromCache(uuid);
-        }
-
-        if (chart != null)
-            return chart;
-
-        log.info("Chart not in cache yet.");
-        
-        log.warn("This sort of chart is not implemented yet.");
-        /* TODO Implement a special chart for this sort of charts.
-        chart = new HorizontalProfileChart(
-            chartLables,
-            chartTheme,
-            parameters,
-            measurements,
-            result,
-            dates,
-            locale
-        );
-        chart.generateChart();
-
-        if (CACHE_CHART) {
-            log.info("Put chart into cache.");
-            purifyChart(chart, uuid);
-        }
-        */
-
-        return chart;
-    }
-
-
-    /**
-     * @see de.intevation.gnv.transition.timeseries.TimeSeriesOutputTransition#getStatisticsGenerator()
-     */
-    @Override
-    protected Statistics getStatisticsGenerator() {
-        return null; //Statistiken werden nicht für diesen Out-Typ unterstützt.
-    }
-    
-    /**
-     * @see de.intevation.gnv.transition.timeseries.TimeSeriesOutputTransition#createCSV(java.io.OutputStream,
-     *      java.util.Collection)
-     */
-    @Override
-    protected void createCSV(OutputStream outputStream,
-                             Collection<Result> chartResult)
-                                            throws UnsupportedEncodingException,
-                                                   IOException,
-                                                   TransitionException {
-        if (chartResult != null) {
-            try {
-                CSVWriter writer = new CSVWriter(new OutputStreamWriter(
-                        outputStream, "ISO-8859-1"), ','); 
-                // USE THIS ENCODING BECAUSE OF
-                // PROBLEMS WITH EXCEL AND UTF-8
-                Iterator<Result> it = chartResult.iterator();
-                while (it.hasNext()) {
-                    Result result = it.next();
-                    int i = 0;
-                    String[] entries = new String[5];
-                    entries[i++] = result.getString("SHAPE");
-                    entries[i++] = result.getString("YORDINATE");
-                    entries[i++] = result.getString("IPOSITION");
-                    entries[i++] = result.getString("JPOSITION");
-                    entries[i++] = result.getString("KPOSITION");
-                    writer.writeNext(entries);
-                }
-                writer.close();
-            } catch (Exception e) {
-                log.error(e,e);
-                throw new TransitionException(
-                "Exception occured while parsing an Point from WKT.");
-            }
-        } else {
-            log.error("No Data given for generating an CSV-File.");
-            throw new TransitionException(
-                    "No Data given for generating an CSV-File.");
-        }
-    }
-
-}
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/transition/profile/vertical/VerticalProfileOutputTransition.java	Mon Dec 07 17:03:24 2009 +0000
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,100 +0,0 @@
-/**
- *
- */
-package de.intevation.gnv.transition.profile.vertical;
-
-import java.util.Collection;
-import java.util.Locale;
-
-import org.apache.log4j.Logger;
-
-import de.intevation.gnv.chart.Chart;
-import de.intevation.gnv.chart.ChartLabels;
-import de.intevation.gnv.chart.VerticalProfileChart;
-import de.intevation.gnv.statistics.Statistics;
-import de.intevation.gnv.statistics.VerticalProfileStatistics;
-import de.intevation.gnv.transition.timeseries.TimeSeriesOutputTransition;
-
-/**
- * @author Tim Englich <tim.englich@intevation.de>
- * 
- */
-public class VerticalProfileOutputTransition extends TimeSeriesOutputTransition {
-    /**
-     * The UID of this class
-     */
-    private static final long serialVersionUID = 4401516087492028840L;
-
-    private static Logger log = Logger
-            .getLogger(TimeSeriesOutputTransition.class);
-
-    /**
-     * Constructor
-     */
-    public VerticalProfileOutputTransition() {
-        super();
-        super.domainLable = "Depth [m]";
-    }
-
-    
-    @Override
-    protected Chart getChart(
-        ChartLabels chartLables,
-        Collection  parameters,
-        Collection  measurements,
-        Collection  dates,
-        Collection  result,
-        Locale      locale,
-        String      uuid,
-        boolean     linesVisible,
-        boolean     shapesVisible
-    ) {
-        Chart chart = null;
-
-        if (CACHE_CHART) {
-            log.info("Try to get verticalprofile chart from cache.");
-            chart = (Chart) getChartFromCache(uuid);
-        }
-
-        if (chart != null)
-            return chart;
-
-        log.info("Chart not in cache yet.");
-        chart = new VerticalProfileChart(
-            chartLables,
-            this.createStyle(),
-            parameters,
-            measurements,
-            dates,
-            result,
-            null,
-            locale,
-            linesVisible,
-            shapesVisible
-        );
-        chart.generateChart();
-
-        if (CACHE_CHART) {
-            log.info("Put chart into cache.");
-            purifyChart(chart, uuid);
-        }
-
-        return chart;
-    }
-
-
-    protected String createChartSubtitle(Locale locale, String uuid) {
-        return getSelectedFeatureName(uuid);
-    }
-
-
-
-    /**
-     * @see de.intevation.gnv.transition.timeseries.TimeSeriesOutputTransition#getStatisticsGenerator()
-     */
-    @Override
-    protected Statistics getStatisticsGenerator() {
-        return new VerticalProfileStatistics();
-    }
-
-}
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/transition/profile/verticalcrosssection/VerticalCrossSectionOutputTransition.java	Mon Dec 07 17:03:24 2009 +0000
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,176 +0,0 @@
-/**
- *
- */
-package de.intevation.gnv.transition.profile.verticalcrosssection;
-
-import java.io.IOException;
-import java.io.OutputStream;
-import java.io.OutputStreamWriter;
-import java.io.UnsupportedEncodingException;
-import java.util.Collection;
-import java.util.Iterator;
-import java.util.Locale;
-
-import org.apache.log4j.Logger;
-
-import au.com.bytecode.opencsv.CSVWriter;
-
-import com.vividsolutions.jts.geom.Point;
-import com.vividsolutions.jts.io.ParseException;
-import com.vividsolutions.jts.io.WKTReader;
-
-import de.intevation.gnv.chart.Chart;
-import de.intevation.gnv.chart.ChartLabels;
-import de.intevation.gnv.chart.ChartStyle;
-import de.intevation.gnv.chart.VerticalCrossSectionChartFactory;
-import de.intevation.gnv.chart.exception.TechnicalChartException;
-import de.intevation.gnv.geobackend.base.Result;
-import de.intevation.gnv.statistics.Statistics;
-import de.intevation.gnv.statistics.VerticalProfileStatistics;
-import de.intevation.gnv.transition.describedata.KeyValueDescibeData;
-import de.intevation.gnv.transition.exception.TransitionException;
-import de.intevation.gnv.transition.timeseries.TimeSeriesOutputTransition;
-
-/**
- * @author Tim Englich <tim.englich@intevation.de>
- * 
- */
-public class VerticalCrossSectionOutputTransition extends TimeSeriesOutputTransition {
-
-    private static Logger log = Logger
-    .getLogger(VerticalCrossSectionOutputTransition.class);
-    
-    /**
-     * The UID of this Class
-     */
-    private static final long serialVersionUID = 3233620652465061860L;
-
-    /**
-     * Constructor
-     */
-    public VerticalCrossSectionOutputTransition() {
-        super();
-        super.domainLable = "Depth [m]";
-    }
-
-    @Override
-    protected Chart getChart(
-        ChartLabels  chartLables,
-        Collection   parameters,
-        Collection   measurements,
-        Collection   dates,
-        Collection   result,
-        Locale       locale,
-        String       uuid,
-        boolean      linesVisible,
-        boolean      shapesVisible
-    ) {
-        Chart chart = null;
-
-        if (CACHE_CHART) {
-            log.info("Try to get verticalcrosssection chart from cache.");
-            chart = (Chart) getChartFromCache(uuid);
-        }
-
-        if (chart != null)
-            return chart;
-
-        log.info("Chart not in cache yet.");
-        
-        log.warn("This sort of chart is not implemented yet.");
-        /* TODO Implement a special chart for this sort of charts.
-        chart = new VerticalProfileChart(
-            chartLables,
-            chartTheme,
-            parameters,
-            measurements,
-            result,
-            dates,
-            locale
-        );
-        chart.generateChart();
-
-        if (CACHE_CHART) {
-            log.info("Put chart into cache.");
-            purifyChart(chart, uuid);
-        }
-        */
-
-        return chart;
-    }
-
-    /**
-     * @see de.intevation.gnv.transition.timeseries.TimeSeriesOutputTransition#createChart(java.io.OutputStream,
-     *      java.util.Collection, java.util.Collection, java.lang.String,
-     *      de.intevation.gnv.chart.ChartStyle,
-     *      de.intevation.gnv.chart.ChartLabels)
-     */
-    /*
-    @Override
-    protected void createChart(OutputStream outputStream,
-                               Collection<KeyValueDescibeData> parameters,
-                               Collection<KeyValueDescibeData> measurements,
-                               Collection<KeyValueDescibeData> dates,
-                               ChartStyle chartStyle, ChartLabels chartLables,
-                               String uuid) throws IOException,
-                                           TechnicalChartException {
-        new VerticalCrossSectionChartFactory().createProfileChart(chartLables,
-                chartStyle, parameters, measurements, dates, outputStream, this
-                        .getChartResult(uuid));
-    }
-    */
-
-    /**
-     * @see de.intevation.gnv.transition.timeseries.TimeSeriesOutputTransition#getStatisticsGenerator()
-     */
-    @Override
-    protected Statistics getStatisticsGenerator() {
-        return new VerticalProfileStatistics();
-    }
-    
-    /**
-     * @see de.intevation.gnv.transition.timeseries.TimeSeriesOutputTransition#createCSV(java.io.OutputStream, java.util.Collection)
-     */
-    @Override
-    protected void createCSV(OutputStream outputStream,
-                             Collection<Result> chartResult)
-                                                            throws UnsupportedEncodingException,
-                                                            IOException,
-                                                            TransitionException {
-        if (chartResult != null) {
-            try {
-                CSVWriter writer = new CSVWriter(new OutputStreamWriter(
-                        outputStream, "ISO-8859-1"), ','); 
-                // USE THIS ENCODING BECAUSE OF
-                // PROBLEMS WITH EXCEL AND UTF-8
-                Iterator<Result> it = chartResult.iterator();
-                WKTReader wktReader = new WKTReader();
-                while (it.hasNext()) {
-                    Result result = it.next();
-                    int i = 0;
-                    String[] entries = new String[8];
-                    Point p = (Point)wktReader.read(result.getString("SHAPE"));
-                    entries[i++] = ""+p.getX();
-                    entries[i++] = ""+p.getY();
-                    entries[i++] = result.getString("YORDINATE");
-                    entries[i++] = result.getString("GROUP1");
-                    entries[i++] = result.getString("GROUP2");
-                    entries[i++] = result.getString("IPOSITION");
-                    entries[i++] = result.getString("JPOSITION");
-                    entries[i++] = result.getString("KPOSITION");
-                    writer.writeNext(entries);
-                }
-                writer.close();
-            } catch (ParseException e) {
-                log.error(e,e);
-                throw new TransitionException(
-                "Exception occured while parsing an Point from WKT.");
-            }
-        } else {
-            log.error("No Data given for generating an CSV-File.");
-            throw new TransitionException(
-                    "No Data given for generating an CSV-File.");
-        }
-    }
-
-}
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/transition/timeseries/TimeSeriesOutputTransition.java	Mon Dec 07 17:03:24 2009 +0000
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,835 +0,0 @@
-/**
- *
- */
-package de.intevation.gnv.transition.timeseries;
-
-import java.io.IOException;
-import java.io.File;
-import java.io.OutputStream;
-import java.io.FileOutputStream;
-import java.io.UnsupportedEncodingException;
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Locale;
-import java.util.Vector;
-
-import javax.xml.transform.Transformer;
-import javax.xml.transform.TransformerConfigurationException;
-import javax.xml.transform.TransformerException;
-import javax.xml.transform.TransformerFactory;
-import javax.xml.transform.TransformerFactoryConfigurationError;
-import javax.xml.transform.dom.DOMSource;
-import javax.xml.transform.stream.StreamResult;
-
-import org.apache.log4j.Logger;
-import org.w3c.dom.Document;
-import org.w3c.dom.Element;
-import org.w3c.dom.Node;
-import org.w3c.dom.NodeList;
-
-import org.jfree.chart.ChartTheme;
-
-import au.com.bytecode.opencsv.CSVWriter;
-import de.intevation.artifactdatabase.Config;
-import de.intevation.artifactdatabase.XMLUtils;
-import de.intevation.artifacts.CallMeta;
-import de.intevation.artifacts.PreferredLocale;
-import de.intevation.gnv.artifacts.ressource.RessourceFactory;
-import de.intevation.gnv.chart.Chart;
-import de.intevation.gnv.chart.ChartLabels;
-import de.intevation.gnv.chart.TimeSeriesChart;
-import de.intevation.gnv.chart.XMLChartTheme;
-import de.intevation.gnv.chart.exception.TechnicalChartException;
-import de.intevation.gnv.exports.ChartExportHelper;
-import de.intevation.gnv.exports.DefaultExport;
-import de.intevation.gnv.exports.DefaultDataCollector;
-import de.intevation.gnv.exports.SimpleOdvDataCollector;
-import de.intevation.gnv.exports.DefaultProfile;
-import de.intevation.gnv.exports.Export.Profile;
-import de.intevation.gnv.geobackend.base.Result;
-import de.intevation.gnv.statistics.Statistic;
-import de.intevation.gnv.statistics.StatisticSet;
-import de.intevation.gnv.statistics.Statistics;
-import de.intevation.gnv.statistics.TimeseriesStatistics;
-import de.intevation.gnv.statistics.exception.StatisticsException;
-import de.intevation.gnv.timeseries.gap.DefaultTimeGap;
-import de.intevation.gnv.timeseries.gap.TimeGap;
-import de.intevation.gnv.transition.InputData;
-import de.intevation.gnv.transition.OutputTransitionBase;
-import de.intevation.gnv.transition.describedata.KeyValueDescibeData;
-import de.intevation.gnv.transition.describedata.NamedCollection;
-import de.intevation.gnv.transition.exception.TransitionException;
-import de.intevation.gnv.utils.ArtifactXMLUtilities;
-
-
-/**
- * @author Tim Englich <tim.englich@intevation.de>
- * 
- */
-public class TimeSeriesOutputTransition extends OutputTransitionBase {
-
-    protected static final boolean CACHE_CHART =
-        Boolean.parseBoolean(System.getProperty("cache.chart", "false"));
-
-    protected static final boolean PDF_FORMAT_LANDSCAPE =
-        Boolean.parseBoolean(System.getProperty("export.pdf.landscape","true"));
-
-    protected static final String[] IMG_EXPORT_FORMAT = {
-        "PNG", "JPEG", "GIF"
-    };
-
-    /**
-     * The UID of this Class
-     */
-    private static final long serialVersionUID = 4178407570503098858L;
-
-    /**
-     * the logger, used to log exceptions and additonaly information
-     */
-    private static Logger log = Logger
-            .getLogger(TimeSeriesOutputTransition.class);
-
-    private static List<TimeGap> timeGapDefinitions = null;
-
-    protected String domainLable = "Zeit [UTC]";
-
-    protected String featureValuesName = "featureid";
-    protected String parameterValuesName = "parameterid";
-    protected String measuremenValueName = "measurementid";
-    protected String dateValueName = "dateid";
-    
-    public static final String [] TIMESERIES_CSV_PROFILE_NAMES = {
-        "XORDINATE",
-        "YORDINATE",
-        "GROUP1",
-        "GROUP2",
-        "GROUP3"
-    };
-    
-    public static final String [] TIMESERIES_ODV_PROFILE_NAMES = {
-          "CRUISE",
-          "STATION",
-          "TYPE",
-          "SHAPE",
-          "BOTDEPTH",
-          "DEPTH",
-          "TIMEVALUE",
-          "DATAVALUE",
-          "PARAMETER"
-    };
-
-
-    public static final String [] ODV_COLUMN_HEADER = {
-        "Cruise",
-        "Station",
-        "Type",
-        "Longitude [deegrees_east]",
-        "Latitude [deegrees_north]",
-        "Bot. Depth [m]",
-        "Depth [m]",
-        "Date/Time",
-        "Value",
-        "Parameterid"
-    };
-
-    /**
-     * Profile for exporting data to cvs
-     */
-    public static final Profile TIMESERIES_CSV_PROFILE =
-        new DefaultProfile(
-            null,
-            ',',
-            '"',
-            '"',
-            "CSV",
-            "ISO-8859-1");
-
-    /**
-     * Profile for exporting data to odv
-     * TODO Change TIMESERIES_PROFILE_NAMES, which belong to CSV exports
-     */
-    public static final Profile TIMESERIES_ODV_PROFILE =
-        new DefaultProfile(
-            ODV_COLUMN_HEADER,
-            '\t',
-            CSVWriter.NO_QUOTE_CHARACTER,
-            CSVWriter.NO_ESCAPE_CHARACTER,
-            "ODV",
-            "ISO-8859-1");
-
-    /**
-     * Constructor
-     */
-    public TimeSeriesOutputTransition() {
-        super();
-    }
-
-    /**
-     * @see de.intevation.gnv.transition.OutputTransition#out(java.lang.String,
-     *      java.util.Collection, java.io.OutputStream, java.lang.String,
-     *      de.intevation.artifacts.CallMeta)
-     */
-    public void out(
-        Document format,
-        Collection<InputData> inputData,
-        OutputStream outputStream,
-        String uuid,
-        CallMeta callMeta
-    ) throws TransitionException
-    {
-        log.debug("TimeSeriesOutputTransition.out");
-
-        String outputMode = Config.getStringXPath(
-            format,
-            "action/out/@name"
-        );
-        String mimeType   = Config.getStringXPath(
-            format,
-            "action/out/mime-type/@value"
-        );
-
-        try {
-            if (outputMode.equalsIgnoreCase("chart")) {
-                log.debug("Chart will be generated.");
-                int chartWidth = 600;
-                int chartHeight = 400;
-                try {
-                    if (inputData != null) {
-                        Iterator<InputData> it = inputData.iterator();
-                        while (it.hasNext()) {
-                            InputData ip = it.next();
-                            if (ip.getName().equalsIgnoreCase("width")) {
-                                chartWidth = Integer.parseInt(ip.getValue());
-                            } else if (ip.getName().equalsIgnoreCase("height")) {
-                                chartHeight = Integer.parseInt(ip.getValue());
-                            }
-                        }
-                    }
-                } catch (NumberFormatException e) {
-                    log.error(e, e);
-                    throw new TransitionException(e);
-                }
-
-                PreferredLocale[] locales = callMeta.getLanguages();
-                Locale[] serverLocales    =
-                    RessourceFactory.getInstance().getLocales();
-                Locale locale             =
-                    callMeta.getPreferredLocale(serverLocales);
-
-                log.debug(
-                    "Best locale - regarding intersection of server and " +
-                    "browser locales -  is " + locale.toString()
-                );
-
-                Collection parameters   = this.getCleanedParameters(uuid);
-                Collection measurements = this.getMeasurements(uuid);
-                Collection dates        = this.getDates(uuid);
-
-                ChartLabels chartLables = new ChartLabels(
-                    createChartTitle(locale, uuid),
-                    createChartSubtitle(locale, uuid),
-                    domainLable
-                );
-
-                String exportFormat = getExportFormat(mimeType);
-
-                // TODO Remove this and parse input data
-                boolean linesVisible = true;
-                boolean shapesVisible = true;
-
-                this.createChart(
-                    outputStream,
-                    parameters,
-                    measurements,
-                    dates,
-                    chartLables,
-                    uuid,
-                    exportFormat,
-                    locale,
-                    chartWidth,
-                    chartHeight,
-                    linesVisible,
-                    shapesVisible
-                );
-            }
-            else if (outputMode.equalsIgnoreCase("pdf")) {
-                log.debug("Output mode == pdf");
-
-                Locale[] serverLocales    =
-                    RessourceFactory.getInstance().getLocales();
-                Locale locale             =
-                    callMeta.getPreferredLocale(serverLocales);
-
-                // TODO Remove this and parse input data
-                boolean linesVisible = true;
-                boolean shapesVisible = true;
-
-                log.debug(
-                    "Best locale - regarding intersection of server and " +
-                    "browser locales -  is " + locale.toString()
-                );
-
-                createPDF(
-                    outputStream,
-                    getCleanedParameters(uuid),
-                    getMeasurements(uuid),
-                    getDates(uuid),
-                    new ChartLabels(
-                        createChartTitle(locale, uuid),
-                        createChartSubtitle(locale, uuid),
-                        domainLable),
-                    uuid,
-                    "A4",
-                    true,
-                    locale,
-                    linesVisible,
-                    shapesVisible
-                );
-            }
-            else if (outputMode.equalsIgnoreCase("svg")) {
-                log.debug("Output mode == svg");
-                int width  = 600;
-                int height = 400;
-
-                // TODO Remove this and parse input data
-                boolean linesVisible = true;
-                boolean shapesVisible = true;
-
-                Locale[] serverLocales    =
-                    RessourceFactory.getInstance().getLocales();
-                Locale locale             =
-                    callMeta.getPreferredLocale(serverLocales);
-
-                log.debug(
-                    "Best locale - regarding intersection of server and " +
-                    "browser locales -  is " + locale.toString()
-                );
-
-                createSVG(
-                    outputStream,
-                    getCleanedParameters(uuid),
-                    getMeasurements(uuid),
-                    getDates(uuid),
-                    new ChartLabels(
-                        createChartTitle(locale, uuid),
-                        createChartSubtitle(locale, uuid),
-                        domainLable
-                    ),
-                    uuid,
-                    locale,
-                    width,
-                    height,
-                    linesVisible,
-                    shapesVisible
-                );
-            }
-            else if (outputMode.equalsIgnoreCase("csv")) {
-                log.debug("CSV-File will be generated.");
-                Collection<Result> chartResult = this.getChartResult(uuid);
-                this.createCSV(outputStream, chartResult);
-            } else if (outputMode.equalsIgnoreCase("statistics")) {
-                log.debug("Statistics will be generated.");
-                Statistics s = getStatisticsGenerator();
-                Collection<Result> chartResult = this.getChartResult(uuid);
-                Collection<KeyValueDescibeData> parameters = 
-                                                this.getParameters(uuid);
-                Collection<KeyValueDescibeData> measurements = 
-                                                this.getMeasurements(uuid);
-                Collection<KeyValueDescibeData> dates = 
-                                                this.getDates(uuid);
-                Collection<StatisticSet> statistics = 
-                                      s.calculateStatistics(chartResult,
-                                                            parameters,
-                                                            measurements,
-                                                            dates);
-                Document doc = this.writeStatistics2XML(statistics);
-                this.writeDocument2OutputStream(doc, outputStream);
-            } else if (outputMode.equalsIgnoreCase("odv")) {
-                
-                Collection<Result> odvResult = this.getODVResult(uuid);
-                this.createODV(outputStream, odvResult);
-            }
-        } catch (IOException e) {
-            log.error(e, e);
-            throw new TransitionException(e);
-        } catch (TechnicalChartException e) {
-            log.error(e, e);
-            throw new TransitionException(e);
-        } catch (StatisticsException e) {
-            log.error(e, e);
-            throw new TransitionException(e);
-        }
-    }
-
-
-    protected String getExportFormat(String mime) {
-        for(int i = 0; i < IMG_EXPORT_FORMAT.length; i++) {
-            if (mime.trim().toUpperCase().indexOf(IMG_EXPORT_FORMAT[i]) > 0)
-                return IMG_EXPORT_FORMAT[i];
-        }
-
-        // no format found relating to mimeType, default export as PNG
-        return IMG_EXPORT_FORMAT[0];
-    }
-
-
-    protected Collection getCleanedParameters(Collection parameters) {
-        Iterator iter        = parameters.iterator();
-        Collection parameter = new Vector(parameters);
-        while (iter.hasNext()) {
-            KeyValueDescibeData data = (KeyValueDescibeData)iter.next();
-            if (!data.isSelected())
-                parameter.remove(data);
-        }
-
-        return parameter;
-    }
-
-
-    protected Collection getCleanedParameters(String uuid) {
-        return getCleanedParameters(getParameters(uuid));
-    }
-
-
-    /**
-     * @param outputStream
-     * @param chartResult
-     * @throws UnsupportedEncodingException
-     * @throws IOException
-     * @throws TransitionException
-     */
-    protected void createCSV(OutputStream outputStream,
-                            Collection<Result> chartResult)
-                                                          throws UnsupportedEncodingException,
-                                                          IOException,
-                                                          TransitionException {
-        DefaultExport export = new DefaultExport(new DefaultDataCollector(
-            TIMESERIES_CSV_PROFILE_NAMES));
-
-        export.create(TIMESERIES_CSV_PROFILE, outputStream, chartResult);
-    }
-
-    /**
-     * TODO Result is not used at the moment. Change result with correct data.
-     */
-    protected void createODV(OutputStream outputStream, Collection result)
-    throws IOException, TransitionException {
-
-        DefaultExport export = new DefaultExport(new SimpleOdvDataCollector(
-            TIMESERIES_ODV_PROFILE_NAMES));
-
-        if (result == null)
-            log.error("#################### RESULT == NULL #################");
-        export.create(TIMESERIES_ODV_PROFILE, outputStream, result);
-    }
-
-    /**
-     * @return
-     */
-    protected Statistics getStatisticsGenerator() {
-        Statistics s = new TimeseriesStatistics();
-        return s;
-    }
-
-    protected void writeDocument2OutputStream(Document document, OutputStream os) {
-
-        try {
-            TransformerFactory transformerFactory = TransformerFactory
-                    .newInstance();
-            Transformer transformer = transformerFactory.newTransformer();
-            DOMSource source = new DOMSource(document);
-            StreamResult result = new StreamResult(os);
-            transformer.transform(source, result);
-        } catch (TransformerConfigurationException e) {
-            log.error(e, e);
-        } catch (TransformerFactoryConfigurationError e) {
-            log.error(e, e);
-        } catch (TransformerException e) {
-            log.error(e, e);
-        }
-    }
-
-    protected Document writeStatistics2XML( Collection<StatisticSet> statistic) {
-        ArtifactXMLUtilities xmlUtilities = new ArtifactXMLUtilities();
-        Document doc = XMLUtils.newDocument();
-        if (statistic != null) {
-            Node statisticResults = xmlUtilities.createArtifactElement(doc,
-                    "statistics");
-            doc.appendChild(statisticResults);
-            Iterator<StatisticSet> it = statistic.iterator();
-            while (it.hasNext()) {
-                StatisticSet set = it.next();
-                Element setElement = xmlUtilities.createArtifactElement(doc,
-                                                                       "statistic");
-                setElement.setAttribute("name", set.getName());
-                
-                Iterator<Statistic> sit = set.getStatistics().iterator();
-                while (sit.hasNext()){
-                    Statistic s = sit.next();
-                    Element result = xmlUtilities.createArtifactElement(doc,
-                    "statistic-value");
-                    result.setAttribute("name", s.getKey());
-                    result.setAttribute("value", s.getStringValue());
-                    setElement.appendChild(result);
-                }
-                statisticResults.appendChild(setElement);
-            }
-
-        }
-        return doc;
-    }
-
-
-    protected String getSelectedFeatureName(String uuid) {
-        Collection values = getCollection(featureValuesName, uuid);
-
-        if (values != null) {
-            Iterator it = values.iterator();
-
-            while (it.hasNext()) {
-                KeyValueDescibeData data = (KeyValueDescibeData) it.next();
-
-                if (data.isSelected()) {
-                    return data.getValue();
-                }
-            }
-        }
-        return null;
-    }
-
-
-    /**
-     * @param outputStream
-     * @param parameters
-     * @param measurements
-     * @param timeSeriesName
-     * @param chartStyle
-     * @param chartLables
-     * @throws IOException
-     * @throws TechnicalChartException
-     */
-    protected void createChart(
-        OutputStream outputStream,
-        Collection   parameters,
-        Collection   measurements,
-        Collection   dates,
-        ChartLabels  chartLables,
-        String       uuid,
-        String       exportFormat,
-        Locale       locale,
-        int          width,
-        int          height,
-        boolean      linesVisible,
-        boolean      shapesVisible
-    )
-    throws IOException, TechnicalChartException
-    {
-        log.debug("Create chart.");
-        Chart chart = getChart(
-            chartLables,
-            parameters,
-            measurements,
-            dates,
-            getChartResult(uuid),
-            locale, // Locale
-            uuid,
-            linesVisible,
-            shapesVisible
-        );
-
-        if (chart == null) {
-            log.error("Could not initialize chart.");
-            return;
-        }
-
-        log.debug(
-            "export chart as " + exportFormat +
-            " in " + width + "x" + height
-        );
-
-        ChartExportHelper.exportImage(
-            outputStream,
-            chart.generateChart(),
-            exportFormat,
-            width,
-            height
-        );
-    }
-
-
-    protected void createPDF(
-        OutputStream outputStream,
-        Collection   parameters,
-        Collection   measurements,
-        Collection   dates,
-        ChartLabels  chartLables,
-        String       uuid,
-        String       exportFormat,
-        boolean      landscape,
-        Locale       locale,
-        boolean      linesVisible,
-        boolean      shapesVisible
-    ) {
-        Chart chart = getChart(
-            chartLables,
-            parameters,
-            measurements,
-            dates,
-            getChartResult(uuid),
-            locale,
-            uuid,
-            linesVisible,
-            shapesVisible
-        );
-
-        if (chart == null) {
-            log.error("Could not initialize chart.");
-            return;
-        }
-
-        ChartExportHelper.exportPDF(
-            outputStream,
-            chart.generateChart(),
-            "A4",
-            PDF_FORMAT_LANDSCAPE,
-            50F, 50F, 50F, 50F
-        );
-
-        try {
-            OutputStream toFile = new FileOutputStream("/vol1/home/iweinzierl/tmp/test.svg");
-            ChartExportHelper.exportSVG(
-                toFile,
-                chart.generateChart(),
-                null,
-                600, 400
-            );
-            toFile.flush();
-            toFile.close();
-        }
-        catch(Exception e) { log.debug("ERROR WHLILE TEST."); }
-    }
-
-
-    protected void createSVG(
-        OutputStream outputStream,
-        Collection   parameters,
-        Collection   measurements,
-        Collection   dates,
-        ChartLabels  chartLables,
-        String       uuid,
-        Locale       locale,
-        int          width,
-        int          height,
-        boolean      linesVisible,
-        boolean      shapesVisible
-    ) {
-        Chart chart = getChart(
-            chartLables,
-            parameters,
-            measurements,
-            dates,
-            getChartResult(uuid),
-            locale,
-            uuid,
-            linesVisible,
-            shapesVisible
-        );
-
-        if (chart == null) {
-            log.error("Could not initialize chart.");
-            return;
-        }
-
-        ChartExportHelper.exportSVG(
-            outputStream,
-            chart.generateChart(),
-            null,
-            600, 400
-        );
-
-        log.debug("svg export finished.");
-    }
-
-
-    protected Chart getChart(
-        ChartLabels  chartLables,
-        Collection   parameters,
-        Collection   measurements,
-        Collection   dates,
-        Collection   result,
-        Locale       locale,
-        String       uuid,
-        boolean      linesVisible,
-        boolean      shapesVisible
-    ) {
-        Chart chart = null;
-
-        if (CACHE_CHART) {
-            log.info("Try to get timeseries chart from cache.");
-            chart = (Chart) getChartFromCache(uuid);
-        }
-
-        if (chart != null)
-            return chart;
-
-        log.info("Chart not in cache yet.");
-        chart = new TimeSeriesChart(
-            chartLables,
-            createStyle(),
-            parameters,
-            measurements,
-            dates,
-            result,
-            timeGapDefinitions,
-            locale,
-            linesVisible,
-            shapesVisible
-        );
-        chart.generateChart();
-
-        if (CACHE_CHART) {
-            log.info("Put chart into cache.");
-            purifyChart(chart, uuid);
-        }
-
-        return chart;
-    }
-
-    protected ChartTheme createStyle() {
-        XMLChartTheme theme = null;
-
-        Document template = Config.getChartTemplate();
-        String   name     = Config.getStringXPath(
-            template,
-            "theme/name/@value"
-        );
-
-        theme  = new XMLChartTheme(name);
-        theme.applyXMLConfiguration(template);
-
-        return theme;
-    }
-
-
-    protected String createChartTitle(Locale locale, String uuid) {
-        return getFisName(locale);
-
-    }
-
-
-    protected String createChartSubtitle(Locale locale, String uuid) {
-        return getSelectedFeatureName(uuid);
-    }
-
-
-    protected String getFisName(Locale locale) {
-        String    returnValue = "";
-        InputData input       = inputData.get("fisname");
-
-        if (input != null) {
-            String value = input.getValue();
-
-            returnValue = RessourceFactory.getInstance().getRessource(
-                locale,
-                value,
-                value
-            );
-        }
-        return returnValue;
-    }
-
-
-    protected Collection<KeyValueDescibeData> getParameters(String uuid) {
-        return this.getCollection(parameterValuesName, uuid);
-    }
-
-    protected Collection<KeyValueDescibeData> getMeasurements(String uuid) {
-        return this.getCollection(measuremenValueName, uuid);
-    }
-    protected Collection<KeyValueDescibeData> getDates(String uuid) {
-        return this.getCollection(dateValueName,uuid);
-    }
-
-    @Override
-    public void setup(Node configuration) {
-        super.setup(configuration);
-        String featureNameValue = Config.getStringXPath(configuration,
-                "value-names/value-name[@name='feature']/@value");
-        if (featureNameValue != null) {
-            this.featureValuesName = featureNameValue;
-        }
-        String parameterNameValue = Config.getStringXPath(configuration,
-                "value-names/value-name[@name='parameter']/@value");
-        if (parameterNameValue != null) {
-            this.parameterValuesName = parameterNameValue;
-        }
-        String measurementNameValue = Config.getStringXPath(configuration,
-                "value-names/value-name[@name='measurement']/@value");
-        if (measurementNameValue != null) {
-            this.measuremenValueName = measurementNameValue;
-        }
-        
-        String dateNameValue = Config.getStringXPath(configuration,
-        "value-names/value-name[@name='date']/@value");
-        if (dateNameValue != null) {
-            this.dateValueName = dateNameValue;
-        }
-        if (timeGapDefinitions == null){
-            Element gapDefinition =  (Element)Config.getNodeXPath(configuration,
-                                                                 "time-gap-definition");
-            synchronized (this.getClass()) {
-                if (gapDefinition != null){
-                    String link = gapDefinition.getAttribute("xlink:href");
-                    if (link != null ){
-                        String absolutFileName = Config.replaceConfigDir(link);
-                        gapDefinition = (Element)new ArtifactXMLUtilities().
-                                                     readConfiguration(absolutFileName);
-                    }
-                    
-                    NodeList gapDefinitions = Config.getNodeSetXPath(gapDefinition, 
-                                                                    "/time-gaps/time-gap");
-                    if (gapDefinition != null){
-                        timeGapDefinitions = new ArrayList<TimeGap>(gapDefinitions.
-                                                                    getLength());
-                        for (int i = 0; i < gapDefinitions.getLength(); i++){
-                            Element gapNode = (Element)gapDefinitions.item(i);
-                            String unit = gapNode.getAttribute("unit");
-                            int key = Integer.parseInt(gapNode.getAttribute("key"));
-                            int value = Integer.parseInt(gapNode.getAttribute("gap"));
-                            log.info("Add new Timegap: "+key+" "+value+" "+ unit);
-                            timeGapDefinitions.add(new DefaultTimeGap(unit, 
-                                                                      key, 
-                                                                      value));
-                        }
-                    }
-                    
-                }
-            }
-        }
-    }
-    
-    /**
-     * @param collectionName
-     * @return
-     */
-    protected Collection<KeyValueDescibeData> getCollection(
-                                                            String collectionName, 
-                                                            String uuid) {
-        Iterator<Object> it = this.getDescibeData(uuid).iterator();
-        while (it.hasNext()) {
-
-            Object o = it.next();
-
-            if (o instanceof NamedCollection<?>) {
-                NamedCollection<KeyValueDescibeData> nc = (NamedCollection<KeyValueDescibeData>) o;
-                if (nc.getName().equals(collectionName)) {
-                    return nc;
-                }
-            }
-        }
-        return null;
-    }
-}
-// vim:set ts=4 sw=4 si et sta sts=4 fenc=utf-8 :
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/utils/ArtifactXMLUtilities.java	Mon Dec 07 17:03:24 2009 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/utils/ArtifactXMLUtilities.java	Tue Dec 08 08:39:03 2009 +0000
@@ -28,7 +28,6 @@
 import org.xml.sax.SAXException;
 
 import de.intevation.artifacts.ArtifactNamespaceContext;
-import de.intevation.gnv.transition.timeseries.TimeSeriesOutputTransition;
 
 /**
  * @author Tim Englich <tim.englich@intevation.de>
@@ -44,7 +43,7 @@
      * the logger, used to log exceptions and additonaly information
      */
     private static Logger log = Logger
-            .getLogger(TimeSeriesOutputTransition.class);
+            .getLogger(ArtifactXMLUtilities.class);
 
     public static final String XFORM_URL = "http://www.w3.org/2002/xforms";
     public static final String XFORM_PREFIX = "xform";
--- a/gnv-artifacts/src/test/ressources/horizontalProfile_mesh/horizontalprofile_step_10_feed.xml	Mon Dec 07 17:03:24 2009 +0000
+++ b/gnv-artifacts/src/test/ressources/horizontalProfile_mesh/horizontalprofile_step_10_feed.xml	Tue Dec 08 08:39:03 2009 +0000
@@ -4,7 +4,7 @@
 	<art:uuid value="1f6a63e2-c9d6-4ab1-830e-1effbc189d68" />
 	<art:hash value="29647319" />
 	<art:data>
-		<art:input name="dateid" value="2009.11.27 00:00:00" />
-		<art:input name="dateid" value="2009.11.26 00:00:00" />
+		<art:input name="dateid" value="2009.11.29 00:00:00" />
+		<art:input name="dateid" value="2009.11.30 00:00:00" />
 	</art:data>
 </art:action>
\ No newline at end of file
--- a/gnv-artifacts/src/test/ressources/timeseries_mesh/timeseries_step_08_feed.xml	Mon Dec 07 17:03:24 2009 +0000
+++ b/gnv-artifacts/src/test/ressources/timeseries_mesh/timeseries_step_08_feed.xml	Tue Dec 08 08:39:03 2009 +0000
@@ -4,7 +4,7 @@
 	<art:uuid value="1e9f6583-9073-4409-aac1-432ad06d7ce1" />
 	<art:hash value="29913235" />
 	<art:data>
-		<art:input name="maxvalue" value="2009.11.27 00:00:00" />
-		<art:input name="minvalue" value="2009.11.17 01:00:00" />
+		<art:input name="maxvalue" value="2009.12.10 00:00:00" />
+		<art:input name="minvalue" value="2009.11.29 01:00:00" />
 	</art:data>
 </art:action>
\ No newline at end of file
--- a/gnv-artifacts/src/test/ressources/verticalcrosssection_mesh/verticalcrosssection_step_07_feed.xml	Mon Dec 07 17:03:24 2009 +0000
+++ b/gnv-artifacts/src/test/ressources/verticalcrosssection_mesh/verticalcrosssection_step_07_feed.xml	Tue Dec 08 08:39:03 2009 +0000
@@ -4,6 +4,6 @@
     <art:uuid value="07807bb4-572b-4a46-a71d-7c1c8c9ab50c" />
     <art:hash value="2969645" />
     <art:data>
-        <art:input name="parameterid" value="2" />
+        <art:input name="parameterid" value="1" />
     </art:data>
 </art:action>
\ No newline at end of file
--- a/gnv-artifacts/src/test/ressources/verticalcrosssection_mesh/verticalcrosssection_step_08_feed.xml	Mon Dec 07 17:03:24 2009 +0000
+++ b/gnv-artifacts/src/test/ressources/verticalcrosssection_mesh/verticalcrosssection_step_08_feed.xml	Tue Dec 08 08:39:03 2009 +0000
@@ -4,6 +4,6 @@
 	<art:uuid value="07807bb4-572b-4a46-a71d-7c1c8c9ab50c" />
 	<art:hash value="2969645" />
 	<art:data>
-		<art:input name="dateid" value="2009.11.27 00:00:00" />
+		<art:input name="dateid" value="2009.12.10 00:00:00" />
 	</art:data>
 </art:action>
\ No newline at end of file
--- a/gnv-artifacts/src/test/ressources/verticalprofile_mesh/verticalprofile_step_10_feed.xml	Mon Dec 07 17:03:24 2009 +0000
+++ b/gnv-artifacts/src/test/ressources/verticalprofile_mesh/verticalprofile_step_10_feed.xml	Tue Dec 08 08:39:03 2009 +0000
@@ -4,7 +4,7 @@
     <art:uuid value="73da18e1-16ef-4ef8-9388-df07a22d9099" />
     <art:hash value="3061481" />
 	<art:data>
-		<art:input name="dateid" value="2009.11.27 00:00:00" />
-        <art:input name="dateid" value="2009.11.26 00:00:00" />
+		<art:input name="dateid" value="2009.11.29 00:00:00" />
+        <art:input name="dateid" value="2009.11.30 00:00:00" />
 	</art:data>
 </art:action>
\ No newline at end of file

http://dive4elements.wald.intevation.org