changeset 2137:04b6b6a4564d

Prepare improved hyk-handling. flys-artifacts/trunk@3715 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author Felix Wolfsteller <felix.wolfsteller@intevation.de>
date Thu, 19 Jan 2012 10:51:20 +0000
parents 3a5ef4ac8e0f
children 59bb5c895be3
files flys-artifacts/ChangeLog flys-artifacts/src/main/java/de/intevation/flys/artifacts/model/HYKFactory.java
diffstat 2 files changed, 20 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/flys-artifacts/ChangeLog	Wed Jan 18 16:54:09 2012 +0000
+++ b/flys-artifacts/ChangeLog	Thu Jan 19 10:51:20 2012 +0000
@@ -1,3 +1,11 @@
+2012-01-19	Felix Wolfsteller	<felix.wolfsteller@intevation.de>
+
+	Preparing improved HYK handling.
+
+	* src/main/java/de/intevation/flys/artifacts/model/HYKFactory.java:
+	  (Zone.getTo): New accesor.
+	  TODOs and documentation added.
+
 2012-01-18  Raimund Renkert <raimund.renkert@intevation.de>
 
 	'New Chart' for w-differences curve.
--- a/flys-artifacts/src/main/java/de/intevation/flys/artifacts/model/HYKFactory.java	Wed Jan 18 16:54:09 2012 +0000
+++ b/flys-artifacts/src/main/java/de/intevation/flys/artifacts/model/HYKFactory.java	Thu Jan 19 10:51:20 2012 +0000
@@ -76,6 +76,8 @@
      * @param wst_id database id of the wst
      * @return according WKms.
      */
+    // TODO we also need to know the HYK-id to specify which set we are
+    //      inspecting.
     public static List<Zone> getZonesUncached(int riverId, double km) {
 
         if (logger.isDebugEnabled()) {
@@ -83,6 +85,9 @@
         }
 
         Session session = SessionHolder.HOLDER.get();
+
+        // TODO respect interval better. respect multiples (sort, limit),
+        // TODO respect flow direction of river.
         Query query = session.createQuery(
             "from HYKFormation where entry.HYK.river.id = :riverid " +
             " and entry.km between " +
@@ -127,10 +132,17 @@
             this.name = name;
         }
 
+        /** Get upper value. */
+        public double getTo() {
+            return to;
+        }
+
+        /** Get lower value. */
         public double getFrom() {
             return from;
         }
 
+        /** Get name (type). */
         public String getName() {
             return name;
         }

http://dive4elements.wald.intevation.org