fsmvis.utils
Interface MonitorableTask

All Known Implementing Classes:
CSVLoader

public abstract interface MonitorableTask


Method Summary
 void doneWork()
          A method that is called when ever an item of work has been completed
 void doneWork(int units)
          A method that is called when ever a number of work items have been completed
 int getLengthOfTask()
          Returns the length of this current task, this is defined to be some kind of abstract work unit.
 int getProgress()
          Returns the current progress through this task.
 boolean isFinished()
          Returns whether or not the current task has been completed
 

Method Detail

getLengthOfTask

public int getLengthOfTask()
Returns the length of this current task, this is defined to be some kind of abstract work unit. For example a 1000 line text file might return a task length of 1000, and would consider reading a line of the file as doing a unit of work
Returns:
The length of the task in abstract work units

getProgress

public int getProgress()
Returns the current progress through this task. This is the number of units that have been completed
Returns:
The current progress through the task

isFinished

public boolean isFinished()
Returns whether or not the current task has been completed
Returns:
Whether or not the task has finished

doneWork

public void doneWork()
A method that is called when ever an item of work has been completed

doneWork

public void doneWork(int units)
A method that is called when ever a number of work items have been completed
Parameters:
units - The number of work units that where comleted