Package org.zkoss.chart.model
Class AbstractChartsModel
- java.lang.Object
-
- org.zkoss.chart.model.AbstractChartsModel
-
- All Implemented Interfaces:
Serializable
,ChartsModel
- Direct Known Subclasses:
ChartsModelProxy
,DefaultBoxPlotModel
,DefaultCategoryModel
,DefaultDialModel
,DefaultFromToModel
,DefaultSingleValueCategoryModel
,DefaultXYModel
public abstract class AbstractChartsModel extends Object implements ChartsModel, Serializable
A skeletal implementation forChartsModel
.- Author:
- jumperchen
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected List<ChartsDataListener>
_listeners
-
Constructor Summary
Constructors Constructor Description AbstractChartsModel()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addChartsDataListener(ChartsDataListener l)
Adds a listener to the chart that's notified each time a change to the data model occurs.Object
clone()
protected void
fireEvent(int type, Comparable<?> series, Comparable<?> category, int seriesIndex, int categoryIndex, Object data)
Fires aChartsDataEvent
for all registered listener (thruaddChartsDataListener(org.zkoss.chart.model.ChartsDataListener)
.void
removeChartsDataListener(ChartsDataListener l)
Removes a listener from the chart that's notified each time a change to the data model occurs.
-
-
-
Field Detail
-
_listeners
protected List<ChartsDataListener> _listeners
-
-
Method Detail
-
fireEvent
protected void fireEvent(int type, Comparable<?> series, Comparable<?> category, int seriesIndex, int categoryIndex, Object data)
Fires aChartsDataEvent
for all registered listener (thruaddChartsDataListener(org.zkoss.chart.model.ChartsDataListener)
.Note: you can invoke this method only in an event listener.
-
addChartsDataListener
public void addChartsDataListener(ChartsDataListener l)
Description copied from interface:ChartsModel
Adds a listener to the chart that's notified each time a change to the data model occurs.- Specified by:
addChartsDataListener
in interfaceChartsModel
-
removeChartsDataListener
public void removeChartsDataListener(ChartsDataListener l)
Description copied from interface:ChartsModel
Removes a listener from the chart that's notified each time a change to the data model occurs.- Specified by:
removeChartsDataListener
in interfaceChartsModel
-
-