Package org.jboss.netty.util.internal
Class ExecutorUtil
java.lang.Object
org.jboss.netty.util.internal.ExecutorUtil
Shuts down a list of
Executors. terminate(Executor...) will
shut down all specified ExecutorServices immediately and wait for
their termination. An Executor which is not an ExecutorService
will be ignored silently.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic booleanisShutdown(Executor executor) static voidshutdownNow(Executor executor) Try to callExecutorService.shutdownNow()static voidterminate(ThreadLocal<Executor> deadLockChecker, Executor... executors) Shuts down the specified executors using the givenThreadLocalto check if there is a deadlockstatic voidShuts down the specified executors.
-
Constructor Details
-
ExecutorUtil
private ExecutorUtil()
-
-
Method Details
-
shutdownNow
Try to callExecutorService.shutdownNow() -
isShutdown
Returnstrueif and only if the specifiedexecutoris anExecutorServiceand is shut down. Please note that this method returnsfalseif the specifiedexecutoris not anExecutorService. -
terminate
Shuts down the specified executors. -
terminate
Shuts down the specified executors using the givenThreadLocalto check if there is a deadlock
-