|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object de.laures.cewolf.taglib.CewolfChartFactory
public abstract class CewolfChartFactory
Chart factory creates Jfreechart instances. To add a new factory use the
CewolfChartFactory.registerFactory(new CewolfChartFactory() {...});
method.
Field Summary | |
---|---|
protected java.lang.String |
chartType
|
Fields inherited from interface de.laures.cewolf.taglib.ChartConstants |
---|
AREA, AREA_XY, BUBBLE, CANDLE_STICK, COMBINED_XY, COMPASS, DIAL, GANTT, HEATMAP, HIGH_LOW, HISTOGRAM, HORIZONTAL_BAR, HORIZONTAL_BAR_3D, LINE, METER, OVERLAY_CATEGORY, OVERLAY_XY, PIE, PIE_3D, SCATTER, SPIDERWEB, SPLINE, STACKED_AREA, STACKED_HORIZONTAL_BAR, STACKED_HORIZONTAL_BAR_3D, STACKED_VERTICAL_BAR, STACKED_VERTICAL_BAR_3D, THERMOMETER, TIME_SERIES, VERTICAL_BAR, VERTICAL_BAR_3D, VERTICAL_XY_BAR, WAFER, WIND, XY |
Fields inherited from interface de.laures.cewolf.taglib.AxisConstants |
---|
AXIS_TYPE_CATEGORY, AXIS_TYPE_DATE, AXIS_TYPE_NUMBER, ORIENTATION_HORIZONTAL, ORIENTATION_VERTICAL |
Fields inherited from interface de.laures.cewolf.taglib.LayoutConstants |
---|
DOMAIN, RANGE |
Constructor Summary | |
---|---|
protected |
CewolfChartFactory(java.lang.String chartType)
Creates a new instance of ChartFactory |
Method Summary | |
---|---|
static void |
check(org.jfree.data.general.Dataset data,
java.lang.Class clazz,
java.lang.String chartType)
Helper to check if the given dataset is the expected type. |
static org.jfree.chart.JFreeChart |
createScatterPlot(java.lang.String title,
java.lang.String xAxisLabel,
java.lang.String yAxisLabel,
org.jfree.data.xy.XYDataset dataset,
org.jfree.chart.plot.PlotOrientation orientation,
boolean legend,
boolean tooltips,
boolean urls)
Creates a scatter plot with default settings. |
static org.jfree.chart.JFreeChart |
createSplineChart(java.lang.String title,
java.lang.String xAxisLabel,
java.lang.String yAxisLabel,
org.jfree.data.xy.XYDataset dataset,
org.jfree.chart.plot.PlotOrientation orientation,
boolean showLegend,
boolean tooltips,
boolean urls)
Creates a spline chart (based on an XYDataset ) with default settings. |
static org.jfree.chart.JFreeChart |
createXYLineChart(java.lang.String title,
java.lang.String xAxisLabel,
java.lang.String yAxisLabel,
org.jfree.data.xy.XYDataset dataset,
org.jfree.chart.plot.PlotOrientation orientation,
boolean legend,
boolean tooltips,
boolean urls)
Creates a line chart (based on an XYDataset ) with default settings. |
abstract org.jfree.chart.JFreeChart |
getChartInstance(java.lang.String title,
java.lang.String xAxisLabel,
java.lang.String yAxisLabel,
org.jfree.data.general.Dataset data)
Callback when the chart instance to be created. |
static org.jfree.chart.JFreeChart |
getChartInstance(java.lang.String chartType,
java.lang.String title,
java.lang.String xAxisLabel,
java.lang.String yAxisLabel,
org.jfree.data.general.Dataset data,
boolean showLegend)
|
static org.jfree.chart.JFreeChart |
getCombinedChartInstance(java.lang.String chartType,
java.lang.String title,
java.lang.String xAxisLabel,
java.lang.String yAxisLabel,
java.util.List plotDefinitions,
java.lang.String layout,
boolean showLegend)
|
static org.jfree.chart.JFreeChart |
getOverlaidChartInstance(java.lang.String chartType,
java.lang.String title,
java.lang.String xAxisLabel,
java.lang.String yAxisLabel,
int xAxisType,
int yAxisType,
java.util.List plotDefinitions,
boolean showLegend)
|
static void |
registerFactory(CewolfChartFactory factory)
Register a new chart factory instance. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected java.lang.String chartType
Constructor Detail |
---|
protected CewolfChartFactory(java.lang.String chartType)
Method Detail |
---|
public abstract org.jfree.chart.JFreeChart getChartInstance(java.lang.String title, java.lang.String xAxisLabel, java.lang.String yAxisLabel, org.jfree.data.general.Dataset data) throws IncompatibleDatasetException
title
- The title of chartxAxisLabel
- label on x axisyAxisLabel
- label on y axisdata
- The dataset to create chart for
IncompatibleDatasetException
- If the incoming data is not compatible with this factorypublic static void registerFactory(CewolfChartFactory factory)
factory
- The factory to registerpublic static org.jfree.chart.JFreeChart getChartInstance(java.lang.String chartType, java.lang.String title, java.lang.String xAxisLabel, java.lang.String yAxisLabel, org.jfree.data.general.Dataset data, boolean showLegend) throws ChartValidationException
ChartValidationException
public static org.jfree.chart.JFreeChart createSplineChart(java.lang.String title, java.lang.String xAxisLabel, java.lang.String yAxisLabel, org.jfree.data.xy.XYDataset dataset, org.jfree.chart.plot.PlotOrientation orientation, boolean showLegend, boolean tooltips, boolean urls)
XYDataset
) with default settings.
title
- the chart title (null
permitted).xAxisLabel
- a label for the X-axis (null
permitted).yAxisLabel
- a label for the Y-axis (null
permitted).dataset
- the dataset for the chart (null
permitted).orientation
- the plot orientation (horizontal or vertical) (null
NOT permitted).showLegend
- a flag specifying whether or not a legend is required.tooltips
- configure chart to generate tool tips?urls
- configure chart to generate URLs?
public static org.jfree.chart.JFreeChart createScatterPlot(java.lang.String title, java.lang.String xAxisLabel, java.lang.String yAxisLabel, org.jfree.data.xy.XYDataset dataset, org.jfree.chart.plot.PlotOrientation orientation, boolean legend, boolean tooltips, boolean urls)
XYPlot
instance as the plot,
with a NumberAxis
for the domain axis, a NumberAxis
as the range axis, and an XYConditionRenderer
as the renderer.
title
- the chart title (null
permitted).xAxisLabel
- a label for the X-axis (null
permitted).yAxisLabel
- a label for the Y-axis (null
permitted).dataset
- the dataset for the chart (null
permitted).orientation
- the plot orientation (horizontal or vertical) (null
NOT permitted).legend
- a flag specifying whether or not a legend is required.tooltips
- configure chart to generate tool tips?urls
- configure chart to generate URLs?
public static org.jfree.chart.JFreeChart createXYLineChart(java.lang.String title, java.lang.String xAxisLabel, java.lang.String yAxisLabel, org.jfree.data.xy.XYDataset dataset, org.jfree.chart.plot.PlotOrientation orientation, boolean legend, boolean tooltips, boolean urls)
XYDataset
) with default settings.
title
- the chart title (null
permitted).xAxisLabel
- a label for the X-axis (null
permitted).yAxisLabel
- a label for the Y-axis (null
permitted).dataset
- the dataset for the chart (null
permitted).orientation
- the plot orientation (horizontal or vertical) (null
NOT permitted).legend
- a flag specifying whether or not a legend is required.tooltips
- configure chart to generate tool tips?urls
- configure chart to generate URLs?
public static org.jfree.chart.JFreeChart getOverlaidChartInstance(java.lang.String chartType, java.lang.String title, java.lang.String xAxisLabel, java.lang.String yAxisLabel, int xAxisType, int yAxisType, java.util.List plotDefinitions, boolean showLegend) throws ChartValidationException, DatasetProduceException
ChartValidationException
DatasetProduceException
public static org.jfree.chart.JFreeChart getCombinedChartInstance(java.lang.String chartType, java.lang.String title, java.lang.String xAxisLabel, java.lang.String yAxisLabel, java.util.List plotDefinitions, java.lang.String layout, boolean showLegend) throws ChartValidationException, DatasetProduceException
ChartValidationException
DatasetProduceException
public static void check(org.jfree.data.general.Dataset data, java.lang.Class clazz, java.lang.String chartType) throws IncompatibleDatasetException
data
- The datasetclazz
- Expected type (class)chartType
- The chart type string
IncompatibleDatasetException
- If not the expected class
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |