net.pacbell.jfai.toh.util
Class AbstractSwingWorkerWithWaitCursor

java.lang.Object
  extended by net.pacbell.jfai.toh.util.AbstractSwingWorker
      extended by net.pacbell.jfai.toh.util.AbstractSwingWorkerWithWaitCursor

public abstract class AbstractSwingWorkerWithWaitCursor
extends AbstractSwingWorker

Subclass to run a Runnable on the dispatch event thread while displaying the wait cursor.

Author:
Jürgen Failenschmid
See Also:
AbstractSwingWorker

Constructor Summary
AbstractSwingWorkerWithWaitCursor(Container aContainer)
          Creates an instance that shows the wait cursor during execution of AbstractSwingWorker.construct()for the specified container.
 
Method Summary
 void finished()
          Called on the event dispatching thread (not on the worker thread) after the AbstractSwingWorker.construct()method has returned. Displays the original cursor.
 Container getContainer()
          Gets the container.
 Cursor getOriginalCursor()
          Gets the original cursor.
 void setContainer(Container newContainer)
          Sets the container.
protected  void setOriginalCursor(Cursor newOriginalCursor)
          Remembers the original cursor.
 void started()
          Called on the event dispatching thread (not on the worker thread) before the AbstractSwingWorker.construct()method is called. Displays the wait cursor.
 
Methods inherited from class net.pacbell.jfai.toh.util.AbstractSwingWorker
construct, get, getThreadVar, getValue, interrupt, invokeAndWait, invokeLater, setThreadVar, setValue, showMessageDialog, start
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AbstractSwingWorkerWithWaitCursor

public AbstractSwingWorkerWithWaitCursor(Container aContainer)
Creates an instance that shows the wait cursor during execution of AbstractSwingWorker.construct()for the specified container.

Parameters:
aContainer - a container
Method Detail

finished

public void finished()
Called on the event dispatching thread (not on the worker thread) after the AbstractSwingWorker.construct()method has returned. By default, does nothing. Displays the original cursor.

Overrides:
finished in class AbstractSwingWorker

getContainer

public Container getContainer()
Gets the container.

Returns:
the container

getOriginalCursor

public Cursor getOriginalCursor()
Gets the original cursor.

Returns:
the original displayed cursor

setContainer

public void setContainer(Container newContainer)
Sets the container.

Parameters:
newContainer - the container

started

public void started()
Called on the event dispatching thread (not on the worker thread) before the AbstractSwingWorker.construct()method is called. By default, does nothing. Displays the wait cursor.

Overrides:
started in class AbstractSwingWorker

setOriginalCursor

protected void setOriginalCursor(Cursor newOriginalCursor)
Remembers the original cursor.

Parameters:
newOriginalCursor - the original cursor