| 
 | Jadex 0.96-beta1 | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectjadex.util.concurrent.ThreadPool
public class ThreadPool
A thread pool manages pool and saves resources and time by precreating and reusing pool.
| Nested Class Summary | |
|---|---|
|  class | ThreadPool.ServiceThreadA service thread executes tasks. | 
| Constructor Summary | |
|---|---|
| ThreadPool()Default constructor, called by the factory. | |
| Method Summary | |
|---|---|
|  void | dispose()Shutdown the task pool | 
|  void | execute(Runnable task)Execute a task in its own thread. | 
|  Runnable | getTask(Thread thread)The task for a given thread. | 
|  Thread | getThread(Runnable task)Get a thread for a task. | 
| static void | main(String[] args)Main for testing. | 
|  void | run()The observer thread. | 
|  String | toString()Get the string representation. | 
| Methods inherited from class java.lang.Object | 
|---|
| equals, getClass, hashCode, notify, notifyAll, wait, wait, wait | 
| Constructor Detail | 
|---|
public ThreadPool()
| Method Detail | 
|---|
public void execute(Runnable task)
execute in interface IThreadPooltask - The task to execute.public void dispose()
dispose in interface IThreadPoolpublic static void main(String[] args)
args - The arguments.public String toString()
toString in class Objectpublic Thread getThread(Runnable task)
public Runnable getTask(Thread thread)
public void run()
run in interface Runnable| 
 | Jadex 0.96-beta1 | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
Copyright (C) 2002-2007 Lars Braubach, Alexander Pokahr - University of Hamburg. Use is subject to license terms.