Package org.zkoss.chart
Class PlotData
- java.lang.Object
-
- org.zkoss.chart.PlotData
-
- All Implemented Interfaces:
Serializable
,OptionDataListener
,org.zkoss.json.JSONAware
public class PlotData extends Object implements org.zkoss.json.JSONAware, OptionDataListener
A plot data used for PlotEngine to generate the result as JSON string.- Author:
- jumperchen
- See Also:
- Serialized Form
-
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description void
addAnnotations(Annotation annotation)
Sets the annotation with out putting it in an Array.void
addSeries(Series series)
Adds the series at the end of the series listvoid
addXAxis(XAxis xAxis)
Adds the xAxis at the end of the xAxis list.void
addYAxis(YAxis yAxis)
Adds the yAxis at the end of yAxis list.void
addZAxis(ZAxis zAxis)
Adds the yAxis at the end of zAxis list.boolean
equals(Object o)
Accessibility
getAccessibility()
Returns options for configuring accessibility for the chart, or create a new one.Annotation
getAnnotations()
Returns the annotation at the index 0.Annotation
getAnnotations(int index)
Returns the annotation from the given index.int
getAnnotationsSize()
Returns the size of the annotation list.Caption
getCaption()
Returns the caption options.Chart
getChart()
Returns the chart optionsColorAxis
getColorAxis()
Returns the color axisColorAxis
getColorAxis(int index)
Returns the color axis from the given indexList<Color>
getColors()
Returns the default colors for the chart's series.Credits
getCredits()
Returns the credits optionsData
getData()
Returns the data optionsDrilldown
getDrilldown()
Returns the drilldown optionsExporting
getExporting()
Returns whether to enable the exporting moduleLabels
getLabels()
Returns the labels optionsLang
getLang()
Returns the labels optionsLegend
getLegend()
Returns the legend optionsLoading
getLoading()
Returns the loading optionsNavigation
getNavigation()
Returns the navigation optionsNoData
getNoData()
Returns the no-data optionsPane
getPane()
Returns the pane at the index 0Pane
getPane(int index)
Returns the pane from the given indexint
getPaneSize()
Return the size of the pane listPlotOptions
getPlotOptions()
Returns the plot optionsResponsive
getResponsive()
Series
getSeries()
Returns the series at the index 0Series
getSeries(int index)
Returns the series from the given index.int
getSeriesSize()
Returns the size of the series listSonification
getSonification()
Returns the sonification optionsSubtitle
getSubtitle()
Returns the subtitle optionsTitle
getTitle()
Returns the title optionsTooltip
getTooltip()
Returns the tooltip optionsXAxis
getXAxis()
Returns the xAxis at the index 0XAxis
getXAxis(int index)
Returns the xAxis from the given index.int
getXAxisSize()
Returns the size of the xAxis list.YAxis
getYAxis()
Returns the yAxis at the index 0YAxis
getYAxis(int index)
int
getYAxisSize()
Returns the size of yAxis list.ZAxis
getZAxis()
Returns the zAxis at the index 0ZAxis
getZAxis(int index)
int
getZAxisSize()
Returns the size of zAxis list.int
hashCode()
protected PlotData
merge(PlotData other)
Merges the current plot data with the given one.void
onChange(OptionDataEvent event)
Sent when the contents of the chart option has changed.void
setAccessibility(Accessibility accessibility)
Sets options for configuring accessibility for the chart.void
setCaption(Caption caption)
Sets the caption options.void
setChart(Chart chart)
Sets the chart optionsvoid
setColorAxis(List<ColorAxis> colorAxis)
Sets the color axisvoid
setColorAxis(ColorAxis colorAxis)
Deprecated.since 7.2.1.0void
setColorAxis(ColorAxis... colorAxis)
Sets the color axisvoid
setColors(String... source)
Sets the default colors for the chart's series.void
setColors(List<Color> colors)
Sets the default colors for the chart's series.void
setCredits(Credits credits)
Sets the credits optionsvoid
setData(Data data)
Sets the data optionsvoid
setDrilldown(Drilldown drilldown)
Sets the drilldown optionsvoid
setExporting(Exporting exporting)
Sets whether to enable the exporting modulevoid
setLabels(Labels labels)
Sets the labels optionsvoid
setLang(Lang lang)
Sets the lang optionsvoid
setLegend(Legend legend)
Sets the legend optionsvoid
setLoading(Loading loading)
Sets the loading optionsvoid
setNavigation(Navigation navigation)
Sets the navigation optionsvoid
setNoData(NoData noData)
Sets the no-data optionsvoid
setPlotOptions(PlotOptions plotOptions)
Sets the plot optionsvoid
setResponsive(Responsive responsive)
void
setSonification(Sonification sonification)
Sets the sonification optionsvoid
setSubtitle(Subtitle subtitle)
Sets the subtitle optionsvoid
setTitle(Title title)
Sets the title optionsvoid
setTooltip(Tooltip tooltip)
Sets the tooltip optionsvoid
setXAxis(XAxis xAxis)
Sets the xAxis with out putting it in an Arrayvoid
setYAxis(YAxis yAxis)
Sets the yAxis with out putting it in an Arrayvoid
setZAxis(ZAxis zAxis)
Sets the zAxis with out putting it in an ArrayString
toJSONString()
-
-
-
Constructor Detail
-
PlotData
public PlotData(Charts owner)
-
-
Method Detail
-
getExporting
public Exporting getExporting()
Returns whether to enable the exporting module
-
getAccessibility
public Accessibility getAccessibility()
Returns options for configuring accessibility for the chart, or create a new one.Requires the accessibility module to be loaded. For example,
Library.setProperty("org.zkoss.chart.modules.accessibility", "true");
- Since:
- 10.2.1.0
-
setAccessibility
public void setAccessibility(Accessibility accessibility)
Sets options for configuring accessibility for the chart.Requires the accessibility module to be loaded. For example,
Library.setProperty("org.zkoss.chart.modules.accessibility", "true");
- Since:
- 10.2.1.0
-
setExporting
public void setExporting(Exporting exporting)
Sets whether to enable the exporting module
-
getColors
public List<Color> getColors()
Returns the default colors for the chart's series. When all colors are used, new colors are pulled from the start again.
-
setColors
public void setColors(List<Color> colors)
Sets the default colors for the chart's series. When all colors are used, new colors are pulled from the start again.
-
setColors
public void setColors(String... source)
Sets the default colors for the chart's series. When all colors are used, new colors are pulled from the start again.
-
onChange
public void onChange(OptionDataEvent event)
Description copied from interface:OptionDataListener
Sent when the contents of the chart option has changed.- Specified by:
onChange
in interfaceOptionDataListener
-
getSeries
public Series getSeries()
Returns the series at the index 0
-
getSeriesSize
public int getSeriesSize()
Returns the size of the series list
-
getSeries
public Series getSeries(int index)
Returns the series from the given index.
-
addSeries
public void addSeries(Series series)
Adds the series at the end of the series list
-
getXAxis
public XAxis getXAxis()
Returns the xAxis at the index 0
-
getXAxisSize
public int getXAxisSize()
Returns the size of the xAxis list.
-
getXAxis
public XAxis getXAxis(int index)
Returns the xAxis from the given index.
-
addXAxis
public void addXAxis(XAxis xAxis)
Adds the xAxis at the end of the xAxis list.
-
setXAxis
public void setXAxis(XAxis xAxis)
Sets the xAxis with out putting it in an Array
-
getYAxis
public YAxis getYAxis()
Returns the yAxis at the index 0
-
getYAxisSize
public int getYAxisSize()
Returns the size of yAxis list.
-
getYAxis
public YAxis getYAxis(int index)
-
addYAxis
public void addYAxis(YAxis yAxis)
Adds the yAxis at the end of yAxis list.
-
setYAxis
public void setYAxis(YAxis yAxis)
Sets the yAxis with out putting it in an Array
-
getZAxis
public ZAxis getZAxis()
Returns the zAxis at the index 0
-
getZAxisSize
public int getZAxisSize()
Returns the size of zAxis list.
-
getZAxis
public ZAxis getZAxis(int index)
-
addZAxis
public void addZAxis(ZAxis zAxis)
Adds the yAxis at the end of zAxis list.
-
setZAxis
public void setZAxis(ZAxis zAxis)
Sets the zAxis with out putting it in an Array
-
getColorAxis
public ColorAxis getColorAxis()
Returns the color axis
-
getColorAxis
public ColorAxis getColorAxis(int index)
Returns the color axis from the given index
-
setColorAxis
public void setColorAxis(ColorAxis colorAxis)
Deprecated.since 7.2.1.0Sets the color axis
-
setColorAxis
public void setColorAxis(List<ColorAxis> colorAxis)
Sets the color axis- Since:
- 7.2.1.0
-
setColorAxis
public void setColorAxis(ColorAxis... colorAxis)
Sets the color axis- Since:
- 7.2.1.0
-
getNoData
public NoData getNoData()
Returns the no-data options- Since:
- 1.1.0
-
setNoData
public void setNoData(NoData noData)
Sets the no-data options- Since:
- 1.1.0
-
getChart
public Chart getChart()
Returns the chart options
-
setChart
public void setChart(Chart chart)
Sets the chart options
-
getCredits
public Credits getCredits()
Returns the credits options
-
setCredits
public void setCredits(Credits credits)
Sets the credits options
-
getData
public Data getData()
Returns the data options- Since:
- 11.2.0.0
-
setData
public void setData(Data data)
Sets the data options- Since:
- 11.2.0.0
-
getDrilldown
public Drilldown getDrilldown()
Returns the drilldown options
-
setDrilldown
public void setDrilldown(Drilldown drilldown)
Sets the drilldown options
-
getLabels
public Labels getLabels()
Returns the labels options
-
setLabels
public void setLabels(Labels labels)
Sets the labels options
-
getLang
public Lang getLang()
Returns the labels options- Since:
- 11.2.0.0
-
setLang
public void setLang(Lang lang)
Sets the lang options- Since:
- 11.2.0.0
-
getLegend
public Legend getLegend()
Returns the legend options
-
setLegend
public void setLegend(Legend legend)
Sets the legend options
-
getLoading
public Loading getLoading()
Returns the loading options
-
setLoading
public void setLoading(Loading loading)
Sets the loading options
-
getNavigation
public Navigation getNavigation()
Returns the navigation options
-
setNavigation
public void setNavigation(Navigation navigation)
Sets the navigation options
-
getPlotOptions
public PlotOptions getPlotOptions()
Returns the plot options
-
setPlotOptions
public void setPlotOptions(PlotOptions plotOptions)
Sets the plot options
-
getSonification
public Sonification getSonification()
Returns the sonification options- Since:
- 11.2.0.0
-
setSonification
public void setSonification(Sonification sonification)
Sets the sonification options- Since:
- 11.2.0.0
-
getSubtitle
public Subtitle getSubtitle()
Returns the subtitle options
-
setSubtitle
public void setSubtitle(Subtitle subtitle)
Sets the subtitle options
-
getTitle
public Title getTitle()
Returns the title options
-
setTitle
public void setTitle(Title title)
Sets the title options- Parameters:
title
-
-
getTooltip
public Tooltip getTooltip()
Returns the tooltip options
-
setTooltip
public void setTooltip(Tooltip tooltip)
Sets the tooltip options
-
getPane
public Pane getPane()
Returns the pane at the index 0
-
getPaneSize
public int getPaneSize()
Return the size of the pane list
-
getPane
public Pane getPane(int index)
Returns the pane from the given index
-
getAnnotations
public Annotation getAnnotations()
Returns the annotation at the index 0.- Since:
- 7.2.1.0
-
getAnnotationsSize
public int getAnnotationsSize()
Returns the size of the annotation list.- Since:
- 7.2.1.0
-
getAnnotations
public Annotation getAnnotations(int index)
Returns the annotation from the given index.- Since:
- 7.2.1.0
-
addAnnotations
public void addAnnotations(Annotation annotation)
Sets the annotation with out putting it in an Array.- Since:
- 7.2.1.0
-
getCaption
public Caption getCaption()
Returns the caption options.- Since:
- 7.2.1.0
-
setCaption
public void setCaption(Caption caption)
Sets the caption options.- Since:
- 7.2.1.0
-
getResponsive
public Responsive getResponsive()
- Since:
- 7.2.1.0
-
setResponsive
public void setResponsive(Responsive responsive)
- Since:
- 7.2.1.0
-
toJSONString
public String toJSONString()
- Specified by:
toJSONString
in interfaceorg.zkoss.json.JSONAware
-
-