SigPath

org.sigpath.util
Class ProgressListener

java.lang.Object
  extended by org.sigpath.util.ProgressListener

public class ProgressListener
extends Object

Progress Listener for monitoring long term tasks. Primarily Used by Swing Clients

Author:
Ethan Cerami

Constructor Summary
ProgressListener()
           
 
Method Summary
 String getCurrentMessage()
          Gets the Current Message from the Task
 int getCurrentValue()
          Gets the Current Counter Value
 ArrayList getLog()
          Gets the Log Messages
 int getMaxValue()
          Gets the Maximum Value of "things" to process
 void incrementCurrentValue()
          Increment the Current Counter Value
 boolean isDone()
          Is the Task Done?
 boolean isIndeterminate()
           
 void logMsg(String msg)
          Adds a Log Message
 void setCurrentMessage(String msg)
          Sets the Current Task Message
 void setCurrentValue(int current)
          Sets the Current Counter Value
 void setDone()
          Sets the Task Done Flag to True
 void setIndeterminate(boolean flag)
           
 void setMaxValue(int max)
          Sets the Maximum Value of "things" to process
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ProgressListener

public ProgressListener()
Method Detail

isDone

public boolean isDone()
Is the Task Done?

Returns:
true or false

setDone

public void setDone()
Sets the Task Done Flag to True


getCurrentMessage

public String getCurrentMessage()
Gets the Current Message from the Task

Returns:
current message

setCurrentMessage

public void setCurrentMessage(String msg)
Sets the Current Task Message

Parameters:
msg - Current Message

logMsg

public void logMsg(String msg)
Adds a Log Message

Parameters:
msg - Message to Add

getMaxValue

public int getMaxValue()
Gets the Maximum Value of "things" to process

Returns:
total number of things to process

setMaxValue

public void setMaxValue(int max)
Sets the Maximum Value of "things" to process

Parameters:
max - Total Number of things to process

getCurrentValue

public int getCurrentValue()
Gets the Current Counter Value

Returns:
Current Value

setCurrentValue

public void setCurrentValue(int current)
Sets the Current Counter Value

Parameters:
current - Current Counter Value

setIndeterminate

public void setIndeterminate(boolean flag)

isIndeterminate

public boolean isIndeterminate()

incrementCurrentValue

public void incrementCurrentValue()
Increment the Current Counter Value


getLog

public ArrayList getLog()
Gets the Log Messages

Returns:
ArrayList of String objects

SigPath

Copyright © 2002-2005 Institute for Computational Biomedicine, All Rights Reserved.