Mercurial > dive4elements > gnv-client
changeset 193:34f233123a6f
Adding empty Series into Chart to prevent NPE issue 19
gnv-artifacts/trunk@243 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author | Tim Englich <tim.englich@intevation.de> |
---|---|
date | Mon, 19 Oct 2009 12:06:48 +0000 |
parents | 17987acf20d0 |
children | 00c1a931b9c3 |
files | gnv-artifacts/ChangeLog gnv-artifacts/src/main/java/de/intevation/gnv/chart/ChartFactory.java gnv-artifacts/src/main/java/de/intevation/gnv/chart/VerticalProfileChartFactory.java |
diffstat | 3 files changed, 12 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/gnv-artifacts/ChangeLog Mon Oct 19 10:25:54 2009 +0000 +++ b/gnv-artifacts/ChangeLog Mon Oct 19 12:06:48 2009 +0000 @@ -1,5 +1,10 @@ 2009-10-19 Tim Englich <tim.englich@intevation.de> + * src/main/java/de/intevation/gnv/chart/ChartFactory.java (createDataset), + src/main/java/de/intevation/gnv/chart/VerticalProfileChartFactory.java (createDataset): + Adding empty Series into Chart to prevent NPE issue 19 + +2009-10-19 Tim Englich <tim.englich@intevation.de> * src/main/java/de/intevation/gnv/transition/TransitionBase.java (putInputData): Correct misspelled Exception-Message as an Result of fixing issue35
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/chart/ChartFactory.java Mon Oct 19 10:25:54 2009 +0000 +++ b/gnv-artifacts/src/main/java/de/intevation/gnv/chart/ChartFactory.java Mon Oct 19 12:06:48 2009 +0000 @@ -368,6 +368,10 @@ lTimeSeriesCollection.addSeries(createTimeSeries( mTimeSeriesName, resultSet, lUpperCut, lLowerCut, mStart, mEnd, dStart, dEnd)); + }else{ + lTimeSeriesCollection.addSeries(createTimeSeries( + "", resultSet, lUpperCut, lLowerCut, + mStart, mEnd, dStart, dEnd)); } } catch (Exception e) { sLogger.error(e.getMessage(), e);
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/chart/VerticalProfileChartFactory.java Mon Oct 19 10:25:54 2009 +0000 +++ b/gnv-artifacts/src/main/java/de/intevation/gnv/chart/VerticalProfileChartFactory.java Mon Oct 19 12:06:48 2009 +0000 @@ -298,6 +298,9 @@ + "von Datensätzen " + mStart + " / " + mEnd); xyDataset.addSeries(createXYSeries(seriesName, resultSet, lUpperCut, lLowerCut, mStart, mEnd)); + }else{ + xyDataset.addSeries(createXYSeries("", + resultSet, lUpperCut, lLowerCut, mStart, mEnd)); } } catch (Exception e) { sLogger.error(e.getMessage(), e);