changeset 5730:4ce126aa130c

FixRealizingCompute: Add one FixEventFacet per selected Event.
author Felix Wolfsteller <felix.wolfsteller@intevation.de>
date Tue, 16 Apr 2013 12:42:54 +0200
parents 187762f5e905
children 0152d639d7a7
files flys-artifacts/src/main/java/de/intevation/flys/artifacts/states/fixation/FixRealizingCompute.java
diffstat 1 files changed, 9 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/flys-artifacts/src/main/java/de/intevation/flys/artifacts/states/fixation/FixRealizingCompute.java	Tue Apr 16 12:41:02 2013 +0200
+++ b/flys-artifacts/src/main/java/de/intevation/flys/artifacts/states/fixation/FixRealizingCompute.java	Tue Apr 16 12:42:54 2013 +0200
@@ -16,9 +16,11 @@
 import de.intevation.flys.artifacts.model.ReportFacet;
 import de.intevation.flys.artifacts.model.WQCKms;
 import de.intevation.flys.artifacts.model.WQKms;
+import de.intevation.flys.artifacts.model.WQKmsFactory;
 import de.intevation.flys.artifacts.model.fixings.FixOutlierFacet;
 import de.intevation.flys.artifacts.model.fixings.FixRealizingCalculation;
 import de.intevation.flys.artifacts.model.fixings.FixRealizingResult;
+import de.intevation.flys.artifacts.model.fixings.FixEventFacet;
 import de.intevation.flys.artifacts.model.fixings.FixReferenceEventsFacet;
 import de.intevation.flys.artifacts.model.fixings.FixWQCurveFacet;
 import de.intevation.flys.artifacts.model.fixings.FixWaterlevelFacet;
@@ -122,6 +124,13 @@
             }
         }
 
+        // Add one facet per event.
+        int i = 0;
+        for (int event: access.getEvents()) {
+            facets.add(new FixEventFacet(i, FIX_EVENTS, WQKmsFactory.getWQKmsName(event)));
+            i++;
+        }
+
         if (wqkms.length > 0) {
             facets.add(
                 new DataFacet(CSV, "CSV data", ComputeType.ADVANCE, hash, id));

http://dive4elements.wald.intevation.org