public class TaskSeriesCollection extends AbstractSeriesDataset implements GanttCategoryDataset, java.lang.Cloneable, org.jfree.util.PublicCloneable, java.io.Serializable
TaskSeries
objects. This class provides one
implementation of the GanttCategoryDataset
interface.Constructor and Description |
---|
TaskSeriesCollection()
Default constructor.
|
Modifier and Type | Method and Description |
---|---|
void |
add(TaskSeries series)
Adds a series to the dataset and sends a
DatasetChangeEvent to all registered
listeners. |
java.lang.Object |
clone()
Returns an independent copy of this dataset.
|
boolean |
equals(java.lang.Object obj)
Tests this instance for equality with an arbitrary object.
|
int |
getColumnCount()
Returns the number of column in the dataset.
|
int |
getColumnIndex(java.lang.Comparable columnKey)
Returns the column index for a column key.
|
java.lang.Comparable |
getColumnKey(int index)
Returns a column key.
|
java.util.List |
getColumnKeys()
Returns a list of the column keys in the dataset.
|
java.lang.Number |
getEndValue(java.lang.Comparable rowKey,
java.lang.Comparable columnKey)
Returns the end value for a task.
|
java.lang.Number |
getEndValue(java.lang.Comparable rowKey,
java.lang.Comparable columnKey,
int subinterval)
Returns the end value of a sub-interval for a given item.
|
java.lang.Number |
getEndValue(int row,
int column)
Returns the end value for a task.
|
java.lang.Number |
getEndValue(int row,
int column,
int subinterval)
Returns the end value of a sub-interval for a given item.
|
java.lang.Number |
getPercentComplete(java.lang.Comparable rowKey,
java.lang.Comparable columnKey)
Returns the percent complete for a given item.
|
java.lang.Number |
getPercentComplete(java.lang.Comparable rowKey,
java.lang.Comparable columnKey,
int subinterval)
Returns the percentage complete value of a sub-interval for a given item.
|
java.lang.Number |
getPercentComplete(int row,
int column)
Returns the percent complete for a given item.
|
java.lang.Number |
getPercentComplete(int row,
int column,
int subinterval)
Returns the percentage complete value of a sub-interval for a given item.
|
int |
getRowCount()
Returns the number of rows (series) in the collection.
|
int |
getRowIndex(java.lang.Comparable rowKey)
Returns the row index for the given row key.
|
java.lang.Comparable |
getRowKey(int index)
Returns the key for a row.
|
java.util.List |
getRowKeys()
Returns the row keys.
|
TaskSeries |
getSeries(java.lang.Comparable key)
Returns a series from the collection.
|
TaskSeries |
getSeries(int series)
Returns a series from the collection.
|
int |
getSeriesCount()
Returns the number of series in the collection.
|
java.lang.Comparable |
getSeriesKey(int series)
Returns the name of a series.
|
java.lang.Number |
getStartValue(java.lang.Comparable rowKey,
java.lang.Comparable columnKey)
Returns the start value for a task.
|
java.lang.Number |
getStartValue(java.lang.Comparable rowKey,
java.lang.Comparable columnKey,
int subinterval)
Returns the start value of a sub-interval for a given item.
|
java.lang.Number |
getStartValue(int row,
int column)
Returns the start value for a task.
|
java.lang.Number |
getStartValue(int row,
int column,
int subinterval)
Returns the start value of a sub-interval for a given item.
|
int |
getSubIntervalCount(java.lang.Comparable rowKey,
java.lang.Comparable columnKey)
Returns the number of sub-intervals for a given item.
|
int |
getSubIntervalCount(int row,
int column)
Returns the number of sub-intervals for a given item.
|
java.lang.Number |
getValue(java.lang.Comparable rowKey,
java.lang.Comparable columnKey)
Returns the value for an item.
|
java.lang.Number |
getValue(int row,
int column)
Returns the value for a task.
|
void |
remove(int series)
Removes a series from the collection and sends
a
DatasetChangeEvent
to all registered listeners. |
void |
remove(TaskSeries series)
Removes a series from the collection and sends
a
DatasetChangeEvent
to all registered listeners. |
void |
removeAll()
Removes all the series from the collection and sends
a
DatasetChangeEvent
to all registered listeners. |
void |
seriesChanged(SeriesChangeEvent event)
Called when a series belonging to the dataset changes.
|
indexOf
addChangeListener, fireDatasetChanged, getGroup, getNotify, hasListener, notifyListeners, removeChangeListener, setGroup, setNotify, validateObject
finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
addChangeListener, getGroup, removeChangeListener, setGroup
public TaskSeriesCollection()
public TaskSeries getSeries(java.lang.Comparable key)
key
- the series key (null
not permitted).public TaskSeries getSeries(int series)
series
- the series index (zero-based).public int getSeriesCount()
getSeriesCount
in interface SeriesDataset
getSeriesCount
in class AbstractSeriesDataset
public java.lang.Comparable getSeriesKey(int series)
getSeriesKey
in interface SeriesDataset
getSeriesKey
in class AbstractSeriesDataset
series
- the series index (zero-based).public int getRowCount()
getRowCount
in interface Values2D
public java.util.List getRowKeys()
getRowKeys
in interface KeyedValues2D
public int getColumnCount()
getColumnCount
in interface Values2D
public java.util.List getColumnKeys()
getColumnKeys
in interface KeyedValues2D
public java.lang.Comparable getColumnKey(int index)
getColumnKey
in interface KeyedValues2D
index
- the column index.public int getColumnIndex(java.lang.Comparable columnKey)
getColumnIndex
in interface KeyedValues2D
columnKey
- the column key (null
not permitted).public int getRowIndex(java.lang.Comparable rowKey)
getRowIndex
in interface KeyedValues2D
rowKey
- the row key.public java.lang.Comparable getRowKey(int index)
getRowKey
in interface KeyedValues2D
index
- the row index (zero-based).public void add(TaskSeries series)
DatasetChangeEvent
to all registered
listeners.series
- the series (null
not permitted).public void remove(TaskSeries series)
DatasetChangeEvent
to all registered listeners.series
- the series.public void remove(int series)
DatasetChangeEvent
to all registered listeners.series
- the series (zero based index).public void removeAll()
DatasetChangeEvent
to all registered listeners.public java.lang.Number getValue(java.lang.Comparable rowKey, java.lang.Comparable columnKey)
getValue
in interface KeyedValues2D
rowKey
- the row key.columnKey
- the column key.public java.lang.Number getValue(int row, int column)
public java.lang.Number getStartValue(java.lang.Comparable rowKey, java.lang.Comparable columnKey)
getStartValue
in interface IntervalCategoryDataset
rowKey
- the series.columnKey
- the category.null
).IntervalCategoryDataset.getEndValue(Comparable, Comparable)
public java.lang.Number getStartValue(int row, int column)
getStartValue
in interface IntervalCategoryDataset
row
- the row index (zero-based).column
- the column index (zero-based).IntervalCategoryDataset.getEndValue(int, int)
public java.lang.Number getEndValue(java.lang.Comparable rowKey, java.lang.Comparable columnKey)
getEndValue
in interface IntervalCategoryDataset
rowKey
- the series.columnKey
- the category.null
).IntervalCategoryDataset.getStartValue(Comparable, Comparable)
public java.lang.Number getEndValue(int row, int column)
getEndValue
in interface IntervalCategoryDataset
row
- the row index (zero-based).column
- the column index (zero-based).IntervalCategoryDataset.getStartValue(int, int)
public java.lang.Number getPercentComplete(int row, int column)
getPercentComplete
in interface GanttCategoryDataset
row
- the row index (zero-based).column
- the column index (zero-based).null
).GanttCategoryDataset.getPercentComplete(Comparable, Comparable)
public java.lang.Number getPercentComplete(java.lang.Comparable rowKey, java.lang.Comparable columnKey)
getPercentComplete
in interface GanttCategoryDataset
rowKey
- the row key.columnKey
- the column key.GanttCategoryDataset.getPercentComplete(int, int)
public int getSubIntervalCount(int row, int column)
getSubIntervalCount
in interface GanttCategoryDataset
row
- the row index (zero-based).column
- the column index (zero-based).GanttCategoryDataset.getSubIntervalCount(Comparable, Comparable)
public int getSubIntervalCount(java.lang.Comparable rowKey, java.lang.Comparable columnKey)
getSubIntervalCount
in interface GanttCategoryDataset
rowKey
- the row key.columnKey
- the column key.GanttCategoryDataset.getSubIntervalCount(int, int)
public java.lang.Number getStartValue(int row, int column, int subinterval)
getStartValue
in interface GanttCategoryDataset
row
- the row index (zero-based).column
- the column index (zero-based).subinterval
- the sub-interval index (zero-based).null
).GanttCategoryDataset.getEndValue(int, int, int)
public java.lang.Number getStartValue(java.lang.Comparable rowKey, java.lang.Comparable columnKey, int subinterval)
getStartValue
in interface GanttCategoryDataset
rowKey
- the row key.columnKey
- the column key.subinterval
- the subinterval.null
).GanttCategoryDataset.getEndValue(Comparable, Comparable, int)
public java.lang.Number getEndValue(int row, int column, int subinterval)
getEndValue
in interface GanttCategoryDataset
row
- the row index (zero-based).column
- the column index (zero-based).subinterval
- the subinterval.null
).GanttCategoryDataset.getStartValue(int, int, int)
public java.lang.Number getEndValue(java.lang.Comparable rowKey, java.lang.Comparable columnKey, int subinterval)
getEndValue
in interface GanttCategoryDataset
rowKey
- the row key.columnKey
- the column key.subinterval
- the subinterval.null
).GanttCategoryDataset.getStartValue(Comparable, Comparable, int)
public java.lang.Number getPercentComplete(int row, int column, int subinterval)
getPercentComplete
in interface GanttCategoryDataset
row
- the row index (zero-based).column
- the column index (zero-based).subinterval
- the sub-interval.null
).GanttCategoryDataset.getPercentComplete(Comparable, Comparable, int)
public java.lang.Number getPercentComplete(java.lang.Comparable rowKey, java.lang.Comparable columnKey, int subinterval)
getPercentComplete
in interface GanttCategoryDataset
rowKey
- the row key.columnKey
- the column key.subinterval
- the sub-interval.null
).GanttCategoryDataset.getPercentComplete(int, int, int)
public void seriesChanged(SeriesChangeEvent event)
seriesChanged
in interface SeriesChangeListener
seriesChanged
in class AbstractSeriesDataset
event
- information about the change.public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
obj
- the object (null
permitted).public java.lang.Object clone() throws java.lang.CloneNotSupportedException
clone
in interface org.jfree.util.PublicCloneable
clone
in class AbstractDataset
java.lang.CloneNotSupportedException
- if there is some problem cloning
the dataset.