Package org.zkoss.zul
Class SimpleSingleValueCategoryModel
java.lang.Object
org.zkoss.zul.AbstractChartModel
org.zkoss.zul.SimpleSingleValueCategoryModel
- All Implemented Interfaces:
Serializable,ChartModel,SingleValueCategoryModel
- Direct Known Subclasses:
SimplePieModel
public class SimpleSingleValueCategoryModel
extends AbstractChartModel
implements SingleValueCategoryModel
A Pie chart data model implementation of
SingleValueCategoryModel.
SimpleSingleValueCategoryModel used by PieChart and FunnelChart is a series of (Category, singleValue) data objects.- Author:
- henrichen, rwenzel
- See Also:
-
Field Summary
Fields inherited from class org.zkoss.zul.AbstractChartModel
_listeners -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidclear()clear the model.clone()Collection<Comparable<?>>Get categories as a collection.Comparable<?>getCategory(int index) Get category of the specified index (0 based).getValue(Comparable<?> category) Get value of the specified category.voidremoveValue(Comparable<?> category) remove the value of the specified category.voidsetValue(Comparable<?> category, Number value) add or update the value of a specified category.Methods inherited from class org.zkoss.zul.AbstractChartModel
addChartDataListener, fireEvent, removeChartDataListenerMethods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.zkoss.zul.ChartModel
addChartDataListener, removeChartDataListener
-
Constructor Details
-
SimpleSingleValueCategoryModel
public SimpleSingleValueCategoryModel()
-
-
Method Details
-
getCategory
Description copied from interface:SingleValueCategoryModelGet category of the specified index (0 based).- Specified by:
getCategoryin interfaceSingleValueCategoryModel- Parameters:
index- the index of the category.
-
getCategories
Description copied from interface:SingleValueCategoryModelGet categories as a collection.- Specified by:
getCategoriesin interfaceSingleValueCategoryModel
-
getValue
Description copied from interface:SingleValueCategoryModelGet value of the specified category.- Specified by:
getValuein interfaceSingleValueCategoryModel- Parameters:
category- the pie category.
-
setValue
Description copied from interface:SingleValueCategoryModeladd or update the value of a specified category.- Specified by:
setValuein interfaceSingleValueCategoryModel- Parameters:
category- the pie category.value- the pie value.
-
removeValue
Description copied from interface:SingleValueCategoryModelremove the value of the specified category.- Specified by:
removeValuein interfaceSingleValueCategoryModel- Parameters:
category- the pie category.
-
clear
public void clear()Description copied from interface:SingleValueCategoryModelclear the model.- Specified by:
clearin interfaceSingleValueCategoryModel
-
clone
- Overrides:
clonein classAbstractChartModel
-