diff doc/config-manual/model_of_transitions.tex @ 908:babeef4f8480

Added description fpr Configuration of Products, States and Transitions doc/trunk@1042 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author Tim Englich <tim.englich@intevation.de>
date Mon, 03 May 2010 12:35:48 +0000
parents 29a675796e76
children fcde68463722
line wrap: on
line diff
--- a/doc/config-manual/model_of_transitions.tex	Fri Apr 30 12:18:47 2010 +0000
+++ b/doc/config-manual/model_of_transitions.tex	Mon May 03 12:35:48 2010 +0000
@@ -1,19 +1,27 @@
 \section{Model of transitions}
 \subsection{General principle of model of transitions}
         - FIS -> product -> transitions in data model
-The configuration of the provided FIS are devided in three parts.
 
-* Configuration of the Artifactfactories which represents the FIS.
-* Configuration of main Artifacts which will be instantiated if an 
+It is possible to configure the GNV in many ways.
+It is possible to add or remove FIS, add or remove Products from a FIS or
+to manipulate the steps which must be gone until a product can be create
+a diagramm or generate an CSV-Export.
+
+The configuration of the provided FIS are devided in three main parts.
+
+\begin{itemize}
+    \item Configuration of the Artifactfactories which represents the FIS.
+    \item Configuration of main Artifacts which will be instantiated if an 
   Artifactfactory was called.
-* Configuration of the different Artifacts which provides Products which can be 
+    \item Configuration of the different Artifacts which provides Products which can be 
   served by the FIS.
+\end{itemize}
 
 \subsubsection{Configuration of ArtifactFactories}
 The Point of Enty into the system is to configure an Artifactfactory.
 Each Artifactfactory represents one FIS.
 It is possible to configure several Artifactfactories.
-The Artifactfactories will be vonfigured in the Section 
+The Artifactfactories will be configured in the Section 
 /artifact-database/artifact-factories of the Configurationfile.
 
 \begin{lstlisting}
@@ -26,19 +34,21 @@
 \end{lstlisting}
 
 At this moment the following Attributes of an Artifact-Factory are configurabel.
-* name: The Name of the Artifact. Must be unique in one Artifact-Server
-* description: Short description which Job the Artifactfactory has to do.
-* ttl: The Time to Live: The Time using Milliseconds an Artifact created by this 
-       factory can live without any Userinteraction.
-* artifact: The Name of the Class of the Artifact which should be created.
+\begin{itemize}
+    \item name: The Name of the Artifact. Must be unique in one Artifact-Server
+    \item description: Short description which Job the Artifactfactory has to do.
+    \item  ttl: The Time to Live: The Time using Milliseconds an Artifact, created using this 
+                factory, can live without any Userinteraction.
+    \item artifact: The Name of the Class of the Artifact which should be created.
+\end{itemize}
 
 // TODO: List of Artifacts which currently used in this Configuration? 
 
 \subsubsection{Configuration of main Artifact}
-To each Artifact-Factory it is necessary to configure one Artifact which will be 
-created from the Factory.
+For each Artifact-Factory it is necessary to configure one Artifact which will be 
+created using the Factory.
 This Artifact is the representation of the specific FIS.
-It contains the Configuration which product will be serverd for ths FIS.
+It contains the Configuration which products will be serverd for ths FIS.
 
 The Artifacts are configured in the Section /artifact-database/artifacts of 
 the Configurationfile.
@@ -78,7 +88,7 @@
  </product>
  \end{lstlisting}
 
-Each Product is represented by an Artifact. To create this Artifact we have to 
+Each Product is also represented by an Artifact. To create this Artifact we have to 
 use an Artifact-Factory which is configured in each product 
 (/product/artifact-factory).
 
@@ -92,16 +102,94 @@
 
 
 \subsubsection{Configuration of the Product-Artifacts}
+The Products of the different FIS are also modeled as Artifact-Objects.
+The different Products which are currently avaliable are stored in separate
+Files in the Folder project.
+
+In those Files the Workflow of each product is configured.  Each step which is
+required to model a new Diagramm is represented using a state in the
+Configuration-File.
+
+To move between those States it is required to model Transitions which define
+between which States it is possible to move and which conditions must be
+fulfilled.
+
+The Last step is called OutputState. This State is responsible to generate the
+output for the different Formats which can be served from the Product (Diagramm,
+CSV, ODV, WMS,...).
+
 \paragraph{States}
+A state is one Step which is required to fetch the Data for generating e.g. an
+Diagramm.
+
+For example in each Product it is Possible to choose one or more Parameters.
+
+To configure a State you have to use a XML-Fragment as shown below:
+
+\begin{lstlisting}
+<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>
+   <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>
+</state>
+\end{lstlisting}
+
+At this moment the following Attributes of an Artifact-Factory are configurabel.
+\begin{itemize}
+    \item id: The Name of the Artifact. Must be unique in one Artifact-Server
+    \item description: Short description which Job the Artifactfactory has to do.
+    \item queryID: The ID of the Query which should be used to fetch the Data 
+                   displayed in this state. //TODO: Reference to queries.properties
+    \item dataname: The ID of the Data which will be displaied in this State.
+                    The ID will be use to localize the description of the Data.
+    \item data-multiselect: true it is possible to select 1 or more Items.
+                            false ist is possible to select only one Item.
+    \item inputvalues: The Values which can be "feed" //TODO: How to explain this
+                       to this State.
+ \end{itemize}
+
+
 \paragraph{Transitions}
+
+To move between two States it is necessary to configure dependencies between
+the different States.
+This dependencies are called. Transitions.
+
+There are different Kind of Transitions which can be used.
+\begin{itemize}
+  \item Transitions which only link two States
+  \item Transition which link two States with a aditional Condition. 
+        (e.g. If a region was selected in the Regionfilter or not )
+\end{itemize}
+
+The listing below shows a Transition with an additional Condition.
+\begin{lstlisting}
+<transition transition="de.intevation.gnv.transition.ValueCompareTransition">
+    <from state="timeseries_area"/>
+    <to state="timeseries_without_geom"/>
+    <condition inputvalue="areaid" value="n/n" operator="equal"/>
+</transition>
+\end{lstlisting}
+
+\begin{itemize}
+  \item from: The ID of the State which you have to come from
+  \item to:   The ID of the State which can be reached.
+  \item condition: The Condition which have to be fulfilled.
+\end{itemize}
+
 \paragraph{Outputstate}
 
 
 \subsection{Adding a new FIS}
-In this Section it will explained which steps has to be done to integrate a new 
-FIS into the Artifact-Server.
-This will be done using the Configuration for an FIS which use data from 
-MEDIAN.TIMESERIES Section of the DataWareHouse e.g. MARNET or STAUN
+In this Section it will be explained which steps has to be done to integrate a
+new FIS into the Artifact-Server.  This will be done using the Configuration for
+an FIS which use data from MEDIAN.TIMESERIES Section of the DataWareHouse e.g.
+MARNET or STAUN
 
 Pay attention that for publishing the Changes to the Artifact-Server you will 
 have to restart it. 
@@ -183,7 +271,7 @@
 </artifact>
 \end{lstlisting}
 
-In this XML Fragment you have to replace the placeholders NEWFISNAME as before 
+In this XML-Fragment you have to replace the placeholders NEWFISNAME as before 
 and VALUEOFSOURCEID with the value for the new FIS as defined in the Table 
 MEDIAN.SOURCEINFO.
 
@@ -194,7 +282,7 @@
 Without doing that step it is not possible to create a new Product.
 
 All Products are configured in separate Files that will be included into the 
-Mainconfiguration using Xlink-references.
+Mainconfiguration using Xlink-References.
 
 First Step is to create a new File in the Folder products and there in the 
 subfolder where the Product belongs to (timeseries,verticalprofile,

http://dive4elements.wald.intevation.org