Mercurial > dive4elements > river
changeset 3085:3e5f45a9e052
Added missing 'else's in if/else ladders.
flys-artifacts/trunk@4681 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author | Sascha L. Teichmann <sascha.teichmann@intevation.de> |
---|---|
date | Mon, 18 Jun 2012 08:42:45 +0000 |
parents | d78b7c06e061 |
children | ba7df29264cd |
files | flys-artifacts/ChangeLog flys-artifacts/src/main/java/de/intevation/flys/artifacts/model/WKmsJRDataSource.java flys-artifacts/src/main/java/de/intevation/flys/artifacts/model/WQTJRDataSource.java flys-artifacts/src/main/java/de/intevation/flys/artifacts/model/WWQQJRDataSource.java |
diffstat | 4 files changed, 40 insertions(+), 33 deletions(-) [+] |
line wrap: on
line diff
--- a/flys-artifacts/ChangeLog Mon Jun 18 08:36:55 2012 +0000 +++ b/flys-artifacts/ChangeLog Mon Jun 18 08:42:45 2012 +0000 @@ -1,3 +1,10 @@ +2012-06-18 Sascha L. Teichmann <sascha.teichmann@intevation.de> + + * src/main/java/de/intevation/flys/artifacts/model/WKmsJRDataSource.java, + src/main/java/de/intevation/flys/artifacts/model/WWQQJRDataSource.java, + src/main/java/de/intevation/flys/artifacts/model/WQTJRDataSource.java: + Added missing 'else's in if/else ladders. + 2012-06-18 Sascha L. Teichmann <sascha.teichmann@intevation.de> * src/main/java/de/intevation/flys/artifacts/services/FileUploadService.java:
--- a/flys-artifacts/src/main/java/de/intevation/flys/artifacts/model/WKmsJRDataSource.java Mon Jun 18 08:36:55 2012 +0000 +++ b/flys-artifacts/src/main/java/de/intevation/flys/artifacts/model/WKmsJRDataSource.java Mon Jun 18 08:42:45 2012 +0000 @@ -73,40 +73,40 @@ if ("river".equals(fieldName)) { value = metaData.get("river"); } - if ("date".equals(fieldName)) { + else if ("date".equals(fieldName)) { value = metaData.get("date"); } - if ("range".equals(fieldName)) { + else if ("range".equals(fieldName)) { value = metaData.get("range"); } - if ("gauge".equals(fieldName)) { + else if ("gauge".equals(fieldName)) { value = metaData.get("gauge"); } - if ("calculation".equals(fieldName)) { + else if ("calculation".equals(fieldName)) { value = metaData.get("calculation"); } - if ("differences".equals(fieldName)) { + else if ("differences".equals(fieldName)) { value = metaData.get("differences"); } - if ("km".equals(fieldName)) { + else if ("km".equals(fieldName)) { value = data.get(index)[0]; } - if ("W".equals(fieldName)) { + else if ("W".equals(fieldName)) { value = data.get(index)[1]; } - if ("Q".equals(fieldName)) { + else if ("Q".equals(fieldName)) { value = data.get(index)[2]; } - if ("description".equals(fieldName)) { + else if ("description".equals(fieldName)) { value = data.get(index)[3]; } - if ("location".equals(fieldName)) { + else if ("location".equals(fieldName)) { value = data.get(index)[4]; } - if ("gaugename".equals(fieldName)) { + else if ("gaugename".equals(fieldName)) { value = data.get(index)[5]; } - if ("day".equals(fieldName)) { + else if ("day".equals(fieldName)) { value = data.get(index)[6]; } return value;
--- a/flys-artifacts/src/main/java/de/intevation/flys/artifacts/model/WQTJRDataSource.java Mon Jun 18 08:36:55 2012 +0000 +++ b/flys-artifacts/src/main/java/de/intevation/flys/artifacts/model/WQTJRDataSource.java Mon Jun 18 08:42:45 2012 +0000 @@ -73,25 +73,25 @@ if ("river".equals(fieldName)) { value = metaData.get("river"); } - if ("date".equals(fieldName)) { + else if ("date".equals(fieldName)) { value = metaData.get("date"); } - if ("calculation".equals(fieldName)) { + else if ("calculation".equals(fieldName)) { value = metaData.get("calculation"); } - if ("range".equals(fieldName)) { + else if ("range".equals(fieldName)) { value = data.get(index)[0]; } - if ("W".equals(fieldName)) { + else if ("W".equals(fieldName)) { value = data.get(index)[1]; } - if ("Q".equals(fieldName)) { + else if ("Q".equals(fieldName)) { value = data.get(index)[2]; } - if ("delta".equals(fieldName)) { + else if ("delta".equals(fieldName)) { value = data.get(index)[3]; } - if ("gaugename".equals(fieldName)) { + else if ("gaugename".equals(fieldName)) { value = data.get(index)[4]; } return value;
--- a/flys-artifacts/src/main/java/de/intevation/flys/artifacts/model/WWQQJRDataSource.java Mon Jun 18 08:36:55 2012 +0000 +++ b/flys-artifacts/src/main/java/de/intevation/flys/artifacts/model/WWQQJRDataSource.java Mon Jun 18 08:42:45 2012 +0000 @@ -73,46 +73,46 @@ if ("river".equals(fieldName)) { value = metaData.get("river"); } - if ("date".equals(fieldName)) { + else if ("date".equals(fieldName)) { value = metaData.get("date"); } - if ("calculation".equals(fieldName)) { + else if ("calculation".equals(fieldName)) { value = metaData.get("calculation"); } - if ("reference".equals(fieldName)) { + else if ("reference".equals(fieldName)) { value = metaData.get("reference"); } - if ("location".equals(fieldName)) { + else if ("location".equals(fieldName)) { value = metaData.get("location"); } - if ("km1".equals(fieldName)) { + else if ("km1".equals(fieldName)) { value = data.get(index)[0]; } - if ("location1".equals(fieldName)) { + else if ("location1".equals(fieldName)) { value = data.get(index)[1]; } - if ("W1".equals(fieldName)) { + else if ("W1".equals(fieldName)) { value = data.get(index)[2]; } - if ("Q1".equals(fieldName)) { + else if ("Q1".equals(fieldName)) { value = data.get(index)[3]; } - if ("km2".equals(fieldName)) { + else if ("km2".equals(fieldName)) { value = data.get(index)[4]; } - if ("location2".equals(fieldName)) { + else if ("location2".equals(fieldName)) { value = data.get(index)[5]; } - if ("W2".equals(fieldName)) { + else if ("W2".equals(fieldName)) { value = data.get(index)[6]; } - if ("Q2".equals(fieldName)) { + else if ("Q2".equals(fieldName)) { value = data.get(index)[7]; } - if ("Wcm1".equals(fieldName)) { + else if ("Wcm1".equals(fieldName)) { value = data.get(index)[8]; } - if("Wcm2".equals(fieldName)) { + else if ("Wcm2".equals(fieldName)) { value = data.get(index)[9]; } return value;