Mercurial > dive4elements > river
diff flys-artifacts/src/main/java/de/intevation/flys/exports/XYChartGenerator.java @ 2233:958a10e2e246
Added a new ChartGenerator for timeseries charts and refactored some code in XYChartGenerator.
flys-artifacts/trunk@3877 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author | Ingo Weinzierl <ingo.weinzierl@intevation.de> |
---|---|
date | Thu, 02 Feb 2012 12:26:36 +0000 |
parents | 5648b5b34ae2 |
children | 46ec09c7f578 |
line wrap: on
line diff
--- a/flys-artifacts/src/main/java/de/intevation/flys/exports/XYChartGenerator.java Thu Feb 02 11:57:38 2012 +0000 +++ b/flys-artifacts/src/main/java/de/intevation/flys/exports/XYChartGenerator.java Thu Feb 02 12:26:36 2012 +0000 @@ -155,16 +155,6 @@ } // class AxisDataset - /** - * A mini interface that allows to walk over the YAXIS enums defined in - * subclasses. - */ - public interface YAxisWalker { - int length(); - String getId(int idx); - } - - /** Override to make axis information available. */ protected YAxisWalker getYAxisWalker() { return new YAxisWalker() { @@ -346,31 +336,6 @@ /** - * Returns the Y-Axis label of a chart at position <i>pos</i>. - * - * @return the Y-Axis label of a chart at position <i>0</i>. - */ - protected String getYAxisLabel(int pos) { - ChartSettings chartSettings = getChartSettings(); - if (chartSettings == null) { - return getDefaultYAxisLabel(pos); - } - - YAxisWalker walker = getYAxisWalker(); - AxisSection as = chartSettings.getAxisSection(walker.getId(pos)); - if (as != null) { - String label = as.getLabel(); - - if (label != null) { - return label; - } - } - - return getDefaultYAxisLabel(pos); - } - - - /** * This method is called to retrieve the default label for an Y axis at * position <i>pos</i>. * @@ -1486,21 +1451,6 @@ /** - * Creates a new instance of <i>IdentifiableNumberAxis</i>. - * - * @param idx The index of the new axis. - * @param label The label of the new axis. - * - * @return an instance of IdentifiableNumberAxis. - */ - protected NumberAxis createNumberAxis(int idx, String label) { - YAxisWalker walker = getYAxisWalker(); - - return new IdentifiableNumberAxis(walker.getId(idx), label); - } - - - /** * Returns an instance of <i>ChartSettings</i> with a chart specific section * but with no axes settings. *