juife
v0.1a

net.sf.juife
Class TaskList

java.lang.Object
  extended by net.sf.juife.TaskList

public class TaskList
extends java.lang.Object

This class represents a list of tasks held for further processing.


Field Summary
protected  javax.swing.event.EventListenerList listenerList
          A list of event listeners for this TaskList.
 
Constructor Summary
TaskList()
          Creates a new instance of TaskList.
TaskList(java.lang.String name)
          Creates a new instance of TaskList with the specified name.
TaskList(java.lang.String name, Task... tasks)
          Creates a new instance of TaskList with the specified name and adds the specified tasks to the list.
TaskList(Task... tasks)
          Creates a new instance of TaskList and adds the specified tasks.
 
Method Summary
 void add(Task task)
          Adds the specified task to this task list.
 void addActionListener(java.awt.event.ActionListener l)
          Registers the specified ActionListener to be notified when all tasks in the list are done.
 boolean isProcessed()
          Determines whether all of the tasks in the list are done.
 boolean isStarted()
          Determines whether the processing of the tasks in the list has been started.
 void process()
          Starts the processing of the tasks in this list.
 void removeActionListener(java.awt.event.ActionListener l)
          Removes the specified listener.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

listenerList

protected final javax.swing.event.EventListenerList listenerList
A list of event listeners for this TaskList.

Constructor Detail

TaskList

public TaskList()
Creates a new instance of TaskList.


TaskList

public TaskList(java.lang.String name)
Creates a new instance of TaskList with the specified name.

Parameters:
name - The name of the task list.

TaskList

public TaskList(Task... tasks)
Creates a new instance of TaskList and adds the specified tasks.

Parameters:
tasks - The tasks to be added to the newly created task list.

TaskList

public TaskList(java.lang.String name,
                Task... tasks)
Creates a new instance of TaskList with the specified name and adds the specified tasks to the list.

Parameters:
name - The name of the task list.
tasks - The tasks to be added to the newly created task list.
Method Detail

add

public void add(Task task)
Adds the specified task to this task list.

Parameters:
task - The task to be added.
Throws:
java.lang.IllegalStateException - If the processing of the tasks in the list is already started.

process

public void process()
Starts the processing of the tasks in this list.


isStarted

public boolean isStarted()
Determines whether the processing of the tasks in the list has been started.

Returns:
true if the processing of the tasks in the list has been started, false otherwise.

isProcessed

public boolean isProcessed()
Determines whether all of the tasks in the list are done.

Returns:
true if all tasks in the list are done, false otherwise.

addActionListener

public void addActionListener(java.awt.event.ActionListener l)
Registers the specified ActionListener to be notified when all tasks in the list are done.

Parameters:
l - The ActionListener to register.

removeActionListener

public void removeActionListener(java.awt.event.ActionListener l)
Removes the specified listener.

Parameters:
l - The ActionListener to remove.

juife
v0.1a

Copyright © 2005 Grigor Iliev. All rights reserved. SourceForge.net Logo