com.odesys.chart
Interface ChartModel

All Known Subinterfaces:
BarChartModel, BubbleChartModel, LineChartModel, PieChartModel
All Known Implementing Classes:
DefaultChartModel

public interface ChartModel

This interface is used by the charts to access the data that needs to be shown. ChartModel defines the methods to access the data series and the methods to handle the ModelChangeListeners that are notified of all changes to the model.


Field Summary
static int COLOR
          Constant used as a hint that a color in this ChartModel was changed.
static int LABEL
          Constant used as a hint that a label in this ChartModel was changed.
static int SERIES
          Constant used as a hint that a series in this ChartModel was modified.
static int VALUE
          Constant used as a hint that a value in this ChartModel was changed.
 
Method Summary
 void addModelChangeListener(ModelChangeListener l)
          Adds a listener that is notified each time a change to the data model occurs.
 void fireModelChanged(ModelChangedEvent e)
          Notifies all registered ModelChangeListeners that this model has changed.
 int getSeriesSize()
          Gets the number of data Series of this ChartModel
 void removeModelChangeListener(ModelChangeListener l)
          Removes a listener from this ChartModel.
 java.util.Enumeration series()
          Returns an Enumeration of all data Series of this model
 

Field Detail

VALUE

public static final int VALUE
Constant used as a hint that a value in this ChartModel was changed.
See Also:
ModelChangedEvent

LABEL

public static final int LABEL
Constant used as a hint that a label in this ChartModel was changed.
See Also:
ModelChangedEvent

COLOR

public static final int COLOR
Constant used as a hint that a color in this ChartModel was changed.
See Also:
ModelChangedEvent

SERIES

public static final int SERIES
Constant used as a hint that a series in this ChartModel was modified.
See Also:
ModelChangedEvent
Method Detail

addModelChangeListener

public void addModelChangeListener(ModelChangeListener l)
Adds a listener that is notified each time a change to the data model occurs.

removeModelChangeListener

public void removeModelChangeListener(ModelChangeListener l)
Removes a listener from this ChartModel.

fireModelChanged

public void fireModelChanged(ModelChangedEvent e)
Notifies all registered ModelChangeListeners that this model has changed.

getSeriesSize

public int getSeriesSize()
Gets the number of data Series of this ChartModel

series

public java.util.Enumeration series()
Returns an Enumeration of all data Series of this model