org.jfree.data.gantt
Class TaskSeries
- Cloneable, Serializable
A series that contains zero, one or many
Task objects.
This class is used as a building block for the
TaskSeriesCollection
class that can be used to construct basic Gantt charts.
TaskSeries(String name)- Constructs a new series with the specified name.
|
void | add(Task task)- Adds a task to the series and sends a
SeriesChangeEvent to all registered
listeners.
|
boolean | equals(Object obj)- Tests this object for equality with an arbitrary object.
|
Task | get(String description)- Returns the task in the series that has the specified description.
|
Task | get(int index)- Returns a task from the series.
|
int | getItemCount()- Returns the number of items in the series.
|
List | getTasks()- Returns an unmodifialble list of the tasks in the series.
|
void | remove(Task task)- Removes a task from the series and sends
a
SeriesChangeEvent
to all registered listeners.
|
void | removeAll()- Removes all tasks from the series and sends
a
SeriesChangeEvent
to all registered listeners.
|
addChangeListener, addPropertyChangeListener, clone, equals, firePropertyChange, fireSeriesChanged, getDescription, getKey, getNotify, hashCode, notifyListeners, removeChangeListener, removePropertyChangeListener, setDescription, setKey, setNotify |
TaskSeries
public TaskSeries(String name)
Constructs a new series with the specified name.
name - the series name (null not permitted).
add
public void add(Task task)
task - the task (null not permitted).
equals
public boolean equals(Object obj)
Tests this object for equality with an arbitrary object.
- equals in interface Series
obj - the object to test against (null permitted).
get
public Task get(String description)
Returns the task in the series that has the specified description.
description - the name (null not permitted).
- The task (possibly
null).
get
public Task get(int index)
Returns a task from the series.
index - the task index (zero-based).
getItemCount
public int getItemCount()
Returns the number of items in the series.
getTasks
public List getTasks()
Returns an unmodifialble list of the tasks in the series.