changeset 3258:3c006a53e551

Replaced tabs with four spaces each. flys-artifacts/trunk@4895 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author Sascha L. Teichmann <sascha.teichmann@intevation.de>
date Sun, 08 Jul 2012 08:43:13 +0000 (2012-07-08)
parents 2aca387333d6
children 9422b559b2d5
files flys-artifacts/ChangeLog flys-artifacts/src/main/java/de/intevation/flys/artifacts/WaterlevelArtifact.java flys-artifacts/src/main/java/de/intevation/flys/artifacts/access/BedHeightAccess.java flys-artifacts/src/main/java/de/intevation/flys/artifacts/access/FlowVelocityAccess.java flys-artifacts/src/main/java/de/intevation/flys/artifacts/geom/Polygon2D.java flys-artifacts/src/main/java/de/intevation/flys/artifacts/model/FlowVelocityCalculation.java flys-artifacts/src/main/java/de/intevation/flys/artifacts/model/MiddleBedHeightCalculation.java
diffstat 7 files changed, 116 insertions(+), 108 deletions(-) [+]
line wrap: on
line diff
--- a/flys-artifacts/ChangeLog	Sun Jul 08 07:56:46 2012 +0000
+++ b/flys-artifacts/ChangeLog	Sun Jul 08 08:43:13 2012 +0000
@@ -1,3 +1,13 @@
+2012-07-08	Sascha L. Teichmann	<sascha.teichmann@intevation.de>
+
+	* src/main/java/de/intevation/flys/artifacts/WaterlevelArtifact.java,
+	  src/main/java/de/intevation/flys/artifacts/geom/Polygon2D.java,
+	  src/main/java/de/intevation/flys/artifacts/model/FlowVelocityCalculation.java,
+	  src/main/java/de/intevation/flys/artifacts/model/MiddleBedHeightCalculation.java,
+	  src/main/java/de/intevation/flys/artifacts/access/BedHeightAccess.java,
+	  src/main/java/de/intevation/flys/artifacts/access/FlowVelocityAccess.java:
+	  Replaced tabs with four spaces each.
+
 2012-07-07	Sascha L. Teichmann	<sascha.teichmann@intevation.de>
 
 	* src/main/java/de/intevation/flys/exports/XYChartGenerator.java,
--- a/flys-artifacts/src/main/java/de/intevation/flys/artifacts/WaterlevelArtifact.java	Sun Jul 08 07:56:46 2012 +0000
+++ b/flys-artifacts/src/main/java/de/intevation/flys/artifacts/WaterlevelArtifact.java	Sun Jul 08 08:43:13 2012 +0000
@@ -83,7 +83,7 @@
     {
         WINFOArtifact winfo = (WINFOArtifact) artifact;
         this.data = winfo.cloneData();
-	logger.debug("Cloned data of winfo artifact.");
+        logger.debug("Cloned data of winfo artifact.");
         // Statically add Facets.
         List<Facet> fs = new ArrayList<Facet>();
         DefaultState state = (DefaultState) getCurrentState(context);
--- a/flys-artifacts/src/main/java/de/intevation/flys/artifacts/access/BedHeightAccess.java	Sun Jul 08 07:56:46 2012 +0000
+++ b/flys-artifacts/src/main/java/de/intevation/flys/artifacts/access/BedHeightAccess.java	Sun Jul 08 08:43:13 2012 +0000
@@ -10,101 +10,100 @@
 
 public class BedHeightAccess extends Access {
 
-	private static final Logger logger = Logger.getLogger(BedHeightAccess.class);
-
+    private static final Logger logger = Logger.getLogger(BedHeightAccess.class);
 
-	private int[] singleIDs;
-	private int[] epochIDs;
+    private int[] singleIDs;
+    private int[] epochIDs;
 
-	private Double lowerKM;
-	private Double upperKM;
+    private Double lowerKM;
+    private Double upperKM;
 
 
-	public BedHeightAccess(FLYSArtifact artifact) {
-		super(artifact);
-	}
+    public BedHeightAccess(FLYSArtifact artifact) {
+        super(artifact);
+    }
 
 
-	public Double getLowerKM() {
-    	if (lowerKM == null) {
-    		lowerKM = getDouble("ld_from");
-    	}
+    public Double getLowerKM() {
+        if (lowerKM == null) {
+            lowerKM = getDouble("ld_from");
+        }
 
-    	return lowerKM;
+        return lowerKM;
     }
 
 
     public Double getUpperKM() {
-    	if (upperKM == null) {
-    		upperKM = getDouble("ld_to");
-    	}
+        if (upperKM == null) {
+            upperKM = getDouble("ld_to");
+        }
 
-    	return upperKM;
+        return upperKM;
     }
 
 
     public int[] getBedHeightSingleIDs() {
-    	if (singleIDs == null) {
-	        String data = getString("soundings");
-
-	        if (data == null) {
-	            logger.warn("No 'soundings' parameter specified!");
-	            return null;
-	        }
-
-	        String[] parts = data.split(";");
-
-	        TIntArrayList ids = new TIntArrayList();
+        if (singleIDs == null) {
+            String data = getString("soundings");
 
-	        for (String part: parts) {
-	            if (part.indexOf(SoundingsSelect.PREFIX_SINGLE) >= 0) {
-	                String tmp = part.replace(SoundingsSelect.PREFIX_SINGLE, "");
+            if (data == null) {
+                logger.warn("No 'soundings' parameter specified!");
+                return null;
+            }
 
-	                try {
-	                    ids.add(Integer.parseInt(tmp));
-	                }
-	                catch (NumberFormatException nfe) {
-	                    logger.warn("Cannot parse int from string: '" + tmp + "'");
-	                }
-	            }
-	        }
+            String[] parts = data.split(";");
 
-	        singleIDs = ids.toNativeArray();
-    	}
+            TIntArrayList ids = new TIntArrayList();
 
-    	return singleIDs;
+            for (String part: parts) {
+                if (part.indexOf(SoundingsSelect.PREFIX_SINGLE) >= 0) {
+                    String tmp = part.replace(SoundingsSelect.PREFIX_SINGLE, "");
+
+                    try {
+                        ids.add(Integer.parseInt(tmp));
+                    }
+                    catch (NumberFormatException nfe) {
+                        logger.warn("Cannot parse int from string: '" + tmp + "'");
+                    }
+                }
+            }
+
+            singleIDs = ids.toNativeArray();
+        }
+
+        return singleIDs;
     }
 
 
     public int[] getBedHeightEpochIDs() {
-    	if (epochIDs == null) {
-	        String data = getString("soundings");
-
-	        if (data == null) {
-	            logger.warn("No 'soundings' parameter specified!");
-	            return null;
-	        }
-
-	        String[] parts = data.split(";");
-
-	        TIntArrayList ids = new TIntArrayList();
+        if (epochIDs == null) {
+            String data = getString("soundings");
 
-	        for (String part: parts) {
-	            if (part.indexOf(SoundingsSelect.PREFIX_EPOCH) >= 0) {
-	                String tmp = part.replace(SoundingsSelect.PREFIX_EPOCH, "");
+            if (data == null) {
+                logger.warn("No 'soundings' parameter specified!");
+                return null;
+            }
 
-	                try {
-	                    ids.add(Integer.parseInt(tmp));
-	                }
-	                catch (NumberFormatException nfe) {
-	                    logger.warn("Cannot parse int from string: '" + tmp + "'");
-	                }
-	            }
-	        }
+            String[] parts = data.split(";");
 
-	        epochIDs = ids.toNativeArray();
-    	}
+            TIntArrayList ids = new TIntArrayList();
 
-    	return epochIDs;
+            for (String part: parts) {
+                if (part.indexOf(SoundingsSelect.PREFIX_EPOCH) >= 0) {
+                    String tmp = part.replace(SoundingsSelect.PREFIX_EPOCH, "");
+
+                    try {
+                        ids.add(Integer.parseInt(tmp));
+                    }
+                    catch (NumberFormatException nfe) {
+                        logger.warn("Cannot parse int from string: '" + tmp + "'");
+                    }
+                }
+            }
+
+            epochIDs = ids.toNativeArray();
+        }
+
+        return epochIDs;
     }
 }
--- a/flys-artifacts/src/main/java/de/intevation/flys/artifacts/access/FlowVelocityAccess.java	Sun Jul 08 07:56:46 2012 +0000
+++ b/flys-artifacts/src/main/java/de/intevation/flys/artifacts/access/FlowVelocityAccess.java	Sun Jul 08 08:43:13 2012 +0000
@@ -5,50 +5,50 @@
 
 public class FlowVelocityAccess extends Access {
 
-	private int[] mainChannels;
-	private int[] totalChannels;
+    private int[] mainChannels;
+    private int[] totalChannels;
 
-	private Double lowerKM;
-	private Double upperKM;
+    private Double lowerKM;
+    private Double upperKM;
 
 
-	public FlowVelocityAccess(FLYSArtifact artifact) {
-		super(artifact);
-	}
+    public FlowVelocityAccess(FLYSArtifact artifact) {
+        super(artifact);
+    }
 
 
-	public int[] getMainChannels() {
-		if (mainChannels == null) {
-			mainChannels = getIntArray("main.channel");
-		}
+    public int[] getMainChannels() {
+        if (mainChannels == null) {
+            mainChannels = getIntArray("main.channel");
+        }
 
-		return mainChannels;
+        return mainChannels;
     }
 
 
     public int[] getTotalChannels() {
-    	if (totalChannels == null) {
-    		totalChannels = getIntArray("total.channel");
-    	}
+        if (totalChannels == null) {
+            totalChannels = getIntArray("total.channel");
+        }
 
-    	return totalChannels;
+        return totalChannels;
     }
 
 
     public Double getLowerKM() {
-    	if (lowerKM == null) {
-    		lowerKM = getDouble("ld_from");
-    	}
+        if (lowerKM == null) {
+            lowerKM = getDouble("ld_from");
+        }
 
-    	return lowerKM;
+        return lowerKM;
     }
 
 
     public Double getUpperKM() {
-    	if (upperKM == null) {
-    		upperKM = getDouble("ld_to");
-    	}
+        if (upperKM == null) {
+            upperKM = getDouble("ld_to");
+        }
 
-    	return upperKM;
+        return upperKM;
     }
 }
--- a/flys-artifacts/src/main/java/de/intevation/flys/artifacts/geom/Polygon2D.java	Sun Jul 08 07:56:46 2012 +0000
+++ b/flys-artifacts/src/main/java/de/intevation/flys/artifacts/geom/Polygon2D.java	Sun Jul 08 08:43:13 2012 +0000
@@ -93,13 +93,13 @@
     public double area() {
         double area = 0d;
 
-		for (int i = 0, N = points.size(); i < N; ++i) {
-			int j = (i + 1) % N;
+        for (int i = 0, N = points.size(); i < N; ++i) {
+            int j = (i + 1) % N;
             Point2D pi = points.get(i);
             Point2D pj = points.get(j);
-			area += X(pi)*Y(pj);
-			area -= X(pj)*Y(pi);
-		}
+            area += X(pi)*Y(pj);
+            area -= X(pj)*Y(pi);
+        }
 
         return 0.5d*area;
     }
--- a/flys-artifacts/src/main/java/de/intevation/flys/artifacts/model/FlowVelocityCalculation.java	Sun Jul 08 07:56:46 2012 +0000
+++ b/flys-artifacts/src/main/java/de/intevation/flys/artifacts/model/FlowVelocityCalculation.java	Sun Jul 08 08:43:13 2012 +0000
@@ -22,7 +22,6 @@
         Logger.getLogger(FlowVelocityCalculation.class);
 
 
-
     public CalculationResult calculate(FlowVelocityAccess access) {
         logger.info("FlowVelocityCalculation.calculate");
 
@@ -30,7 +29,7 @@
         int[] totalIds = access.getTotalChannels();
 
         if (logger.isDebugEnabled()) {
-        	Artifact a = access.getArtifact();
+            Artifact a = access.getArtifact();
             logger.debug("Artifact '" + a.identifier() + "' contains:");
             if (mainIds != null) {
                 logger.debug("   " + mainIds.length + " main channel ids");
@@ -79,7 +78,7 @@
 
 
     protected List<FlowVelocityModel> getFlowVelocityModels(
-    	FlowVelocityAccess  access,
+        FlowVelocityAccess  access,
         List<DischargeZone> zones
     ) {
         River river = FLYSUtils.getRiver(access.getArtifact());
@@ -132,7 +131,7 @@
 
 
     protected CalculationResult buildCalculationResult(
-    	FlowVelocityAccess 	    access,
+        FlowVelocityAccess         access,
         List<FlowVelocityModel> models
     ) {
         double kmLo = access.getLowerKM();
--- a/flys-artifacts/src/main/java/de/intevation/flys/artifacts/model/MiddleBedHeightCalculation.java	Sun Jul 08 07:56:46 2012 +0000
+++ b/flys-artifacts/src/main/java/de/intevation/flys/artifacts/model/MiddleBedHeightCalculation.java	Sun Jul 08 08:43:13 2012 +0000
@@ -32,7 +32,7 @@
 
 
         if (logger.isDebugEnabled()) {
-        	Artifact artifact = access.getArtifact();
+            Artifact artifact = access.getArtifact();
 
             logger.debug("Artifact '" + artifact.identifier() + "' contains:");
             if (singleIds != null) {
@@ -52,8 +52,8 @@
 
 
     protected List<BedHeightSingle> getSingles(
-    	BedHeightAccess access,
-    	int[] ids
+        BedHeightAccess access,
+        int[] ids
     ) {
         List<BedHeightSingle> singles = new ArrayList<BedHeightSingle>();
 
@@ -74,8 +74,8 @@
 
 
     protected List<BedHeightEpoch> getEpochs(
-    	BedHeightAccess access,
-    	int[] ids
+        BedHeightAccess access,
+        int[] ids
     ) {
         List<BedHeightEpoch> epochs = new ArrayList<BedHeightEpoch>();
 
@@ -96,7 +96,7 @@
 
 
     protected CalculationResult buildCalculationResult(
-    	BedHeightAccess		  access,
+        BedHeightAccess          access,
         List<BedHeightSingle> singles,
         List<BedHeightEpoch>  epochs
     ) {

http://dive4elements.wald.intevation.org