com.jidesoft.chart.model
Class ChartModelChangeEvent
java.lang.Object
java.util.EventObject
com.jidesoft.chart.model.ChartModelChangeEvent
- All Implemented Interfaces:
- Serializable
public class ChartModelChangeEvent
- extends EventObject
An event object to signify a change in a ChartModel
- See Also:
ChartModelChangeListener
,
Serialized Form
ChartModelChangeEvent
public ChartModelChangeEvent(Object source,
ChartModelChangeType changeType,
int index)
- Create a ChartModelChangeEvent and indicate the index in the model at which the change occurred
- Parameters:
source
- the ChartModel object that is the source of the changeindex
- the index at which the change occurred
ChartModelChangeEvent
public ChartModelChangeEvent(Object source,
ChartModelChangeType changeType,
int index,
int size)
- Create a ChartModelChangeEvent and indicate the index in the model at which the change occurred
as well as the number of points affected.
- Parameters:
source
- the ChartModel object that is the source of the changeindex
- the index at which the change occurredsize
- the number of points affected by the change
getChangeType
public ChartModelChangeType getChangeType()
- The type of the change: Was it an insertion, deletion or modification?
- Returns:
- the change type
setChangeType
public void setChangeType(ChartModelChangeType changeType)
- Specify the type of the change
- Parameters:
changeType
- the change type
getIndex
public int getIndex()
- Returns:
- the index of the model where the change occurred (prior to the change).
By default this is set to 0.
getSize
public int getSize()
- Returns:
- the number of points affected by the change; for example the number of points inserted or deleted.
By default this is set at 1.
hashCode
public int hashCode()
- Overrides:
hashCode
in class Object
equals
public boolean equals(Object obj)
- Overrides:
equals
in class Object
toString
public String toString()
- Overrides:
toString
in class EventObject