| 
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||

java.lang.Objectorg.xsocket.DynamicWorkerPool
Executor) instead
public final class DynamicWorkerPool
| Field Summary | |
|---|---|
static int | 
DEFAULT_ADJUST_CHECK_PERIOD
Deprecated.  | 
static int | 
DEFAULT_LOAD_THRESHOLD_DECREASE
Deprecated.  | 
static int | 
DEFAULT_LOAD_THRESHOLD_INCREASE
Deprecated.  | 
static java.lang.String | 
WORKER_PREFIX
Deprecated.  | 
| Constructor Summary | |
|---|---|
DynamicWorkerPool(int minSize,
                  int maxSize)
Deprecated.  | 
|
| Method Summary | ||
|---|---|---|
 void | 
close()
Deprecated.  | 
|
 void | 
execute(java.lang.Runnable command)
Deprecated.  | 
|
 int | 
getActiveCount()
Deprecated.  | 
|
 int | 
getAdjustPeriod()
Deprecated.  | 
|
 int | 
getLoad()
Deprecated. return the load (range: 0...100)  | 
|
 int | 
getMaximumPoolSize()
Deprecated.  | 
|
 int | 
getMinimumPoolSize()
Deprecated.  | 
|
 int | 
getPoolSize()
Deprecated.  | 
|
 int | 
getThresholdDecrease()
Deprecated.  | 
|
 int | 
getThresholdIncrease()
Deprecated.  | 
|
 | 
invokeAll(java.util.Collection<java.util.concurrent.Callable<T>> tasks)
Deprecated.  | 
|
 boolean | 
isOpen()
Deprecated.  | 
|
 void | 
setAdjustPeriod(int adjustPeriodSec)
Deprecated.  | 
|
 void | 
setThresholdDecrease(int decThreshold)
Deprecated.  | 
|
 void | 
setThresholdIncrease(int incThreshold)
Deprecated.  | 
|
 java.lang.String | 
toString()
Deprecated.  | 
|
| Methods inherited from class java.lang.Object | 
|---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait | 
| Field Detail | 
|---|
public static final java.lang.String WORKER_PREFIX
public static final int DEFAULT_LOAD_THRESHOLD_DECREASE
public static final int DEFAULT_LOAD_THRESHOLD_INCREASE
public static final int DEFAULT_ADJUST_CHECK_PERIOD
| Constructor Detail | 
|---|
public DynamicWorkerPool(int minSize,
                         int maxSize)
minSize - the min pool size (and the initial size)maxSize - the max pool size| Method Detail | 
|---|
public void execute(java.lang.Runnable command)
execute in interface java.util.concurrent.Executorexecute in interface IWorkerPoolcommand - the commnd to execute
public <T> java.util.List<java.util.concurrent.Future<T>> invokeAll(java.util.Collection<java.util.concurrent.Callable<T>> tasks)
                                                         throws java.lang.InterruptedException
invokeAll in interface IWorkerPooltasks - the collection of tasks
java.lang.InterruptedException - if interrupted while waiting, in which case unfinished tasks are cancelled.public int getActiveCount()
getActiveCount in interface IWorkerPoolpublic int getPoolSize()
getPoolSize in interface IWorkerPoolpublic int getLoad()
public int getMaximumPoolSize()
public int getMinimumPoolSize()
public boolean isOpen()
public void close()
public void setAdjustPeriod(int adjustPeriodSec)
adjustPeriodSec - the adjust check period of the pool size in secondspublic int getAdjustPeriod()
public int getThresholdIncrease()
public void setThresholdIncrease(int incThreshold)
incThreshold - the increase thresholdpublic int getThresholdDecrease()
public void setThresholdDecrease(int decThreshold)
decThreshold - the decrease thresholdpublic java.lang.String toString()
toString in class java.lang.Object
  | 
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||