Package org.zkoss.zul
Interface XYModel
- All Superinterfaces:
ChartModel
- All Known Subinterfaces:
XYZModel
- All Known Implementing Classes:
SimpleXYModel,SimpleXYZModel
A XY chart data model.
- Author:
- henrichen
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionvoidaddValue(Comparable<?> series, Number x, Number y) Append an (x,y) into a series.voidaddValue(Comparable<?> series, Number x, Number y, int index) Add an (x,y) into a series at specified index.voidclear()clear this model.intgetDataCount(Comparable<?> series) Get data count of a specified series.Collection<Comparable<?>>Get all series as a collection.Comparable<?>getSeries(int index) Get a series of the specified index;getX(Comparable<?> series, int index) Get X value of a specified series and data index.getY(Comparable<?> series, int index) Get Y value of a specified series and data index.booleancheck whether to autosort on x value for each series; default is true.voidremoveSeries(Comparable<?> series) Remove data of a specified series.voidremoveValue(Comparable<?> series, int index) Remove (x,y) value of a specified series and data index.voidsetAutoSort(boolean auto) Set model to autosort on x value for each series.voidsetValue(Comparable<?> series, Number x, Number y, int index) Replace the value of the new (x,y) into a series at specified index.Methods inherited from interface org.zkoss.zul.ChartModel
addChartDataListener, removeChartDataListener
-
Method Details
-
getSeries
Get a series of the specified index; -
getSeries
Collection<Comparable<?>> getSeries()Get all series as a collection. -
getDataCount
Get data count of a specified series.- Parameters:
series- the specified series.
-
getX
Get X value of a specified series and data index.- Parameters:
series- the series.index- the data index.
-
getY
Get Y value of a specified series and data index.- Parameters:
series- the series.index- the data index.
-
setValue
Replace the value of the new (x,y) into a series at specified index.- Parameters:
series- the seriesx- the x valuey- the y valueindex- the data index- Since:
- 5.0.0
-
addValue
Append an (x,y) into a series.- Parameters:
series- the series.x- the x value.y- the y value.
-
addValue
Add an (x,y) into a series at specified index.- Parameters:
series- the series.x- the x value.y- the y value.index- the data index.- Since:
- 5.0.0
-
setAutoSort
void setAutoSort(boolean auto) Set model to autosort on x value for each series. -
isAutoSort
boolean isAutoSort()check whether to autosort on x value for each series; default is true. -
removeSeries
Remove data of a specified series.- Parameters:
series- the series
-
removeValue
Remove (x,y) value of a specified series and data index.- Parameters:
series- the series.index- the data index.
-
clear
void clear()clear this model.
-