org.apache.batik.util.gui
Class MemoryMonitor.RepaintThread

java.lang.Object
  extended by java.lang.Thread
      extended by org.apache.batik.util.gui.MemoryMonitor.RepaintThread
All Implemented Interfaces:
Runnable
Enclosing class:
MemoryMonitor

public static class MemoryMonitor.RepaintThread
extends Thread

This thread repaints a list of components.


Nested Class Summary
protected  class MemoryMonitor.RepaintThread.UpdateRunnable
           
 
Nested classes/interfaces inherited from class java.lang.Thread
Thread.State, Thread.UncaughtExceptionHandler
 
Field Summary
protected  List components
          The components to repaint.
protected  Runtime runtime
          The runtime.
protected  boolean suspended
          Whether or not the thread was supended.
protected  long timeout
          The repaint timeout
protected  MemoryMonitor.RepaintThread.UpdateRunnable updateRunnable
          Runnable for updating components.
 
Fields inherited from class java.lang.Thread
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY
 
Constructor Summary
MemoryMonitor.RepaintThread(long timeout, List components)
          Creates a new Thread.
 
Method Summary
protected  MemoryMonitor.RepaintThread.UpdateRunnable createUpdateRunnable()
           
 void run()
          The thread main method.
 void safeResume()
          Resumes the thread.
 void safeSuspend()
          Suspends the thread.
 
Methods inherited from class java.lang.Thread
activeCount, checkAccess, clone, countStackFrames, currentThread, destroy, dumpStack, enumerate, getAllStackTraces, getContextClassLoader, getDefaultUncaughtExceptionHandler, getId, getName, getPriority, getStackTrace, getState, getThreadGroup, getUncaughtExceptionHandler, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, resume, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, start, stop, stop, suspend, toString, yield
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

timeout

protected long timeout
The repaint timeout


components

protected List components
The components to repaint.


runtime

protected Runtime runtime
The runtime.


suspended

protected boolean suspended
Whether or not the thread was supended.


updateRunnable

protected MemoryMonitor.RepaintThread.UpdateRunnable updateRunnable
Runnable for updating components.

Constructor Detail

MemoryMonitor.RepaintThread

public MemoryMonitor.RepaintThread(long timeout,
                                   List components)
Creates a new Thread.

Parameters:
timeout - The time between two repaint in ms.
components - The components to repaint.
Method Detail

run

public void run()
The thread main method.

Specified by:
run in interface Runnable
Overrides:
run in class Thread

createUpdateRunnable

protected MemoryMonitor.RepaintThread.UpdateRunnable createUpdateRunnable()

safeSuspend

public void safeSuspend()
Suspends the thread.


safeResume

public void safeResume()
Resumes the thread.



Copyright © 2008 Apache Software Foundation. All Rights Reserved.