net.sf.jomic.tools
Class NestedTask

java.lang.Object
  extended by net.sf.jomic.tools.AbstractTask
      extended by net.sf.jomic.tools.NestedTask
All Implemented Interfaces:
ProgressChangeListener, Task

public class NestedTask
extends AbstractTask
implements ProgressChangeListener

A task composed of sub-tasks.

Author:
Thomas Aglassinger

Constructor Summary
NestedTask(Task[] newSubTasks)
           
NestedTask(Task[] newSubTasks, boolean newAfterErrorContinueWithNextTask)
           
 
Method Summary
 void progressChanged(Task source)
          Listen to progress changes in sub-tasks and update the total progress of the nested task accordingly.
 void start()
          Run the sub-tasks.
 
Methods inherited from class net.sf.jomic.tools.AbstractTask
addProgressChangeListener, getMaxProgress, getProgress, getProgressMessage, isInterrupted, removeProgressChangeListener, setMaxProgress, setProgress, setProgressMessage
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

NestedTask

public NestedTask(Task[] newSubTasks)

NestedTask

public NestedTask(Task[] newSubTasks,
                  boolean newAfterErrorContinueWithNextTask)
Method Detail

progressChanged

public void progressChanged(Task source)
Listen to progress changes in sub-tasks and update the total progress of the nested task accordingly.

Specified by:
progressChanged in interface ProgressChangeListener

start

public void start()
           throws java.lang.Exception
Run the sub-tasks.

Specified by:
start in interface Task
Specified by:
start in class AbstractTask
Throws:
java.lang.Exception