org.jfree.data.gantt

Class TaskSeriesCollection

public class TaskSeriesCollection extends AbstractSeriesDataset implements GanttCategoryDataset, Cloneable, PublicCloneable, Serializable

A collection of TaskSeries objects. This class provides one implementation of the GanttCategoryDataset interface.
Constructor Summary
TaskSeriesCollection()
Default constructor.
Method Summary
voidadd(TaskSeries series)
Adds a series to the dataset and sends a DatasetChangeEvent to all registered listeners.
Objectclone()
Returns an independent copy of this dataset.
booleanequals(Object obj)
Tests this instance for equality with an arbitrary object.
intgetColumnCount()
Returns the number of column in the dataset.
intgetColumnIndex(Comparable columnKey)
Returns the column index for a column key.
ComparablegetColumnKey(int index)
Returns a column key.
ListgetColumnKeys()
Returns a list of the column keys in the dataset.
NumbergetEndValue(Comparable rowKey, Comparable columnKey)
Returns the end value for a task.
NumbergetEndValue(int row, int column)
Returns the end value for a task.
NumbergetEndValue(int row, int column, int subinterval)
Returns the end value of a sub-interval for a given item.
NumbergetEndValue(Comparable rowKey, Comparable columnKey, int subinterval)
Returns the end value of a sub-interval for a given item.
NumbergetPercentComplete(int row, int column)
Returns the percent complete for a given item.
NumbergetPercentComplete(Comparable rowKey, Comparable columnKey)
Returns the percent complete for a given item.
NumbergetPercentComplete(int row, int column, int subinterval)
Returns the percentage complete value of a sub-interval for a given item.
NumbergetPercentComplete(Comparable rowKey, Comparable columnKey, int subinterval)
Returns the percentage complete value of a sub-interval for a given item.
intgetRowCount()
Returns the number of rows (series) in the collection.
intgetRowIndex(Comparable rowKey)
Returns the row index for the given row key.
ComparablegetRowKey(int index)
Returns the key for a row.
ListgetRowKeys()
Returns the row keys.
TaskSeriesgetSeries(Comparable key)
Returns a series from the collection.
TaskSeriesgetSeries(int series)
Returns a series from the collection.
intgetSeriesCount()
Returns the number of series in the collection.
ComparablegetSeriesKey(int series)
Returns the name of a series.
NumbergetStartValue(Comparable rowKey, Comparable columnKey)
Returns the start value for a task.
NumbergetStartValue(int row, int column)
Returns the start value for a task.
NumbergetStartValue(int row, int column, int subinterval)
Returns the start value of a sub-interval for a given item.
NumbergetStartValue(Comparable rowKey, Comparable columnKey, int subinterval)
Returns the start value of a sub-interval for a given item.
intgetSubIntervalCount(int row, int column)
Returns the number of sub-intervals for a given item.
intgetSubIntervalCount(Comparable rowKey, Comparable columnKey)
Returns the number of sub-intervals for a given item.
NumbergetValue(Comparable rowKey, Comparable columnKey)
Returns the value for an item.
NumbergetValue(int row, int column)
Returns the value for a task.
voidremove(TaskSeries series)
Removes a series from the collection and sends a DatasetChangeEvent to all registered listeners.
voidremove(int series)
Removes a series from the collection and sends a DatasetChangeEvent to all registered listeners.
voidremoveAll()
Removes all the series from the collection and sends a DatasetChangeEvent to all registered listeners.
voidseriesChanged(SeriesChangeEvent event)
Called when a series belonging to the dataset changes.

Constructor Detail

TaskSeriesCollection

public TaskSeriesCollection()
Default constructor.

Method Detail

add

public void add(TaskSeries series)
Adds a series to the dataset and sends a DatasetChangeEvent to all registered listeners.

Parameters: series the series (null not permitted).

clone

public Object clone()
Returns an independent copy of this dataset.

Returns: A clone of the dataset.

Throws: CloneNotSupportedException if there is some problem cloning the dataset.

equals

public boolean equals(Object obj)
Tests this instance for equality with an arbitrary object.

Parameters: obj the object (null permitted).

Returns: A boolean.

getColumnCount

public int getColumnCount()
Returns the number of column in the dataset.

Returns: The column count.

getColumnIndex

public int getColumnIndex(Comparable columnKey)
Returns the column index for a column key.

Parameters: columnKey the column key (null not permitted).

Returns: The column index.

getColumnKey

public Comparable getColumnKey(int index)
Returns a column key.

Parameters: index the column index.

Returns: The column key.

getColumnKeys

public List getColumnKeys()
Returns a list of the column keys in the dataset.

Returns: The category list.

getEndValue

public Number getEndValue(Comparable rowKey, Comparable columnKey)
Returns the end value for a task. This is a date/time value, measured in milliseconds since 1-Jan-1970.

Parameters: rowKey the series. columnKey the category.

Returns: The end value (possibly null).

getEndValue

public Number getEndValue(int row, int column)
Returns the end value for a task.

Parameters: row the row index (zero-based). column the column index (zero-based).

Returns: The end value.

getEndValue

public Number getEndValue(int row, int column, int subinterval)
Returns the end value of a sub-interval for a given item.

Parameters: row the row index (zero-based). column the column index (zero-based). subinterval the subinterval.

Returns: The end value (possibly null).

getEndValue

public Number getEndValue(Comparable rowKey, Comparable columnKey, int subinterval)
Returns the end value of a sub-interval for a given item.

Parameters: rowKey the row key. columnKey the column key. subinterval the subinterval.

Returns: The end value (possibly null).

getPercentComplete

public Number getPercentComplete(int row, int column)
Returns the percent complete for a given item.

Parameters: row the row index (zero-based). column the column index (zero-based).

Returns: The percent complete (possibly null).

getPercentComplete

public Number getPercentComplete(Comparable rowKey, Comparable columnKey)
Returns the percent complete for a given item.

Parameters: rowKey the row key. columnKey the column key.

Returns: The percent complete.

getPercentComplete

public Number getPercentComplete(int row, int column, int subinterval)
Returns the percentage complete value of a sub-interval for a given item.

Parameters: row the row index (zero-based). column the column index (zero-based). subinterval the sub-interval.

Returns: The percent complete value (possibly null).

getPercentComplete

public Number getPercentComplete(Comparable rowKey, Comparable columnKey, int subinterval)
Returns the percentage complete value of a sub-interval for a given item.

Parameters: rowKey the row key. columnKey the column key. subinterval the sub-interval.

Returns: The percent complete value (possibly null).

getRowCount

public int getRowCount()
Returns the number of rows (series) in the collection.

Returns: The series count.

getRowIndex

public int getRowIndex(Comparable rowKey)
Returns the row index for the given row key.

Parameters: rowKey the row key.

Returns: The index.

getRowKey

public Comparable getRowKey(int index)
Returns the key for a row.

Parameters: index the row index (zero-based).

Returns: The key.

getRowKeys

public List getRowKeys()
Returns the row keys. In this case, each series is a key.

Returns: The row keys.

getSeries

public TaskSeries getSeries(Comparable key)
Returns a series from the collection.

Parameters: key the series key (null not permitted).

Returns: The series.

Since: 1.0.1

getSeries

public TaskSeries getSeries(int series)
Returns a series from the collection.

Parameters: series the series index (zero-based).

Returns: The series.

Since: 1.0.1

getSeriesCount

public int getSeriesCount()
Returns the number of series in the collection.

Returns: The series count.

getSeriesKey

public Comparable getSeriesKey(int series)
Returns the name of a series.

Parameters: series the series index (zero-based).

Returns: The name of a series.

getStartValue

public Number getStartValue(Comparable rowKey, Comparable columnKey)
Returns the start value for a task. This is a date/time value, measured in milliseconds since 1-Jan-1970.

Parameters: rowKey the series. columnKey the category.

Returns: The start value (possibly null).

getStartValue

public Number getStartValue(int row, int column)
Returns the start value for a task.

Parameters: row the row index (zero-based). column the column index (zero-based).

Returns: The start value.

getStartValue

public Number getStartValue(int row, int column, int subinterval)
Returns the start value of a sub-interval for a given item.

Parameters: row the row index (zero-based). column the column index (zero-based). subinterval the sub-interval index (zero-based).

Returns: The start value (possibly null).

getStartValue

public Number getStartValue(Comparable rowKey, Comparable columnKey, int subinterval)
Returns the start value of a sub-interval for a given item.

Parameters: rowKey the row key. columnKey the column key. subinterval the subinterval.

Returns: The start value (possibly null).

getSubIntervalCount

public int getSubIntervalCount(int row, int column)
Returns the number of sub-intervals for a given item.

Parameters: row the row index (zero-based). column the column index (zero-based).

Returns: The sub-interval count.

getSubIntervalCount

public int getSubIntervalCount(Comparable rowKey, Comparable columnKey)
Returns the number of sub-intervals for a given item.

Parameters: rowKey the row key. columnKey the column key.

Returns: The sub-interval count.

getValue

public Number getValue(Comparable rowKey, Comparable columnKey)
Returns the value for an item.

Parameters: rowKey the row key. columnKey the column key.

Returns: The item value.

getValue

public Number getValue(int row, int column)
Returns the value for a task.

Parameters: row the row index (zero-based). column the column index (zero-based).

Returns: The start value.

remove

public void remove(TaskSeries series)
Removes a series from the collection and sends a DatasetChangeEvent to all registered listeners.

Parameters: series the series.

remove

public void remove(int series)
Removes a series from the collection and sends a DatasetChangeEvent to all registered listeners.

Parameters: series the series (zero based index).

removeAll

public void removeAll()
Removes all the series from the collection and sends a DatasetChangeEvent to all registered listeners.

seriesChanged

public void seriesChanged(SeriesChangeEvent event)
Called when a series belonging to the dataset changes.

Parameters: event information about the change.

Copyright © 2000-2009 by Object Refinery Limited. All Rights Reserved.