slib.utils.threads
Class ThreadManager

java.lang.Object
  extended by slib.utils.threads.PoolLocker
      extended by slib.utils.threads.ThreadManager

public class ThreadManager
extends PoolLocker

Author:
seb

Field Summary
 
Fields inherited from class slib.utils.threads.PoolLocker
capacity, lock, running
 
Method Summary
 void freeResource(int nbThread)
           
 PoolWorker getMaxLoadPoolWorker()
           
 int getMaxThread()
           
 PoolWorker getPoolWorker(int size)
           
static ThreadManager getSingleton()
           
 void setMaxThread(int maxThread)
           
 
Methods inherited from class slib.utils.threads.PoolLocker
addTask, awaitFreeResource, getCapacity, getLoad, taskComplete
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getSingleton

public static ThreadManager getSingleton()
Returns:

getMaxLoadPoolWorker

public PoolWorker getMaxLoadPoolWorker()
                                throws SLIB_Ex_Critic
Returns:
Throws:
SLIB_Ex_Critic

getPoolWorker

public PoolWorker getPoolWorker(int size)
                         throws SLIB_Ex_Critic
Parameters:
size -
Returns:
Throws:
SLIB_Ex_Critic

setMaxThread

public void setMaxThread(int maxThread)
Parameters:
maxThread -

getMaxThread

public int getMaxThread()
Returns:

freeResource

public void freeResource(int nbThread)
Parameters:
nbThread -


Copyright © 2013. All Rights Reserved.