Package com.mchange.v3.concurrent
Class BoundedExecutorService
java.lang.Object
java.util.concurrent.AbstractExecutorService
com.mchange.v3.concurrent.BoundedExecutorService
- All Implemented Interfaces:
Executor
,ExecutorService
-
Constructor Summary
ConstructorDescriptionBoundedExecutorService
(ExecutorService inner, int blockBound) BoundedExecutorService
(ExecutorService inner, int blockBound, int restartBeneath) -
Method Summary
Modifier and TypeMethodDescriptionboolean
awaitTermination
(long timeout, TimeUnit unit) void
com.mchange.v3.concurrent.BoundedExecutorService.State
getState()
boolean
boolean
protected <V> RunnableFuture<V>
newTaskFor
(Runnable runnable, V result) protected <V> RunnableFuture<V>
newTaskFor
(Callable<V> callable) void
shutdown()
-
Constructor Details
-
BoundedExecutorService
-
BoundedExecutorService
-
-
Method Details
-
getState
public com.mchange.v3.concurrent.BoundedExecutorService.State getState() -
isShutdown
public boolean isShutdown() -
isTerminated
public boolean isTerminated() -
shutdown
public void shutdown() -
shutdownNow
-
awaitTermination
- Throws:
InterruptedException
-
execute
-
newTaskFor
- Overrides:
newTaskFor
in classAbstractExecutorService
-
newTaskFor
- Overrides:
newTaskFor
in classAbstractExecutorService
-