|
deegree 2.5 (2011/06/29 09:44 build-8-official) | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.deegree.graphics.charts.ChartsBuilder
public class ChartsBuilder
A Charts class with static methods. Its used to create de.latlon.charts from the given inputs.
Field Summary | |
---|---|
static int |
ORIENTATION_HORIZONTAL
To indicate a horizontal chart type |
static int |
ORIENTATION_VERTICAL
To indicate a vertical chart type |
protected static int |
VALUE_FORMAT_SERIES
&CDU=23,25,21,26&SPD=42 23 33 36 |
protected static int |
VALUE_FORMAT_SIMPLE
&CDU=34&SPD=36&Gruene=11 |
protected static int |
VALUE_FORMAT_UNKNOWN
Unknown format |
protected static int |
VALUE_FORMAT_XYSERIES
&CDU=1970 23;1974,44;1978,43&SPD=1970,23;1974,44;1978,43 |
Constructor Summary | |
---|---|
ChartsBuilder(ChartConfig chartConfigs)
|
Method Summary | |
---|---|
protected org.jfree.chart.JFreeChart |
configChart(org.jfree.chart.JFreeChart chart,
ChartConfig chartConfigs)
Initializes the chart with the values from the properties file config.properties |
protected org.jfree.chart.JFreeChart |
configLineChart(org.jfree.chart.JFreeChart chart,
ChartConfig chartConfigs)
Configures the pie chart according to the stored configurations file |
protected org.jfree.chart.JFreeChart |
configPieChart(org.jfree.chart.JFreeChart chart,
ChartConfig chartConfigs)
Configures the pie chart according to the stored configurations file |
protected org.jfree.data.category.CategoryDataset |
convertMapToCategoryDataSet(QueuedMap<java.lang.String,java.lang.String> keyedValues)
It takes in a map a QueuedMap and converts it to a XYDataSet. |
protected org.jfree.data.xy.XYDataset |
convertMapToXYSeriesDataSet(QueuedMap<java.lang.String,java.lang.String> keyedValues)
It takes in a map a QueuedMap and converts it to a XYDataSet.The two tokens of each tupel have to be numbers Format: key = x1,y1;x2,y2;x3,y3; Example row1 = 2,3;4,10; |
java.awt.image.BufferedImage |
createBarChart(java.lang.String title,
QueuedMap<java.lang.String,java.lang.String> keyedValues,
int width,
int height,
boolean is3D,
boolean legend,
boolean tooltips,
int orientation,
java.lang.String imageType,
java.lang.String horizontalAxisName,
java.lang.String verticalAxisName,
ChartConfig chartConfigs)
Creates a Bar chart |
protected java.awt.image.BufferedImage |
createBufferedImage(org.jfree.chart.JFreeChart chart,
int width,
int height,
java.lang.String imageType)
Creates a BufferedImage instance from a given chart, according to the given additional parameters |
java.awt.image.BufferedImage |
createLineChart(java.lang.String title,
QueuedMap<java.lang.String,java.lang.String> keyedValues,
int width,
int height,
boolean is3D,
boolean legend,
boolean tooltips,
int orientation,
java.lang.String imageType,
java.lang.String horizontalAxisName,
java.lang.String verticalAxisName,
ChartConfig chartConfigs)
Creates a Line chart |
java.awt.image.BufferedImage |
createPieChart(java.lang.String title,
QueuedMap<java.lang.String,java.lang.Double> keyedValues,
int width,
int height,
boolean is3D,
boolean legend,
boolean tooltips,
java.lang.String lblType,
java.lang.String imageType,
ChartConfig chartConfigs)
Create a pie 2D/3D Pie Chart |
java.awt.image.BufferedImage |
createXYLineChart(java.lang.String title,
QueuedMap<java.lang.String,java.lang.String> keyedValues,
int width,
int height,
boolean legend,
boolean tooltips,
int orientation,
java.lang.String imageType,
java.lang.String horizontalAxisName,
java.lang.String verticalAxisName,
ChartConfig chartConfigs)
Creates an XY Line chart |
protected int |
mapImageformat(java.lang.String imgFormat)
Maps the image format to an appropriate type, either RGB or RGBA (allow opacity). |
protected org.jfree.chart.plot.PlotOrientation |
translateToPlotOrientation(int orientation)
Translates an integer that represents the chart orientation to a plot orientation instance |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final int ORIENTATION_HORIZONTAL
public static final int ORIENTATION_VERTICAL
protected static final int VALUE_FORMAT_SIMPLE
protected static final int VALUE_FORMAT_SERIES
protected static final int VALUE_FORMAT_XYSERIES
protected static final int VALUE_FORMAT_UNKNOWN
Constructor Detail |
---|
public ChartsBuilder(ChartConfig chartConfigs)
chartConfigs
- Method Detail |
---|
public java.awt.image.BufferedImage createPieChart(java.lang.String title, QueuedMap<java.lang.String,java.lang.Double> keyedValues, int width, int height, boolean is3D, boolean legend, boolean tooltips, java.lang.String lblType, java.lang.String imageType, ChartConfig chartConfigs)
title
- keyedValues
- The key/value pairs used for the pie chartwidth
- of the output imageheight
- height of the output imageis3D
- is a 3D Chartlegend
- for the output charttooltips
- for the output chartlblType
- Possible types are Key, Value, KeyValueimageType
- of the output imagechartConfigs
- to configure the output chart, or null to use the default ChartConfig
public java.awt.image.BufferedImage createBarChart(java.lang.String title, QueuedMap<java.lang.String,java.lang.String> keyedValues, int width, int height, boolean is3D, boolean legend, boolean tooltips, int orientation, java.lang.String imageType, java.lang.String horizontalAxisName, java.lang.String verticalAxisName, ChartConfig chartConfigs) throws IncorrectFormatException
title
- keyedValues
- key is the category name, value is a series tupels as follows for instance key1 = (arg1,4);(arg2,6)
key2 = (arg1,8); (arg2,11)width
- of the output imageheight
- height of the output imageis3D
- is a 3D Chartlegend
- for the output charttooltips
- for the output de.latlon.chartsorientation
- Horiyontal or vertical chartimageType
- of the output imagehorizontalAxisName
- Name of the Horizontal AxisverticalAxisName
- Name of the vertical AxischartConfigs
- to configure the output chart, or null to use the default ChartConfig
IncorrectFormatException
public java.awt.image.BufferedImage createLineChart(java.lang.String title, QueuedMap<java.lang.String,java.lang.String> keyedValues, int width, int height, boolean is3D, boolean legend, boolean tooltips, int orientation, java.lang.String imageType, java.lang.String horizontalAxisName, java.lang.String verticalAxisName, ChartConfig chartConfigs) throws IncorrectFormatException
title
- keyedValues
- key is the category name, value is a series tupels as follows for instance key1 = (arg1,4);(arg2,6)
key2 = (arg1,8); (arg2,11)width
- of the output imageheight
- height of the output imageis3D
- is a 3D Chartlegend
- for the output charttooltips
- for the output de.latlon.chartsorientation
- Horiyontal or vertical chartimageType
- of the output imagehorizontalAxisName
- Name of the Horizontal AxisverticalAxisName
- Name of the vertical AxischartConfigs
- to configure the output chart, or null to use the default ChartConfig
IncorrectFormatException
public java.awt.image.BufferedImage createXYLineChart(java.lang.String title, QueuedMap<java.lang.String,java.lang.String> keyedValues, int width, int height, boolean legend, boolean tooltips, int orientation, java.lang.String imageType, java.lang.String horizontalAxisName, java.lang.String verticalAxisName, ChartConfig chartConfigs) throws IncorrectFormatException
title
- keyedValues
- key is the category name, value is a series tupels Format: key = x1,y1;x2,y2;x3,y3 Example row1 =
2,3;4,10 Note that x and y have to be numberswidth
- of the output imageheight
- height of the output imagelegend
- for the output charttooltips
- for the output de.latlon.chartsorientation
- Horiyontal or vertical chartimageType
- of the output imagehorizontalAxisName
- Name of the Horizontal AxisverticalAxisName
- Name of the vertical AxischartConfigs
- to configure the output chart, or null to use the default ChartConfig
IncorrectFormatException
protected org.jfree.data.category.CategoryDataset convertMapToCategoryDataSet(QueuedMap<java.lang.String,java.lang.String> keyedValues) throws IncorrectFormatException
keyedValues
-
IncorrectFormatException
protected org.jfree.data.xy.XYDataset convertMapToXYSeriesDataSet(QueuedMap<java.lang.String,java.lang.String> keyedValues) throws IncorrectFormatException
keyedValues
-
IncorrectFormatException
protected org.jfree.chart.plot.PlotOrientation translateToPlotOrientation(int orientation)
orientation
-
protected java.awt.image.BufferedImage createBufferedImage(org.jfree.chart.JFreeChart chart, int width, int height, java.lang.String imageType)
chart
- width
- of the generated imageheight
- of the generated imageimageType
- ex image/png, image/jpg
protected org.jfree.chart.JFreeChart configPieChart(org.jfree.chart.JFreeChart chart, ChartConfig chartConfigs)
chart
- chartConfigs
- to configure the output chart
protected org.jfree.chart.JFreeChart configLineChart(org.jfree.chart.JFreeChart chart, ChartConfig chartConfigs)
chart
- chartConfigs
- to configure the output chart
protected org.jfree.chart.JFreeChart configChart(org.jfree.chart.JFreeChart chart, ChartConfig chartConfigs)
chart
- chartConfigs
- to configure the output chart
protected int mapImageformat(java.lang.String imgFormat)
imgFormat
-
|
deegree 2.5 (2011/06/29 09:44 build-8-official) | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
an open source project founded by lat/lon, Bonn, Germany.
For more information visit: http://www.deegree.org