01: /* ChartModel.java
02:
03: {{IS_NOTE
04: Purpose:
05:
06: Description:
07:
08: History:
09: Wed Aug 03 11:22:44 2006, Created by henrichen
10: }}IS_NOTE
11:
12: Copyright (C) 2006 Potix Corporation. All Rights Reserved.
13:
14: {{IS_RIGHT
15: This program is distributed under GPL Version 2.0 in the hope that
16: it will be useful, but WITHOUT ANY WARRANTY.
17: }}IS_RIGHT
18: */
19: package org.zkoss.zul;
20:
21: import org.zkoss.zul.event.ChartDataListener;
22:
23: /**
24: * Chart Model is used to hold the data model for the chart.
25: * <ul>
26: * <li>{@link PieModel}: one series of data objects. Each data object contains the category name and numeric value of a pie.</li>
27: * <li>{@link CategoryModel}: n series of data objects. Each data object contains the category name and associated numeric value .</li>
28: * <li>{@link XYModel}: n series of data objects. Each data object contains an (x,y) pair.</li>
29: * </ul>
30: *
31: * This interface defines the data model for components like {@link Chart}
32: * use to get the value of data.
33: *
34: * @author henrichen
35: * @see Chart
36: * @see PieModel
37: * @see CategoryModel
38: * @see XYModel
39: * @see org.zkoss.zul.event.ChartAreaListener
40: */
41: public interface ChartModel {
42: /** Adds a listener to the chart that's notified each time a change
43: * to the data model occurs.
44: */
45: public void addChartDataListener(ChartDataListener l);
46:
47: /** Removes a listener from the chart that's notified each time
48: * a change to the data model occurs.
49: */
50: public void removeChartDataListener(ChartDataListener l);
51: }
|