changeset 1763:0e748e8972b5

Cosmetics, docs. flys-artifacts/trunk@3079 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author Felix Wolfsteller <felix.wolfsteller@intevation.de>
date Wed, 26 Oct 2011 08:15:24 +0000
parents c85a84d60f68
children 87c82499b98f
files flys-artifacts/ChangeLog flys-artifacts/src/main/java/de/intevation/flys/artifacts/FLYSArtifact.java
diffstat 2 files changed, 32 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/flys-artifacts/ChangeLog	Tue Oct 25 14:41:34 2011 +0000
+++ b/flys-artifacts/ChangeLog	Wed Oct 26 08:15:24 2011 +0000
@@ -1,3 +1,8 @@
+2011-10-25  Felix Wolfsteller	<felix.wolfsteller@intevation.de>
+
+	* src/main/java/de/intevation/flys/artifacts/FLYSArtifact.java:
+	  Cosmetics, docs.
+
 2011-10-25  Felix Wolfsteller	<felix.wolfsteller@intevation.de>
 
 	Let Qs in Longitudinal Diagram be inactive, initally.
--- a/flys-artifacts/src/main/java/de/intevation/flys/artifacts/FLYSArtifact.java	Tue Oct 25 14:41:34 2011 +0000
+++ b/flys-artifacts/src/main/java/de/intevation/flys/artifacts/FLYSArtifact.java	Wed Oct 26 08:15:24 2011 +0000
@@ -63,7 +63,6 @@
     /** The logger that is used in this artifact. */
     private static Logger logger = Logger.getLogger(FLYSArtifact.class);
 
-
     public static final String COMPUTING_CACHE = "computed.values";
 
     /** The XPath that points to the input data elements of the FEED document. */
@@ -192,10 +191,12 @@
         filterFacets = buildFilterFacets(data);
     }
 
+
     protected List<String> clonePreviousStateIds() {
         return new ArrayList<String>(previousStateIds);
     }
 
+
     protected Map<String, StateData> cloneData() {
         Map<String, StateData> copy = new TreeMap<String, StateData>();
 
@@ -206,6 +207,10 @@
         return copy;
     }
 
+    /**
+     * Return a copy of the facet mapping.
+     * @return Mapping of outputnames to facets.
+     */
     protected Map<String, List<Facet>> cloneFacets() {
         Map copy = new HashMap<String, List<Facet>>();
 
@@ -221,6 +226,7 @@
         return copy;
     }
 
+
     protected void initialize(
         Artifact artifact,
         Object   context,
@@ -521,10 +527,17 @@
         return data != null ? (String) data.getValue() : null;
     }
 
+
+    /**
+     * Add StateData containing a given string.
+     * @param name Name of the data object.
+     * @param value String to store.
+     */
     public void addStringData(String name, String value) {
         addData(name, new DefaultStateData(name, null, null, value));
     }
 
+
     public Collection<StateData> getAllData() {
         return data.values();
     }
@@ -671,7 +684,9 @@
 
 
     /**
-     * Return List.
+     * Return List of outputs, where combinations of outputname and filtername
+     * that match content in filterFacets is left out.
+     * @return filtered Outputlist.
      */
     protected List<Output> filterOutputs(List<Output> outs) {
 
@@ -760,6 +775,13 @@
     }
 
 
+    /**
+     * Generate a list of outputs with facets from fs if type is found in list
+     * of output.
+     *
+     * @param list List of outputs
+     * @param fs List of facets
+     */
     protected List<Output> generateOutputs(List<Output> list, List<Facet> fs) {
         List<Output> generated = new ArrayList<Output>();
 
@@ -978,6 +1000,9 @@
     }
 
 
+    /**
+     * Destroy the states.
+     */
     @Override
     public void endOfLife(Object context) {
         logger.info("FLYSArtifact.endOfLife: " + identifier());

http://dive4elements.wald.intevation.org