changeset 3876:c0a15547ad76

Use generics aware Collections.emptyList(). flys-artifacts/trunk@5511 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author Sascha L. Teichmann <sascha.teichmann@intevation.de>
date Tue, 18 Sep 2012 16:24:51 +0000
parents d12f108ccc9c
children 00abcd3737f9
files flys-artifacts/ChangeLog flys-artifacts/src/main/java/de/intevation/flys/artifacts/WINFOArtifact.java flys-artifacts/src/main/java/de/intevation/flys/artifacts/model/AnnotationsFactory.java flys-artifacts/src/main/java/de/intevation/flys/jfree/StableXYDifferenceRenderer.java
diffstat 4 files changed, 11 insertions(+), 5 deletions(-) [+]
line wrap: on
line diff
--- a/flys-artifacts/ChangeLog	Tue Sep 18 15:45:49 2012 +0000
+++ b/flys-artifacts/ChangeLog	Tue Sep 18 16:24:51 2012 +0000
@@ -1,3 +1,10 @@
+2012-09-18	Sascha L. Teichmann	<sascha.teichmann@intevation.de>
+
+	* src/main/java/de/intevation/flys/jfree/StableXYDifferenceRenderer.java,
+	  src/main/java/de/intevation/flys/artifacts/model/AnnotationsFactory.java,
+	  src/main/java/de/intevation/flys/artifacts/WINFOArtifact.java:
+	  Use generics aware Collections.emptyList().
+
 2012-09-18	Sascha L. Teichmann	<sascha.teichmann@intevation.de>
 
 	* src/main/java/de/intevation/flys/artifacts/model/minfo/BedQualityResult.java,
--- a/flys-artifacts/src/main/java/de/intevation/flys/artifacts/WINFOArtifact.java	Tue Sep 18 15:45:49 2012 +0000
+++ b/flys-artifacts/src/main/java/de/intevation/flys/artifacts/WINFOArtifact.java	Tue Sep 18 16:24:51 2012 +0000
@@ -560,12 +560,12 @@
         StateData wqValues = getData("wq_values");
         if (wqValues == null) {
             logger.warn("no wq_values given");
-            return Collections.emptyList();
+            return Collections.<Segment>emptyList();
         }
         String input = (String) wqValues.getValue();
         if (input == null || (input = input.trim()).length() == 0) {
             logger.warn("wq_values are empty");
-            return Collections.emptyList();
+            return Collections.<Segment>emptyList();
         }
         return Segment.parseSegments(input);
     }
--- a/flys-artifacts/src/main/java/de/intevation/flys/artifacts/model/AnnotationsFactory.java	Tue Sep 18 15:45:49 2012 +0000
+++ b/flys-artifacts/src/main/java/de/intevation/flys/artifacts/model/AnnotationsFactory.java	Tue Sep 18 16:24:51 2012 +0000
@@ -100,8 +100,7 @@
         riverQuery.setParameter("name", riverName);
         List<River> rivers = riverQuery.list();
         if (rivers.isEmpty()) {
-            List<Annotation> list = Collections.emptyList();
-            return list.iterator();
+            return Collections.<Annotation>emptyList().iterator();
         }
 
         Query query = session.createQuery(
--- a/flys-artifacts/src/main/java/de/intevation/flys/jfree/StableXYDifferenceRenderer.java	Tue Sep 18 15:45:49 2012 +0000
+++ b/flys-artifacts/src/main/java/de/intevation/flys/jfree/StableXYDifferenceRenderer.java	Tue Sep 18 16:24:51 2012 +0000
@@ -846,7 +846,7 @@
 
         switch (dataset.getSeriesCount()) {
             case 0:
-                return Collections.emptyList();
+                return Collections.<XYDataset>emptyList();
             case 1:
                 return splitByNaNsOneSeries(dataset);
             default: // two or more

http://dive4elements.wald.intevation.org