org.xsocket
Class SerializedTaskQueue
java.lang.Object
   org.xsocket.SerializedTaskQueue
org.xsocket.SerializedTaskQueue
- public final class SerializedTaskQueue 
- extends Object
Serialized Task Queue
 
 
This is a xSocket internal class and subject to change
- Author:
- grro@xsocket.org
 
 
| Methods inherited from class java.lang.Object | 
| clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait | 
 
SerializedTaskQueue
public SerializedTaskQueue()
performNonThreaded
public void performNonThreaded(Runnable task,
                               Executor workerpool)
- process a task non threaded synchronized by the internal task queue. If the 
 task queue is empty the task will be processed by the current thread. If a task running 
 or the task queue size is not empty, the task will be executed by a dedicated thread.
 
- 
- Parameters:
- task- the task to process
- workerpool- the workerpool
 
performMultiThreaded
public void performMultiThreaded(Runnable task,
                                 Executor workerpool)
- process a task multi threaded synchronized by the internal task queue. The task will
 be processed by a dedicated thread. The given worker pool can be used to perform this 
 tasks (as well as other task of the queue).
 
- 
- Parameters:
- task- the task to process
- workerpool- the workerpool
 
Copyright 2010 						xSocket.org