|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||
java.lang.Objectcom.jrefinery.data.Series
com.jrefinery.data.XYSeries
public class XYSeries
Represents a sequence of zero or more data pairs in the form (x, y).
| Field Summary | |
|---|---|
protected java.util.List |
data
The list of data pairs in the series. |
| Fields inherited from class com.jrefinery.data.Series |
|---|
description, listeners, name, propertyChangeSupport |
| Constructor Summary | |
|---|---|
XYSeries(java.lang.String name)
Constructs a new xy-series that contains no data. |
|
| Method Summary | |
|---|---|
void |
add(double x,
double y)
Adds a data item to the series. |
void |
add(java.lang.Number x,
java.lang.Number y)
Adds new data to the series. |
void |
add(XYDataPair pair)
Adds a data item to the series. |
void |
clear()
Removes all data pairs from the series. |
XYDataPair |
getDataPair(int index)
Return the data pair with the specified index. |
int |
getItemCount()
Returns the number of items in the series. |
java.lang.Number |
getXValue(int index)
Returns the x-value at the specified index. |
java.lang.Number |
getYValue(int index)
Returns the y-value at the specified index. |
void |
update(int item,
java.lang.Number y)
Updates the value of an item in the series. |
| Methods inherited from class com.jrefinery.data.Series |
|---|
addChangeListener, addPropertyChangeListener, clone, fireSeriesChanged, getDescription, getName, notifyListeners, removeChangeListener, removePropertyChangeListener, setDescription, setName |
| Methods inherited from class java.lang.Object |
|---|
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected java.util.List data
| Constructor Detail |
|---|
public XYSeries(java.lang.String name)
name - The series name.| Method Detail |
|---|
public int getItemCount()
public void add(XYDataPair pair)
throws SeriesException
pair - The (x, y) pair.
SeriesException
public void add(double x,
double y)
throws SeriesException
x - The x value.y - The y value.
SeriesException
public void add(java.lang.Number x,
java.lang.Number y)
throws SeriesException
Throws an exception if the x-value is a duplicate.
x - The x-value.y - The y-value.
SeriesExceptionpublic void clear()
public XYDataPair getDataPair(int index)
index - The index.public java.lang.Number getXValue(int index)
index - The index.
public java.lang.Number getYValue(int index)
index - The index.
public void update(int item,
java.lang.Number y)
index - The item (zero based index).y - The new value.
|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||