changeset 1770:e8a98eee816d

Cosmetics, documentation. flys-artifacts/trunk@3091 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author Felix Wolfsteller <felix.wolfsteller@intevation.de>
date Wed, 26 Oct 2011 12:55:32 +0000
parents bbe12d77710d
children c62ff9e72cea
files flys-artifacts/ChangeLog flys-artifacts/src/main/java/de/intevation/flys/artifacts/states/WaterlevelState.java flys-artifacts/src/main/java/de/intevation/flys/collections/OutputParser.java
diffstat 3 files changed, 22 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/flys-artifacts/ChangeLog	Wed Oct 26 12:54:22 2011 +0000
+++ b/flys-artifacts/ChangeLog	Wed Oct 26 12:55:32 2011 +0000
@@ -1,3 +1,9 @@
+2011-10-26	Felix Wolfsteller	<felix.wolfsteller@intevation.de>
+
+	* src/main/java/de/intevation/flys/artifacts/states/WaterlevelState.java,
+	  src/main/java/de/intevation/flys/collections/OutputParser.java:
+	  Cosmetics, documentation.
+
 2011-10-26	Felix Wolfsteller	<felix.wolfsteller@intevation.de>
 
 	* src/main/java/de/intevation/flys/exports/LongitudinalSectionGenerator.java:
--- a/flys-artifacts/src/main/java/de/intevation/flys/artifacts/states/WaterlevelState.java	Wed Oct 26 12:54:22 2011 +0000
+++ b/flys-artifacts/src/main/java/de/intevation/flys/artifacts/states/WaterlevelState.java	Wed Oct 26 12:55:32 2011 +0000
@@ -29,6 +29,9 @@
     private static Logger logger = Logger.getLogger(WaterlevelState.class);
 
 
+    /**
+     * From this state can only be continued trivially.
+     */
     @Override
     protected String getUIProvider() {
         return "continue";
--- a/flys-artifacts/src/main/java/de/intevation/flys/collections/OutputParser.java	Wed Oct 26 12:54:22 2011 +0000
+++ b/flys-artifacts/src/main/java/de/intevation/flys/collections/OutputParser.java	Wed Oct 26 12:55:32 2011 +0000
@@ -22,11 +22,10 @@
 
 public class OutputParser {
 
-    /** Constant XPath that points to the outputmodes of an artifact.*/
+    /** Constant XPath that points to the outputmodes of an artifact. */
     public static final String XPATH_ARTIFACT_OUTPUTMODES =
         "/art:result/art:outputmodes/art:output";
 
-
     private static Logger logger = Logger.getLogger(OutputParser.class);
 
     protected ArtifactDatabase db;
@@ -36,6 +35,9 @@
     protected Map<String, Output> outs;
 
 
+    /**
+     * @param db Database used to fetch artifacts, outputs and facets.
+     */
     public OutputParser(ArtifactDatabase db, CallContext context) {
         this.db      = db;
         this.meta    = context.getMeta();
@@ -44,6 +46,11 @@
     }
 
 
+    /**
+     * Gets raw facet with given id and sorts outputs in mapping.
+     * Converts Facets to ManagedFacets on the way.
+     * @param uuid uuid of artifact to load from database.
+     */
     public void parse(String uuid)
     throws ArtifactDatabaseException
     {
@@ -66,10 +73,10 @@
                     out.getMimeType(),
                     new ArrayList<Facet>(),
                     out.getType());
-
                 outs.put(name, o);
             }
             else {
+                logger.debug("OutputParser.parse: Use 'old' Output");
                 pos = o.getFacets().size() + 1;
             }
 
@@ -79,6 +86,9 @@
     }
 
 
+    /**
+     * Access mapping of Outputname to Output.
+     */
     public Map<String, Output> getOuts() {
         return outs;
     }

http://dive4elements.wald.intevation.org