Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

org.apache.tomcat.util.threads
Class ThreadPool.MonitorRunnable  view ThreadPool.MonitorRunnable download ThreadPool.MonitorRunnable.java

java.lang.Object
  extended byorg.apache.tomcat.util.threads.ThreadPool.MonitorRunnable
All Implemented Interfaces:
java.lang.Runnable
Enclosing class:
ThreadPool

public static class ThreadPool.MonitorRunnable
extends java.lang.Object
implements java.lang.Runnable

Periodically execute an action - cleanup in this case


Field Summary
(package private)  int interval
           
(package private)  ThreadPool p
           
(package private)  boolean shouldTerminate
           
(package private)  java.lang.Thread t
           
 
Constructor Summary
(package private) ThreadPool.MonitorRunnable(ThreadPool p)
           
 
Method Summary
 void run()
          This method will be called by whoever wishes to run your class implementing Runnable.
 void setInterval(int i)
           
 void start()
           
 void stop()
           
 void terminate()
          Stop the monitor
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

p

ThreadPool p

t

java.lang.Thread t

interval

int interval

shouldTerminate

boolean shouldTerminate
Constructor Detail

ThreadPool.MonitorRunnable

ThreadPool.MonitorRunnable(ThreadPool p)
Method Detail

start

public void start()

setInterval

public void setInterval(int i)

run

public void run()
Description copied from interface: java.lang.Runnable
This method will be called by whoever wishes to run your class implementing Runnable. Note that there are no restrictions on what you are allowed to do in the run method, except that you cannot throw a checked exception.

Specified by:
run in interface java.lang.Runnable

stop

public void stop()

terminate

public void terminate()
Stop the monitor