diff flys-backend/src/main/java/de/intevation/flys/importer/ImportSQRelationValue.java @ 3328:a41f279a66e2

Added parser and import classes to import MINFO sq relations. flys-backend/trunk@4646 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author Ingo Weinzierl <ingo.weinzierl@intevation.de>
date Wed, 13 Jun 2012 06:22:04 +0000
parents
children cc8fc6b29649
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/flys-backend/src/main/java/de/intevation/flys/importer/ImportSQRelationValue.java	Wed Jun 13 06:22:04 2012 +0000
@@ -0,0 +1,64 @@
+package de.intevation.flys.importer;
+
+import java.sql.SQLException;
+
+import org.apache.log4j.Logger;
+
+import org.hibernate.exception.ConstraintViolationException;
+
+import de.intevation.flys.model.SQRelation;
+import de.intevation.flys.model.SQRelationValue;
+
+
+public class ImportSQRelationValue {
+
+    private static Logger log = Logger.getLogger(ImportSQRelationValue.class);
+
+
+    private SQRelationValue peer;
+
+    private String parameter;
+    private String fraction;
+    private String function;
+
+    private double km;
+    private double a;
+    private double b;
+
+
+    public ImportSQRelationValue(
+        String parameter,
+        String fraction,
+        String function,
+        double km,
+        double a,
+        double b
+    ) {
+        this.parameter = parameter;
+        this.fraction  = fraction;
+        this.function  = function;
+        this.km        = km;
+        this.a         = a;
+        this.b         = b;
+    }
+
+
+    public void storeDependencies(SQRelation owner)
+    throws SQLException, ConstraintViolationException
+    {
+        log.info("store dependencies");
+        log.warn("TODO: IMPLEMENT 'storeDependencies()'");
+    }
+
+
+    public SQRelationValue getPeer() {
+        log.debug("getPeer()");
+
+        if (peer == null) {
+            // TODO
+        }
+
+        return peer;
+    }
+}
+// vim:set ts=4 sw=4 si et sta sts=4 fenc=utf8 :

http://dive4elements.wald.intevation.org