Mercurial > dive4elements > river
diff flys-artifacts/src/main/java/de/intevation/flys/exports/CrossSectionGenerator.java @ 3453:e74e707ff650
Replace string comparison with empty string with length equals zero comparison
flys-artifacts/trunk@5117 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author | Sascha L. Teichmann <sascha.teichmann@intevation.de> |
---|---|
date | Tue, 24 Jul 2012 09:16:00 +0000 |
parents | 97ad960f5579 |
children | 0b9b2a0c4e64 |
line wrap: on
line diff
--- a/flys-artifacts/src/main/java/de/intevation/flys/exports/CrossSectionGenerator.java Tue Jul 24 08:03:28 2012 +0000 +++ b/flys-artifacts/src/main/java/de/intevation/flys/exports/CrossSectionGenerator.java Tue Jul 24 09:16:00 2012 +0000 @@ -326,7 +326,7 @@ if (ThemeUtil.parseShowWidth(theme)) { NumberFormat nf = Formatter.getMeterFormat(this.context); String labelAdd = "b=" + nf.format(lines.width) + "m"; - if (series.getLabel().equals("")) { + if (series.getLabel().length() == 0) { series.setLabel(labelAdd); } else { @@ -337,7 +337,7 @@ && lines.points[1].length > 0) { NumberFormat nf = Formatter.getMeterFormat(this.context); String labelAdd = "W=" + nf.format(lines.points[1][0]) + "NN+m"; - if (series.getLabel().equals("")) { + if (series.getLabel().length() == 0) { series.setLabel(labelAdd); } else { @@ -348,7 +348,7 @@ NumberFormat nf = Formatter.getMeterFormat(this.context); String labelAdd = "H=" + nf.format(lines.area / lines.width) + "m"; // : " + lines.area + "/" + lines.width); - if (series.getLabel().equals("")) { + if (series.getLabel().length() == 0) { series.setLabel(labelAdd); } else {